This gets rid of the header and footer OK. But there is still a blank line as the first line in stdout. Also, each record has a preceding space before the column value. Is there a way to do what I want?
pgsql-general by date:
Соглашаюсь с условиями обработки персональных данных