From: Achilleus Mantzios <achill@matrix.gatewaynet.com>
To: Christoph Haller <ch@rodos.fzk.de>
Cc: pgsql-sql@postgresql.org, <rajendran@davlin.co.in>
Subject: Re: Inquiry From Form [pgsql]
Date: Fri, 23 May 2003 16:29:44 -0200 (GMT+2)
Message-ID: <Pine.LNX.4.44.0305231626510.30269-100000@matrix.gatewaynet.com> (raw)
In-Reply-To: <3ECE04E1.86BE5143@rodos.fzk.de>
On Fri, 23 May 2003, Christoph Haller wrote:
> >
> > I am using Java language for getting first 10 records from the table
> in postgres.
> > I dont know how to fetch 10 records from the table.
> > Raj
> >
Could you try
selecy name from bar where serves_greek_tsipouro order by price limit 10;
> First answer is RTFM. But within psql you can fetch like this:
>
> begin;
> declare fu cursor for select * from foo;
> fetch 10 in fu;
> fetch 10 in fu;
> ...
> close fu;
> end;
>
> Does this answer your question?
>
> Regards, Christoph
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>
--
==================================================================
Achilleus Mantzios
S/W Engineer
IT dept
Dynacom Tankers Mngmt
Nikis 4, Glyfada
Athens 16610
Greece
tel: +30-210-8981112
fax: +30-210-8981877
email: achill@matrix.gatewaynet.com
mantzios@softlab.ece.ntua.gr
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: achill@matrix.gatewaynet.com, ch@rodos.fzk.de, rajendran@davlin.co.in
Subject: Re: Inquiry From Form [pgsql]
In-Reply-To: <Pine.LNX.4.44.0305231626510.30269-100000@matrix.gatewaynet.com>
References: <3ECE04E1.86BE5143@rodos.fzk.de> <Pine.LNX.4.44.0305231626510.30269-100000@matrix.gatewaynet.com>
* 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