Support Questions

Find answers, ask questions, and share your expertise

Pass parameters to oozie subworkflow

avatar
Expert Contributor

Hello,

Is it possible to pass parameters to oozie subworkflows from the parent workflow actions using the actionData funciton, i.e. ${wf:actionData('ParentWFAction')['PARAM_NAME']}?

 

Thanks,

Martin

1 ACCEPTED SOLUTION

avatar
Expert Contributor

Hi Harsh, thanks for the follow up, though it's not 100% clear from the response what needs to be done.

 

However, I was able to figure out the following & posting here for the benefit of the community. In the subworkflow task, you can use the Job Properties box to achieve this, e.g.

 

Property Name = PARAM1

Property Value = ${wf:actionData('ParentWFAction')['PARAM_NAME']}

 

Then in the subworkflow itself, you will be able to access the value as ${PARAM1}.

 

Regards,

Martin

View solution in original post

4 REPLIES 4

avatar
Mentor
You can use on the to pass any variable
name and substituted values around.

avatar
Expert Contributor

Hi Harsh, thanks for the follow up, though it's not 100% clear from the response what needs to be done.

 

However, I was able to figure out the following & posting here for the benefit of the community. In the subworkflow task, you can use the Job Properties box to achieve this, e.g.

 

Property Name = PARAM1

Property Value = ${wf:actionData('ParentWFAction')['PARAM_NAME']}

 

Then in the subworkflow itself, you will be able to access the value as ${PARAM1}.

 

Regards,

Martin

avatar
New Contributor

Hi, How can I get the status of the workflow and the execution time taken by the workflow through these commands, 

 

${wf:actionData('ParentWFAction')['PARAM_NAME']}

avatar
Expert Contributor
Hi sairamvj, I would suggest you open a new thread for your question, as it is not related to this topic of this thread.

Martin