/**Begin D:\PDM_UPGRADE\PDM1\TSRBD_constraint.sql **/
 EXEC P_ALTERPK 'PK_TSRBD_INSPECTDIM', 'T_TSRBD_INSPECTDIM', 'FINSPECTDIMID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INSPECTDIM') CREATE INDEX IDX_TSRBD_INSPECTDIM ON T_TSRBD_INSPECTDIM ( FID ,FINDEX );


 EXEC P_ALTERPK 'PK_TSRBD_INSPECTDIM_L', 'T_TSRBD_INSPECTDIM_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INSPECTDIM_L') CREATE INDEX IDX_TSRBD_INSPECTDIM_L ON T_TSRBD_INSPECTDIM_L ( FINSPECTDIMID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INSPECTQU', 'T_TSRBD_INSPECTQU', 'FINSPECTQUID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INSPECTQU') CREATE INDEX IDX_TSRBD_INSPECTQU ON T_TSRBD_INSPECTQU ( FINSPECTDIMID ,FINDEX );


 EXEC P_ALTERPK 'PK_TSRBD_INSPECTQU_L', 'T_TSRBD_INSPECTQU_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INSPECTQU_L') CREATE INDEX IDX_TSRBD_INSPECTQU_L ON T_TSRBD_INSPECTQU_L ( FINSPECTQUID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVEVLQUNR_L', 'T_TSRBD_INTVEVLQUNR_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVEVLQUNR_L') CREATE INDEX IDX_TSRBD_INTVEVLQUNR_L ON T_TSRBD_INTVEVLQUNR_L ( FID ,FLOCALEID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVEVLQUNR_L_NAME') CREATE INDEX IDX_TSRBD_INTVEVLQUNR_L_NAME ON T_TSRBD_INTVEVLQUNR_L ( FNAME );


 EXEC P_ALTERPK 'PK_TSRBD_INTVEVLQUNRDEF', 'T_TSRBD_INTVEVLQUNRDEF', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_INTVEVLQUNRDE_QUNRID') CREATE INDEX IDX_INTVEVLQUNRDE_QUNRID ON T_TSRBD_INTVEVLQUNRDEF ( FINTVEVLQUNRID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_USEORG_RECCATEGORYID') CREATE INDEX IDX_USEORG_RECCATEGORYID ON T_TSRBD_INTVEVLQUNRDEF ( FUSEORGID ,FRECCATEGORYID );


 EXEC P_ALTERPK 'PK_TSRBD_SUBOPTION_L', 'T_TSRBD_SUBOPTION_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SUBOPTION_L') CREATE INDEX IDX_TSRBD_SUBOPTION_L ON T_TSRBD_SUBOPTION_L ( FDETAILID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVEVLQUNR', 'T_TSRBD_INTVEVLQUNR', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_INTVEVLQUNR_NUMBER') CREATE INDEX IDX_INTVEVLQUNR_NUMBER ON T_TSRBD_INTVEVLQUNR ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_SUBOPTION', 'T_TSRBD_SUBOPTION', 'FDETAILID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SUBOPTION') CREATE INDEX IDX_TSRBD_SUBOPTION ON T_TSRBD_SUBOPTION ( FINSPECTQUID );


 EXEC P_ALTERPK 'PK_TSRBD_SECFUNCONFENTITY', 'T_TSRBD_SECFUNCONFENTITY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECENTITY_FID') CREATE INDEX IDX_TSRBD_SECENTITY_FID ON T_TSRBD_SECFUNCONFENTITY ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_SECFUNCONFENTITY_L', 'T_TSRBD_SECFUNCONFENTITY_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECFUNCONFENTITY_L') CREATE INDEX IDX_TSRBD_SECFUNCONFENTITY_L ON T_TSRBD_SECFUNCONFENTITY_L ( FENTRYID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_SECURITYFUNCONF', 'T_TSRBD_SECURITYFUNCONF', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECCONF_FNUM') CREATE INDEX IDX_TSRBD_SECCONF_FNUM ON T_TSRBD_SECURITYFUNCONF ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_SECURITYFUNCONF_L', 'T_TSRBD_SECURITYFUNCONF_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECURITYFUNCONF_L') CREATE INDEX IDX_TSRBD_SECURITYFUNCONF_L ON T_TSRBD_SECURITYFUNCONF_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_SECURITYLEVEL', 'T_TSRBD_SECURITYLEVEL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECURITYLEVEL') CREATE INDEX IDX_TSRBD_SECURITYLEVEL ON T_TSRBD_SECURITYLEVEL ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_SECURITYLEVEL_L', 'T_TSRBD_SECURITYLEVEL_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECURITYLEVELL_NUM') CREATE INDEX IDX_TSRBD_SECURITYLEVELL_NUM ON T_TSRBD_SECURITYLEVEL_L ( FNAME );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECURITYLEVELL_DES') CREATE INDEX IDX_TSRBD_SECURITYLEVELL_DES ON T_TSRBD_SECURITYLEVEL_L ( FDESCRIPTION );


 EXEC P_ALTERPK 'PK_TSRBD_SECUSERLEVEL', 'T_TSRBD_SECUSERLEVEL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECUSERL_FUSERID') CREATE INDEX IDX_TSRBD_SECUSERL_FUSERID ON T_TSRBD_SECUSERLEVEL ( FUSERID );


 EXEC P_ALTERPK 'PK_TSRBD_SECUSERLEVELENT', 'T_TSRBD_SECUSERLEVELENT', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_SECUSERLEVELENT_FSEQ') CREATE INDEX IDX_TSRBD_SECUSERLEVELENT_FSEQ ON T_TSRBD_SECUSERLEVELENT ( FSEQ );


 EXEC P_ALTERPK 'PK_TSRBD_OPDEF', 'T_TSRBD_OPDEF', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPDEF_NUMBER') CREATE INDEX IDX_TSRBD_OPDEF_NUMBER ON T_TSRBD_OPDEF ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_OPDEF_L', 'T_TSRBD_OPDEF_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPDEF_L') CREATE INDEX IDX_TSRBD_OPDEF_L ON T_TSRBD_OPDEF_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_OPRECORD', 'T_TSRBD_OPRECORD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPRECORD_OPTIME') CREATE INDEX IDX_TSRBD_OPRECORD_OPTIME ON T_TSRBD_OPRECORD ( FOPTIME );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPRECORD_BIZOBJ') CREATE INDEX IDX_TSRBD_OPRECORD_BIZOBJ ON T_TSRBD_OPRECORD ( FBIZOBJ );


 EXEC P_ALTERPK 'PK_TSRBD_OBJFCRECORD', 'T_TSRBD_OBJFCRECORD', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OBJFCRECORD_ENTRY') CREATE INDEX IDX_TSRBD_OBJFCRECORD_ENTRY ON T_TSRBD_OBJFCRECORD ( FID );

