I which distinct on ...
I wish distinct on ...
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-sql
Craig Ringer wrote:
b| n | stamp
A| 1 | 2008-09-20 06:07:47.981445 [1]
A| 1 | 2008-09-20 06:08:13.294306 [1]
A| 1 | 2008-09-20 06:12:02.046596 [1]
A| 2 | 2008-09-20 06:12:26.267786 [2]
A| 2 | 2008-09-20 06:12:47.75042
Hi,
I was looking for a simple solution to this problem. I can't find a way
to group on b and n by just collapsing sequential n's (identical n's
right next to each other) the sorting condition is the timestamp.
b| n | stamp
A| 1 | 200