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 7D11E528E7 for ; Thu, 9 Jun 2005 04:16:00 -0300 (ADT) 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 84125-05 for ; Thu, 9 Jun 2005 07:15:59 +0000 (GMT) Received: from WM12.inbox.com (wm12.inbox.com [208.50.6.12]) by svr1.postgresql.org (Postfix) with SMTP id A6B4F52864 for ; Thu, 9 Jun 2005 04:15:57 -0300 (ADT) Received: from inbox.com (127.0.0.1:25) by inbox.com with [InBox.Com ESMTP Server] id <506080030715.WM12> for from ; Wed, 8 Jun 2005 11:15:58 PM -0800 Mime-Version: 1.0 Date: Wed, 8 Jun 2005 23:15:56 -0800 Message-ID: From: Gnanavel Shanmugam Subject: Re: rejecting characters in a field To: Kenneth Gonsalves Cc: pgsql-sql@postgresql.org In-Reply-To: <200506091236.31790.lawgon@thenilgiris.com> X-Mailer: IBISIT WebMail Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200506/129 X-Sequence-Number: 21730 add check constraint with following pattern check(name =21=7E '=5B*/=5E=23=5D') with regards, S.Gnanavel > -----Original Message----- > From: lawgon=40thenilgiris.com > Sent: Thu, 9 Jun 2005 12:36:31 +0530 > To: pgsql-sql=40postgresql.org > Subject: =5BSQL=5D rejecting characters in a field > > hi > i have a table with a varchar field called 'name'. I want postgres to > reject any insert with characters defined as illegal characters, for > example '*/=5E=23'. How do i do this? > -- > regards > kg > > http://www.livejournal.com/users/lawgon > tally ho=21 http://avsap.sourceforge.net > = =E0=B2=87=E0=B2=82=E0=B2=A1=E0=B3=8D=E0=B2=B2=E0=B2=BF=E0=B2=A8=E0=B2=95=E0= =B3=8D=E0=B2=B8 =E0=AE=B5=E0=AE=BE=E0=AE=B4=E0=AF=8D=E0=AE=95=21 > > ---------------------------(end of broadcast)--------------------------- > TIP 2: you can get off all lists at once with the unregister command > (send =22unregister YourEmailAddressHere=22 to = majordomo=40postgresql.org)=