Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.

General Discussions has some can't miss conversations going on right now! From conversations about automation to sharing your favorite Alteryx memes, there's something for everyone. Make it part of your community routine!

SOLVED

Dynamic Filter for multiple values?

eaphymao
7 - Meteor

I have 2 columns of data. The first is essentially an ingredient list.

 

For example a values will be like 40% corn, 30% flour, 10% oil, 5% apples etc

 

The 2nd column is a dynamic list the user will update periodically on what I want to filter on

 

For example

 

Apples

Oranges

Flour

Quinoa

 

What I want to do is check the values in the 1st column to see if it contains any of the values in my 2nd column and keep those rows. My first challenge is the values in the first column are not standardized so the syntax (eg flour won't just be flour it'll be gluten free flour) & location (from the 1st ingredient listed to the last) of the values i want to filter constantly change. The 2nd is the list of values I want to filter on will constantly change as well. 


Any ideas how I can do this? It'd be great if I could do some sort of conditional join tool 

ImadZidan
12 - Quasar

Hello @eaphymao ,

 

I hope I understood you correctly.

Please see attached.

vizAlter
12 - Quasar

Hi @eaphymao — Can you attach sample data for input and desired output, both?

seinchyiwoo
Alteryx
Alteryx

Hi,

 

Using an iterative macro workflow that I've built a few months back for another use case, it seems to also work for your use case.

If you take a look at the attached workflow, just simply ignore the header name for both datasets (I did not bother to change it for now and simply want to test out if it works for your data). I change the data to your data for both input data, run the workflow and it will try to loop through the dynamic list (input_data_2) and see if a particular item is found.

As an output, you can see that every category that can be found from input_data_2 will be concatenated as the last column:

seinchyiwoo_0-1601271377853.png

Let me know if this is what you want?

 

Best,

Seinchyi

 

eaphymao
7 - Meteor

This works! I was wondering if there was some way to do it without an interative macro, but I guess you can't get away from loops. 

Labels