Re: query problem - Mailing list pgsql-general

From will trillich
Subject Re: query problem
Date
Msg-id 20010326023815.B18494@mail.serensoft.com
Whole thread Raw
In response to query problem  ("Gyan" <gyan@noida.hcltech.com>)
List pgsql-general
On Fri, Mar 23, 2001 at 02:21:24PM -0000, Gyan wrote:
> Greetings!  Kindly lemme know how do u sort a table on some
> field...please talk about the command that does it.  Thanx.

the sorting is done in the select command (see the docs under
'SELECT' for more detail):

    select p.fullname,e.salary,d.name as dept,d.supervisor
    from person p,employee e,department d
    where p.id=e.id and dept.id=e.dept
    ORDER BY dept,fullname

--
It is always hazardous to ask "Why?" in science, but it is often
interesting to do so just the same.
        -- Isaac Asimov, 'The Genetic Code'

will@serensoft.com
http://newbieDoc.sourceforge.net/ -- we need your brain!
http://www.dontUthink.com/ -- your brain needs us!

pgsql-general by date:

Previous
From: will trillich
Date:
Subject: Re: Free Text Search
Next
From: Einar Karttunen
Date:
Subject: Re: query problem