summaryrefslogtreecommitdiff
path: root/storage/mroonga/mysql-test/mroonga/storage/r/index_multiple_column_select_float.result
blob: 452cae2d65150e00c41d88990e8bec6630d68d8d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
DROP TABLE IF EXISTS temperatures;
CREATE TABLE temperatures (
id INT PRIMARY KEY AUTO_INCREMENT,
title VARCHAR(20),
temperature FLOAT,
KEY temperature_index(temperature),
KEY multi_index(temperature, title)
);
INSERT INTO temperatures VALUES (NULL, "Hot!", 28.2);
INSERT INTO temperatures VALUES (NULL, "Snow!", -2.8);
INSERT INTO temperatures VALUES (NULL, "Rainy!", 12.7);
SELECT temperature FROM temperatures WHERE temperature BETWEEN 10 AND 30;
temperature
12.7
28.2
SELECT temperature FROM temperatures WHERE temperature BETWEEN -10 AND 20;
temperature
-2.8
12.7
SELECT title, temperature FROM temperatures WHERE temperature BETWEEN 10 AND 30;
title	temperature
Rainy!	12.7
Hot!	28.2
SELECT title, temperature FROM temperatures WHERE temperature BETWEEN -10 AND 20;
title	temperature
Snow!	-2.8
Rainy!	12.7
DROP TABLE temperatures;