Re: Results messages in "results output" window

Поиск
Список
Период
Сортировка
От J.F. Oster
Тема Re: Results messages in "results output" window
Дата
Msg-id 1868087437.20150213210901@mail.ru
обсуждение исходный текст
Ответ на Re: Results messages in "results output" window  (Edson Richter <edsonrichter@hotmail.com>)
Ответы Re: Results messages in "results output" window  (Guillaume Lelarge <guillaume@lelarge.info>)
Список pgadmin-support
Hello Edson,

Friday, February 13, 2015, 8:54:58 PM, you wrote:

ER> On 13-02-2015 15:46, Guillaume Lelarge      wrote:

ER> Le 13 fevr. 2015 18:39, "Edson Richter"
ER> <edsonrichter@hotmail.com>        a ecrit :>>>> Dear friends,>>>> I've been using PgAdmin 12.0.0 released on Jan 6,
2015,     >> compiled in my Ubuntu 14.04 x64.>> Nothing noticiable in terms of use (actually, there are few  >> known
bugs,but they don't bug me anyway).>>>> I would like to know if there is any change to enable       >> processing
resultsto appear in Results output window when       >> running a script the this one:>>>> begin transaction;>> update
mytableset factor_xy = 10 where factor_xy = 15 and    nature_id = 4;>> commit transaction;>>>> Today I get the
followingoutput:>>>> [QUERY═══ ] begin transaction>> [QUERY═══ ] update mytable set factor_xy = 10 where       >>
factor_xy= 15 and nature_id = 4>> [QUERY═══ ] rollback transaction>>>> I would like to get something like:>>>>
[QUERY═══] begin transaction>> 0 rows changed.>> [QUERY═══ ] update mytable set factor_xy = 10 where       >> factor_xy
=15 and nature_id = 4>> 16 rows changed.>> [QUERY═══ ] rollback transaction>> 0 rows changed.>>>>>> Is there any
configurationI can change to get this?>>
 
 
ER> Nope. There's nothing for this.


ER>  Ok, I see. So, results window is almost useless when running scripts...
ER>  Any tip on where to look if I can provide a patch for this? 
Hi! As far as I know, pgAdmin sends the whole query text to Postgres
"as-is". Then, Postgres parses it and executes as a series of queries,
returning output related to the last one. So, first of all pgAdmin
should split the text into separate queries and perform them serially.
Then it can append results to the output window (and probably
render several result grids in a tabbed manner - cool!).

How to parse query text and split it into separate queries? I hope
that code related to pgScript feature will help.


-- 
Best regards,J.F.




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

Предыдущее
От: Edson Richter
Дата:
Сообщение: Re: Results messages in "results output" window
Следующее
От: Guillaume Lelarge
Дата:
Сообщение: Re: Results messages in "results output" window