Re: massive performance hit when using "Limit 1" - Mailing list pgsql-general

From Rich Doughty
Subject Re: massive performance hit when using "Limit 1"
Date
Msg-id 4395633A.5040507@opusvl.com
Whole thread Raw
In response to massive performance hit when using "Limit 1"  (Rich Doughty <rich@opusvl.com>)
List pgsql-general
Rich Doughty wrote:
> can anyone explain the reason for the difference in the
> following 2 query plans, or offer any advice? the two queries
> are identical apart from the limit clause.

[snip]

fwiw, join order makes no difference here either. i get a slightly
different plan, but with LIMIT 1 postgres make a really strange
planner choice.

As before LIMIT > 1 the choice is logical and performance fine.



   - Rich Doughty

pgsql-general by date:

Previous
From: Bernhard Weisshuhn
Date:
Subject: Re: Using a 250GB RAID10 server for postgres
Next
From: Vinay Jain
Date:
Subject: UNSUBSCRIBE