setting up if switch

Dear all,

please see attached workflow where I have two tables:

TEST with columns:
customer _id
Customer_StatGroupName

Destination / filter with columns:
key
filter

I have to loop for all records from table destination / Filter to set row filter conditions to table TEST.

So in run 1 I filter table TEST to Customer_StatGroupName = a; this runs ok
So in run 2 I filter table TEST to Customer_StatGroupName = b; this runs ok

I would like to except when filter condition = *
In this case no filtering is required; all records should been shown
test 7 to Knime.knwf (27.2 KB)
.

In general row filter node should only be executed when filtercondition != *.

I tried with If Switch / End Switch but unsuccessfully.

Do you have any hint for me?

Thx for help!

BR,

Heinz

Have you set the Wildcard Setting?

Then the “*” will be interpreted correctly.

Dear ActionAndi,

Thanks for your solution; it works for the example I sent to you.

In real life there are more nodes that should not be executed when filter = , e.g. sorting etc.
Therefore I want to use an if switch / end switch to devide workflow ito 2 parts: 1 for all filter !=
and one for filter =*.

I have problems setting up if switch to devide into this condition:
If CustomerStatGroupName !=* to be lead to one port in case of condition is true and in case of condition is false to the other.

Please see below diagram:

BTW: Rowfilter Dialog look differnt from the one you sent to me:

I am using latest Knime version with all updates installed.

BR,

Heinz

Yeah I’m sorry, I’m using sometimes older versions with the old User Interface.
You can try to use the “Rule Engine (Variable)” Node to switch branches of a “if/switch” node


Settings of the “Rule Engine”:

Settings of the “if-Node”

In case of a switch with multiple “choices” you can use instead of “top/Bottom” integer numbers like “0/1/2…”

here are the settings of the “Switch-Node”
image

Hope this helps

2 Likes

Thank you very much for support.

Have a nice weekend!

BR,

Heinz

1 Like