Re: Selects query stats?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Selects query stats?
Дата
Msg-id 17713.1148411593@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Selects query stats?  ("Jim C. Nasby" <jnasby@pervasive.com>)
Ответы Re: Selects query stats?
Список pgsql-performance
"Jim C. Nasby" <jnasby@pervasive.com> writes:
> On Tue, May 23, 2006 at 11:33:12AM -0700, Dan Gorman wrote:
>> In any other DB (oracle, mysql) I know how many queries (selects) per
>> second the database is executing. How do I get this
>> number out of postgres?

> You can't. You also can't know how many DML statements were executed
> (though you can see how many tuples were inserted/updated/deleted), or
> how many transactions have occured (well, you can hack the last one, but
> it's a bit of a mess).

Hack?  We do count commits and rollbacks (see pg_stat_database); doesn't
seem that hacky to me.

Counting individual statements would add overhead (which the OP already
declared unacceptable) and there are some definitional issues too, like
whether to count statements executed within functions.

            regards, tom lane

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

Предыдущее
От: Dan Gorman
Дата:
Сообщение: Re: Selects query stats?
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Selects query stats?