Sequencer which echoes Paramater Name and Value to a file

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
memrinal
Participant
Posts: 74
Joined: Wed Nov 24, 2004 9:13 pm

Sequencer which echoes Paramater Name and Value to a file

Post by memrinal »

Hi
As a project requirement I need a DS sequencer which echoes all the parameter name and values to a file when the sequencer is run.

Please provide pointers about how to achieve the same.

Thanks in Advance.
Mrinal
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

It's in the first event in the job log. You can capture this with the DataStage API or with the dsjob command, and direct the information to wherever you will.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
kduke
Charter Member
Charter Member
Posts: 5227
Joined: Thu May 29, 2003 9:47 am
Location: Dallas, TX
Contact:

Post by kduke »

One of the tables in EtlStats is ETL_PARAM_HIST. This gets loaded along with the other tables. There is a job which can extract these values from previous job runs in the log files as long as there are not cleared.
Mamu Kim
memrinal
Participant
Posts: 74
Joined: Wed Nov 24, 2004 9:13 pm

Post by memrinal »

Thanks Ray,

Resolved it using dsjob command with the following script

Code: Select all

dsjob -server ${ServerName} \
-user ${USERID} \
-password ${PASSWORD} \
-logsum \
-type "STARTED" \
-max 1 \
${PROJECT} $1  > ${FilePath}/FileName.log

StartID=`head -2   ${FilePath}/FileName.log | cut -f1 `

echo ${StartID}

dsjob -server ${ServerName} \
-user ${USERID} \
-password ${PASSWORD} \
-logdetail \
${PROJECT} $1 ${StartID} > ${FilePath}/ActualLog.log


grep '=' ${FilePath}/ActualLog.log | grep -v 'DSJobController'  > ${FilePath}/Parameter.lst
Post Reply