Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Last Executed date of a job.

Former Member
0 Kudos
2,835

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.

1 ACCEPTED SOLUTION

Former Member
0 Kudos
1,314

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.

8 REPLIES 8

Former Member
0 Kudos
1,314

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

0 Kudos
1,314

Thank you, i've been looking this for hours 🙂

Former Member
0 Kudos
1,314

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

0 Kudos
1,314

Hi,

Use the table

TBTCP

0 Kudos
1,314

Hi,

I checked the table TBTCP. It did not have the last executed date. I request you to suggest any other alternative table.

Former Member
0 Kudos
1,315

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.

0 Kudos
1,314

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.

0 Kudos
1,314

HI Murali,

Your reply has solved my problem. Thank you so much.