Monday 13 December 2021

Multi flat file connection manager in SSIS

 The multi flat files connection manager in SSIS works very much like the familiar flat file connection manager. Only Difference between them like Flat file connection manager takes single file and Multi flat files connection connect to multiple files at a time.

With this file connection we can load the multiple flat files or CSV files into the database. It Works similar to Foreach loop container.

Below are the files.

 

We can load these file as below method.

·         Using Multi flat file connection manager

·         Using Foreach loop container (File enumerator)

·         Creating connection manager for each files (Not recommended)

In this demo we will see How to load the multiple CSV files using Multi flat file connection manager.

Selecting Multi flat file connection manager.

  

Click on this.

  

Keep in mind file names we need to give the directory with a file name wildcard (such as *.CSV).

 Now we are taking the Data flow task and taking source as Flat file Source.  


See the columns. 

Now taking Destination as OLEDB destination.

Creating the connection manager and doing the columns mapping.

  

Now our package is ready to run.

Before run this package records in the staging table.

   


Running this package.

  

Package executed successfully.

  


All 10 files loaded successfully.

See the records in the table.

 

Next post we will see how to load these files using Foreach loop container.

Read Here: Load Multiple CSV fileusing Foreach loop container

https://bageshkumarbagi-msbi.blogspot.com/2021/12/load-multiple-csv-file-using-foreach.html

 Thanks for reading!

J  

No comments:

Post a Comment

If you have any doubt, please let me know.

Popular Posts