Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I would like to know if it's normal when i use a Job, with a subjob, with prod context my subjob doesn't run with the context prod ?
Tjava_1 : System.out.println(context.new2);
For me I launch the job with the "Prod" context normally I should have:
System.out.println(context.new2); = Prod2
Why i have : default2 ?
And who can i have "Prod2" with out have context.new2 in my man job ?
Regards,
Nad
A long time I wrote a piece on contexts and ways of getting around this problem. The first blog of 4 (I believe) can be seen here....
https://www.talend.com/resources/best-practices-for-using-context-variables-part-1/
It may give you a few ideas as there are many ways to get around this depending on your many other requirements.
Hi
I noticed that you don't define variable context.new2 in parent job, when using 'transmit the whole context' from parent job to child job, the variable should exist in both parent job and child job, the variable name should be the same.
Regards
Shong
Hi,
Yes i know that. Like i said : who can i have "Prod2" with out have context.new2 in my man job ?