mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
add json statistics test and change histogram column type to blob
This commit is contained in:
committed by
Sergei Petrunia
parent
2aca7b0c33
commit
79cdb535da
@@ -183,7 +183,7 @@ TABLE_FIELD_TYPE column_stat_fields[COLUMN_STAT_N_FIELDS] =
|
||||
},
|
||||
{
|
||||
{ STRING_WITH_LEN("histogram") },
|
||||
{ STRING_WITH_LEN("varbinary(255)") },
|
||||
{ STRING_WITH_LEN("blob") },
|
||||
{ NULL, 0 }
|
||||
}
|
||||
};
|
||||
@@ -1071,7 +1071,8 @@ public:
|
||||
break;
|
||||
case COLUMN_STAT_HISTOGRAM:
|
||||
if (stats->histogram.get_type() == JSON) {
|
||||
stat_field->store((char *) "hello_world", 11, &my_charset_bin);
|
||||
const char* val = "{'hello': 'world'}";
|
||||
stat_field->store(val, strlen(val), &my_charset_bin);
|
||||
} else {
|
||||
stat_field->store((char *) stats->histogram.get_values(),
|
||||
stats->histogram.get_size(), &my_charset_bin);
|
||||
|
Reference in New Issue
Block a user