Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id BD8B14761B8 for ; Thu, 24 Oct 2002 06:57:52 -0400 (EDT) Received: from natura.cebas.csic.es (natura.cebas.csic.es [161.111.146.9]) by postgresql.org (Postfix) with ESMTP id 4CDF947612D for ; Thu, 24 Oct 2002 06:57:51 -0400 (EDT) Received: from natura.cebas.csic.es (localhost.localdomain [127.0.0.1]) by natura.cebas.csic.es (8.11.6/8.11.6) with ESMTP id g9OAs9r15364 for ; Thu, 24 Oct 2002 12:54:09 +0200 Received: from there (equipo97.cebas.csic.es [161.111.146.97]) by natura.cebas.csic.es (8.11.6/8.11.6) with SMTP id g9OAs9c15358 for ; Thu, 24 Oct 2002 12:54:09 +0200 Message-Id: <200210241054.g9OAs9c15358@natura.cebas.csic.es> Content-Type: text/plain; charset="iso-8859-15" From: andres javier garcia garcia To: PostgreSQL List Subject: ORDER the result of a query by date Date: Thu, 24 Oct 2002 12:57:28 +0200 X-Mailer: KMail [version 1.3.2] MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200210/331 X-Sequence-Number: 10048 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