Re: Assert single row returning SQL-standard functions

Поиск
Список
Период
Сортировка
От Vik Fearing
Тема Re: Assert single row returning SQL-standard functions
Дата
Msg-id 57c67366-a84f-4636-b783-dfc059107048@postgresfriends.org
обсуждение исходный текст
Ответ на Re: Assert single row returning SQL-standard functions  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: Assert single row returning SQL-standard functions
Список pgsql-hackers


On 29/08/2025 12:06, Pavel Stehule wrote:
> I can imagine allowing the NOT NULL flag for functions, and then the
> result can be checked on NOT NULL value.

I like the idea of a NOT NULL flag for functions.
What syntax could we image for that?

CREATE OR REPLACE FUNCTION foo() RETURNS int NOT NULL AS $$ SELECT 10 $$ LANGUAGE ...


What if the function is supposed to return NULL sometimes?  The point here is not the value but the row count.

-- 

Vik Fearing

В списке pgsql-hackers по дате отправления: