How to pass data from main workflow to sub workflow?

sanyalshubh
Tera Contributor

I have tried using variable creation and passing using g_scratchpad. but not working

3 ACCEPTED SOLUTIONS

Ankur Bawiskar
Tera Patron
Tera Patron

@sanyalshubh 

this link has solution, you can create input to 2nd workflow and pass that input when you call from 1st workflow

How pass variable of on workflow to another workflow 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

View solution in original post

Ravi Gaurav
Giga Sage
Giga Sage

Hi @sanyalshubh 

Configure the subflow to accept variables from the parent workflow by defining the inputs.
Include the subflow in the parent workflow and connect the inputs to the parent workflow variables

--------------------------------------------------------------------------------------------------------------------------


If you found my response helpful, I would greatly appreciate it if you could mark it as "Accepted Solution" and "Helpful."
Your support not only benefits the community but also encourages me to continue assisting. Thank you so much!

Thanks and Regards
Ravi Gaurav | ServiceNow MVP 2025,2024 | ServiceNow Practice Lead | Solution Architect
CGI
M.Tech in Data Science & AI

ï”— YouTube: https://www.youtube.com/@learnservicenowwithravi
ï”— LinkedIn: https://www.linkedin.com/in/ravi-gaurav-a67542aa/

View solution in original post

3 REPLIES 3

Ankur Bawiskar
Tera Patron
Tera Patron

@sanyalshubh 

this link has solution, you can create input to 2nd workflow and pass that input when you call from 1st workflow

How pass variable of on workflow to another workflow 

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

Ravi Gaurav
Giga Sage
Giga Sage

Hi @sanyalshubh 

Configure the subflow to accept variables from the parent workflow by defining the inputs.
Include the subflow in the parent workflow and connect the inputs to the parent workflow variables

--------------------------------------------------------------------------------------------------------------------------


If you found my response helpful, I would greatly appreciate it if you could mark it as "Accepted Solution" and "Helpful."
Your support not only benefits the community but also encourages me to continue assisting. Thank you so much!

Thanks and Regards
Ravi Gaurav | ServiceNow MVP 2025,2024 | ServiceNow Practice Lead | Solution Architect
CGI
M.Tech in Data Science & AI

ï”— YouTube: https://www.youtube.com/@learnservicenowwithravi
ï”— LinkedIn: https://www.linkedin.com/in/ravi-gaurav-a67542aa/