Github user twdsilva commented on a diff in the pull request: https://github.com/apache/phoenix/pull/34#discussion_r23719273 --- Diff: phoenix-core/src/main/java/org/apache/phoenix/schema/MetaDataClient.java --- @@ -2051,7 +2087,7 @@ public MutationState addColumn(AddColumnStatement statement) throws SQLException } } - boolean isAddingPKColumn = false; + int numPkColumnsAdded = 0; --- End diff -- I need numPkColumnsAdded to initialize the pkColumns list later . The boolean isAddingPKColumn can be derived from numPkColumnsAdded, so I removed it, I can add it back using the boolean makes it more readable // create PK column list that includes the newly created columns List<PColumn> pkColumns = Lists.newArrayListWithExpectedSize(table.getPKColumns().size()+numPkColumnsAdded);
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---