Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Need to filter dynamically as per the string I want to pass

Naga
8 - Asteroid

Hi All,

 

I am looking for below solution and need help on this.

 

Requirement-

I have a 400+ tags in a xml / text file and I want to filter out only few tags / fields as per the testing needs. So I want to have a analytic app / workflow in which I / user will pass the required strings and it filters out from the input string I provide. For this I can accomplish using the normal filter tool, however, appreciate if you provide a better solution. I will take this solution as base and can modify and add as per my requirement.

 

Thanks
Naga

3 REPLIES 3
echuong1
Alteryx Alumni (Retired)

You can accomplish this with an action tool and a text box from the Interface tools. 

 

Essentially, the text input would prompt the user for a value when the workflow is run as an app. The action tool would update the value specified. In the example below, I have my workflow set up to filter where Customer ID is 2. The action tool is updating the operand (2) and replacing it with a value the user inputs.

 

echuong1_0-1582309001653.png

 

Let me know if that helps! If you post sample data I can mock up a workflow with it.

 

Naga
8 - Asteroid

Thanks for responding @echuong1 

 

Below is the sample input..

 

Record #Field
1<Employee>
2<EmployerID>
3<EmployeeID>
4<EmploymentStatus>
5<JobType>
6<DepartmentId>
7<Role>
8<Yrsofexperience>
9<Employee>
10<EmployerID>
11<EmployeeID>
12<EmploymentStatus>
13<JobType>
14<DepartmentId>
15<Role>
16<Yrsofexperience>

 

Expected output, where the criteria is dynamic as per the requirement

Record #Field
1<Employee>
2<EmployerID>
7<Role>
15<Role>

 

echuong1
Alteryx Alumni (Retired)

See attached for an example workflow. I cleaned the data using a data cleansing to make the filter a little easier, then joined the original records back.

 

The user would need to enter items to be filtered for in quotation marks and separated by commas. 

 

If this works for you, please mark as a solution.

Labels