Exec DOS questions
Moderators: chulett, rschirm, roy
Exec DOS questions
Hi everybody !!!
If I can to execute DOS script containing some rows of code with DSExecute function and how to concenate the rows ?
If I can to execute DOS script containing some rows of code with DSExecute function and how to concenate the rows ?
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Use DSExecute with the first (Shell) argument set to "DOS".
The third argument contains the output. All of the output, with each line returned as a field in a dynamic array.
The third argument contains the output. All of the output, with each line returned as a field in a dynamic array.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 3337
- Joined: Mon Jan 17, 2005 4:49 am
- Location: United Kingdom
Hi,
You might be able to do it with the ftp stage using the telnet options.
Beyond that why are you relactant to use a batch? (you can build it on hte fly using a ds job if that is what your worried about.
IHTH,
You might be able to do it with the ftp stage using the telnet options.
Beyond that why are you relactant to use a batch? (you can build it on hte fly using a ds job if that is what your worried about.
IHTH,
Roy R.
Time is money but when you don't have money time is all you can afford.
Search before posting:)
Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Time is money but when you don't have money time is all you can afford.
Search before posting:)
Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Hello,
You have two options:
1. a batch file
2. a routine
if you'll need to write multiple lines in the ExecSH often, I suggest write a generic routine that gets all the code as one string parameter with a delimiter between the lines. in the routine open a loop that reads and executes field by field (ie line by line).
good luck,
Keren
You have two options:
1. a batch file
2. a routine
if you'll need to write multiple lines in the ExecSH often, I suggest write a generic routine that gets all the code as one string parameter with a delimiter between the lines. in the routine open a loop that reads and executes field by field (ie line by line).
good luck,
Keren
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Yes, with field marks (@FM) between them. In this way you have constructed a dynamic array, in which each element will be interpreted as a separate line by the shell.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.