Solved

collation on system tables

Posted on 2014-03-08
2
252 Views
Last Modified: 2014-03-10
how come this gives error?

Msg 468, Level 16, State 9, Line 2
Cannot resolve the collation conflict between "SQL_Latin1_General_CP1_CI_AS" and "SQL_Latin1_General_CP850_BIN" in the EXCEPT operation.

are system tables subject to collation too?


select name from VKDVUL.sys.all_objects where type = 'fn'
except
select name from VKDVUL1.sys.all_objects where type = 'fn'
0
Comment
Question by:25112
2 Comments
 
LVL 75

Assisted Solution

by:Anthony Perkins
Anthony Perkins earned 250 total points
ID: 39915260
are system tables subject to collation too?
Absolutely.  They acquire the same COLLATION as the database.

Incidentally, sys.all_objects is not a table.  It is a system VIEW.
0
 
LVL 35

Accepted Solution

by:
David Todd earned 250 total points
ID: 39916715
Hi,

Welcome to the world of similar collations that need to be explicitly cast.

I've found that unless there are very good (ie vendor documented) reasons, the collation on the database should be the same as the collation on the server. As tempdb collation follows that from Model, you can have issues comparing the results from temp tables vs your databases tables if the collations are different.

Also if you install a case insensitive collation for SQL 2000, the SQL authenticated passwords are case insensitive.

Regards
  David
0

Featured Post

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL 2008 with .NET 4.5.2 4 28
SQL Server 2012 rs - Field1 and Field2 add 1 to Total 4 18
export sql results to csv 6 34
MySQL Query Using Up Memory 6 22
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Along with being a a promotional video for my three-day Annielytics Dashboard Seminor, this Micro Tutorial is an intro to Google Analytics API data.
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

785 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question