Link to home
Start Free TrialLog in
Avatar of Mike Littlewood
Mike LittlewoodFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Trying to run a query across multiple server with incorrect collation settings

I am trying to run a select statement across a linked server where the join is based on a field of the same type (char) on both databases, but one of the database I believe was setup incorrectly a long time ago and I have no ability to change it

SELECT t1.xxx, t2.xxx, t2.xxx
FROM table1 t1
JOIN table2 t1 on t1.code = t2.code

The error I am getting is
"Cannot resolve collation conflict for equal to operation."

Is there anyway of adding a collation type to the select statement so thay I can compare correctly?
Or is there anything else I can do

Thanks
ASKER CERTIFIED SOLUTION
Avatar of matrix_aash
matrix_aash
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Mike Littlewood

ASKER

Sorry my bad I should have written that in as I am already

SELECT t1.xxx, t2.xxx, t2.xxx
FROM table1 t1
JOIN serverlink.cat1.dbo.table2 t1 on t1.code = t2.code