How to switch from one condition to another.

Hi Team,

I have Two Excel files with 3 different Tabs, i am trying to use 2 Reference column filter to extract selected fields. One with Values and one without Values.
In some cases one of the Reference Column Filter will not have Values, right after the selection i am using Loop and using Current Column Variable as a field. As one of the field is Reference column filter is blank its throwing error in Loop.
Please help me to find a solution for the issue.

Thank you,
Sai Akula.

You can use either the Case Switch / IF Switch or possibly the Empty Table Switch (assuming the issue is caused by a completely empty table) to solve this.

Hi,

Thanks for your response.

i have using If Switch and Empty table Switch but i was unable to figure it out.
Could you please help me with any example Workflow.

Thank you.

There are some generic ones available for reference on the public hub like this that should help show how to make a rule trigger the case switch. If you want specific help, then you can upload a workflow with some dummy data in it. Be sure to uncheck the box that asks about resetting the workflow.

1 Like

will this work if their is a Loop??
In the below Example as you can see the reference column filter doesn’t have any field. In Column Loop Start we dont have any columns we are unable to proceed to next step.

Below in Column Expression i am taking Current Column for checking and its throwing error.
image

i tried Constant Value column but it will only give us a default value but not the current column in use.

1 Like

Just use the Column Rename (Regex) for this and it will bypass the problem. You don’t even need to use “regex” for this one. Just enter the old column name into the “Search String (regexp)” spot, and the new column name in the “Replacement” spot. It will not fail if a column name is not present.

If you are feeding through 1 column at a time and want to rename that one column then enter .* into the “Search String (regexp)” spot. If more than one column are present it will add (#1), (#2), etc to the end of the renamed columns. You can also control the values via flow variable if necessary.

1 Like

If you are attempting to Re-Map a large number of column names to match another table structure, then you can try out my interactive view based component if you like. I use it for organizing a large scale re-mapping of column names. The top input is the data table and the bottom input is the list of the new column headers for dropdown selection (Vertical list = Advanced Mode, standard table with Horizontal headers = Basic Mode). Once you apply the change, it pulls the selected column names out of the dropdown options. It also blocks duplicate assignments if you attempt to apply a large number of changes at once. There are a lot of advanced options like sorting / ensuring column presence / settings backup & recovery / dropdown filtering / and so on, but it has plenty of capabilities without touching them.

You may need to right click on it and select “reset” to get it to execute and refresh to your new column names on the initial setup in advanced mode.

1 Like

Hi,

Thanks you for your reply, i was able to solve the issue using the below method.
image

Thanks for your help,
Sai A.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.