I have been trying to use the dtswizard.exe in SQL Server 2005 to import Excel 07 spreadsheets with no success.
Any idea how this can be done?
As a work around I have been importing the Excel 07 data into Access 07 and saving the database as the older mdb extension, THEN importing the mdb file into SQL Server 2005. Seems silly though.
To access native excel 2007 data, create an OLEDB connection manager (not an Excel connection) with the following connection string specific to the source file.
Data Source=c:\data\myfilehere.xlsx;Provider=Microsoft.ACE.OLEDB.12.0;Extended Properties="Excel 12.0;HDR=YES";
Access the spreadsheet in a dataflow using an OLEDB source with its select statement set to "select * from [Sheet1$]", replacing Sheet1$ with the name of the appropriate worksheet.
You will need the OLEDB provider, naturally, which comes with the install of Office 2007.
No comments:
Post a Comment