Re: [PATCHES] Escape handling in strings

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Michael Glaesemann <grzm(at)myrealbox(dot)com>
Cc: Greg Stark <gsstark(at)mit(dot)edu>, PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [PATCHES] Escape handling in strings
Date: 2005-06-17 12:55:21
Message-ID: 200506171255.j5HCtLb24529@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Michael Glaesemann wrote:
>
> On Jun 17, 2005, at 4:34 PM, Greg Stark wrote:
>
> > And for an app issuing
> > hundreds or thousands of queries per minute (or even second) a
> > warning could
> > effectively be a showstopper. It could require disabling all
> > warnings in their
> > config to avoid filling their disk with Postgres logs in minutes.
>
> Good point.
>
> > I would suggest this warning be disable-able with a GUC variable.
> > Otherwise
> > you're effectively giving no advance warning time to those users.
>
> Perhaps NOTICE would be better, at least for the first step? People
> might be more comfortable with that, as using backslash escaping
> isn't really going to cause problems with this particular version,
> but rather for future versions.

I am thinking changing the level of the message isn't going to help
people much because it still displays and fills up the server logs.

> > If postgres keeps advancing at the pace it's advancing now I might
> > suggest
> > waiting two release cycles instead of just one.
>
> How's this for an idea?
>
> Step 1 (8.1) NOTICE level (or some other level, lower than WARNING),
> E'' and \' are available
> Step 2 (8.2?) WARNING level, E'' and \' are available
> Step 3 (8.3? 8.4?) E'' available, plain '' interpreted literally.

Right now I am thinking we would have the warning available in 8.1, but
not turn it on by default. Perhaps we can tell users to enable the
warning at some time during 8.1 so they are ready for it in 8.2.

If we get a significant must-upgrade 8.0.X release a few months before
8.1, we can tell them to change \' to '' and perhaps have the \' warning
be enabled always in 8.1.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dave Page 2005-06-17 13:13:57 Re: Utility database (Was: RE: Autovacuum in the backend)
Previous Message Matthew T. O'Connor 2005-06-17 12:21:23 Re: Autovacuum in the backend

Browse pgsql-patches by date

  From Date Subject
Next Message Bruce Momjian 2005-06-17 13:42:43 Re: Escape handling in strings
Previous Message Peter Eisentraut 2005-06-17 11:43:48 Re: Updated french .po files