agora inbox for pgsql-sql@postgresql.org  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Tena Sakai <tsakai@gallo.ucsf.edu>
Cc: pgsql-sql@postgresql.org
Cc: pgsql-hackers@postgresql.org
Subject: Re: How would I get rid of trailing blank line?
Date: Thu, 02 Apr 2009 19:01:21 -0400
Message-ID: <14638.1238713281@sss.pgh.pa.us> (raw)
In-Reply-To: <FE44E0D7EAD2ED4BB2165071DB8E328C04E84A65@egcrc-ex01.egcrc.org>
References: <FE44E0D7EAD2ED4BB2165071DB8E328C04E84A65@egcrc-ex01.egcrc.org>

"Tena Sakai" <tsakai@gallo.ucsf.edu> writes:
> I often use a line like:
>   psql -tf query.sql mydatabase > query.out

> -t option gets rid of the heading and count
> report at the bottom.  There is a blank line
> at the bottom, however.  Is there any way to
> have psql not give me that blank line?

Doesn't look like it --- the final fputc('\n', fout); seems to be
done unconditionally in all the output formats.  I wonder if we should
change that?  I'm afraid it might break programs that are used to it :-(

			regards, tom lane



view thread (9+ messages)  latest in thread

Message-ID: <14638.1238713281@sss.pgh.pa.us>
Permalink:  ../14638.1238713281@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/14638.1238713281@sss.pgh.pa.us

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, tsakai@gallo.ucsf.edu, pgsql-hackers@postgresql.org
  Subject: Re: How would I get rid of trailing blank line?
  In-Reply-To: <14638.1238713281@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox