Re: agregates

Andrew Sullivan <andrew@libertyrms.info>

From: Andrew Sullivan <andrew@libertyrms.info>
To: pgsql-general@postgresql.org
Date: 2003-01-22T19:28:55Z
Lists: pgsql-general
On Wed, Jan 22, 2003 at 10:07:06AM -0700, David Blood wrote:
>  
> is there a better way to get the max - 1?

You could try ORDER BY paymentid DESC LIMIT 1 OFFSET 1.  That'll give
you the second from the top of the list, according to the order you
used.

A

-- 
----
Andrew Sullivan                         204-4141 Yonge Street
Liberty RMS                           Toronto, Ontario Canada
<andrew@libertyrms.info>                              M2P 2A8
                                         +1 416 646 3304 x110