Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Collation Conflict


Collation Conflict

Author
Message
SQLbeginner
SQLbeginner
Valued Member
Valued Member (50 reputation)Valued Member (50 reputation)Valued Member (50 reputation)Valued Member (50 reputation)Valued Member (50 reputation)Valued Member (50 reputation)Valued Member (50 reputation)Valued Member (50 reputation)

Group: General Forum Members
Points: 50 Visits: 249
where specifically in the query should i use the Collate function?

I already have it in the middle part of the query.
homebrew01
homebrew01
SSCrazy
SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)

Group: General Forum Members
Points: 2988 Visits: 9071
SQLbeginner (10/7/2008)
where specifically in the query should i use the Collate function?

I already have it in the middle part of the query.


Anywhere you're comparing or joining between the 2 databases. Think of it like converting 1 collation to the other. So if DB_A is Collation_A, and DB_B is Collation_B then your code will be:

select DB_A.dbo.TableA, DB_B.dbo.TableB
from DB_A.dbo.tableA TbA
join DB_B.dbo.tableB TbB on TbA.FldA collate Collation_B = TbB.FldB

That converts FldA to B's collation



Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search