export multiple tables data into multipule sheets in singlecsv file

SubbaReddy Kovvuru 1 Reputation point

From multipole stored procedure result into multiple sheets in csv files. each proc different meta data.

SQL Server Integration Services
SQL Server Integration Services
A Microsoft platform for building enterprise-level data integration and data transformations solutions.
2,467 questions
{count} votes

2 answers

Sort by: Most helpful
  1. ZoeHui-MSFT 33,551 Reputation points

    Hi @SubbaReddy Kovvuru ,

    CSV is a very simple format, and does not have the concept of a "sheet", so you could not load data into sheets in csv file.

    Excel should be more suitable.

    And it also depends on the metadata (structure) of the database tables.

    If all the tables with the exact same structure, we can use an Execute SQL Task to return the table names with an object variable. Then use a foreach loop container uses this object variable and contains a single data flow task. Otherwise you would need separate data flow tasks for each file. Because the metadata for a data flow cannot change during runtime in SSIS and it will be fixed at design time when you map from source to destination component.

    Useful links: Using-the-Foreach-ADO-Enumerator-in-SSIS




    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.

    0 comments No comments

  2. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.

    Comments have been turned off. Learn more