Job set the own parameters
Posted: Fri Jan 07, 2005 4:36 am
Hi,
I use the sequencer to run a job (named "JOB1") that need a parameter (named "PAR_XX") that is stored in a file.
PAR_XX is in the parametr's list of JOB1
I think to read the parameter in the job control code of JOB1 and use it in the same job.
When the job start, first of all execute the job control code and read the file but I don't understand how I can "tell" to JOB1 to use this parameter in a ORAOCI8 Plug-in.
How can i do it? Is it possible to do it?
In the ORAOCI8 i have the query
SELECT ID
FROM table
WHERE LAST_MODIFIED > TO_DATE('#PAR_XX#', 'YYYY-MM-DD HH24:MI:SS')
and in the job control code have:
OpenSeq KshPath:"/EBIS_params_21" To FileVar Else Call DSLogFatal('Errore nella lettura del parametro di filtro 21 per il job : H3GITmisODStoODSACCOUNTRev2', "JobControl")
ReadSeq val From FileVar Then PAR_XX = val
I tried to set the parameter with the next code in the job contol code but doesn't work
ErrCode3 = DSSetParam(DSJ.ME, "PAR_XX", PAR_XX)
An another little question: where can I find information about the DataStage language for routine?
Thanks in advance
Regards
Mario
I use the sequencer to run a job (named "JOB1") that need a parameter (named "PAR_XX") that is stored in a file.
PAR_XX is in the parametr's list of JOB1
I think to read the parameter in the job control code of JOB1 and use it in the same job.
When the job start, first of all execute the job control code and read the file but I don't understand how I can "tell" to JOB1 to use this parameter in a ORAOCI8 Plug-in.
How can i do it? Is it possible to do it?
In the ORAOCI8 i have the query
SELECT ID
FROM table
WHERE LAST_MODIFIED > TO_DATE('#PAR_XX#', 'YYYY-MM-DD HH24:MI:SS')
and in the job control code have:
OpenSeq KshPath:"/EBIS_params_21" To FileVar Else Call DSLogFatal('Errore nella lettura del parametro di filtro 21 per il job : H3GITmisODStoODSACCOUNTRev2', "JobControl")
ReadSeq val From FileVar Then PAR_XX = val
I tried to set the parameter with the next code in the job contol code but doesn't work
ErrCode3 = DSSetParam(DSJ.ME, "PAR_XX", PAR_XX)
An another little question: where can I find information about the DataStage language for routine?
Thanks in advance
Regards
Mario