pgsql: basebackup_to_shell: Add some const qualifiers for consistency

2022-12-13 Thread Peter Eisentraut
basebackup_to_shell: Add some const qualifiers for consistency Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/4cb65e10722164fd12c6b8d010a39ce0f92e71f9 Modified Files -- contrib/basebackup_to_shell/basebackup_to_shell.c | 6 +++--- 1 file changed, 3 inser

pgsql: Rethink handling of [Prevent|Is]InTransactionBlock in pipeline m

2022-12-13 Thread Tom Lane
Rethink handling of [Prevent|Is]InTransactionBlock in pipeline mode. Commits f92944137 et al. made IsInTransactionBlock() set the XACT_FLAGS_NEEDIMMEDIATECOMMIT flag before returning "false", on the grounds that that kept its API promises equivalent to those of PreventInTransactionBlock(). This t

pgsql: Rethink handling of [Prevent|Is]InTransactionBlock in pipeline m

2022-12-13 Thread Tom Lane
Rethink handling of [Prevent|Is]InTransactionBlock in pipeline mode. Commits f92944137 et al. made IsInTransactionBlock() set the XACT_FLAGS_NEEDIMMEDIATECOMMIT flag before returning "false", on the grounds that that kept its API promises equivalent to those of PreventInTransactionBlock(). This t

pgsql: Rethink handling of [Prevent|Is]InTransactionBlock in pipeline m

2022-12-13 Thread Tom Lane
Rethink handling of [Prevent|Is]InTransactionBlock in pipeline mode. Commits f92944137 et al. made IsInTransactionBlock() set the XACT_FLAGS_NEEDIMMEDIATECOMMIT flag before returning "false", on the grounds that that kept its API promises equivalent to those of PreventInTransactionBlock(). This t

pgsql: Rethink handling of [Prevent|Is]InTransactionBlock in pipeline m

2022-12-13 Thread Tom Lane
Rethink handling of [Prevent|Is]InTransactionBlock in pipeline mode. Commits f92944137 et al. made IsInTransactionBlock() set the XACT_FLAGS_NEEDIMMEDIATECOMMIT flag before returning "false", on the grounds that that kept its API promises equivalent to those of PreventInTransactionBlock(). This t

pgsql: Rethink handling of [Prevent|Is]InTransactionBlock in pipeline m

2022-12-13 Thread Tom Lane
Rethink handling of [Prevent|Is]InTransactionBlock in pipeline mode. Commits f92944137 et al. made IsInTransactionBlock() set the XACT_FLAGS_NEEDIMMEDIATECOMMIT flag before returning "false", on the grounds that that kept its API promises equivalent to those of PreventInTransactionBlock(). This t

pgsql: Rethink handling of [Prevent|Is]InTransactionBlock in pipeline m

2022-12-13 Thread Tom Lane
Rethink handling of [Prevent|Is]InTransactionBlock in pipeline mode. Commits f92944137 et al. made IsInTransactionBlock() set the XACT_FLAGS_NEEDIMMEDIATECOMMIT flag before returning "false", on the grounds that that kept its API promises equivalent to those of PreventInTransactionBlock(). This t

pgsql: Remove SHA256_HMAC_B from scram-common.h

2022-12-13 Thread Michael Paquier
Remove SHA256_HMAC_B from scram-common.h This referred to the size of the buffers for k_ipad and k_opad in HMAC computations. This is unused since e6bdfd9, where SCRAM has switched to the cryptohash routines for its HMAC calculations rather than its own maths. Reviewed-by: Jacob Champion Discuss

pgsql: Add grantable MAINTAIN privilege and pg_maintain role.

2022-12-13 Thread Jeff Davis
Add grantable MAINTAIN privilege and pg_maintain role. Allows VACUUM, ANALYZE, REINDEX, REFRESH MATERIALIZED VIEW, CLUSTER, and LOCK TABLE. Effectively reverts 4441fc704d. Instead of creating separate privileges for VACUUM, ANALYZE, and other maintenance commands, group them together under a sing

pgsql: Non-decimal integer literals

2022-12-13 Thread Peter Eisentraut
Non-decimal integer literals Add support for hexadecimal, octal, and binary integer literals: 0x42F 0o273 0b100101 per SQL:202x draft. This adds support in the lexer as well as in the integer type input functions. Reviewed-by: John Naylor Reviewed-by: Zhihong Yu Reviewed-by: Davi