Alteryx Designer Desktop Discussions

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

Macro - What Type to Use

stapuff
9 - Comet

I have a list of about 20 tables I want to push though 3 joined tables (macro). These tables (data dictionary) retrieve the field names and descriptions, etc for the 20 tables.

 

I could see a use case for an output (yxdb) for each of the tables and a use case where the are unioned to a single yxdb.

 

Macros are something I do not have in my tool box yet. There are so many repetitive processes I could apply this approach to. 

 

Your thoughts, 

 

Thanks!

 

Puff

6 REPLIES 6
Thableaus
17 - Castor
17 - Castor

Hi @stapuff 

 

If you want to do the same process for the 20 tables you're working on, I recommend you to use a Batch Macro.

 

The Control Parameter Interface Tool will be your best friend and probably what you would use to update each table each time.

 

And you can either have an option to end your macro with an Output tool (that meaning you would generate an yxdb for each table) or you can end it with a Macro Output (which would union every table output in a single dataset) and then in your workflow, you would connect the Macro Output to an Output tool to generate a single .yxdb file.

 

Cheers,

stapuff
9 - Comet

I appreciate your response. I thought that was going to be the answer,  but I didn't see a option to output to a single file for each. 

 

Thank you for your response.  I am grateful for your guidance. 

 

Puff

Thableaus
17 - Castor
17 - Castor

@stapuff 

 

Imagine a Batch Macro like this. With an Output Tool at the end, no Macro Output at all

 

Thableaus_0-1583887042022.png

 

 

And then, a workflow would have a list of the tables that would go as your Control Parameter. 

 

Thableaus_1-1583887197180.png

 

 

Your Batch Macro would have no output at all in your main workflow. But at the end, if you have 3 tables for example, you would have 3 outputs, because each iteration would generate a .yxdb file inside your macro. So it would be a single file for each.

 

Understand what I mean?

If you need more examples, please let me know.

 

Cheers,

stapuff
9 - Comet

@Thableaus 

I appreciate your example and description. 

Took a step back to make my actual use case, which I will post later on so I can make sure we are talking apples to apples.

 

Thanks,

 

Puff

stapuff
9 - Comet

@Thableaus 

 

Attached is the copy of my workflow.

 

Not 100% complete because I want to add send email & logging the result to a db, etc.

 

If I understand you correctly....

 

If I want to create 1 yxdb for each batch run that blue circle on the far right would be a output as a yxdb. If not I would use an macro output tool?

 

The three 3 green boxes and 1 light blue would need to be changed out for dynamic inputs so I could modify the SQL Where and From Clauses, which would be passed to them.  I would then save this as a batch macro.

 

Use the input tool to pass the the table names to the macro tool, which would then run for every table name I have listed?

 

Is my understanding close?

 

Thanks,

 

Puff

 

 

 

stapuff
9 - Comet

@Thableaus 

 

With the exception of the use of the Control Parameter... I was able to successfully set up my workflow just like your example.

 

I appreciate your input and pictures. Both helped tremendously.

 

Puff

Labels
Top Solution Authors