‎2015 May 29 6:40 PM
I have searched the forums for this, but could not get the answer.
My requirement:
There is a select option for dates: s_dates.
There is a variable which holds one date: lv_date.
Before i can use the s_dates in my select statement, i need to delete all the dates after lv_date.
My opinion:
Get all the dates using any FM: *date*, then delete the dates greater than lv_date.
But i am not convinced this is professional way.
Can anyone please suggest me a better way of doing this.
‎2015 May 29 7:12 PM
Hi Naveen,
maybe a silly solution, but couldn't this just work as you need?
clear s_dates.
s_dates-sign = 'E'.
s_dates-option = 'GT'.
s_date-slow = lv_date
append s_dates.
Then use your s_dates normally in SELECT.
Give a try.
Regards,
Frisoni
‎2015 May 29 6:49 PM
What *DATE* FM would you use to get all the dates? (There are a lot of both FMs and dates.)
Rob
‎2015 May 29 7:12 PM
Hi Naveen,
maybe a silly solution, but couldn't this just work as you need?
clear s_dates.
s_dates-sign = 'E'.
s_dates-option = 'GT'.
s_date-slow = lv_date
append s_dates.
Then use your s_dates normally in SELECT.
Give a try.
Regards,
Frisoni
‎2015 May 29 7:52 PM
Thanks Rob and Guilherme for responding.
Rob,
I was thinking of using the FM: DAY_ATTRIBUTES_GET, but this i could only use for the sign 'BT', for rest all i need to use if conditions to calculate.
Guilherme,
Yes, i had this thought, but was not sure, because the both conditions overlap.
But just tested it and it works.
Thanks both of you for your time.