I have been trying unsuccessfully to link my excel file to SQL server like I used to with SQL 2005.
In SQL 2008R2 I have installed the 64-bit data access components from Office 2010 to get the provider 'Microsoft.ACE.OLEDB.12.0' avilable.
When I try this command:
*FROMOPENDATASOURCE('Microsoft.ACE.OLEDB.12.0','Data Source="E:\ADUpdates\Employee List1.xlsx"; Extended properties=Excel 12.0')...[Sheet1$]
I get this error:
Msg 7399, Level 16, State 1, Line 1
The OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)" reported an error. Access denied.
Msg 7301, Level 16, State 2, Line 1
Cannot obtain the required interface ("IID_IDBCreateCommand") from OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)".
The Access Denied error seems to be form the worksheet and not the file itself. Evidence is that if I enter a bogus sheet name it tells me the sheet doesn't exist and after this error the file is locked open and can't be saved again from Excel until the
query windows is closed. The sheet is not protected in Excel so I don't know how access to it can be denied.
Does anyone actually have this working in SQL 2008R2?