1
DROP TABLE IF EXISTS t1;
3
i int(10) unsigned not null auto_increment primary key,
4
a varchar(255) not null,
8
Table Op Msg_type Msg_text
9
test.t1 repair status OK
11
Table Op Msg_type Msg_text
12
test.t1 check status OK
14
Table Op Msg_type Msg_text
15
test.t1 optimize status OK
17
Table Op Msg_type Msg_text
18
test.t1 check status OK
19
select count(*) from t1 where match a against ('aaaxxx');
22
select count(*) from t1 where match a against ('aaayyy');
25
select count(*) from t1 where match a against ('aaazzz');
28
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
31
select count(*) from t1 where match a against ('aaayyy' in boolean mode);
34
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
37
select count(*) from t1 where match a against ('aaaxxx aaayyy aaazzz');
40
select count(*) from t1 where match a against ('aaaxxx aaayyy aaazzz' in boolean mode);
43
select count(*) from t1 where match a against ('aaax*' in boolean mode);
46
select count(*) from t1 where match a against ('aaay*' in boolean mode);
49
select count(*) from t1 where match a against ('aaa*' in boolean mode);
52
insert t1 (a) values ('aaaxxx'),('aaayyy');
53
insert t1 (a) values ('aaazzz'),('aaazzz'),('aaazzz'),('aaazzz'),('aaazzz');
54
select count(*) from t1 where match a against ('aaaxxx');
57
select count(*) from t1 where match a against ('aaayyy');
60
select count(*) from t1 where match a against ('aaazzz');
63
insert t1 (a) values ('aaaxxx 000000');
64
select count(*) from t1 where match a against ('000000');
67
delete from t1 where match a against ('000000');
68
select count(*) from t1 where match a against ('000000');
71
select count(*) from t1 where match a against ('aaaxxx');
74
delete from t1 where match a against ('aaazzz');
75
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
78
select count(*) from t1 where match a against ('aaayyy' in boolean mode);
81
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
84
select count(*) from t1 where a = 'aaaxxx';
87
select count(*) from t1 where a = 'aaayyy';
90
select count(*) from t1 where a = 'aaazzz';
93
insert t1 (a) values ('aaaxxx 000000');
94
select count(*) from t1 where match a against ('000000');
97
update t1 set a='aaazzz' where match a against ('000000');
98
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
101
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
104
update t1 set a='aaazzz' where a = 'aaaxxx';
105
update t1 set a='aaaxxx' where a = 'aaayyy';
106
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
109
select count(*) from t1 where match a against ('aaayyy' in boolean mode);
112
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
117
i int(10) unsigned not null auto_increment primary key,
118
a varchar(255) not null,
121
select count(*) from t1 where match a against ('aaaxxx');
124
select count(*) from t1 where match a against ('aaayyy');
127
select count(*) from t1 where match a against ('aaazzz');
130
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
133
select count(*) from t1 where match a against ('aaayyy' in boolean mode);
136
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
139
select count(*) from t1 where match a against ('aaaxxx aaayyy aaazzz');
142
select count(*) from t1 where match a against ('aaaxxx aaayyy aaazzz' in boolean mode);
145
select count(*) from t1 where match a against ('aaax*' in boolean mode);
148
select count(*) from t1 where match a against ('aaay*' in boolean mode);
151
select count(*) from t1 where match a against ('aaa*' in boolean mode);
154
insert t1 (a) values ('aaaxxx'),('aaayyy');
155
insert t1 (a) values ('aaazzz'),('aaazzz'),('aaazzz'),('aaazzz'),('aaazzz');
156
select count(*) from t1 where match a against ('aaaxxx');
159
select count(*) from t1 where match a against ('aaayyy');
162
select count(*) from t1 where match a against ('aaazzz');
165
insert t1 (a) values ('aaaxxx 000000');
166
select count(*) from t1 where match a against ('000000');
169
delete from t1 where match a against ('000000');
170
select count(*) from t1 where match a against ('000000');
173
select count(*) from t1 where match a against ('aaaxxx');
176
delete from t1 where match a against ('aaazzz');
177
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
180
select count(*) from t1 where match a against ('aaayyy' in boolean mode);
183
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
186
select count(*) from t1 where a = 'aaaxxx';
189
select count(*) from t1 where a = 'aaayyy';
192
select count(*) from t1 where a = 'aaazzz';
195
insert t1 (a) values ('aaaxxx 000000');
196
select count(*) from t1 where match a against ('000000');
199
update t1 set a='aaazzz' where match a against ('000000');
200
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
203
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
206
update t1 set a='aaazzz' where a = 'aaaxxx';
207
update t1 set a='aaaxxx' where a = 'aaayyy';
208
select count(*) from t1 where match a against ('aaaxxx' in boolean mode);
211
select count(*) from t1 where match a against ('aaayyy' in boolean mode);
214
select count(*) from t1 where match a against ('aaazzz' in boolean mode);
219
create table t1(a text,fulltext(a)) collate=utf8_swedish_ci;
220
insert into t1 values('test test '),('test'),('test'),('test'),
221
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
222
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
223
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
224
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
225
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
226
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
227
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
228
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
229
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
230
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
231
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
232
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
233
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
234
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test'),
235
('test'),('test'),('test'),('test'),('test'),('test'),('test'),('test');
236
delete from t1 limit 1;
238
insert into t1 values('ab c d');
239
update t1 set a='ab c d';
240
select * from t1 where match a against('ab c' in boolean mode);
245
CREATE TABLE t1(a VARCHAR(255), FULLTEXT(a)) ENGINE=MyISAM DEFAULT CHARSET=utf8;
246
INSERT INTO t1 VALUES('„MySQL“');
247
SELECT a FROM t1 WHERE MATCH a AGAINST('“MySQL„' IN BOOLEAN MODE);