Re: returning parameters from function - Mailing list pgsql-general

From Matthias.Pitzl@izb.de
Subject Re: returning parameters from function
Date
Msg-id 11EC9A592C31034C88965C87AF18C2A70CFD49@m0000s61
Whole thread Raw
In response to returning parameters from function  (Rikard Pavelic <rikard.pavelic@zg.htnet.hr>)
List pgsql-general
You have to call the function in the following form:

SELECT * FROM get_test_data(1) AS (field1 type, field2 type, ...)

In words, you have to tell the database how the data returned by the
function has to be interpreted.

Greetings,
Matthias

> -----Original Message-----
> From: pgsql-general-owner@postgresql.org
> [mailto:pgsql-general-owner@postgresql.org] On Behalf Of
> Rikard Pavelic
> Sent: Tuesday, December 12, 2006 3:06 PM
> To: Shoaib Mir; pgsql-general@postgresql.org
> Subject: Re: [GENERAL] returning parameters from function
>
> This doesn't work. ;(
> I get ERROR: a column definition list is required for functions
> returning "record"
> SQL state: 42601
> when running this function
>
> Regards,
> Rikard
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 1: if posting/reading through Usenet, please send an appropriate
>        subscribe-nomail command to majordomo@postgresql.org
> so that your
>        message can get through to the mailing list cleanly
>

pgsql-general by date:

Previous
From: Rikard Pavelic
Date:
Subject: Re: returning parameters from function
Next
From: Rikard Pavelic
Date:
Subject: Re: returning parameters from function