phoenix-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James Taylor <jamestay...@apache.org>
Subject Re: Is it appropriate to switch between immutable and mutable ?
Date Tue, 15 Sep 2015 13:57:18 GMT
For most cases, you're able to delete from a table with immutable rows (I
believe as of 4.2 release), so that kind of switching shouldn't be
necessary. In theory, that switching should be ok, but I'm not sure we've
tested that code path when the table has an index.

Thanks,
James

On Tuesday, September 15, 2015, zz d <zzd7zzd@gmail.com> wrote:

> For example:
>
>     CREATE TABLE test(
>         id BIGINT NOT NULL PRIMARY KEY,
>         value  BIGINT
>     ) IMMUTABLE_ROWS=true;
>
>     CREATE INDEX idx ON test(id, value);
>
> As I know:
>
> > Creating indexes on tables with immutable rows should only be used for
> use cases where the data is written once and not deleted.
>
> and
>
> > If you have an existing table that you’d like to switch from immutable
> indexing to mutable indexing, use the ALTER TABLE command as show below:
>
>    ALTER TABLE my_table SET IMMUTABLE_ROWS=false;
>
> So, can I change the table to "IMMUTABLE_ROWS=false" when I want to delete
> some bad data, and after that, I set "IMMUTABLE_ROWS=true" back ?
>
> Will this way damage something ?
>
> Thanks.
>

Mime
View raw message