Received: from odin.sinectis.com.ar (IDENT:root@odin.sinectis.com.ar [216.244.192.22]) by hub.org (8.10.1/8.10.1) with ESMTP id e6PFVch93001 for ; Tue, 25 Jul 2000 11:31:38 -0400 (EDT) Received: from kosh.babylon (IDENT:pablo@modem185-as14.capfed1.sinectis.com.ar [216.244.199.185]) by odin.sinectis.com.ar (8.9.3/8.9.1) with ESMTP id MAA10241; Tue, 25 Jul 2000 12:31:12 -0300 Message-ID: X-Mailer: XFMail 1.4.6-3 on Linux X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <3976A9A6.55E6BE2E@kss.net.au> Date: Tue, 25 Jul 2000 12:37:20 -0400 (ART) From: Pablo Niklas To: Carolyn Lu Wong Subject: RE: primary key question Cc: "pgsql-sql@postgresql.org" X-Archive-Number: 200007/235 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 El 20-Jul-2000 Carolyn Lu Wong escribio: > create table aaa( > field1 .... not null, > field2 ...., > ...., > primary key (field1, field2) > ); > > Based on the above table definition, field2 allows null values. But > after the table created based on the above script, field2 becomes not > null. The only conclusion I come up with is setting the field as part of > the primary key, PostgreSQL automatically sets the field to not null. Or > is it something else? > > Is this a feature or bug? It's a SQL feature, because primary key must no contain null values. Pablo Niklas pniklas@bigfoot.com -----BEGIN PGP SIGNATURE----- Version: PGPfreeware 5.0i for non-commercial use Charset: noconv iQA/AwUBOXg9Mozs62hO+t8PEQIsGgCdFO5HlMTy087WsBFc3tPSGFBKGOUAni6C 2NnOSwcsnlNFrkNsPoV1N3u7 =Ex7i -----END PGP SIGNATURE-----