File tree Expand file tree Collapse file tree 3 files changed +14
-0
lines changed Expand file tree Collapse file tree 3 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -5954,6 +5954,13 @@ SET @arg00=_binary 0xFF;
5954
5954
EXECUTE stmt USING @arg00;
5955
5955
ERROR HY000: Invalid utf8 character string: 'FF'
5956
5956
DEALLOCATE PREPARE stmt;
5957
+ SET NAMES latin1;
5958
+ PREPARE stmt FROM "SELECT CONCAT(_utf8'a' COLLATE utf8_unicode_ci, ?)";
5959
+ EXECUTE stmt USING @no_such_var;
5960
+ CONCAT(_utf8'a' COLLATE utf8_unicode_ci, ?)
5961
+ NULL
5962
+ DEALLOCATE PREPARE stmt;
5963
+ SET NAMES utf8;
5957
5964
#
5958
5965
# End of 10.0 tests
5959
5966
#
Original file line number Diff line number Diff line change @@ -1675,6 +1675,11 @@ SET @arg00=_binary 0xFF;
1675
1675
--error ER_INVALID_CHARACTER_STRING
1676
1676
EXECUTE stmt USING @arg00;
1677
1677
DEALLOCATE PREPARE stmt;
1678
+ SET NAMES latin1;
1679
+ PREPARE stmt FROM "SELECT CONCAT(_utf8'a' COLLATE utf8_unicode_ci, ?)";
1680
+ EXECUTE stmt USING @no_such_var;
1681
+ DEALLOCATE PREPARE stmt;
1682
+ SET NAMES utf8;
1678
1683
1679
1684
--echo #
1680
1685
--echo # End of 10.0 tests
Original file line number Diff line number Diff line change @@ -1274,6 +1274,8 @@ Item *Item_param::safe_charset_converter(CHARSET_INFO *tocs)
1274
1274
*/
1275
1275
if (const_item ())
1276
1276
{
1277
+ if (state == NULL_VALUE)
1278
+ return this ;
1277
1279
uint cnv_errors;
1278
1280
String *ostr= val_str (&cnvstr);
1279
1281
if (!needs_charset_converter (tocs))
You can’t perform that action at this time.
0 commit comments