Stanley Chan
Stanley Chan

Reputation: 41

Do I have to manually create the sink SQL table for a copy activity?

I am a newbie of ADF and start learning from the very basic copy activity between blob storage and SQL database in Azure.

My question is for a copy activity, do I have to manually create every sink SQL-tables in the SQL-database for all csv files in blob storage that may have different columns, even I can parameterize the input and sink source?

Besides, if my csv file have like 100 columns, do I also have to manually create each sink SQL tabls by:

CREATE TABLE table_name (
    column1 datatype,
    column2 datatype,
    column3 datatype,
   ....
    column100 datatype,
);

?

Upvotes: 2

Views: 4640

Answers (2)

Deniz Kizilca
Deniz Kizilca

Reputation: 59

In order to use the auto create sink table in other words the Auto create table option, table name in the Sink dataset should be entered. So;

  1. Click edit the sink dataset.

  2. Check "Edit" button as below. enter image description here

  3. Type the schema and table name to be auto created. In this step, there is no table created, only a name given.

  4. Go to your Copy data activity > Sink then check Auto create table option. enter image description here

Upvotes: 1

Anand Sowmithiran
Anand Sowmithiran

Reputation: 2920

You can utilise the auto create sink table feature, available in the Copy Activity in ADF. See the docs.

Upvotes: 0

Related Questions