On Thu, Mar 6, 2025 at 10:38 AM Ron Johnson <ronljohnso...@gmail.com> wrote:
> psql -Xc "select datname from pg_database WHERE datname \!~ > 'template|postgres' ORDER BY datname;" > Remove the space: psql -Xc "select datname from pg_database WHERE datname!~ 'template|postgres' ORDER BY datname" I'm not really sure why as this one works: psql -c "SELECT ' !'"