Re: [HACKERS] WIP patch: distinguish selectivity of < from <= and >from >=

Поиск
Список
Период
Сортировка
От Ashutosh Bapat
Тема Re: [HACKERS] WIP patch: distinguish selectivity of < from <= and >from >=
Дата
Msg-id CAFjFpReiJNoOqOLksX3CQkeig8RVU+O7mz9OgPuuoCQLCAqTKw@mail.gmail.com
обсуждение исходный текст
Ответ на [HACKERS] WIP patch: distinguish selectivity of < from <= and > from >=  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: [HACKERS] WIP patch: distinguish selectivity of < from <= and > from >=  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Tue, Jul 4, 2017 at 9:23 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> regression=# explain analyze select * from tenk1 where thousand < 10;
> before:
>  Bitmap Heap Scan on tenk1  (cost=5.14..241.38 rows=110 width=244) (actual time=0.121..0.623 rows=100 loops=1)
> with patch:
>  Bitmap Heap Scan on tenk1  (cost=5.06..227.42 rows=100 width=244) (actual time=0.054..0.300 rows=100 loops=1)

It's expected that the estimates will change with this patch. But I am
wondering why should actual times vary so much. May be that's just
accidental. Butthe actual timings are consistently lower with the
patch except the last one

>
> regression=# explain analyze select * from tenk1 where thousand between 10 and 10;
> before:
>  Index Scan using tenk1_thous_tenthous on tenk1  (cost=0.29..8.30 rows=1 width=244) (actual time=0.041..0.112 rows=10
loops=1)
> with patch:
>  Bitmap Heap Scan on tenk1  (cost=4.39..39.52 rows=10 width=244) (actual time=0.074..0.142 rows=10 loops=1)

The actual time has increased even though estimation is correct.

Those differences may just vanish if we take average of multiple runs
and are not that important to ponder about.

-- 
Best Wishes,
Ashutosh Bapat
EnterpriseDB Corporation
The Postgres Database Company



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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: [HACKERS] hash index on unlogged tables doesn't behave as expected
Следующее
От: Amit Khandekar
Дата:
Сообщение: Re: [HACKERS] UPDATE of partition key