psql: Missing option to print current buffer to current output channel (i.e., \qprint) - Mailing list pgsql-hackers

From David G. Johnston
Subject psql: Missing option to print current buffer to current output channel (i.e., \qprint)
Date
Msg-id CAKFQuwZAm9WXpY+=iBvQUgALCtAP1VA6sT6eRRWg4r_MmWLm=g@mail.gmail.com
Whole thread
List pgsql-hackers
"\echo" has "\qecho" - I'm basically looking for a "\qprint"

"\write" doesn't apply

The following doesn't work either...

#bash (stock Ubuntu 14.04)
psql --set=query_in_var='SELECT version();' > /dev/null <<'SQL'
\o /tmp/psql-test.txt
\set ECHO queries
--still ends up on stdout, hence the redirect to /dev/null to avoid it showing on screen along with the cat output below 
:query_in_var
\o
SQL
cat /tmp/psql-test.txt

Can anyone offer a reason not to add "\qprint"?

David J.



pgsql-hackers by date:

Previous
From: Claudio Freire
Date:
Subject: Re: Heap WARM Tuples - Design Draft
Next
From: Greg Stark
Date:
Subject: Pgbench performance tuning?