Re: Bug with ORDER BY expression [ ASC | DESC ] ?

From: Christoph Haller <ch(at)rodos(dot)fzk(dot)de>
To: tgl(at)sss(dot)pgh(dot)pa(dot)us (Tom Lane)
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Bug with ORDER BY expression [ ASC | DESC ] ?
Date: 2002-05-22 16:01:01
Message-ID: 200205221401.QAA26812@rodos
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

>
> Christoph Haller <ch(at)rodos(dot)fzk(dot)de> writes:
> > select distinct on (o.sid,o.timepoint,o.lid,o.mid) o.sid,o.timepoint,o.lid,o.mid,o.value
> > from onfvalue o, tempreftime t
> > where o.sid=t.sid and o.timepoint=t.timepoint and o.lid=t.lid and o.mid=t.mid
> > order by o.sid,o.timepoint,o.lid,o.mid,o.entrancetime desc;
>
> > but the result is coming in ascending order.
>
> Perhaps you meant to say
>
> order by o.sid desc, o.timepoint desc, o.lid desc, o.mid desc, o.entrancetime desc;
>
>
Indeed. Thanks, Christoph

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Wm. G. Urquhart 2002-05-22 16:13:11 Re: Turning column into row
Previous Message Christoph Haller 2002-05-22 15:17:01 Bug with ORDER BY expression [ ASC | DESC ] ?