We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Pass more than 1 lists of columns to SQL queries where clauses in a huge workflow

anjali88
5 - Atom

Hi,

I have created a huge workflow with lots of different tools in Alteryx Designer for 1 employee_id belonging to 1 client_id. These employee_id and client_id are used in where clause of SQL queries.  I now want to run the workflow for 50 different combinations of client_id and employee_ids. Can you please help me automate this?

 

Sample of 1 SQL query:

select client_id, client_name, employee_id, salary
from db1.table_salary
where client_id= 1
and employee_id = 101

 

Sample of 2nd SQL query:

select client_id, client_name, employee_id, age
from db2.table_age
where client_id= 1
and employee_id = 101

1 REPLY 1
mbarone
16 - Nebula
16 - Nebula

Hi @anjali88 - a couple ways to do this - first we'll try the easy way - a Dynamic Input tool.  That should work, but if not, then there's the batch macro route.  For the Dynamic Input, you want to feed in the list of all your clt/ee ids.  And then in the configuration choose the option Modify SQL Query and Add "replace a specific string" (you'll need 2 of these obviously - one for clt one for ee).

 

Play around with that Dynamic Input tool and see if you can get it.  If not, post your configuration here and we'll help you get it working!

Labels
Top Solution Authors