Quantcast
Channel: SQL Server Integration Services forum
Viewing all articles
Browse latest Browse all 24688

Need help: How to import csv file with inconsistent columns?

$
0
0

I have a csv file with the following columns:

A , B ,C ,D ,E

I would like to import records from only the following columns B and D excluding others, the data type is fixed for B and D.

The csv file can have inconsistent columns the next day which only shows:

B, D, E

or A, B, D

When using SSIS Flat File connection manager and point it to the csv file, I must add all the columns A,B,C,D,E

but when column A or C or E is missing the component failes due to mismatch in data type.

Is it possible to scan through the csv file header and select only columns B and D only? 

Note:

Column B and D are always available.

I appreciate any help, thanks in advance.


Viewing all articles
Browse latest Browse all 24688

Trending Articles