# Issue with Multi-Flow Routing in CBR Script — Only First Flow Executes

**URL:** <https://connective.celigo.com/t/issue-with-multi-flow-routing-in-cbr-script-only-first-flow-executes/6307>\
**Category:** Integrator.io\
**Tags:** javascript\
**Created:** [May 20, 2026, 5:12am UTC](https://connective.celigo.com/t/issue-with-multi-flow-routing-in-cbr-script-only-first-flow-executes/6307 "2026-05-20T05:12:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sriram\_Ramji](https://avatars.discourse-cdn.com/v4/letter/s/e8c25b/32.png) [@Sriram\_Ramji](https://connective.celigo.com/u/Sriram_Ramji)\
**Post date:** [May 20, 2026, 5:12am UTC](https://connective.celigo.com/t/issue-with-multi-flow-routing-in-cbr-script-only-first-flow-executes/6307/1 "2026-05-20T05:12:03Z")

</div>

Hi Celigo Community,

We are facing an issue with a Content-Based Routing (CBR) script where returning multiple flows for a transaction type only executes one flow.

### What we observed

- The CBR script returns an array containing two flow/export ID objects for certain transaction types.

- Only one flow executes — specifically, whichever flow appears first in the array.

- Swapping the order of the flows changes which one executes, confirming the issue is position-dependent rather than flow-specific.

- We tested both array-based returns and alternate syntax approaches, but the behavior remains the same: only one flow triggers.

- The issue occurs consistently across all transaction types configured with two flows, including 852, 860, 864, and 820.

- Returning a single flow object works correctly throughout the script.

### Additional context

- All flow/export IDs referenced in the arrays are active and valid.

- Single-flow routing works as expected.

- The issue is not isolated to a specific transaction type or flow configuration.

Has anyone implemented multi-flow routing successfully in a CBR script?  
Could you please advise on the correct approach to ensure both flows execute as expected?

I’ve attached the script for reference.

[CBR\_Script.txt](https://connective.celigo.com/uploads/short-url/hin1PfjLWJ2NuBk24J4dI3kPwrZ.txt) (6.0 KB)

---

<div class="post-metadata">

**Author:** ![adamkeyes](https://sea1.discourse-cdn.com/flex001/user_avatar/connective.celigo.com/adamkeyes/32/6969_2.png) [@adamkeyes](https://connective.celigo.com/u/adamkeyes)\
**Post date:** [May 27, 2026, 2:20pm UTC](https://connective.celigo.com/t/issue-with-multi-flow-routing-in-cbr-script-only-first-flow-executes/6307/2 "2026-05-27T14:20:58Z")

</div>

Hi Sriram, I'll check in with the Celigo engineering team, but just based on your testing I would assume that we can only submit the file to a single flow/exportid. I see in your script you tried a few attempts, with the single file submission result. The alternatvie would be to pass the file to a flow in IO, store to a temp location, and run secondary flows to process the data multiple times.
