From 2dba06a3a3f123c4ead8c6ff196ae43f2e7fda91 Mon Sep 17 00:00:00 2001 From: xf0 Date: Fri, 24 Dec 2021 10:55:35 +0800 Subject: [PATCH] fix a bug of ignore null value in not null text/blob column in mysql dml --- src/share/object/ob_obj_cast.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/share/object/ob_obj_cast.cpp b/src/share/object/ob_obj_cast.cpp index 8102a5a082..b69d8b8fda 100644 --- a/src/share/object/ob_obj_cast.cpp +++ b/src/share/object/ob_obj_cast.cpp @@ -8680,6 +8680,8 @@ int ObObjCaster::get_zero_value(const ObObjType expect_type, ObCollationType exp params.warning_ = 1; if (ob_is_string_tc(expect_type)) { zero_obj.set_string(expect_type, ""); + } else if (ob_is_text_tc(expect_type)) { + zero_obj.set_lob_value(expect_type, static_cast(NULL), 0); } else if (ob_is_int_tc(expect_type)) { int64_t value = 0; SET_RES_INT(zero_obj);