Share

Cannot resolve the collation conflict between "SQL_Latin1_General_CP1_CI_AS" and "Latin1_General_CI_AI" in the equal to operation.


#SQL Error#SQL_Latin1_General_CP1_CI_AS

We have 3 solutions As below :

Solution-1 (Store Procedure Level)

Just Alter the database as below Query. so if any table having Different Collate so all are the same using Alter the Database.

ALTER DATABASE {Test} COLLATE SQL_Latin1_General_CP1_CI_AS;

*Note: Replace {Test} to Your Database Name.

Solution-2 (Query Level)

When are you using "=" Equal to sign in your Query please mention both side Left and Right

[Field Name][COLLATE][Collate Name] = [Field Name][COLLATE][Collate Name]

Ex.

SELECT Tags FROM dbo.AssignedTagMaster WHERE

ContactNumber COLLATE Latin1_General_CI_AI=@ContactNumber COLLATE Latin1_General_CI_AI  AND IsDeleted=0;

Solution-3 (Full Database Level)

Just create a new Instance for the same database & the Error resolved.

1