optimizer's cost formulas

Поиск
Список
Период
Сортировка
От dafNi
Тема optimizer's cost formulas
Дата
Msg-id 515FFE48.6090307@gmail.com
обсуждение исходный текст
Ответы Re: optimizer's cost formulas  (Daniel Bausch <bausch@dvs.tu-darmstadt.de>)
Список pgsql-general
Hello everybody!

I'm trying to understand the the query planner's cost estimator.
I was not able to find anywhere the formulas that estimate the cost
of each operation that the optimizer produces.

I only found this for the sequential scan:
SEQ SCAN = ( cpu_tuple_cost *  rows ) +  ( number of pages * seq_page_cost )
where :
cpu_tuple_cost=0.01
seq_page_cost=1.0
and "rows" and "number of pages" are given in the query plan (via EXPLAIN ANALYZE)

I am wondering where could I find the rest formulas for the rest operations
(e.g. HashAggregate, Nested Loop, Hash Join, Index Scan, Sort, etc)

I also looked at costsize.c but could not find a formula like the above or maybe I
couldn't make sense of it


Thank you in advance!

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

Предыдущее
От: Martín Marqués
Дата:
Сообщение: Re: Oracle to PostgreSQL transition?
Следующее
От: rudolf
Дата:
Сообщение: how to get collation according to Unicode Collation Algorithm?