private TableDesc handlExistence(boolean ifNotExists, String qualifiedName) throws DuplicateTableException, UndefinedTableException { if (ifNotExists) { LOG.info("relation \"" + qualifiedName + "\" is already exists."); return catalog.getTableDesc(qualifiedName); } else { throw new DuplicateTableException(qualifiedName); } }
private TableDesc handlExistence(boolean ifNotExists, String qualifiedName) throws DuplicateTableException, UndefinedTableException { if (ifNotExists) { LOG.info("relation \"" + qualifiedName + "\" is already exists."); return catalog.getTableDesc(qualifiedName); } else { throw new DuplicateTableException(qualifiedName); } }
private boolean assertRelationNoExistence(Context context, String tableName) { String qualifiedName = guessTableName(context, tableName); if (catalog.existsTable(qualifiedName)) { context.state.addVerification(new DuplicateTableException(qualifiedName)); return false; } return true; }
private boolean assertRelationNoExistence(Context context, String tableName) { String qualifiedName = guessTableName(context, tableName); if (catalog.existsTable(qualifiedName)) { context.state.addVerification(new DuplicateTableException(qualifiedName)); return false; } return true; }
throw new DuplicateTableException(tableName);
throw new DuplicateTableException(tableName);
throw new DuplicateTableException(alterTable.getNewTableName());
throw new DuplicateTableException(alterTable.getNewTableName());
case RENAME_TABLE: if (existTable(databaseName,alterTableDescProto.getNewTableName().toLowerCase())) { throw new DuplicateTableException(alterTableDescProto.getNewTableName());
String simpleNewTableName = CatalogUtil.extractSimpleName(alterTableDescProto.getNewTableName()); if (existTable(databaseName, simpleNewTableName)) { throw new DuplicateTableException(alterTableDescProto.getNewTableName());
String simpleNewTableName = extractSimpleName(alterTableDescProto.getNewTableName()); if (existTable(databaseName, simpleNewTableName)) { throw new DuplicateTableException(alterTableDescProto.getNewTableName());