Re: LIMIT clause extremely slow

From: Christophe Pettus <xof(at)thebuild(dot)com>
To: Melzer Kassensysteme <office(at)melzer-kassen(dot)com>
Cc: pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: LIMIT clause extremely slow
Date: 2023-11-15 17:48:37
Message-ID: 23678F58-FF60-4A9E-A975-A7AA65784A00@thebuild.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

> On Nov 15, 2023, at 08:46, Melzer Kassensysteme <office(at)melzer-kassen(dot)com> wrote:
>
> SELECT * FROM table WHERE (index1 > 1 OR (index1 = 1 AND index2 > 5)) ORDER BY index1, index2 LIMIT 1

Can you show the output of the query running under EXPLAIN ANALYZE ... ?

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Laurenz Albe 2023-11-15 17:48:47 Re: BUG #18196: Databases Created in Turkish Language Will Not Run on the Latest Version of Windows
Previous Message Laurenz Albe 2023-11-15 17:23:08 Re: BUG #18200: Undefined behaviour in interval_div