Re: [GENERAL] the last row in a table - Mailing list pgsql-general

From Oleg Broytmann
Subject Re: [GENERAL] the last row in a table
Date
Msg-id Pine.SOL2.3.96.SK.990310114052.6083H-100000@sun.med.ru
Whole thread Raw
In response to the last row in a table  (hoelc <hoelc@pd.jaring.my>)
List pgsql-general
Hi!

On Tue, 9 Mar 1999, hoelc wrote:
> I am developing a database with PostgreSQL in Linux, and using ecpg to write the
> C program to communicate with the database.
> One of my application need to get the data from the last row in a table.
> Is there any function or command that can tract which is the last row of data in
> a table?

   Reorder your query to get the data in the FIRST row and use cursor to fetch
just the row.

> Thank you.
> Regards,
> lch

Oleg.
----
    Oleg Broytmann  National Research Surgery Centre  http://sun.med.ru/~phd/
           Programmers don't die, they just GOSUB without RETURN.


pgsql-general by date:

Previous
From: Remigiusz Sokolowski
Date:
Subject: Re: [GENERAL] i want to start automaticly postgres when a reboot my server...help please.....
Next
From: Gilles Darold
Date:
Subject: Re: [GENERAL] Postgres tutorial examples !