Re: [HACKERS] planner not choosing fastest estimated plan

2013-07-07 Thread Tom Lane
Jeff Janes writes: > I have a weird case where the planner doesn't choose the plan that it > itself believes to be the fastest plan. I poked into this a bit and found where things are going wrong. The ideal plan for this case involves a nestloop with a parameterized inner scan over an inheritanc

Re: [HACKERS] planner not choosing fastest estimated plan

2013-07-06 Thread Jeff Janes
On Sat, Jul 6, 2013 at 10:52 AM, Pavel Stehule wrote: > Hello > > pls, can you send EXPLAIN ANALYZE result? Sure. I've put them on depesz. (I don't know how useful it will be, as I'm worried about the internal inconsistency rather than the actual run time): enable_seqscan=on http://explain.dep

Re: [HACKERS] planner not choosing fastest estimated plan

2013-07-06 Thread Pavel Stehule
Hello pls, can you send EXPLAIN ANALYZE result? Regards Pavel Stehule 2013/7/6 Jeff Janes : > I have a weird case where the planner doesn't choose the plan that it > itself believes to be the fastest plan. If I disable seqscan, it then > chooses a faster plan (faster in estimate and faster in

[HACKERS] planner not choosing fastest estimated plan

2013-07-06 Thread Jeff Janes
I have a weird case where the planner doesn't choose the plan that it itself believes to be the fastest plan. If I disable seqscan, it then chooses a faster plan (faster in estimate and faster in reality) than the one chosen when all options were open to it. I can't figure out how this can be any