Re: Planner hints in Postgresql

Поиск
Список
Период
Сортировка
Искать
От
Jim Nasby
Тема
Re: Planner hints in Postgresql
Дата
Msg-id
53277291.2090908@nasby.net
Ответ на
Список
Дерево обсуждения
Planner hints in Postgresql Rajmohan C <csrajmohan@gmail.com>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql David Johnston <polobo@yahoo.com>
Re: Planner hints in Postgresql Tom Lane <tgl@sss.pgh.pa.us>
Re: Planner hints in Postgresql Merlin Moncure <mmoncure@gmail.com>
Re: Planner hints in Postgresql Stephen Frost <sfrost@snowman.net>
Re: Planner hints in Postgresql Jim Nasby <jim@nasby.net>
Re: Planner hints in Postgresql Merlin Moncure <mmoncure@gmail.com>
Re: Planner hints in Postgresql Jim Nasby <jim@nasby.net>
Re: Planner hints in Postgresql Claudio Freire <klaussfreire@gmail.com>
Re: Planner hints in Postgresql Tom Lane <tgl@sss.pgh.pa.us>
Re: Planner hints in Postgresql Claudio Freire <klaussfreire@gmail.com>
Re: Planner hints in Postgresql Merlin Moncure <mmoncure@gmail.com>
Re: Planner hints in Postgresql Claudio Freire <klaussfreire@gmail.com>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Jeff Janes <jeff.janes@gmail.com>
Re: Planner hints in Postgresql Jim Nasby <jim@nasby.net>
Re: Planner hints in Postgresql Claudio Freire <klaussfreire@gmail.com>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Merlin Moncure <mmoncure@gmail.com>
Re: Planner hints in Postgresql Martijn van Oosterhout <kleptog@svana.org>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Tom Lane <tgl@sss.pgh.pa.us>
Re: Planner hints in Postgresql Pavel Stehule <pavel.stehule@gmail.com>
Re: Planner hints in Postgresql Merlin Moncure <mmoncure@gmail.com>
Re: Planner hints in Postgresql Jim Nasby <jim@nasby.net>
Re: Planner hints in Postgresql Claudio Freire <klaussfreire@gmail.com>
Re: Planner hints in Postgresql Jim Nasby <jim@nasby.net>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql David Johnston <polobo@yahoo.com>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Stephen Frost <sfrost@snowman.net>
Re: Planner hints in Postgresql Vik Fearing <vik.fearing@dalibo.com>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Stephen Frost <sfrost@snowman.net>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
Re: Planner hints in Postgresql Jeff Janes <jeff.janes@gmail.com>
Re: Planner hints in Postgresql Tom Lane <tgl@sss.pgh.pa.us>
Re: Planner hints in Postgresql Atri Sharma <atri.jiit@gmail.com>
On 3/17/14, 2:16 PM, Merlin Moncure wrote:
> On Mon, Mar 17, 2014 at 1:45 PM, Pavel Stehule  wrote:
>> >I don't believe so SELECTIVITY can work well too. Slow queries are usually
>> >related to some strange points in data. I am thinking so well concept should
>> >be based on validity of estimations. Some plans are based on totally wrong
>> >estimation, but should be fast due less sensitivity to bad estimations. So
>> >well concept is penalization some risk plans - or use brute force - like
>> >COLUMN store engine does. Their plan is usually simply and tolerant to bad
>> >estimations.
> Disagree.  There is a special case of slow query where problem is not
> with the data but with the expression over the data; something in the
> query defeats sampled selectivity.  Common culprits are:
>
> *) CASE expressions
> *) COALESCE
> *) casts
> *) simple tranformational expressions
> *) predicate string concatenation

*) time/date functions, ie WHERE date_trunc( 'quarter', some_timestamp ) = '2014-1-1'

Though, in this case it's probably much better to teach the parser how to turn that into a range expression.
-- 
Jim C. Nasby, Data Architect                       jim@nasby.net
512.569.9461 (cell)                         http://jim.nasby.net


В списке pgsql-hackers по дате отправления
От: Claudio Freire
Дата:
От: Claudio Freire
Дата:
FAQ