Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««123»»

Variant Order 2 Expand / Collapse
Author
Message
Posted Monday, December 5, 2011 5:23 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Thursday, November 27, 2014 4:23 AM
Points: 20,584, Visits: 9,624
L' Eomot Inversé (12/5/2011)
Pieter de K (12/5/2011)
Interesting... When I run the example on my SQL Server (Denali, CTP 3) the result is: A,D,B,E,C

That's startling. I don't have a modern (windows 7 or later) platform available to test on, but given that all the locales ids are different there should be no imaginable way for a new locale version to affect the order of these collations; the only thing I can thionk of is that some locale ids have been changed.

It would be useful if you could run the following code and post the results here, so that we can see what has happened in Denali to make this order change.
select cname CollationName, collationproperty(cname,'LCID') LCID 
from (values('bosnian_latin_100_ci_as'),
('corsican_100_ci_as'),
('latin1_general_100_ci_as'),
('norwegian_100_ci_as'),
('romansh_100_ci_as')
) X(cname)



He edited out his comment.

I've run the same thing on Denali CTP3 and it returns the same results as sql 2008 R2.
Post #1216217
Posted Monday, December 5, 2011 5:49 AM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Sunday, April 27, 2014 7:45 PM
Points: 1,589, Visits: 253
Good question and great explanation. I learned something new today. Thanks for submitting.

http://brittcluff.blogspot.com/
Post #1216234
Posted Monday, December 5, 2011 6:15 AM
Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Wednesday, September 17, 2014 1:32 PM
Points: 581, Visits: 733
Great question and great explanation. I can see how this could cause unexpected behavior. I definitely learned something today.

Thanks,

Matt
Post #1216247
Posted Monday, December 5, 2011 8:58 AM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Yesterday @ 10:32 PM
Points: 18,055, Visits: 16,087
Nice work on this one Tom.



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Post #1216371
Posted Monday, December 5, 2011 10:15 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Thursday, January 31, 2013 8:53 AM
Points: 1,176, Visits: 778
Thanks Tom for another great question. Another valuable lesson in an area rarely used by me in my day to day. Cheers mate!
Post #1216484
Posted Monday, December 5, 2011 10:22 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: 2 days ago @ 7:11 PM
Points: 7,920, Visits: 9,646
Ninja's_RGR'us (12/5/2011)
L' Eomot Inversé (12/5/2011)
Pieter de K (12/5/2011)
Interesting... When I run the example on my SQL Server (Denali, CTP 3) the result is: A,D,B,E,C

That's startling. I don't have a modern (windows 7 or later) platform available to test on, but given that all the locales ids are different there should be no imaginable way for a new locale version to affect the order of these collations; the only thing I can thionk of is that some locale ids have been changed.

It would be useful if you could run the following code and post the results here, so that we can see what has happened in Denali to make this order change.
select cname CollationName, collationproperty(cname,'LCID') LCID 
from (values('bosnian_latin_100_ci_as'),
('corsican_100_ci_as'),
('latin1_general_100_ci_as'),
('norwegian_100_ci_as'),
('romansh_100_ci_as')
) X(cname)



He edited out his comment.

I've run the same thing on Denali CTP3 and it returns the same results as sql 2008 R2.

Thanks for the good news, Remi; I was quite wondering what on earth could be going on, and it's nice to know that it was nothing.


Tom
Post #1216491
Posted Monday, December 5, 2011 10:25 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Thursday, November 27, 2014 4:23 AM
Points: 20,584, Visits: 9,624
L' Eomot Inversé (12/5/2011)
Ninja's_RGR'us (12/5/2011)
L' Eomot Inversé (12/5/2011)
Pieter de K (12/5/2011)
Interesting... When I run the example on my SQL Server (Denali, CTP 3) the result is: A,D,B,E,C

That's startling. I don't have a modern (windows 7 or later) platform available to test on, but given that all the locales ids are different there should be no imaginable way for a new locale version to affect the order of these collations; the only thing I can thionk of is that some locale ids have been changed.

It would be useful if you could run the following code and post the results here, so that we can see what has happened in Denali to make this order change.
select cname CollationName, collationproperty(cname,'LCID') LCID 
from (values('bosnian_latin_100_ci_as'),
('corsican_100_ci_as'),
('latin1_general_100_ci_as'),
('norwegian_100_ci_as'),
('romansh_100_ci_as')
) X(cname)



He edited out his comment.

I've run the same thing on Denali CTP3 and it returns the same results as sql 2008 R2.

Thanks for the good news, Remi; I was quite wondering what on earth could be going on, and it's nice to know that it was nothing.


HTH. You're still <somewhat> saine-ish .
Post #1216492
Posted Monday, December 5, 2011 10:51 AM


SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Yesterday @ 10:16 AM
Points: 1,949, Visits: 2,121
This all sounds like yet another reason to never use SQL_VARIANT columns in your database.
Post #1216514
Posted Monday, December 5, 2011 6:03 PM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Thursday, December 4, 2014 4:46 PM
Points: 2,012, Visits: 10,973
Great question. Not what I would have expected....but then, many aspects of SQLVariants are not what I would expect.



Rob Schripsema
Accelitec, Inc
Post #1216747
Posted Tuesday, December 6, 2011 12:08 PM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Monday, December 15, 2014 2:26 PM
Points: 5,466, Visits: 7,647
Rob Schripsema (12/5/2011)
Great question. Not what I would have expected....but then, many aspects of SQLVariants are not what I would expect.


Agreed, it's like opening Pandora's Box. I'm not even sure what led Tom to finding this nugget, nevermind how I'd go about finding the full answer if he hadn't spoon-fed me what was going on in a reasonable amount of time.

Variant can burn from everything I've been seeing on the complexity of its rulesets.



- Craig Farrell

Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.

For better assistance in answering your questions | Forum Netiquette
For index/tuning help, follow these directions. |Tally Tables

Twitter: @AnyWayDBA
Post #1217347
« Prev Topic | Next Topic »

Add to briefcase ««123»»

Permissions Expand / Collapse