diff options
author | unknown <monty@mysql.com> | 2003-12-11 06:24:08 +0200 |
---|---|---|
committer | unknown <monty@mysql.com> | 2003-12-11 06:24:08 +0200 |
commit | 287661e66cc1fea6730b357bb56d48c6d065ef43 (patch) | |
tree | 1122f20a76a6996599a4c136c6be17aecb8f8bf6 /mysql-test/t/limit.test | |
parent | 4119451ba1065274be6435349a786f7995fd4dae (diff) | |
download | mariadb-git-287661e66cc1fea6730b357bb56d48c6d065ef43.tar.gz |
Fixed a possible memory leak on MacOSX when using the shared libmysql.so library (Bug #2061)
mysql_server_init() now returns error code if something went wrong (Bug #2062)
Don't use my_fopen() when reading symlink information as this may cause problems when a lot of files are opened.
Free thread keys with pthread_key_delete() instead of relying on automatic free. (Bug #2062)
Fixed bug in UNION statement with alias '*'. (Bug #1249)
Fixed a bug in DELETE ... ORDER BY ... LIMIT where the rows where not deleted in the proper order. (Bug #1024).
FOUND_ROWS() could return incorrect number of rows after a query with an impossible WHERE condition.
HOW DATABASES doesn't anymore show .sym files (on windows) that doesn't point to a valid directory. (Bug #1385)
include/config-win.h:
Ensure that USE_SYMDIR is set for all windows versions
(This is set in makefiles, so this is just an extra safety measure)
include/my_pthread.h:
Fixed a possible memory leak on MacOSX when using the shared libmysql.so library (Bug #2061)
include/my_sys.h:
my_init() now returns error code if something went wrong
include/mysql.h:
mysql_once_init() now returns error code if something went wrong
include/mysql_com.h:
my_init() now returns error code if something went wrong
libmysql/libmysql.c:
mysql_server_init() and mysql_once_init() now returns error code if something went wrong (Bug #2062)
mysql-test/r/limit.result:
Update results
mysql-test/r/select_found.result:
Update results
mysql-test/r/union.result:
Update results
mysql-test/t/limit.test:
Added test for DELETE ... ORDER BY ... LIMIT (bug #1024)
mysql-test/t/select_found.test:
Added test for problem with impossible WHERE (Bug #1468)
mysql-test/t/union.test:
Added test for problem with alias '*' (Bug #1249)
mysys/mf_pack.c:
Don't use my_fopen() when reading symlink information as this may cause problems when a lot of files are opened.
mysys/my_init.c:
my_init() now returns error code if something went wrong
mysys/my_lib.c:
More debug information
mysys/my_thr_init.c:
Free thread keys with pthread_key_delete() instead of relying on automatic free. (Bug #2062)
sql/sql_base.cc:
Fixed bug in UNION statement with alias '*'. (Bug #1249)
sql/sql_delete.cc:
Fixed a bug in DELETE ... ORDER BY ... LIMIT where the rows where not deleted in the proper order. (Bug #1024).
sql/sql_select.cc:
FOUND_ROWS() could return incorrect number of rows after a query with an impossible WHERE condition.
sql/sql_show.cc:
SHOW DATABASES doesn't anymore show .sym files (on windows) that doesn't point to a valid directory. (Bug #1385)
sql/sql_yacc.yy:
Allow syntax UNION DISTINCT
Diffstat (limited to 'mysql-test/t/limit.test')
-rw-r--r-- | mysql-test/t/limit.test | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/mysql-test/t/limit.test b/mysql-test/t/limit.test index d4f6ce186cf..32962073eee 100644 --- a/mysql-test/t/limit.test +++ b/mysql-test/t/limit.test @@ -19,9 +19,7 @@ select * from t1; drop table t1; create table t1 (i int); -insert into t1 (i) values(1); -insert into t1 (i) values(1); -insert into t1 (i) values(1); +insert into t1 (i) values(1),(1),(1); delete from t1 limit 1; update t1 set i=2 limit 1; delete from t1 limit 0; @@ -29,4 +27,22 @@ update t1 set i=3 limit 0; select * from t1; drop table t1; +# LIMIT 0 + select 0 limit 0; + +# +# Test with DELETE, ORDER BY and limit (bug #1024) +# + +CREATE TABLE t1(id int auto_increment primary key, id2 int, index(id2)); +INSERT INTO t1 (id2) values (0),(0),(0); +DELETE FROM t1 WHERE id=1; +INSERT INTO t1 SET id2=0; +SELECT * FROM t1; +DELETE FROM t1 WHERE id2 = 0 ORDER BY id LIMIT 1; +# should have deleted WHERE id=2 +SELECT * FROM t1; +DELETE FROM t1 WHERE id2 = 0 ORDER BY id desc LIMIT 1; +SELECT * FROM t1; +DROP TABLE t1; |