From: | Konstantin Knizhnik <k(dot)knizhnik(at)postgrespro(dot)ru> |
---|---|
To: | Sergei Kornilov <sk(at)zsrv(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Using scalar function as set-returning: bug or feature? |
Date: | 2018-02-09 08:02:43 |
Message-ID: | 3d6b0f5c-c157-65b0-f534-225780ace804@postgrespro.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 09.02.2018 10:47, Sergei Kornilov wrote:
> Hello
>
>> select into b from my_insert('from func atx');
> You missed select something into b. For example,
> select ret into b from my_insert('from func atx') as ret;
>
> Using scalar function in from is not bug.
> Silent assigning NULL for variables in "into" not matches same in "select"... I think better would be raise warning.
>
> regards, Sergei
Thank you.
Really the problem is caused by empty source list for INTO.
If I rewrite query as
select my_insert into b from my_insert('from func atx');
then it works as expected.
But I wonder if the original statement should be considered as error or
at least we should produce warning for such empty projections?
--
Konstantin Knizhnik
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company
From | Date | Subject | |
---|---|---|---|
Next Message | Kyotaro HORIGUCHI | 2018-02-09 08:06:35 | Parallel bt build crashes when DSM_NONE |
Previous Message | Garym | 2018-02-09 07:56:00 | Is there a cache consistent interface to tables ? |