The following lines contain the word 'select', 'insert', 'update' or 'delete':
SELECT meaning
INTO l_meaning
FROM ar_lookups
WHERE lookup_type = p_lookup_type
AND lookup_code = p_lookup_code ;
select financial_number into v_financial_number from hz_financial_numbers
where financial_report_id = p_financial_report_id
and financial_number_name = p_financial_name;
select financial_number_currency into v_financial_number_currency from hz_financial_numbers
where financial_report_id = p_financial_report_id
and financial_number_name = p_financial_name;
select projected_actual_flag into v_financial_number_actflg from hz_financial_numbers
where financial_report_id = p_financial_report_id
and financial_number_name = p_financial_name;
SELECT cp.raw_phone_number
FROM HZ_CONTACT_POINTS cp
WHERE cp.owner_table_id = p_party_id
AND cp.owner_table_name = 'HZ_PARTIES'
AND cp.actual_content_source = p_source_type
AND cp.CONTACT_POINT_TYPE = 'PHONE'
AND cp.status = 'A'
AND cp.primary_flag = 'Y'
AND cp.phone_line_type <> 'FAX';
SELECT cp.raw_phone_number
FROM HZ_CONTACT_POINTS cp
WHERE cp.owner_table_id = p_party_id
AND cp.owner_table_name = 'HZ_PARTIES'
AND cp.actual_content_source = p_source_type
AND cp.CONTACT_POINT_TYPE = 'PHONE'
AND cp.status = 'A'
AND cp.phone_line_type <> 'FAX';
SELECT cp.raw_phone_number
FROM HZ_CONTACT_POINTS cp
WHERE cp.owner_table_id = p_party_id
AND cp.owner_table_name = 'HZ_PARTIES'
AND cp.actual_content_source = p_source_type
AND cp.CONTACT_POINT_TYPE = 'PHONE'
AND cp.status = 'A'
AND cp.primary_flag = 'Y'
AND cp.phone_line_type = 'FAX';
SELECT cp.raw_phone_number
FROM HZ_CONTACT_POINTS cp
WHERE cp.owner_table_id = p_party_id
AND cp.owner_table_name = 'HZ_PARTIES'
AND cp.actual_content_source = p_source_type
AND cp.CONTACT_POINT_TYPE = 'PHONE'
AND cp.status = 'A'
AND cp.phone_line_type = 'FAX';
SELECT cp.raw_phone_number
FROM HZ_CONTACT_POINTS cp
WHERE cp.owner_table_id = p_party_id
AND cp.owner_table_name = 'HZ_PARTIES'
AND cp.actual_content_source = p_source_type
AND cp.status = 'A'
AND cp.CONTACT_POINT_TYPE = 'PHONE'
AND cp.phone_line_type='GEN';
| 10-18-2000 Chirag Mehta Changed select clause
+======================================================================*/
function get_country_name(p_country_code IN VARCHAR2) RETURN VARCHAR2 IS
country_name fnd_territories_vl.TERRITORY_SHORT_NAME%TYPE;
select TERRITORY_SHORT_NAME into country_name from fnd_territories_vl
where TERRITORY_CODE=p_country_code;
SELECT MAX(date_report_issued)
INTO l_date_report_issued
FROM hz_financial_reports
WHERE party_id = p_party_id
AND type_of_financial_report = p_type_of_financial_report
AND actual_content_source = p_actual_content_source;
SELECT MAX(report_end_date)
INTO l_report_end_date
FROM hz_financial_reports
WHERE party_id = p_party_id
AND type_of_financial_report = p_type_of_financial_report
AND actual_content_source = p_actual_content_source;
SELECT MAX(creation_date)
INTO l_creation_date
FROM hz_financial_reports
WHERE party_id = p_party_id
AND type_of_financial_report = p_type_of_financial_report
AND actual_content_source = p_actual_content_source;
SELECT financial_report_id
INTO l_financial_report_id
FROM hz_financial_reports
WHERE party_id = p_party_id
AND type_of_financial_report = p_type_of_financial_report
AND actual_content_source = p_actual_content_source
-- Bug 3395969 : Change the conditino to creation_date
AND creation_date = l_creation_date
AND rownum=1;
SELECT MAX(rated_as_of_date)
INTO l_max_rated_as_of_date
FROM hz_credit_ratings
WHERE party_id = p_party_id
AND actual_content_source = p_actual_content_source;
SELECT credit_rating_id
INTO l_credit_rating_id
FROM hz_credit_ratings
WHERE party_id = p_party_id
AND actual_content_source = p_actual_content_source
AND NVL(rated_as_of_date, TO_DATE('31-12-4712', 'DD-MM-YYYY'))=
NVL(l_max_rated_as_of_date, TO_DATE('31-12-4712', 'DD-MM-YYYY'))
AND rownum = 1;
select symbol into l_symbol
from fnd_currencies
where currency_code = l_financial_number_currency
AND rownum = 1;
select
DECODE( HZ_DNBUI_PVT.GET_FINANCIAL_NUMBER(p_financial_name, p_financial_report_id),
null, null,
nvl(HZ_DNBUI_PVT.get_financial_number_currency(p_financial_name, p_financial_report_id), 'USD') || ' ' ||
HZ_DNBUI_PVT.GET_FINANCIAL_NUMBER(p_financial_name, p_financial_report_id))
into l_financial_symbol_number
from dual;
select CLASS_CODE
from HZ_CODE_ASSIGNMENTS
where OWNER_TABLE_NAME = 'HZ_PARTIES' AND
OWNER_TABLE_ID = p_party_id AND
CLASS_CATEGORY = p_class_category AND
actual_content_source = p_actual_content_source AND --Bug 9071339
(END_DATE_ACTIVE IS NULL OR
(END_DATE_ACTIVE IS not NULL and END_DATE_ACTIVE >= SYSDATE))
order by code_assignment_id;
select displayed_duns_party_id into l_displayed_duns_party_id
from hz_organization_profiles
where party_id = p_party_id and
effective_end_date is null
and actual_content_source = 'DNB';
select loc.location_id
into l_location_id
from HZ_LOCATIONS loc, HZ_PARTY_SITES ps
where
ps.party_id = l_displayed_duns_party_id AND
loc.location_id = ps.location_id AND
loc.actual_content_source = p_actual_content_source AND
ps.actual_content_source = p_actual_content_source AND
nvl(ps.end_date_active, sysdate+1) >= sysdate AND
ps.status = 'A' AND
rownum=1;
select loc.location_id
into l_location_id
from HZ_LOCATIONS loc, HZ_PARTY_SITES ps
where
ps.party_id = p_party_id AND
loc.location_id = ps.location_id AND
loc.actual_content_source = p_actual_content_source AND
ps.identifying_address_flag = 'Y';
select loc.location_id
into l_location_id
from HZ_LOCATIONS loc, HZ_PARTY_SITES ps
where
ps.party_id = p_party_id AND
loc.location_id = ps.location_id AND
loc.actual_content_source = p_actual_content_source AND
nvl(ps.end_date_active, sysdate+1) >= sysdate AND
ps.status = 'A' AND
Loc.last_update_date =
(select max(l_temp.last_update_date)
from hz_locations l_temp, hz_party_sites ps_temp
where l_temp.location_id = ps_temp.location_id AND
ps_temp.party_id = p_party_id AND
l_temp.actual_content_source = p_actual_content_source AND
nvl(ps_temp.end_date_active, sysdate+1) >= sysdate AND
ps_temp.status = 'A' );
select displayed_duns_party_id into l_displayed_duns_party_id
from hz_organization_profiles
where party_id = p_party_id and effective_end_date is null and actual_content_source = 'DNB';
select loc.location_id
into l_location_id
from HZ_LOCATIONS loc, HZ_PARTY_SITES ps
where ps.party_id = l_displayed_duns_party_id AND
loc.location_id = ps.location_id AND
loc.actual_content_source = 'DNB' AND
nvl(ps.end_date_active, sysdate+1) >= sysdate AND
ps.status = 'A' and
rownum=1;
select displayed_duns_party_id into l_displayed_duns_party_id
from hz_organization_profiles
where party_id = p_party_id and
effective_end_date is null and
actual_content_source = 'DNB';