/**
 EXEC P_ALTERPK 'PK_TSRBD_LABEL', 'T_TSRBD_LABEL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LABEL_FNUMBER') CREATE INDEX IDX_TSRBD_LABEL_FNUMBER ON T_TSRBD_LABEL ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_LABEL_L', 'T_TSRBD_LABEL_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LABEL_L') CREATE INDEX IDX_TSRBD_LABEL_L ON T_TSRBD_LABEL_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_LABELOBJTYPE', 'T_TSRBD_LABELOBJTYPE', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LABELOBJTYPE') CREATE INDEX IDX_TSRBD_LABELOBJTYPE ON T_TSRBD_LABELOBJTYPE ( FBASEDATAID );


 EXEC P_ALTERPK 'PK_TSRBD_LABELTYPE', 'T_TSRBD_LABELTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LABELTYPE') CREATE INDEX IDX_TSRBD_LABELTYPE ON T_TSRBD_LABELTYPE ( FNAME );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LABELTYPE_FCODE') CREATE INDEX IDX_TSRBD_LABELTYPE_FCODE ON T_TSRBD_LABELTYPE ( FCODE );


 EXEC P_ALTERPK 'PK_TSRBD_LABELTYPE_L', 'T_TSRBD_LABELTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LABELTYPE_L') CREATE INDEX IDX_TSRBD_LABELTYPE_L ON T_TSRBD_LABELTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_TAGOBJTYPE', 'T_TSRBD_TAGOBJTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSPPM_TAGOBJTYPE_FNUMBER') CREATE INDEX IDX_TSPPM_TAGOBJTYPE_FNUMBER ON T_TSRBD_TAGOBJTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_TAGOBJTYPE_L', 'T_TSRBD_TAGOBJTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_TAGOBJTYPE_L') CREATE INDEX IDX_TSRBD_TAGOBJTYPE_L ON T_TSRBD_TAGOBJTYPE_L ( FID ,FLOCALEID );

 **/
 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELDCTRTYP', 'T_TSRBD_MTDFIELDCTRTYP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELDCTRTYP') CREATE INDEX IDX_TSRBD_MTDFIELDCTRTYP ON T_TSRBD_MTDFIELDCTRTYP ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELDCTRTYP_L', 'T_TSRBD_MTDFIELDCTRTYP_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELDCTRTYP_L') CREATE INDEX IDX_TSRBD_MTDFIELDCTRTYP_L ON T_TSRBD_MTDFIELDCTRTYP_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELDENTRY', 'T_TSRBD_MTDFIELDENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELDENTRY_FID') CREATE INDEX IDX_TSRBD_MTDFIELDENTRY_FID ON T_TSRBD_MTDFIELDENTRY ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELDENTRY_L', 'T_TSRBD_MTDFIELDENTRY_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELDENTRY_L') CREATE INDEX IDX_TSRBD_MTDFIELDENTRY_L ON T_TSRBD_MTDFIELDENTRY_L ( FENTRYID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELDGROUP', 'T_TSRBD_MTDFIELDGROUP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELDGROUP_OBJ') CREATE INDEX IDX_TSRBD_MTDFIELDGROUP_OBJ ON T_TSRBD_MTDFIELDGROUP ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELDGROUP_L', 'T_TSRBD_MTDFIELDGROUP_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELDGROUP_L') CREATE INDEX IDX_TSRBD_MTDFIELDGROUP_L ON T_TSRBD_MTDFIELDGROUP_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDOBJ_L', 'T_TSRBD_MTDOBJ_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDOBJ_L') CREATE INDEX IDX_TSRBD_MTDOBJ_L ON T_TSRBD_MTDOBJ_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDOBJTABLE', 'T_TSRBD_MTDOBJTABLE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDOBJTABLE_OBJ') CREATE INDEX IDX_TSRBD_MTDOBJTABLE_OBJ ON T_TSRBD_MTDOBJTABLE ( FMTDOBJID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELD_L', 'T_TSRBD_MTDFIELD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELD_L') CREATE INDEX IDX_TSRBD_MTDFIELD_L ON T_TSRBD_MTDFIELD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MTDOBJ', 'T_TSRBD_MTDOBJ', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDOBJ') CREATE INDEX IDX_TSRBD_MTDOBJ ON T_TSRBD_MTDOBJ ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MTDFIELD', 'T_TSRBD_MTDFIELD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELD_FNUMBER') CREATE INDEX IDX_TSRBD_MTDFIELD_FNUMBER ON T_TSRBD_MTDFIELD ( FNUMBER );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MTDFIELD_FGROUP') CREATE INDEX IDX_TSRBD_MTDFIELD_FGROUP ON T_TSRBD_MTDFIELD ( FGROUPID );


 EXEC P_ALTERPK 'PK_TSRBD_FIELDBASEDATA', 'T_TSRBD_FIELDBASEDATA', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_BD_FNUMBER') CREATE INDEX IDX_TSRBD_BD_FNUMBER ON T_TSRBD_FIELDBASEDATA ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_FIELDBASEDATA_L', 'T_TSRBD_FIELDBASEDATA_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDBASEDATA_L') CREATE INDEX IDX_TSRBD_FIELDBASEDATA_L ON T_TSRBD_FIELDBASEDATA_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_JOURNALGRADE', 'T_TSRBD_JOURNALGRADE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOURNALGRADE_NUM') CREATE INDEX IDX_TSRBD_JOURNALGRADE_NUM ON T_TSRBD_JOURNALGRADE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_JOURNALGRADE_L', 'T_TSRBD_JOURNALGRADE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOURNALGRADE_L') CREATE INDEX IDX_TSRBD_JOURNALGRADE_L ON T_TSRBD_JOURNALGRADE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_JOURNALTYPE', 'T_TSRBD_JOURNALTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOURNALTYPE_NUM') CREATE INDEX IDX_TSRBD_JOURNALTYPE_NUM ON T_TSRBD_JOURNALTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_JOURNALTYPE_L', 'T_TSRBD_JOURNALTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOURNALTYPE_L') CREATE INDEX IDX_TSRBD_JOURNALTYPE_L ON T_TSRBD_JOURNALTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_LANGUAGE', 'T_TSRBD_LANGUAGE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LANGUAGE_FNUMBER') CREATE INDEX IDX_TSRBD_LANGUAGE_FNUMBER ON T_TSRBD_LANGUAGE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_LANGUAGE_L', 'T_TSRBD_LANGUAGE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LANGUAGE_L') CREATE INDEX IDX_TSRBD_LANGUAGE_L ON T_TSRBD_LANGUAGE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_LEAVEREASON', 'T_TSRBD_LEAVEREASON', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LEAVEREASON_FNUMBER') CREATE INDEX IDX_TSRBD_LEAVEREASON_FNUMBER ON T_TSRBD_LEAVEREASON ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_LEAVEREASON_L', 'T_TSRBD_LEAVEREASON_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LEAVEREASON_L') CREATE INDEX IDX_TSRBD_LEAVEREASON_L ON T_TSRBD_LEAVEREASON_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_PATENTTYPE', 'T_TSRBD_PATENTTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PATENTTYPE_NUM') CREATE INDEX IDX_TSRBD_PATENTTYPE_NUM ON T_TSRBD_PATENTTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_PATENTTYPE_L', 'T_TSRBD_PATENTTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PATENTTYPE_L') CREATE INDEX IDX_TSRBD_PATENTTYPE_L ON T_TSRBD_PATENTTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_BIZCONFIGDATA', 'T_TSRBD_BIZCONFIGDATA', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_BIZCONFIGDATA') CREATE INDEX IDX_TSRBD_BIZCONFIGDATA ON T_TSRBD_BIZCONFIGDATA ( FNUMBER );

