CUST_BILLTO

(SQL View)
Index Back

Valid Bill To Relationships

Valid Bill To Relationships. This is used in RB_EIP. View to show Customer Bill to information

SELECT B.SETID , B.CUST_ID , C.CUST_ID , CASE WHEN 0 < ( SELECT COUNT(*) FROM PS_BO_REL D WHERE D.REL_TYPE_ID IN (57,59,69,71) AND B.BO_ID = D.BO_ID_1 AND D.ROLE_TYPE_ID_1 IN (42,46) AND C.BO_ID = D.BO_ID_2 AND D.ROLE_TYPE_ID_2 IN (43,47) AND D.START_DT <= %CurrentDateIn AND D.END_DT > %CurrentDateIn) THEN 1 ELSE 0 END , A.ROW_LASTMANT_OPRID , %CurrentDateIn FROM PS_BO_REL A, PS_BC B , PS_BC C WHERE A.BO_ID_1 =B.BO_ID AND A.BO_ID_2 = C. BO_ID AND (A.REL_TYPE_ID IN(57,59,69,71) OR A.REL_TYPE_ID IN (56,58,68,70) ) AND A.ROLE_TYPE_ID_1 IN (42,46) AND A.ROLE_TYPE_ID_2 IN (43,47) AND A.START_DT <= %CurrentDateIn AND A.END_DT > %CurrentDateIn

# PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
1 SETID Character(5) VARCHAR2(5) NOT NULL This field is used to store the value of SetID on various setup tables.

Prompt Table: SP_SETID_NONVW

2 CUST_ID Character(15) VARCHAR2(15) NOT NULL Customer ID
3 BILL_TO_CUST_ID Character(15) VARCHAR2(15) NOT NULL Customer
4 SLDTO_PRIORITY_NBR Number(4,0) SMALLINT NOT NULL Sldto Priority Nbr

Default Value: 1

5 LAST_MAINT_OPRID Character(30) VARCHAR2(30) NOT NULL This field determines the last user or operator that last changed this item.
6 DATE_LAST_MAINT Date(10) DATE This field determines the date of last maintenance.