Brody
Brody

Reputation: 1

Importing multiple Flat Files into Single OLE DB Table destination(all files have different columns for table)

I am currently working on creating an SSIS package for a new import files we will received. The company changed how it was before - 1 flat file for 1 table. Now they have there data scatted across multiple files for 1 table.

I have 2 data flow tasks of the 12 that I am fiddling with trying to get to work correctly. --1 has 5 files to 1 db destionation --1 has 3 files to 1 db destination.

Each file does have a consistent key (Property_ID) that I am using for sorting. Current setup of a flat file data flow task is:

I have tried all join types for the merge join and am still having problems getting the data into the table correctly.

Each file has different columns for the specified destination table aside from the "Property_ID"

The current results I am receiving are Just rows of data with data from only 1 flat source file and not the others.

Any assistance is greatly appreciated.

UPDATE

I did solve this problem.

What I did was combine 2 files into a merge after each was sorted on a key.

After that, the merge was put into a merge join as the right table where the left join table was the other solo flat source file that would actually have the main sorting key to go into the tables.

The merge join was then sorted on the same sortID all files have been used on directly to the ole db destination.

Upvotes: 0

Views: 1895

Answers (1)

Brody
Brody

Reputation: 1

What I did was combine 2 files into a merge after each was sorted on a key.

Flat Source DataConversion Sort Merge Join(The left table is the table that has the main id's I want to match)

This goes into a Merge Join that is from the solo Flat Source File; Flat Source DataConversion Sort ToAboveMerge Join

The merge join was then sorted on the same sortID all files have been used on directly to the ole db destination.

Upvotes: 0

Related Questions