Received: from localhost.localdomain (postgresql.org [64.49.215.8]) by localhost (Postfix) with ESMTP id 8589F475CA5 for ; Sun, 7 Jul 2002 09:41:48 -0400 (EDT) Mailbox-Line: From mallah@trade-india.com Sun Jul 7 09:41:48 2002 Received: from mail-relay.trade-india.com (mail-relay.trade-india.com [203.196.129.235]) by postgresql.org (Postfix) with SMTP id CE470475A5F for ; Sun, 7 Jul 2002 09:41:44 -0400 (EDT) Received: (qmail 5760 invoked from network); 7 Jul 2002 13:34:47 -0000 Received: from system67.trade-india-local.com (192.168.0.67) by infocom-236-129-del.trade-india.com with SMTP; 7 Jul 2002 13:34:47 -0000 Content-Type: text/plain; charset="iso-8859-1" From: "Rajesh Kumar Mallah." Organization: Infocom Network Limited. To: "Christopher Kings-Lynne" , Subject: Re: Is Dropping a column "CHECK" constraint possible? Date: Sun, 7 Jul 2002 19:15:10 +0530 User-Agent: KMail/1.4.1 References: <200207051729.42137.mallah@trade-india.com> <00e101c224a6$81ee3bc0$0200a8c0@SOL> In-Reply-To: <00e101c224a6$81ee3bc0$0200a8c0@SOL> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200207071915.10489.mallah@trade-india.com> X-Spam-Status: No, hits=-5.4 required=5.0 tests=IN_REP_TO,X_NOT_PRESENT,SUBJ_ENDS_IN_Q_MARK version=2.30 X-Spam-Level: X-Archive-Number: 200207/79 X-Sequence-Number: 8458 Hi , i want to enforce that a coulumn 'imp' shud either contain valid data or no data at all. by valid data i mean data having at least one non whitespace character. will this constraint be approprote for accomplishing it? tradein_client=3D> ALTER TABLE t_a ADD CHECK ( length( btrim(imp) ) > 1= or imp is NULL ); regards mallah. On Saturday 06 July 2002 10:05, Christopher Kings-Lynne wrote: > > can anyone please help? > > i have a to drop a check contstraint from a column. eg > > > > tradein_clients=3D# \d t_a > > Table "t_a" > > Column | Type | Modifiers > > ------------+---------+----------- > > company_id | integer | > > exp | text | > > imp | text | > > Check constraints: "$1" (length(imp) > 1) > > "aaaaaq" (length(imp) > 1) > >