Create function a(int)
Returns TABLE(col1 text)
As $$
...
$$
Language 'plpgsql'
On May 24, 2011, at 4:08, Adarsh Sharma wrote:
> Dear all,
>
> I need to return the rows of a table which was also created in that procedure.
>
> I know it is very easy when the table is existed before and we c
On 24 May 2011, at 10:08, Adarsh Sharma wrote:
> Dear all,
>
> I need to return the rows of a table which was also created in that procedure.
>
> I know it is very easy when the table is existed before and we can specify
> like this to return
>
> create function a(integer) returns setof exist_
Hello
2011/5/24 Adarsh Sharma :
> Pavel Stehule wrote:
>>
>> Hello
>>
>> you have to use a dynamic sql
>>
>> look on statement
>>
>> FOR r IN EXECUTE
>> or RETURN QUERY EXECUTE
>>
>
> Can u explain in the example, I find it difficult to understand .
>
> I think we have to specify return type whil
Pavel Stehule wrote:
Hello
you have to use a dynamic sql
look on statement
FOR r IN EXECUTE
or RETURN QUERY EXECUTE
Can u explain in the example, I find it difficult to understand .
I think we have to specify return type while creating procedures.
Thanks
Regards
Pavel Stehule
2011/5
Hello
you have to use a dynamic sql
look on statement
FOR r IN EXECUTE
or RETURN QUERY EXECUTE
Regards
Pavel Stehule
2011/5/24 Adarsh Sharma :
> Dear all,
>
> I need to return the rows of a table which was also created in that
> procedure.
>
> I know it is very easy when the table is existed
Dear all,
I need to return the rows of a table which was also created in that
procedure.
I know it is very easy when the table is existed before and we can
specify like this to return
create function a(integer) returns setof exist_table as $$
But it gives error when the table is also creat