In postgres I can define custom option using
set x.x = 12;
I can also read it using following query
SHOW x.x;
But I couldn’t find any command to list all such defined options. Is there anything I can use to get a list of custom defined options?
3
Answers
There is not any possibility to show list of custom configuration options.
You’d have to plan that ahead of time. If you list the
x.x
setting inpostgresql.conf
, it’ll show up inpg_settings
system view where you could then check if its current value is different from its reset/reboot value:But if you only run
set x.x=12;
without having it in there beforehand, it won’t show in that view.Or, as suggested by @Luuk, you could set up your own duplicate set of tables that are meant to store your own settings, then
At the start of each session to load the profile. Afterwards, to check which ones have been modified:
Thing is, that’s duplicating/emulating a set of features that are already built-in.
It’s called SQL: