1
--source include/have_falcon.inc
2
--source include/big_test.inc
4
# Record cache memory leak test inspired by Kevin.
6
# Note: Original test is with loop count of
7
# 250000. For the big-test version we use loop count of 500k.
9
# ----------------------------------------------------- #
10
# --- Initialisation --- #
11
# ----------------------------------------------------- #
12
let $engine = 'Falcon';
13
eval SET @@storage_engine = $engine;
16
DROP TABLE IF EXISTS t1;
19
CREATE TABLE t1 (c1 varchar(100));
20
INSERT INTO t1 VALUES (repeat('A', 100));
21
INSERT INTO t1 VALUES (repeat('B', 100));
22
INSERT INTO t1 VALUES (repeat('C', 100));
25
# ----------------------------------------------------- #
27
# ----------------------------------------------------- #
29
# During this series of updates, there should be no increase in memory
30
# since each previous record version should be freed once it is replaced.
36
UPDATE t1 SET c1 = lower(c1);
37
UPDATE t1 SET c1 = upper(c1);
45
# ----------------------------------------------------- #
47
# ----------------------------------------------------- #
48
SELECT count(*) FROM t1;
50
# ----------------------------------------------------- #
51
# --- Final cleanup --- #
52
# ----------------------------------------------------- #