diff options
author | unknown <ram@gw.mysql.r18.ru> | 2004-06-29 13:51:35 +0500 |
---|---|---|
committer | unknown <ram@gw.mysql.r18.ru> | 2004-06-29 13:51:35 +0500 |
commit | 0a1381e05b09aa4d99cd4cbd1e0a0985a02c175a (patch) | |
tree | 35a367784c55e2d7df8719dbd4979a247a8cda31 | |
parent | 834bde020d11fc433d7e364840afd577ae2dbae0 (diff) | |
parent | f9b7537eb6bf336df71893e5d7cdaeb645a04eac (diff) | |
download | mariadb-git-0a1381e05b09aa4d99cd4cbd1e0a0985a02c175a.tar.gz |
Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-4.1
into gw.mysql.r18.ru:/usr/home/ram/work/4.1.b4089
mysql-test/r/bdb.result:
Auto merged
mysql-test/t/bdb.test:
Auto merged
sql/handler.h:
Auto merged
-rw-r--r-- | mysql-test/r/bdb.result | 7 | ||||
-rw-r--r-- | mysql-test/t/bdb.test | 11 | ||||
-rw-r--r-- | sql/handler.h | 3 |
3 files changed, 20 insertions, 1 deletions
diff --git a/mysql-test/r/bdb.result b/mysql-test/r/bdb.result index f2846e238e3..25118702d09 100644 --- a/mysql-test/r/bdb.result +++ b/mysql-test/r/bdb.result @@ -1244,3 +1244,10 @@ a b 3 three 4 four drop table t1, t2; +create table t1 (a int, b varchar(30), primary key(a)) engine = bdb; +insert into t1 values (1,'one'); +commit; +truncate t1; +select * from t1; +a b +drop table t1; diff --git a/mysql-test/t/bdb.test b/mysql-test/t/bdb.test index 32ea0662534..7ee7d18439d 100644 --- a/mysql-test/t/bdb.test +++ b/mysql-test/t/bdb.test @@ -886,3 +886,14 @@ insert into t2 (a, b) select a, b from t1 where (a, b) in (select a, b from t1); select * from t2; drop table t1, t2; + +# +# Bug #4304: TRUNCATE <table of type BDB> , wrong result +# + +create table t1 (a int, b varchar(30), primary key(a)) engine = bdb; +insert into t1 values (1,'one'); +commit; +truncate t1; +select * from t1; +drop table t1; diff --git a/sql/handler.h b/sql/handler.h index ca452b6dedf..506038fccfd 100644 --- a/sql/handler.h +++ b/sql/handler.h @@ -515,7 +515,8 @@ extern TYPELIB tx_isolation_typelib; #define ha_commit(thd) (ha_commit_trans((thd), &((thd)->transaction.all))) #define ha_rollback(thd) (ha_rollback_trans((thd), &((thd)->transaction.all))) -#define ha_supports_generate(T) (T != DB_TYPE_INNODB) +#define ha_supports_generate(T) (T != DB_TYPE_INNODB && \ + T != DB_TYPE_BERKELEY_DB) bool ha_caching_allowed(THD* thd, char* table_key, uint key_length, uint8 cache_type); |