FA_ZIP_REGN_VW(SQL View) |
Index Back |
---|---|
Zip Code Region Base Node ViewThis view returnsr the lowest-level regions on the Region tree. |
SELECT A.SETID, B.REGION, B.EFFDT, B.EFF_STATUS, B.DESCR, A.EFFDT, A.TREE_NODE_NUM, A.TREE_NODE_NUM_END FROM PSTREENODE A, PS_BDGT_REGION_TBL B WHERE A.TREE_NAME = 'FA_ZIPCODE_REGION' AND A.TREE_NODE = B.REGION AND A.SETID = B.SETID AND B.EFFDT = (SELECT MAX(EFFDT) FROM PS_BDGT_REGION_TBL B1 WHERE B1.SETID = B.SETID AND B1.REGION = B.REGION AND B1.EFFDT <= %CURRENTDATEIN) AND A.EFFDT = (SELECT MAX(EFFDT) FROM PSTREENODE A1 WHERE A1.SETID = A.SETID AND A1.TREE_NAME = A.TREE_NAME AND A1.TREE_BRANCH = A.TREE_BRANCH AND A1.TREE_NODE_NUM = A.TREE_NODE_NUM AND A1.TREE_NODE = A.TREE_NODE AND A1.EFFDT <= %CURRENTDATEIN) AND EXISTS (SELECT 'X' FROM PSTREELEAF D WHERE D.TREE_NODE_NUM=A.TREE_NODE_NUM AND D.SETID = A.SETID AND D.TREE_NAME = A.TREE_NAME AND D.EFFDT = A.EFFDT) |
# | PeopleSoft Field Name | PeopleSoft Field Type | Database Column Type | Description |
---|---|---|---|---|
1 | SETID | Character(5) | VARCHAR2(5) NOT NULL | SetID |
2 | REGION | Character(10) | VARCHAR2(10) NOT NULL |
Region
Prompt Table: REGION_TBL |
3 | EFFDT | Date(10) | DATE NOT NULL |
Effective Date
Default Value: %date |
4 | EFF_STATUS | Character(1) | VARCHAR2(1) NOT NULL |
Effective Status
A=Active I=Inactive |
5 | DESCR | Character(30) | VARCHAR2(30) NOT NULL | Description |
6 | TREE_EFFDT | Date(10) | DATE NOT NULL | Effective date of the Tree |
7 | TREE_NODE_NUM | Number(10,0) | DECIMAL(10) NOT NULL | Internal beginning node range number |
8 | TREE_NODE_NUM_END | Number(10,0) | DECIMAL(10) NOT NULL | Internal ending node range number |