Oracle R12 Shipping Status and Delivery Status Query

Oracle Shipping Execution stores two different statuses. The delivery status is WSH_NEW_DELIVERIES.STATUS_CODE (lookup DELIVERY_STATUS), and the shipping (pick) status of each delivery line is WSH_DELIVERY_DETAILS.RELEASED_STATUS (lookup PICK_STATUS). The queries below translate both codes into the meanings shown in the Shipping Transactions form.

SQL: delivery status and shipping status

--Delivery status
SELECT STATUS_CODE, meaning, delivery_id
  FROM wsh_new_deliveries wnd, 
       apps.fnd_lookup_values_vl flv
 WHERE     flv.LOOKUP_CODE = wnd.STATUS_CODE
       AND lookup_type = 'DELIVERY_STATUS'
       AND delivery_id = 1000;
       
       
--Shipping status
SELECT RELEASED_STATUS, meaning, delivery_detail_id
  FROM wsh_delivery_details wdd, 
       apps.fnd_lookup_values_vl flv
 WHERE flv.LOOKUP_CODE = wdd.RELEASED_STATUS 
   AND lookup_type = 'PICK_STATUS'
   AND delivery_detail_id = 215353;

Common status values

Delivery STATUS_CODEMeaning
OPOpen
COConfirmed
ITIn Transit
CLClosed
SAShipped Awaiting Confirmation (if used)
RELEASED_STATUSMeaning
NNot Ready for Release
RReady to Release
SReleased to Warehouse
BBackordered
YStaged / Pick Confirmed
CShipped
DCancelled
XNot Applicable

Replace delivery_id and delivery_detail_id with your values. To get every delivery line for an order line, filter WSH_DELIVERY_DETAILS on SOURCE_LINE_ID and SOURCE_CODE = 'OE'.

What is the difference between delivery status and released status?

Delivery status (WSH_NEW_DELIVERIES.STATUS_CODE) is the status of the whole delivery, such as Open or Closed. Released status (WSH_DELIVERY_DETAILS.RELEASED_STATUS) is the pick and ship status of each line.

What does released status B mean in Oracle Shipping?

B means Backordered: pick release could not allocate enough on-hand quantity.

How do I link a delivery detail to a delivery?

Through WSH_DELIVERY_ASSIGNMENTS, which stores DELIVERY_DETAIL_ID and DELIVERY_ID.

Related queries

Related posts: Upload your own post and refer it anywhere anytime: