EXEC P_ALTERPK 'PK_FMM_PCSETTING', 'T_FMM_PCSETTING', 'FID', '1';
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_PCSENG_FNUMBER') CREATE INDEX IDX_FMM_PCSENG_FNUMBER ON T_FMM_PCSETTING( FNUMBER );
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_PCSENG_FCREATETIME') CREATE INDEX IDX_FMM_PCSENG_FCREATETIME ON T_FMM_PCSETTING( FCREATETIME );


EXEC P_ALTERPK 'PK_FMM_PCSETTING_L', 'T_FMM_PCSETTING_L', 'FPKID', '1';
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_PCSENGL_FID') CREATE INDEX IDX_FMM_PCSENGL_FID ON T_FMM_PCSETTING_L( FID,FLOCALEID );
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_PCSENGL_FNAME') CREATE INDEX IDX_FMM_PCSENGL_FNAME ON T_FMM_PCSETTING_L( FNAME );


EXEC P_ALTERPK 'PK_FMM_PCSETTING_ENTRY', 'T_FMM_PCSETTING_ENTRY', 'FENTRYID', '1';
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_PCSENG_FID') CREATE INDEX IDX_FMM_PCSENG_FID ON T_FMM_PCSETTING_ENTRY( FID,FSEQ );