Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

BUG #2948: default null values for not-null domains



The following bug has been logged online:

Bug reference:      2948
Logged by:          Sergiy Vyshnevetskiy
Email address:      serg(at)vostok(dot)net
PostgreSQL version: 8.2.1
Operating system:   FreeBSD-6 stable
Description:        default null values for not-null domains
Details: 

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

#psql  = serg(at)[local]:5432 test

Last select should have risen an exception:

ERROR:  variable "t" declared NOT NULL cannot default to NULL



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group