Re: Improvements in psql hooks for variables - Mailing list pgsql-hackers

From Daniel Verite
Subject Re: Improvements in psql hooks for variables
Date
Msg-id 4d4b8d34-6233-4fb4-93dc-7e929808b982@mm
Whole thread Raw
In response to Re: Improvements in psql hooks for variables  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Improvements in psql hooks for variables
List pgsql-hackers
    Tom Lane wrote:

> Stephen Frost <sfrost@snowman.net> writes:
> > In reviewing this patch, I also noticed that it's set up to assume a
> > 'true' result when a variable can't be parsed by ParseVariableBool.
>
> I suppose that's meant to be backwards-compatible with the current
> behavior:
>
> regression=# \timing foo
> unrecognized value "foo" for "\timing"; assuming "on"
> Timing is on.

Exactly. The scope of the patch is limited to the effect
of \set assignments to built-in variables.

> but I agree that if we're changing things in this area, that would
> be high on my list of things to change.  I think what we want going
> forward is to disallow setting "special" variables to invalid values,
> and that should hold both for regular variables that have special
> behaviors, and for the special-syntax cases like \timing.

+1

Best regards,
--
Daniel Vérité
PostgreSQL-powered mailer: http://www.manitou-mail.org
Twitter: @DanielVerite



pgsql-hackers by date:

Previous
From: Man
Date:
Subject: Re: How to change order sort of table in HashJoin
Next
From: Stephen Frost
Date:
Subject: Re: Improvements in psql hooks for variables