Search Postgresql Archives

Re: is this a bug or I am blind?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tom Lane wrote:
> Perhaps the fast-path check is a bad idea, but fixing this is not
> just a matter of removing that.  If we subscribe to strcoll's
> worldview then we have to conclude that *text strings are not
> hashable*, because strings that should be "equal" may have different
> hash codes.

By the way, I have always been concerned about the feature of Unicode 
that you can write logically equivalent strings using different 
code-point sequences.  Namely, you often have the option of writing an 
accented letter using the "legacy" single codepoint (like in ISO 
8859-something) or alternatively using accept plus "base letter" as two 
code points.  Collating systems should treat them the same, so hashing 
the byte values won't work anyway.  This is a more extreme case of 
"tyty" vs. "tty" because using a proper rendering system, those Unicode 
strings should look the same to the naked eye.  Therefore, I'm doubtful 
that using a binary comparison as tie-breaker is proper behavior.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux