flow designer script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi All,
I am getting two or more sysid via flow varible in the flow designer, I neded to pass one by one sysid in the another subflow flow along with group name , but it takeing only first sysid other sysid is not taking .I have designed using the for each records , can anyone advise me how to achive this requirement.
if the receive 5 sysid is than 5 times subflow should run can anyone advise me how to do it .
Thanks and Regards,
Chandan Patra
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
why not pass complete string and then in Subflow iterate?
You can't have flow variable of type Array and hence you can't iterate that
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
another way is
-> pass that string of 5 sysIds to custom flow action as input
-> in that use script step and convert that to array of string
-> then return this output from action to main flow and then iterate that array using For Each
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 weeks ago
Hope you are doing good.
Did my reply answer your question?
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 weeks ago
Hi @chandan2212 ,
Based on my understanding, you want to run parallel sub-flows for each record.
To achieve this, you can use a combination of For Each and Dynamic Flow, as shown below:
How it works:
- The For Each loop will iterate through all your records.
- For each record, a Dynamic Flow will trigger the corresponding sub-flow in parallel.
If my response helped you, please consider marking it as "Accept as Solution" ✔️ and "Helpful" 👍 .
Doing so makes it easier for other community members to find the right answers and helps strengthen our community.