Excel filesize increases when data exported from SSIS Package, how to control it using script task?

  • Hi

    I have SSIS Package which exports data from SQL Server to Excel. I drop the table we create in excel and recreate the table using Execute SQL Task.

    Whenever I run the package, the excel size increases gradually, but when I open the file and save it as is the filesize decreases. I had similiar problem in DTS and I used vbscript for this operation.

    Can anyone help me in writing a vbscript in .net which will use the script task in opening the excel file and saving it with the same name at same location.

    If there is any other way , let me know

    Thanks

  • Not sure why excel is not saving your data exported to it. You may try this

    1. Create a template excel file with you table (named range) in it

    2. In your package copy this template file to a new file

    3. Use data flow task to export data to this new file. Use Excel Destination for exporting data to excel (guess you are already using this).Use the named range values for column mapping.

    If you try this approach you will not have to drop and recreate your table.

    HTH

    ~Mukti

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply