News


SQL Server and Sorting with Case Sensitive Collations

Make sure you understand how SQL Server treats Case Sensitive Collations.  It's very much a dictionary sort and not an ASCII sort.  What does this mean?  It means it sorts things aAbBcC, not ABCabc as you might expect.  So, if you do a WHERE value LIKE '[A-Z]%', you won't get all things that start with capital letters, you'll also get anything that starts with a lowercase b-z.

Details and example code can be found here.

  • Share This Post:
  • Share on Twitter
  • Share on Facebook
  • Share on Technorati
Thursday, June 07, 2007 5:54 PM

Feedback

No comments posted yet.


Post A Comment
Title:
Name:
Email:
Website:
Comment:
Verification: