EB_CUST_HIER_VW(SQL View) |
Index Back |
---|---|
Bill To Customer Security ViewUsed for row-level security for self-service transactions |
SELECT OPRID ,B.SETID ,B.CONTACT_ID , B.CUSTOMER_SETID , B.CUST_ID , CASE WHEN C.CUST_ID=C.CORPORATE_CUST_ID THEN NULL ELSE C.CORPORATE_CUST_ID END , CASE WHEN C.CUST_ID=C.CORPORATE_CUST_ID THEN NULL ELSE C.CORPORATE_SETID END , C.NAME1 , B.ADDRESS_SEQ_NUM FROM PSOPRALIAS A , PS_CONTACT_CUST B , PS_CUSTOMER C WHERE A.SETID = B.SETID AND A.CONTACT_ID = B.CONTACT_ID AND B.CUSTOMER_SETID = C.SETID AND B.CUST_ID = C.CUST_ID AND A.OPRALIASTYPE = 'CNT' AND B.BILL_TO_FLG = 'Y' AND B.EFFDT = ( SELECT MAX(X.EFFDT) FROM PS_CONTACT X WHERE X.SETID = B.SETID AND X.CONTACT_ID = B.CONTACT_ID AND X.EFFDT <= %CurrentDateIn) AND B.EFF_STATUS = 'A' |
# | PeopleSoft Field Name | PeopleSoft Field Type | Database Column Type | Description |
---|---|---|---|---|
1 | OPRID | Character(30) | VARCHAR2(30) NOT NULL | A user's ID (see PSOPRDEFN). |
2 | SETID | Character(5) | VARCHAR2(5) NOT NULL | SetID |
3 | CONTACT_ID | Character(15) | VARCHAR2(15) NOT NULL | Contact Identifier for Treasury Contacts |
4 | CUSTOMER_SETID | Character(5) | VARCHAR2(5) NOT NULL | Customer SetID |
5 | CUST_ID | Character(15) | VARCHAR2(15) NOT NULL | Uniquely identifies an organizational entity that purchases goods or services from the enterprise. Represents the sold-to customer which is the customer organization that places orders. The CUST_ID may or may not be the same as the identifiers for the bill-to and ship-to locations. |
6 | PARENT_CUST_ID | Character(15) | VARCHAR2(15) NOT NULL | Parent Cust ID |
7 | PARENT_SETID | Character(5) | VARCHAR2(5) NOT NULL | Parent SetID |
8 | NAME1 | Character(40) | VARCHAR2(40) NOT NULL | Name 1 |
9 | ADDRESS_SEQ_NUM | Number(5,0) | INTEGER NOT NULL | Address Sequence Number |