Re: function returning a setof a column type - Mailing list pgsql-novice

From Tom Lane
Subject Re: function returning a setof a column type
Date
Msg-id 5590.1138733590@sss.pgh.pa.us
Whole thread Raw
In response to function returning a setof a column type  (Murat Tasan <murat.tasan@cwru.edu>)
List pgsql-novice
Murat Tasan <murat.tasan@cwru.edu> writes:
> => CREATE FUNCTION test_function() RETURNS SETOF table.column%TYPE AS
> $$ SELECT 1; $$ LANGUAGE SQL;
> ERROR:  syntax error at or near "%" at character 59

This seems to be an oversight in the grammar: that combination simply
isn't handled.  I'll see about fixing it for 8.2, but for the moment
you're just stuck with not using %TYPE and SETOF together :-(

            regards, tom lane

pgsql-novice by date:

Previous
From: Tom Lane
Date:
Subject: Re:
Next
From: Darren R
Date:
Subject: subscribe-digest