~ubuntu-branches/ubuntu/trusty/drizzle/trusty

« back to all changes in this revision

Viewing changes to plugin/memory/tests/r/heap_var.result

  • Committer: Bazaar Package Importer
  • Author(s): Monty Taylor
  • Date: 2010-10-02 14:17:48 UTC
  • mfrom: (1.1.1 upstream)
  • mto: (2.1.17 sid)
  • mto: This revision was merged to the branch mainline in revision 3.
  • Revision ID: james.westby@ubuntu.com-20101002141748-m6vbfbfjhrw1153e
Tags: 2010.09.1802-1
* New upstream release.
* Removed pid-file argument hack.
* Updated GPL-2 address to be new address.
* Directly copy in drizzledump.1 since debian doesn't have sphinx 1.0 yet.
* Link to jquery from libjs-jquery. Add it as a depend.
* Add drizzled.8 symlink to the install files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
drop table if exists t1;
 
2
set @@session.max_heap_table_size=16*1024*1024*24;
 
3
create temporary table t1 (a int not null, b int, c varchar(400), d varchar(400), primary key (a), key (b)) engine=MEMORY comment="testing heaps";
 
4
show table status like "t1";
 
5
Session Schema  Name    Type    Engine  Version Rows    Avg_row_length  Table_size      Auto_increment
 
6
#       test    t1      TEMPORARY       MEMORY  #       #       #       #       #
 
7
insert into t1 values (1,1,'012',NULL), (2,2,'0123456789',NULL), (3,3,'012345678901234567890123456789',NULL), (4,4,NULL,'0123456789012345678901234567890123456789012345678901234567890123456789');
 
8
select * from t1;
 
9
a       b       c       d
 
10
1       1       012     NULL
 
11
2       2       0123456789      NULL
 
12
3       3       012345678901234567890123456789  NULL
 
13
4       4       NULL    0123456789012345678901234567890123456789012345678901234567890123456789
 
14
delete from t1 where a = 3;
 
15
select * from t1;
 
16
a       b       c       d
 
17
1       1       012     NULL
 
18
2       2       0123456789      NULL
 
19
4       4       NULL    0123456789012345678901234567890123456789012345678901234567890123456789
 
20
insert into t1 values (5,5,NULL,'0123'), (6,6,NULL,'0123');
 
21
select * from t1;
 
22
a       b       c       d
 
23
1       1       012     NULL
 
24
2       2       0123456789      NULL
 
25
5       5       NULL    0123
 
26
4       4       NULL    0123456789012345678901234567890123456789012345678901234567890123456789
 
27
6       6       NULL    0123
 
28
update t1 set c = '012345678901234567890123456789' where a = 2;
 
29
select * from t1;
 
30
a       b       c       d
 
31
1       1       012     NULL
 
32
2       2       012345678901234567890123456789  NULL
 
33
5       5       NULL    0123
 
34
4       4       NULL    0123456789012345678901234567890123456789012345678901234567890123456789
 
35
6       6       NULL    0123
 
36
update t1 set c = '0123456789' where a = 2;
 
37
select * from t1;
 
38
a       b       c       d
 
39
1       1       012     NULL
 
40
2       2       0123456789      NULL
 
41
5       5       NULL    0123
 
42
4       4       NULL    0123456789012345678901234567890123456789012345678901234567890123456789
 
43
6       6       NULL    0123
 
44
insert into t1 values (7,7,'0123',NULL), (8,8,'0123',NULL);
 
45
select * from t1;
 
46
a       b       c       d
 
47
1       1       012     NULL
 
48
2       2       0123456789      NULL
 
49
5       5       NULL    0123
 
50
4       4       NULL    0123456789012345678901234567890123456789012345678901234567890123456789
 
51
6       6       NULL    0123
 
52
7       7       0123    NULL
 
53
8       8       0123    NULL
 
54
delete from t1;
 
55
select * from t1;
 
56
a       b       c       d
 
57
select count(*) from t1;
 
58
count(*)
 
59
10001
 
60
insert into t1 values (100000,100000,NULL,'0123'), (100000,100000,NULL,'0123');
 
61
ERROR 23000: Duplicate entry '100000' for key 'PRIMARY'
 
62
show table status like "t1";
 
63
Session Schema  Name    Type    Engine  Version Rows    Avg_row_length  Table_size      Auto_increment
 
64
#       test    t1      TEMPORARY       MEMORY  #       #       #       #       #
 
65
select count(*) from t1;
 
66
count(*)
 
67
10002
 
68
set @@session.max_heap_table_size=default;
 
69
drop table t1;