EXEC P_ALTERPK 'PK_FMM_WORKTYPEMSG', 'T_FMM_WORKTYPEMSG', 'FENTRYID', '1';
 
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_WORKTYPEMSG_FBAS') CREATE INDEX IDX_FMM_WORKTYPEMSG_FBAS ON T_FMM_WORKTYPEMSG (FID,FSEQ);


EXEC P_ALTERPK 'PK_FMM_WKGPPERSONMSG', 'T_FMM_WKGPPERSONMSG', 'FENTRYID', '1';
 
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_WKGPPERSONMSG_FBAS') CREATE INDEX IDX_FMM_WKGPPERSONMSG_FBAS ON T_FMM_WKGPPERSONMSG (FID,FSEQ);


EXEC P_ALTERPK 'PK_FMM_WKGRESPONSIBLE', 'T_FMM_WKGRESPONSIBLE', 'FPKID', '1';
 
IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_FMM_WKGRESPONSIBLE_FBAS') CREATE INDEX IDX_FMM_WKGRESPONSIBLE_FBAS ON T_FMM_WKGRESPONSIBLE (FENTRYID,FBASEDATAID);