Skip to content

Commit 77aad67

Browse files
obdevfootkaGarfiled
authored andcommitted
fix blob CS_TYPE_BINARY type output
Co-authored-by: footka <672528926@qq.com> Co-authored-by: Garfiled <799044397@qq.com>
1 parent c8342b5 commit 77aad67

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/observer/embed/python/ob_embed_impl.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -939,6 +939,8 @@ int ObLiteEmbedUtil::convert_result_to_pyobj(const int64_t col_idx, common::sqlc
939939
LOG_WARN("get obj failed", K(ret), K(col_idx));
940940
} else if (OB_FAIL(sql::ObTextStringHelper::read_real_string_data(&allocator, obj, real_data))) {
941941
LOG_WARN("failed to read real string data", K(ret), K(obj));
942+
} else if (obj_meta.get_collation_type() == ObCollationType::CS_TYPE_BINARY) {
943+
val = pybind11::bytes(real_data.ptr(), real_data.length());
942944
} else {
943945
ObString out_str;
944946
if (OB_FAIL(convert_string_charset(session, allocator, real_data,

0 commit comments

Comments
 (0)