Skip to content

Commit 937aaf0

Browse files
authored
Merge pull request #268 from oceanbase/cherry-pick-e655f24a-to-hbase_2.0.0-alpha4-20250708_175932
Cherry-pick: fix tableExists namespace not exists throw exception
2 parents 9f03f84 + b0c76e7 commit 937aaf0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/alipay/oceanbase/hbase/util/OHAdmin.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ public boolean tableExists(TableName tableName) throws IOException {
9999
int errCode = ((ObTableException) cause).getErrorCode();
100100
// if the original cause is database_not_exist, means namespace in tableName does not exist
101101
// for HBase, namespace not exist will not throw exceptions but will return false
102-
if (errCode == ResultCodes.OB_ERR_BAD_DATABASE.errorCode) {
102+
if (errCode == ResultCodes.OB_KV_HBASE_NAMESPACE_NOT_FOUND.errorCode) {
103103
return false;
104104
}
105105
}

0 commit comments

Comments
 (0)