0

I have a parallel job with parameter value "202203011537". I want to split this parameter value as "20220301" and "1537" and use it in SQL stage. Is there a way we can do it in Datastage parallel job?

1 Answers1

0

If you add Environment Variable in job properties?

In this case, if you set a variable, you will can call a cuostom routine that calculated the split value.

marian
  • 21
  • 2
  • Thanks Marian for the reply. Yes i am passing the value as Environmental variable. I am not sure how to do custom routine could you please help me? Also i should pass the split values to my SQL. is that possible? – Srikanth May 25 '22 at 08:33
  • yes, you could do it by sql and another alternative is the routine. You could create it and call it from a sequence or from a variable step https://www.ibm.com/docs/en/iis/11.3?topic=routines-creating-parallel-routine – marian May 25 '22 at 21:44
  • @marian, I don't see any benefit from going global like wasting static environment variables to achieve dynamic tasks? – Justus Kenklies May 30 '22 at 02:24
  • In terms of resource performance, i don't think there is a benefit. If I consider that if you are going to have to use that routine in more than one job, it will allow it to be reusable, and even when you want to modify it, it will have the same effect in all implementations – marian Jun 14 '22 at 17:21