拼接sql ()
WORK.FQREALNAME||‘(‘||FQDEPT.FULLNAME||‘)‘ AS FQREALNAME,
NVL2(WORK.BHREALNAME,WORK.BHREALNAME||‘(‘||BHDEPT.FULLNAME||‘)‘,‘‘) AS BHREALNAME
FROM OA_WF_BHWORKFLOW WORK
LEFT OUTER JOIN (SELECT FULLNAME,USERID FROM SYS_USER USERNAME LEFT OUTER JOIN SYS_ORGANIZATION DEPT ON USERNAME.DEPARTMENTID=DEPT.ORGANIZATIONID )FQDEPT
ON FQDEPT.USERID=WORK.FQUSERNAME
LEFT OUTER JOIN (SELECT FULLNAME,USERID FROM SYS_USER USERNAME LEFT OUTER JOIN SYS_ORGANIZATION DEPT ON USERNAME.DEPARTMENTID=DEPT.ORGANIZATIONID )BHDEPT
ON BHDEPT.USERID=WORK.BHUSERNAME
WHERE
YJBOBJECTID=‘$YJBOBJECTID$‘
ORDER BY SEQUENCE DESC
郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。