[
https://issues.apache.org/jira/browse/PHOENIX-2156?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thomas D'Silva updated PHOENIX-2156:
------------------------------------
Attachment: PHOENIX-2156-v2.patch
[~samarthjain] [~jamestaylor]
I have uploaded a modified patch with the review feedback.
testDropColumnsFromBaseTableWithView drops multiple columns from the base table
and verifies these are dropped from the view
testDroppingIndexedColDropsViewIndex drops two columns of a base table that has
views with multiple indexes.
I moved tests that are multi-tenant from AlterTableWithViewsIT to
AlterMultiTenantTableWithViewsIT and made the remaining tests parameterized to
run for multitenant/non-multitenant cases.
The ClassNotFoundException can be thrown when we get the PhoenixConnection. I
changed it so that its caught in dropIndexes.
{code}
try {
connection = table.getIndexes().isEmpty() ? null :
QueryUtil.getConnection(
env.getConfiguration()).unwrap(PhoenixConnection.class);
} catch (ClassNotFoundException e) {
}
{code}
> Support drop of column from table with views
> --------------------------------------------
>
> Key: PHOENIX-2156
> URL: https://issues.apache.org/jira/browse/PHOENIX-2156
> Project: Phoenix
> Issue Type: Sub-task
> Reporter: James Taylor
> Assignee: Thomas D'Silva
> Fix For: 4.8.0
>
> Attachments: PHOENIX-2156-v2.patch, PHOENIX-2156.patch
>
>
> Much like PHOENIX-1504 allows a column to be added to a base view, we should
> support dropping a column from a table that has views as well. These seems
> like a simpler problem: you just need to query for all views with a
> BASE_COLUMN_COUNT < dropped_column_ordinal_pos, decrement the ordinal
> positions of columns after that, and drop indexes that reference the column
> being dropped.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)