Skip to main content

How to override parameter set value for a specific parameter in Datastage via unix command line ?

Sometimes you are running a data fix for production in datastage eg. back loading data and you get lazy to create a monstrous SQL just to replicate what the actual job is doing. You find yourself creating a unix script replicating the sequence call to the jobs that only populates the table you are fixing, of course you do not want other jobs in the sequence to be re-run during the fix which will mess up other tables.

An then you come across a parameter set in which you only need specific values of the parameter set to be passed with different values eg. Connection details.
Now that's simple if your parameter set is not importing environment variables.
As per IBM it should just be :

dsjob -run -wait -jobstatus -param "paramset.paramfield"="myvalues" MYDSPROJECT my_sample_ds_job

see the following link :

https://www-01.ibm.com/support/knowledgecenter/SSZJPZ_11.3.0/com.ibm.swg.im.iis.ds.direct.doc/topics/t_ddesref_running_job_command_line.html

Its a different case if your parameter set has values imported from DS ADMIN (ds environment variables).
In this case you should trick unix to ignore special characters:

dsjob -run -wait -jobstatus -param "paramset.\$paramfield"="myvalues" MYDSPROJECT my_sample_ds_job


Note of the back slash (\) that serves as unix escape character, it will ignore the special character and just treat it as normal text character which is recognized by Datastage.

Comments