 --根据来源单据信息更新合同信息
--【合同实体】=“来源单据实体”；【合同编号】=来源单据编号；【合同ID】=“来源单据ID”；【合同行ID】=“来源单据行ID” 【合同分录序号】="来源单据行序号“
UPDATE t_sm_salorderentry_r SET fconbillnumber = fsrcbillnumber WHERE (fsrcbillentity='conm_salcontract' AND (fconbillnumber=' ' OR (fconbillnumber IS NULL)));

UPDATE t_sm_salorderentry_r SET fconbillentity = fsrcbillentity WHERE (fsrcbillentity='conm_salcontract' AND (fconbillentity=' ' OR (fconbillentity IS NULL)));

UPDATE t_sm_salorderentry_r SET fconbillentryid = fsrcbillentryid WHERE (fsrcbillentity='conm_salcontract' AND (fconbillentryid= 0 OR (fconbillentryid IS NULL)));

UPDATE t_sm_salorderentry_r SET fconbillid = fsrcbillid WHERE (fsrcbillentity='conm_salcontract' AND (fconbillid= 0 OR (fconbillid IS NULL)));

UPDATE t_sm_salorderentry_r SET fconbillentryseq = fsrcbillentryseq WHERE (fsrcbillentity='conm_salcontract' AND (fconbillentryseq= 0 OR (fconbillentryseq IS NULL)));