swaroopak commented on a change in pull request #699: PHOENIX-5496 Ensure that 
we handle all server-side mutation codes on the client
URL: https://github.com/apache/phoenix/pull/699#discussion_r377397994
 
 

 ##########
 File path: 
phoenix-core/src/main/java/org/apache/phoenix/schema/MetaDataClient.java
 ##########
 @@ -2964,18 +2965,11 @@ public boolean isViewReferenced() {
                     isNamespaceMapped, parent);
             MutationCode code = result.getMutationCode();
             if (code != MutationCode.TABLE_NOT_FOUND) {
-                if(code == MutationCode.TABLE_ALREADY_EXISTS) {
-                    if(result.getTable() != null){
-                        addTableToCache(result);
-                    }
-                    if(statement.ifNotExists()) {
-                        throw new TableAlreadyExistsException(schemaName, 
tableName, result.getTable());
-                    }
+                boolean mutationResult =  
handleCreateTableMutationCode(result, code, statement,
+                        schemaName, tableName, parent);
+                if(mutationResult)
                     return null;
 
 Review comment:
   nit: please put braces around the `if` block

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to