OLE DB provider "SQLNCLI" for linked server "MySQLServer01" returned message "String data, length mismatch".
Msg 7421, Level 16, State 2, Line 1
Cannot fetch the rowset from OLE DB provider "SQLNCLI" for linked server "MySQLServer01". .
So part of problem had to do with the fact that I was trying to join two bits of data from different servers. I had a join that tried to join a VARCHAR(30) field from one SQL Server to a NVARCHAR(MAX) field on another SQL Server. I know that this isn't going to be the fastest of JOINS but it was a requirement. Seems that there is a problem with joining the MAX to something in another server. Once I did a CONVERT(VARCHAR(30) to the VARCHAR(MAX) field, my query completed beautifully.I'm not sure how I would resolve this issue if I had to really join VARCHAR(MAX) to VARCHAR(MAX), but I guess I'll handle that in the future if that day comes.
2 comments:
Make it collation comaptible in linked server connection
I double checked the linked server connection and it is set to Collation Compatible = true. It was worth a try. Thanks for the idea though.
Post a Comment