0% found this document useful (0 votes)
103 views

Audit Query Queries

This document contains several SQL queries that are selecting data from different tables in Oracle Applications related to compensation details, currency conversion rates, fixed asset categories, and bank accounts. The queries filter on date ranges and join various tables to retrieve employee, organizational, and accounting dimension data.

Uploaded by

Priya Nimmagadda
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
103 views

Audit Query Queries

This document contains several SQL queries that are selecting data from different tables in Oracle Applications related to compensation details, currency conversion rates, fixed asset categories, and bank accounts. The queries filter on date ranges and join various tables to retrieve employee, organizational, and accounting dimension data.

Uploaded by

Priya Nimmagadda
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 3

select * from all_tables where table_name like 'PA%RATE%OVER%'

SELECT pcda.compensation_rule_set,
pcda.start_date_active,
pcda.end_date_active,
pcda.hourly_cost_rate,
pcda.cost_rate_currency_code,
hou.name,
fu.user_name created_by,
fu1.user_name last_updated_by,
pap.full_name,
pap.employee_number,
pap.person_id
--pcda.org_id*
FROM apps.PA_COMPENSATION_DETAILS_ALL pcda,
apps.per_all_people_f pap,
apps.fnd_user fu,
apps.hr_operating_units hou,
apps.fnd_user fu1
WHERE 1 = 1
AND pap.person_id = pcda.person_id
AND pcda.org_id = hou.organization_id
AND pcda.created_by = fu.user_id
AND pcda.last_updated_by = fu1.user_id
AND TRUNC (SYSDATE) BETWEEN TRUNC (effective_start_date)
AND TRUNC (effective_end_Date)
AND TRUNC (pcda.start_date_active) >=
TO_DATE ('01-NOV-2018', 'DD-MON-YYYY')
AND (TRUNC (pcda.end_date_active) <=
TO_DATE ('30-APR-2019', 'DD-MON-YYYY') or pcda.end_date_active is
null)
--AND TRUNC (pap.effective_start_date) >= TO_DATE ('01-NOV-2018', 'DD-MON-YYYY')
--AND TRUNC (pap.effective_end_date) <= TO_DATE ('30-APR-2019', 'DD-MON-YYYY')
--and pcda.person_id=532476;

select * from apps.per_all_people_f where person_id=468044--

select * from apps.PA_COMPENSATION_DETAILS_ALL where person_id=468044

select * from apps.hr_operating_units

--PA_EMP_BILL_RATE_OVERRIDES_EFC--PA_BILL_RATES_ALL

========================================

select
a.from_currency,a.to_currency,a.conversion_Date,a.conversion_type,a.conversion_rate
,a.creation_date,a.status_code,a.created_by,a.last_updated_by,
b.user_name created_by, fu2.last_updated_by
from apps.gl_daily_rates a,apps.fnd_user b,apps.fnd_user fu2
where 1=1
AND TRUNC (a.conversion_Date) >= TO_DATE ('01-NOV-2018', 'DD-MON-YYYY')
AND TRUNC (a.conversion_Date) <= TO_DATE ('30-APR-2019', 'DD-MON-YYYY')
and b.user_id=a.created_by
and fu2.user_id=b.last_updated_by;

==================================================

select
b.segment1,b.segment2,a.creation_Date,b.description,b.capitalize_flag,b.inventorial
,b.category_id,b.summary_flag,b.enabled_flag,b.owned_leased,b.category_type,b.capit
alize_flag,b.segment1,b.segment2,b.inventorial,
a.book_type_code,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.asset_cost_account_ccid) asset_cost_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.asset_clearing_account_ccid) asset_clearing,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.WIP_cost_account_ccid) WIP_cost_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.WIP_clearing_account_ccid) WIP_clearing_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.reserve_account_ccid) reserve_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.reval_amort_account_ccid) reval_amort_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.reval_reserve_account_ccid) reval_reserve_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.bonus_reserve_acct_ccid) bonus_reserve_acct,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.unplan_expense_account_ccid) unplan_expense_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.deprn_expense_account_ccid) deprn_expense_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.bonus_expense_account_ccid) bonus_expense_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.alt_cost_account_ccid) alt_cost_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.write_off_account_ccid) write_off_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.impair_expense_account_ccid) impair_expense_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.capital_adj_account_ccid) capital_adj_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.general_fund_account_ccid) general_fund_account,
(select concatenated_segments from apps.gl_code_combinations_kfv c where
c.code_combination_id = a.reval_loss_account_ccid) reval_loss_account
from
apps.FA_CATEGORY_BOOKS a,
apps.FA_CATEGORIES_VL b
where 1=1
--and a.book_type_code Like '%SY%'
and a.category_id = b.category_id
--and a.category_id=10628
AND TRUNC (a.creation_Date) >= TO_DATE ('01-NOV-2018', 'DD-MON-YYYY')
AND TRUNC (a.creation_Date) <= TO_DATE ('30-APR-2019', 'DD-MON-YYYY')

===================================================================================
===============

select bank_account_id,bank_account_name,
fu.user_name created_by,fu1.user_name last_updated_by,
cba.bank_account_num,cba.currency_code,
hou.name,cba.account_owner_org_id,
cba.account_classification,
cba.ap_use_allowed_flag,ar_use_allowed_flag,cba.pay_use_allowed_flag,cba.multi_curr
ency_allowed_flag,cba.payment_multi_currency_flag,cba.zero_amount_allowed,cba.creat
ion_date,
--cba.last_updated_date,
cba.start_date,cba.end_Date,
(select concatenated_segments from apps.gl_code_combinations_kfv gcck where
gcck.code_combination_id = cba.Asset_code_combination_id) Asset_Code_account,
(select concatenated_segments from apps.gl_code_combinations_kfv gcck where
gcck.code_combination_id = cba.cash_clearing_ccid) cash_clearing_account,
(select concatenated_segments from apps.gl_code_combinations_kfv gcck where
gcck.code_combination_id = cba.bank_charges_ccid) bank_charges_account,
(select concatenated_segments from apps.gl_code_combinations_kfv gcck where
gcck.code_combination_id = cba.bank_errors_ccid) bank_errors_account,
(select concatenated_segments from apps.gl_code_combinations_kfv gcck where
gcck.code_combination_id = cba.gain_code_combination_id) gain_account,
(select concatenated_segments from apps.gl_code_combinations_kfv gcck where
gcck.code_combination_id = cba.Loss_code_combination_id) Loss_account
from apps.ce_bank_accounts cba,apps.gl_code_combinations_kfv gcck,apps.fnd_user
fu,apps.fnd_user fu1
,apps.hr_operating_units hou
where 1=1
AND TRUNC (cba.creation_Date) >= TO_DATE ('01-NOV-2018', 'DD-MON-YYYY')
AND TRUNC (cba.creation_Date) <= TO_DATE ('30-APR-2019', 'DD-MON-YYYY')
AND cba.created_by = fu.user_id
AND cba.last_updated_by = fu1.user_id
and cba.account_owner_org_id=hou.organization_id(+)
-- and bank_account_name in ('EO 19200 NOK 60050776851')--,'GO 19830 EUR
166030-1137036','SY 19203 NOK 60050777114','SY 19203 NOK 60050777114')
and cba.Asset_code_combination_id=gcck.code_combination_id (+)
order by bank_account_id desc

==============================================================================

You might also like