Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Import Excel into SQL Server using SSIS dynamically Expand / Collapse
Author
Message
Posted Sunday, March 24, 2013 10:26 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, September 12, 2014 12:59 AM
Points: 10, Visits: 94
Hi Experts,

Can anyone explain me step by step how to import excel into SQL server database using SSIS dynamically and automate it (run the package on weekly basis)

Here are few conditions:
1. System folder remain constant but Filename can be anything
2. Report out if any additional fields are added to the excel data after the design.
3. Archive processed files to Processed folder
4. It should pick the latest excel in this folder.

Any help is highly appreciated
Post #1434681
Posted Sunday, March 24, 2013 11:52 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Yesterday @ 7:27 PM
Points: 7,107, Visits: 12,657
casanova (3/24/2013)
Hi Experts,

Can anyone explain me step by step how to import excel into SQL server database using SSIS dynamically and automate it (run the package on weekly basis)

Here are few conditions:
1. System folder remain constant but Filename can be anything
2. Report out if any additional fields are added to the excel data after the design.
3. Archive processed files to Processed folder
4. It should pick the latest excel in this folder.

Any help is highly appreciated

Condition 2 is going to be a tough requirement to meet with standard SSIS components. SSIS likes for the metadata to be defined at design-time. If anything is different at runtime SSIS is not easily adapted to pickup the changes.

If you can live without condition 2 then this may help:

Using the Script Task in SSIS to Process Data Files When They Arrive

Else, you may look into using the Excel Object Model in a Script Task to determine if structural differences exist in the spreadsheet.


__________________________________________________________________________________________________
There are no special teachers of virtue, because virtue is taught by the whole community. --Plato
Post #1434687
Posted Sunday, March 24, 2013 11:08 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, September 12, 2014 12:59 AM
Points: 10, Visits: 94
I dont mind ignoring the second condition as far as it satisfies the rest of them. Thank you so much for your help on this post. Much appreciated
We are good to close this post.
Post #1434748
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse