Re: BUG #14315: pg_dump --no-tablespaces doesn't do it's job when --create specified

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: abcz2(dot)uprola(at)gmail(dot)com
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14315: pg_dump --no-tablespaces doesn't do it's job when --create specified
Date: 2016-09-08 14:05:28
Message-ID: 17757.1473343528@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

abcz2(dot)uprola(at)gmail(dot)com writes:
> But I noticed that --no-tablespaces doesn't change --create option to not
> include tablespaces:

> $ pg_dump -C --schema-only -U postgres -h test --no-tablespaces -d
> wp_analytics | grep "CREATE DATABASE"
> CREATE DATABASE wp_analytics WITH TEMPLATE = template0 ENCODING = 'UTF8'
> LC_COLLATE = 'en_US.UTF-8' LC_CTYPE = 'en_US.UTF-8' TABLESPACE =
> wp_tblspc;

> I think that it is a bug.

Yeah, I think you're right, especially since the corresponding code in
pg_dumpall does suppress the TABLESPACE clause with --no-tablespaces.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message lucian.ciufudean 2016-09-08 15:40:03 BUG #14317: psql \dt not working as expected
Previous Message Vitaly Burovoy 2016-09-08 11:24:25 Re: BUG #14316: union all with order by "missing from-clause"