BUG #10547: Query too long with order and limit - Mailing list pgsql-bugs

From alamy@ltutech.com
Subject BUG #10547: Query too long with order and limit
Date
Msg-id 20140606095510.2721.52790@wrigleys.postgresql.org
Whole thread Raw
Responses Re: BUG #10547: Query too long with order and limit  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      10547
Logged by:          Arnaud Lamy
Email address:      alamy@ltutech.com
PostgreSQL version: 9.2.4
Operating system:   Linux
Description:

Hi guys,

After double checked with #postgresqlfr users, I think I have a bug.

With the pastebin below, if I add a limit to my query the behavior totally
change. It could take minutes instead of milliseconds.

explain and query:

http://paste.debian.net/103554/

Please let me know if you need more informations.

I tested with 9.4, same behavior.

Arnaud

pgsql-bugs by date:

Previous
From: surbhu06@gmail.com
Date:
Subject: BUG #10545: The connection has been closed
Next
From: kuladeepmca2007@gmail.com
Date:
Subject: BUG #10548: NpgsqlException - ERROR: 57014: canceling statement due to user request