dbTalk Databases Forums  

[BUGS] BUG #2286: Wrong index creation with cs_CZ locales and HYPHEN

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss [BUGS] BUG #2286: Wrong index creation with cs_CZ locales and HYPHEN in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
David Sauer
 
Posts: n/a

Default [BUGS] BUG #2286: Wrong index creation with cs_CZ locales and HYPHEN - 02-27-2006 , 11:16 AM







The following bug has been logged online:

Bug reference: 2286
Logged by: David Sauer
Email address: profa (AT) profa (DOT) cz
PostgreSQL version: 8.1.2, 8.1.3
Operating system: Linux (libc6), debian
Description: Wrong index creation with cs_CZ locales and HYPHEN
Details:

I have table:

CREATE TABLE m (i TEXT);
CREATE INDEX myidx ON m(i);

.... INSERT about 2000 values INTO m in the form
INSERT INTO m VALUES ('some-hack-1');
INSERT INTO m VALUES ('some-hack-2');
INSERT INTO m VALUES ('some-hack-3');
INSERT INTO m VALUES ('some-hack-4');
........ approx 2000 values with 'HYPHEN' (-)

VACUUM FULL ANALYZE;

now, the query:
SELECT * FROM m WHERE i = 'some-hack-4';

finds nothing ...

but:

SELECT * FROM m WHERE i || '' = 'some-hack-4';

finds expected row (but without index use, so it is slow).

The problem is between libc6 2.3.2 and libc6 2.3.6, definition files are
stored at:

http://img.123shop.cz/gimg/Popis/a.zip

Problem is probably in libc6 locales, but postgresql developer knows more
about libc6 ... (not true in opposite direction ?)

I'am running current version of debian linux, postgres 8.1.2 or 8.1.3
compiled myself. Feel free to contact me for more details.

Thank You,

David Sauer

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Reply With Quote
  #2  
Old   
Tom Lane
 
Posts: n/a

Default Re: [BUGS] BUG #2286: Wrong index creation with cs_CZ locales and HYPHEN - 02-27-2006 , 11:24 AM






"David Sauer" <profa (AT) profa (DOT) cz> writes:
Quote:
PostgreSQL version: 8.1.2, 8.1.3
Operating system: Linux (libc6), debian
Description: Wrong index creation with cs_CZ locales and HYPHEN
You've probably gotten bit by the 8.1.2 changes in locale-dependent
sorting. Try REINDEXing the affected indexes, as per the 8.1.2 release
notes.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.