pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: John Scalia <jayknowsunix@gmail.com>
To: David G. Johnston <david.g.johnston@gmail.com>
Cc: Albe Laurenz <laurenz.albe@wien.gv.at>
Cc: pgsql-admin@postgresql.org <pgsql-admin@postgresql.org>
Subject: Re: string not equal query, postgresql 9.4.4
Date: Thu, 17 Sep 2015 19:52:57 -0500
Message-ID: <55FB6069.3030108@gmail.com> (raw)
In-Reply-To: <CAKFQuwawTZkzW75hfU_shS-_uEW7AGw83b_G0ZuWNc6+TFLcXw@mail.gmail.com>
References: <55FA13F1.7060204@gmail.com>
	<A737B7A37273E048B164557ADEF4A58B50FA82A0@ntex2010i.host.magwien.gv.at>
	<CABzCKRAdrgi+feKz6nCzNx_4P7xDoJ-G+pL3UQ4f9+C+VtGQGQ@mail.gmail.com>
	<A737B7A37273E048B164557ADEF4A58B50FA85B6@ntex2010i.host.magwien.gv.at>
	<55FB3C42.6030301@gmail.com>
	<CAKFQuwawTZkzW75hfU_shS-_uEW7AGw83b_G0ZuWNc6+TFLcXw@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>

On 9/17/2015 6:49 PM, David G. Johnston wrote:
> On Thu, Sep 17, 2015 at 6:18 PM, John Scalia <jayknowsunix@gmail.com <mailto:jayknowsunix@gmail.com>>wrote:
>
>
>     SELECT * FROM results where result <> 'PASS';
>
>     and it produced all the rows, not just the ones beginning with visc60 that I expected. Based on what you had written, I should have seen the correct output. So, any ideas?
>
>
> ​ EXPLAIN ANALYZE SELECT * FROM results WHERE result <> 'PASS';
>
> What happens when you run the following?  Do you see the same incorrect behavior?
>
> WITH vals (v) AS (
> VALUES ('PASS'::char(4)), ('FAIL'::char(4))
> )
> SELECT 
> ​ DISTINCT ​
> *
> FROM vals
> WHERE v <> 'PASS'::char(4);
>
> David J.​
>  
I tried your code above, and some additional queries prior to your message arriving, and I see now why I'm still getting multiple row beyond my original expecting. Carefully
looking at the rows being produced showed that each instrument is performing a powerup test and all those passed. I guess I was just expecting too much from distinct and I
understand why. I just need to add a second where clause if I can figure out how to make the powerup test clearly indicated as such in the table.

Thanks for everyone's help, I should have examined the automated data collection more closely.
--
Jay

view thread (8+ messages)  latest in thread

Message-ID: <55FB6069.3030108@gmail.com>
Permalink:  ../55FB6069.3030108@gmail.com/
Also on:    postgresql.org/message-id/55FB6069.3030108@gmail.com

 · 

reply

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-admin@postgresql.org
  Cc: jayknowsunix@gmail.com, david.g.johnston@gmail.com, laurenz.albe@wien.gv.at
  Subject: Re: string not equal query, postgresql 9.4.4
  In-Reply-To: <55FB6069.3030108@gmail.com>

* 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