bypassing the result of no rows using EmptyTable switch in loop

Hi,

I need to query database with list of queries sequentially and process them distinctly . I am using loop to to execute the queries and need to proceed to next query if the response of the earlier query in the loop is empty. Used empty table switch , but still facing error stating of active node error on loop end … How can I move to next set query , attached my workflow. Appreciate help on resolution of the same .

can you connect your second empty table switch to the end if port?

Yes, I had. MIssed putting it in the snapshot earlier.

Perhaps use loop end instead of variable loop end and connect end if port o the loop end one ?

1 Like

Hi @JPollet , I have quite a lot processing to be done if DB returns records and then write processed records into individual excel files . . If I use loop end instead of variable loop with end if output port connecting to next logical node, I will get exceptions in the intermediate process nodes due to no data

Ok, perhaps, I miss understand for this kind of processings :

At a glance, I’m not sure why you’re connecting both the flow variable from the Column Filter AND the End If nodes to the Variable Loop End. This shouldn’t be necessary, and might be “confusing” the Loop End and throwing the error. But it’s hard to know based on screenshots alone.

2 Likes

I think @ScottF is right. Remove the variable connection from column filter to loop end node
(and as he also pointed out with data it’s always easier to debug)
br

Thanks removed the flow variable from column filter to end if node , But having same issues