On Mon, 29 Oct 2018, David G. Johnston wrote:
You can either use \out or \copy within psql script or redirect the shell output using shell features.
David, willamette-river-hg-# \out data-summary-by-form.txt willamette-river-hg-# select param, site_nbr, sampdate, min(quant), max(quant), unit from concentrations group by param, site_nbr, sampdate, unit order by param, site_nbr, sampdate, unit; ERROR: syntax error at or near "|" LINE 1: | 1980-05-08 | 0.5 | 0.5 | ug/L Still not working. Rich