sas12329
sas12329

Reputation: 97

Error while trying to read data from Excel

This is my SQL query:

SELECT *
FROM OPENROWSET('Microsoft.ACE.OLEDB.12.0',
                'Excel 12.0;Extended Properties=Excel 12.0;Database=D:\MyFolder\Shop\Activity_Utility.xls',
                'SELECT * FROM [RouteFlexField$]') 

I get an error:

Cannot process the object "select * from [RouteFlexField$]". The OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)" indicates that either the object has no columns or the current user does not have permissions on that object.

Can anyone tell me why?

Upvotes: 1

Views: 480

Answers (1)

Genish Parvadia
Genish Parvadia

Reputation: 1455

Solution 1

First you need to check whether you have installed the 2007 Office System Driver: Data Connectivity Components which is necessary for Microsoft OLEDB ACE 12.0 driver to work. So if you have not done that download it by clicking the link below.

2007 Office System Driver: Data Connectivity Components

Once you downloaded and installed it on your system restart your machine to see if the issue is resolved for you or not.

Solution 2

Description

Upvotes: 2

Related Questions