"Merlin Moncure" <[EMAIL PROTECTED]> writes:
> Here is the actual query:
> select lock_cuid(id), *
> ...
>       order by wcl_vin_no, wcl_claim_no, id
>       limit 1

Looks like Stephan made the right guess.

Logically the LIMIT executes after the ORDER BY, so the sorted result
has to be formed completely.  The fact that we are able to optimize
this in some cases does not represent a promise that we can do it in
all cases.  Ergo, it's not a bug.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Reply via email to