BUG #2954: null is not checked against domain constraints in return clause

Поиск
Список
Период
Сортировка
От Sergiy Vyshnevetskiy
Тема BUG #2954: null is not checked against domain constraints in return clause
Дата
Msg-id 200702011543.l11FhtSB071525@wwwmaster.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #2954: null is not checked against domain constraints in return clause  (Sergiy Vyshnevetskiy <serg@vostok.net>)
Список pgsql-bugs
The following bug has been logged online:

Bug reference:      2954
Logged by:          Sergiy Vyshnevetskiy
Email address:      serg@vostok.net
PostgreSQL version: 8.2.1
Operating system:   FreeBSD-6 stable
Description:        null is not checked against domain constraints in return
clause
Details:

#psql  = serg@[local]:5432 test
create domain "DInt" as int not null;
CREATE DOMAIN
#psql  = serg@[local]:5432 test
create or replace function test() returns "DInt" immutable strict language
plpgsql as $F$begin return null; end$F$;
CREATE FUNCTION
#psql  = serg@[local]:5432 test
select test() is null;
 ?column?
----------
 t
(1 запись)

#psql  = serg@[local]:5432 test

We should have gotten an error during execution of test().

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

Предыдущее
От: Sergiy Vyshnevetskiy
Дата:
Сообщение: Re: BUG #2948: default null values for not-null domains
Следующее
От: Sergiy Vyshnevetskiy
Дата:
Сообщение: Re: BUG #2954: null is not checked against domain constraints in return clause