Friday, August 13, 2010

How to export data from Excel spreadsheet to Sql Server 2008 table

Programmer Question

I want to import data from an Excel file - assume Excel 2003 / .xls - to Sql Server 2008.



Have tried adding a linked server to the JET OLE DB Access driver, and of course it fails on the 64-bit machine.
But when I try to drop the linked server while experimenting, there's another error saying that the linked server already/still exists!



I have also tried changing the Excel driver to 32-bit (regedit tool) but am not sure if it's doing anything, same error is coming up!



Some more details:
Say Table1 in Excel file has 5 columns.
I want to map to Database.dbo.Table1 with 5 columns again, but with different names in table.
Is there a way to do even do such an import?



Find the answer here

No comments:

Post a Comment

LinkWithin

Related Posts with Thumbnails