Diagnostic Queries
Symptoms
A boolean configuration parameter was given a value that is not a recognized boolean. PostgreSQL raises SQLSTATE 22023 (invalid_parameter_value).
- The parameter expects on/off/true/false/1/0/yes/no.
- Common with a numeric or arbitrary string value.
- Quoting/format mistakes can trigger it.
What the server log shows
ERROR: parameter "autovacuum" requires a Boolean value
Why PostgreSQL raises this — what the manual says
Section 19.1.1 Parameter Names and Values:
“Values can be written as on, off, true, false, yes, no, 1, 0 (all case-insensitive) or any unambiguous prefix of one of these.”
Boolean GUCs accept only a fixed set of truth literals. A value outside that set cannot be interpreted as boolean, so PostgreSQL reports 22023.
Common causes
- Using an unsupported literal (e.g.
enabled). - A typo in
on/off. - Passing a number other than 0/1.
How to fix it
- Use a valid boolean literal:
on/off,true/false,1/0. - Remove stray quotes/whitespace around the value.
- Check the parameter type in
pg_settings.vartype.
Related & next steps
Reference: PostgreSQL 18 Section 20.1 “Setting Parameters”.
Thanks — noted. This helps keep the database accurate.