December 8, 2009 at 1:21 pm
I have SQL 2005 EE. I have a process that read data from a database in MySQL.
In order to read the data I created a linked server like this:
EXEC sp_addlinkedserver
@server='GATEWAY',
@srvproduct='MySQL',
@provider= 'MSDASQL',
@datasrc='Gateway'
I read my data like this:
select * from openquery(gateway, 'select * from [Table]')
I didn’t have any problem at all with this, until we did some Windows updates and some reboots to our server. When I tried to run the query I get this error:
The OLE DB provider "MSDASQL" has not been registered.
When I register the dll file and run the query I get this error:
Msg 7308, Level 16, State 1, Line 1
OLE DB provider 'MSDASQL' cannot be used for distributed queries because the provider is configured to run in single-threaded apartment mode.
I checked my provider listing in SQL and I don’t have that one listed. I don’t know if the version of the .dll changes with the updates.
My SQL2005 is for 64bit. If this kind of provider isn’t working with this, why it was working before? And How I can connect to my MYSQL db to read the data?
Also I tried the providers: SQLNCLI and SQLOLEDB and nothing. I don’t have to much experience wit this kind of connections.
Any advice?
December 8, 2009 at 2:01 pm
I found a solution:
for some reason the ODBC connection was gone (i guess after the updates) and the provider as well. Just need to be reinstalled and configured
here is teh dll installation link
here is the Provider Instalation
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply