mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-27 11:55:15 +00:00
In issues #7944 and #10625 it was noticed that by assigning an empty string to a non-string type (int, date, etc.) using INSERT or INSERT JSON, some combinations of the above can create "empty" values while they should produce a clear error. The tests added in this patch explore the different combinations of types and insert modes, and reproduce several buggy cases in Scylla (resulting in xfail'ing tests) as well as Cassandra. We feared that there might be a way using those buggy statements to create a partition with an empty key - something which used to kill older versions of Scylla. But the tests show that this is not possible - while a user can use the buggy statements to create an empty value, Scylla refuses it when it is used as a single-column partition key. Refs #10625 Refs #7944 Signed-off-by: Nadav Har'El <nyh@scylladb.com> Closes #10628