pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Emi Lu <emilu@encs.concordia.ca>
To: pgsql-sql@postgresql.org
Subject: Re: quotes etc
Date: Wed, 23 Feb 2011 14:11:54 -0500
Message-ID: <4D655BFA.5010900@encs.concordia.ca> (raw)
In-Reply-To: <201102221318.56516.adrian.klaver@gmail.com>
References: <201102221226.41317.johnf@jfcomputer.com>
	<201102221318.56516.adrian.klaver@gmail.com>

On 02/22/2011 04:18 PM, Adrian Klaver wrote:
> On Tuesday, February 22, 2011 12:26:41 pm John Fabiani wrote:
>
>  > Hi,
>
>  > I would have thought that there would be a simple built-in function that
>
>  > would escape the quotes as ('D' Andes') to ('D\' Andes'). But I did not
>
>  > see anything?
>
>  >
>
>  > I am I wrong?
>
>  >
>
>  > Johnf
>
> Dollar quoting ? :
>
> http://www.postgresql.org/docs/9.0/interactive/sql-syntax-lexical.html
>
> 4.1.2.4. Dollar-Quoted String Constants
>
> test(5432)aklaver=>SELECT $$D' Andes$$;
>
> ?column?
>
> ----------
>
> D' Andes

I like this $str$....$str$ very much!

Vote for this!
--
Lu Ying



view thread (4+ messages)

Message-ID: <4D655BFA.5010900@encs.concordia.ca>
Permalink:  ../4D655BFA.5010900@encs.concordia.ca/
Also on:    postgresql.org/message-id/4D655BFA.5010900@encs.concordia.ca

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: emilu@encs.concordia.ca
  Subject: Re: quotes etc
  In-Reply-To: <4D655BFA.5010900@encs.concordia.ca>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox