The following lines contain the word 'select', 'insert', 'update' or 'delete':
select p.trx_credit_limit
from hz_cust_accounts a,
hz_cust_profile_amts p
where a.account_number = ci_accountnumber and
a.status = 'A' and
p.currency_code = ci_currency_code and
p.site_use_id is null and
a.cust_account_id = p.cust_account_id;
select p.overall_credit_limit,a.party_id
from hz_cust_accounts a,
hz_cust_profile_amts p
where a.account_number = ci_accountnumber and
a.status = 'A' and
p.currency_code = ci_currency_code and
p.site_use_id is null and
a.cust_account_id = p.cust_account_id;
select party_id
from hz_cust_accounts
where account_number = ci_accountnumber;
select nvl(sum(amount_due_remaining),0)
from ar_payment_schedules_all
where customer_id = ci_customer_id and
class in ('DM','INV') and
status = 'OP';
select nvl(sum(amount_due_remaining),0)
from ar_payment_schedules_all
where customer_id = ci_customer_id and
class in ('CM') and
status = 'OP';
select nvl(sum(decode(app.status,'ACC',(-1*app.amount_applied_from),0)),0)
from ar_receivable_applications_all app,
ar_payment_schedules_all ps,
gl_code_combinations cc
where ps.customer_id = ci_customer_id and
ps.cash_receipt_id = app.cash_receipt_id and
nvl(app.confirmed_flag ,'Y') = 'Y' and
app.status in ('ACC') and
app.code_combination_id = cc.code_combination_id;
select nvl(sum(decode(app.status,'UNAPP',(-1*app.amount_applied_from),0)),0)
from ar_receivable_applications_all app,
ar_payment_schedules_all ps,
gl_code_combinations cc
where ps.customer_id = ci_customer_id and
ps.cash_receipt_id = app.cash_receipt_id and
nvl(app.confirmed_flag,'Y') = 'Y' and
app.status IN ('UNAPP') and
app.code_combination_id = cc.code_combination_id;
select p.credit_rating
from hz_cust_accounts a,
hz_customer_profiles p
where a.account_number = ci_accountnumber and
p.status = 'A' and
a.status = 'A' and
p.site_use_id is null and
a.cust_account_id = p.cust_account_id;
select m.value
from iby_mappings m
where m.mapping_code = ci_creditratingcode and
m.mapping_type = 'CREDIT_CODE_TYPE' and
((payeeid is null and ci_payeeid is null) or (m.payeeid = ci_payeeid));
select count(1) into l_cnt
from iby_mappings
where mapping_type = 'CREDIT_CODE_TYPE'
and payeeid = i_payeeid;
select p.risk_code
from hz_cust_accounts a,
hz_customer_profiles p
where a.account_number = ci_accountnumber and
p.status = 'A' and
a.status = 'A' and
p.site_use_id is null and
a.cust_account_id = p.cust_account_id;
select m.value
from iby_mappings m
where m.mapping_code = ci_riskcode and
m.mapping_type = 'RISK_CODE_TYPE' and
((m.payeeid is null and ci_payeeid is null) or (m.payeeid = ci_payeeid));
select count(1) into l_cnt
from iby_mappings
where mapping_type = 'RISK_CODE_TYPE'
and payeeid = i_payeeid;