 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_AR_ACCPLANCARD_FENTRYID') CREATE INDEX IDX_AR_ACCPLANCARD_FENTRYID ON T_AR_ACCRUALPLANENTRY_L ( FENTRYID );

 -- 手工生成的索引 因为自动生成规则不允许索引第一个字段重复(应收单和预收单都有以forgid开头的索引)
 IF NOT EXISTS (SELECT 1 FROM KSQL_INDEXES WHERE KSQL_INDNAME = 'IDX_AR_RECE_ORGASST') CREATE INDEX IDX_AR_RECE_ORGASST ON T_AR_ReceivedBill ( FOrgID, FAsstactID );

