获取单据当前工作流状态原创
1人赞赏了该文章
79次浏览
编辑于2024年08月12日 10:47:04
SELECT
assign.FRECEIVERNAMES 处理人
,assign_l.FASSIGNNAME 节点
,approval.FASSIGNID
,approval.FOBJECTTYPEID 单据id
,approval.FKEYVALUE 单据id
FROM (
select FASSIGNID, FOBJECTTYPEID, FKEYVALUE from (
select ROW_NUMBER() over(partition by FOBJECTTYPEId, FKEYVALUE order by fdealtime desc) RowNum ,T_WF_APPROVALASSIGN.* from T_WF_APPROVALASSIGN ) as t1
where RowNum = 1
) approval
left join T_WF_ASSIGN assign on approval.FASSIGNID = assign.FASSIGNID
left join T_WF_ASSIGN_L assign_l on assign.FASSIGNID = assign_l.FASSIGNID and FLOCALEID = 2052
where assign.FSTATUS = 0
--and approval.FKEYVALUE= '124388'
赞 1
1人点赞
还没有人点赞,快来当第一个点赞的人吧!
打赏
0人打赏
还没有人打赏,快来当第一个打赏的人吧!