Re: highest match in group

From: "Dave [Hawk-Systems]" <dave(at)hawk-systems(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-general(at)postgresql(dot)org>
Subject: Re: highest match in group
Date: 2003-12-10 20:36:33
Message-ID: DBEIKNMKGOBGNDHAAKGNKELCHNAC.dave@hawk-systems.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>"Dave [Hawk-Systems]" <dave(at)hawk-systems(dot)com> writes:
>> have a data table that records entries by date(unix timestamp) and customer
>> number. each custnum will have several entries showing a running
>ledger type
>> snapshot. we have the need to get the most recent entry from not
>one, but all
>> unique customers, in the most cost effective manner.
>
>If you don't mind using a Postgres-only construct, SELECT DISTINCT ON
>is made for this. See the "weather report" example in the SELECT
>reference page.

thanks Tom, had a forest for the trees problem there and that put me on the
right track.

Dave

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Keith C. Perry 2003-12-10 20:39:11 Re: [NOVICE] PostgreSQL Training
Previous Message Ramesh Krishnan 2003-12-10 20:29:11 can someone point me to links for olap/multi-dimension database in postgresql site.