pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: andrew@pillette.com
To: Tilmann Singer <tils-pgsql@tils.net>
Cc: andrew@pillette.com
Cc: pgsql-performance@postgresql.org
Subject: Re: Slow query with backwards index scan
Date: Sat, 28 Jul 2007 13:43:58 -0700
Message-ID: <200707282043.l6SKhwP08503@pillette.com> (raw)

As other posters have pointed out, you can overcome the ORDER BY/LIMIT restriction on UNIONs with parentheses. I think I misbalanced the parentheses in my original post, which would have caused an error if you just copied and pasted.

I don't think the limitation has to do with planning--just parsing the query.



view thread (12+ messages)  latest in thread

Message-ID: <200707282043.l6SKhwP08503@pillette.com>
Permalink:  ../200707282043.l6SKhwP08503@pillette.com/
Also on:    postgresql.org/message-id/200707282043.l6SKhwP08503@pillette.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: andrew@pillette.com, tils-pgsql@tils.net
  Subject: Re: Slow query with backwards index scan
  In-Reply-To: <200707282043.l6SKhwP08503@pillette.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox