From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Michael Paquier <michael(dot)paquier(at)gmail(dot)com> |
Cc: | Julien Rouhaud <julien(dot)rouhaud(at)dalibo(dot)com>, sudalai <sudalait2(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-bugs(at)postgresql(dot)org> |
Subject: | Re: Index file got removed |
Date: | 2016-11-23 22:46:11 |
Message-ID: | 4723.1479941171@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
Michael Paquier <michael(dot)paquier(at)gmail(dot)com> writes:
> On Thu, Nov 24, 2016 at 3:50 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> I think that this is the correct fix. There aren't any other callers
>> in the core code, and even if some third party is calling it, it's
>> fairly hard to see what usage would be okay with a TABLESPACE clause
>> being appended some of the time but not all of the time. Also, both
>> of the other proposed fixes seem like kluges to me.
> This fix looked like a kludge to me, that's why I did not do it :)
> Any code paths of ALTER TABLE calling DefineIndex won't take advantage
> of is_alter_table to define the tablespace, so we may be bitten again
> by the same kind of problems in the future.
Well, the reason that way seemed like a kluge is that I don't see what
connection is_alter_table has to overriding DefineIndex's normal idea
of which tablespace to use. I think that's at least as likely to
induce new bugs as fix them. For instance, wouldn't it change the
behavior of ALTER TABLE ADD PRIMARY KEY? It seems to me that that
command *should* honor default_tablespace, if there's no tablespace
clause in it.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2016-11-23 23:31:07 | Re: Index file got removed |
Previous Message | Michael Paquier | 2016-11-23 22:05:58 | Re: Index file got removed |