Output multiple variables (Excel tabs) into one node and multiple workflow branches

Hi, I’m trying to read one Excel sheet with multiple tabs. Each tab should be one variable and each variable should be output in one workflow branch.

For example: I want to analyse tab 1 and tab 2 in different branches. All the branches come together in the end and are being written into one excel file again.

I created the following workflow:

The idea is:
The reader node reads each tab in a loop, uses dictionary to name each variable (sheet order may vary and needs regex filtering). Eveything ist given to the case switch start as an input variable. Until here, it works fine.

The problem is: as far as I understand, the Case Switch functions as First match, meaning just one output is being activated at a time. However, I need all the outputs active all the time. I guess I’m probably using the wrong node then.

Do you have any suggestions to replace the Case Switch Start?

Hi @FS_Clan,

Welcome to the forum.

You are already looping over each sheet and processing them one by one, so each sheet is handled separately in each iteration. What is the need for activating all the branches?

The CASE Switch only activates one branch per execution, by design. Currently the case switch is not part of the loop and will not execute for each iteration. If you want each sheet to be processed differently, move the CASE Switch inside the loop. There’s no need to have all branches active at once, since the sheets are processed sequentially.

Maybe you can share a example workflow with some dummy data and explain what are you expecting as the output.

Best,
Keerthan

1 Like