That's not really possible in SSIS using build-in tasks.
The only way would be a .NET script task with a lot of .NET (C#/VB.NET) programming.
How to create table dynamically in ssis using the data from rows of flat file
I have a excel source with following fields:
I want to create table dynamically with First 4 rows having column name, data type & length. Eg for Decimal its (10,2).
Then import data from excel to SQL database with Data starting from Row No. 5.
How do I achieve the same?
Any help is appreciate.
Thanks
3 answers
Sort by: Most helpful
-
Olaf Helper 40,901 Reputation points
2022-01-12T14:45:44.477+00:00 -
ZoeHui-MSFT 33,126 Reputation points
2022-01-13T02:49:23.017+00:00 Hi @Anjali Shah ,
You may use Script Task to create table and load the data to the table.
Here is a similar blog you may have a check.
http://www.techbrothersit.com/2016/03/how-to-create-tables-dynamically-from.html
Regards,
Zoe
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
-
Anjali Shah 21 Reputation points
2022-01-13T05:25:29.393+00:00 Hey @ZoeHui-MSFT
Below is the link to the excel source file.
EUVwndvJuvlGrpxAMcWBA88Bddxe3bF0NO76Z2g_qkAEaAIt would be great if you can help!
Thanks.