PS Query - How can I add additional criteria for Sequence number in Effdt criteria for Job Table
PS Query - How can i add additional criteria for Sequence number in Effdt criteria for join involving Job Table 2 time.
For instance, this is the SQL for PS Query which fetches max effdt row & second max effdt row. But i want to add a condition of effseq
as well wherein 2nd max row should consider effseq value as well when effdt for both top two rows is same. This qiery is getting used as AWE user list and returns OPRID for employee if Location/state for his max & second max row is different. This is not working when top two rows have same effdt but diff effseq because only below mentioned highlited in green criteria is present and requires additional criteria like highlited in red. Can some one share how do i add the criteria (highlited in red) in this PS Query. Table H gives max row