Re: feature request: auto savepoint for interactive psql when in transaction.

Поиск
Список
Период
Сортировка
Искать
От
Ross Reedstrom
Тема
Re: feature request: auto savepoint for interactive psql when in transaction.
Дата
Msg-id
20111114230519.GE24723@rice.edu
Ответ на
Список
Дерево обсуждения
feature request: auto savepoint for interactive psql when in transaction. Will Leinweber <will@heroku.com>
Re: feature request: auto savepoint for interactive psql when in transaction. Alvaro Herrera <alvherre@commandprompt.com>
Re: feature request: auto savepoint for interactive psql when in transaction. "Kevin Grittner" <Kevin.Grittner@wicourts.gov>
Re: feature request: auto savepoint for interactive psql when in transaction. Stephen Frost <sfrost@snowman.net>
Re: feature request: auto savepoint for interactive psql when in transaction. Alvaro Herrera <alvherre@commandprompt.com>
Re: feature request: auto savepoint for interactive psql when in transaction. "Kevin Grittner" <Kevin.Grittner@wicourts.gov>
Re: feature request: auto savepoint for interactive psql when in transaction. Daniel Farina <daniel@heroku.com>
Re: feature request: auto savepoint for interactive psql when in transaction. Gurjeet Singh <singh.gurjeet@gmail.com>
Re: feature request: auto savepoint for interactive psql when in transaction. David Fetter <david@fetter.org>
Re: feature request: auto savepoint for interactive psql when in transaction. Ross Reedstrom <reedstrm@rice.edu>
Re: feature request: auto savepoint for interactive psql when in transaction. Bruce Momjian <bruce@momjian.us>
Re: feature request: auto savepoint for interactive psql when in transaction. Ross Reedstrom <reedstrm@rice.edu>
Re: feature request: auto savepoint for interactive psql when in transaction. Will Leinweber <will@heroku.com>
Re: feature request: auto savepoint for interactive psql when in transaction. Ross Reedstrom <reedstrm@rice.edu>
Re: feature request: auto savepoint for interactive psql when in transaction. Daniel Farina <daniel@heroku.com>
Re: feature request: auto savepoint for interactive psql when in transaction. Marko Tiikkaja <marko.tiikkaja@2ndquadrant.com>
Re: feature request: auto savepoint for interactive psql when in transaction. Will Leinweber <will@heroku.com>
Re: feature request: auto savepoint for interactive psql when in transaction. Gurjeet Singh <singh.gurjeet@gmail.com>
Re: feature request: auto savepoint for interactive psql when in transaction. "Kevin Grittner" <Kevin.Grittner@wicourts.gov>
On Mon, Nov 14, 2011 at 02:45:04PM -0800, Will Leinweber wrote:
> My coworker Dan suggested that some people copy and paste scripts. However
> I feel that that is an orthogonal problem and if there is a very high rate
> of input psql should detect that and turn interactive off. And I
> still strongly feel that on_error_rollback=interactive should be the
> default.

Hmm, I think that falls under the "don't so that, then" usecase. I've been
known to c&p the occasional script - I guess the concern here would be not
seeing failed steps that scrolled off the terminal. (I set my scrollback to
basically infinity and actaully use it, but then I'm strange that way :-) )

Trying to autodetect 'high rate of input' seems ... problematic. The code as is
does handle detecting interactivity at startup, and for the current command
- switching mid-stream ... catching repeated auto-rollbacks might be a possibility, then switching the transaction into 'failed' state. That should
catch most of the possible cases where an early set of steps failed, but
scrolled off, so there's no visible error at the end of paste.
> Until then, I've included this as a PSA at the start of any postgres talks
> I've given, because it's simply not widely known.

Good man. (That's a Postgres Service Announcement, then?)

Ross
-- 
Ross Reedstrom, Ph.D.                                 reedstrm@rice.edu
Systems Engineer & Admin, Research Scientist        phone: 713-348-6166
Connexions                  http://cnx.org            fax: 713-348-3665
Rice University MS-375, Houston, TX 77005
GPG Key fingerprint = F023 82C8 9B0E 2CC6 0D8E  F888 D3AE 810E 88F0 BEDE

В списке pgsql-hackers по дате отправления
От: Martijn van Oosterhout
Дата:
От: Andres Freund
Дата:
FAQ