I get the error message 'Cannot resolve collation conflict for equal to operation.' when I run the following query (abbreviated for ease) which attempts to link two tables, one of which is on a linked server:DECLARE @ProjectCode varchar(10)SET @ProjectCode = 'DETO006'SELECT dl.ref2, ca.AttributeNameFROM oas_docline dl LEFT JOIN DEGWLONSRV4.Icorp.dbo.Cons_Attribute ca ON dl.ref2 = ca.AttributeId WHERE dl.el2 = 'P' + @ProjectCode AND dl.doccode = 'TIMESHEET' AND ca.AttributeTypeId=2GROUP BY dl.ref2, ca.AttributeName
The relevant columns in the tables are defined as follows:oas_docline:el2 - varchar(72)ref2 - varchar(32)
DEGWLONSRV4.Icorp.dbo.Cons_Attribute:AttributeId - varchar(20)AttributeTypeId - intAttributeName -varchar(50)
I realise that this has to do with different collation being used on the two servers: the collation on the main database is SQL_Latin1_General_CP850_CI_AI whereas the collation on database on the linked server is SQL_AltDiction_CP850_CI_AI; both servers are SQL 2000.Is there a way around this?Many thanks for your help.Alan