Commit 8eadb024 authored by monty@hundin.mysql.fi's avatar monty@hundin.mysql.fi
Browse files

Fixed mysqldumpslow for new dump format.

Fix for HEAP tables with many rows deleted.
Add '' arround database names in SHOW GRANT
parent c4b8c1b6
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -6252,7 +6252,7 @@ shell> groupadd mysql
shell> useradd -g mysql mysql
shell> cd /usr/local
shell> gunzip < /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
shell> ln -s mysql-VERSION-OS mysql
shell> ln -s full-path-to-mysql-VERSION-OS mysql
shell> cd mysql
shell> scripts/mysql_install_db
shell> chown -R root  .
@@ -6327,7 +6327,7 @@ Unpack the distribution and create the installation directory:
@example
shell> gunzip < /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
shell> ln -s mysql-VERSION-OS mysql
shell> ln -s full-path-to-mysql-VERSION-OS mysql
@end example
The first command creates a directory named @file{mysql-VERSION-OS}.  The
@@ -48703,6 +48703,8 @@ Our TODO section contains what we plan to have in 4.0. @xref{TODO MySQL 4.0}.
@itemize @bullet
@item
Fixed wrong error value when doing a @code{SELECT} with an empty HEAP table.
@item
Use @code{ORDER BY column DESC} now sorts @code{NULL} values first.
@item
Fixed bug in @code{SELECT DISTINCT ... ORDER BY DESC} optimization.
+0 −5
Original line number Diff line number Diff line
@@ -21,11 +21,6 @@
int heap_rfirst(HP_INFO *info, byte *record)
{
  DBUG_ENTER("heap_rfirst");
  if (!(info->s->records))
  {
    my_errno=HA_ERR_END_OF_FILE;
    DBUG_RETURN(my_errno);
  }
  info->current_record=0;
  info->current_hash_ptr=0;
  info->update=HA_STATE_PREV_FOUND;
+6 −0
Original line number Diff line number Diff line
@@ -197,3 +197,9 @@ a b
INSERT INTO t1 VALUES (1,3);
Duplicate entry '3' for key 1
DROP TABLE t1;
CREATE TABLE t1 (a int not null, primary key(a)) type=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
a
DROP TABLE t1;
+10 −0
Original line number Diff line number Diff line
@@ -128,3 +128,13 @@ SELECT * FROM t1 WHERE b<=>NULL;
--error 1062
INSERT INTO t1 VALUES (1,3);
DROP TABLE t1;

#
# Test when deleting all rows
#

CREATE TABLE t1 (a int not null, primary key(a)) type=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
DROP TABLE t1;
+1 −2
Original line number Diff line number Diff line
@@ -36,8 +36,7 @@ my_string my_load_path(my_string to, const char *path,
      test_if_hard_path(path))
    VOID(strmov(buff,path));
  else if ((path[0] == FN_CURLIB && path[1] == FN_LIBCHAR) ||
	   (is_prefix((gptr) path,FN_PARENTDIR) &&
	    path[strlen(FN_PARENTDIR)] == FN_LIBCHAR) ||
	   (is_prefix((gptr) path,FN_PARENTDIR)) ||
	   ! own_path_prefix)
  {
    if (! my_getwd(buff,(uint) (FN_REFLEN-strlen(path)),MYF(0)))
Loading