pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedplpgsql function return array
2+ messages / 2 participants
[nested] [flat]
* plpgsql function return array
@ 2007-03-31 07:43 Karthikeyan Sundaram <skarthi98@hotmail.com>
0 siblings, 1 reply; 2+ messages in thread
From: Karthikeyan Sundaram @ 2007-03-31 07:43 UTC (permalink / raw)
To: pgsql-admin@postgresql.org; pgsql-sql
Hi, I am using Postgres 8.1.0. I have a requirement. I will create a function accepting few parameters. This will check into various tables and give back an array of values. I want to use the pgpsql block. I know that we can create using language sql. Is it possible to return an array from the function? Please guide me. Regardsskarthi
_________________________________________________________________
Take a break and play crossword puzzles - FREE!
http://games.msn.com/en/flexicon/default.htm?icid=flexicon_ wlmemailtaglinemarch07=
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: plpgsql function return array
@ 2007-03-31 12:55 Michael Fuhr <mike@fuhr.org>
parent: Karthikeyan Sundaram <skarthi98@hotmail.com>
0 siblings, 0 replies; 2+ messages in thread
From: Michael Fuhr @ 2007-03-31 12:55 UTC (permalink / raw)
To: Karthikeyan Sundaram <skarthi98@hotmail.com>; +Cc: pgsql-sql
On Sat, Mar 31, 2007 at 12:43:44AM -0700, Karthikeyan Sundaram wrote:
> Hi, I am using Postgres 8.1.0. I have a requirement. I will
> create a function accepting few parameters. This will check into
> various tables and give back an array of values. I want to use the
> pgpsql block. I know that we can create using language sql. Is
> it possible to return an array from the function? Please guide me.
See the documentation for how to declare a function's return type,
how to return values from a function, and how to build and manipulate
arrays:
http://www.postgresql.org/docs/8.2/interactive/sql-createfunction.html
http://www.postgresql.org/docs/8.2/interactive/plpgsql-overview.html
http://www.postgresql.org/docs/8.2/interactive/plpgsql-control-structures.html#PLPGSQL-STATEMENTS-RE...
http://www.postgresql.org/docs/8.2/interactive/arrays.html
http://www.postgresql.org/docs/8.2/interactive/functions-array.html
If you're having a specific problem then please post the code you're
running and describe how its behavior differs from what you expect.
--
Michael Fuhr
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2007-03-31 12:55 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2007-03-31 07:43 plpgsql function return array Karthikeyan Sundaram <skarthi98@hotmail.com>
2007-03-31 12:55 ` Michael Fuhr <mike@fuhr.org>
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