Friday, January 27, 2012

'' = 'ss' - are they equal?

Alex,
http://www.ureader.com/message/1343195.aspx has a conversation on this
subject you may find useful.
Most languages (especially English) have a fair number of homographs, which
are words spelled the same but with different pronunciations and meanings.
"Wind" can mean 'moving air' or 'tightening a spring', etc. I think that
you have probably run into this with your German words.
RLF
"Axel Dahmen" <KeenToKnow@.newsgroup.nospam> wrote in message
news:OP2PAHwQIHA.2396@.TK2MSFTNGP02.phx.gbl...
Hi,
I've set up an NVARCHAR table column having a UNIQUE constraint. This UNIQUE
constraint is supposed to keep double entries from being entered into that
column. So far so good...
In my new project I'm quite baffled about the fact that SQL Server 2000
seems to believe that '' and 'ss' are identical!
This assumption is only true for special cases. The German words "Mae" and
"Masse", for instance, have totally different meanings ("measures",
"mass"/"crowd").
How can I set up my table column definition (COLLATE perhaps?) in SQL Server
2000 to have it regard '' and 'ss' being distinct characters?
Your help is quite appreciated.
Best regards,
Axel Dahmen
Axel,
I imagine from the ANSI-SQL docuements that SQL is tracking with the ISO
standard on this. I see that the ISO collation standard was updated in
2007, but I am not willing to pay to find out what changed.
http://www.iso.org/iso/iso_catalogue/catalogue_tc/catalogue_detail.htm?csnumber=44872
So, I don't know who to ask to get a good answer for you about what SQL is
doing. (Maybe Joe Celko has an update.)
In the meantime, if is worth the extra work for you, you can use this
workaround.
SELECT * FROM Composers
WHERE LastName = 'Strau'
AND LastName COLLATE Latin1_General_BIN = 'Strau'
The extra binary collation compare will ensure that you get 'Strau' and do
not get ' Strauss'.
RLF
"Axel Dahmen" <KeenToKnow@.newsgroup.nospam> wrote in message
news:%23EJWJu4QIHA.5400@.TK2MSFTNGP04.phx.gbl...
Great, Russel, thanks!
From the conversation you mentioned I've learned that according to DIN and
ANSI-SQL "" equals to "ss". But in fact this isn't true anymore since
German has been updated to new spelling rules a few years ago.
With the spelling reform we've got they changed the meaning of "". It has
now become a letter of its own and is no more a replacement for "ss". They
are even planning to introduce a new, "capital " letter.
With the old spelling rules words like "Mae" were equal to "Masse". But
nowadays this isn't true anymore.
Are there any plans to update ANSI-SQL and SQL-Server collation rules
according to current German rules?
TIA,
Axel Dahmen
"Russell Fields" <russellfields@.nomail.com> schrieb im Newsbeitrag
news:e6VOWBxQIHA.4180@.TK2MSFTNGP06.phx.gbl...
> Alex,
> http://www.ureader.com/message/1343195.aspx has a conversation on this
> subject you may find useful.
> Most languages (especially English) have a fair number of homographs,
> which
> are words spelled the same but with different pronunciations and meanings.
> "Wind" can mean 'moving air' or 'tightening a spring', etc. I think that
> you have probably run into this with your German words.
> RLF
>
> "Axel Dahmen" <KeenToKnow@.newsgroup.nospam> wrote in message
> news:OP2PAHwQIHA.2396@.TK2MSFTNGP02.phx.gbl...
> Hi,
> I've set up an NVARCHAR table column having a UNIQUE constraint. This
> UNIQUE
> constraint is supposed to keep double entries from being entered into that
> column. So far so good...
> In my new project I'm quite baffled about the fact that SQL Server 2000
> seems to believe that '' and 'ss' are identical!
> This assumption is only true for special cases. The German words "Mae"
> and
> "Masse", for instance, have totally different meanings ("measures",
> "mass"/"crowd").
> How can I set up my table column definition (COLLATE perhaps?) in SQL
> Server
> 2000 to have it regard '' and 'ss' being distinct characters?
> Your help is quite appreciated.
> Best regards,
> Axel Dahmen
>
>

No comments:

Post a Comment