Hello,
Several built-in functions are documented with parameter names that differ from
the names registered in pg_proc. PostgreSQL supports named-argument calls, so
these differences directly affect whether the documented call can be used.
For example, on PostgreSQL 16.14:
SELECT parse_ident(str => 'a.b');
-- {a,b}
SELECT parse_ident(qualified_identifier => 'a.b');
-- ERROR: function parse_ident(qualified_identifier => unknown) does not
exist
The current REL_18_STABLE documentation uses qualified_identifier/strict_mode,
while pg_proc.dat registers the names as str/strict.
The same class of mismatch appears in:
- make_timestamp and make_timestamptz: documentation uses day;
pg_proc uses mday.
- jsonb_set, jsonb_set_lax, and jsonb_insert: documentation uses
target/new_value; the registered names are jsonb_in/replacement.
- table_to_xml, table_to_xmlschema, and table_to_xml_and_xmlschema:
documentation uses table; pg_proc uses tbl.
- pg_logical_emit_message in PG18: documentation uses content; the SQL-visible
name is message for both overloads.
References:
https://www.postgresql.org/docs/current/sql-syntax-calling-funcs.html
https://github.com/postgres/postgres/blob/REL_18_STABLE/doc/src/sgml/func.sgml
https://github.com/postgres/postgres/blob/REL_18_STABLE/src/include/catalog/pg_proc.dat
https://github.com/postgres/postgres/blob/REL_18_STABLE/src/backend/catalog/system_functions.sql
I suggest updating the displayed names to the SQL-visible parameter names.
Renaming the runtime parameters would change named-call compatibility.
Regards