Re: psql -e

Поиск
Список
Период
Сортировка
От Dennis Gearon
Тема Re: psql -e
Дата
Msg-id 3F1FFE15.5000804@cvc.net
обсуждение исходный текст
Ответ на Re: psql -e  (nolan@celery.tssi.com)
Ответы Re: psql -e  (Dennis Gearon <gearond@cvc.net>)
Re: psql -et  (nolan@celery.tssi.com)
Список pgsql-general
A macro for the print, which substitutes:

    print()
    fflush()

for a bare print is a good idea.

And then have a routine that looks for contributions that are mistakenly NOT using the macro.


nolan@celery.tssi.com wrote:

>>>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.
>>
>>thanks ,
>>shud there be a fflush then after that print?
>>or there is something i can do on the shell itself?
>
>
> I've been looking into the echo feature, especially as it relates
> to the \o feature, and there are several places where an fflush
> would be helpful so that the output appears on a timely basis and always
> appears in the same order if readline is being used, because
> readline appears to maintain an independent output buffer.
>
> I made the changes for me in 7.3.3 to add some missing fflush's and also
> changed it so that if echo queries and \o are both on, then the query
> is echoed to the output file.
>
> I can probably create diffs for 7.3.3 if you want them.
>
> This was before I got cvs working here, so I have not yet tried these
> patches in 7.4.  I've been holding back in part because of the 7.4 feature
> freeze period (though that might not be enough of a feature change
> to raise eyebrows), and also because there appears to be some readline
> complications.  For example, if you try to backspace you can get some
> weird looking terminal output.
>
> The output sections of psql should probably be rewritten to ensure it
> doesn't intermingle output.  It may be desirable to use parallel
> streams to the console and to an output file (if defined), but that was
> a bit more than I wanted to bite off as my first project at the time.
>
> Tom, would rewriting the output sections interfere with any changes
> you are/were working on in psql?  I probably won't have time to work on
> this before August 15th at this point, so maybe I should wait until we're
> ready to start on 7.5 stuff, in which case I may propose several changes
> in the definitions and options for both the echo and output options
> in psql.
> --
> Mike Nolan
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>


В списке pgsql-general по дате отправления:

Предыдущее
От: nolan@celery.tssi.com
Дата:
Сообщение: Re: optimum postgres server configuration
Следующее
От: Errol Neal
Дата:
Сообщение: Solaris, Postgresql and Problems