Counter of Festivals

Ashok Blog for SQL Learners and Beginners and Experts

Thursday, 25 July 2019

The operation could not be performed because OLE DB provider “SQLNCLI11” for linked server was unable to begin a distributed transaction.


Issue:
When we tried to update table data, which uses triggers with linked servers
It will through error.




Solution:

To resolve this we should need to configure DTC(Distributed Transaction Coordinator)  Settings like below in both Source and Destination
RUN------------> dcomcnfg.exe
Expand "Component Services"
Expand "computers" >
Expand "My computer"
Expand "DTC"
Right click on the server and make the same config as below step for the "local DTC"
Place a check in the Network DTC Access and the Allow Inbound and Allow Outbound under the Transaction Manager Communication option.  We also selected No Authentication Required, as this was the way the other servers in the environment were configured.

Restart the DTC services from Services.msc





We should need to same config on source and destination
Issue fixed now

We can update data using linked server inside triggers as see below




Friday, 5 July 2019

Troubleshooting - Getting error A four-part name was supplied, but the provider does not expose the necessary interfaces to use a catalog or schema.

[QODBC-ALL] Troubleshooting - Getting error A four-part name was supplied, but the provider does not expose the necessary interfaces to use a catalog or schema.

Troubleshooting - Getting error A four-part name was supplied, but the provider does not expose the necessary interfaces to use a catalog or schema.

Problem Description:

I am using QODBC to fetch QuickBooks Data in SQL Server. I have created Linked Server in SQL Server.

We are receiving the following error when trying to fetch data.

The SQL is:
SELECT * FROM [QREMOTE].[QODBC]..[Company]

The error is:
Msg 7399, Level 16, State 1, Line 4
The OLE DB provider "MSDASQL" for linked server "QREMOTE" reported an error. The provider did not give any information about the error.

Msg 7312, Level 16, State 1, Line 4
Invalid use of schema or catalog for OLE DB provider "MSDASQL" for linked server "QREMOTE". A four-part name was supplied, but the provider does not expose the necessary interfaces to use a catalog or schema.

Solution:

You have used wrong SQL statement. You need to use LinkedServerName & table name in the query.

For Example:
Select * from YourLinkedServerName...TableName
SELECT * FROM [QREMOTE]...[Company]
 

 (0 vote(s))
 Helpful
 Not helpful