Re: if not exists (SELECT 1... UNION SELECT 1...)

Поиск
Список
Период
Сортировка
Искать
От
Alexander Farber
Тема
Re: if not exists (SELECT 1... UNION SELECT 1...)
Дата
Msg-id
CAADeyWi+2ULFv7h-N+LHAZ8Gs4TYfUPqMM0fv5pQA30AcSk4mg@mail.gmail.com
Ответ на
Список
Дерево обсуждения
if not exists (SELECT 1... UNION SELECT 1...) Alexander Farber <alexander.farber@gmail.com>
Re: if not exists (SELECT 1... UNION SELECT 1...) Laurenz Albe <laurenz.albe@cybertec.at>
Re: if not exists (SELECT 1... UNION SELECT 1...) Alexander Farber <alexander.farber@gmail.com>
Re: if not exists (SELECT 1... UNION SELECT 1...) Alexander Farber <alexander.farber@gmail.com>
Re: if not exists (SELECT 1... UNION SELECT 1...) Laurenz Albe <laurenz.albe@cybertec.at>
Re: if not exists (SELECT 1... UNION SELECT 1...) Ralf Schuchardt <rasc@gmx.de>
Re: if not exists (SELECT 1... UNION SELECT 1...) Alexander Farber <alexander.farber@gmail.com>
Re: if not exists (SELECT 1... UNION SELECT 1...) Alexander Farber <alexander.farber@gmail.com>
Ah, thank you Ralf! That has explained it (because I was still grumbling...)

On Wed, Feb 16, 2022 at 4:44 PM Ralf Schuchardt <rasc@gmx.de> wrote:

You must rather end the assignment with a semicolon:

out_text := '___WRONG___';
RETURN;

Otherwise what really happens is:

out_text := '___WRONG___' RETURN;

where „return“ is a simple column name as in this select statement:

select '___WRONG___' return;


В списке pgsql-general по дате отправления
От: Ralf Schuchardt
Дата:
От: Alexander Farber
Дата:
FAQ