Cannot resolve the collation conflict between "Latin1_General_CI_AS" and "SQL_Latin1_General_CP1_CI_
- by Patrick Olurotimi Ige
I was writing a store proc for a report and i needed some data from another server
so i added a linked server to connect to this new db server.
when i do a select like below its all fine
select a,b,c from Server.DatabaseName.dbo.table
But when i use the table in a join i get the error
"Cannot resolve the collation conflict between "Latin1_General_CI_AS" and "SQL_Latin1_General_CP1_CI_AS" in the equal to operation."
I did check the collation set on the 2 databases and it was actually the same and had mo idea why i'm getting the error.
I later found out that you could specifically tell it to use a COLLATE
Just rewrite your join like this
on a.name COLLATE Latin1_General_CI_AS = eaobjname
Hope that helps and saves your precious time
Patrick