Received: from lin.local.lan ([216.221.221.2]) by mail.postgresql.org (8.11.1/8.11.1) with ESMTP id f28GDPx48501 for ; Thu, 8 Mar 2001 11:13:25 -0500 (EST) (envelope-from najm@mondo-live.com) Received: from mondo-live.com (IDENT:najm@najm.local2.lan [192.168.2.20]) by lin.local.lan (8.9.3/8.8.7) with ESMTP id PAA19237; Thu, 8 Mar 2001 15:51:30 GMT Message-ID: <3AA9026C.86D545FE@mondo-live.com> Date: Fri, 09 Mar 2001 11:18:53 -0500 From: Najm Hashmi X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.2.14-5.0 i686) X-Accept-Language: en MIME-Version: 1.0 To: Roberto Mello CC: pgsql Subject: Re: quotes in pl/pgsql 0n variable type text or varchar References: <3AA80DAE.2DF3F902@mondo-live.com> <20010307180354.A20006@cc.usu.edu> Content-Type: multipart/mixed; boundary="------------E912CC4E531E3B6781348144" X-Archive-Number: 200103/177 X-Sequence-Number: 1830 This is a multi-part message in MIME format. --------------E912CC4E531E3B6781348144 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Roberto Mello wrote: > On Thu, Mar 08, 2001 at 05:54:38PM -0500, Najm Hashmi wrote: > > Hi all, I just want to know how to put quotes around a string. Is there a > > function to do so? > > If not how can I escape a single quote. > > Others have answered how to quote a single string. I wrote an entire > section on quotes on the PL/SQL-to-PL/pgSQL-HOWTO. It's called "Quote me > on that" and mentions several cases on quote usage in PL/pgSQL and what to > do about it. > http://www.brasileiro.net/roberto/howto > > -Roberto > > -- > +----| http://fslc.usu.edu USU Free Software & GNU/Linux Club|------+ > Roberto Mello - Computer Science, USU - http://www.brasileiro.net > http://www.sdl.usu.edu - Space Dynamics Lab, Web Developer > DOS = Damned Old Software Hi, I just want to know is there way to put single quotes around the value of var type text or varchar. Thanks in advance. Regards. --------------E912CC4E531E3B6781348144 Content-Type: text/x-vcard; charset=us-ascii; name="najm.vcf" Content-Transfer-Encoding: 7bit Content-Description: Card for Najm Hashmi Content-Disposition: attachment; filename="najm.vcf" begin:vcard n:Hashmi;Najm x-mozilla-html:FALSE org:Mondo-Live.com;www.flipr.com adr:;;;;;; version:2.1 email;internet:najm@mondo-live.com x-mozilla-cpt:;6144 fn:Najm Hashmi end:vcard --------------E912CC4E531E3B6781348144--