销售出库单与应收单关联明细行更新数据
学习记录:
update t4 set t4.FCOMMENT=t2.FNOTE from T_SAL_OUTSTOCK t1 inner join T_SAL_OUTSTOCKENTRY t2 on t1.FID=t2.FID
inner join T_AR_RECEIVABLEENTRY_LK t3 on t3.FSID=t2.FENTRYID and t1.FID=t3.FSBILLID and t3.FSTABLENAME='T_SAL_OUTSTOCKENTRY'
inner join t_AR_receivableEntry t4 on t4.FENTRYID=t3.FENTRYID
where t4.FCOMMENT=''
/*更新应收单上的空备注*/
update t4 set t4.F_TTQI_TEXT3=t2.F_TTQI_TEXT from T_SAL_OUTSTOCK t1 inner join T_SAL_OUTSTOCKENTRY t2 on t1.FID=t2.FID
inner join T_AR_RECEIVABLEENTRY_LK t3 on t3.FSID=t2.FENTRYID and t1.FID=t3.FSBILLID and t3.FSTABLENAME='T_SAL_OUTSTOCKENTRY'
inner join t_AR_receivableEntry t4 on t4.FENTRYID=t3.FENTRYID
where t4.F_TTQI_TEXT3=''
/*更新应收单上的空电商订单号
这里重点是"T_AR_RECEIVABLEENTRY_LK "应收单关联明细表,主要通过他将应收明细行与销售出库明细行关联起来。
字段解析:
FSBILLID //源单表头主键
FSID //源单表体主键
FENTRYID //应收单表体主键
FSTABLENAME
销售出库单与应收单关联明细行更新数据
本文2024-09-16 17:38:51发表“云星空知识”栏目。
本文链接:https://wenku.my7c.com/article/kingdee-k3cloud-17036.html