SQL Command in a Routine

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
chowdary
Participant
Posts: 38
Joined: Thu Jun 23, 2005 11:25 am

SQL Command in a Routine

Post by chowdary »

People,

I need to update an existing row or insert a new row in a table after the job runs, i am tinking of writing a AFTER JOB ROUTINE, so Can i run a SQL Command in a Routine, I knwo we can run a Unix command using DSExecute('UNIX','Command','OUTPUT','ReturnCode'), is there any similar way to run a SQL command.

Please throw some ideas.

Thanks
Chowdary
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Yes, you can do this in an after-job routine. But you will need to execute a UNIX command just as you would normally - if it needs to be done in several commands (i.e. using DB/2) then you would need to issue those commands; plus your after-job routine would also need to know the relevant information (instance, schema, userid, password).
Post Reply