Re: Help with SQL staterment - Mailing list pgsql-novice

From Steve Crawford
Subject Re: Help with SQL staterment
Date
Msg-id 4E0D057D.6040809@pinpointresearch.com
Whole thread Raw
In response to Re: Help with SQL staterment  (Thom Brown <thom@linux.com>)
Responses Re: Help with SQL staterment  (Thom Brown <thom@linux.com>)
List pgsql-novice
On 06/30/2011 04:04 PM, Thom Brown wrote:
> SELECT DISTINCT ON (contactkey)
>      paymentkey, contactkey, paymentdate
> FROM
>      my_table
> ORDER BY
>      contactkey, paymentdate DESC
Gives the same result as my example but your solution is much cleaner.

Cheers,
Steve


pgsql-novice by date:

Previous
From: Thom Brown
Date:
Subject: Re: Help with SQL staterment
Next
From: Thom Brown
Date:
Subject: Re: Help with SQL staterment