Alteryx Designer Desktop Discussions

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

Copy tables from one database to another

saqib
8 - Asteroid

I have a list of tables that need to copied from one database to another. The list resides in the table in a DB. I am trying to write a Standard Macro to perform this. This is what I have so far.

 

The macro reads the in list of tables and then reads that using the Dynamic Input. But I am unsure how to write the tables to the second DB. Please advise.

 

Screen Shot 2018-06-21 at 5.05.23 PM.png

3 REPLIES 3
BenMoss
ACE Emeritus
ACE Emeritus

Are the tables all of the same schema? Or is each table unique?

 

If the latter then I think you are going to need a batch macro.

 

Ben

saqib
8 - Asteroid

@BenMoss, they are different schemas. Do you have any examples on how I can implement this? I am fairly new to batch macros.

BenMoss
ACE Emeritus
ACE Emeritus

https://community.alteryx.com/t5/Alteryx-Knowledge-Base/CS-Macro-Dev-Reading-in-multiple-files-with-...

 

The macro in this post shows something very similar (batch.yxzp), but instead of having a macro output within your batch macro you will have your output data tool, and use the value passed into the control parameter to overwrite the value on the input tool (so it loops through all of the input tables) and also overwrite the table name in the output tool, so you write a new table per batch.

 

Check this out. try and apply it and let us know where you get stuck.

 

Ben

Labels