Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2012 Forums
 Transact-SQL (2012)
 Columns in View generated with wrong Collation

Author  Topic 

SuperJB
Starting Member

12 Posts

Posted - 2014-04-22 : 05:32:43
Hello everyone.

I have database (Db-A) with default Collation "Latin1_General_CI_AS".
I've created a view (vw-A) that simple reads info from a table in another database (Db-B). This database also has the same default collation "Latin1_General_CI_AS".

I've double checked every column in the table, one by one to make sure the correct Collation is set.

ISSUE: The columns in the view in Db-A, set the column Collation to "Latin1_General_CI_AI".

Can anyone help me out on figuring out why? For now I've "hardcoded" each column in the tsql to use the intended Collation, but it won't solve the issue for any other View I create.

Thanks in advance.


JB

SuperJB

Lamprey
Master Smack Fu Yak Hacker

4614 Posts

Posted - 2014-04-22 : 12:01:55
Hard to say, but if the Default is one thing and the columns are another, I'd say that someone over road the default when creating the tables/columns. I think if you change the default collation then SQL will update the text columns to match (not 100% sure about that).
Go to Top of Page
   

- Advertisement -