Loading acinclude.m4 +6 −1 Original line number Diff line number Diff line Loading @@ -746,7 +746,12 @@ AC_MSG_CHECKING(for OpenSSL) AC_DEFINE(HAVE_VIO) AC_MSG_RESULT(yes) openssl_libs="-L$OPENSSL_LIB -lssl -lcrypto" # Don't set openssl_includes to /usr/include as this gives us a lot of # compiler warnings when using gcc 3.x if test "$OPENSSL_INCLUDE" != "/usr/include" then openssl_includes="-I$OPENSSL_INCLUDE" fi AC_DEFINE(HAVE_OPENSSL) # openssl-devel-0.9.6 requires dlopen() and we can't link staticly Loading myisam/mi_delete_all.c +5 −0 Original line number Diff line number Diff line Loading @@ -52,6 +52,11 @@ int mi_delete_all_rows(MI_INFO *info) VOID(_mi_writeinfo(info,WRITEINFO_UPDATE_KEYFILE)); if (my_chsize(info->dfile, 0, 0, MYF(MY_WME))) goto err; /* If we are using delayed keys or if the user has done changes to the tables since it was locked then there may be key blocks in the key cache */ flush_key_blocks(share->kfile, FLUSH_IGNORE_CHANGED); allow_break(); /* Allow SIGHUP & SIGINT */ DBUG_RETURN(0); Loading mysql-test/r/null_key.result +34 −1 Original line number Diff line number Diff line Loading @@ -188,10 +188,43 @@ id uniq_id 4 2 7 3 8 4 DROP table t1,t2; CREATE TABLE `t1` ( `order_id` char(32) NOT NULL default '', `product_id` char(32) NOT NULL default '', `product_type` int(11) NOT NULL default '0', PRIMARY KEY (`order_id`,`product_id`,`product_type`) ) TYPE=MyISAM; CREATE TABLE `t2` ( `order_id` char(32) NOT NULL default '', `product_id` char(32) NOT NULL default '', `product_type` int(11) NOT NULL default '0', PRIMARY KEY (`order_id`,`product_id`,`product_type`) ) TYPE=MyISAM; INSERT INTO t1 (order_id, product_id, product_type) VALUES ('3d7ce39b5d4b3e3d22aaafe9b633de51',1206029, 3), ('3d7ce39b5d4b3e3d22aaafe9b633de51',5880836, 3), ('9d9aad7764b5b2c53004348ef8d34500',2315652, 3); INSERT INTO t2 (order_id, product_id, product_type) VALUES ('9d9aad7764b5b2c53004348ef8d34500',2315652, 3); select t1.* from t1 left join t2 using(order_id, product_id, product_type) where t2.order_id=NULL; order_id product_id product_type select t1.* from t1 left join t2 using(order_id, product_id, product_type) where t2.order_id is NULL; order_id product_id product_type 3d7ce39b5d4b3e3d22aaafe9b633de51 1206029 3 3d7ce39b5d4b3e3d22aaafe9b633de51 5880836 3 drop table t1,t2; create table t1 (id int); insert into t1 values (null), (0); create table t2 (id int); insert into t2 values (null); select * from t1, t2 where t1.id = t2.id; id id alter table t1 add key id (id); select * from t1, t2 where t1.id = t2.id; id id DROP table t1,t2; drop table t1,t2; sql/ha_innodb.cc +0 −40 Original line number Diff line number Diff line Loading @@ -3640,46 +3640,6 @@ ha_innobase::reset(void) } /********************************************************************** When we create a temporary table inside MySQL LOCK TABLES, MySQL will not call external_lock for the temporary table when it uses it. Instead, it will call this function. */ int ha_innobase::start_stmt( /*====================*/ /* out: 0 or error code */ THD* thd) /* in: handle to the user thread */ { row_prebuilt_t* prebuilt = (row_prebuilt_t*) innobase_prebuilt; trx_t* trx; update_thd(thd); trx = prebuilt->trx; innobase_release_stat_resources(trx); trx_mark_sql_stat_end(trx); auto_inc_counter_for_this_stat = 0; prebuilt->sql_stat_start = TRUE; prebuilt->hint_no_need_to_fetch_extra_cols = TRUE; prebuilt->read_just_key = 0; if (prebuilt->select_lock_type == LOCK_NONE) { /* This handle is for a temporary table created inside this same LOCK TABLES; since MySQL does NOT call external_lock in this case, we must use x-row locks inside InnoDB to be prepared for an update of a row */ prebuilt->select_lock_type = LOCK_X; } thd->transaction.all.innodb_active_trans = 1; return(0); } /********************************************************************** When we create a temporary table inside MySQL LOCK TABLES, MySQL will not call external_lock for the temporary table when it uses it. Instead, Loading sql/sql_parse.cc +4 −4 Original line number Diff line number Diff line Loading @@ -3356,10 +3356,10 @@ bool reload_acl_and_cache(THD *thd, ulong options, TABLE_LIST *tables) } if (options & REFRESH_LOG) { mysql_log.new_file(0); mysql_update_log.new_file(0); mysql_bin_log.new_file(0); mysql_slow_log.new_file(0); mysql_log.new_file(1); mysql_update_log.new_file(1); mysql_bin_log.new_file(1); mysql_slow_log.new_file(1); if (ha_flush_logs()) result=1; } Loading Loading
acinclude.m4 +6 −1 Original line number Diff line number Diff line Loading @@ -746,7 +746,12 @@ AC_MSG_CHECKING(for OpenSSL) AC_DEFINE(HAVE_VIO) AC_MSG_RESULT(yes) openssl_libs="-L$OPENSSL_LIB -lssl -lcrypto" # Don't set openssl_includes to /usr/include as this gives us a lot of # compiler warnings when using gcc 3.x if test "$OPENSSL_INCLUDE" != "/usr/include" then openssl_includes="-I$OPENSSL_INCLUDE" fi AC_DEFINE(HAVE_OPENSSL) # openssl-devel-0.9.6 requires dlopen() and we can't link staticly Loading
myisam/mi_delete_all.c +5 −0 Original line number Diff line number Diff line Loading @@ -52,6 +52,11 @@ int mi_delete_all_rows(MI_INFO *info) VOID(_mi_writeinfo(info,WRITEINFO_UPDATE_KEYFILE)); if (my_chsize(info->dfile, 0, 0, MYF(MY_WME))) goto err; /* If we are using delayed keys or if the user has done changes to the tables since it was locked then there may be key blocks in the key cache */ flush_key_blocks(share->kfile, FLUSH_IGNORE_CHANGED); allow_break(); /* Allow SIGHUP & SIGINT */ DBUG_RETURN(0); Loading
mysql-test/r/null_key.result +34 −1 Original line number Diff line number Diff line Loading @@ -188,10 +188,43 @@ id uniq_id 4 2 7 3 8 4 DROP table t1,t2; CREATE TABLE `t1` ( `order_id` char(32) NOT NULL default '', `product_id` char(32) NOT NULL default '', `product_type` int(11) NOT NULL default '0', PRIMARY KEY (`order_id`,`product_id`,`product_type`) ) TYPE=MyISAM; CREATE TABLE `t2` ( `order_id` char(32) NOT NULL default '', `product_id` char(32) NOT NULL default '', `product_type` int(11) NOT NULL default '0', PRIMARY KEY (`order_id`,`product_id`,`product_type`) ) TYPE=MyISAM; INSERT INTO t1 (order_id, product_id, product_type) VALUES ('3d7ce39b5d4b3e3d22aaafe9b633de51',1206029, 3), ('3d7ce39b5d4b3e3d22aaafe9b633de51',5880836, 3), ('9d9aad7764b5b2c53004348ef8d34500',2315652, 3); INSERT INTO t2 (order_id, product_id, product_type) VALUES ('9d9aad7764b5b2c53004348ef8d34500',2315652, 3); select t1.* from t1 left join t2 using(order_id, product_id, product_type) where t2.order_id=NULL; order_id product_id product_type select t1.* from t1 left join t2 using(order_id, product_id, product_type) where t2.order_id is NULL; order_id product_id product_type 3d7ce39b5d4b3e3d22aaafe9b633de51 1206029 3 3d7ce39b5d4b3e3d22aaafe9b633de51 5880836 3 drop table t1,t2; create table t1 (id int); insert into t1 values (null), (0); create table t2 (id int); insert into t2 values (null); select * from t1, t2 where t1.id = t2.id; id id alter table t1 add key id (id); select * from t1, t2 where t1.id = t2.id; id id DROP table t1,t2; drop table t1,t2;
sql/ha_innodb.cc +0 −40 Original line number Diff line number Diff line Loading @@ -3640,46 +3640,6 @@ ha_innobase::reset(void) } /********************************************************************** When we create a temporary table inside MySQL LOCK TABLES, MySQL will not call external_lock for the temporary table when it uses it. Instead, it will call this function. */ int ha_innobase::start_stmt( /*====================*/ /* out: 0 or error code */ THD* thd) /* in: handle to the user thread */ { row_prebuilt_t* prebuilt = (row_prebuilt_t*) innobase_prebuilt; trx_t* trx; update_thd(thd); trx = prebuilt->trx; innobase_release_stat_resources(trx); trx_mark_sql_stat_end(trx); auto_inc_counter_for_this_stat = 0; prebuilt->sql_stat_start = TRUE; prebuilt->hint_no_need_to_fetch_extra_cols = TRUE; prebuilt->read_just_key = 0; if (prebuilt->select_lock_type == LOCK_NONE) { /* This handle is for a temporary table created inside this same LOCK TABLES; since MySQL does NOT call external_lock in this case, we must use x-row locks inside InnoDB to be prepared for an update of a row */ prebuilt->select_lock_type = LOCK_X; } thd->transaction.all.innodb_active_trans = 1; return(0); } /********************************************************************** When we create a temporary table inside MySQL LOCK TABLES, MySQL will not call external_lock for the temporary table when it uses it. Instead, Loading
sql/sql_parse.cc +4 −4 Original line number Diff line number Diff line Loading @@ -3356,10 +3356,10 @@ bool reload_acl_and_cache(THD *thd, ulong options, TABLE_LIST *tables) } if (options & REFRESH_LOG) { mysql_log.new_file(0); mysql_update_log.new_file(0); mysql_bin_log.new_file(0); mysql_slow_log.new_file(0); mysql_log.new_file(1); mysql_update_log.new_file(1); mysql_bin_log.new_file(1); mysql_slow_log.new_file(1); if (ha_flush_logs()) result=1; } Loading