The data in it is generated via a FOCUS application, and sometimes we can have multiple actions for the same system/userid on the same date. The thing is, at some point in my application I need to get only the last entry, for each userid. I've been trying this:
TABLE FILE SECFLLOG
SUM FIRST_NAM_BF
FIRST_NAM_AF
LAST_NAME_BF
LAST_NAME_AF
REQ_TYPE
REQ_STATUS
SEC_OPERID
VER_OPERID
VER_MAINT_DT
VER_TIME
VER_STATUS
LEVEL_BFOR
LEVEL_AFTR
IF VER_STATUS IS 'A'
BY REQ_SYSTEM
BY USERID
BY HIGHEST SEC_MAINT_DT
BY HIGHEST SEC_TIME
END
And this is producing the following result (I'm purposedly suppressing a few columns of the output here just to be more readable):
I've been trying a few things I've read on the documentation, but still couldn't find a way to do the output come as I need it. I Need the output to come out like this, showing just the last occurence for each system/userid:
REQ_SYSTEM USERID SEC_MAINT_DT SEC_TIME FIRST_NAM_BF
---------- ------ ------------ -------- ------------
BTCCS CDALOZB 09/09/14 08.51.05 ARADHANA
CDALOZ2 09/09/14 08.54.31 RAJ
CDALOZ3 09/09/14 08.48.20 ANU
CDALOZ5 08/29/14 15.07.49 KALYANA
CDALOZ6 08/29/14 15.10.33 PAUL
CDALOZ7 09/03/14 15.06.13 BOBBY
WHS CDALOZB 09/09/14 08.53.55 ARADHANA
CDALOZ2 09/09/14 08.55.04 RAJ
CDALOZ3 09/09/14 08.49.13 ANU
CDALOZ5 08/29/14 15.08.50 KALYANA
CDALOZ6 08/29/14 15.11.19 PAUL
CDALOZ7 09/03/14 15.06.51 BOBBY
Is there a way to do such filtering? Thanks in advanceThis message has been edited. Last edited by: andrekilik,
FOCUS 7.6 Mainframe, Outputs available
September 09, 2014, 09:32 AM
RSquared
quote:
BY HIGHEST SEC_TIME
Try changing your code from BY HIGHEST SEC_TIME to
BY HIGHEST 1 SEC_TIME
WF 7.6.11 Oracle WebSphere Windows NT-5.2 x86 32bit
September 09, 2014, 09:47 AM
andrekilik
That worked smoothly, thanks a lot.
FOCUS 7.6 Mainframe, Outputs available
September 09, 2014, 11:04 AM
RSquared
please tag as solved
WF 7.6.11 Oracle WebSphere Windows NT-5.2 x86 32bit