zOs/TX/WK916DDL

------------$-{right(userid() sysvar(sysnode) date(s) time(), 60, '-')}
-- testCase $dsn
-- env      $env      phase $phase
-- subsys   $subsys     db $db       creator $creator
------------------------------------------------------------------------
---||| begin ddl testcase $mbr env $env phase $phase
$=tb=TWK916A1
SET CURRENT SQLID='S100447';
drop tablespace $db.a916a;
commit;
------------------------------------------------------------------------
CREATE TABLESPACE A916A
    IN $db
    USING STOGROUP GSMS
    PRIQTY -1 SECQTY -1
    ERASE  NO
    FREEPAGE 0 PCTFREE 10
    GBPCACHE CHANGED
    TRACKMOD YES
    SEGSIZE  64
    BUFFERPOOL BP2
    LOCKSIZE ANY
    LOCKMAX SYSTEM
    CLOSE YES
    COMPRESS YES
    CCSID      EBCDIC
    DEFINE YES
    MAXROWS 255
;  ---------------------------------------------------------------------
  CREATE TABLE $creator.$tb
     ( WK916CH20            CHAR(20) FOR SBCS DATA not null with default
     , WK916CH5             CHAR(5) FOR SBCS DATA not null with default
$@[
if $phase = 1 then $@=[
     , WK916FL float(21) not null with default
$] else if $phase >= 2 then $@=[
     , WK916FL float(53) not null with default
$]
$]
     , WK916CH1             CHAR(1) FOR SBCS DATA not null with default
     )
    IN $db.A916A
    AUDIT NONE
    DATA CAPTURE NONE
    CCSID      EBCDIC
    NOT VOLATILE ;
commit;
------------------------------------------------------------------------
  CREATE UNIQUE INDEX $creator.IWK916A0
    ON $creator.$tb
     ( WK916CH20            ASC
     )
    USING STOGROUP GSMS
    PRIQTY 40 SECQTY 40
    ERASE  NO
    FREEPAGE 10 PCTFREE 10
    GBPCACHE CHANGED
    BUFFERPOOL BP1
    CLUSTER
    CLOSE YES
    COPY NO
    DEFER NO
    DEFINE YES
    PIECESIZE 2 G;
  COMMIT;
$@[
if $phase = 2 | $phase > 5 then $@=[
  LABEL   ON TABLE $creator.$tb IS 'CASH BOOKING ORDERS' ;
  CREATE UNIQUE INDEX $creator.IWK916A1
    ON $creator.$tb
     ( WK916CH5             ASC
     )
    USING STOGROUP GSMS
    PRIQTY 40 SECQTY 40
    ERASE  NO
    FREEPAGE 10 PCTFREE 10
    GBPCACHE CHANGED
    BUFFERPOOL BP1
    not CLUSTER
    CLOSE YES
    COPY NO
    DEFER NO
    DEFINE YES
    PIECESIZE 2 G;
  COMMIT;
  CREATE INDEX $creator.IWK916A2
    ON $creator.$tb
     ( WK916FL            ASC
     )
    USING STOGROUP GSMS
    PRIQTY 40 SECQTY 40
    ERASE  NO
    FREEPAGE 10 PCTFREE 10
    GBPCACHE CHANGED
    not CLUSTER
    BUFFERPOOL BP1
    CLOSE YES
    COPY NO
    DEFER NO
    DEFINE YES
    PIECESIZE 2 G;
  COMMIT;
$]
$]
insert into $creator.$tb values
('erstens',  'eins',  1, '');
insert into $creator.$tb values
('zweitens', 'zwei',  22, '');
insert into $creator.$tb values
('drittens', 'drei',  333, '');
insert into $creator.$tb values
('viertens', 'vier',  4444e-4, '');
insert into $creator.$tb values
('fuenftens', 'fuenf', 55555e5, '');
commit;
---||| end   ddl testcase $mbr env $env phase $phase