/*业务分类 添加关联单据表 约束*/
EXEC P_ALTERPK 'PK_T_ER_PROJECTTYPE_RELBILL', 'T_ER_PROJECTTYPE_RELBILL', 'FPKID', '1';

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