strange problem
strange problem
Hi,
I don't know what is going on here. Maybe somebody can help.
Iam using postgresql 7.3.
ici=# select id,pseudonym from user_all where pseudonym = 'autologin_funkey';
id | pseudonym
----+-----------
(0 rows)ici=# select id,pseudonym from user_all where pseudonym ~ '^autologin_funkey$';
id | pseudonym
------+------------------
6881 | autologin_funkey
(1 row)ici=# update user_all set pseudonym = (select pseudonym from user_all where pseudonym ~ '^autologin_funkey$') where pseudonym ~ '^autologin_funkey$';
UPDATE 1
ici=# select id,pseudonym from user_all where pseudonym = 'autologin_funkey';
id | pseudonym
------+------------------
6881 | autologin_funkey
(1 row)Sebastian Böhm
Friendscout24.de
Re: strange problem
"Böhm, Sebastian (Vendor)" writes: > ici=3D# select id,pseudonym from user_all where pseudonym =3D > 'autologin_funkey'; > id | pseudonym > ----+----------- > (0 rows) > ici=3D# select id,pseudonym from user_all where pseudonym ~ > '^autologin_funkey$'; > id | pseudonym > ------+------------------ > 6881 | autologin_funkey > (1 row) That's pretty bizarre. Can you give a procedure for reproducing this from a standing start? regards, tom lane
Re: strange problem
Hi,
I did reindex, vacuum , dump/import, ...
I also tried 7.3.1-->> It happens only with btree index on that column, without index it works, with hash index also no problem.
This happend to 0.3% of all rows in this table, after dump/import exactly the same rows were affected.
Can somebody tell me how to import a 7.3(.1) dump into 7.2.3 ?
It gives errors on import, so I cannot try it on 7.2.3.Hope that helps.
Sebastian Böhm
Friendscout24-----Ursprüngliche Nachricht-----
Von: Tom Lane [mailto:tgl@sss.pgh.pa.us]
Gesendet: Mittwoch, 18. Dezember 2002 17:42
An: "Böhm, Sebastian (Vendor)"
Cc: 'pgsql-bugs@postgresql.org'
Betreff: Re: [BUGS] strange problem"Böhm, Sebastian (Vendor)" <sebastian.boehm@friendscout24.de> writes:
> ici=3D# select id,pseudonym from user_all where pseudonym =3D
> 'autologin_funkey';
> id | pseudonym
> ----+-----------
> (0 rows)> ici=3D# select id,pseudonym from user_all where pseudonym ~
> '^autologin_funkey$';
> id | pseudonym
> ------+------------------
> 6881 | autologin_funkey
> (1 row)That's pretty bizarre. Can you give a procedure for reproducing this
from a standing start?regards, tom lane
Re: strange problem
"Böhm, Sebastian (Vendor)" writes: > This happend to 0.3% of all rows in this table, after dump/import exactly > the same rows were affected. So you can reproduce the problem after dumping/reloading? If you could send me the dump file (off-list!) I'd be willing to investigate here ... regards, tom lane
Re: strange problem
Hi,
I installed an newer rpm of the glibc (2.2.2-8.1 / 2.2.2-4 before) und reinitialized the database with locale=C.
Just after installing the rpm, the problem was still there (reindex I did), but after dump/initdb --locale=C/import the problem was gone.
Dont know wheater it is the reinit with new glibc or the reinit with locale=C, dont have the time to figure it out.
(have to sleep now)Thank you for your help !
Sebastian Böhm
-----Ursprüngliche Nachricht-----
Von: Tom Lane [mailto:tgl@sss.pgh.pa.us]
Gesendet: Donnerstag, 19. Dezember 2002 00:18
An: "Böhm, Sebastian (Vendor)"
Betreff: Re: AW: [BUGS] strange problemThanks for sending the test data. Unsurprisingly, I don't see any
failure here:regression=# select id,pseudonym from test4 where pseudonym = 'autologin_funkey';
id | pseudonym
------+------------------
6881 | autologin_funkey
(1 row)but I was already suspecting a platform-dependent or locale-dependent
problem.Please update to glibc 2.2.3 or later, then rebuild (or at least
reindex) your tables, and let me know if you can still see a problem.regards, tom lane
Re: strange problem
"Böhm, Sebastian (Vendor)" writes: > I installed an newer rpm of the glibc (2.2.2-8.1 / 2.2.2-4 before) und > reinitialized the database with locale=3DC. > Just after installing the rpm, the problem was still there (reindex I = > did), > but after dump/initdb --locale=3DC/import the problem was gone. > Dont know wheater it is the reinit with new glibc or the reinit with > locale=3DC, dont have the time to figure it out. If I am correct in guessing that strcoll is to blame, then setting the locale to C would have made the problem go away. I am dubious that glibc 2.2.2-8 fixes the strcoll bug --- the notes I have say that that fix appeared in glibc 2.2.3. However, if you're happy running in C locale then it doesn't really matter whether strcoll works or not ... regards, tom lane