How to return T-SQL query with column names as first row

  • Why are you trying to add the header in SQL?  There's an option in SSIS in the flat file connection to add a header row with column names.

  • When I do that, I don't get the column names I assign in my SQL statement in the OLE DB Data Source; I get column names that the SSIS package randomly assigns in the Flat File Destination (Column1, Column2, etc.)

  • OK, I think I got it. If I create a csv file with column names ONLY and then link to a Flat File Connection Manager with Column names in the first data row checked, it works! Thanks!

Viewing 3 posts - 1 through 4 (of 4 total)

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