09-10-2013 7:10 AM
Hello Experts,
I have a requirement to add the date condition wherein :
1) Consider LE sy-datum for the first run
2) Consider EQ sy-datum for rest of the runs/execution of the program.
Please help me on how to find out the First Run of the Program?
I searched SCN but didnt find any relevant posts.
Appreciate your help.
Thanks & Regards,
Sowmya
09-10-2013 7:41 AM
AFAIK not possible as MONI and other tables and files used by ST03N are supposed to be cleared of oldest records regularly.
Set the date range as a SELECT-OPTIONS, then in INITIALIZATION look for the last execution in TVARVC, if not found, initialize to LE sy-datum, else EQ sy-datum, and at start of execution,update TVARVC ?
Regards,
Raymond
09-10-2013 7:15 AM
Hi,
it's not really possible. The trace of what/when/who are stored in the transaction ST03, but for the most part of the system the period archived is 3 months.
regards
Fred
09-10-2013 7:41 AM
AFAIK not possible as MONI and other tables and files used by ST03N are supposed to be cleared of oldest records regularly.
Set the date range as a SELECT-OPTIONS, then in INITIALIZATION look for the last execution in TVARVC, if not found, initialize to LE sy-datum, else EQ sy-datum, and at start of execution,update TVARVC ?
Regards,
Raymond
09-10-2013 8:05 AM
Hi Sowmya,
For this requirment you have to create a Z Table where you have to maintain value of a FLAG.
At start value of this field will be ZERO or Initial,
Once that report is executed , you have to check value of this flag,
If this is initial or ZERO, You have to take date as per requirement LE SY-DATUM, and set value of this flag as 'X'.
OR if this flag is "X", you have to take as equal to SY-DATUM. (Because value of this flag will be 'X' only if you have already executed this report).
Hope that will help to achieve your requirement.
You can also add field in your Z Table if you have to xecute this report according to variant.
Let me know in case you need more clarification.
Regards,
Shyam Goyal