fix json/gis/text/blob meta response inconsistent with mysql5.7 (master)

This commit is contained in:
obdev
2023-11-03 03:39:29 +00:00
committed by ob-robot
parent 6267ac92d9
commit 4f162cdcc5
4 changed files with 14 additions and 7 deletions

View File

@ -1724,6 +1724,9 @@ void ObResultSet::replace_lob_type(const ObSQLSessionInfo &session,
// for 5.x, always return MYSQL_TYPE_BLOB
// for 8.x always return MYSQL_TYPE_BLOB, and do text type judge in mysql-jdbc by length
mfield.type_ = obmysql::EMySQLFieldType::MYSQL_TYPE_BLOB;
} else if (mfield.type_ == obmysql::EMySQLFieldType::MYSQL_TYPE_JSON) {
// for mysql 5.x json response as plain text not binary, but the charset always binary
mfield.charsetnr_ = common::CS_TYPE_BINARY;
}
}
}