Re: execute command tag including affected rows count

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: execute command tag including affected rows count
Дата
Msg-id 7917.1079910354@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: execute command tag including affected rows count  (Neil Conway <neilc@samurai.com>)
Ответы Re: execute command tag including affected rows count  (Kris Jurka <books@ejurka.com>)
Список pgsql-hackers
Neil Conway <neilc@samurai.com> writes:
> On 21-Mar-04, at 11:39 AM, Kris Jurka wrote:
>> Would it be possible to have the command completion tag for EXECUTE 
>> return
>> the affected row count?

> Yes, this has been suggested before -- for example:

> http://www.mail-archive.com/pgsql-hackers@postgresql.org/msg26787.html

> I agree it would be a good idea, although I can't recall what the 
> conclusion of the previous discussions was -- did anyone raise any 
> critical objections to this?

The previous discussion concluded that EXECUTE should return the command
tag of the executed command --- eg, "UPDATE n" not "EXECUTE n".  Without
this, you cannot for example sensibly cope with both the INSERT and
UPDATE tag formats.

Not sure what it takes internally to the backend to make this happen
... but IIRC there already is provision for utility commands to override
their default tag, so I hope that it would be a pretty localized change.

However, does this really solve Kris' problem?  JDBC generally likes to
think that it works with old Postgres versions; will a fix that only
works in >= 7.5 be good enough for them?
        regards, tom lane


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

Предыдущее
От: "Matthew T. O'Connor"
Дата:
Сообщение: pg_autovacuum next steps
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pg_autovacuum next steps