We have moved to www.dataGenX.net, Keep Learning with us.

Wednesday, June 05, 2013

DataStage Macros



They are built from Data Stage functions and do not require arguments.
A number of macros are provided in the JOBCONTROL.H file to facilitate getting information about the current job, and links and stages belonging to the current job. These can be used in expressions, job control routines, filenames and table names, and before/after subroutines.


Some Parallel transformer Macros are listed here, as said, these can be used in anywhere in job


DSHostName 
This macro will give you the Host name of DataStage server.

DSJobController
It returns the name of the job that started the current one (if any).

DSJobInvocationId
This will return the InvocationId of job if job is multiple instance enables

DSJobName
As name says, return the Job name

DSJobStartDate
Return Job Start Date

DSJobStartTime
Return Job Start Time

DSJobStartTimestamp
Return Job Start timestamp

DSJobWaveNo
This is kind of Sequence no generated for each successful job run.
When compiled – 0
Each successful run – last+1
Each un-successful run – last+0

DSProjectName
Return Project Name of running job


Here you can find a Example Design :  CLICK HERE