On 09/30/21 17:54, Florin Irion wrote:
> We could also help users get a warning if they set a parameter with the
> `SET` command.
This is funny. For years I have been so confident I knew how this worked
that I, obviously, hadn't tried it. :)
My first setting of a made-up variable gets no warning, as I already expected:
postgres=# set plpgsql.no_such_setting = false;
SET
Then as soon as I do the first thing in the session involving plpgsql,
I get the warning for that one:
postgres=# do language plpgsql
postgres-# 'begin delete from pg_class where false; end';
WARNING: unrecognized configuration parameter "plpgsql.no_such_setting"
DO
But then, I have always assumed I would get warnings thereafter:
postgres=# set plpgsql.not_this_one_neither = false;
SET
But no!
So I am in favor of patching this.
Regards,
-Chap