pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Kristian Eide <kreide@online.no>
Cc: pgsql-sql@postgresql.org
Subject: Re: Bug with dump/restore when using UNION and ORDER BY in views
Date: Sat, 03 Aug 2002 23:06:41 -0400
Message-ID: <6562.1028430401@sss.pgh.pa.us> (raw)
In-Reply-To: <036501c23b32$5c5149f0$6b97f181@speed>
References: <036501c23b32$5c5149f0$6b97f181@speed>

"Kristian Eide" <kreide@online.no> writes:
> There seems to be a bug when dumping a view which is a UNION of selects, one
> of which has an ORDER BY. A pair of paranthesises around the select is
> missing, and this cause a subsequent restore to fail.

Yeah.  This is fixed in current sources, and I back-patched it into
the REL7_2 branch, but current plans don't seem to include a 7.2.2
release --- we'll be going straight to 7.3 beta instead.

If you're sufficiently annoyed to want to install a source patch
locally, see rev 1.89.2.1 at
http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/utils/adt/ruleutils.c

Note this is a server-side patch; the bug is not in pg_dump.
So using a 7.3 pg_dump against your existing server won't help.
You might want to apply the back-patch just so that you can
dump when the time comes to go to 7.3...

			regards, tom lane



view thread (6+ messages)  latest in thread

Message-ID: <6562.1028430401@sss.pgh.pa.us>
Permalink:  ../6562.1028430401@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/6562.1028430401@sss.pgh.pa.us

 · 

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-sql@postgresql.org
  Cc: tgl@sss.pgh.pa.us, kreide@online.no
  Subject: Re: Bug with dump/restore when using UNION and ORDER BY in views
  In-Reply-To: <6562.1028430401@sss.pgh.pa.us>

* 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