TomBorcoman
Technical User
Hi there, first post for me. Below I have some sample data in a master file for employees and I would like some help with some code that will select/filter out the right data:
ID# POS# FUND PERCENT EFF.DATE
4366 Z1 20502 100 35796
4366 Z1 20502 100 36923 *
4306 Z2 20502 50 35796
4306 Z2 22018 50 35796
4306 Z2 20502 50 36192
4306 Z2 22018 50 36192
4306 Z2 20502 50 36514 *
4306 Z2 10003 50 36514 *
4307 Z3 20502 100 35796
4356 Z3 20502 100 36290
4323 Z3 20502 100 37270 *
I have a number of issues here. Ideally, I'd like to select the line(s) of code that have the highest date for a particular POS#. The PERCENT field, if not 100, needs to have more than one line produced. I have put an asterisk next to the lines I would want to keep. I hope I have been clear on this and I would really appreciate some ideas for the Focus code.
I'm thinking I need to have a complex WHERE statement in the TABLE FILE section. Thanks in advance!!
ID# POS# FUND PERCENT EFF.DATE
4366 Z1 20502 100 35796
4366 Z1 20502 100 36923 *
4306 Z2 20502 50 35796
4306 Z2 22018 50 35796
4306 Z2 20502 50 36192
4306 Z2 22018 50 36192
4306 Z2 20502 50 36514 *
4306 Z2 10003 50 36514 *
4307 Z3 20502 100 35796
4356 Z3 20502 100 36290
4323 Z3 20502 100 37270 *
I have a number of issues here. Ideally, I'd like to select the line(s) of code that have the highest date for a particular POS#. The PERCENT field, if not 100, needs to have more than one line produced. I have put an asterisk next to the lines I would want to keep. I hope I have been clear on this and I would really appreciate some ideas for the Focus code.
I'm thinking I need to have a complex WHERE statement in the TABLE FILE section. Thanks in advance!!