pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Fuhr <mike@fuhr.org>
To: Edmund Bacon <ebacon@onesystem.com>
Cc: pgsql-sql@postgresql.org, Kieran Ashley <krashley@space.qinetiq.com>
Subject: Re: Problems with Quotes
Date: Wed, 12 Jan 2005 11:58:47 -0700
Message-ID: <20050112185847.GA95755@winnie.fuhr.org> (raw)
In-Reply-To: <41E5709D.8010705@onesystem.com>
References: <6665151E3647D711B27B0090277C004F9AF721@ntexch02s.scs.dra.hmg.gb>
	<41E5709D.8010705@onesystem.com>

On Wed, Jan 12, 2005 at 11:46:53AM -0700, Edmund Bacon wrote:

> Perhaps you are forgetting to double up on your quote chars?

If that's the problem then 8.0's dollar quoting will simplify
the situation:

CREATE OR REPLACE FUNCTION foo(text) RETURNS text AS $$
SELECT replace($1, '"', '');
$$ LANGUAGE sql;

-- 
Michael Fuhr
http://www.fuhr.org/~mfuhr/



view thread (7+ messages)  latest in thread

Message-ID: <20050112185847.GA95755@winnie.fuhr.org>
Permalink:  ../20050112185847.GA95755@winnie.fuhr.org/
Also on:    postgresql.org/message-id/20050112185847.GA95755@winnie.fuhr.org

 · 

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: mike@fuhr.org, ebacon@onesystem.com, krashley@space.qinetiq.com
  Subject: Re: Problems with Quotes
  In-Reply-To: <20050112185847.GA95755@winnie.fuhr.org>

* 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