Loading mysql-test/r/grant.result +3 −0 Original line number Diff line number Diff line Loading @@ -440,3 +440,6 @@ insert into tables_priv values ('','test_db','mysqltest_1','test_table','test_gr flush privileges; delete from tables_priv where host = '' and user = 'mysqltest_1'; flush privileges; set @user123="non-existent"; select * from mysql.db where user=@user123; Host Db User Select_priv Insert_priv Update_priv Delete_priv Create_priv Drop_priv Grant_priv References_priv Index_priv Alter_priv Create_tmp_table_priv Lock_tables_priv mysql-test/t/grant.test +7 −0 Original line number Diff line number Diff line Loading @@ -402,4 +402,11 @@ flush privileges; delete from tables_priv where host = '' and user = 'mysqltest_1'; flush privileges; # # Bug #10892 user variables not auto cast for comparisons # Check that we don't get illegal mix of collations # set @user123="non-existent"; select * from mysql.db where user=@user123; # End of 4.1 tests sql/item.cc +8 −4 Original line number Diff line number Diff line Loading @@ -455,14 +455,18 @@ bool DTCollation::aggregate(DTCollation &dt, uint flags) ; // Do nothing } else if ((flags & MY_COLL_ALLOW_SUPERSET_CONV) && derivation < dt.derivation && collation->state & MY_CS_UNICODE) collation->state & MY_CS_UNICODE && (derivation < dt.derivation || (derivation == dt.derivation && !(dt.collation->state & MY_CS_UNICODE)))) { // Do nothing } else if ((flags & MY_COLL_ALLOW_SUPERSET_CONV) && dt.derivation < derivation && dt.collation->state & MY_CS_UNICODE) dt.collation->state & MY_CS_UNICODE && (dt.derivation < derivation || (dt.derivation == derivation && !(collation->state & MY_CS_UNICODE)))) { set(dt); } Loading Loading
mysql-test/r/grant.result +3 −0 Original line number Diff line number Diff line Loading @@ -440,3 +440,6 @@ insert into tables_priv values ('','test_db','mysqltest_1','test_table','test_gr flush privileges; delete from tables_priv where host = '' and user = 'mysqltest_1'; flush privileges; set @user123="non-existent"; select * from mysql.db where user=@user123; Host Db User Select_priv Insert_priv Update_priv Delete_priv Create_priv Drop_priv Grant_priv References_priv Index_priv Alter_priv Create_tmp_table_priv Lock_tables_priv
mysql-test/t/grant.test +7 −0 Original line number Diff line number Diff line Loading @@ -402,4 +402,11 @@ flush privileges; delete from tables_priv where host = '' and user = 'mysqltest_1'; flush privileges; # # Bug #10892 user variables not auto cast for comparisons # Check that we don't get illegal mix of collations # set @user123="non-existent"; select * from mysql.db where user=@user123; # End of 4.1 tests
sql/item.cc +8 −4 Original line number Diff line number Diff line Loading @@ -455,14 +455,18 @@ bool DTCollation::aggregate(DTCollation &dt, uint flags) ; // Do nothing } else if ((flags & MY_COLL_ALLOW_SUPERSET_CONV) && derivation < dt.derivation && collation->state & MY_CS_UNICODE) collation->state & MY_CS_UNICODE && (derivation < dt.derivation || (derivation == dt.derivation && !(dt.collation->state & MY_CS_UNICODE)))) { // Do nothing } else if ((flags & MY_COLL_ALLOW_SUPERSET_CONV) && dt.derivation < derivation && dt.collation->state & MY_CS_UNICODE) dt.collation->state & MY_CS_UNICODE && (dt.derivation < derivation || (dt.derivation == derivation && !(collation->state & MY_CS_UNICODE)))) { set(dt); } Loading