Wednesday 24 September 2014

Query to findout order type and freight terms

select ooh.order_number, ott.name , ooh.freight_terms_code, ol.meaning
from
oe_order_headers_all ooh,
OE_TRANSACTION_TYPES_TL ott,
oe_lookups ol
where ooh.order_type_id = ott.TRANSACTION_TYPE_ID
and upper (ol.lookup_type) = 'FREIGHT_TERMS'  and ol.enabled_flag = 'Y'
and upper (ol.lookup_code) = upper (ooh.freight_terms_code)
and ooh.header_id =p_header_id;

No comments:

Post a Comment