
 EXEC P_ALTERPK 'PK_MDS_SITERECORD', 'T_MDS_SITERECORD', 'FID', '1';

 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_MDS_SITERECORD_NO') CREATE INDEX IDX_MDS_SITERECORD_NO ON T_MDS_SITERECORD ( FSITESCHEMEID );
 
 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_MDS_SITERECORD_MATNO') CREATE INDEX IDX_MDS_SITERECORD_MATNO ON T_MDS_SITERECORD ( FMATERIALID );



