2008 Mar 25 12:40 AM
Hi everybody,
I have a scenario where I need to compare the record created date with the last executed date of a batch job. The record created date, we are retrieving from a Z table. But I am unable to find the table from where I can find the last executed date of the job / Report.
I came to know from many forms to use TBTCO table. But in our development systems, we could not find the latest executed date for some jobs which were executed recently. that field is completely empty for some jobs.
Please suggest me the right table where I can find the last executed date of the JOB / Report.
Any helpful answer will be rewarded immediately.
Thanks in advance.
Vana.
2008 Mar 25 4:11 AM
Hi all,
When I run the sql trace for the TC sm37, it is taking the values from the view v_op which has the join of tables TBTCO and TBTCP. But in my dev systems, the field for the last executed date LASTSTRTDT is empty for almost all jobs.
Can you please tell me atleast for what cases, this field will be empty and in what scenarios I can get the last executed date of the job.
Please reply me ASAP.
Helpful points will be rewarded.
Thanks in advance.
2008 Mar 25 1:06 AM
Hi Vana,
TBTCO is the only table which will give you the last execution date of the job. You need to pass the correct job id.
Regards,
Atish
2020 Jan 17 8:44 PM
2008 Mar 25 1:10 AM
Hi Atish,
Thank you for your prompt reply. You are right, that TBTCO is the table to find the last executed date.. but for some reasons, we could not find that date for some jobs which we executed recelntly. Thats the only reason I am searching for the other alternative table.
Thanks
2008 Mar 25 3:22 AM
2008 Mar 25 3:39 AM
Hi,
I checked the table TBTCP. It did not have the last executed date. I request you to suggest any other alternative table.
2008 Mar 25 4:11 AM
Hi all,
When I run the sql trace for the TC sm37, it is taking the values from the view v_op which has the join of tables TBTCO and TBTCP. But in my dev systems, the field for the last executed date LASTSTRTDT is empty for almost all jobs.
Can you please tell me atleast for what cases, this field will be empty and in what scenarios I can get the last executed date of the job.
Please reply me ASAP.
Helpful points will be rewarded.
Thanks in advance.
2008 Mar 25 4:27 AM
Vana,
In table "TBTCP" there is field called SDLDATE(Date of job/step scheduling).
So, select data of paricular job .Say it will give 5 different dates. into internal table.
SORT the internal table SDLDATE DESCENDING.
So you will get the latest scheduling date record in first position of internal table.
IF latest record date is < sy-datum+1.
Yes last schedulke date.
ENDIF.
2008 Mar 25 4:54 AM
HI Murali,
Your reply has solved my problem. Thank you so much.