From: | Scott Marlowe <smarlowe(at)g2switchworks(dot)com> |
---|---|
To: | KeithW(at)narrowpathinc(dot)com |
Cc: | pgsql-sql(at)postgresql(dot)org |
Subject: | Re: Does Postgresql have a similar pseudo-column "ROWNUM" as |
Date: | 2005-05-20 18:42:58 |
Message-ID: | 1116614578.31821.201.camel@state.g2switchworks.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-php pgsql-sql |
On Fri, 2005-05-20 at 13:27, Keith Worthington wrote:
> Scott,
>
> I realize that this thread went off in another direction however your
> suggestion proved very helpful for a problem that I was trying to solve. I
> wanted the row number of a set returned by a function. Here is a chopped
> version of the function that I wrote.
>
> CREATE OR REPLACE FUNCTION func_bom(integer, integer)
> RETURNS SETOF func_bom AS
SNIP
> Although I have no need to limit the output I tried it just for giggles and it
> worked fine.
>
> SELECT * FROM func_bom(12345, 1) WHERE subline between 4 AND 6;
You're welcome. I've saved that off to my ~/pgsql directory for future
use. So, the thanks are back to you. :)
From | Date | Subject | |
---|---|---|---|
Next Message | Maura P. Jones, II | 2005-05-25 23:46:23 | Industry News |
Previous Message | Keith Worthington | 2005-05-20 18:27:35 | Re: Does Postgresql have a similar pseudo-column "ROWNUM" as |
From | Date | Subject | |
---|---|---|---|
Next Message | Mark Fenbers | 2005-05-20 19:46:34 | DBD::Pg on Enterprise 3 |
Previous Message | John DeSoi | 2005-05-20 18:36:53 | Re: How do I quit in the middle of a SQL script? |