diff --git a/msg/de_DE.utf8/cubrid.msg b/msg/de_DE.utf8/cubrid.msg index 57f4f228205..52009dc3dea 100644 --- a/msg/de_DE.utf8/cubrid.msg +++ b/msg/de_DE.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Isolation Pegelwert in MVCC muss 'read committed', 'repeatable read' oder 'serializable'. 81 '%1$s' ist ein 'auto_increment' Objekt, das nicht erlaubt als serielle verändert werden wird. 82 Ungültiger JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** Ungültiges Cache *** diff --git a/msg/en_US.utf8/cubrid.msg b/msg/en_US.utf8/cubrid.msg index 0693913cf0b..fafac03bc77 100644 --- a/msg/en_US.utf8/cubrid.msg +++ b/msg/en_US.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Isolation level value in MVCC must be 'read committed', 'repeatable read' or 'serializable'. 81 '%1$s' is an 'auto_increment' object, which is not allowed to be altered as a serial. 82 Invalid JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** invalid cache *** diff --git a/msg/en_US/cubrid.msg b/msg/en_US/cubrid.msg index bc48ab423bb..81a236a1b0c 100644 --- a/msg/en_US/cubrid.msg +++ b/msg/en_US/cubrid.msg @@ -2012,6 +2012,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Isolation level value in MVCC must be 'read committed', 'repeatable read' or 'serializable'. 81 '%1$s' is an 'auto_increment' object, which is not allowed to be altered as a serial. 82 Invalid JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** invalid cache *** diff --git a/msg/es_ES.utf8/cubrid.msg b/msg/es_ES.utf8/cubrid.msg index 21cb777cb32..386ed17e352 100644 --- a/msg/es_ES.utf8/cubrid.msg +++ b/msg/es_ES.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 El valor del nivel de aislamiento en MVCC debe ser 'read committed', 'readable read' o 'serializable'. 81 '%1$s' es un objeto 'auto_increment', que no se puede alterar como serial. 82 JSON inválido: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** Cache no valida. *** diff --git a/msg/fr_FR.utf8/cubrid.msg b/msg/fr_FR.utf8/cubrid.msg index 2d7eb7f2141..2f5e1cfd5e7 100644 --- a/msg/fr_FR.utf8/cubrid.msg +++ b/msg/fr_FR.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 La valeur de niveau d'isolement dans MVCC doit être 'read committed', 'repeatable read' ou 'serializable'. 81 '%1$s' est un objet 'auto_increment', qui n'est pas autorisé à être modifié comme 'serial'. 82 JSON invalide: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** cache invalide *** diff --git a/msg/it_IT.utf8/cubrid.msg b/msg/it_IT.utf8/cubrid.msg index 32053345af0..bf25234a059 100644 --- a/msg/it_IT.utf8/cubrid.msg +++ b/msg/it_IT.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Valore del livello isolation in MVCC deve essere 'read committed', 'repeatable read' o 'serializable'. 81 '%1$s' è un 'auto_increment' oggetto, che non può essere modificato come un seriale. 82 JSON non valido: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** cache non valido *** diff --git a/msg/ja_JP.utf8/cubrid.msg b/msg/ja_JP.utf8/cubrid.msg index d612f7214e6..e39d93e7233 100644 --- a/msg/ja_JP.utf8/cubrid.msg +++ b/msg/ja_JP.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 MVCCで分離レベルの値は、「read committed」、「repeatable read」または「serializable」でなければなりません。 81 「%1$s」は「auto_increment」オブジェクトです。これはシリアルように変更することが許可されていません。 82 Invalid JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** 正しくないキャッシュ *** diff --git a/msg/km_KH.utf8/cubrid.msg b/msg/km_KH.utf8/cubrid.msg index 47c738209af..9079cdf9946 100644 --- a/msg/km_KH.utf8/cubrid.msg +++ b/msg/km_KH.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Isolation level value in MVCC must be 'read committed', 'repeatable read' or 'serializable'. 81 '%1$s' is an 'auto_increment' object, which is not allowed to be altered as a serial. 82 Invalid JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** invalid cache *** diff --git a/msg/ko_KR.euckr/cubrid.msg b/msg/ko_KR.euckr/cubrid.msg index 8b428c6675a..5c55dcf5989 100644 --- a/msg/ko_KR.euckr/cubrid.msg +++ b/msg/ko_KR.euckr/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Ʈ ݸ 'read committed', 'repeatable read', 'serializable' ϳ մϴ. 81 '%1$s' auto_increment üμ serial üó ϴ. 82 ȿ JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** ߸ ij *** diff --git a/msg/ko_KR.utf8/cubrid.msg b/msg/ko_KR.utf8/cubrid.msg index f3dc8bc38cc..333c900c2ee 100644 --- a/msg/ko_KR.utf8/cubrid.msg +++ b/msg/ko_KR.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 트랜잭션 격리도는 'read committed', 'repeatable read', 'serializable' 중의 하나여야 합니다. 81 '%1$s'은 auto_increment 객체로서 serial 객체처럼 변경할 수 없습니다. 82 유효하지 않은 JSON: '%1$s'. +83 Vclass %1$s is not updatable. Please check if any of its related classes are marked as REUSE_OID. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** 잘못된 캐시 *** diff --git a/msg/ro_RO.utf8/cubrid.msg b/msg/ro_RO.utf8/cubrid.msg index 99266742718..2bedf2f742d 100644 --- a/msg/ro_RO.utf8/cubrid.msg +++ b/msg/ro_RO.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Nivelul de izolare MVCC trebuie să fie 'read committed', 'repeatable read' sau'serializable'. 81 '%1$s' este un obiect 'auto_increment', care nu poate fi modificat ca serial. 82 JSON invalid: '%1$s'. +83 Vclass %1$s is not updatable because the vclass has some reuse_oid table. Please check it. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** cache invalid *** diff --git a/msg/tr_TR.utf8/cubrid.msg b/msg/tr_TR.utf8/cubrid.msg index 1254b4256fc..5f69e180ebf 100644 --- a/msg/tr_TR.utf8/cubrid.msg +++ b/msg/tr_TR.utf8/cubrid.msg @@ -2011,6 +2011,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 MVCC tecrit seviye değerlerini 'read committed', 'repeatable read' ya da 'serializable' olması gerekir. 81 '%1$s' bir 'auto_increment' nesne olduğunu, seri olarak değiştirilebilir izin verilmez. 82 Geçersiz JSON: '%1$s'. +83 Vclass %1$s is not updatable because the vclass has some reuse_oid table. Please check it. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** geçersiz önbellek *** diff --git a/msg/vi_VN.utf8/cubrid.msg b/msg/vi_VN.utf8/cubrid.msg index d0873ef2f73..6b1364fe52e 100644 --- a/msg/vi_VN.utf8/cubrid.msg +++ b/msg/vi_VN.utf8/cubrid.msg @@ -2018,6 +2018,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 Isolation level value in MVCC must be 'read committed', 'repeatable read' or 'serializable'. 81 '%1$s' is an 'auto_increment' object, which is not allowed to be altered as a serial. 82 Invalid JSON: '%1$s'. +83 Vclass %1$s is not updatable because the vclass has some reuse_oid table. Please check it. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** invalid cache *** diff --git a/msg/zh_CN.utf8/cubrid.msg b/msg/zh_CN.utf8/cubrid.msg index a130430eceb..8ca80aacd03 100644 --- a/msg/zh_CN.utf8/cubrid.msg +++ b/msg/zh_CN.utf8/cubrid.msg @@ -2012,6 +2012,7 @@ $set 9 MSGCAT_SET_PARSER_RUNTIME 80 MVCC中的隔离级别值必须是 'read committed', 'repeatable read' 或 'serializable'. 81 '%1$s' 是一个 'auto_increment' 对象, 不允许改变成一个序列. 82 无效的JSON: '%1$s'. +83 Vclass %1$s is not updatable because the vclass has some reuse_oid table. Please check it. $set 11 MSGCAT_SET_AUTHORIZATION 1 *** 无效的缓存 *** diff --git a/src/parser/parse_tree.h b/src/parser/parse_tree.h index 67e83fa7a81..43a9d9d39fe 100644 --- a/src/parser/parse_tree.h +++ b/src/parser/parse_tree.h @@ -1816,6 +1816,7 @@ struct view_cache_info int number_of_attrs; DB_AUTH authorization; NESTED_VIEW_VERSION_INFO *nested_views; + bool has_reuse_oid_table; }; struct parser_hint diff --git a/src/parser/parser_message.h b/src/parser/parser_message.h index 2d501798d32..db12d2d46b9 100644 --- a/src/parser/parser_message.h +++ b/src/parser/parser_message.h @@ -574,4 +574,5 @@ #define MSGCAT_MVCC_RUNTIME_XACT_ISO_LVL_MSG MSGCAT_RUNTIME_NO(80) #define MSGCAT_RUNTIME_INVALID_AUTO_INCREMENT_ALTER MSGCAT_RUNTIME_NO(81) #define MSGCAT_RUNTIME_INVALID_JSON MSGCAT_RUNTIME_NO(82) +#define MSGCAT_RUNTIME_REUSE_OID_TABLE_NOT_UPDATABLE MSGCAT_RUNTIME_NO(83) #endif /* _PARSER_MESSAGE_H_ */ diff --git a/src/parser/view_transform.c b/src/parser/view_transform.c index f8dca23e986..fe3eec4aa90 100644 --- a/src/parser/view_transform.c +++ b/src/parser/view_transform.c @@ -186,8 +186,7 @@ static PT_NODE *mq_rewrite_agg_names (PARSER_CONTEXT * parser, PT_NODE * node, v static PT_NODE *mq_rewrite_agg_names_post (PARSER_CONTEXT * parser, PT_NODE * node, void *void_arg, int *continue_walk); static bool mq_conditionally_add_objects (PARSER_CONTEXT * parser, PT_NODE * flat, DB_OBJECT *** classes, int *index, int *max); -static PT_UPDATABILITY mq_updatable_local (PARSER_CONTEXT * parser, PT_NODE * statement, DB_OBJECT *** classes, int *i, - int *max); +static PT_UPDATABILITY mq_updatable_local (PARSER_CONTEXT * parser, PT_NODE * statement, DB_OBJECT *** classes, int *i); static PT_NODE *mq_substitute_select_in_statement (PARSER_CONTEXT * parser, PT_NODE * statement, PT_NODE * query_spec, PT_NODE * class_); static PT_NODE *mq_substitute_select_for_inline_view (PARSER_CONTEXT * parser, PT_NODE * statement, @@ -1155,6 +1154,10 @@ mq_updatable_local (PARSER_CONTEXT * parser, PT_NODE * statement, DB_OBJECT *** if (sm_is_reuse_oid_class ((*classes)[i]) || sm_is_system_class ((*classes)[i]) > 0) { local = (PT_UPDATABILITY) (local & PT_NOT_UPDATABLE); + if (parser->view_cache) + { + parser->view_cache->has_reuse_oid_table = true; + } break; } } @@ -1207,6 +1210,7 @@ mq_updatable (PARSER_CONTEXT * parser, PT_NODE * statement) PT_UPDATABILITY updatable; int num_classes = 0; int max = MAX_STACK_OBJECTS; + DB_OBJECT *class_stack_array[MAX_STACK_OBJECTS]; DB_OBJECT **classes = class_stack_array; @@ -11717,9 +11721,18 @@ mq_fetch_subqueries_for_update_local (PARSER_CONTEXT * parser, PT_NODE * class_, if (!query_cache->view_cache->vquery_for_update && (!query_cache->view_cache->vquery_for_partial_update || (fetch_as != PT_PARTIAL_SELECT)) && parser) { - PT_ERRORmf (parser, class_, MSGCAT_SET_PARSER_RUNTIME, MSGCAT_RUNTIME_VCLASS_NOT_UPDATABLE, - /* use function to get name. class_->info.name.original is not always set. */ - db_get_class_name (class_object)); + if (query_cache->view_cache->has_reuse_oid_table) + { + PT_ERRORmf (parser, class_, MSGCAT_SET_PARSER_RUNTIME, MSGCAT_RUNTIME_REUSE_OID_TABLE_NOT_UPDATABLE, + /* use function to get name. class_->info.name.original is not always set. */ + db_get_class_name (class_object)); + } + else + { + PT_ERRORmf (parser, class_, MSGCAT_SET_PARSER_RUNTIME, MSGCAT_RUNTIME_VCLASS_NOT_UPDATABLE, + /* use function to get name. class_->info.name.original is not always set. */ + db_get_class_name (class_object)); + } } if (fetch_as == PT_INVERTED_ASSIGNMENTS) {