Re: Allow SQL/plpgsql functions to accept record - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: Allow SQL/plpgsql functions to accept record
Date
Msg-id 5537BE3F.6050606@BlueTreble.com
Whole thread Raw
In response to Re: Allow SQL/plpgsql functions to accept record  ("David G. Johnston" <david.g.johnston@gmail.com>)
Responses Re: Allow SQL/plpgsql functions to accept record
List pgsql-hackers
On 4/20/15 2:04 PM, David G. Johnston wrote:
>
> ​SELECT (src.v).* FROM ( VALUES (ROW(1,2,3)) ) src (v)​;
> ERROR: record type has not been registered
>
> While it may not be necessary to solve both problems I suspect they have
> the same underlying root cause - specifically the separation of concerns
> between the planner and the executor.

I don't think they're related at all. C functions have the ability to 
accept a record, so the executor must be able to support it. It's just 
that SQL and plpgsql functions don't have that support. I suspect that's 
just because no one has gotten around to it.
-- 
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com



pgsql-hackers by date:

Previous
From: Kevin Grittner
Date:
Subject: Re: Freeze avoidance of very large table.
Next
From: Stephen Frost
Date:
Subject: Re: inherit support for foreign tables