EE_MEDCATN_VW(SQL View) |
Index Back |
---|---|
EE - Medication Details TableThis is the Employee related Medication view for Remote Worker Analyutics It is used to maintain allergy codes by REG_REGION. |
SELECT EMPLID ,REG_REGION ,MEDICATION_CODE ,START_DATE ,END_DATE FROM PS_EE_MEDCATN_DTL D WHERE start_date=( SELECT MAX(START_DATE) FROM PS_EE_MEDCATN_DTL d1 WHERE d.EMPLID=d1.EMPLID AND D.REG_REGION=D1.REG_REGION AND D.MEDICATION_CODE=D1.MEDICATION_CODE AND D1.START_DATE<=%CurrentDateIn ) AND (D.END_DATE IS NULL OR D.END_DATE>%CurrentDateIn) |
# | PeopleSoft Field Name | PeopleSoft Field Type | Database Column Type | Description |
---|---|---|---|---|
1 | EMPLID | Character(11) | VARCHAR2(11) NOT NULL |
Employee ID
Prompt Table: PERSON |
2 | REG_REGION | Character(5) | VARCHAR2(5) NOT NULL |
Regulatory Region
Prompt Table: REG_REGION_TBL |
3 | MEDICATION_CODE | Character(4) | VARCHAR2(4) NOT NULL |
Medication Code
Prompt Table: HS_MEDCATN_TBL |
4 | START_DATE | Date(10) | DATE NOT NULL | Start Date for Gen Standing PO |
5 | END_DATE | Date(10) | DATE | End Date |