Add %x to default PROMPT1 and PROMPT2 in psql

Enterprise / PostgreSQL - Michael Paquier [paquier.xyz] - 12 February 2020 04:31 EST

%d can be used to track if the current connection is in a transaction block or not, and adding it by default to the prompt has the advantage to not need a modification of .psqlrc, something not possible depending on the environment.

This discussion has happened across various sources, and there was a strong consensus in favor of this change.

Author: Vik Fearing

dcdbb5a5db Add %x to default PROMPT1 and PROMPT2 in psql
doc/src/sgml/logicaldecoding.sgml | 6 +++---
doc/src/sgml/ref/psql-ref.sgml | 2 +-
src/bin/psql/settings.h | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)

Upstream: git.postgresql.org


  • Share