Re: What does \timing measure?

Поиск
Список
Период
Сортировка
От Jeff Janes
Тема Re: What does \timing measure?
Дата
Msg-id CAMkU=1zrDrqDzuANKR-PH2kNweSdYt5t7y6uRtoVccXjuZu9+Q@mail.gmail.com
обсуждение исходный текст
Ответ на What does \timing measure?  (Daniel Tahara <daniel.tahara@yale.edu>)
Ответы Re: What does \timing measure?  (Daniel Tahara <daniel.tahara@yale.edu>)
Список pgsql-general
On Tue, Sep 24, 2013 at 1:13 PM, Daniel Tahara <daniel.tahara@yale.edu> wrote:
I am attempting to benchmark a number of queries over a 15GB dataset with ~ 10mil records. When I run linux time on the query execution (single column projection), it returns 1 minute, but the \timing command returns only 15 seconds?

Can you show exactly how you are executing those?
 
Can someone explain the difference? 1 minute is consistent with reading the 15gb from disk at 250mb/s (I have SSDs), but is \timing supposed to include that cost? Or simply the computation time plus the time to return results.

Probably much of your data is cached in RAM so doesn't have be read from disk anyway.  To the extent it does need to be read from disk, that time will be included.

psql's \timing doesn't include the time it takes for psql to format and print the results to the screen (or whereever the output of psql is sent).

Cheers,

Jeff

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

Предыдущее
От: Daniel Tahara
Дата:
Сообщение: What does \timing measure?
Следующее
От: Daniel Tahara
Дата:
Сообщение: Re: What does \timing measure?