The following lines contain the word 'select', 'insert', 'update' or 'delete':
SELECT count(1)
INTO l_count
FROM dual
WHERE exists (
SELECT NULL
FROM po_doc_style_headers pdsh,
po_doc_style_lines_vl pdsl
WHERE pdsl.display_name = p_name
AND pdsh.style_id = pdsl.style_id
AND pdsh.status = 'ACTIVE'
AND pdsl.style_id <> nvl(p_style_id, -9999));
SELECT count(1)
INTO l_count
FROM dual
WHERE exists (
SELECT NULL
FROM po_doc_style_headers pdsh
WHERE pdsh.style_name = p_name
AND pdsh.style_id <> nvl(p_style_id, -9999));
SELECT count(1)
INTO l_count
FROM dual
WHERE exists (
SELECT NULL
FROM po_doc_style_headers pdhs
WHERE style_type = 'STANDARD'
and style_id = p_style_id);
SELECT style_id
INTO l_style_id
FROM po_doc_style_headers pdhs
WHERE style_type = 'STANDARD';
SELECT
pdsh.style_name
, pdsh.style_description
, pdsh.style_type
, pdsh.status
, pdsh.advances_flag
, pdsh.retainage_flag
, pdsh.price_breaks_flag
, pdsh.price_differentials_flag
, pdsh.progress_payment_flag
, pdsh.contract_financing_flag
, pdsh.line_type_allowed
INTO
x_style_name
, x_style_description
, x_style_type
, x_status
, x_advances_flag
, x_retainage_flag
, x_price_breaks_flag
, x_price_differentials_flag
, x_progress_payment_flag
, x_contract_financing_flag
, x_line_type_allowed
FROM po_doc_style_headers pdsh
WHERE pdsh.style_id = p_style_id;