Fix error info bug
This commit is contained in:
@ -2017,8 +2017,14 @@ int ObAlterTableResolver::resolve_drop_index(const ParseNode &node)
|
|||||||
true /* index table */,
|
true /* index table */,
|
||||||
index_table_schema))) {
|
index_table_schema))) {
|
||||||
if (OB_TABLE_NOT_EXIST == ret) {
|
if (OB_TABLE_NOT_EXIST == ret) {
|
||||||
LOG_USER_ERROR(OB_TABLE_NOT_EXIST, to_cstring(alter_table_stmt->get_org_database_name()),
|
if (is_mysql_mode()) {
|
||||||
to_cstring(alter_table_stmt->get_org_table_name()));
|
ret = OB_ERR_CANT_DROP_FIELD_OR_KEY;
|
||||||
|
LOG_WARN("index does not exist", K(ret), K(drop_index_name));
|
||||||
|
LOG_USER_ERROR(OB_ERR_CANT_DROP_FIELD_OR_KEY, drop_index_name.length(), drop_index_name.ptr());
|
||||||
|
} else {
|
||||||
|
LOG_USER_ERROR(OB_TABLE_NOT_EXIST, to_cstring(alter_table_stmt->get_org_database_name()),
|
||||||
|
to_cstring(alter_table_stmt->get_org_table_name()));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
LOG_WARN("fail to get index table schema", K(ret));
|
LOG_WARN("fail to get index table schema", K(ret));
|
||||||
} else if (OB_ISNULL(index_table_schema)) {
|
} else if (OB_ISNULL(index_table_schema)) {
|
||||||
|
|||||||
@ -1838,7 +1838,13 @@ int ObRawExprUtils::check_deterministic_single(const ObRawExpr *expr,
|
|||||||
int ret = OB_SUCCESS;
|
int ret = OB_SUCCESS;
|
||||||
CK (OB_NOT_NULL(expr));
|
CK (OB_NOT_NULL(expr));
|
||||||
if (OB_SUCC(ret) && ObResolverUtils::DISABLE_CHECK != check_status) {
|
if (OB_SUCC(ret) && ObResolverUtils::DISABLE_CHECK != check_status) {
|
||||||
if (expr->is_sys_func_expr()) {
|
if (is_oracle_mode()
|
||||||
|
&& (T_FUN_SYS_DEFAULT == expr->get_expr_type()
|
||||||
|
|| T_OP_IS == expr->get_expr_type())) {
|
||||||
|
ret = OB_NOT_SUPPORTED;
|
||||||
|
LOG_USER_ERROR(OB_NOT_SUPPORTED, "Use special functions in generated columns");
|
||||||
|
LOG_WARN("special function is not suppored in generated column", K(ret), KPC(expr));
|
||||||
|
} else if (expr->is_sys_func_expr()) {
|
||||||
bool is_non_pure_func = false;
|
bool is_non_pure_func = false;
|
||||||
if (OB_FAIL(expr->is_non_pure_sys_func_expr(is_non_pure_func))) {
|
if (OB_FAIL(expr->is_non_pure_sys_func_expr(is_non_pure_func))) {
|
||||||
LOG_WARN("check is non pure sys func expr failed", K(ret));
|
LOG_WARN("check is non pure sys func expr failed", K(ret));
|
||||||
|
|||||||
Reference in New Issue
Block a user