Skip site navigation (1) Skip section navigation (2)

string escaping in tutorial/syscat.source

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: Josh Kupershmidt <schmiddy(at)gmail(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: string escaping in tutorial/syscat.source
Date: 2013-01-16 01:35:15
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
On Sun, Oct 14, 2012 at 8:53 PM, Josh Kupershmidt
> Hi all,
> It seems the queries in ./src/tutorial/syscat.source use string
> escaping with the assumption that standard_conforming_strings is off,
> and thus give wrong results with modern versions. A simple fix is
> attached.

Hi Josh,

Do you propose back-patching this?  You could argue that this is a bug in
9.1 and 9.2.   Before that, they generate deprecation warnings, but do not
give the wrong answer.

If it is only to be applied to HEAD, or only to 9.1, 9.2, and HEAD, then
this part seems to be unnecessary and I think should be removed (setting a
value to its default is more likely to cause confusion than remove

SET standard_conforming_strings TO on;

and the corresponding reset as well.

Other than that, it does what it says (fix a broken example), does it
cleanly, we want this, and I have no other concerns.

I guess the src/tutorial directory could participate in regression tests,
in which case this problem would have been detected when introduced, but I
don't think I can demand that you invent regression tests for a feature you
are just fixing rather than creating.

Thanks for the patch,


In response to


pgsql-hackers by date

Next:From: Andres FreundDate: 2013-01-16 01:35:42
Subject: Re: Curious buildfarm failures (fwd)
Previous:From: Andres FreundDate: 2013-01-16 01:34:52
Subject: Re: Curious buildfarm failures (fwd)

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group