To calculate/compare the user license according to application/responsibility. –In Details which user using which responsibility.
SELECT fu.employee_id,
fu.user_name,
application_name,
t.responsibility_name,
wur.START_DATE responsibility_start_date,
wur.EXPIRATION_DATE responsibility_end_date
FROM fnd_responsibility_tl t,
fnd_responsibility b,
fnd_application_tl fn,
fnd_user fu,
wf_all_user_roles wur,
per_all_assignments_f asg
WHERE b.responsibility_id = t.responsibility_id
AND asg.person_id = fu.employee_id
AND b.application_id = t.application_id
AND b.application_id = fn.application_id
AND t.LANGUAGE = 'US'
--AND fu.end_date IS NULL
--AND wur.expiration_date IS NULL
AND fn.LANGUAGE = 'US'
AND b.end_date IS NULL
AND fu.user_name = wur.user_name
AND wur.role_orig_system_id = t.responsibility_id
AND wur.role_orig_system = 'FND_RESP'
AND sysdate between wur.START_DATE and NVL (wur.expiration_date, SYSDATE )
-- AND fu.user_name='4445'
-- AND application_name='Human Resources'
and sysdate between fu.START_DATE and nvl(fu.end_date,sysdate)
Sample output:
EMPLOYEE_ID USER_NAME APPLICATION_NAME RESPONSIBILITY_NAME RESPONSIBILITY_START_DATE RESPONSIBILITY_END_DATE
20804 4724 Human Resources Employee Self-Service 12/25/2013
20804 4724 Human Resources Employee Self-Service 12/25/2013
20804 4724 Oracle iProcurement AME Application Administrator 6/1/2014
20804 4724 Oracle iProcurement AME Application Administrator 6/1/2014
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20696 4462 Enterprise Asset Management Enterprise Asset Management 8/3/2015
More Precise (which user using one application how many licenses
fu.user_name,
application_name,
t.responsibility_name,
wur.START_DATE responsibility_start_date,
wur.EXPIRATION_DATE responsibility_end_date
FROM fnd_responsibility_tl t,
fnd_responsibility b,
fnd_application_tl fn,
fnd_user fu,
wf_all_user_roles wur,
per_all_assignments_f asg
WHERE b.responsibility_id = t.responsibility_id
AND asg.person_id = fu.employee_id
AND b.application_id = t.application_id
AND b.application_id = fn.application_id
AND t.LANGUAGE = 'US'
--AND fu.end_date IS NULL
--AND wur.expiration_date IS NULL
AND fn.LANGUAGE = 'US'
AND b.end_date IS NULL
AND fu.user_name = wur.user_name
AND wur.role_orig_system_id = t.responsibility_id
AND wur.role_orig_system = 'FND_RESP'
AND sysdate between wur.START_DATE and NVL (wur.expiration_date, SYSDATE )
-- AND fu.user_name='4445'
-- AND application_name='Human Resources'
and sysdate between fu.START_DATE and nvl(fu.end_date,sysdate)
Sample output:
EMPLOYEE_ID USER_NAME APPLICATION_NAME RESPONSIBILITY_NAME RESPONSIBILITY_START_DATE RESPONSIBILITY_END_DATE
20804 4724 Human Resources Employee Self-Service 12/25/2013
20804 4724 Human Resources Employee Self-Service 12/25/2013
20804 4724 Oracle iProcurement AME Application Administrator 6/1/2014
20804 4724 Oracle iProcurement AME Application Administrator 6/1/2014
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20735 4555 Advanced Product Catalog Project Engineer 12/10/2013
20696 4462 Enterprise Asset Management Enterprise Asset Management 8/3/2015
More Precise (which user using one application how many licenses
SELECT fu.user_name,
application_name,
count(application_name)
FROM fnd_responsibility_tl t,
fnd_responsibility b,
fnd_application_tl fn,
fnd_user fu,
wf_all_user_roles wur,
per_all_assignments_f asg
WHERE b.responsibility_id = t.responsibility_id
AND asg.person_id = fu.employee_id
AND b.application_id = t.application_id
AND b.application_id = fn.application_id
AND t.LANGUAGE = 'US'
--AND fu.end_date IS NULL
--AND wur.expiration_date IS NULL
AND fn.LANGUAGE = 'US'
AND b.end_date IS NULL
AND fu.user_name = wur.user_name
AND wur.role_orig_system_id = t.responsibility_id
AND wur.role_orig_system = 'FND_RESP'
AND sysdate between wur.START_DATE and NVL (wur.expiration_date, SYSDATE )
and sysdate between fu.START_DATE and nvl(fu.end_date,sysdate)
group by application_name, fu.user_name
Sample output:
USER_NAME APPLICATION_NAME COUNT(APPLICATION_NAME)
4445 Human Resources 4
4490 Purchasing 4
4632 Human Resources 3
4632 Purchasing 3
4502 Human Resources 4
More Precise (per application How many users) as comes in oracle Invoice.
application_name,
count(application_name)
FROM fnd_responsibility_tl t,
fnd_responsibility b,
fnd_application_tl fn,
fnd_user fu,
wf_all_user_roles wur,
per_all_assignments_f asg
WHERE b.responsibility_id = t.responsibility_id
AND asg.person_id = fu.employee_id
AND b.application_id = t.application_id
AND b.application_id = fn.application_id
AND t.LANGUAGE = 'US'
--AND fu.end_date IS NULL
--AND wur.expiration_date IS NULL
AND fn.LANGUAGE = 'US'
AND b.end_date IS NULL
AND fu.user_name = wur.user_name
AND wur.role_orig_system_id = t.responsibility_id
AND wur.role_orig_system = 'FND_RESP'
AND sysdate between wur.START_DATE and NVL (wur.expiration_date, SYSDATE )
and sysdate between fu.START_DATE and nvl(fu.end_date,sysdate)
group by application_name, fu.user_name
Sample output:
USER_NAME APPLICATION_NAME COUNT(APPLICATION_NAME)
4445 Human Resources 4
4490 Purchasing 4
4632 Human Resources 3
4632 Purchasing 3
4502 Human Resources 4
More Precise (per application How many users) as comes in oracle Invoice.
select application_name, count(user_name)
from
(SELECT fu.user_name,
application_name,
count(application_name)
FROM fnd_responsibility_tl t,
fnd_responsibility b,
fnd_application_tl fn,
fnd_user fu,
wf_all_user_roles wur,
per_all_assignments_f asg
WHERE b.responsibility_id = t.responsibility_id
AND asg.person_id = fu.employee_id
AND b.application_id = t.application_id
AND b.application_id = fn.application_id
AND t.LANGUAGE = 'US'
--AND fu.end_date IS NULL
--AND wur.expiration_date IS NULL
AND fn.LANGUAGE = 'US'
AND b.end_date IS NULL
AND fu.user_name = wur.user_name
AND wur.role_orig_system_id = t.responsibility_id
AND wur.role_orig_system = 'FND_RESP'
AND sysdate between wur.START_DATE and NVL (wur.expiration_date, SYSDATE )
and sysdate between fu.START_DATE and nvl(fu.end_date,sysdate)
group by application_name, fu.user_name)
group by application_name;
Sample Output:
Application Name Count(Users)
General Ledger 33
Receivables 21
Order Management 14
Advanced Supply Chain Planning 3
Process Manufacturing Product Development 4
Sourcing 44
Assets 8
Process Manufacturing Financials 6
Application Object Library 17
YES Custom 162
Marketing 15
XML Publisher 4
System Administration 11
Process Manufacturing Process Execution 86
Cash Management 21
Time and Labor Engine 13
Advanced Product Catalog 1
Alert 4
Oracle iProcurement 1
Enterprise Asset Management 204
Inventory 135
Oracle Landed Cost Management 16
Human Resources 1196
Purchasing 386
Treasury 11
Property Manager 8
Cost Management 3
Quality 5
Advanced Pricing 8
Bills of Material 1
Payables 25
from
(SELECT fu.user_name,
application_name,
count(application_name)
FROM fnd_responsibility_tl t,
fnd_responsibility b,
fnd_application_tl fn,
fnd_user fu,
wf_all_user_roles wur,
per_all_assignments_f asg
WHERE b.responsibility_id = t.responsibility_id
AND asg.person_id = fu.employee_id
AND b.application_id = t.application_id
AND b.application_id = fn.application_id
AND t.LANGUAGE = 'US'
--AND fu.end_date IS NULL
--AND wur.expiration_date IS NULL
AND fn.LANGUAGE = 'US'
AND b.end_date IS NULL
AND fu.user_name = wur.user_name
AND wur.role_orig_system_id = t.responsibility_id
AND wur.role_orig_system = 'FND_RESP'
AND sysdate between wur.START_DATE and NVL (wur.expiration_date, SYSDATE )
and sysdate between fu.START_DATE and nvl(fu.end_date,sysdate)
group by application_name, fu.user_name)
group by application_name;
Sample Output:
Application Name Count(Users)
General Ledger 33
Receivables 21
Order Management 14
Advanced Supply Chain Planning 3
Process Manufacturing Product Development 4
Sourcing 44
Assets 8
Process Manufacturing Financials 6
Application Object Library 17
YES Custom 162
Marketing 15
XML Publisher 4
System Administration 11
Process Manufacturing Process Execution 86
Cash Management 21
Time and Labor Engine 13
Advanced Product Catalog 1
Alert 4
Oracle iProcurement 1
Enterprise Asset Management 204
Inventory 135
Oracle Landed Cost Management 16
Human Resources 1196
Purchasing 386
Treasury 11
Property Manager 8
Cost Management 3
Quality 5
Advanced Pricing 8
Bills of Material 1
Payables 25
Hope this helps..