SELECT DISTINCT fat.application_name application_name
,fu.user_name user_name
,CASE
WHEN NVL (fu.end_date, SYSDATE + 1) > SYSDATE
THEN 'ACTIVE'
ELSE 'INACTIVE'
END user_status
,frt.responsibility_name
,furgd.start_date responsibility_start_date
,furgd.end_date responsibility_end_date
,fu.last_logon_date
,fu.end_date user_end_date
,fr.end_date
FROM apps.fnd_user_resp_groups_direct furgd
,apps.fnd_user fu
,apps.fnd_responsibility_tl frt
,apps.fnd_responsibility fr
,apps.fnd_application_tl fat
,apps.fnd_application fa
WHERE furgd.user_id = fu.user_id
AND furgd.responsibility_id = frt.responsibility_id
AND fr.responsibility_id = frt.responsibility_id
AND fa.application_id = fat.application_id
AND fr.application_id = fat.application_id
AND frt.responsibility_name LIKE 'XX%'
AND frt.LANGUAGE = USERENV ('LANG')
AND fat.LANGUAGE = USERENV ('LANG')
AND NVL(furgd.end_date, SYSDATE)>=SYSDATE
AND NVL(fu.end_date, SYSDATE)>=SYSDATE
AND NVL(fr.end_date, SYSDATE)>=SYSDATE
ORDER BY fu.user_name, furgd.end_date
Thanks for sharing.
ReplyDeleteKeep posting. Thanks for sharing.
ReplyDelete