From: | Achilleus Mantzios <achill(at)matrix(dot)gatewaynet(dot)com> |
---|---|
To: | Christoph Haller <ch(at)rodos(dot)fzk(dot)de> |
Cc: | pgsql-sql(at)postgresql(dot)org, <rajendran(at)davlin(dot)co(dot)in> |
Subject: | Re: Inquiry From Form [pgsql] |
Date: | 2003-05-23 18:29:44 |
Message-ID: | Pine.LNX.4.44.0305231626510.30269-100000@matrix.gatewaynet.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
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(at)matrix(dot)gatewaynet(dot)com
mantzios(at)softlab(dot)ece(dot)ntua(dot)gr
From | Date | Subject | |
---|---|---|---|
Next Message | Bruno Wolff III | 2003-05-23 20:32:28 | Re: libpq program SELECT FOR UPDATE and TIMEOUT or CANCEL REQUEST |
Previous Message | Josh Berkus | 2003-05-23 18:15:47 | Bad rowtype on PL/SQL Oracle -- does anyone know? |