 EXEC P_ALTERPK 'PK_T_LIC_ASSIGNLOGSETTING', 'T_LIC_ASSIGNLOGSETTING', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IX_LIC_ASSIGNLOGSET_RETAINDAY') CREATE INDEX IX_LIC_ASSIGNLOGSET_RETAINDAY ON T_LIC_ASSIGNLOGSETTING ( FRETAINDAYS );