1

I created a linked server to MySQL database server on my SQL Server database server. I tested the connection. It succeeded successfully for MySQL connection. I can see the databases on MySQL instance via my linked server but when i try to run a query with OPENROWSET, it gives me an error message like below. I have searched it on google many times but i couldn't solve my issue. What is the problem? Why do i get this message and how to solve it?

The OLE DB provider "MSDASQL" for linked server "(null)" reported an error. The provider reported an unexpected catastrophic failure. Msg 7330, Level 16, State 2, Line 25 Cannot fetch a row from OLE DB provider "MSDASQL" for linked server "(null)".

1 Answer 1

0

I had same issue once, You may need to recreate the linked server with this set to false (or just change it in the linked server properties->server options):

EXEC master.dbo.sp_serveroption @server=N'servername', 
    @optname=N'remote proc transaction promotion', @optvalue=N'false'

Additionally, try using OPENQUERY to run this against the link

syntax:

OPENQUERY ( linked_server ,'query' )  

and example SQL:

SELECT * FROM OPENQUERY(server_name,'SELECT * FROM table_name');
2
  • Unfourtunately, i got the error message below : ** The OLE DB provider "STREAM" for linked server "(null)" reported an error. The provider reported an unexpected catastrophic failure. Msg 7330, Level 16, State 2, Line 1 Cannot fetch a row from OLE DB provider "STREAM" for linked server "(null)". **
    – DBA
    May 27, 2020 at 8:56
  • What is the catastrophic failure? :/ The provider reported an unexpected catastrophic failure.
    – DBA
    May 27, 2020 at 8:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.