Hard time creating multiple selection filter on SQL Query Reader

Hello everyone,

I’m new to the KNIME kommunity and the tool itself. I’m trying to understand how it works on the example database “Northwind”.

I created some visualizations and now would like to add some filters but there I hit a blocker. I tried setting up Multiple Selection Widget, added values to “Possible Choices” that correspond to product categories in the database (in this format):

“Beverages”

“Condiments”

“Confections”

“Dairy Products”

“Grains/Cereals”

“Meat/Poultry”

“Produce”

“Seafood”

Then I try to assign the variable to the SQL Query Reader:

SELECT

products

FROM “order_details”

JOIN “orders” ON “orders”.“orderid” = “orderdetails”.“order_id”

JOIN “products” ON “orderdetails”.“productid” = “products”.“product_id”

JOIN categories ON products.categoryid = categories.categoryid

WHERE categories.categoryname IN $${Sproductcategory}$$

But there is an error. I tried several things, changing the variable in SQL statement:

$${Sproduct_category}$$

‘$${Sproduct_category}$$’

“$${Sproduct_category}$$”

($${Sproduct_category}$$)

Finally it didn’t throw an error with this SQL statement:

WHERE categories.categoryname IN (‘$${Sproductcategory}$$’)

But I get an empty table as the result.

Any ideas?

Thanks in advance :slight_smile: