Oracle ERP 各廠的線上人員與其開啟的 Responsibility

在 Oracle ERP 中, 可用下面語法得知 "各廠的線上人員與其開啟的 Responsibility" :
 程式碼
SELECT A.USER_ID
, A.USER_NAME
, FU.DESCRIPTION USER_DESC
, FR.RESPONSIBILITY_ID
, FR.RESPONSIBILITY_NAME
, COUNT(*) FORM_COUNT
FROM (SELECT RESPONSIBILITY_ID
, USER_ID
, USER_NAME
FROM FND_SIGNON_AUDIT_VIEW
) A
, ORG_ACCESS OA
, FND_RESPONSIBILITY_TL FR
, FND_USER FU
WHERE A.USER_ID = FU.USER_ID
AND A.RESPONSIBILITY_ID = OA.RESPONSIBILITY_ID(+)
AND A.RESPONSIBILITY_ID = FR.RESPONSIBILITY_ID(+)
AND OA.ORGANIZATION_ID = &ORGANIZATION_ID
GROUP BY A.USER_NAME, A.USER_ID, FU.DESCRIPTION, FR.RESPONSIBILITY_ID, FR.RESPONSIBILITY_NAME
ORDER BY A.USER_NAME, A.USER_ID, FU.DESCRIPTION, FR.RESPONSIBILITY_ID, FR.RESPONSIBILITY_NAME;
天聖經:神的心不僅在神的聖言當中,也在神所創造的萬物之中,天涯海角每一處都有神的心
Related Posts Plugin for WordPress, Blogger...