Execute script from DS

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
shiva459
Premium Member
Premium Member
Posts: 100
Joined: Wed Jun 11, 2003 1:49 am
Location: Bangalore

Execute script from DS

Post by shiva459 »

Hi
I have to run a SQL script from the command line through EXECUTE COMMAND activity of the sequencer.Now I can give the command as
db2 -tf and the parameter as the file name.Now my question is where should I place the script file?Should it be placed in any specific folder?I am working on AIX.
Regards

Shiv
spracht
Participant
Posts: 105
Joined: Tue Apr 15, 2003 11:30 pm
Location: Germany

Post by spracht »

For portability reasons, I found it sensible to place scripts into subfolders of the project directory, as the utilities executing OS commands or scripts always take the project directory as their working directory. Thus you can always specify the path to your script relative to the project account.

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

Post by ray.wurlod »

Stephan's approach has the additional benefit that these sub-folders can then be referenced as custom folders by Version Control for DataStage.

Ray Wurlod
Education and Consulting Services
ABN 57 092 448 518
Post Reply