From: Maximilian Tyrtania <maximilian.tyrtania@onlinehome.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-sql@postgresql.org
Subject: Re: Distinct oddity
Date: Wed, 13 May 2009 14:37:43 +0200
Message-ID: <C6308BB7.3611D%maximilian.tyrtania@onlinehome.de> (raw)
In-Reply-To: <6111.1241879627@sss.pgh.pa.us>
am 09.05.2009 16:33 Uhr schrieb Tom Lane unter tgl@sss.pgh.pa.us:
> What you need to do is
> dump out the *entire* results of the DISTINCT queries and look for the
> unmatched lines. I'd try dumping to two files, stripping the 'e' with
> sed, and then sort/diff.
Okay, that's what I did, and the results are, well, surprising (for me, mind
you).
FAKDB=# \o /withapp
FAKDB=# select distinct f.bezeichnung||'$' from firmen f order by 1;
FAKDB=# \o /withoutapp
FAKDB=# select distinct f.bezeichnung from firmen f order by 1;
Opened those files (with textwrangler, as I 've never used sed), stripped
off the '$', sorted and looked at the differences (using textwranglers
"compare documents"-feature).
The file "withoutapp" has those lines:
"Abendschau"
"Abendschau"
They don't look distinct to me. The "Abendschau"-Entry appears only once in
"withapp". But then again the "withapp" file has these entries:
Adformatie
Adformatie
which in turn only appear once in "withoutapp". I turned "show invisibles"
on in textwrangler, so I don't think there is some gremlin business going
on.
Actually I'm interested in but in no way dependant on what's going on here,
I just thought as a good pg-citizen I should report whatever might be wrong.
Best,
Maximilian Tyrtania
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: maximilian.tyrtania@onlinehome.de, tgl@sss.pgh.pa.us
Subject: Re: Distinct oddity
In-Reply-To: <C6308BB7.3611D%maximilian.tyrtania@onlinehome.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox