Skip to Content
0
Former Member
Oct 17, 2005 at 05:44 PM

select coding

26 Views

hi,

i have several entries in db as follows.

-id -date ---

10001----20060403

10001-- 20050403 < -----

10001----20040403

i need to pick the record which is less than or equal to current date and the most current one. in this case i need to pick the second record.

i DONT WANT TO USE internal table. could some one suggest a select statement on which i can proceed.

your help would be appreciated

Thanks,

ravi.

rob and rich,

one small problem, i have several records with different id's but if i use this its working only for one id, can you suggest some modifications so that i can go ahead.its important for me to use select and endselect.

Thanks,

ravi.

rich,

i need one record per id with the above validations(there are several fields i need to select apart from id and date).

Thanks,

ravi.

Message was edited by: ravi kumar

Message was edited by: ravi kumar