HI_GL_RUN_3_VW(SQL View) |
Index Back |
---|---|
Payroll Run IDs with GL DataThis view retrieves all companies/paygroup/pay_end_date combinations for which the PAYGL01 process has been run. They are entered in the GL_GEN_HISTORY table with a GL_GEN_STATUS of N. |
SELECT DISTINCT A.COMPANY , A.PAYGROUP , A.PAY_END_DT FROM PS_GL_GEN_HISTORY A WHERE A.RUN_ID = ' ' AND A.GL_GEN_STATUS = 'N' AND A.PROGRAM_ID = 'PAYGL01' AND A.RUN_DT = ( SELECT MAX(A1.RUN_DT) FROM PS_GL_GEN_HISTORY A1 WHERE A1.PROGRAM_ID = 'PAYGL01' AND A1.COMPANY = A.COMPANY AND A1.PAYGROUP = A.PAYGROUP AND A1.PAY_END_DT = A.PAY_END_DT ) AND A.GL_RUN_NUM = ( SELECT MAX(A2.GL_RUN_NUM) FROM PS_GL_GEN_HISTORY A2 WHERE A2.PROGRAM_ID = 'PAYGL01' AND A2.COMPANY = A.COMPANY AND A2.PAYGROUP = A.PAYGROUP AND A2.PAY_END_DT = A.PAY_END_DT AND A2.RUN_DT = A.RUN_DT ) |
# | PeopleSoft Field Name | PeopleSoft Field Type | Database Column Type | Description |
---|---|---|---|---|
1 | COMPANY | Character(3) | VARCHAR2(3) NOT NULL |
Company
Prompt Table: COMPANY_TBL |
2 | PAYGROUP | Character(3) | VARCHAR2(3) NOT NULL |
Pay Group
Prompt Table: PAYGROUP_TBL |
3 | PAY_END_DT | Date(10) | DATE |
Pay Period End Date
Prompt Table: PAY_CALENDAR |