SAS Data Integration Studio, DataFlux Data Management Studio, SAS/ACCESS, SAS Data Loader for Hadoop and others

Creating an Audit table in SAS DI 4.21

Occasional Contributor
Posts: 8

Creating an Audit table in SAS DI 4.21

Hi All,

We have a requirement to create a Audit log table, to capture the following details

1) JobId

2) JobName

3) StartTime

4) EndTime

5) Status

This basically is used to capture details of the the current Job, so that this can be used

to track details about the Job at all times.


Prakash Ramesh

Super Contributor
Posts: 330

Re: Creating an Audit table in SAS DI 4.21

Posted in reply to blindgaurdien16


If I am correct the first four has an corresponding automatic variable on a DI.

JobId - jobID

JobName - etls_jobName

For the StartTime and EndTime, you can probably use the date time function. Update start time on the pre-process and update end time on the post process.

For the Status, you can update your audit table on the post-process code and check the &syserr or &sysrc value. This is a little tricky since if you get some errors, job might abort and it might not reach the portion of the post-process.

Hope this helps.

Super Contributor
Posts: 350

Re: Creating an Audit table in SAS DI 4.21

Hi Ramesh,

Try using Status handling to get all this information and capture this information in will get

Job End Time

Job Start Time

Job Return Code

Job Name

Job Status and many more.Hope this helps..




Ask a Question
Discussion stats
  • 2 replies
  • 3 in conversation