Attach DSJ.JOBPID during job
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
Attach DSJ.JOBPID during job
Basically I would like to attach the PID from UNIX into our job so that the Change Data Capture log entries will contain the PID. I have looked at the DSMacro's in the transformer and they do not contain a very robust list of system variables. I have seen similar discussions on-line but no definitive answers (unless I missed them).
Thanks
Thanks
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
You could employ the Transformer stage function GetEnvironment($$) when intializing a stage variable (for the Transformer stage's process ID) or GetEnvironment($PPID) for the job's process ID.
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: 51
- Joined: Mon Feb 05, 2007 1:53 pm
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
That does'nt work for youray.wurlod wrote:You could employ the Transformer stage function GetEnvironment($$) when intializing a stage variable (for the Transformer stage's process ID) or GetEnvironment($PPID) for the job's process ID.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
I looked up GetEnvironment in the help and this is all it tells me.
The following table lists the functions available in the Utility category (square brackets indicate an argument is optional):
Name
Description
Arguments
Output
GetEnvironment
Return the value of the given environment variable
environment variable (string)
result (string)
I also tried to find it in the transformer and it is not listed in the macros,system variables,functions etc... Without any info on how to use the GEtEnvironment in the help guide I am stumped
The following table lists the functions available in the Utility category (square brackets indicate an argument is optional):
Name
Description
Arguments
Output
GetEnvironment
Return the value of the given environment variable
environment variable (string)
result (string)
I also tried to find it in the transformer and it is not listed in the macros,system variables,functions etc... Without any info on how to use the GEtEnvironment in the help guide I am stumped
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
-
- Participant
- Posts: 51
- Joined: Mon Feb 05, 2007 1:53 pm
I tried to right click on the stage variable and it would not work. I can set one up in the transformer properties where it asks for NAME...INITIAL VALUE...SQLTYPE...EXTENDED...Precision...SCALE...DESCRIPTION once defined there the system variable option becomes ungrayed and I can use the variable I set up. I do not see the UTILITY option although I found it in the help section.
Yes, where you see NAME...Initial Value bla bla bla, specify a name, give an initial value of 0 specify it as integer. Hit ok. Then in the transformer you will see your stage variable on the right hand side on the top. If you dont see it, click the fourth icon from the right. That icon, present at the top, hides and shows stage variables. Inside the derivation of the stage variable you will have to right click and go to functions, extent Utility and click on GetEnvironment(). THats the only option under Utility.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.