Sunday, February 19, 2012

Error in accessing data via Linked Server

Hi,

I am trying to access the View through linked server connection .The linked server connection is between two sql server 2005.

The problem is I am not able to access 2 columns of nvarchar datatype of length 255, from the view through select statement.

I do a SELECT col1,col2 from VIEW,then getting the following error .

Cannot get the data of the row from the OLE DB provider "SQLNCLI" for linked server "SRVXPR". Could not convert the data value due to reasons other than sign mismatch or overflow.

Then I tried with

Select cast(Col1 as nvarchar) ,

cast(col2 as nvarchar) from VIEW,

I am able to get the values.

The collation type is same for all underlying tables and also for the servers.

Is there any restrictions in handling nvarchar data thru linked server/ anyother size limitation.

I don't want to use cast as this will lead to performance problem.

Thanks,

Philip


Seems as this is a problem of the OLEDB driver. You could send this to Microsoft as a BUG through the connect.microsoft.com portal, or in urgent cases call PSS to get the problem fixed.

HTH, Jens K. Suessmeyer.


http://www.sqlserver2005.de

No comments:

Post a Comment