Re: psql -e

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, Rajesh Kumar Mallah <mallah(at)trade-india(dot)com>, pgsql-general(at)postgresql(dot)org
Subject: Re: psql -e
Date: 2003-07-31 04:23:58
Message-ID: 200307310423.h6V4NwS26257@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


I assume this is the fflush you mentioned. Patch attached and applied.

---------------------------------------------------------------------------

Tom Lane wrote:
> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > Rajesh Kumar Mallah writes:
> >> The echo feature of psql echos the query after its executed.
> >> does it makes more sense to have the reverse.
>
> > The query is printed *before* it is executed, but you might not see it
> > because your terminal is not flushing the stdout at the right times.
>
> It might be a good idea to do an explicit fflush(stdout) right after
> printing the query. I observe that PSQLexec() does this, and SendQuery
> does too in one path --- but not in the other.
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073

Attachment Content-Type Size
unknown_filename text/plain 759 bytes

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Joe Conway 2003-07-31 05:21:29 Re: hexadecimal to decimal
Previous Message Tom Lane 2003-07-31 04:13:19 Re: hexadecimal to decimal