EXEC P_ALTERPK 'PK_TSRBD_BIZCONFIGDATA_L', 'T_TSRBD_BIZCONFIGDATA_L', 'FPKID', '1';

IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_BIZCONFIGDATA_L') CREATE INDEX IDX_TSRBD_BIZCONFIGDATA_L ON T_TSRBD_BIZCONFIGDATA_L ( FID ,FLOCALEID );

 EXEC P_ALTERPK 'PK_TSRBD_FIELDBLOCK', 'T_TSRBD_FIELDBLOCK', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDBLOCK_NUM') CREATE INDEX IDX_TSRBD_FIELDBLOCK_NUM ON T_TSRBD_FIELDBLOCK ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_FIELDBLOCK_L', 'T_TSRBD_FIELDBLOCK_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDBLOCK_L') CREATE INDEX IDX_TSRBD_FIELDBLOCK_L ON T_TSRBD_FIELDBLOCK_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_FIELDPOOL', 'T_TSRBD_FIELDPOOL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDPOOL_NUM') CREATE INDEX IDX_TSRBD_FIELDPOOL_NUM ON T_TSRBD_FIELDPOOL ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_FIELDPOOL_L', 'T_TSRBD_FIELDPOOL_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDPOOL_L') CREATE INDEX IDX_TSRBD_FIELDPOOL_L ON T_TSRBD_FIELDPOOL_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGFIELD', 'T_TSRBD_MSGFIELD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGFIELD_NUM') CREATE INDEX IDX_TSRBD_MSGFIELD_NUM ON T_TSRBD_MSGFIELD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MSGFIELD_L', 'T_TSRBD_MSGFIELD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGFIELD_L') CREATE INDEX IDX_TSRBD_MSGFIELD_L ON T_TSRBD_MSGFIELD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_OFFERTEMPLATE_L', 'T_TSRBD_OFFERTEMPLATE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OFFERTEMPLATE_L') CREATE INDEX IDX_TSRBD_OFFERTEMPLATE_L ON T_TSRBD_OFFERTEMPLATE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_OFFERTEMPLATE', 'T_TSRBD_OFFERTEMPLATE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OFFERTEMPLATE_NUM') CREATE INDEX IDX_TSRBD_OFFERTEMPLATE_NUM ON T_TSRBD_OFFERTEMPLATE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUCHNLMEDIA', 'T_TSRBD_RECRUCHNLMEDIA', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUCHNLMEDIA_FNUM') CREATE INDEX IDX_TSRBD_RECRUCHNLMEDIA_FNUM ON T_TSRBD_RECRUCHNLMEDIA ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUCHNLMEDIA_L', 'T_TSRBD_RECRUCHNLMEDIA_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUCHNLMEDIA_L') CREATE INDEX IDX_TSRBD_RECRUCHNLMEDIA_L ON T_TSRBD_RECRUCHNLMEDIA_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RECRURSNTYP', 'T_TSRBD_RECRURSNTYP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRURSNTYP_FNUM') CREATE INDEX IDX_TSRBD_RECRURSNTYP_FNUM ON T_TSRBD_RECRURSNTYP ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRURSNTYP_L', 'T_TSRBD_RECRURSNTYP_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRURSNTYP_L') CREATE INDEX IDX_TSRBD_RECRURSNTYP_L ON T_TSRBD_RECRURSNTYP_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RESACQMTHD', 'T_TSRBD_RESACQMTHD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RESACQMTHD_FNUM') CREATE INDEX IDX_TSRBD_RESACQMTHD_FNUM ON T_TSRBD_RESACQMTHD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RESACQMTHD_L', 'T_TSRBD_RESACQMTHD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RESACQMTHD_L') CREATE INDEX IDX_TSRBD_RESACQMTHD_L ON T_TSRBD_RESACQMTHD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVLINK', 'T_TSRBD_INTVLINK', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVLINK_FNUMBER') CREATE INDEX IDX_TSRBD_INTVLINK_FNUMBER ON T_TSRBD_INTVLINK ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_INTVLINK_L', 'T_TSRBD_INTVLINK_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVLINK_L') CREATE INDEX IDX_TSRBD_INTVLINK_L ON T_TSRBD_INTVLINK_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVMTHD', 'T_TSRBD_INTVMTHD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVMTHD_FNUMBER') CREATE INDEX IDX_TSRBD_INTVMTHD_FNUMBER ON T_TSRBD_INTVMTHD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_INTVMTHD_L', 'T_TSRBD_INTVMTHD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVMTHD_L') CREATE INDEX IDX_TSRBD_INTVMTHD_L ON T_TSRBD_INTVMTHD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVORGFRM', 'T_TSRBD_INTVORGFRM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_IOFRM_NUMBER') CREATE INDEX IDX_TSRBD_IOFRM_NUMBER ON T_TSRBD_INTVORGFRM ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_INTVORGFRM_L', 'T_TSRBD_INTVORGFRM_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVORGFRM_L') CREATE INDEX IDX_TSRBD_INTVORGFRM_L ON T_TSRBD_INTVORGFRM_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVTYP', 'T_TSRBD_INTVTYP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVTYP_FNUMBER') CREATE INDEX IDX_TSRBD_INTVTYP_FNUMBER ON T_TSRBD_INTVTYP ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_INTVTYP_L', 'T_TSRBD_INTVTYP_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVTYP_L') CREATE INDEX IDX_TSRBD_INTVTYP_L ON T_TSRBD_INTVTYP_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_PAYMENTTYPE', 'T_TSRBD_PAYMENTTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PAYMENTTYPE_FNUMBER') CREATE INDEX IDX_TSRBD_PAYMENTTYPE_FNUMBER ON T_TSRBD_PAYMENTTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_PAYMENTTYPE_L', 'T_TSRBD_PAYMENTTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PAYMENTTYPE_L') CREATE INDEX IDX_TSRBD_PAYMENTTYPE_L ON T_TSRBD_PAYMENTTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_BASEDATALIST', 'T_TSRBD_BASEDATALIST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_BASEDATALIST_FNUM') CREATE INDEX IDX_TSRBD_BASEDATALIST_FNUM ON T_TSRBD_BASEDATALIST ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_BASEDATALIST_L', 'T_TSRBD_BASEDATALIST_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_BASEDATALIST_L') CREATE INDEX IDX_TSRBD_BASEDATALIST_L ON T_TSRBD_BASEDATALIST_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSTGTYP', 'T_TSRBD_RECRUSTGTYP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSTGTYP_FNUM') CREATE INDEX IDX_TSRBD_RECRUSTGTYP_FNUM ON T_TSRBD_RECRUSTGTYP ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSTGTYP_L', 'T_TSRBD_RECRUSTGTYP_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSTGTYP_L') CREATE INDEX IDX_TSRBD_RECRUSTGTYP_L ON T_TSRBD_RECRUSTGTYP_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_FILTERTYPE', 'T_TSRBD_FILTERTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FILTERTYPE_FNUMBER') CREATE INDEX IDX_TSRBD_FILTERTYPE_FNUMBER ON T_TSRBD_FILTERTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_FILTERTYPE_L', 'T_TSRBD_FILTERTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FILTERTYPE_L') CREATE INDEX IDX_TSRBD_FILTERTYPE_L ON T_TSRBD_FILTERTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_LANGUAGEVERSION_L', 'T_TSRBD_LANGUAGEVERSION_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LANGUAGEVERSION_L') CREATE INDEX IDX_TSRBD_LANGUAGEVERSION_L ON T_TSRBD_LANGUAGEVERSION_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RQMTPROCENTITY', 'T_TSRBD_RQMTPROCENTITY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RQMTPROCENTITY_FID') CREATE INDEX IDX_TSRBD_RQMTPROCENTITY_FID ON T_TSRBD_RQMTPROCENTITY ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_RQMTPROCSUBENT', 'T_TSRBD_RQMTPROCSUBENT', 'FDETAILID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RQMTPROCSUBENT_FETY') CREATE INDEX IDX_TSRBD_RQMTPROCSUBENT_FETY ON T_TSRBD_RQMTPROCSUBENT ( FENTRYID );


 EXEC P_ALTERPK 'PK_TSRBD_RQMTPROC_L', 'T_TSRBD_RQMTPROC_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RQMTPROC_L') CREATE INDEX IDX_TSRBD_RQMTPROC_L ON T_TSRBD_RQMTPROC_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_JOBSTATUS_L', 'T_TSRBD_JOBSTATUS_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOBSTATUS_L') CREATE INDEX IDX_TSRBD_JOBSTATUS_L ON T_TSRBD_JOBSTATUS_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_JOBSTATUS', 'T_TSRBD_JOBSTATUS', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOBSTATUS_FNUM') CREATE INDEX IDX_TSRBD_JOBSTATUS_FNUM ON T_TSRBD_JOBSTATUS ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUCHNLNM_L', 'T_TSRBD_RECRUCHNLNM_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUCHNLNM_L') CREATE INDEX IDX_TSRBD_RECRUCHNLNM_L ON T_TSRBD_RECRUCHNLNM_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RECRURSN', 'T_TSRBD_RECRURSN', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRURSN_FNUM') CREATE INDEX IDX_TSRBD_RECRURSN_FNUM ON T_TSRBD_RECRURSN ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRURSN_L', 'T_TSRBD_RECRURSN_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRURSN_L') CREATE INDEX IDX_TSRBD_RECRURSN_L ON T_TSRBD_RECRURSN_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSTGNEW', 'T_TSRBD_RECRUSTGNEW', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSTGNEW_FNUM') CREATE INDEX IDX_TSRBD_RECRUSTGNEW_FNUM ON T_TSRBD_RECRUSTGNEW ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSTGNEW_L', 'T_TSRBD_RECRUSTGNEW_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSTGNEW_L') CREATE INDEX IDX_TSRBD_RECRUSTGNEW_L ON T_TSRBD_RECRUSTGNEW_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSTATNEW', 'T_TSRBD_RECRUSTATNEW', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBS_RECRUSTATNEW_FNUM') CREATE INDEX IDX_TSRBS_RECRUSTATNEW_FNUM ON T_TSRBD_RECRUSTATNEW ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSTATNEW_L', 'T_TSRBD_RECRUSTATNEW_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSTATNEW_L') CREATE INDEX IDX_TSRBD_RECRUSTATNEW_L ON T_TSRBD_RECRUSTATNEW_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RSNSELNEWENTRY', 'T_TSRBD_RSNSELNEWENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RSNSELNEWENTRY_FID') CREATE INDEX IDX_TSRBD_RSNSELNEWENTRY_FID ON T_TSRBD_RSNSELNEWENTRY ( FID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RSNSEL_FRSNNUM') CREATE INDEX IDX_TSRBD_RSNSEL_FRSNNUM ON T_TSRBD_RSNSELNEWENTRY ( FREASONNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_STATSELNEWENTRY', 'T_TSRBD_STATSELNEWENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_STATSELENTRYNEW_FID') CREATE INDEX IDX_TSRBD_STATSELENTRYNEW_FID ON T_TSRBD_STATSELNEWENTRY ( FID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_STATSELENTRY_FSTAT') CREATE INDEX IDX_TSRBD_STATSELENTRY_FSTAT ON T_TSRBD_STATSELNEWENTRY ( FSTATID );


 EXEC P_ALTERPK 'PK_TSRBD_POSCAT', 'T_TSRBD_POSCAT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_POSCAT_FNUM') CREATE INDEX IDX_TSRBD_POSCAT_FNUM ON T_TSRBD_POSCAT ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_POSCAT_L', 'T_TSRBD_POSCAT_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_POSCAT_L') CREATE INDEX IDX_TSRBD_POSCAT_L ON T_TSRBD_POSCAT_L ( FID ,FLOCALEID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_POSCAT_L_FNAME') CREATE INDEX IDX_TSRBD_POSCAT_L_FNAME ON T_TSRBD_POSCAT_L ( FNAME );


 EXEC P_ALTERPK 'PK_TSRBD_APPMTHD', 'T_TSRBD_APPMTHD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_APPMTHD_FNUM') CREATE INDEX IDX_TSRBD_APPMTHD_FNUM ON T_TSRBD_APPMTHD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_APPMTHD_L', 'T_TSRBD_APPMTHD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_APPMTHD_L') CREATE INDEX IDX_TSRBD_APPMTHD_L ON T_TSRBD_APPMTHD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_TGTCOLL', 'T_TSRBD_TGTCOLL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_TGTCOLL_FNUM') CREATE INDEX IDX_TSRBD_TGTCOLL_FNUM ON T_TSRBD_TGTCOLL ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_TGTCOLL_L', 'T_TSRBD_TGTCOLL_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_TGTCOLL_L') CREATE INDEX IDX_TSRBD_TGTCOLL_L ON T_TSRBD_TGTCOLL_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_TGTCOLLENTRY', 'T_TSRBD_TGTCOLLENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_TGTCOLLENTRY_FID') CREATE INDEX IDX_TSRBD_TGTCOLLENTRY_FID ON T_TSRBD_TGTCOLLENTRY ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_OFFERSTATUS', 'T_TSRBD_OFFERSTATUS', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OFFERSTATUS_NUM') CREATE INDEX IDX_TSRBD_OFFERSTATUS_NUM ON T_TSRBD_OFFERSTATUS ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_OFFERSTATUS_L', 'T_TSRBD_OFFERSTATUS_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OFFERSTATUS_L') CREATE INDEX IDX_TSRBD_OFFERSTATUS_L ON T_TSRBD_OFFERSTATUS_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_OFFERSTATUSTYPE', 'T_TSRBD_OFFERSTATUSTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OFFERSTATUSTYPE_NUM') CREATE INDEX IDX_TSRBD_OFFERSTATUSTYPE_NUM ON T_TSRBD_OFFERSTATUSTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_OFFERSTATUSTYPE_L', 'T_TSRBD_OFFERSTATUSTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OFFERSTATUSTYPE_L') CREATE INDEX IDX_TSRBD_OFFERSTATUSTYPE_L ON T_TSRBD_OFFERSTATUSTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMAIL_L', 'T_TSRBD_CFGMAIL_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMAIL_L') CREATE INDEX IDX_TSRBD_CFGMAIL_L ON T_TSRBD_CFGMAIL_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_RECYCLERECORD', 'T_TSRBD_RECYCLERECORD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECYCLERECORD_FMAIL') CREATE INDEX IDX_TSRBD_RECYCLERECORD_FMAIL ON T_TSRBD_RECYCLERECORD ( FMAILINFOID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGCHANNLIST_L', 'T_TSRBD_CFGCHANNLIST_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGCHANNLIST_L') CREATE INDEX IDX_TSRBD_CFGCHANNLIST_L ON T_TSRBD_CFGCHANNLIST_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGCHANNLIST', 'T_TSRBD_CFGCHANNLIST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGCHANNLIST_FNUMBER') CREATE INDEX IDX_TSRBD_CFGCHANNLIST_FNUMBER ON T_TSRBD_CFGCHANNLIST ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECYCLETASK', 'T_TSRBD_RECYCLETASK', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECYCLETASK_FMAIL') CREATE INDEX IDX_TSRBD_RECYCLETASK_FMAIL ON T_TSRBD_RECYCLETASK ( FMAILINFOID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMAILPROP', 'T_TSRBD_CFGMAILPROP', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMAILPROP_FSERVER') CREATE INDEX IDX_TSRBD_CFGMAILPROP_FSERVER ON T_TSRBD_CFGMAILPROP ( FSERVERADDR );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMAIL', 'T_TSRBD_CFGMAIL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMAIL_FMAILADDR') CREATE INDEX IDX_TSRBD_CFGMAIL_FMAILADDR ON T_TSRBD_CFGMAIL ( FEMAILADDR );


 EXEC P_ALTERPK 'PK_TSRBD_WORKADDR', 'T_TSRBD_WORKADDR', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_WORKADDR') CREATE INDEX IDX_TSRBD_WORKADDR ON T_TSRBD_WORKADDR ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_WORKADDR_L', 'T_TSRBD_WORKADDR_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_WORKADDR_L') CREATE INDEX IDX_TSRBD_WORKADDR_L ON T_TSRBD_WORKADDR_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGRESURULE', 'T_TSRBD_CFGRESURULE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGRESURULE') CREATE INDEX IDX_TSRBD_CFGRESURULE ON T_TSRBD_CFGRESURULE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGRESURULE_L', 'T_TSRBD_CFGRESURULE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGRESURULE_L') CREATE INDEX IDX_TSRBD_CFGRESURULE_L ON T_TSRBD_CFGRESURULE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGRESURULEFD', 'T_TSRBD_CFGRESURULEFD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGRESURULEFD') CREATE INDEX IDX_TSRBD_CFGRESURULEFD ON T_TSRBD_CFGRESURULEFD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGRESURULEFD_L', 'T_TSRBD_CFGRESURULEFD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGRESURULEFD_L') CREATE INDEX IDX_TSRBD_CFGRESURULEFD_L ON T_TSRBD_CFGRESURULEFD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MAJORCATEGORY', 'T_TSRBD_MAJORCATEGORY', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MAJORCATE_FNUMBER') CREATE INDEX IDX_TSRBD_MAJORCATE_FNUMBER ON T_TSRBD_MAJORCATEGORY ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MAJORCATEGORY_L', 'T_TSRBD_MAJORCATEGORY_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MAJORCATEGORY_L') CREATE INDEX IDX_TSRBD_MAJORCATEGORY_L ON T_TSRBD_MAJORCATEGORY_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MAJORSUBCATEGORY', 'T_TSRBD_MAJORSUBCATEGORY', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MAJORSUBCATE_FNUM') CREATE INDEX IDX_TSRBD_MAJORSUBCATE_FNUM ON T_TSRBD_MAJORSUBCATEGORY ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MAJORSUBCATEGORY_L', 'T_TSRBD_MAJORSUBCATEGORY_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MAJORSUBCATEGORY_L') CREATE INDEX IDX_TSRBD_MAJORSUBCATEGORY_L ON T_TSRBD_MAJORSUBCATEGORY_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CHANNELACCOUNT_L', 'T_TSRBD_CHANNELACCOUNT_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CHANNELACCOUNT_L') CREATE INDEX IDX_TSRBD_CHANNELACCOUNT_L ON T_TSRBD_CHANNELACCOUNT_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGCAT', 'T_TSRBD_CFGMSGCAT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGCAT_FNUMBER') CREATE INDEX IDX_TSRBD_CFGMSGCAT_FNUMBER ON T_TSRBD_CFGMSGCAT ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGCAT_L', 'T_TSRBD_CFGMSGCAT_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGCAT_L') CREATE INDEX IDX_TSRBD_CFGMSGCAT_L ON T_TSRBD_CFGMSGCAT_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGRECVTYPE', 'T_TSRBD_CFGMSGRECVTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGRECVTYPE_FNUMBER') CREATE INDEX IDX_TSRBD_MSGRECVTYPE_FNUMBER ON T_TSRBD_CFGMSGRECVTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGRECVTYPE_L', 'T_TSRBD_CFGMSGRECVTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGRECVTYPE_L') CREATE INDEX IDX_TSRBD_CFGMSGRECVTYPE_L ON T_TSRBD_CFGMSGRECVTYPE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGSCENE', 'T_TSRBD_CFGMSGSCENE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGSCENE_FNUMBER') CREATE INDEX IDX_TSRBD_CFGMSGSCENE_FNUMBER ON T_TSRBD_CFGMSGSCENE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGSCENE_L', 'T_TSRBD_CFGMSGSCENE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGSCENE_L') CREATE INDEX IDX_TSRBD_CFGMSGSCENE_L ON T_TSRBD_CFGMSGSCENE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGSENDLOG', 'T_TSRBD_CFGMSGSENDLOG', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGLOG_FNUMBER') CREATE INDEX IDX_TSRBD_CFGMSGLOG_FNUMBER ON T_TSRBD_CFGMSGSENDLOG ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGTEMPFD', 'T_TSRBD_CFGMSGTEMPFD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGTEMPFD_FNUMBER') CREATE INDEX IDX_TSRBD_CFGMSGTEMPFD_FNUMBER ON T_TSRBD_CFGMSGTEMPFD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGTEMPFD_L', 'T_TSRBD_CFGMSGTEMPFD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGTEMPFD_L') CREATE INDEX IDX_TSRBD_CFGMSGTEMPFD_L ON T_TSRBD_CFGMSGTEMPFD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGTEMPLATE_L', 'T_TSRBD_CFGMSGTEMPLATE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGTEMPLATE_L') CREATE INDEX IDX_TSRBD_CFGMSGTEMPLATE_L ON T_TSRBD_CFGMSGTEMPLATE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGUSELOG_L', 'T_TSRBD_CFGMSGUSELOG_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGMSGUSELOG_L') CREATE INDEX IDX_TSRBD_CFGMSGUSELOG_L ON T_TSRBD_CFGMSGUSELOG_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGPUSHSCENEFD', 'T_TSRBD_CFGPUSHSCENEFD', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGPUSHSCENEFD') CREATE INDEX IDX_TSRBD_CFGPUSHSCENEFD ON T_TSRBD_CFGPUSHSCENEFD ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGWHITELIST', 'T_TSRBD_CFGWHITELIST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGWHITELIST_FVALUE') CREATE INDEX IDX_TSRBD_CFGWHITELIST_FVALUE ON T_TSRBD_CFGWHITELIST ( FVALUE );


 EXEC P_ALTERPK 'PK_TSRBD_CFGWHITELIST_L', 'T_TSRBD_CFGWHITELIST_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CFGWHITELIST_L') CREATE INDEX IDX_TSRBD_CFGWHITELIST_L ON T_TSRBD_CFGWHITELIST_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGCHANNEL', 'T_TSRBD_MSGCHANNEL', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGCHANNEL_FID') CREATE INDEX IDX_TSRBD_MSGCHANNEL_FID ON T_TSRBD_MSGCHANNEL ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGCHANNELFD', 'T_TSRBD_MSGCHANNELFD', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGCHANNELFD_FID') CREATE INDEX IDX_TSRBD_MSGCHANNELFD_FID ON T_TSRBD_MSGCHANNELFD ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGINTVCAT', 'T_TSRBD_MSGINTVCAT', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGINTVCAT_FID') CREATE INDEX IDX_TSRBD_MSGINTVCAT_FID ON T_TSRBD_MSGINTVCAT ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGINTVMTHD', 'T_TSRBD_MSGINTVMTHD', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGINTVMTHD_FID') CREATE INDEX IDX_TSRBD_MSGINTVMTHD_FID ON T_TSRBD_MSGINTVMTHD ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGRECEFD', 'T_TSRBD_MSGRECEFD', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGRECEFD_FID') CREATE INDEX IDX_TSRBD_MSGRECEFD_FID ON T_TSRBD_MSGRECEFD ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_PUSHMSGSCENE', 'T_TSRBD_PUSHMSGSCENE', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PUSHMSGSCENE_FID') CREATE INDEX IDX_TSRBD_PUSHMSGSCENE_FID ON T_TSRBD_PUSHMSGSCENE ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_CFGMSGTEMPLATE', 'T_TSRBD_CFGMSGTEMPLATE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGTEMPLATE_FNUMBER') CREATE INDEX IDX_TSRBD_MSGTEMPLATE_FNUMBER ON T_TSRBD_CFGMSGTEMPLATE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MSGRECRUTYP', 'T_TSRBD_MSGRECRUTYP', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGRECRUTYP_FID') CREATE INDEX IDX_TSRBD_MSGRECRUTYP_FID ON T_TSRBD_MSGRECRUTYP ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_CHANNELACCOUNT', 'T_TSRBD_CHANNELACCOUNT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CHANNELACCOUNT_FNAME') CREATE INDEX IDX_TSRBD_CHANNELACCOUNT_FNAME ON T_TSRBD_CHANNELACCOUNT ( FNAME );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CHANNELACCOUNT_FNUM') CREATE INDEX IDX_TSRBD_CHANNELACCOUNT_FNUM ON T_TSRBD_CHANNELACCOUNT ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSCNMULTYP', 'T_TSRBD_RECRUSCNMULTYP', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSCNMULTYP') CREATE INDEX IDX_TSRBD_RECRUSCNMULTYP ON T_TSRBD_RECRUSCNMULTYP ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUCHNLNM', 'T_TSRBD_RECRUCHNLNM', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUCHNLNM_FNUM') CREATE INDEX IDX_TSRBD_RECRUCHNLNM_FNUM ON T_TSRBD_RECRUCHNLNM ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_MULTIRECRUTYP', 'T_TSRBD_MULTIRECRUTYP', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MULTIRECRUTYP_FID') CREATE INDEX IDX_TSRBD_MULTIRECRUTYP_FID ON T_TSRBD_MULTIRECRUTYP ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_COMMCON', 'T_TSRBD_COMMCON', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMCON_FNUMBER') CREATE INDEX IDX_TSRBD_COMMCON_FNUMBER ON T_TSRBD_COMMCON ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_COMMCON_L', 'T_TSRBD_COMMCON_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMCON_L') CREATE INDEX IDX_TSRBD_COMMCON_L ON T_TSRBD_COMMCON_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_COMMTHEME', 'T_TSRBD_COMMTHEME', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMTHEME_FNUMBER') CREATE INDEX IDX_TSRBD_COMMTHEME_FNUMBER ON T_TSRBD_COMMTHEME ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_CONOPTENTRY', 'T_TSRBD_CONOPTENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_CONOPTENTRY_FID') CREATE INDEX IDX_TSRBD_CONOPTENTRY_FID ON T_TSRBD_CONOPTENTRY ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_THEMERECRUTYPE', 'T_TSRBD_THEMERECRUTYPE', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_VISIBLEPERSONFID') CREATE INDEX IDX_TSRBD_VISIBLEPERSONFID ON T_TSRBD_THEMERECRUTYPE ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_THEMESTGTYP', 'T_TSRBD_THEMESTGTYP', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_THEMESTGTYP') CREATE INDEX IDX_TSRBD_THEMESTGTYP ON T_TSRBD_THEMESTGTYP ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_COMREPEATABLE', 'T_TSRBD_COMREPEATABLE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMTHEMEFNUMBER') CREATE INDEX IDX_TSRBD_COMMTHEMEFNUMBER ON T_TSRBD_COMREPEATABLE ( FTENANTID );


 EXEC P_ALTERPK 'PK_TSRBD_COMMTHEME_L', 'T_TSRBD_COMMTHEME_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMTHEME_L') CREATE INDEX IDX_TSRBD_COMMTHEME_L ON T_TSRBD_COMMTHEME_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_LANGUAGEVERSION', 'T_TSRBD_LANGUAGEVERSION', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LANGUAGEVERSION_FNUM') CREATE INDEX IDX_TSRBD_LANGUAGEVERSION_FNUM ON T_TSRBD_LANGUAGEVERSION ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_FIELD', 'T_TSRBD_FIELD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELD_FNUM') CREATE INDEX IDX_TSRBD_FIELD_FNUM ON T_TSRBD_FIELD ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_FIELD_L', 'T_TSRBD_FIELD_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELD_L') CREATE INDEX IDX_TSRBD_FIELD_L ON T_TSRBD_FIELD_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_FIELDCFGRESULT', 'T_TSRBD_FIELDCFGRESULT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDCFGRESULT_PRO') CREATE INDEX IDX_TSRBD_FIELDCFGRESULT_PRO ON T_TSRBD_FIELDCFGRESULT ( FRQMTPROCID ,FRECRUSTGID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FIELDCFGRESULT_TYP') CREATE INDEX IDX_TSRBD_FIELDCFGRESULT_TYP ON T_TSRBD_FIELDCFGRESULT ( FRECRUSTGTYPID );


 EXEC P_ALTERPK 'PK_TSRBD_MSGTRACK', 'T_TSRBD_MSGTRACK', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGTRACK_FRECNAME') CREATE INDEX IDX_TSRBD_MSGTRACK_FRECNAME ON T_TSRBD_MSGTRACK ( FRECNAME );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGTRACK_FRECEMAIL') CREATE INDEX IDX_TSRBD_MSGTRACK_FRECEMAIL ON T_TSRBD_MSGTRACK ( FRECEMAIL );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGTRACK_FSENDER') CREATE INDEX IDX_TSRBD_MSGTRACK_FSENDER ON T_TSRBD_MSGTRACK ( FSENDER );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGTRACK_FRECPHONE') CREATE INDEX IDX_TSRBD_MSGTRACK_FRECPHONE ON T_TSRBD_MSGTRACK ( FRECPHONE );


 EXEC P_ALTERPK 'PK_TSRBD_MSGTRACKOBJ', 'T_TSRBD_MSGTRACKOBJ', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGOBJ_FMSGID') CREATE INDEX IDX_TSRBD_MSGOBJ_FMSGID ON T_TSRBD_MSGTRACKOBJ ( FMSGTRACKID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGOBJ_FOPRECORDID') CREATE INDEX IDX_TSRBD_MSGOBJ_FOPRECORDID ON T_TSRBD_MSGTRACKOBJ ( FOPRECORDID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_MSGOBJ_FBIZOBJ') CREATE INDEX IDX_TSRBD_MSGOBJ_FBIZOBJ ON T_TSRBD_MSGTRACKOBJ ( FBIZOBJ );


 EXEC P_ALTERPK 'PK_TSRBD_OPERATE', 'T_TSRBD_OPERATE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_T_TSRBD_OPERATE_FNUM') CREATE INDEX IDX_T_TSRBD_OPERATE_FNUM ON T_TSRBD_OPERATE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_OPERATE_L', 'T_TSRBD_OPERATE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPERATE_L') CREATE INDEX IDX_TSRBD_OPERATE_L ON T_TSRBD_OPERATE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_OPERCFGRESULT', 'T_TSRBD_OPERCFGRESULT', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPERCFGRESULT_PRO') CREATE INDEX IDX_TSRBD_OPERCFGRESULT_PRO ON T_TSRBD_OPERCFGRESULT ( FRQMTPROCID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_OPERCFGRESULT_STG') CREATE INDEX IDX_TSRBD_OPERCFGRESULT_STG ON T_TSRBD_OPERCFGRESULT ( FRECRUSTGID );


 EXEC P_ALTERPK 'PK_TSRBD_PROCESSINST', 'T_TSRBD_PROCESSINST', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PROCESSINST_PRO') CREATE INDEX IDX_TSRBD_PROCESSINST_PRO ON T_TSRBD_PROCESSINST ( FRQMTPROCID );

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_PROCESSINST_BOID') CREATE INDEX IDX_TSRBD_PROCESSINST_BOID ON T_TSRBD_PROCESSINST ( FBOID );


 EXEC P_ALTERPK 'PK_TSRBD_RQMTPROC', 'T_TSRBD_RQMTPROC', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RQMTPROC_FNUM') CREATE INDEX IDX_TSRBD_RQMTPROC_FNUM ON T_TSRBD_RQMTPROC ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSCENE', 'T_TSRBD_RECRUSCENE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSCENE_FNUMBER') CREATE INDEX IDX_TSRBD_RECRUSCENE_FNUMBER ON T_TSRBD_RECRUSCENE ( FNUMBER );


 EXEC P_ALTERPK 'PK_TSRBD_RECRUSCENE_L', 'T_TSRBD_RECRUSCENE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_RECRUSCENE_L') CREATE INDEX IDX_TSRBD_RECRUSCENE_L ON T_TSRBD_RECRUSCENE_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_COMMTOPIC_L', 'T_TSRBD_COMMTOPIC_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMTOPIC_L') CREATE INDEX IDX_TSRBD_COMMTOPIC_L ON T_TSRBD_COMMTOPIC_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_COMMTOPIC', 'T_TSRBD_COMMTOPIC', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMTOPIC_FNUMBER') CREATE INDEX IDX_TSRBD_COMMTOPIC_FNUMBER ON T_TSRBD_COMMTOPIC ( FNUMBER );


 EXEC P_ALTERPK 'PK_T_TSRBD_INTVERFILE', 'T_TSRBD_INTVERFILE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_COMMRCV') CREATE INDEX IDX_TSRBD_COMMRCV ON T_TSRBD_INTVERFILE ( FUSERID );


 EXEC P_ALTERPK 'PK_T_TSRBD_INTVERFILEENTRY', 'T_TSRBD_INTVERFILEENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVERFILEENTRY_FID') CREATE INDEX IDX_TSRBD_INTVERFILEENTRY_FID ON T_TSRBD_INTVERFILEENTRY ( FID );


 EXEC P_ALTERPK 'PK_T_TSRBD_INTVERLEVEL', 'T_TSRBD_INTVERLEVEL', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVERLEVEL_FNUMBER') CREATE INDEX IDX_TSRBD_INTVERLEVEL_FNUMBER ON T_TSRBD_INTVERLEVEL ( FNUMBER );


 EXEC P_ALTERPK 'PK_T_TSRBD_INTVERTYPE', 'T_TSRBD_INTVERTYPE', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVERTYPE_FNUMBER') CREATE INDEX IDX_TSRBD_INTVERTYPE_FNUMBER ON T_TSRBD_INTVERTYPE ( FNUMBER );


 EXEC P_ALTERPK 'PK_T_TSRBD_JOBFAMENTRY', 'T_TSRBD_JOBFAMENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_JOBFAMENTRY_FID') CREATE INDEX IDX_TSRBD_JOBFAMENTRY_FID ON T_TSRBD_JOBFAMENTRY ( FID );


 EXEC P_ALTERPK 'PK_T_TSRBD_LVJOBCLENTRY', 'T_TSRBD_LVJOBCLENTRY', 'FENTRYID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_LVJOBCLENTRY_FID') CREATE INDEX IDX_TSRBD_LVJOBCLENTRY_FID ON T_TSRBD_LVJOBCLENTRY ( FID );


--  EXEC P_ALTERPK 'PK_T_TSRBD_TYJOBCLENTRY', 'T_TSRBD_TYJOBCLENTRY', 'FDETAILID', '1';
--
--  IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_TYJOBCLENTRY_FEID') CREATE INDEX IDX_TSRBD_TYJOBCLENTRY_FEID ON T_TSRBD_TYJOBCLENTRY ( FENTRYID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVERFILE_L', 'T_TSRBD_INTVERFILE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVERFILE_FID') CREATE INDEX IDX_TSRBD_INTVERFILE_FID ON T_TSRBD_INTVERFILE_L ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVERLEVEL_L', 'T_TSRBD_INTVERLEVEL_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_INTVL_FID') CREATE INDEX IDX_TSRBD_INTVL_FID ON T_TSRBD_INTVERLEVEL_L ( FID ,FLOCALEID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVERTYPE_L', 'T_TSRBD_INTVERTYPE_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_FID') CREATE INDEX IDX_TSRBD_FID ON T_TSRBD_INTVERTYPE_L ( FID );


 EXEC P_ALTERPK 'PK_TSRBD_INTVERFILEENTRY_L', 'T_TSRBD_INTVERFILEENTRY_L', 'FPKID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_TSRBD_ENTRY') CREATE INDEX IDX_TSRBD_ENTRY ON T_TSRBD_INTVERFILEENTRY_L ( FENTRYID ,FLOCALEID );

/**End D:\PDM_UPGRADE\PDM1\TSRBD_constraint.sql **/
