Re: SELECT * FROM huge_table LIMIT 10; Why does it take more than 10 min to complete, with cold caches

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: SELECT * FROM huge_table LIMIT 10; Why does it take more than 10 min to complete, with cold caches
Дата
Msg-id CAKFQuwah8Zbn52oY6Mz6saydH6NUjbX+bmsh_kH+7BbgmwUy8Q@mail.gmail.com
обсуждение исходный текст
Ответ на SELECT * FROM huge_table LIMIT 10; Why does it take more than 10 min to complete, with cold caches  (Dimitrios Apostolou <jimis@gmx.net>)
Ответы Re: SELECT * FROM huge_table LIMIT 10; Why does it take more than 10 min to complete, with cold caches  (Dimitrios Apostolou <jimis@gmx.net>)
Список pgsql-general
On Tue, Jan 31, 2023 at 8:07 AM Dimitrios Apostolou <jimis@gmx.net> wrote:
 
    ->  Seq Scan on public.test_runs_raw  (cost=0.00..9250235.80 rows=317603680 width=42) (actual time=745910.672..745910.677 rows=10 loops=1)
          Output: run_n, test_name_n, workitem_n, started_on, duration_ms, test_result_n, test_executable_n, test_function_n, test_datatag_n
          Buffers: shared read=2334526
          I/O Timings: shared/local read=691137.029

The system has to return 10 live rows to you.  If it needs to search through that many buffers to find 10 live rows you most likely have a large bloating problem going on.  Seems like it is time to vacuum full.

David J.

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

Предыдущее
От: Dimitrios Apostolou
Дата:
Сообщение: Re: SELECT * FROM huge_table LIMIT 10; Why does it take more than 10 min to complete, with cold caches
Следующее
От: Tom Lane
Дата:
Сообщение: Re: SELECT * FROM huge_table LIMIT 10; Why does it take more than 10 min to complete, with cold caches