Share via

Load odd column data to local file

Su Si 60 Reputation points
2024-11-26T08:48:26.32+00:00

Is it possible to load odd column data from sql server table to flat file in ssis package?

SQL Server | Other
SQL Server | Other

Additional SQL Server features and topics not covered by specific categories

0 comments No comments

Answer accepted by question author

ZoeHui-MSFT 41,551 Reputation points
2024-11-26T09:01:54.7566667+00:00

Hi @Su Si,

When you create the source manager, you may use below command.

Select * from yourtable where (RowID % 2) = 1


If you do not have the RowID, you may use ROW_NUMBER().

Regards,

Zoe Hui


If the answer is helpful, please click "Accept Answer" and upvote it.

Was this answer helpful?

0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Olaf Helper 47,621 Reputation points
    2024-11-26T09:25:39.5866667+00:00

    Create a view with only that columns you want to export.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.