I am new to DS and need to read a table and pass the retrieved value to a DS parameter value.
For example, I read the table and get the file path and file location, I need to be able to pass that value to the SEQ File at the end of the process. How can I accomplish that?
Thanks
passing a value from a db2 table to a datastage parameter
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 24
- Joined: Wed Apr 16, 2014 11:11 am
- Location: United States
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Welcome aboard.
You can't do that in a single job. You need one job to read and store the value (perhaps in its user status area) and the controlling sequence can pass the value to a job parameter in the second job. The Sequential File stage's File property is set to a reference to that job parameter.
You can't do that in a single job. You need one job to read and store the value (perhaps in its user status area) and the controlling sequence can pass the value to a job parameter in the second job. The Sequential File stage's File property is set to a reference to that job parameter.
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: 24
- Joined: Wed Apr 16, 2014 11:11 am
- Location: United States
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
The result of the Execute Command activity is available as an activity variable that you can use to populate the job parameter in the Job activity.
Note that you may need to trim a trailing field mark character.
Note that you may need to trim a trailing field mark character.
Code: Select all
Trim(MyCommand.$CommandOutput, @FM)
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: 24
- Joined: Wed Apr 16, 2014 11:11 am
- Location: United States