pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Ronan Dunklau <rdunklau@gmail.com>
Cc: pgsql-bugs@postgresql.org
Subject: Re: pg_dump - foreign table - server name is not quoted
Date: Mon, 28 Nov 2011 11:51:58 -0500
Message-ID: <11056.1322499118@sss.pgh.pa.us> (raw)
In-Reply-To: <4ED38CE3.5060503@gmail.com>
References: <4ED38CE3.5060503@gmail.com>

Ronan Dunklau <rdunklau@gmail.com> writes:
> When dumping foreign tables, the server name is not properly quoted,
> which leads to unrestorable dumps.

Clearly a bug.

> Please look at the attached test case and the proposed patch.

I think this patch is not in keeping with typical coding practices in
pg_dump.  Usually we prefer to retrieve names from the server as-is,
then apply fmtId() when printing them --- this is more flexible than
having possibly-pre-quoted names in pg_dump's internal state.

Will fix it the latter way.  Thanks for the report!

			regards, tom lane



view thread (4+ messages)  latest in thread

Message-ID: <11056.1322499118@sss.pgh.pa.us>
Permalink:  ../11056.1322499118@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/11056.1322499118@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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, rdunklau@gmail.com
  Subject: Re: pg_dump - foreign table - server name is not quoted
  In-Reply-To: <11056.1322499118@sss.pgh.pa.us>
  References: <4ED38CE3.5060503@gmail.com> <11056.1322499118@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