SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Import Excel into SQL Server using SSIS dynamically


Import Excel into SQL Server using SSIS dynamically

Author
Message
casanova
casanova
SSC Rookie
SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)

Group: General Forum Members
Points: 34 Visits: 149
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
Orlando Colamatteo
Orlando Colamatteo
SSCoach
SSCoach (15K reputation)SSCoach (15K reputation)SSCoach (15K reputation)SSCoach (15K reputation)SSCoach (15K reputation)SSCoach (15K reputation)SSCoach (15K reputation)SSCoach (15K reputation)

Group: General Forum Members
Points: 15611 Visits: 14396
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
casanova
casanova
SSC Rookie
SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)

Group: General Forum Members
Points: 34 Visits: 149
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 appreciatedSatisfied
We are good to close this post.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search