Re: Sorting and then...

From: Jason Earl <jdearl(at)yahoo(dot)com>
To: wweng(at)pobox(dot)com, pgsql-sql(at)postgresql(dot)org
Subject: Re: Sorting and then...
Date: 2001-04-10 17:32:13
Message-ID: 20010410173213.72791.qmail@web10006.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

SELECT name FROM test ORDER BY id DESC LIMIT 10;

Take care,
Jason

--- Wei Weng <wweng(at)kencast(dot)com> wrote:
> Suppose I have a table
>
> create table test
> (
> id integer,
> name text
> );
>
> And I want to get the names of the largest 10 "id"s.
> How can I do that in
> sql?
>
> Thanks!
>
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 2: you can get off all lists at once with the
> unregister command
> (send "unregister YourEmailAddressHere" to
majordomo(at)postgresql(dot)org)

__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.
http://personal.mail.yahoo.com/

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Mark Butler 2001-04-10 18:02:13 Semantics of Typed Numeric Constants
Previous Message Albert REINER 2001-04-10 16:38:15 Re: Re: select substr???