Commit 1d1b10e9 authored by Sergei Petrunia's avatar Sergei Petrunia

MariaRocks: rocksdb.rocksdb fails with a duplicate key error

In MariaDB, Field::make_sort_key stores NULL-indicator byte for
the field.
In MySQL, it doesn't, so MyRocks stores the NULL-indicator itself.

Switch to using Field::sort_string, which is the same as
Field::make_sort_key in MySQL.
parent 3ac33f8c
......@@ -741,7 +741,7 @@ void rdb_pack_with_make_sort_key(Rdb_field_packing *fpi, Field *field,
DBUG_ASSERT(*dst != nullptr);
const int max_len= fpi->m_max_image_len;
field->make_sort_key(*dst, max_len);
field->sort_string(*dst, max_len);
*dst += max_len;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment