X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 4B4BC3A594E for ; Tue, 11 Jan 2005 15:17:26 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 04886-01 for ; Tue, 11 Jan 2005 15:17:08 +0000 (GMT) Received: from mx-00.sil.at (mx-00.sil.at [62.116.68.196]) by svr1.postgresql.org (Postfix) with ESMTP id 8F27D3A5925 for ; Tue, 11 Jan 2005 15:17:10 +0000 (GMT) Received: (qmail-ldap/ctrl 75476 invoked from network); 11 Jan 2005 15:17:03 -0000 Received: from unknown (HELO jupiter.sonorys.at) ([213.235.243.42]) (envelope-sender ) by mx-00.sil.at (qmail-ldap-1.03) with SMTP for ; 11 Jan 2005 15:17:03 -0000 Received: from neptun.sonorys.at (neptun.sonorys.at [172.24.1.17]) by jupiter.sonorys.at (8.11.7+Sun/8.11.7) with ESMTP id j0BFHDs18259 for ; Tue, 11 Jan 2005 16:17:13 +0100 (MET) Received: by neptun.sonorys.at with Internet Mail Service (5.5.2653.19) id ; Tue, 11 Jan 2005 16:17:06 +0100 Message-ID: From: =?iso-8859-1?Q?K=D6PFERL_Robert?= To: Cc: pgsql-sql@postgresql.org Subject: Re: Single row tables Date: Tue, 11 Jan 2005 16:17:06 +0100 Importance: high X-Priority: 1 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by amavisd-new at hub.org X-Archive-Number: 200501/42 X-Sequence-Number: 19830 Also I thought of an UNIQUE constraint on a column with =3Dconst = constraint. But ....=20 It's for global configuration data that exists only once. Making a key value thing was to weak typed for my taste. > -----Original Message----- > From: Dmitri Bichko [mailto:dbichko@genpathpharma.com] > Sent: Dienstag, 11. J=E4nner 2005 15:50 > To: K=D6PFERL Robert > Cc: pgsql-sql@postgresql.org > Subject: RE: [SQL] Single row tables >=20 >=20 > I suppose you could put a check constraint that forces a=20 > single value on a column with a unique index? Or an insert=20 > trigger that always inserts the same value into a unique field. >=20 > Out of curiosity, why do you need to do this? >=20 > Dmitri >=20 > -----Original Message----- > From: pgsql-sql-owner@postgresql.org=20 > [mailto:pgsql-sql-owner@postgresql.org] On Behalf Of K=D6PFERL Robert > Sent: Tuesday, January 11, 2005 9:46 AM > Cc: pgsql-sql@postgresql.org > Subject: [SQL] Single row tables > Importance: High >=20 >=20 > Hi, >=20 > with what constraint or how can I ensure that one of my=20 > tables has exact one record or 0..1 records? >=20 > ---------------------------(end of=20 > broadcast)--------------------------- > TIP 7: don't forget to increase your free space map settings >=20