Re: psql feature thought

Поиск
Список
Период
Сортировка
От Mark Dilger
Тема Re: psql feature thought
Дата
Msg-id 446A3866.3060909@markdilger.com
обсуждение исходный текст
Ответ на psql feature thought  ("Joshua D. Drake" <jd@commandprompt.com>)
Список pgsql-hackers
Joshua D. Drake wrote:
> Hello,
> 
> I was dinking around wand came across something that may (or may not be
> useful).
> 
> What if single line statements that were seperated by ; within psql were
> implicitly within a transaction?
> 
> E.g;
> 
> postgres=# select * from foo; update foo set bar = 'baz'; delete from bing;
> 
> Would be a single transaction ? The begin/commit would be implicit.
> 
> Joshua D. Drake
> 
> 
> 

In psql (and in bash, etc) I like to type multiple commands separated by ';' if
I want them all to run but I don't want to wait for the first to complete before
typing the second, third, etc.  (Possibly I would rather go get a coffee while
the commands are running.)

So, I might type:

psql#  <LONG RUNNING INSERT STATEMENT>; <LONG RUNNING SELECT STATEMENT>

and let it fly.  It would violate the principle of least surprise if doing this
on one line caused the semantics to change.

mark


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: [BUGS] BUG #2429: Explain does not report object's schema
Следующее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: Compression and on-disk sorting