IN_DMD_PEGV_VW

(SQL View)
Index Back

IN Peg MSR Search View

06/21/04 EGS: Created 05/30/07 EGS: Remove "Open" check

SELECT A.BUSINESS_UNIT , A.DEMAND_SOURCE , A.SOURCE_BUS_UNIT , A.ORDER_NO , A.ORDER_INT_LINE_NO , A.SCHED_LINE_NBR , A.INV_ITEM_ID , A.DEMAND_LINE_NO , A.DESTIN_BU , A.QTY_REQUESTED_BASE - A.QTY_BACKORDER_BASE , A.PEG_STATUS FROM PS_IN_DEMAND A WHERE A.IN_FULFILL_STATE = '20' AND A.APPROVED_FLAG = 'Y' AND NOT EXISTS ( SELECT 'X' FROM PS_IN_DEMAND_LOCK B WHERE B.BUSINESS_UNIT = A.BUSINESS_UNIT AND B.DEMAND_SOURCE = A.DEMAND_SOURCE AND B.SOURCE_BUS_UNIT = A.SOURCE_BUS_UNIT AND B.ORDER_NO = A.ORDER_NO AND B.ORDER_INT_LINE_NO = A.ORDER_INT_LINE_NO AND B.SCHED_LINE_NBR = A.SCHED_LINE_NBR AND B.INV_ITEM_ID = A.INV_ITEM_ID AND B.DEMAND_LINE_NO = A.DEMAND_LINE_NO)

# PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
1 BUSINESS_UNIT Character(5) VARCHAR2(5) NOT NULL Business Unit
2 DEMAND_SOURCE Character(2) VARCHAR2(2) NOT NULL Demand Source
IN=Material Request
OM=Sales Order
PL=Planning Requisition
PO=Purchase Order
PR=Purchasing Requisition
RT=Material Return
SF=Production Request
WM=Work Order
3 SOURCE_BUS_UNIT Character(5) VARCHAR2(5) NOT NULL Source Bus Unit
4 ORDER_NO Character(10) VARCHAR2(10) NOT NULL Identifies a customer order number that appears as a reference on a receivables pending item. Date Initials Issue Description 022701 mv SP2 (F-CJORGENS-3) CSR Desktop
5 ORDER_INT_LINE_NO Number(5,0) INTEGER NOT NULL Order Line
6 SCHED_LINE_NBR Number(6,0) INTEGER NOT NULL Schedule Line Number
7 INV_ITEM_ID Character(18) VARCHAR2(18) NOT NULL Item ID
8 DEMAND_LINE_NO Number(4,0) SMALLINT NOT NULL Demand Line No
9 DESTIN_BU Character(5) VARCHAR2(5) NOT NULL Destination Unit
10 QTY_AVAILABLE Signed Number(17,4) DECIMAL(15,4) NOT NULL Qty Available
11 PEG_STATUS Character(2) VARCHAR2(2) NOT NULL 07/21/04 EGS: Created
10=Open
20=Completed
30=Canceled
40=Not Pegged