How to handle nested record data.

From: yi huang <yi(dot)codeplayer(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: How to handle nested record data.
Date: 2012-05-30 03:11:30
Message-ID: CAHU7rYYuZFvGyaN-GsCQnZ09EdUwd75WY1JsQT4C45inr-wa6A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I'm porting a oracle function to postgresql, which has signature like this:

FUNCTION foo
( seq IN varchar
, somerow OUT SomeTable
, otherinfo OUT varchar
)

It's easy to port this function itself to postgresql, but i have problem to
execute this function and assign the results into variables:

SELECT (foo(seq)).* INTO (v_somerow, v_otherinfo);

It complains v_somerow can not be row type.

How to handle the result of function foo?

Best regards.
YiHuang.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Pavel Stehule 2012-05-30 03:21:03 Re: How to handle nested record data.
Previous Message Alan Gutierrez 2012-05-30 02:20:55 Re: Escaping `psql --variable`