-- See http://www.postgresql.org/docs/9.6/static/app-psql.html for the list of other useful variables -- Be quiet during loading of this file \set ECHO none -- set client_min_messages = fatal; -- makes running script stop on the 1st error -- \set ON_ERROR_STOP 1 -- display null values as [null], instead of blank \pset null '[null]' \set COMP_KEYWORD_CASE upper -- one history file per database \set HISTFILE ~/.psql_history- :DBNAME \set HISTSIZE 2000 -- have all queries display query times \timing -- prompt customization \set PROMPT1 '%[%033[31;5m%]%x%[%033[0m%]%[%033[31;1m%]%n%[%033[33;1m%]@%[%033[32;1m%m%[%033[0m%] %[%033[37;1m%]%/%[%033[0m%] %`date +"%H:%M:%S"` %#' \set PROMPT2 '[more] %R > ' -- Verbose error reports. \set VERBOSITY verbose -- unicode \encoding unicode -- switch to expanded table format for large results \x auto -- custom shortcuts \set settings 'select name, setting,unit,context from pg_settings;' -- Okay, be noisy again -- set client_min_messages = warning; -- When running scripts, echos all commmands to stdout. \set ECHO all