Below is the query to get Distributed Order Orchestration (Sales Order) header informations along with its EFF:
SELECT dha.header_id
, dha.order_number
, dha.customer_po_number
, dha.source_order_system
, dha.source_order_number
, dha.source_order_id
, dha.sold_to_party_id
, dha.transactional_currency_code
, TO_CHAR (dha.ordered_date, 'RRRR-MM-DD HH24:MI:SS') ordered_date
, dha.org_id bu_id
, dha.order_type_code
, dha.legal_entity_id
, dha.freeze_tax_flag
, dha.freeze_price_flag
, dha.freeze_shipping_charge_flag
, TO_CHAR (dha.priced_on, 'RRRR-MM-DD HH24:MI:SS') priced_on
, dha.submitted_flag
, dha.status_code
, dha.change_version_number
, dheb.context_code
, dheb.attribute_char1
, dheb.attribute_char2
, dheb.attribute_char3
, dheb.attribute_char4
, dheb.attribute_char5
, dheb.attribute_char6
, dheb.attribute_char7
, dheb.attribute_char8
, dheb.attribute_char9
, dheb.attribute_char10
, dheb.attribute_char11
, dheb.attribute_char12
, dheb.attribute_char13
, dheb.attribute_char14
, dheb.attribute_char15
, dha.created_by
, TO_CHAR (FROM_TZ (dha.creation_date, DBTIMEZONE) AT TIME ZONE 'Asia/Jakarta'
, 'RRRR-MM-DD HH24:MI:SS') creation_date
, dha.last_updated_by
, TO_CHAR (FROM_TZ (dha.last_update_date, DBTIMEZONE) AT TIME ZONE 'Asia/Jakarta'
, 'RRRR-MM-DD HH24:MI:SS') last_update_date
FROM doo_headers_all dha, doo_headers_eff_b dheb
WHERE dha.header_id = dheb.header_id(+)
No comments:
Post a Comment
Silahkan pos komentarnya... :)