Re: [HACKERS] why can't plpgsql return a row-expression?

2012-12-06 Thread Asif Rehman
Thanks. Regards, --Asif On Fri, Dec 7, 2012 at 9:11 AM, Tom Lane wrote: > Asif Rehman writes: > > I have attached the stripped-down version. I will leave the type > coercions > > support for a separate patch. > > Applied with assorted corrections. > >

Re: [HACKERS] why can't plpgsql return a row-expression?

2012-12-06 Thread Asif Rehman
Hi, I have attached the stripped-down version. I will leave the type coercions support for a separate patch. Regards, --Asif On Fri, Dec 7, 2012 at 1:14 AM, Tom Lane wrote: > Robert Haas writes: > > Are you going to commit a stripped-down version of the patch? > > I set it back to "waiting

Re: [HACKERS] why can't plpgsql return a row-expression?

2012-12-04 Thread Asif Rehman
ns record as $$ > declare r record; > begin > r := (10,20); return r; > end; > $$ language plpgsql; > > postgres=# select sum(a) from generate_series(1,3000) g(i), lateral > fo(i) as (a int, b numeric); > sum > --- > 3 > (1 row) > > postgres=

Re: [HACKERS] why can't plpgsql return a row-expression?

2012-12-03 Thread Asif Rehman
Hi, Thanks for the review. Please see the updated patch. Hmm. We're running an I/O cast during do_tup_convert() now, and look > up the required functions for each tuple. I think if we're going to > support this operation at that level, we need to look up the necessary > functions at convert_tup

Re: [HACKERS] review: plpgsql return a row-expression

2012-11-23 Thread Asif Rehman
Hi, I forgot to add documentation changes in the earlier patch. In the attached patch, I have added documentation as well as fixed other issues you raised. Regards, --Asif On Thu, Nov 22, 2012 at 10:47 PM, Asif Rehman wrote: > Thanks for the review Pavel. I have taken care of the points

Re: [HACKERS] review: plpgsql return a row-expression

2012-11-22 Thread Asif Rehman
Thanks for the review Pavel. I have taken care of the points you raised. Please see the updated patch. Regards, --Asif On Wed, Nov 21, 2012 at 1:47 AM, Pavel Stehule wrote: > related to > http://archives.postgresql.org/message-id/caauglxwpedfwae6dajmf7sxewfusa0f68p07retbbpf_fsa...@mail.gmail.com

Re: [HACKERS] why can't plpgsql return a row-expression?

2012-11-12 Thread Asif Rehman
Hi, I have tried to solve this issue. Please see the attached patch. With this patch, any expression is allowed in the return statement. For any invalid expression an error is generated without doing any special handling. When a row expression is used in the return statement then the resultant tu

Re: [HACKERS] Patch to allow domains over composite types

2012-02-27 Thread Asif Rehman
Hi Yeb Havinga, I was digging archives to see anyone worked on supporting domain's over composite type and found your patch, but that was pulled back. According to commitfest comments it needs some more work... Are you going to submit the updated patch? Regards, --Asif On Wed, May 11, 2011 at 5