Re: ALL() question - Mailing list pgsql-sql

From Richard Huxton
Subject Re: ALL() question
Date
Msg-id 473AF646.2010307@archonet.com
Whole thread Raw
In response to Re: ALL() question  (Julien Cigar <jcigar@ulb.ac.be>)
List pgsql-sql
Julien Cigar wrote:
> I finally found a solution:
> 
> SELECT specimen_id 
> FROM specimen_test_bits 
> GROUP BY specimen_id 
> HAVING array_accum(test_bit_id) =  '{2,3,4}';
> 
> .. but I don't think it's very "clean" ..

The key question is whether you can rely on getting (2,3,4) or whether 
you might get (4,3,2) or some other ordering.

--   Richard Huxton  Archonet Ltd


pgsql-sql by date:

Previous
From: Richard Huxton
Date:
Subject: Re: ALL() question
Next
From: hubert depesz lubaczewski
Date:
Subject: Re: ALL() question