From: Henshall, Stuart - Design & Print <SHenshall@westcountry-design-print.co.uk>
To: andres javier garcia garcia <andresjavier.garcia@wanadoo.es>
To: PostgreSQL List <pgsql-sql@postgresql.org>
Subject: Re: ORDER the result of a query by date
Date: Thu, 24 Oct 2002 11:59:26 +0100
Message-ID: <E2870D8CE1CCD311BAF50008C71EDE8E0506DC74@MAIL_EXCHANGE> (raw)
andres javier garcia garcia wrote:
> Hello;
> I've got the result of a query that appears as:
> cod_variable | cod_station | year | month | day | rain
> ---------------------+-------------------+--------+----------+
> ------+------
> 30201 | 7237 | 1953 | 1 | 1 | 2
> 30201 | 7237 | 1953 | 2 | 1 | 5
> 30201 | 7237 | 1953 | 3 | 1 | 0
> 30201 | 7237 | 1953 | 4 | 1 | -3 .....
>
> (Of course, thanks to Stephan Szabo for the method to obtain this
> from my strange source data. I didn't think this was possible.)
>
> After have done this query I've realized that I need the data to be
> ordered by date. Do you have any suggestion?
>
> Best regards
> ----------
> Javier
>
ORDER BY year,month,day should do it.
hth,
- Stuart
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: SHenshall@westcountry-design-print.co.uk, andresjavier.garcia@wanadoo.es
Subject: Re: ORDER the result of a query by date
In-Reply-To: <E2870D8CE1CCD311BAF50008C71EDE8E0506DC74@MAIL_EXCHANGE>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox