sqllogictest

Artifact [c5720e16c4]
Login

Artifact c5720e16c4226fa4e621aa81007ca8d8609a57e6:


hash-threshold 8

statement ok
CREATE TABLE tab0(col0 INTEGER, col1 INTEGER, col2 INTEGER)

statement ok
CREATE TABLE tab1(col0 INTEGER, col1 INTEGER, col2 INTEGER)

statement ok
CREATE TABLE tab2(col0 INTEGER, col1 INTEGER, col2 INTEGER)

statement ok
INSERT INTO tab0 VALUES(89,91,82)

statement ok
INSERT INTO tab0 VALUES(35,97,1)

statement ok
INSERT INTO tab0 VALUES(24,86,33)

statement ok
INSERT INTO tab1 VALUES(64,10,57)

statement ok
INSERT INTO tab1 VALUES(3,26,54)

statement ok
INSERT INTO tab1 VALUES(80,13,96)

statement ok
INSERT INTO tab2 VALUES(7,31,27)

statement ok
INSERT INTO tab2 VALUES(79,17,38)

statement ok
INSERT INTO tab2 VALUES(78,59,26)

query I rowsort
SELECT col1 + - ( col0 ) FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + col2 + - 99 AS col1 FROM tab0 AS cor0
----
-17
-66
-98

query I rowsort
SELECT 44 * - col0 AS col2 FROM tab1 AS cor0
----
-132
-2816
-3520

query I rowsort
SELECT 28 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4
SELECT ALL + - CAST( NULL AS SIGNED ) * - col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4
SELECT ALL + - CAST ( NULL AS INTEGER ) * - col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5
SELECT 10 * col0 + + CAST( - col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
216
315
801

skipif mysql # not compatible
query I rowsort label-5
SELECT 10 * col0 + + CAST ( - col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
216
315
801

query I rowsort
SELECT - + col0 - - col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT 7 + col1 AS col1 FROM tab2 cor0
----
24
38
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-8
SELECT ALL + 60 DIV ( tab0.col0 + 64 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8
SELECT ALL + 60 / ( tab0.col0 + 64 ) FROM tab0
----
0
0
0

query I rowsort
SELECT 93 AS col0 FROM tab2
----
93
93
93

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab2 cor1
----
243 values hashing to d489341cd587fd6eb0b972c5464c6ddc

query I rowsort
SELECT DISTINCT col2 * + 20 FROM tab0
----
1640
20
660

query I rowsort
SELECT - 66 FROM tab0, tab1 cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

onlyif mysql # use DIV operator for integer division
query I rowsort label-13
SELECT col2 * tab2.col2 DIV col0 col1 FROM tab2
----
104
18
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-13
SELECT col2 * tab2.col2 / col0 col1 FROM tab2
----
104
18
8

query I rowsort
SELECT - + ( - col0 ) + + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - 30 FROM tab1
----
-30
-30
-30

query I rowsort
SELECT ALL - 87 + + col2 FROM tab1 AS cor0
----
-30
-33
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-17
SELECT DISTINCT col1 DIV + col2 + cor0.col0 * + col2 * + ( col2 ) FROM tab1 AS cor0
----
207936
737280
8748

skipif mysql # not compatible
query I rowsort label-17
SELECT DISTINCT col1 / + col2 + cor0.col0 * + col2 * + ( col2 ) FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT DISTINCT - col1 * 76 + col1 + ( cor0.col0 * cor0.col1 ) FROM tab0 cor0
----
-3880
-4386
1274

query I rowsort
SELECT 20 FROM tab1 cor0
----
20
20
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-20
SELECT ALL CAST( + 80 AS SIGNED ) * col0 AS col0 FROM tab2 AS cor0
----
560
6240
6320

skipif mysql # not compatible
query I rowsort label-20
SELECT ALL CAST ( + 80 AS INTEGER ) * col0 AS col0 FROM tab2 AS cor0
----
560
6240
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-21
SELECT CAST( col1 AS SIGNED ) * col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-21
SELECT CAST ( col1 AS INTEGER ) * col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-22
SELECT DISTINCT + 81 * col2 + + col1 DIV - col0 + col0 * - col1 AS col0 FROM tab1 AS cor0
----
3977
4288
6736

skipif mysql # not compatible
query I rowsort label-22
SELECT DISTINCT + 81 * col2 + + col1 / - col0 + col0 * - col1 AS col0 FROM tab1 AS cor0
----
3977
4288
6736

query I rowsort
SELECT ALL 85 AS col1 FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT - - 22 * - col0 AS col0 FROM tab1 cor0
----
-1408
-1760
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-25
SELECT ALL + ( + cor0.col0 ) DIV col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-25
SELECT ALL + ( + cor0.col0 ) / col2 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-26
SELECT ALL + ( col1 ) + col0 DIV - cor0.col2 + + 79 AS col2 FROM tab0 AS cor0
----
141
165
169

skipif mysql # not compatible
query I rowsort label-26
SELECT ALL + ( col1 ) + col0 / - cor0.col2 + + 79 AS col2 FROM tab0 AS cor0
----
141
165
169

query I rowsort
SELECT + ( + col0 ) + - col0 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-28
SELECT ALL CAST( col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-28
SELECT ALL CAST ( col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - col1 * col1 FROM tab0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-30
SELECT DISTINCT + 73 + 60 DIV col1 AS col2 FROM tab0 AS cor0
----
73

skipif mysql # not compatible
query I rowsort label-30
SELECT DISTINCT + 73 + 60 / col1 AS col2 FROM tab0 AS cor0
----
73

query I rowsort
SELECT DISTINCT ( - col2 ) * + col0 + - 98 FROM tab1 AS cor0
----
-260
-3746
-7778

query I rowsort
SELECT ALL col0 + + col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - ( - col2 ) AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - ( col2 ) AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - 75 * ( col0 ) + col0 + + col1 * + cor0.col0 FROM tab0 AS cor0
----
1513
288
805

query I rowsort
SELECT - 88 AS col2 FROM tab1 cor0
----
-88
-88
-88

query I rowsort
SELECT - + 20 * + col0 FROM tab1 AS cor0
----
-1280
-1600
-60

query I rowsort
SELECT DISTINCT + col0 + - col1 AS col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT ALL + col0 + + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - + 56 * col2 AS col0 FROM tab1 AS cor0
----
-3024
-3192
-5376

query I rowsort
SELECT DISTINCT cor1.col2 * + 76 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
1976
2052
2888

query I rowsort
SELECT DISTINCT + col0 * col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - col2 + - ( + col0 * col1 ) FROM tab0 cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + 19 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-45
SELECT - col2 * CAST( NULL AS SIGNED ) + - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-45
SELECT - col2 * CAST ( NULL AS INTEGER ) + - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + 75 * + col1 - col1 FROM tab2
----
1258
2294
4366

query I rowsort
SELECT DISTINCT col0 * - col2 + + ( + 77 ) FROM tab2
----
-112
-1951
-2925

query I rowsort
SELECT + 33 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT DISTINCT col1 + 0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - col1 + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + tab0.col1 + + col1 * 88 FROM tab0
----
7654
8099
8633

skipif mysql # not compatible
query I rowsort
SELECT + col2 * + CAST ( col0 AS REAL ) + + col1 AS col0 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT ALL - + cor0.col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - cor0.col0 * - cor0.col2 * + col2 + + col0 AS col1 FROM tab1 AS cor0
----
208000
737360
8751

query I rowsort
SELECT DISTINCT - col0 + 61 FROM tab1
----
-19
-3
58

query I rowsort
SELECT col2 + 28 AS col0 FROM tab2
----
54
55
66

query I rowsort
SELECT DISTINCT + + col1 AS col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + col0 * ( 61 ) AS col0 FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT - cor0.col2 * col2 AS col2 FROM tab0 cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-61
SELECT ALL - - col0 DIV + col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-61
SELECT ALL - - col0 / + col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + col1 + ( col2 ) * cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + col1 + - col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 * - 73 FROM tab2
----
-1898
-1971
-2774

query I rowsort
SELECT + col1 + + 27 AS col0 FROM tab0 AS cor0
----
113
118
124

onlyif mysql # use DIV operator for integer division
query I rowsort label-66
SELECT DISTINCT - col1 - col1 DIV + col2 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-66
SELECT DISTINCT - col1 - col1 / + col2 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-67
SELECT DISTINCT 23 + + 14 DIV + col1 - cor0.col1 FROM tab0 cor0
----
-63
-68
-74

skipif mysql # not compatible
query I rowsort label-67
SELECT DISTINCT 23 + + 14 / + col1 - cor0.col1 FROM tab0 cor0
----
-63
-68
-74

query I rowsort
SELECT ALL - ( - ( tab2.col1 ) ) AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT - col2 * 31 * + col0 FROM tab1
----
-113088
-238080
-5022

query I rowsort
SELECT ALL - - col2 + + ( + col1 * col2 ) AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + - cor0.col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT ( 10 ) * - col0 FROM tab1 AS cor0
----
-30
-640
-800

query I rowsort
SELECT 65 + + col0 AS col0 FROM tab2 AS cor0
----
143
144
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-74
SELECT ALL - + col0 DIV + col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-74
SELECT ALL - + col0 / + col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT DISTINCT - ( 99 ) FROM tab2 AS cor0
----
-99

query I rowsort
SELECT ALL - 97 * col2 AS col0 FROM tab2 cor0
----
-2522
-2619
-3686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * - col1 col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL col2 * + col1 * col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL - 82 * - col0 + - tab1.col2 * col2 AS col2 FROM tab1
----
-2656
-2670
1999

query I rowsort
SELECT + cor0.col2 + - tab2.col2 FROM tab2, tab2 cor0
----
9 values hashing to 527fa7f8c75c69da0f3170b987178ec5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 98 + col1 col1 FROM tab2
----
115
129
157

onlyif mysql # use DIV operator for integer division
query I rowsort label-82
SELECT col0 DIV col2 + col2 AS col0 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-82
SELECT col0 / col2 + col2 AS col0 FROM tab0
----
33
36
83

query I rowsort
SELECT DISTINCT 81 FROM tab2 AS cor0
----
81

query I rowsort
SELECT ALL 92 * col0 FROM tab2 AS cor0
----
644
7176
7268

query I rowsort
SELECT DISTINCT col2 * col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT 30 + - col0 * ( 93 ) AS col1 FROM tab0 AS cor0
----
-2202
-3225
-8247

query I rowsort
SELECT - col0 * - 61 AS col1 FROM tab0 AS cor0
----
1464
2135
5429

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-88
SELECT ALL + col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-88
SELECT ALL + col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-89
SELECT ALL + col0 + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-89
SELECT ALL + col0 + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + - 59 + + 51 FROM tab0 AS cor0
----
-7
25
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-91
SELECT - - col2 DIV col0 - + col0 FROM tab1 AS cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-91
SELECT - - col2 / col0 - + col0 FROM tab1 AS cor0
----
-64
-79
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-92
SELECT DISTINCT - col2 * - CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-92
SELECT DISTINCT - col2 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + ( col0 ) col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + + col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL + col1 * - cor0.col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + col2 + + col2 - ( - col1 ) * col2 FROM tab0
----
2904
7626
99

query I rowsort
SELECT + col1 + col0 + 39 AS col0 FROM tab2
----
135
176
77

query I rowsort
SELECT + 13 + - col2 FROM tab1
----
-41
-44
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-99
SELECT + col0 + col0 DIV + ( col0 ) FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-99
SELECT + col0 + col0 / + ( col0 ) FROM tab1
----
4
65
81

query I rowsort
SELECT 21 AS col2 FROM tab0
----
21
21
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-101
SELECT col0 * - CAST( NULL AS SIGNED ) + - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-101
SELECT col0 * - CAST ( NULL AS INTEGER ) + - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col1 + col1 * + col2 * col2 - - tab0.col0 col2 FROM tab0
----
35
604511
90840

query I rowsort
SELECT - 34 FROM tab1, tab2, tab1 cor0
----
27 values hashing to 5b88331e40da4796cc4826c442aa45f7

query I rowsort
SELECT col2 * tab1.col2 + + col0 - - col0 FROM tab1
----
2922
3377
9376

query I rowsort
SELECT 80 - - col0 FROM tab2
----
158
159
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-106
SELECT col0 DIV + col0 AS col2 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-106
SELECT col0 / + col0 AS col2 FROM tab0
----
1
1
1

query I rowsort
SELECT col0 + col1 * ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 98 + + cor0.col1 col1 FROM tab2 AS cor0
----
-39
-67
-81

query I rowsort
SELECT 95 AS col1 FROM tab1
----
95
95
95

query I rowsort
SELECT + 29 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT ALL + cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT + tab2.col0 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - cor0.col1 * + col2 * col0 + col2 FROM tab1 AS cor0
----
-36423
-4158
-99744

query I rowsort
SELECT ALL + - col2 + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - + col2 * - col2 * cor0.col1 - + col2 AS col2 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT + col1 + cor0.col2 * - col0 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT - col0 * col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + 14 AS col0 FROM tab0
----
14
14
14

query I rowsort
SELECT tab2.col1 * - col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT - col0 * + col0 AS col1 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT col0 + - ( - col0 + - col0 ) FROM tab1
----
192
240
9

query I rowsort
SELECT ALL col1 + - 59 FROM tab0
----
27
32
38

query I rowsort
SELECT 14 * col2 + + col1 * cor0.col1 FROM tab0 AS cor0
----
7858
9423
9429

query I rowsort
SELECT + + 65 + col0 AS col1 FROM tab2 AS cor0
----
143
144
72

query I rowsort
SELECT + - ( + col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - tab0.col0 + ( - 91 ) AS col1 FROM tab0
----
-115
-126
-180

query I rowsort
SELECT ( - 81 ) * tab0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 912b9d807d842959d4cb969da39e7a9e

query I rowsort
SELECT ALL + - 10 + ( + col2 ) - col1 FROM tab2 AS cor0
----
-14
-43
11

query I rowsort
SELECT ALL - 42 + col1 * col1 FROM tab0 cor0
----
7354
8239
9367

query I rowsort
SELECT DISTINCT 68 AS col0 FROM tab1 AS cor0
----
68

query I rowsort
SELECT ALL 1 AS col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + col1 * - col2 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT col1 * - 57 + cor0.col2 * col0 FROM tab1 AS cor0
----
-1320
3078
6939

query I rowsort
SELECT - + col0 - - col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + + 96 + - cor0.col2 * + col1 FROM tab0 AS cor0
----
-1
-2742
-7366

query I rowsort
SELECT DISTINCT - - col1 * col1 + cor0.col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + col0 * - 88 FROM tab0 AS cor0
----
-2112
-3080
-7832

query I rowsort
SELECT DISTINCT + - col1 + - col1 - + col2 FROM tab0 AS cor0
----
-195
-205
-264

query I rowsort
SELECT - col0 * - col0 - col1 FROM tab0 AS cor0
----
1128
490
7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-141
SELECT - col1 DIV + col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-141
SELECT - col1 / + col1 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ( + col0 + col1 * 6 ) AS col0 FROM tab0
----
540
617
635

query I rowsort
SELECT DISTINCT 31 * - 1 FROM tab0
----
-31

query I rowsort
SELECT ALL col2 * - tab0.col2 AS col0 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL 69 AS col2 FROM tab2
----
69
69
69

query I rowsort
SELECT DISTINCT 90 * + tab1.col1 AS col1 FROM tab1
----
1170
2340
900

query I rowsort
SELECT - 58 + tab2.col2 - + tab2.col2 AS col0 FROM tab2
----
-58
-58
-58

query I rowsort
SELECT ( col2 ) + col0 AS col1 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-149
SELECT 16 DIV 71 + - col0 AS col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-149
SELECT 16 / 71 + - col0 AS col0 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-150
SELECT + ( col2 ) DIV + col0 AS col1 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-150
SELECT + ( col2 ) / + col0 AS col1 FROM tab2
----
0
0
3

query I rowsort
SELECT tab0.col0 * + col2 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT col2 - + col1 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT cor0.col0 * col2 + + 16 AS col2 FROM tab0 AS cor0
----
51
7314
808

query I rowsort
SELECT + + cor0.col0 + + cor0.col1 * cor0.col1 * col0 FROM tab0 AS cor0
----
177528
329350
737098

query I rowsort
SELECT - + col1 + - cor0.col0 * 64 AS col2 FROM tab0 AS cor0
----
-1622
-2337
-5787

query I rowsort
SELECT + col2 - col0 FROM tab2 AS cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 col0 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-158
SELECT DISTINCT - + col1 DIV col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-158
SELECT DISTINCT - + col1 / col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT - 45 * - col1 - - col1 AS col1 FROM tab0 AS cor0
----
3956
4186
4462

onlyif mysql # use DIV operator for integer division
query I rowsort label-160
SELECT - col0 DIV - col1 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-160
SELECT - col0 / - col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 3 FROM tab2 AS cor0
----
3

query I rowsort
SELECT 82 * + cor0.col2 * + col2 FROM tab2 AS cor0
----
118408
55432
59778

query I rowsort
SELECT - col0 + cor0.col0 * - col0 AS col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT DISTINCT + - col2 + col2 * + 9 AS col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT ALL + col1 + - col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * + 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - col2 * 57 FROM tab1 AS cor0
----
-3078
-3249
-5472

onlyif mysql # use DIV operator for integer division
query I rowsort label-168
SELECT - col0 * 61 DIV + 16 AS col1 FROM tab2 AS cor0
----
-26
-297
-301

skipif mysql # not compatible
query I rowsort label-168
SELECT - col0 * 61 / + 16 AS col1 FROM tab2 AS cor0
----
-26
-297
-301

query I rowsort
SELECT - + col2 * ( - 78 ) + - cor0.col1 * col1 AS col2 FROM tab0 cor0
----
-1885
-4822
-9331

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab0 AS cor1, tab0, tab1 cor2
----
3645 values hashing to e5255b2277726ba4514ff55622dec830

query I rowsort
SELECT col2 + cor0.col1 * col2 AS col1 FROM tab2 cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 * col0 col0 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + 45 AS col1 FROM tab1, tab0 AS cor0
----
45

query I rowsort
SELECT DISTINCT - cor0.col1 * ( - col0 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 4c0813b2179303fdf58f082d81d6d03c

query I rowsort
SELECT - 15 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-177
SELECT - col0 + CAST( col1 + col1 AS SIGNED ) * 1 col2 FROM tab1 cor0
----
-44
-54
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-177
SELECT - col0 + CAST ( col1 + col1 AS INTEGER ) * 1 col2 FROM tab1 cor0
----
-44
-54
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-178
SELECT cor0.col2 + - 30 * + col2 DIV col2 FROM tab1 AS cor0
----
24
27
66

skipif mysql # not compatible
query I rowsort label-178
SELECT cor0.col2 + - 30 * + col2 / col2 FROM tab1 AS cor0
----
24
27
66

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to 149298fc0224e93f3bc2df24a3ebeeb8

query I rowsort
SELECT ALL - col0 * 93 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT DISTINCT + col2 + + col1 + - col2 AS col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-182
SELECT - - col1 + + 12 DIV cor0.col0 col1 FROM tab2 AS cor0
----
17
32
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-182
SELECT - - col1 + + 12 / cor0.col0 col1 FROM tab2 AS cor0
----
17
32
59

query I rowsort
SELECT ALL col0 + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-184
SELECT DISTINCT + col1 * col1 + cor0.col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
7395
8280
9408

skipif mysql # not compatible
query I rowsort label-184
SELECT DISTINCT + col1 * col1 + cor0.col0 / - col0 AS col0 FROM tab0 AS cor0
----
7395
8280
9408

query I rowsort
SELECT ALL col0 - - col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-186
SELECT DISTINCT + col0 + ( - col0 + - cor0.col0 ) DIV - ( cor0.col1 * col1 + col2 ) AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-186
SELECT DISTINCT + col0 + ( - col0 + - cor0.col0 ) / - ( cor0.col1 * col1 + col2 ) AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col2 * col1 + 90 AS col2 FROM tab1 cor0
----
1338
1494
660

query I rowsort
SELECT ALL + col0 * - col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col2 + col0 * col0 AS col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT + col0 + cor0.col2 * - cor0.col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - 75 * - col0 FROM tab1 AS cor0
----
225
4800
6000

query I rowsort
SELECT ALL + ( - cor0.col0 ) FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-193
SELECT DISTINCT + - col0 DIV col1 AS col1 FROM tab1 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-193
SELECT DISTINCT + - col0 / col1 AS col1 FROM tab1 AS cor0
----
-6
0

query I rowsort
SELECT ALL - col2 * - col0 * - col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - ( cor0.col0 ) AS col1 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 29 * + col1 FROM tab1 cor0
----
290
377
754

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 6726a15019c52908f1f1d0df0cd4c1b8

query I rowsort
SELECT DISTINCT cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
7
78
79

query I rowsort
SELECT DISTINCT 93 AS col1 FROM tab2, tab2 AS cor0
----
93

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to f655b6f4c5b9ff73813030f2822ea1fd

query I rowsort
SELECT - col0 + - col0 AS col1 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT - ( - col2 ) + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - col0 + col0 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 + - col1 AS col0 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT ALL tab1.col2 AS col2 FROM tab1
----
54
57
96

query III rowsort
SELECT * FROM tab1 WHERE NULL < - col1 / col0
----

query I rowsort
SELECT ALL - col2 + col2 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 - - col1 FROM tab1 AS cor0
----
20
26
52

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) <= + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-210
SELECT ALL col0 DIV col2 + - col0 DIV col2 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-210
SELECT ALL col0 / col2 + - col0 / col2 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT 8 * col1 AS col1 FROM tab2
----
136
248
472

query I rowsort
SELECT DISTINCT 6 - - col2 * 10 * 67 FROM tab2
----
17426
18096
25466

query I rowsort
SELECT DISTINCT - - cor0.col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT col1 * + col1 * ( col2 ) AS col0 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - col0 + col1 * 73 AS col1 FROM tab2
----
1162
2256
4229

query I rowsort
SELECT - 74 + col2 AS col2 FROM tab0 AS cor0
----
-41
-73
8

query I rowsort
SELECT DISTINCT - ( col0 ) * - 65 + 90 FROM tab2
----
5160
5225
545

query I rowsort
SELECT + col2 + col2 - ( + tab1.col2 ) AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT + col0 * + tab2.col0 AS col1 FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-220
SELECT ALL col1 - - col1 DIV col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-220
SELECT ALL col1 - - col1 / col1 FROM tab2
----
18
32
60

query I rowsort
SELECT ALL + col1 * col0 + 97 FROM tab2 AS cor0
----
1440
314
4699

onlyif mysql # use DIV operator for integer division
query I rowsort label-222
SELECT + + col1 * cor0.col2 * col2 + col0 * ( + col2 ) DIV col1 col2 FROM tab1 AS cor0
----
120398
32854
75822

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-222
SELECT + + col1 * cor0.col2 * col2 + col0 * ( + col2 ) / col1 col2 FROM tab1 AS cor0
----
120398
32854
75822

query I rowsort
SELECT 80 * col2 AS col2 FROM tab2
----
2080
2160
3040

query I rowsort
SELECT DISTINCT + col1 + - col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT 97 + - col0 + + 53 AS col1 FROM tab1
----
147
70
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-226
SELECT ALL col2 + - 4 DIV col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-226
SELECT ALL col2 + - 4 / col0 FROM tab0
----
1
33
82

query I rowsort
SELECT col1 + + tab0.col1 AS col0 FROM tab0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-228
SELECT ALL col1 DIV + col0 + - tab0.col2 AS col1 FROM tab0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-228
SELECT ALL col1 / + col0 + - tab0.col2 AS col1 FROM tab0
----
-30
-81
1

query I rowsort
SELECT DISTINCT + col1 * + 37 * + col1 AS col0 FROM tab0 AS cor0
----
273652
306397
348133

query I rowsort
SELECT + - col1 + - col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL + col2 + ( 17 ) FROM tab0 cor0
----
18
50
99

query I rowsort
SELECT ALL cor0.col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - + col2 * CAST ( 27 AS REAL ) + col0 * col1 col2 FROM tab0 AS cor0
----
1173
3368
5885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + ( - 24 ) col1 FROM tab1
----
-11
-14
2

query I rowsort
SELECT ALL + + col1 * - col0 * - col1 + + col1 * + 84 FROM tab2 AS cor0
----
24259
276474
9331

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-237
SELECT CAST( NULL AS SIGNED ) + - col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-237
SELECT CAST ( NULL AS INTEGER ) + - col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * + tab2.col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT 52 FROM tab0
----
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-240
SELECT ALL CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-240
SELECT ALL CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 40 FROM tab1
----
40

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 6dfb18fb846f922ba9ea60ce42b86fb0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 6 ) * cor0.col2 col0 FROM tab2 AS cor0
----
156
162
228

query I rowsort
SELECT ALL - col0 * + col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL - - 10 * + cor0.col1 + + col0 FROM tab0 AS cor0
----
1005
884
999

query I rowsort
SELECT DISTINCT 37 FROM tab1, tab0 AS cor0
----
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-247
SELECT ALL - CAST( NULL AS DECIMAL ) * 13 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-247
SELECT ALL - CAST ( NULL AS REAL ) * 13 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 28 * - tab2.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 0d057f4f59be31681b291b3352ff2557

query I rowsort
SELECT - 37 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-250
SELECT + col0 + tab2.col0 * col2 * + CAST( + col0 + - col2 AS SIGNED ) FROM tab2
----
-3773
105534
123161

skipif mysql # not compatible
query I rowsort label-250
SELECT + col0 + tab2.col0 * col2 * + CAST ( + col0 + - col2 AS INTEGER ) FROM tab2
----
-3773
105534
123161

query I rowsort
SELECT 55 FROM tab1
----
55
55
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-252
SELECT col0 DIV - col0 + + col2 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-252
SELECT col0 / - col0 + + col2 FROM tab0
----
0
32
81

query I rowsort
SELECT + ( - col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT 67 - - col2 * - col0 * - col2 FROM tab2 AS cor0
----
114143
5170
52795

query I rowsort
SELECT ALL - col1 * col2 + ( - 7 * + cor0.col0 ) FROM tab0 cor0
----
-3006
-342
-8085

query I rowsort
SELECT DISTINCT - 34 + + col2 AS col0 FROM tab0 AS cor0
----
-1
-33
48

query I rowsort
SELECT - col1 - + col1 AS col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT + cor0.col1 + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT 92 FROM tab0 cor0
----
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-260
SELECT ALL 23 DIV col0 FROM tab1 cor0
----
0
0
7

skipif mysql # not compatible
query I rowsort label-260
SELECT ALL 23 / col0 FROM tab1 cor0
----
0
0
7

query I rowsort
SELECT + 15 + - col1 FROM tab1
----
-11
2
5

query I rowsort
SELECT - - cor0.col2 - col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + 30 + - col0 AS col1 FROM tab2 AS cor0
----
-48
-49
23

query I rowsort
SELECT DISTINCT col0 + + col2 - + 13 FROM tab2 AS cor0
----
104
21
91

query I rowsort
SELECT - 89 * cor0.col1 FROM tab2 AS cor0
----
-1513
-2759
-5251

query I rowsort
SELECT ALL - + 0 + col1 * - col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 33 FROM tab2 AS cor0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 57 * + cor0.col2 col0 FROM tab0, tab0 cor0
----
9 values hashing to 1d6306f216c759692cd9a50966ae3340

onlyif mysql # use DIV operator for integer division
query I rowsort label-269
SELECT 5 * col2 DIV - ( + col1 ) AS col0 FROM tab0 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-269
SELECT 5 * col2 / - ( + col1 ) AS col0 FROM tab0 cor0
----
-1
-4
0

query I rowsort
SELECT + + col1 + + col0 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - - col0 * - col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - tab2.col2 * + tab2.col2 AS col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - col1 * - col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - col0 + - col2 + col0 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL - col2 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col0 + col0 + col0 AS col1 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT - + col2 + + col2 * col2 AS col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL 67 + col0 * col0 FROM tab1
----
4163
6467
76

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NOT ( NULL ) <> ( NULL )
----

query I rowsort
SELECT + + col1 * col2 - col0 AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT + - col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col2 col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT col0 + tab0.col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT col0 * + col2 + + col1 * - col0 AS col0 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT ALL col1 + tab1.col0 * col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT - col1 + col1 + cor0.col2 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + col0 * - col0 * - col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT col1 * + col1 * col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT ALL tab2.col1 + col2 FROM tab2
----
55
58
85

query I rowsort
SELECT col1 * - col0 * col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - - col0 + col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + + col2 + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + + col2 + col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-296
SELECT + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-296
SELECT + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( + col0 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - - col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - col1 + - col0 * col2 * + col0 FROM tab1 AS cor0
----
-233482
-512
-614413

query I rowsort
SELECT + - 90 + col0 FROM tab0 AS cor0
----
-1
-55
-66

query I rowsort
SELECT + 15 + + col2 * - tab2.col2 AS col0 FROM tab2
----
-1429
-661
-714

query I rowsort
SELECT col0 + ( col0 ) FROM tab1
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-303
SELECT DISTINCT CAST( - col0 AS SIGNED ) FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-303
SELECT DISTINCT CAST ( - col0 AS INTEGER ) FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL + 34 FROM tab1
----
34
34
34

query I rowsort
SELECT + col2 * - col1 + - col0 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + 91 FROM tab0
----
91

query I rowsort
SELECT ALL col2 * col0 * col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + + ( - cor0.col2 ) + col2 + + cor0.col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - col0 - - col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + - 63 + col2 AS col1 FROM tab0 AS cor0
----
-30
-62
19

query I rowsort
SELECT - 23 * col2 AS col2 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT ALL - 85 - + col2 AS col0 FROM tab0 AS cor0
----
-118
-167
-86

query I rowsort
SELECT DISTINCT - - col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - - 9 AS col0 FROM tab1 AS cor0
----
9

query I rowsort
SELECT + + col0 * - col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 9 FROM tab1 AS cor0
----
9
9
9

query I rowsort
SELECT ALL + 94 AS col1 FROM tab2 cor0
----
94
94
94

query I rowsort
SELECT DISTINCT + + cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - - 53 - col1 * + col0 FROM tab0 cor0
----
-2011
-3342
-8046

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + cor0.col2 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + col0 + + col2 FROM tab1
----
121
176
57

query III rowsort
SELECT ALL * FROM tab2 WHERE col1 = NULL
----

query I rowsort
SELECT DISTINCT - col1 + col1 * tab1.col2 FROM tab1
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-324
SELECT DISTINCT col0 DIV - col1 + col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-324
SELECT DISTINCT col0 / - col1 + col0 FROM tab0
----
24
35
89

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL BETWEEN + col2 * col1 AND NULL
----

query I rowsort
SELECT + col1 + + col0 * + tab1.col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT - tab2.col0 + - col0 AS col2 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT col2 + col0 * tab2.col1 FROM tab2
----
1381
244
4628

query I rowsort
SELECT col1 * - col1 + - col2 + - col2 AS col2 FROM tab0
----
-7462
-8445
-9411

query I rowsort
SELECT + col0 + - col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT + tab0.col0 FROM tab0 WHERE NULL < + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-332
SELECT DISTINCT col0 DIV + col2 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-332
SELECT DISTINCT col0 / + col2 FROM tab1
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-333
SELECT + tab0.col0 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-333
SELECT + tab0.col0 / - col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-334
SELECT DISTINCT col1 * + col1 DIV col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-334
SELECT DISTINCT col1 * + col1 / col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-335
SELECT ALL col0 DIV - col2 AS col0 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-335
SELECT ALL col0 / - col2 AS col0 FROM tab0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-336
SELECT col2 + - col1 DIV - col1 AS col1 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-336
SELECT col2 + - col1 / - col1 AS col1 FROM tab0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-337
SELECT ALL + tab1.col0 DIV - col0 - - tab1.col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-337
SELECT ALL + tab1.col0 / - col0 - - tab1.col2 FROM tab1
----
53
56
95

query I rowsort
SELECT + col1 * + col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col1 + col0 * col2 + col2 * col2 FROM tab2
----
2763
4463
949

query I rowsort
SELECT - col0 * tab0.col0 FROM tab0
----
-1225
-576
-7921

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( col1 * + col2 )
----

query I rowsort
SELECT ALL col2 * - col1 FROM tab0
----
-2838
-7462
-97

query IIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0
----
54 values hashing to b8667d60d280879b35ad1450a82b3a49

query I rowsort
SELECT + col1 * col0 + col2 AS col1 FROM tab1 cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-345
SELECT cor0.col0 DIV + col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-345
SELECT cor0.col0 / + col0 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-346
SELECT + - col0 * cor0.col2 + + col2 DIV + col2 + + cor0.col1 FROM tab1 cor0
----
-135
-3637
-7666

skipif mysql # not compatible
query I rowsort label-346
SELECT + - col0 * cor0.col2 + + col2 / + col2 + + cor0.col1 FROM tab1 cor0
----
-135
-3637
-7666

query I rowsort
SELECT cor0.col1 * - col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT col0 + + cor0.col1 + col1 FROM tab2 AS cor0
----
113
196
69

query I rowsort
SELECT col2 * col0 * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT cor0.col2 * - cor0.col0 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 18f45a7edd86e3eccc832dcdb6123662

query IIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1
----
54 values hashing to 69e208df4a305efdfcc036bb4b31e720

query I rowsort
SELECT col0 * - cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 * ( + col0 * + col1 ) + + 57 FROM tab1
----
13577
2085
6457

query I rowsort
SELECT DISTINCT col0 * + col2 + + col0 AS col2 FROM tab2
----
196
2106
3081

query I rowsort
SELECT tab1.col1 - + 26 AS col2 FROM tab1
----
-13
-16
0

query I rowsort
SELECT + col0 * col1 AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col0 + + 53 FROM tab2
----
131
132
60

query I rowsort
SELECT ALL - 35 FROM tab2 AS cor0
----
-35
-35
-35

query I rowsort
SELECT + col1 * col0 + col1 * + col2 AS col0 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT ALL + col2 + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT 35 + + col2 - col0 AS col1 FROM tab1
----
28
51
86

query I rowsort
SELECT DISTINCT col0 - - col2 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL + col0 + tab0.col2 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - ( - col1 ) * - col1 AS col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT col0 + + col1 + col2 FROM tab0
----
133
143
262

query I rowsort
SELECT ALL - cor0.col0 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT + - col0 + col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col2 * col2 + col1 * - col1 FROM tab2 cor0
----
-232
-2805
1155

query I rowsort
SELECT 66 + + col0 AS col2 FROM tab1 AS cor0
----
130
146
69

query I rowsort
SELECT ALL - ( col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + + col0 - - col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + cor0.col0 * col2 + 9 AS col0 FROM tab2 AS cor0
----
198
2037
3011

query I rowsort
SELECT ALL 45 AS col0 FROM tab1 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT col2 * - col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT 40 * col1 * ( - col0 ) FROM tab0 AS cor0
----
-135800
-323960
-82560

query I rowsort
SELECT DISTINCT col0 * col1 + - 66 * 15 FROM tab2 AS cor0
----
-773
353
3612

query I rowsort
SELECT - - 41 FROM tab1 cor0
----
41
41
41

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 + cor0.col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 + + col0 * ( col1 + + col0 ) AS col2 FROM tab0 AS cor0
----
16102
2673
4621

query I rowsort
SELECT + cor0.col0 * col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + 38 * col1 FROM tab1 AS cor0
----
380
494
988

query I rowsort
SELECT + + 91 * + col0 FROM tab1 AS cor0
----
273
5824
7280

query I rowsort
SELECT ALL - col1 * - cor0.col1 - col2 * col0 AS col1 FROM tab0 AS cor0
----
6604
9374
983

query I rowsort
SELECT ALL + 40 + col0 AS col0 FROM tab2 AS cor0
----
118
119
47

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 cor2
----
972 values hashing to b2fa3f9d060540fe1eb4ad1c0754e163

query I rowsort
SELECT DISTINCT col0 * - ( cor0.col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-388
SELECT + + col0 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-388
SELECT + + col0 / cor0.col1 AS col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT DISTINCT + col0 * col1 + - 96 FROM tab1 AS cor0
----
-18
544
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-390
SELECT col1 * col2 DIV col2 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-390
SELECT col1 * col2 / col2 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + col0 + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + - col2 * + col0 + + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-393
SELECT ALL col1 * - CAST( + cor0.col1 AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
-205379
-29791
-4913

skipif mysql # not compatible
query I rowsort label-393
SELECT ALL col1 * - CAST ( + cor0.col1 AS INTEGER ) * col1 AS col0 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT - ( col2 ) * + col1 + - col1 AS col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL - cor0.col2 + col2 * col0 * + 88 FROM tab0 AS cor0
----
3079
642142
69663

query I rowsort
SELECT DISTINCT + col2 * + col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-397
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-397
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
NULL

query I rowsort
SELECT - 4 * + col1 - - cor0.col1 FROM tab0 AS cor0
----
-258
-273
-291

query I rowsort
SELECT DISTINCT + 40 FROM tab2 cor0
----
40

query I rowsort
SELECT - col0 + col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - + 88 + + col1 FROM tab1 AS cor0
----
-62
-75
-78

query I rowsort
SELECT DISTINCT + 40 + + col0 AS col0 FROM tab1 cor0
----
104
120
43

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL - - 72 AS col2 FROM tab1 AS cor0
----
72
72
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-405
SELECT ALL col0 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-405
SELECT ALL col0 / col1 FROM tab0
----
0
0
0

query IIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab0, tab2 cor1
----
243 values hashing to 2248b8c3b6efacb4e8fc6d9f81b7df8b

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1, tab1 AS cor2
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL + + col2 * - 27 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT ALL cor0.col1 * 31 FROM tab2 cor0
----
1829
527
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-411
SELECT DISTINCT - col1 DIV + 17 AS col0 FROM tab2 AS cor0
----
-1
-3

skipif mysql # not compatible
query I rowsort label-411
SELECT DISTINCT - col1 / + 17 AS col0 FROM tab2 AS cor0
----
-1
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 67 ) * + col1 col1 FROM tab1 AS cor0
----
-1742
-670
-871

query I rowsort
SELECT DISTINCT - ( col0 ) FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col0 + col1 col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + + col1 * - 9 * col0 FROM tab2 AS cor0
----
-12087
-1953
-41418

query I rowsort
SELECT ALL - - 86 * - col1 FROM tab0 AS cor0
----
-7396
-7826
-8342

query I rowsort
SELECT ALL cor0.col1 * cor0.col1 * - col1 FROM tab2 cor0
----
-205379
-29791
-4913

query I rowsort
SELECT + col0 * 45 * + col2 FROM tab0 AS cor0
----
1575
328410
35640

query I rowsort
SELECT DISTINCT - 94 AS col2 FROM tab2 AS cor0
----
-94

query I rowsort
SELECT + ( col0 + col2 ) AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL + ( 89 ) AS col1 FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT DISTINCT - - 76 * col2 FROM tab1 AS cor0
----
4104
4332
7296

query I rowsort
SELECT - col2 * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-424
SELECT ALL - CAST( 81 AS SIGNED ) + + col2 * 35 + + col1 FROM tab1 AS cor0
----
1835
1924
3292

skipif mysql # not compatible
query I rowsort label-424
SELECT ALL - CAST ( 81 AS INTEGER ) + + col2 * 35 + + col1 FROM tab1 AS cor0
----
1835
1924
3292

query I rowsort
SELECT + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - + ( 90 ) FROM tab2 AS cor0
----
-90

query I rowsort
SELECT + ( - cor0.col1 ) - 73 AS col2 FROM tab0 AS cor0
----
-159
-164
-170

onlyif mysql # use DIV operator for integer division
query I rowsort label-428
SELECT 52 * col1 * 23 - cor0.col2 DIV - col0 AS col1 FROM tab2 AS cor0
----
20332
37079
70564

skipif mysql # not compatible
query I rowsort label-428
SELECT 52 * col1 * 23 - cor0.col2 / - col0 AS col1 FROM tab2 AS cor0
----
20332
37079
70564

query I rowsort
SELECT + cor0.col2 + cor0.col2 * + col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT DISTINCT 90 FROM tab1, tab1 AS cor0
----
90

query I rowsort
SELECT 39 FROM tab1
----
39
39
39

query I rowsort
SELECT DISTINCT + ( - 65 ) * col1 + - 44 AS col2 FROM tab1
----
-1734
-694
-889

onlyif mysql # use DIV operator for integer division
query I rowsort label-434
SELECT - 96 DIV col1 FROM tab1
----
-3
-7
-9

skipif mysql # not compatible
query I rowsort label-434
SELECT - 96 / col1 FROM tab1
----
-3
-7
-9

query I rowsort
SELECT cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-436
SELECT - + col0 * + CAST( NULL AS SIGNED ) + 12 * cor0.col0 * + 38 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-436
SELECT - + col0 * + CAST ( NULL AS INTEGER ) + 12 * cor0.col0 * + 38 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + 28 AS col2 FROM tab1 AS cor0
----
-36
-52
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 col1 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT tab2.col0 * col2 + CAST ( + col1 AS REAL ) AS col2 FROM tab2
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-440
SELECT + 96 DIV - col0 + col1 col0 FROM tab2
----
16
18
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-440
SELECT + 96 / - col0 + col1 col0 FROM tab2
----
16
18
58

query I rowsort
SELECT DISTINCT + 94 + - col0 * 79 FROM tab2
----
-459
-6068
-6147

query I rowsort
SELECT + col0 * 56 + 83 * - col2 * - col1 AS col0 FROM tab1
----
108064
116700
50894

query I rowsort
SELECT 31 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ALL 76 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-445
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-445
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col1 * col2 + - col1 * + col2 + ( cor0.col1 ) FROM tab2 AS cor0
----
-1275
-1643
-3009

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + ( + col2 ) col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-451
SELECT DISTINCT cor0.col1 * CAST( 78 AS SIGNED ) - - col1 AS col1 FROM tab1 cor0
----
1027
2054
790

skipif mysql # not compatible
query I rowsort label-451
SELECT DISTINCT cor0.col1 * CAST ( 78 AS INTEGER ) - - col1 AS col1 FROM tab1 cor0
----
1027
2054
790

skipif mysql # not compatible
query I rowsort
SELECT - + col0 * - CAST ( col0 + - cor0.col1 * cor0.col0 AS REAL ) FROM tab1 AS cor0
----
-225
-36864
-76800

query I rowsort
SELECT ALL col0 * + 92 FROM tab2 AS cor0
----
644
7176
7268

query I rowsort
SELECT ALL + + col2 * col0 - - col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL tab2.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT tab2.col1 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-458
SELECT - - cor0.col0 DIV cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-458
SELECT - - cor0.col0 / cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col0 * - ( - 59 ) col2 FROM tab1 AS cor0
----
241664
377600
531

query I rowsort
SELECT ALL 64 + cor0.col1 FROM tab1 AS cor0
----
74
77
90

query I rowsort
SELECT DISTINCT + 30 AS col1 FROM tab1 AS cor0
----
30

query I rowsort
SELECT - + 29 AS col2 FROM tab2 AS cor0
----
-29
-29
-29

query I rowsort
SELECT - - col1 + - 41 * - 46 FROM tab0 AS cor0
----
1972
1977
1983

query I rowsort
SELECT + cor0.col1 + cor0.col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col2 + + col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT col2 * + tab2.col1 - col2 AS col0 FROM tab2
----
1508
608
810

query I rowsort
SELECT ALL - 8 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

query I rowsort
SELECT + + col0 * col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-469
SELECT - CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-469
SELECT - CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT cor0.col0 * + 30 FROM tab0, tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT + 14 FROM tab0, tab1 AS cor0, tab0 cor1, tab1 AS cor2
----
81 values hashing to 742ac5d81e64168a26fbd2bc8c808eff

query I rowsort
SELECT ALL + cor0.col0 + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col1 + col0 + - col1 AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT + ( + 24 ) FROM tab1
----
24
24
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - ( tab2.col0 ) col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + - 68 + + col0 + col1 * col2 FROM tab2 AS cor0
----
1544
657
776

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL + + 91 AS col2 FROM tab2 AS cor0
----
91
91
91

query I rowsort
SELECT + ( + col1 ) + col2 AS col2 FROM tab0 cor0
----
119
173
98

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0, tab0 cor1, tab1 cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT + - 32 * + col0 AS col0 FROM tab1 cor0
----
-2048
-2560
-96

query I rowsort
SELECT - + 35 * + col1 FROM tab0 AS cor0
----
-3010
-3185
-3395

query I rowsort
SELECT - col2 * - col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-484
SELECT col2 DIV cor0.col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-484
SELECT col2 / cor0.col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT + + 20 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT DISTINCT 23 * + col1 AS col2 FROM tab1
----
230
299
598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 col1 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-488
SELECT DISTINCT CAST( col2 AS SIGNED ) DIV - col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-488
SELECT DISTINCT CAST ( col2 AS INTEGER ) / - col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT DISTINCT ( 53 ) * col0 FROM tab2
----
371
4134
4187

query I rowsort
SELECT + ( col2 * col1 + - ( col1 ) ) FROM tab2
----
1475
629
806

query I rowsort
SELECT DISTINCT col1 * + ( col0 * ( col0 ) ) FROM tab1
----
234
40960
83200

query I rowsort
SELECT + 78 FROM tab1, tab1 cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 51 col2 FROM tab0
----
-51
-51
-51

query I rowsort
SELECT ALL ( + cor0.col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col0 * - col0 AS col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT 0 * + cor0.col0 * + 24 FROM tab2 AS cor0
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab1 cor1
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

query I rowsort
SELECT + ( + 70 ) AS col2 FROM tab0
----
70
70
70

query I rowsort
SELECT ALL + 27 FROM tab1
----
27
27
27

query I rowsort
SELECT ALL - + col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT 68 * col2 * - cor0.col2 FROM tab2 cor0
----
-45968
-49572
-98192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + col2 col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col0 + - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT 78 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
78

query I rowsort
SELECT DISTINCT + 47 * col1 * + col2 FROM tab2
----
30362
39339
72098

query I rowsort
SELECT DISTINCT - col1 + cor0.col2 + col1 * + col1 FROM tab1 AS cor0
----
147
252
704

query I rowsort
SELECT ALL - + cor0.col0 + - ( - col2 ) * - col0 * - col1 AS col1 FROM tab0 AS cor0
----
3360
664029
68088

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-508
SELECT ALL - col1 * CAST( col1 * cor0.col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-205379
-29791
-4913

skipif mysql # not compatible
query I rowsort label-508
SELECT ALL - col1 * CAST ( col1 * cor0.col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT ALL 93 AS col2 FROM tab2
----
93
93
93

query I rowsort
SELECT ALL 79 FROM tab1
----
79
79
79

query I rowsort
SELECT DISTINCT 25 AS col0 FROM tab1, tab2, tab1 AS cor0
----
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 5 col2 FROM tab1
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-513
SELECT ALL + col2 DIV col1 AS col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-513
SELECT ALL + col2 / col1 AS col0 FROM tab2
----
0
0
2

query I rowsort
SELECT tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT 76 + col1 FROM tab1 AS cor0
----
102
86
89

query I rowsort
SELECT + cor0.col0 + - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT 0 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - ( + 57 ) FROM tab2 AS cor0
----
-57
-57
-57

query I rowsort
SELECT + - 72 - col2 AS col0 FROM tab1 AS cor0
----
-126
-129
-168

query I rowsort
SELECT col0 + - col0 * col1 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 13 * - cor0.col1 + + cor0.col1 * - cor0.col0 col1 FROM tab2 AS cor0
----
-1122
-3835
186

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 99 + cor0.col2 + col1 col1 FROM tab2 AS cor0
----
-14
-41
-44

query I rowsort
SELECT ALL - 56 + + 62 - cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 5e8a7098c71deed45ebb1b25113bf1d3

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 3a953203ced079e372111d61dbd9e35f

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + + 7 + col2 FROM tab1 cor0
----
103
61
64

query I rowsort
SELECT - ( - col2 ) + + col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - - col0 + - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT 80 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
144
160
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-530
SELECT - CAST( NULL AS SIGNED ) + + cor0.col1 col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-530
SELECT - CAST ( NULL AS INTEGER ) + + cor0.col1 col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 13 FROM tab2 AS cor0
----
-13
-13
-13

query I rowsort
SELECT ALL col0 * - col1 + - 26 FROM tab0 AS cor0
----
-2090
-3421
-8125

query I rowsort
SELECT ALL + + col0 + - 83 AS col1 FROM tab1 AS cor0
----
-19
-3
-80

query I rowsort
SELECT + col2 + ( 54 ) FROM tab0 AS cor0
----
136
55
87

query I rowsort
SELECT ALL col1 + - col1 * cor0.col2 * - col0 FROM tab1 AS cor0
----
36490
4238
99853

query I rowsort
SELECT ALL - + col2 + col1 * 73 AS col0 FROM tab1 AS cor0
----
1844
673
853

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 + - cor0.col2 * 14 FROM tab0 cor0
----
-1237
-486
-49

query I rowsort
SELECT ALL + col0 * + col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-540
SELECT col2 - - ( - col1 ) DIV - col0 AS col2 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-540
SELECT col2 - - ( - col1 ) / - col0 AS col2 FROM tab2 AS cor0
----
26
31
38

query I rowsort
SELECT + col0 + - col1 AS col2 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT ALL + - col1 + ( 10 ) * + col0 AS col0 FROM tab2 cor0
----
39
721
773

query I rowsort
SELECT + 67 - col0 FROM tab0
----
-22
32
43

query I rowsort
SELECT col1 + - col0 * + col2 * + col0 FROM tab2
----
-1292
-158125
-237141

query I rowsort
SELECT tab1.col1 + - 49 AS col0 FROM tab1
----
-23
-36
-39

query I rowsort
SELECT ALL - col1 + col0 * - col0 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT DISTINCT + col0 * + col0 + col2 * + col1 + col2 AS col1 FROM tab2 AS cor0
----
6925
7644
913

query I rowsort
SELECT ALL - - col2 - + col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT col0 + + 36 FROM tab1 AS cor0
----
100
116
39

query I rowsort
SELECT ALL - col0 + 74 * col0 * col1 FROM tab0 AS cor0
----
152712
251195
599237

query I rowsort
SELECT DISTINCT - col1 - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - + col0 + - col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL cor0.col2 * + col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col0 + ( col2 ) FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-555
SELECT col2 * + CAST( NULL AS SIGNED ) + + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-555
SELECT col2 * + CAST ( NULL AS INTEGER ) + + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col2 * - col1 + - col0 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-558
SELECT + col2 - + ( col2 + col0 ) DIV col2 AS col0 FROM tab0 AS cor0
----
-35
32
80

skipif mysql # not compatible
query I rowsort label-558
SELECT + col2 - + ( col2 + col0 ) / col2 AS col0 FROM tab0 AS cor0
----
-35
32
80

query I rowsort
SELECT DISTINCT - col1 + - ( + cor0.col1 + col2 ) AS col2 FROM tab1 AS cor0
----
-106
-122
-77

query I rowsort
SELECT DISTINCT - cor0.col0 * 33 - + 98 FROM tab1 AS cor0
----
-197
-2210
-2738

query I rowsort
SELECT 41 - - 10 FROM tab0
----
51
51
51

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-563
SELECT CAST( - col2 AS SIGNED ) + + col1 * col1 AS col2 FROM tab0 AS cor0
----
7363
8199
9408

skipif mysql # not compatible
query I rowsort label-563
SELECT CAST ( - col2 AS INTEGER ) + + col1 * col1 AS col2 FROM tab0 AS cor0
----
7363
8199
9408

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 82 AS REAL ) AS col1 FROM tab1 AS cor0
----
-82
-82
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-565
SELECT cor0.col2 + - 53 DIV col0 AS col1 FROM tab2 AS cor0
----
20
26
38

skipif mysql # not compatible
query I rowsort label-565
SELECT cor0.col2 + - 53 / col0 AS col1 FROM tab2 AS cor0
----
20
26
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-566
SELECT DISTINCT - - col0 * col2 DIV + 7 FROM tab1 AS cor0
----
1097
23
521

skipif mysql # not compatible
query I rowsort label-566
SELECT DISTINCT - - col0 * col2 / + 7 FROM tab1 AS cor0
----
1097
23
521

query I rowsort
SELECT DISTINCT + cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-569
SELECT + 99 + col2 DIV - 78 FROM tab1 AS cor0
----
98
99
99

skipif mysql # not compatible
query I rowsort label-569
SELECT + 99 + col2 / - 78 FROM tab1 AS cor0
----
98
99
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 * tab0.col0 col2 FROM tab0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - - col1 * cor0.col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-573
SELECT ALL 59 * cor0.col1 DIV + ( col0 * col0 ) FROM tab0 AS cor0
----
0
4
8

skipif mysql # not compatible
query I rowsort label-573
SELECT ALL 59 * cor0.col1 / + ( col0 * col0 ) FROM tab0 AS cor0
----
0
4
8

query I rowsort
SELECT ALL tab1.col2 * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL - 2 * - col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - - 93 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
93

query I rowsort
SELECT DISTINCT - - cor0.col2 * col1 + - col0 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL col0 * + col1 * - col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + - cor0.col1 + + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col2 * + col1 + - ( 24 + + cor0.col2 ) * 63 AS col2 FROM tab2 AS cor0
----
-1616
-2376
-3260

query I rowsort
SELECT DISTINCT + col1 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col1 + + cor0.col2 * + cor0.col2 * - col2 AS col0 FROM tab2 cor0
----
-17517
-19652
-54855

onlyif mysql # use DIV operator for integer division
query I rowsort label-583
SELECT DISTINCT col0 + cor0.col1 DIV - col0 FROM tab2 AS cor0
----
3
78
79

skipif mysql # not compatible
query I rowsort label-583
SELECT DISTINCT col0 + cor0.col1 / - col0 FROM tab2 AS cor0
----
3
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 54 * + col2 * 92 col1 FROM tab0 AS cor0
----
163944
407376
4968

query I rowsort
SELECT DISTINCT - 2 * - col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - + col0 + col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + - 55 * col2 AS col0 FROM tab0 AS cor0
----
-1815
-4510
-55

query I rowsort
SELECT DISTINCT + + col2 + - col1 AS col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col1 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * + col1 * + ( - 94 + col0 ) col2 FROM tab0 AS cor0
----
198660
37310
5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + 0 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * + 62 + 24 AS col0 FROM tab0 AS cor0
----
5356
5666
6038

query I rowsort
SELECT + - col2 + ( + col0 ) * - col0 * ( + ( col1 ) ) FROM tab0 AS cor0
----
-118826
-49569
-720893

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - col1 * tab2.col2 * 75 AS col0 FROM tab2
----
-115050
-48450
-62775

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT ALL col2 * tab2.col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL + 60 + + col1 + col0 FROM tab2 cor0
----
156
197
98

query I rowsort
SELECT - - col0 + col2 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab2 AS cor0, tab2 cor1
----
7
78
79

query I rowsort
SELECT ALL - col2 + 82 AS col0 FROM tab0 AS cor0
----
0
49
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-603
SELECT ALL - + col0 * col1 + col0 * - CAST( - col1 + col0 AS SIGNED ) FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-603
SELECT ALL - + col0 * col1 + col0 * - CAST ( - col1 + col0 AS INTEGER ) FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - col1 * + 3 + cor0.col2 * + 74 FROM tab2 AS cor0
----
1747
1905
2761

query I rowsort
SELECT DISTINCT 17 * - 35 FROM tab1 AS cor0
----
-595

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) + - col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col1 FROM tab1, tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-608
SELECT DISTINCT CAST( NULL AS SIGNED ) * - col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-608
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - col0 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - col0 * col1 + - col0 * + col0 AS col2 FROM tab1 AS cor0
----
-4736
-7440
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-610
SELECT DISTINCT - 44 * 75 + col0 DIV + cor0.col0 FROM tab1 AS cor0
----
-3299

skipif mysql # not compatible
query I rowsort label-610
SELECT DISTINCT - 44 * 75 + col0 / + cor0.col0 FROM tab1 AS cor0
----
-3299

query I rowsort
SELECT 83 + col0 FROM tab0 AS cor0
----
107
118
172

query I rowsort
SELECT cor1.col2 + - 79 AS col2 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 231188b9b15991cad0df4650d65aa037

query I rowsort
SELECT - - 27 + + 42 * + col0 AS col2 FROM tab0 AS cor0
----
1035
1497
3765

query I rowsort
SELECT DISTINCT + 63 * 85 + col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
5422
5435
5464

query I rowsort
SELECT DISTINCT - ( 65 ) + + col1 * + 47 * col0 + + col1 AS col0 FROM tab2 AS cor0
----
10165
216288
63073

query IIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 WHERE NULL > ( NULL )
----

query I rowsort
SELECT DISTINCT + 80 + col1 AS col0 FROM tab2 AS cor0
----
111
139
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-618
SELECT ALL 34 DIV - col0 + + col2 * ( col2 ) + col0 * col1 FROM tab2
----
2787
5278
942

skipif mysql # not compatible
query I rowsort label-618
SELECT ALL 34 / - col0 + + col2 * ( col2 ) + col0 * col1 FROM tab2
----
2787
5278
942

query I rowsort
SELECT DISTINCT 20 + col1 FROM tab1
----
30
33
46

query I rowsort
SELECT tab1.col2 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-621
SELECT ALL - col2 * cor0.col1 DIV col0 AS col2 FROM tab1 AS cor0
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-621
SELECT ALL - col2 * cor0.col1 / col0 AS col2 FROM tab1 AS cor0
----
-15
-468
-8

query I rowsort
SELECT ALL + + col0 + + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - + col1 * col2 + + cor0.col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - - 32 FROM tab1 AS cor0
----
32
32
32

query I rowsort
SELECT + 56 FROM tab1
----
56
56
56

query I rowsort
SELECT ALL - - 57 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT 73 * + tab2.col1 AS col1 FROM tab2
----
1241
2263
4307

query I rowsort
SELECT col2 + - col0 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT 12 FROM tab2
----
12

query I rowsort
SELECT - col1 + tab1.col0 AS col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT - col0 * cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT + 82 FROM tab0 AS cor0
----
82
82
82

query I rowsort
SELECT DISTINCT + tab1.col2 * + 32 FROM tab1
----
1728
1824
3072

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-635
SELECT + ( - cor0.col2 ) + CAST( 99 AS SIGNED ) FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 31c8a14bde05225a47c2ba7cd367534f

skipif mysql # not compatible
query I rowsort label-635
SELECT + ( - cor0.col2 ) + CAST ( 99 AS INTEGER ) FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 31c8a14bde05225a47c2ba7cd367534f

query I rowsort
SELECT ALL - tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-637
SELECT ALL - CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-637
SELECT ALL - CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col2 * col0 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT + 75 AS col2 FROM tab1
----
75
75
75

query I rowsort
SELECT ALL ( - col2 + col2 ) FROM tab1
----
0
0
0

query I rowsort
SELECT ( 65 ) AS col2 FROM tab2 AS cor0
----
65
65
65

query I rowsort
SELECT + col2 + col0 * col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - + col1 * + col1 + + col2 * ( col2 ) FROM tab1 AS cor0
----
2240
3149
9047

query I rowsort
SELECT ( 39 ) * + col0 AS col2 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT DISTINCT 27 FROM tab0, tab1 cor0
----
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-646
SELECT ALL + 37 DIV cor0.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

skipif mysql # not compatible
query I rowsort label-646
SELECT ALL + 37 / cor0.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

query I rowsort
SELECT DISTINCT - 28 AS col1 FROM tab0
----
-28

query I rowsort
SELECT DISTINCT - 84 AS col0 FROM tab1
----
-84

query I rowsort
SELECT + ( + tab0.col2 ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col2 col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - 25 AS col1 FROM tab0 AS cor0
----
-25
-25
-25

query I rowsort
SELECT DISTINCT + col0 + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - col2 * col0 * - col2 AS col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT - col0 * col1 * 32 AS col2 FROM tab0 AS cor0
----
-108640
-259168
-66048

query I rowsort
SELECT DISTINCT + col1 * + col0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - col0 * + col1 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 * - col0 * - col0 + + col0 * + col1 + cor0.col2 col2 FROM tab0 cor0
----
29169
380468
60971

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 + col2 * col0 col1 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT ALL - col2 + 45 * col0 FROM tab0 AS cor0
----
1047
1574
3923

query I rowsort
SELECT ALL + - cor0.col0 * + col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 61 * col0 col1 FROM tab1 AS cor0
----
157
3894
4867

query I rowsort
SELECT col1 * col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - + col1 * ( 1 ) * col1 + + 78 + + col0 AS col2 FROM tab0 AS cor0
----
-7294
-8114
-9296

query I rowsort
SELECT col2 * 33 FROM tab0 AS cor0
----
1089
2706
33

query I rowsort
SELECT - 5 AS col2 FROM tab1
----
-5
-5
-5

query I rowsort
SELECT 60 * col2 FROM tab0
----
1980
4920
60

query I rowsort
SELECT ALL + col0 + col1 AS col1 FROM tab0
----
110
132
180

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2, tab0 AS cor0, tab2 AS cor1
----
972 values hashing to 42e69ecdafb3c81046bc5cb4c98b1666

query I rowsort
SELECT + col1 + col2 * 16 + cor0.col0 AS col0 FROM tab1 cor0
----
1629
893
986

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-670
SELECT - cor0.col0 * - CAST( 39 AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
22464
308919
47775

skipif mysql # not compatible
query I rowsort label-670
SELECT - cor0.col0 * - CAST ( 39 AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
22464
308919
47775

query I rowsort
SELECT + col2 + - col1 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + cor0.col1 * col2 + - 27 + col2 AS col2 FROM tab1 AS cor0
----
1317
1431
600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-673
SELECT + tab0.col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-673
SELECT + tab0.col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + + ( 1 * - col0 ) FROM tab2
----
0
0
0

query I rowsort
SELECT col1 + cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col1 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL + - col0 * - ( col2 ) + col0 FROM tab1 AS cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - 67 col1 FROM tab1 AS cor0
----
-121
-124
-163

query I rowsort
SELECT + - col2 + ( 84 ) + col1 FROM tab2 AS cor0
----
117
63
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-680
SELECT - + col1 + - col1 DIV 43 + + col0 * ( col2 ) FROM tab2 AS cor0
----
158
1968
2985

skipif mysql # not compatible
query I rowsort label-680
SELECT - + col1 + - col1 / 43 + + col0 * ( col2 ) FROM tab2 AS cor0
----
158
1968
2985

query I rowsort
SELECT DISTINCT - ( + 14 ) FROM tab0 AS cor0
----
-14

onlyif mysql # use DIV operator for integer division
query I rowsort label-682
SELECT DISTINCT - cor0.col2 DIV 31 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-682
SELECT DISTINCT - cor0.col2 / 31 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT 65 FROM tab2 AS cor0
----
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-684
SELECT + cor0.col2 * cor0.col0 DIV + col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-684
SELECT + cor0.col2 * cor0.col0 / + col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - + ( + 91 ) AS col2 FROM tab2 AS cor0
----
-91
-91
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-686
SELECT - + col2 * + 59 + col0 + + 22 DIV + 36 FROM tab1 AS cor0
----
-3183
-3299
-5584

skipif mysql # not compatible
query I rowsort label-686
SELECT - + col2 * + 59 + col0 + + 22 / + 36 FROM tab1 AS cor0
----
-3183
-3299
-5584

query I rowsort
SELECT DISTINCT + col1 * - col0 * col2 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - col1 + col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + + col1 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + ( + col1 ) * col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-691
SELECT ALL - CAST( NULL AS SIGNED ) + + col1 * - col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-691
SELECT ALL - CAST ( NULL AS INTEGER ) + + col1 * - col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-692
SELECT DISTINCT + col0 DIV tab1.col0 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-692
SELECT DISTINCT + col0 / tab1.col0 FROM tab1
----
1

query I rowsort
SELECT DISTINCT col0 * + col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col2 * ( - col0 ) FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT 10 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
10

query I rowsort
SELECT - col1 * - 62 FROM tab2
----
1054
1922
3658

query I rowsort
SELECT col1 * tab0.col1 * - 98 FROM tab0
----
-724808
-811538
-922082

query I rowsort
SELECT cor0.col0 + - col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT - 80 AS col0 FROM tab0 AS cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT + - 80 + - col2 * ( - col2 ) FROM tab2 AS cor0
----
1364
596
649

query I rowsort
SELECT col0 + + col2 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL - + 41 * + col0 AS col0 FROM tab0 AS cor0
----
-1435
-3649
-984

query I rowsort
SELECT col0 * - col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col0 + - col0 + col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + 56 * cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b5ac07851fe10ec7b4f57100c31039f6

query I rowsort
SELECT ALL col1 - - tab2.col2 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT + + col2 + + col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 + col2 * col1 col2 FROM tab2
----
-2356
-494
648

query I rowsort
SELECT + 78 AS col0 FROM tab0 AS cor0
----
78
78
78

query I rowsort
SELECT ALL 79 AS col2 FROM tab0
----
79
79
79

query I rowsort
SELECT DISTINCT - 14 + col1 * + col1 FROM tab1 AS cor0
----
155
662
86

query I rowsort
SELECT ALL + cor1.col2 AS col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT 83 AS col0 FROM tab0 AS cor0
----
83
83
83

query I rowsort
SELECT DISTINCT + col2 * - col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - ( col0 ) * - col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - cor0.col2 + + col1 * ( + col0 ) AS col2 FROM tab2 AS cor0
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-717
SELECT col1 DIV 83 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-717
SELECT col1 / 83 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT col1 * 55 * col0 FROM tab2 AS cor0
----
11935
253110
73865

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-719
SELECT ALL - col1 + CAST( NULL AS SIGNED ) + + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-719
SELECT ALL - col1 + CAST ( NULL AS INTEGER ) + + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 * 97 AS col1 FROM tab1 AS cor0
----
-5238
-5529
-9312

query I rowsort
SELECT DISTINCT + col2 * - col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col2 * + col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + col1 + + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - - col0 * col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col1 * 3 AS col1 FROM tab2 AS cor0
----
-177
-51
-93

query I rowsort
SELECT ALL - col1 * 29 + + 85 FROM tab1 AS cor0
----
-205
-292
-669

query I rowsort
SELECT + 17 FROM tab0
----
17
17
17

query I rowsort
SELECT ALL + tab1.col1 * col0 FROM tab1
----
1040
640
78

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) BETWEEN - col2 * + col2 + col2 AND - col2 * col0
----

query I rowsort
SELECT - col2 + + col1 * col2 AS col0 FROM tab1
----
1152
1350
513

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 > NULL
----

query I rowsort
SELECT DISTINCT + col2 - - col1 AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT col1 * col0 + + col1 * - col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + col1 - - col0 AS col2 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-735
SELECT col1 * col0 DIV col0 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-735
SELECT col1 * col0 / col0 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL col1 * + col2 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 * - col1 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + tab2.col0 * col1 FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + tab0.col1 + col2 col2 FROM tab0
----
63
84
95

query I rowsort
SELECT col1 FROM tab1 WHERE ( NULL ) NOT BETWEEN ( col1 ) AND NULL
----

query I rowsort
SELECT DISTINCT col2 * col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT + tab0.col1 + col0 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT + col1 * + col1 FROM tab0 WHERE ( col2 ) > ( col1 / col2 )
----
7396
8281

query I rowsort
SELECT ALL col1 FROM tab0 WHERE NOT ( NULL ) >= ( NULL )
----

query I rowsort
SELECT ALL + col2 * + col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + col2 + col2 * + col1 * - col2 FROM tab2
----
-22572
-24510
-39858

query I rowsort
SELECT tab2.col2 * col2 AS col0 FROM tab2 WHERE NOT - col0 = ( NULL )
----

query I rowsort
SELECT - col1 + + col2 * col1 AS col2 FROM tab0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-749
SELECT col2 DIV col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-749
SELECT col2 / col0 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT + col1 - tab2.col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT col1 * col2 - tab2.col0 FROM tab2
----
1456
567
830

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) >= ( NULL )
----

query I rowsort
SELECT + col2 + - col0 * col0 + + col2 FROM tab1
----
-3982
-6208
99

query I rowsort
SELECT DISTINCT + col0 * - col1 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - col0 * col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT tab1.col0 * col1 + + col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT col2 FROM tab1 WHERE NULL < NULL
----

query I rowsort
SELECT ALL + tab1.col2 * tab1.col0 + col2 FROM tab1 WHERE NOT NULL > NULL
----

query I rowsort
SELECT - col1 * - col1 + col0 * col2 + - col0 * col1 * + col2 AS col2 FROM tab1
----
-32732
-3374
-91991

onlyif mysql # use DIV operator for integer division
query I rowsort label-760
SELECT + col0 - + col1 DIV - col1 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-760
SELECT + col0 - + col1 / - col1 FROM tab1
----
4
65
81

query I rowsort
SELECT + col0 * col1 AS col1 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col0 + tab1.col2 col2 FROM tab1 WHERE col1 IN ( tab1.col1 )
----
-24
-583
-944

query I rowsort
SELECT DISTINCT ( 93 ) * col2 * + 32 + + col1 FROM tab1
----
160730
169642
285709

onlyif mysql # use DIV operator for integer division
query I rowsort label-764
SELECT ALL + col2 + + 54 DIV - col1 AS col0 FROM tab1
----
52
52
92

skipif mysql # not compatible
query I rowsort label-764
SELECT ALL + col2 + + 54 / - col1 AS col0 FROM tab1
----
52
52
92

query I rowsort
SELECT + col0 + cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-766
SELECT - CAST( 97 AS SIGNED ) * col2 FROM tab1
----
-5238
-5529
-9312

skipif mysql # not compatible
query I rowsort label-766
SELECT - CAST ( 97 AS INTEGER ) * col2 FROM tab1
----
-5238
-5529
-9312

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab1 cor0, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

query I rowsort
SELECT 31 AS col0 FROM tab1
----
31
31
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-769
SELECT cor1.col1 DIV ( + cor1.col1 ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-769
SELECT cor1.col1 / ( + cor1.col1 ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT ALL 50 * - col2 + - col0 AS col0 FROM tab0 AS cor0
----
-1674
-4189
-85

query I rowsort
SELECT - - 0 + - col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - col2 * - col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col1 + col0 * cor0.col2 AS col0 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT ALL - + cor0.col2 * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col0 + cor0.col2 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + - 99 FROM tab1 cor0
----
-99

query I rowsort
SELECT DISTINCT - 44 + - col2 FROM tab2 AS cor0
----
-70
-71
-82

query I rowsort
SELECT ALL - col1 + - col0 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 * ( + ( + col0 ) ) - col1 col1 FROM tab2 AS cor0
----
22814
271459
6696

query I rowsort
SELECT DISTINCT - col0 + col2 FROM tab2
----
-41
-52
20

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 15ae1b54cae2dcf5c6eef7f1d15689eb

query I rowsort
SELECT DISTINCT - - cor0.col0 * + col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT cor0.col1 + ( col2 ) - - cor0.col2 AS col2 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT DISTINCT col2 * col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-786
SELECT - col1 DIV - col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-786
SELECT - col1 / - col0 FROM tab0 cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + cor0.col0 col2 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-788
SELECT ALL col0 * col1 DIV - col0 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-788
SELECT ALL col0 * col1 / - col0 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 32 * cor0.col1 col2 FROM tab1 AS cor0
----
330
429
858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-790
SELECT ALL + col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-790
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + + 73 * tab1.col0 AS col2 FROM tab1
----
273
4729
5936

query I rowsort
SELECT col1 + col0 * col2 AS col2 FROM tab2 cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-793
SELECT DISTINCT + col1 DIV 23 AS col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-793
SELECT DISTINCT + col1 / 23 AS col2 FROM tab1 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + + col2 + col2 * + col1 FROM tab1 cor0
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col1 col1 FROM tab0 AS cor0
----
-53
-9
-96

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

onlyif mysql # use DIV operator for integer division
query I rowsort label-798
SELECT DISTINCT cor0.col0 DIV 70 + col1 FROM tab1 AS cor0
----
10
14
26

skipif mysql # not compatible
query I rowsort label-798
SELECT DISTINCT cor0.col0 / 70 + col1 FROM tab1 AS cor0
----
10
14
26

query I rowsort
SELECT DISTINCT col0 * + col2 + - col0 * + ( 14 + + col0 ) AS col2 FROM tab0 AS cor0
----
-120
-1680
-1869

query I rowsort
SELECT - 50 + ( + col2 ) AS col1 FROM tab1 cor0
----
4
46
7

query I rowsort
SELECT DISTINCT - 32 FROM tab1, tab0, tab2 AS cor0
----
-32

query I rowsort
SELECT + ( col2 ) + + col0 * 23 AS col0 FROM tab2 AS cor0
----
1820
1855
188

query I rowsort
SELECT DISTINCT + 82 FROM tab2, tab2 AS cor0
----
82

query I rowsort
SELECT DISTINCT - - col0 + + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + - ( + col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT 18 * 84 AS col2 FROM tab1 AS cor0
----
1512
1512
1512

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 + - tab0.col0 + - col1 col1 FROM tab0
----
-97
682
7118

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-808
SELECT + CAST( NULL AS SIGNED ) * cor0.col1 - cor0.col0 * ( 55 ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-808
SELECT + CAST ( NULL AS INTEGER ) * cor0.col1 - cor0.col0 * ( 55 ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 63 AS col2 FROM tab1 AS cor0
----
63
63
63

query I rowsort
SELECT + - col0 + - col1 + + cor0.col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + + ( col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col1 * col0 + cor0.col1 * + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-115430
-47472
-712712

query I rowsort
SELECT + 68 FROM tab2 AS cor0
----
68
68
68

query I rowsort
SELECT DISTINCT 25 + col0 * + col1 * - col1 FROM tab2
----
-22806
-271493
-6702

query I rowsort
SELECT ALL + cor0.col0 * - cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col0 + cor0.col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + 70 FROM tab0 AS cor0
----
70

query I rowsort
SELECT - + col1 + col0 + cor0.col2 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT - - col0 + - col0 + col1 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col0 + col2 * - col2 + cor0.col2 * + col1 FROM tab0 AS cor0
----
131
1773
827

query I rowsort
SELECT DISTINCT + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-822
SELECT + + col1 DIV - col1 col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-822
SELECT + + col1 / - col1 col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - 12 * - tab0.col0 AS col1 FROM tab0
----
1068
288
420

query I rowsort
SELECT + 23 * col2 AS col2 FROM tab0
----
1886
23
759

query I rowsort
SELECT ( - col2 ) + + col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col0 + - cor0.col1 * - col1 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query IIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab1, tab1 AS cor1
----
243 values hashing to 2464a6f4cfabe66aeca50fcb4cd85bf5

query I rowsort
SELECT DISTINCT tab2.col1 AS col0 FROM tab2
----
17
31
59

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
243 values hashing to ce53c0e8839c969b0513568da6eb2c4b

query I rowsort
SELECT DISTINCT tab0.col1 FROM tab0, tab2 AS cor0, tab1 cor1
----
86
91
97

query I rowsort
SELECT DISTINCT ( - tab2.col2 ) AS col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT col1 * + tab0.col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + col1 * + col1 FROM tab0
----
7396
8281
9409

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2, tab0 AS cor0 WHERE ( NULL ) < ( NULL )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-835
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-835
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 49 AS col0 FROM tab0
----
49

query I rowsort
SELECT + 29 * col0 * - cor0.col2 + col0 * col1 AS col0 FROM tab0 AS cor0
----
-203543
-20904
2380

query I rowsort
SELECT - cor0.col2 * cor0.col1 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to c52f276f0448e9317aa4a2c462e0bab5

query I rowsort
SELECT DISTINCT col2 * - 24 AS col0 FROM tab0
----
-1968
-24
-792

query I rowsort
SELECT + 0 * - col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab1, tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-842
SELECT col0 DIV - col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-842
SELECT col0 / - col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT col2 * col2 + + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL col0 * cor0.col2 * - col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + cor0.col0 col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col1 * + col1 * col0 AS col1 FROM tab1
----
13520
2028
6400

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col0 NOT BETWEEN + col1 / - col2 AND col2
----
3
26
54
80
13
96

query I rowsort
SELECT tab1.col0 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT - col2 - + col1 AS col1 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT - tab0.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + tab2.col0 / col2 AS col1 FROM tab2 WHERE NULL NOT IN ( - col1 )
----

query I rowsort
SELECT + col1 * col1 + + col0 AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL + cor0.col0 FROM tab1, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT - col0 * - col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT col1 * col0 + col0 + col2 * + col0 FROM tab0
----
15486
2880
3465

query III rowsort
SELECT * FROM tab0 WHERE NULL > ( col0 - col1 )
----

query I rowsort
SELECT col1 + - col2 * col0 - + col1 * - tab1.col0 AS col0 FROM tab1
----
-2998
-58
-6627

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-859
SELECT + col0 + + col2 DIV - col2 + col2 FROM tab0
----
170
35
56

skipif mysql # not compatible
query I rowsort label-859
SELECT + col0 + + col2 / - col2 + col2 FROM tab0
----
170
35
56

query I rowsort
SELECT DISTINCT - col1 / + col0 FROM tab2 WHERE NULL NOT IN ( + col2 + col0 )
----

query I rowsort
SELECT DISTINCT + col0 * col2 + - col2 AS col2 FROM tab0 WHERE NOT NULL BETWEEN ( col1 ) AND NULL
----

query I rowsort
SELECT ALL + col1 * + tab1.col0 * - col2 FROM tab1
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col1 + col1 col1 FROM tab0
----
148
159
93

query I rowsort
SELECT cor0.col2 + + cor0.col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col1 / + col0 AS col0 FROM tab0 AS cor0 WHERE NOT NULL IN ( cor0.col1 / - col1 + + cor0.col0 )
----

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + col0 - col2 FROM tab1 cor0
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL - cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT ( - cor0.col1 ) <= col1 + col2 * - col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE ( NULL ) NOT BETWEEN + col0 + + col2 AND ( col0 * + col2 + - cor0.col1 )
----

query I rowsort
SELECT cor0.col2 AS col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL - col0 * - col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col0 - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + col0 FROM tab0 AS cor0 WHERE ( NULL ) NOT BETWEEN + col0 + + col2 AND - col1 / - col0
----

query I rowsort
SELECT ALL + col0 * - col1 AS col2 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-877
SELECT ALL + col1 DIV + tab0.col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-877
SELECT ALL + col1 / + tab0.col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL - tab1.col2 * tab1.col1 AS col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL - tab0.col1 AS col0 FROM tab0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-880
SELECT - col0 DIV + cor0.col0 col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-880
SELECT - col0 / + cor0.col0 col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + col0 + - col0 * - cor0.col1 FROM tab1 AS cor0
----
1120
704
81

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL <> ( NULL ) OR NOT NULL NOT BETWEEN col2 AND ( + col0 * - col1 )
----

query I rowsort
SELECT ALL + col0 * col2 + + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT col1 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + + col1 * col2 - + col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT col1 * + col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + col1 - - col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT cor0.col0 + cor0.col1 * + col2 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT ALL - col1 * - col2 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-891
SELECT ALL - tab0.col0 DIV col0 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-891
SELECT ALL - tab0.col0 / col0 AS col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + cor0.col0 * + col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT col1 * cor0.col2 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col1 * cor0.col0 + col2 * cor0.col0 + col0 AS col2 FROM tab1 AS cor0
----
3072
6720
87

query I rowsort
SELECT DISTINCT col0 * - cor0.col1 + cor0.col2 AS col1 FROM tab1 cor0
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 col2 FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL col0 * - col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-899
SELECT CAST( - 16 AS SIGNED ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

skipif mysql # not compatible
query I rowsort label-899
SELECT CAST ( - 16 AS INTEGER ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT DISTINCT - col0 * col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-901
SELECT DISTINCT + col0 + - CAST( NULL AS SIGNED ) col2 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-901
SELECT DISTINCT + col0 + - CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - col0 * + col2 + ( + col0 ) * + col2 FROM tab1
----
0

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to e84152c0bf436177d3b3d80e42832d4f

query I rowsort
SELECT ALL - col2 * 13 FROM tab2 AS cor0
----
-338
-351
-494

query I rowsort
SELECT + col0 * col0 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-906
SELECT ALL - - col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-906
SELECT ALL - - col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col2 * ( 79 ) FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT - + col2 + 52 * - col2 + col1 FROM tab0 AS cor0
----
-1663
-4255
44

query I rowsort
SELECT + - col2 + + col0 * - col2 AS col1 FROM tab1 cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL - - ( - 62 ) + col0 FROM tab0 AS cor0
----
-27
-38
27

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab0 AS cor0
----
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 60 * col2 * 86 col0 FROM tab1 AS cor0
----
278666
294130
495373

query I rowsort
SELECT + + col1 * + col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + col2 - - col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - - col0 * col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col2 + 0 * + col1 - ( col2 ) * cor0.col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT cor0.col2 * - col1 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL + col1 * - col0 + - col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - 73 * + 78 AS col2 FROM tab1 AS cor0
----
-5694
-5694
-5694

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 39 * col1 col2 FROM tab0 AS cor0
----
3354
3549
3783

onlyif mysql # use DIV operator for integer division
query I rowsort label-923
SELECT DISTINCT + - col2 + - col1 DIV + col0 AS col1 FROM tab1 cor0
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-923
SELECT DISTINCT + - col2 + - col1 / + col0 AS col1 FROM tab1 cor0
----
-57
-62
-96

query I rowsort
SELECT ALL 16 * ( - col1 ) + - col2 FROM tab1 AS cor0
----
-217
-304
-470

onlyif mysql # use DIV operator for integer division
query I rowsort label-925
SELECT + ( col1 ) + - cor0.col2 DIV + col2 FROM tab0 cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-925
SELECT + ( col1 ) + - cor0.col2 / + col2 FROM tab0 cor0
----
85
90
96

query I rowsort
SELECT ALL col2 + + col1 - col0 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT DISTINCT + col0 * - col2 + - tab0.col1 + - col2 FROM tab0
----
-133
-7471
-911

query I rowsort
SELECT ALL + - col2 * col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ( col1 ) + cor0.col1 * col1 AS col0 FROM tab0 cor0
----
7482
8372
9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-930
SELECT DISTINCT + CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-930
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 10 + - 72 * - col1 FROM tab1 AS cor0
----
1882
730
946

query I rowsort
SELECT + 68 * col1 * + col1 FROM tab1 AS cor0
----
11492
45968
6800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - + 63 * + col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1993
-5075
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col1 - - 99 col2 FROM tab2 AS cor0
----
1060
3580
388

query I rowsort
SELECT + + col0 * + col1 FROM tab1 cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - + col2 + col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL - col1 + - cor0.col1 * col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - col0 * col1 * 98 FROM tab1 AS cor0
----
-101920
-62720
-7644

query I rowsort
SELECT + + col2 + + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - - cor0.col2 + col1 AS col0 FROM tab2 cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-944
SELECT DISTINCT cor0.col2 DIV - col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-944
SELECT DISTINCT cor0.col2 / - col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 33 col0 FROM tab2
----
33
33
33

query I rowsort
SELECT - 54 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 40 * - col1 col2 FROM tab0 AS cor0
----
-3440
-3640
-3880

query I rowsort
SELECT DISTINCT + + col1 + + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-949
SELECT DISTINCT + col1 DIV - col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-949
SELECT DISTINCT + col1 / - col1 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - ( col0 ) + + 33 AS col2 FROM tab2 AS cor0
----
-45
-46
26

query I rowsort
SELECT - col2 + col2 + 56 * - col2 FROM tab0 AS cor0
----
-1848
-4592
-56

query I rowsort
SELECT ALL + cor0.col2 + col1 * + 74 AS col2 FROM tab2 AS cor0
----
1296
2321
4392

query I rowsort
SELECT DISTINCT - - col1 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT col0 + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - ( col0 ) + col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-956
SELECT - + col2 + col0 DIV 70 AS col0 FROM tab2 AS cor0
----
-25
-27
-37

skipif mysql # not compatible
query I rowsort label-956
SELECT - + col2 + col0 / 70 AS col0 FROM tab2 AS cor0
----
-25
-27
-37

query I rowsort
SELECT ALL col0 + - col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col2 + ( - col1 ) FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + cor1.col1 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT cor0.col0 * ( 35 ) + + col1 AS col2 FROM tab0 cor0
----
1322
3206
926

query I rowsort
SELECT ALL + tab0.col1 + col1 FROM tab0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-962
SELECT col1 + - CAST( NULL AS SIGNED ) * ( col2 * - col0 ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-962
SELECT col1 + - CAST ( NULL AS INTEGER ) * ( col2 * - col0 ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * cor0.col1 - - col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-964
SELECT ALL - + col0 * CAST( NULL AS DECIMAL ) + col0 + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-964
SELECT ALL - + col0 * CAST ( NULL AS REAL ) + col0 + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-965
SELECT + - cor0.col0 + + CAST( 71 AS SIGNED ) FROM tab2 AS cor0
----
-7
-8
64

skipif mysql # not compatible
query I rowsort label-965
SELECT + - cor0.col0 + + CAST ( 71 AS INTEGER ) FROM tab2 AS cor0
----
-7
-8
64

query I rowsort
SELECT ALL + + cor0.col2 * + ( col1 * col0 ) - - ( col1 * cor0.col2 ) FROM tab2 AS cor0
----
121186
51680
6696

query I rowsort
SELECT - + cor0.col1 AS col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + col0 * - col0 + ( 17 ) FROM tab2
----
-32
-6067
-6224

query I rowsort
SELECT + 81 * tab2.col1 FROM tab2
----
1377
2511
4779

query I rowsort
SELECT + 5 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT col0 - col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT col1 * - col1 + + 84 FROM tab0
----
-7312
-8197
-9325

query I rowsort
SELECT DISTINCT - col0 + col2 * - col2 FROM tab1
----
-2919
-3313
-9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-974
SELECT - cor0.col1 * + CAST( NULL AS SIGNED ) col1 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-974
SELECT - cor0.col1 * + CAST ( NULL AS INTEGER ) col1 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - tab2.col1 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT ALL + col2 * col2 + ( col0 ) AS col0 FROM tab0 AS cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-977
SELECT - - cor0.col1 DIV + col0 + - col2 AS col0 FROM tab2 AS cor0
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-977
SELECT - - cor0.col1 / + col0 + - col2 AS col0 FROM tab2 AS cor0
----
-23
-26
-38

query I rowsort
SELECT - col2 * col0 + cor0.col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + col2 * 13 + + col1 AS col1 FROM tab2
----
382
397
511

query I rowsort
SELECT - ( + col0 ) * + col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + - col2 * + col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT + col1 * + col2 FROM tab2
----
1534
646
837

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0 CROSS JOIN tab1, tab0 AS cor1
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL + ( col1 ) * col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - cor0.col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT + col2 + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - 51 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

query I rowsort
SELECT ALL 4 + col0 * col1 AS col1 FROM tab2
----
1347
221
4606

onlyif mysql # use DIV operator for integer division
query I rowsort label-990
SELECT ALL col0 DIV + col0 + - col1 * + col2 AS col2 FROM tab1
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-990
SELECT ALL col0 / + col0 + - col1 * + col2 AS col2 FROM tab1
----
-1247
-1403
-569

query I rowsort
SELECT tab0.col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-992
SELECT DISTINCT 58 DIV col2 + + 28 * - 36 FROM tab1
----
-1007
-1008

skipif mysql # not compatible
query I rowsort label-992
SELECT DISTINCT 58 / col2 + + 28 * - 36 FROM tab1
----
-1007
-1008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - col0 * col1 col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + cor0.col2 * col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT col2 * col1 + 56 + col1 * col2 FROM tab2 AS cor0
----
1348
1730
3124

query I rowsort
SELECT ALL ( - cor0.col2 ) * + ( col2 ) AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + col1 * col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col1 * 28 col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab1, tab2 AS cor1
----
243 values hashing to db223b47a7b42b017479529b66276fae

query I rowsort
SELECT - col1 * col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ( col2 ) - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 - - col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * + col1 + - col0 AS col0 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT - 51 * 61 + + col0 * col0 AS col1 FROM tab0 cor0
----
-1886
-2535
4810

query I rowsort
SELECT + ( col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1005
SELECT + CAST( NULL AS SIGNED ) / 87 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1005
SELECT + CAST ( NULL AS INTEGER ) / 87 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 * - col0 - col1 FROM tab0 AS cor0
----
1128
490
7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-1007
SELECT + 98 * - col1 DIV ( col1 ) + - col2 FROM tab1 AS cor0
----
-152
-155
-194

skipif mysql # not compatible
query I rowsort label-1007
SELECT + 98 * - col1 / ( col1 ) + - col2 FROM tab1 AS cor0
----
-152
-155
-194

query I rowsort
SELECT + 22 + col0 FROM tab0 AS cor0
----
111
46
57

query I rowsort
SELECT DISTINCT - cor0.col1 * col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT tab1.col2 + - 18 + col2 FROM tab1
----
174
90
96

query I rowsort
SELECT 46 FROM tab1, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab1, tab0 AS cor1
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT 13 FROM tab0, tab2 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

onlyif mysql # use DIV operator for integer division
query I rowsort label-1014
SELECT - - col2 * 95 DIV + cor0.col2 FROM tab1 AS cor0
----
95
95
95

skipif mysql # not compatible
query I rowsort label-1014
SELECT - - col2 * 95 / + cor0.col2 FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT ALL - 59 AS col2 FROM tab2
----
-59
-59
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 col0 FROM tab2
----
68
68
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col2 * col0 col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT col0 + - 8 FROM tab1
----
-5
56
72

query I rowsort
SELECT ALL col2 * col0 AS col2 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1020
SELECT DISTINCT col2 DIV - col0 AS col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-1020
SELECT DISTINCT col2 / - col0 AS col0 FROM tab2 AS cor0
----
-3
0

query I rowsort
SELECT ALL + col0 + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + 45 AS col1 FROM tab2 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT - + ( cor0.col0 ) * - col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL col0 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1025
SELECT DISTINCT + col0 DIV + col1 AS col2 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-1025
SELECT DISTINCT + col0 / + col1 AS col2 FROM tab0
----
0

query I rowsort
SELECT ALL - tab2.col0 - - 36 * - 2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c1d141d238e84c9f8920e2c04a7976c6

query I rowsort
SELECT + 77 FROM tab1, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT 50 * + tab1.col2 FROM tab1
----
2700
2850
4800

query I rowsort
SELECT - ( + 7 ) * col1 + col1 * col0 FROM tab0
----
1462
2716
7462

query I rowsort
SELECT - ( - cor0.col1 ) FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1031
SELECT - - CAST( NULL AS SIGNED ) + ( col0 ) * ( + cor0.col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1031
SELECT - - CAST ( NULL AS INTEGER ) + ( col0 ) * ( + cor0.col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 81 + col0 AS col2 FROM tab1
----
-1
-17
-78

query I rowsort
SELECT + 43 FROM tab0
----
43
43
43

query I rowsort
SELECT DISTINCT ( tab1.col1 * col2 + col0 ) AS col2 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL 20 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1036
SELECT - col0 * col1 * - CAST( + col2 AS SIGNED ) AS col2 FROM tab0
----
3395
664118
68112

skipif mysql # not compatible
query I rowsort label-1036
SELECT - col0 * col1 * - CAST ( + col2 AS INTEGER ) AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col0 * + col1 * + ( col1 * - col1 ) AS col0 FROM tab2
----
-16019562
-208537
-388127

query I rowsort
SELECT - 77 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT tab1.col1 * col0 * - 23 AS col2 FROM tab1
----
-14720
-1794
-23920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 81 col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
81

query I rowsort
SELECT DISTINCT - col0 + + col1 AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT + - col2 * ( col1 ) AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col0 * 55 FROM tab2
----
-385
-4290
-4345

query I rowsort
SELECT - col2 * + cor0.col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + cor0.col0 AS col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - cor0.col0 * col0 + 24 AS col0 FROM tab1 AS cor0
----
-4072
-6376
15

skipif mysql # not compatible
query I rowsort
SELECT ALL + + col2 * - CAST ( col2 AS REAL ) AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL + col2 * + 79 AS col0 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT ALL + col0 * + col0 * 75 AS col1 FROM tab1 AS cor0
----
307200
480000
675

query I rowsort
SELECT - col0 + 53 FROM tab1 AS cor0
----
-11
-27
50

query I rowsort
SELECT ALL cor1.col1 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + ( - 1 ) + col1 AS col2 FROM tab0
----
85
90
96

query I rowsort
SELECT ALL col2 + - col2 * col2 - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT - col1 + - col2 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL + col1 + - col0 + + ( col2 * + col1 ) AS col1 FROM tab0 AS cor0
----
159
2900
7464

query I rowsort
SELECT ALL col0 + col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT - 17 FROM tab2, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT DISTINCT - cor0.col2 * 80 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
-2640
-6560
-80

query I rowsort
SELECT 67 * - 21 + col1 FROM tab2
----
-1348
-1376
-1390

query IIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0 CROSS JOIN tab2
----
243 values hashing to ce53c0e8839c969b0513568da6eb2c4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1062
SELECT DISTINCT col2 DIV - tab1.col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-1062
SELECT DISTINCT col2 / - tab1.col0 FROM tab1
----
-1
-18
0

query I rowsort
SELECT col0 + col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL 10 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT col1 * + col1 + + ( col1 + - col2 ) FROM tab2
----
268
3514
965

query I rowsort
SELECT ALL + 60 AS col0 FROM tab0
----
60
60
60

query I rowsort
SELECT - col0 + col0 * cor0.col1 FROM tab2 cor0
----
1264
210
4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-1068
SELECT col2 + + col2 DIV + col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-1068
SELECT col2 + + col2 / + col2 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1069
SELECT DISTINCT col1 DIV + col2 + + cor0.col1 + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1069
SELECT DISTINCT col1 / + col2 + + cor0.col1 + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1070
SELECT ALL + ( + col2 ) + - 40 DIV ( col1 ) FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1070
SELECT ALL + ( + col2 ) + - 40 / ( col1 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + 94 * cor0.col0 + col2 AS col2 FROM tab2 cor0
----
685
7358
7464

query I rowsort
SELECT DISTINCT - - col1 + col2 * ( col1 ) FROM tab0 cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1073
SELECT DISTINCT col2 * + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1073
SELECT DISTINCT col2 * + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col2 * col0 + col2 AS col0 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT + col1 * 74 + + tab1.col2 FROM tab1
----
1058
1978
797

query I rowsort
SELECT - 94 FROM tab1, tab0 AS cor0
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

query I rowsort
SELECT - col0 + col2 * + col2 AS col1 FROM tab2
----
1365
598
722

query I rowsort
SELECT + cor0.col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col0 * ( - 9 ) AS col0 FROM tab1
----
-27
-576
-720

query I rowsort
SELECT ALL - col0 + - col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL - cor0.col2 * + col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col1 * ( col2 ) AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL tab0.col0 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT tab2.col2 + + 16 AS col1 FROM tab2
----
42
43
54

query I rowsort
SELECT tab1.col2 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + 58 + + ( + col0 ) * ( + col1 ) AS col0 FROM tab1 AS cor0
----
1098
136
698

query I rowsort
SELECT DISTINCT + + col0 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 14 + + col1 * col1 * col0 + + ( col2 * col0 + cor0.col1 ) col0 FROM tab1 cor0
----
10072
21227
2230

query I rowsort
SELECT ALL col0 + 17 + + col2 AS col0 FROM tab1 AS cor0
----
138
193
74

query I rowsort
SELECT - ( col0 ) + col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - - col1 AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + col0 + col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL - col1 * col2 - + col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL - - col0 * + 31 AS col0 FROM tab0 cor0
----
1085
2759
744

query I rowsort
SELECT + ( col2 ) - + col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + + col1 + 19 AS col2 FROM tab2 AS cor0
----
36
50
78

query I rowsort
SELECT DISTINCT - - col1 + - 50 * col1 * + col2 FROM tab2 AS cor0
----
-32283
-41819
-76641

query I rowsort
SELECT DISTINCT + col2 + + cor0.col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + cor0.col1 AS col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - ( ( cor0.col1 ) ) * + col1 - - 66 AS col2 FROM tab2 AS cor0
----
-223
-3415
-895

query I rowsort
SELECT col1 * cor0.col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - + ( + col2 ) AS col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 * + 81 col0 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT ALL - col0 AS col1 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT 27 + - 16 FROM tab0 AS cor0
----
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-1107
SELECT DISTINCT - col0 DIV 60 - - col2 AS col0 FROM tab2 AS cor0
----
25
27
37

skipif mysql # not compatible
query I rowsort label-1107
SELECT DISTINCT - col0 / 60 - - col2 AS col0 FROM tab2 AS cor0
----
25
27
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - ( + col2 ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab2 AS cor0, tab2 AS cor1
----
972 values hashing to 617c9545df26d6d983e3967864e8e9e4

query I rowsort
SELECT + + col0 * col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - - col2 + col0 AS col1 FROM tab0 cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - 70 + + ( col2 ) AS col0 FROM tab1 cor0
----
-13
-16
26

query I rowsort
SELECT ALL - col1 * col2 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1116
SELECT + CAST( - 4 AS SIGNED ) FROM tab1 AS cor0
----
-4
-4
-4

skipif mysql # not compatible
query I rowsort label-1116
SELECT + CAST ( - 4 AS INTEGER ) FROM tab1 AS cor0
----
-4
-4
-4

query I rowsort
SELECT + ( col2 ) + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col2 + + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - + cor0.col1 + + col0 * + ( col2 ) FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + 83 * col0 + col1 FROM tab2 AS cor0
----
612
6533
6574

onlyif mysql # use DIV operator for integer division
query I rowsort label-1121
SELECT 71 * cor0.col0 DIV ( - col0 ) AS col1 FROM tab2 AS cor0
----
-71
-71
-71

skipif mysql # not compatible
query I rowsort label-1121
SELECT 71 * cor0.col0 / ( - col0 ) AS col1 FROM tab2 AS cor0
----
-71
-71
-71

query I rowsort
SELECT DISTINCT col0 + - tab0.col1 * tab0.col2 FROM tab0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1124
SELECT + CAST( col2 * + col0 AS SIGNED ) AS col2 FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-1124
SELECT + CAST ( col2 * + col0 AS INTEGER ) AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT - tab0.col2 FROM tab0, tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + 32 FROM tab1 AS cor0
----
32
32
32

query I rowsort
SELECT 17 + col0 + col1 FROM tab0
----
127
149
197

query I rowsort
SELECT - ( - col1 ) * tab2.col1 AS col1 FROM tab2
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + ( 60 ) col1 FROM tab0 AS cor0
----
142
61
93

query I rowsort
SELECT ALL - - cor0.col1 + col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + col0 + 88 AS col1 FROM tab0 AS cor0
----
112
123
177

query I rowsort
SELECT DISTINCT + - cor0.col2 + col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + col1 * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col0 * - ( - 8 * col1 ) AS col0 FROM tab0 cor0
----
-16512
-27160
-64792

query I rowsort
SELECT ALL - col1 + col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1137
SELECT + col1 * 48 DIV - ( cor0.col0 + + 59 ) AS col0 FROM tab1 AS cor0
----
-20
-3
-4

skipif mysql # not compatible
query I rowsort label-1137
SELECT + col1 * 48 / - ( cor0.col0 + + 59 ) AS col0 FROM tab1 AS cor0
----
-20
-3
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1138
SELECT ALL - col2 * - col2 + + col1 DIV cor0.col2 AS col0 FROM tab0 AS cor0
----
1091
6725
98

skipif mysql # not compatible
query I rowsort label-1138
SELECT ALL - col2 * - col2 + + col1 / cor0.col2 AS col0 FROM tab0 AS cor0
----
1091
6725
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col2 + + 62 col1 FROM tab1 AS cor0
----
1310
1466
632

onlyif mysql # use DIV operator for integer division
query I rowsort label-1141
SELECT DISTINCT col0 + col1 DIV col1 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-1141
SELECT DISTINCT col0 + col1 / col1 FROM tab0 cor0
----
25
36
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1142
SELECT cor0.col1 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1142
SELECT cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1143
SELECT ALL col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1143
SELECT ALL col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + + cor0.col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + cor0.col1 + + col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - - 88 FROM tab1, tab2, tab1 AS cor0
----
88

query I rowsort
SELECT DISTINCT tab0.col1 * tab0.col0 + - 78 FROM tab0
----
1986
3317
8021

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1148
SELECT ALL + ( + col1 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1148
SELECT ALL + ( + col1 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1149
SELECT - + col2 DIV col2 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1149
SELECT - + col2 / col2 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - - col1 * cor0.col0 + + 90 AS col1 FROM tab1 AS cor0
----
1130
168
730

query I rowsort
SELECT col2 * col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - + cor0.col2 + 72 AS col1 FROM tab0 AS cor0
----
-10
39
71

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 9364ef7545b07c67767dceb70f02c643

query I rowsort
SELECT tab2.col1 + + col2 FROM tab2
----
55
58
85

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to fb1fb273a543ea33958edfcaa2e7ed26

query I rowsort
SELECT ALL col1 * - ( - col1 ) AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + col0 + - col2 * + col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 4fa4bd3038de6e74a345debc8ab4cd53

query I rowsort
SELECT ALL + col1 * + 14 AS col1 FROM tab1
----
140
182
364

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab1, tab1 AS cor1
----
243 values hashing to 89e3b35a4a4f02d7b83645addb9dcdc3

query I rowsort
SELECT ALL - + col0 + col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1163
SELECT DISTINCT + - col1 * + CAST( NULL AS SIGNED ) - col1 * - col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1163
SELECT DISTINCT + - col1 * + CAST ( NULL AS INTEGER ) - col1 * - col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1164
SELECT ALL col2 DIV + ( - col0 ) FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-1164
SELECT ALL col2 / + ( - col0 ) FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT - - col1 * - 86 AS col1 FROM tab0 AS cor0
----
-7396
-7826
-8342

onlyif mysql # use DIV operator for integer division
query I rowsort label-1166
SELECT DISTINCT - col0 DIV - col0 - 38 FROM tab2 AS cor0
----
-37

skipif mysql # not compatible
query I rowsort label-1166
SELECT DISTINCT - col0 / - col0 - 38 FROM tab2 AS cor0
----
-37

query I rowsort
SELECT 36 AS col0 FROM tab2
----
36
36
36

query I rowsort
SELECT ALL 70 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT + col2 - + col0 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL col2 + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + col0 * - col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT ( - col1 ) * col2 FROM tab2
----
-1534
-646
-837

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0 CROSS JOIN tab2, tab1 cor1
----
972 values hashing to 980274175fafec015a83080672486a9a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 28 col2 FROM tab0
----
28
28
28

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab0 AS cor2
----
13122 values hashing to 01b247553a8eda280d50abc8047c3598

onlyif mysql # use DIV operator for integer division
query I rowsort label-1176
SELECT - + 28 + - col2 DIV col1 AS col0 FROM tab2 AS cor0
----
-28
-28
-30

skipif mysql # not compatible
query I rowsort label-1176
SELECT - + 28 + - col2 / col1 AS col0 FROM tab2 AS cor0
----
-28
-28
-30

query I rowsort
SELECT ( col0 ) AS col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT 22 * col0 + col1 FROM tab2 AS cor0
----
1755
1775
185

query I rowsort
SELECT - - 74 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1776
2590
6586

query I rowsort
SELECT - 21 * col1 AS col0 FROM tab2 AS cor0
----
-1239
-357
-651

query I rowsort
SELECT 18 * col1 AS col1 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT DISTINCT - 91 + + col1 * ( ( + cor0.col1 ) ) FROM tab2 AS cor0
----
198
3390
870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) + col2 col0 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-1184
SELECT ALL + col0 + - col2 DIV + 6 FROM tab2 AS cor0
----
3
73
74

skipif mysql # not compatible
query I rowsort label-1184
SELECT ALL + col0 + - col2 / + 6 FROM tab2 AS cor0
----
3
73
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-1185
SELECT - 21 DIV col1 + + cor0.col0 + + ( col2 ) * - 0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1185
SELECT - 21 / col1 + + cor0.col0 + + ( col2 ) * - 0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - col0 + + col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - col0 * - cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col2 * col1 AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL cor0.col2 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - + 96 FROM tab0 AS cor0
----
-96
-96
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1191
SELECT ALL 12 DIV col2 + + 75 col2 FROM tab1 AS cor0
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1191
SELECT ALL 12 / col2 + + 75 col2 FROM tab1 AS cor0
----
75
75
75

query I rowsort
SELECT + col0 * col0 * + col0 FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT ALL 95 + + cor0.col1 + - cor0.col2 FROM tab2 AS cor0
----
128
74
99

query I rowsort
SELECT DISTINCT 23 * + col2 AS col0 FROM tab1 AS cor0
----
1242
1311
2208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * col1 + - 70 col2 FROM tab2 cor0
----
-1413
-287
-4672

query I rowsort
SELECT col0 + col0 * + 13 FROM tab2 AS cor0
----
1092
1106
98

query I rowsort
SELECT DISTINCT + 56 + cor0.col2 AS col2 FROM tab1 AS cor0
----
110
113
152

query I rowsort
SELECT - col0 * + col1 + ( col2 ) + + col2 * + 64 FROM tab1 AS cor0
----
3065
3432
5200

query I rowsort
SELECT DISTINCT - - col0 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + - col1 + + cor0.col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col1 * col1 * 74 AS col2 FROM tab2 AS cor0
----
-21386
-257594
-71114

query I rowsort
SELECT DISTINCT col2 * col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col0 + + ( cor0.col1 ) FROM tab1 AS cor0
----
-54
-67
23

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 cor1, tab0 AS cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT DISTINCT - col0 * - 10 AS col0 FROM tab2 AS cor0
----
70
780
790

onlyif mysql # use DIV operator for integer division
query I rowsort label-1206
SELECT DISTINCT - col1 DIV + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1206
SELECT DISTINCT - col1 / + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT + - col2 * + 97 FROM tab2 AS cor0
----
-2522
-2619
-3686

query I rowsort
SELECT 76 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT + col1 - + col0 AS col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT + tab0.col0 - - 39 * + 24 FROM tab0, tab1 AS cor0
----
9 values hashing to b19dead8d7b3b3b16b5426761cafc6fd

query I rowsort
SELECT 49 FROM tab1, tab1 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1212
SELECT DISTINCT CAST( NULL AS SIGNED ) + + ( + col2 ) * - CAST( + col2 + - col2 AS DECIMAL ) col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1212
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + ( + col2 ) * - CAST ( + col2 + - col2 AS REAL ) col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col2 + - col2 * col1 AS col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT - ( + 65 ) FROM tab0 AS cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT 48 FROM tab0, tab2 AS cor0
----
48

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + col0 + - col2 FROM tab1 AS cor0
----
-42
4103
6384

query I rowsort
SELECT + - 15 + - 62 AS col1 FROM tab0 AS cor0
----
-77
-77
-77

query I rowsort
SELECT + 31 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 5e27196f2932b25a5297ddec46b8b8f1

query I rowsort
SELECT DISTINCT + ( - col2 ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - 33 * - cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d3834505d5e42cb1b3ed13f8b694cb07

query I rowsort
SELECT - col2 * col1 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ( 21 ) + - col0 FROM tab1
----
-43
-59
18

query I rowsort
SELECT ALL - col0 + col1 * ( col1 ) AS col1 FROM tab0 AS cor0
----
7372
8192
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * tab1.col2 col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT 76 AS col1 FROM tab1, tab0 AS cor0
----
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - tab2.col2 + + col0 + col2 col1 FROM tab2
----
-155
-1924
-2885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col0 + - col2 * 50 * col1 col1 FROM tab2 AS cor0
----
-32238
-41874
-76681

query I rowsort
SELECT ( - ( col0 ) ) * - ( col2 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL tab1.col1 + ( - col0 + col2 ) AS col1 FROM tab1
----
29
3
77

query I rowsort
SELECT DISTINCT col2 + + col0 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT 60 + tab2.col2 + + col1 FROM tab2
----
115
118
145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + col0 col2 FROM tab0
----
2
62
62

query I rowsort
SELECT - - col0 * + cor0.col0 + col2 AS col1 FROM tab0 AS cor0
----
1226
609
8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col2 col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - col1 * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-1238
SELECT DISTINCT + col1 DIV 38 + + 60 FROM tab0 AS cor0
----
62

skipif mysql # not compatible
query I rowsort label-1238
SELECT DISTINCT + col1 / 38 + + 60 FROM tab0 AS cor0
----
62

query I rowsort
SELECT - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT - - col1 + ( 90 ) AS col0 FROM tab2 AS cor0
----
107
121
149

query I rowsort
SELECT - col0 * - col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL ( 25 ) AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1243
SELECT col1 * 73 + - 95 DIV + tab1.col0 + + col0 * - col2 FROM tab1
----
-2919
-6732
1705

skipif mysql # not compatible
query I rowsort label-1243
SELECT col1 * 73 + - 95 / + tab1.col0 + + col0 * - col2 FROM tab1
----
-2919
-6732
1705

query I rowsort
SELECT DISTINCT + col2 + 21 AS col2 FROM tab2
----
47
48
59

query I rowsort
SELECT - col1 * col1 + + col0 * + tab0.col2 AS col2 FROM tab0
----
-6604
-9374
-983

onlyif mysql # use DIV operator for integer division
query I rowsort label-1246
SELECT col0 DIV 89 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1246
SELECT col0 / 89 FROM tab0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1247
SELECT DISTINCT - col1 + 68 + - col1 * col0 DIV - col0 AS col2 FROM tab1
----
68

skipif mysql # not compatible
query I rowsort label-1247
SELECT DISTINCT - col1 + 68 + - col1 * col0 / - col0 AS col2 FROM tab1
----
68

query I rowsort
SELECT 90 FROM tab0, tab0 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT - + col0 * col0 + col2 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - 38 col0 FROM tab0
----
48
53
59

query I rowsort
SELECT - col1 + col0 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT ( 72 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + 94 + 19 + + col1 col1 FROM tab0
----
2361
3406
8476

query I rowsort
SELECT ALL + 72 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT DISTINCT col0 * 11 + + 64 AS col0 FROM tab0
----
1043
328
449

query I rowsort
SELECT ALL - col2 + ( - 54 * tab1.col1 ) + + 52 AS col2 FROM tab1
----
-1406
-545
-746

query I rowsort
SELECT DISTINCT col0 * col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col2 * col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT col2 * - 42 * - tab2.col1 + - col2 AS col2 FROM tab2
----
27094
35127
64402

query I rowsort
SELECT ALL 92 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL col0 + - col2 + col1 FROM tab1
----
-25
-3
17

query I rowsort
SELECT col0 * - 7 * tab1.col2 FROM tab1
----
-1134
-25536
-53760

query I rowsort
SELECT ALL + 97 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT ALL tab2.col2 + - 74 FROM tab2
----
-36
-47
-48

query I rowsort
SELECT ALL - 42 + col2 AS col0 FROM tab2 AS cor0
----
-15
-16
-4

query I rowsort
SELECT + ( + col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + 86 * + col0 AS col1 FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT DISTINCT col0 * - col1 + col1 * col0 - + col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + 57 * + col2 - col0 FROM tab1 AS cor0
----
3075
3185
5392

query I rowsort
SELECT ALL + - 71 FROM tab2 AS cor0
----
-71
-71
-71

query I rowsort
SELECT DISTINCT + col1 * + col1 + ( col1 ) AS col2 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT - 66 FROM tab0
----
-66

query I rowsort
SELECT ALL - ( 1 * col2 ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1275
SELECT + col0 * col2 + - 59 DIV + col0 AS col1 FROM tab0
----
34
7298
790

skipif mysql # not compatible
query I rowsort label-1275
SELECT + col0 * col2 + - 59 / + col0 AS col1 FROM tab0
----
34
7298
790

query I rowsort
SELECT ALL - + col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT cor0.col1 + - col0 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + col0 + col2 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT 86 FROM tab2 AS cor0
----
86
86
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1280
SELECT ALL + cor0.col0 + - col1 + + CAST( + col0 + col0 AS SIGNED ) * col1 FROM tab2 AS cor0
----
2748
410
9223

skipif mysql # not compatible
query I rowsort label-1280
SELECT ALL + cor0.col0 + - col1 + + CAST ( + col0 + col0 AS INTEGER ) * col1 FROM tab2 AS cor0
----
2748
410
9223

query I rowsort
SELECT DISTINCT - col2 * col2 + col2 AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT + ( - col2 ) FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1283
SELECT ALL - + 76 + + cor0.col0 DIV + ( col1 + + col1 ) FROM tab0 cor0
----
-76
-76
-76

skipif mysql # not compatible
query I rowsort label-1283
SELECT ALL - + 76 + + cor0.col0 / + ( col1 + + col1 ) FROM tab0 cor0
----
-76
-76
-76

query I rowsort
SELECT DISTINCT col0 - col2 * - 8 * + col0 FROM tab2 AS cor0
----
1519
16302
24095

query I rowsort
SELECT - 17 FROM tab2 AS cor0
----
-17
-17
-17

onlyif mysql # use DIV operator for integer division
query I rowsort label-1286
SELECT ALL - - col0 + col0 DIV - col2 col2 FROM tab0 AS cor0
----
0
24
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1286
SELECT ALL - - col0 + col0 / - col2 col2 FROM tab0 AS cor0
----
0
24
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col2 + - ( 70 ) col0 FROM tab0 AS cor0
----
-4
-68
94

query I rowsort
SELECT ALL + + 49 FROM tab2 AS cor0
----
49
49
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col2 * - cor0.col0 col1 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - col0 + + col0 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + 87 * col2 * col1 + - col1 FROM tab1
----
108563
122122
49580

query I rowsort
SELECT 96 AS col2 FROM tab0
----
96
96
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 0 col2 FROM tab0
----
0

query I rowsort
SELECT ALL + col2 * col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1295
SELECT ALL 86 DIV col1 AS col1 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-1295
SELECT ALL 86 / col1 AS col1 FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT + 72 * + col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT ALL + col1 * col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT 68 * col0 AS col1 FROM tab0
----
1632
2380
6052

query I rowsort
SELECT ALL cor0.col2 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL col0 * col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col0 * col2 * col0 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-1302
SELECT ALL - col2 + + col1 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-1302
SELECT ALL - col2 + + col1 / cor0.col0 AS col2 FROM tab2 AS cor0
----
-23
-26
-38

query I rowsort
SELECT ALL + col0 + - ( ( + cor0.col1 ) ) AS col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + - cor0.col2 * col1 + 7 AS col0 FROM tab1 AS cor0
----
-1241
-1397
-563

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + cor0.col2 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + col2 + - ( + cor0.col0 ) * - cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT col2 * + ( - 11 ) FROM tab1 AS cor0
----
-1056
-594
-627

query I rowsort
SELECT col2 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + ( col0 ) + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + col0 * + col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - ( col0 ) * + col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - - 92 AS col2 FROM tab1 cor0
----
92

query I rowsort
SELECT - col0 * cor0.col1 + cor0.col1 + col0 FROM tab0 cor0
----
-1954
-3263
-7919

query I rowsort
SELECT - 67 * col1 + + col0 FROM tab1
----
-1739
-606
-791

query I rowsort
SELECT DISTINCT cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - + cor0.col0 * - col1 * col1 AS col1 FROM tab1 AS cor0
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 37 + + col0 col2 FROM tab1 AS cor0
----
-34
27
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 26 * - ( col0 ) + + ( - col2 ) col2 FROM tab1 AS cor0
----
-132
-1721
-2176

query I rowsort
SELECT + cor0.col2 + col1 + + col0 * col2 FROM tab0 cor0
----
133
7471
911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 9 col0 FROM tab1 cor0
----
9

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + - 81 * - col0 FROM tab0 AS cor0
----
1944
2835
7209

onlyif mysql # use DIV operator for integer division
query I rowsort label-1325
SELECT + col2 DIV + cor0.col1 + + 56 * + col0 FROM tab1 AS cor0
----
170
3589
4487

skipif mysql # not compatible
query I rowsort label-1325
SELECT + col2 / + cor0.col1 + + 56 * + col0 FROM tab1 AS cor0
----
170
3589
4487

query I rowsort
SELECT + col0 + col0 * 78 FROM tab0 cor0
----
1896
2765
7031

query I rowsort
SELECT DISTINCT - col2 * col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-1328
SELECT - col0 + col2 DIV col1 + col0 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1328
SELECT - col0 + col2 / col1 + col0 AS col0 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT DISTINCT tab2.col0 + - col2 AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL + cor0.col2 AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1331
SELECT ALL CAST( + col0 AS SIGNED ) + + tab2.col0 AS col0 FROM tab2
----
14
156
158

skipif mysql # not compatible
query I rowsort label-1331
SELECT ALL CAST ( + col0 AS INTEGER ) + + tab2.col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT - cor0.col1 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + 67 + + ( + col0 ) AS col1 FROM tab0
----
102
156
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-1334
SELECT DISTINCT + cor0.col2 * - col0 DIV col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-1334
SELECT DISTINCT + cor0.col2 * - col0 / col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 * col0 + 24 * + cor0.col1 col0 FROM tab0 AS cor0
----
15888
45203
707153

onlyif mysql # use DIV operator for integer division
query I rowsort label-1336
SELECT - ( col2 ) DIV - col1 AS col2 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1336
SELECT - ( col2 ) / - col1 AS col2 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1337
SELECT ALL - CAST( NULL AS SIGNED ) * + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1337
SELECT ALL - CAST ( NULL AS INTEGER ) * + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + 58 AS col1 FROM tab1 AS cor0
----
68
71
84

query I rowsort
SELECT - col2 * - ( + col1 + - col0 ) AS col1 FROM tab0 AS cor0
----
164
2046
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1340
SELECT - - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1340
SELECT - - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + tab2.col2 * col0 AS col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + - 79 FROM tab2 AS cor0
----
-79

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab1, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + 80 AS col0 FROM tab1
----
80
80
80

query I rowsort
SELECT ALL 32 * cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 50979d93e65eb2e0eb8da5d863ba5138

query I rowsort
SELECT DISTINCT ( ( - col1 ) + 38 ) * - tab1.col0 FROM tab1
----
-1792
-2000
-36

query I rowsort
SELECT - col2 * 80 FROM tab2 AS cor0
----
-2080
-2160
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1349
SELECT - CAST( col2 AS SIGNED ) + col0 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-1349
SELECT - CAST ( col2 AS INTEGER ) + col0 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1350
SELECT CAST( col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1350
SELECT CAST ( col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 39 AS col1 FROM tab2
----
39
39
39

query I rowsort
SELECT ALL + 15 * - 21 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 690dae633d09ce577e987ac51ce24b4d

query I rowsort
SELECT ALL 79 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT ALL + col2 + - col0 AS col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT - tab2.col1 + - col0 AS col2 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT DISTINCT 69 + - 60 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9

query I rowsort
SELECT ALL + col2 + - col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + - col1 + col2 AS col2 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1359
SELECT DISTINCT - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-1359
SELECT DISTINCT - CAST ( NULL AS REAL ) FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col0 + 5 col2 FROM tab2 AS cor0
----
-184
-2023
-2997

query I rowsort
SELECT - cor0.col1 * col0 + - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + col0 * + ( col2 * - tab2.col0 + - col1 ) FROM tab2
----
-1540
-162786
-238501

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1363
SELECT - col1 * CAST( 10 AS SIGNED ) AS col1 FROM tab2
----
-170
-310
-590

skipif mysql # not compatible
query I rowsort label-1363
SELECT - col1 * CAST ( 10 AS INTEGER ) AS col1 FROM tab2
----
-170
-310
-590

query I rowsort
SELECT + + col2 + + col0 AS col0 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 77 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
-77

query I rowsort
SELECT - col2 + col1 * col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL col1 * + 94 + 30 FROM tab0
----
8114
8584
9148

query I rowsort
SELECT + tab2.col0 * col1 + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT + cor0.col2 * + 17 * - col1 FROM tab2 cor0
----
-10982
-14229
-26078

query I rowsort
SELECT - col0 - col2 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT col1 * - ( + cor0.col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - col1 * col1 - col0 FROM tab2 AS cor0
----
-3559
-368
-968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 35 * col0 col1 FROM tab2 cor0
----
276
2782
2789

query I rowsort
SELECT - col2 * col2 + - cor0.col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT col1 * + 72 AS col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT DISTINCT + col1 * 57 * - cor0.col2 FROM tab1 AS cor0
----
-32490
-71136
-80028

query I rowsort
SELECT ( col1 ) * col1 + col1 AS col0 FROM tab2 cor0
----
306
3540
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1378
SELECT DISTINCT - CAST( + col2 AS SIGNED ) + col1 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-1378
SELECT DISTINCT - CAST ( + col2 AS INTEGER ) + col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + + ( - col0 ) AS col1 FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1380
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col0 + col1 col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1380
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col0 + col1 col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 94 FROM tab0, tab1 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col2 col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col1 AS col1 FROM tab2, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT 48 FROM tab1
----
48

query I rowsort
SELECT + col1 + 92 FROM tab1 AS cor0
----
102
105
118

query I rowsort
SELECT ALL - col1 * 48 AS col2 FROM tab0 cor0
----
-4128
-4368
-4656

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1387
SELECT + CAST( NULL AS SIGNED ) + col0 * + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1387
SELECT + CAST ( NULL AS INTEGER ) + col0 * + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 42 * col2 + - cor0.col2 * - ( col0 ) AS col1 FROM tab1 AS cor0
----
11712
2430
6042

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 - ( - col0 + cor0.col0 ) col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL 22 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT ALL - 57 * 52 - - cor0.col0 FROM tab1 AS cor0
----
-2884
-2900
-2961

query I rowsort
SELECT ALL col1 * 72 - col2 AS col2 FROM tab1 AS cor0
----
1818
663
840

query I rowsort
SELECT DISTINCT - col0 * col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + + 15 AS col1 FROM tab1 cor0
----
15
15
15

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab0 cor1, tab2 cor2
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT - 87 + col2 FROM tab0 AS cor0
----
-5
-54
-86

query I rowsort
SELECT - 21 + col0 * ( col2 ) * col0 FROM tab1 AS cor0
----
233451
465
614379

query I rowsort
SELECT ALL + 60 * - col0 AS col1 FROM tab1 cor0
----
-180
-3840
-4800

onlyif mysql # use DIV operator for integer division
query I rowsort label-1399
SELECT + cor0.col2 DIV - 2 FROM tab1 AS cor0
----
-27
-28
-48

skipif mysql # not compatible
query I rowsort label-1399
SELECT + cor0.col2 / - 2 FROM tab1 AS cor0
----
-27
-28
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-1400
SELECT ALL + col2 DIV col0 + col1 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-1400
SELECT ALL + col2 / col0 + col1 FROM tab0 AS cor0
----
87
91
97

query I rowsort
SELECT DISTINCT + cor0.col0 * - 9 - 43 FROM tab2 AS cor0
----
-106
-745
-754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col1 col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col1 * - 57 FROM tab0 cor0
----
4902
5187
5529

query I rowsort
SELECT DISTINCT + col2 + + 53 * + 46 FROM tab1 AS cor0
----
2492
2495
2534

query I rowsort
SELECT ALL - - col2 + - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-1406
SELECT + col1 + 18 DIV + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1406
SELECT + col1 + 18 / + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + col1 * ( + 20 ) * col2 FROM tab1 AS cor0
----
11400
24960
28080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 - 44 col1 FROM tab2 AS cor0
----
-13
-27
15

query I rowsort
SELECT - col1 * + col0 + col2 AS col1 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-1410
SELECT - tab1.col2 DIV + tab1.col2 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1410
SELECT - tab1.col2 / + tab1.col2 AS col2 FROM tab1
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1411
SELECT ALL - tab1.col2 + + col1 - CAST( NULL AS SIGNED ) col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1411
SELECT ALL - tab1.col2 + + col1 - CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 20 - col2 FROM tab1
----
-116
-74
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1413
SELECT DISTINCT tab0.col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1, tab2 AS cor0, tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-1413
SELECT DISTINCT tab0.col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1, tab2 AS cor0, tab0
----
NULL

query I rowsort
SELECT DISTINCT + tab1.col1 * col1 AS col1 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1415
SELECT + col2 DIV + col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1415
SELECT + col2 / + col0 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT + 11 AS col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
11

query I rowsort
SELECT DISTINCT - 67 + col2 FROM tab2 AS cor0
----
-29
-40
-41

query I rowsort
SELECT ALL - cor0.col1 + col1 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1419
SELECT DISTINCT + 70 DIV col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1419
SELECT DISTINCT + 70 / col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - col1 * + col0 * ( col2 ) FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - 55 AS col2 FROM tab2 cor0
----
-55
-55
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-1423
SELECT DISTINCT - col1 DIV col0 - col1 * + ( - col2 ) FROM tab1 AS cor0
----
1248
1396
570

skipif mysql # not compatible
query I rowsort label-1423
SELECT DISTINCT - col1 / col0 - col1 * + ( - col2 ) FROM tab1 AS cor0
----
1248
1396
570

query I rowsort
SELECT col1 * cor0.col2 + + ( 30 ) FROM tab0 AS cor0
----
127
2868
7492

query I rowsort
SELECT ALL col2 * - col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT 63 AS col0 FROM tab0 AS cor0
----
63
63
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1427
SELECT DISTINCT + col0 * col0 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1427
SELECT DISTINCT + col0 * col0 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col0 - + col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - col2 * + col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col1 + - col0 * col2 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - col1 * + ( + ( + col0 ) ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col1 * - ( col2 ) AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0, tab0 cor2
----
3645 values hashing to 4037d65571c1bbf6e0e7d759f858120e

query I rowsort
SELECT - + col2 + 84 * col0 + + 97 AS col0 FROM tab1 AS cor0
----
295
5416
6721

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + + 55 * - ( + col1 ) + ( col0 * - col1 ) + 96 FROM tab0 AS cor0
----
-13008
-6698
-8634

query I rowsort
SELECT - 2 + col2 AS col0 FROM tab2 AS cor0
----
24
25
36

query I rowsort
SELECT DISTINCT + col2 * col1 + col2 + col1 AS col0 FROM tab1 AS cor0
----
1357
1484
637

query I rowsort
SELECT ALL - - 87 * + col1 AS col2 FROM tab1 AS cor0
----
1131
2262
870

query I rowsort
SELECT - ( - 71 ) FROM tab2
----
71
71
71

query I rowsort
SELECT ALL - ( - col2 ) * col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL + + 81 + - col0 FROM tab1 AS cor0
----
1
17
78

query I rowsort
SELECT DISTINCT - + ( - 15 ) + - col1 FROM tab1 AS cor0
----
-11
2
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1444
SELECT DISTINCT + col0 DIV + cor0.col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-1444
SELECT DISTINCT + col0 / + cor0.col0 FROM tab2 AS cor0
----
1

query I rowsort
SELECT + - ( 69 ) * cor0.col0 * col2 + cor0.col2 * col2 FROM tab2 AS cor0
----
-12312
-139256
-205694

query I rowsort
SELECT ALL + 82 * cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 1d2c15e844e1ec06584e2530ccb9d047

query I rowsort
SELECT DISTINCT + 43 FROM tab1 cor0
----
43

query I rowsort
SELECT DISTINCT col0 + - col1 * col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - col0 + + col2 + - col1 FROM tab2 AS cor0
----
-11
-111
-58

query I rowsort
SELECT DISTINCT + - 82 + + col0 * + col0 FROM tab2 cor0
----
-33
6002
6159

onlyif mysql # use DIV operator for integer division
query I rowsort label-1451
SELECT + col2 DIV - cor0.col2 + + col0 + col1 * col2 AS col2 FROM tab1 cor0
----
1327
1406
633

skipif mysql # not compatible
query I rowsort label-1451
SELECT + col2 / - cor0.col2 + + col0 + col1 * col2 AS col2 FROM tab1 cor0
----
1327
1406
633

query I rowsort
SELECT ALL 20 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT ALL 73 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT + 40 * + col1 * - col0 AS col2 FROM tab0
----
-135800
-323960
-82560

onlyif mysql # use DIV operator for integer division
query I rowsort label-1455
SELECT ALL + col2 DIV + tab1.col0 + col1 * - 43 AS col0 FROM tab1
----
-1100
-430
-558

skipif mysql # not compatible
query I rowsort label-1455
SELECT ALL + col2 / + tab1.col0 + col1 * - 43 AS col0 FROM tab1
----
-1100
-430
-558

query I rowsort
SELECT - tab0.col2 + 40 FROM tab0
----
-42
39
7

query I rowsort
SELECT - cor0.col2 * + col0 * col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT + - col0 + - col0 + 23 AS col0 FROM tab0 AS cor0
----
-155
-25
-47

query I rowsort
SELECT + col2 * col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT tab1.col0 * + col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT ( col2 + tab0.col1 ) * + col0 AS col0 FROM tab0
----
15397
2856
3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-1462
SELECT ALL - 79 + - col2 DIV tab1.col1 AS col2 FROM tab1
----
-81
-84
-86

skipif mysql # not compatible
query I rowsort label-1462
SELECT ALL - 79 + - col2 / tab1.col1 AS col2 FROM tab1
----
-81
-84
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-1463
SELECT ALL - col2 + + col2 DIV + col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-1463
SELECT ALL - col2 + + col2 / + col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT 95 FROM tab2, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT - - 8 + col2 AS col0 FROM tab0 AS cor0
----
41
9
90

query I rowsort
SELECT - 61 AS col0 FROM tab1 AS cor0
----
-61
-61
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1467
SELECT + 75 DIV - col0 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-1467
SELECT + 75 / - col0 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT - + col1 + col1 * + 93 FROM tab1 AS cor0
----
1196
2392
920

query I rowsort
SELECT - ( col1 ) + - tab0.col0 AS col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT + - col0 + col2 + col0 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + tab1.col2 + col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + tab1.col2 + + tab1.col2 FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT + col1 * + col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - col2 + + col1 * - col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT col0 + + col1 + - tab1.col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT col0 + 81 AS col0 FROM tab2
----
159
160
88

query I rowsort
SELECT DISTINCT col1 + + col2 FROM tab2
----
55
58
85

query I rowsort
SELECT - col0 + - col0 FROM tab0 AS cor0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-1479
SELECT + col2 DIV tab2.col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-1479
SELECT + col2 / tab2.col1 FROM tab2
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 + col2 col2 FROM tab2
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1481
SELECT + CAST( NULL AS SIGNED ) * - 39 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1481
SELECT + CAST ( NULL AS INTEGER ) * - 39 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1482
SELECT col2 DIV 48 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1482
SELECT col2 / 48 FROM tab0
----
0
0
1

query I rowsort
SELECT DISTINCT tab1.col2 AS col1 FROM tab1, tab0 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1484
SELECT DISTINCT col2 DIV + col0 + + tab2.col0 FROM tab2
----
10
78
79

skipif mysql # not compatible
query I rowsort label-1484
SELECT DISTINCT col2 / + col0 + + tab2.col0 FROM tab2
----
10
78
79

query I rowsort
SELECT DISTINCT col1 + - col0 * - 94 FROM tab0
----
2342
3387
8457

query I rowsort
SELECT ALL + col2 + tab0.col2 FROM tab0
----
164
2
66

query I rowsort
SELECT + col1 - - ( col2 ) AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + ( - 62 ) FROM tab0 AS cor0
----
-62
-62
-62

query I rowsort
SELECT DISTINCT + 42 * 72 + + col2 AS col0 FROM tab0 AS cor0
----
3025
3057
3106

query I rowsort
SELECT - 9 + - col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1257
-1413
-579

query I rowsort
SELECT DISTINCT - ( col0 ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1492
SELECT - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1492
SELECT - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( col2 ) + + col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + - ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + - 0 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1496
SELECT CAST( + 38 AS SIGNED ) + - col0 FROM tab1 AS cor0
----
-26
-42
35

skipif mysql # not compatible
query I rowsort label-1496
SELECT CAST ( + 38 AS INTEGER ) + - col0 FROM tab1 AS cor0
----
-26
-42
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1497
SELECT - CAST( + col2 AS SIGNED ) * col0 col1 FROM tab1 cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1497
SELECT - CAST ( + col2 AS INTEGER ) * col0 col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + 97 + 44 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
108
140
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1499
SELECT - + 81 * cor0.col0 - - col2 DIV CAST( + 59 + + col2 AS SIGNED ) AS col1 FROM tab1 cor0
----
-243
-5184
-6480

skipif mysql # not compatible
query I rowsort label-1499
SELECT - + 81 * cor0.col0 - - col2 / CAST ( + 59 + + col2 AS INTEGER ) AS col1 FROM tab1 cor0
----
-243
-5184
-6480

query I rowsort
SELECT + - col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + - col1 + - col1 FROM tab2 cor0
----
-118
-34
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

onlyif mysql # use DIV operator for integer division
query I rowsort label-1503
SELECT - col0 DIV + ( 66 ) + col2 * col1 - + 44 col2 FROM tab0
----
2794
53
7417

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1503
SELECT - col0 / + ( 66 ) + col2 * col1 - + 44 col2 FROM tab0
----
2794
53
7417

query I rowsort
SELECT DISTINCT + col1 * - tab2.col0 + + 13 * col2 FROM tab2
----
-4264
-849
134

query I rowsort
SELECT col1 * + col2 + - col2 FROM tab2
----
1508
608
810

query I rowsort
SELECT ALL + col1 + col2 + col0 * - tab2.col0 AS col0 FROM tab2
----
-5999
-6186
9

query I rowsort
SELECT ALL 18 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1508
SELECT DISTINCT + col1 * + CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1508
SELECT DISTINCT + col1 * + CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1509
SELECT + cor0.col2 * - CAST( col0 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-1509
SELECT + cor0.col2 * - CAST ( col0 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - 99 * - col1 FROM tab0 AS cor0
----
8514
9009
9603

query I rowsort
SELECT DISTINCT + - col0 * - col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 3 * col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ALL + + 70 FROM tab0 AS cor0
----
70
70
70

query I rowsort
SELECT 66 * 31 FROM tab2 AS cor0
----
2046
2046
2046

query I rowsort
SELECT DISTINCT 35 + col2 + col0 AS col0 FROM tab2 AS cor0
----
139
152
69

query I rowsort
SELECT ALL - cor0.col0 * col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 89 col0 FROM tab2 cor0
----
89
89
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1518
SELECT ( cor0.col1 ) + + col2 + col1 DIV 3 FROM tab0 AS cor0
----
130
147
203

skipif mysql # not compatible
query I rowsort label-1518
SELECT ( cor0.col1 ) + + col2 + col1 / 3 FROM tab0 AS cor0
----
130
147
203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - col2 + + ( - tab2.col0 * col2 ) AS col1 FROM tab2
----
-2054
-216
-3040

query I rowsort
SELECT + col0 + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT ( + 6 ) + col0 * 23 FROM tab0 cor0
----
2053
558
811

query I rowsort
SELECT 69 + cor0.col2 FROM tab1 cor0
----
123
126
165

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1524
SELECT + col2 * CAST( 33 AS SIGNED ) * - tab2.col1 AS col2 FROM tab2
----
-21318
-27621
-50622

skipif mysql # not compatible
query I rowsort label-1524
SELECT + col2 * CAST ( 33 AS INTEGER ) * - tab2.col1 AS col2 FROM tab2
----
-21318
-27621
-50622

onlyif mysql # use DIV operator for integer division
query I rowsort label-1525
SELECT cor0.col2 * col0 DIV 32 + - 75 AS col1 FROM tab2 AS cor0
----
-12
-70
18

skipif mysql # not compatible
query I rowsort label-1525
SELECT cor0.col2 * col0 / 32 + - 75 AS col1 FROM tab2 AS cor0
----
-12
-70
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-1526
SELECT - - ( cor0.col0 ) DIV 83 - - col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1526
SELECT - - ( cor0.col0 ) / 83 - - col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col2 * + col1 + + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT - 3 FROM tab1, tab1 AS cor0
----
-3

query I rowsort
SELECT ALL 16 FROM tab0, tab2 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT DISTINCT + 58 AS col0 FROM tab0
----
58

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1532
SELECT ALL + - col0 DIV col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1532
SELECT ALL + - col0 / col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + col0 * col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1535
SELECT - 57 DIV - col1 col2 FROM tab1 AS cor0
----
2
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1535
SELECT - 57 / - col1 col2 FROM tab1 AS cor0
----
2
4
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1536
SELECT - col2 DIV + tab2.col0 AS col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-1536
SELECT - col2 / + tab2.col0 AS col0 FROM tab2
----
-3
0
0

query I rowsort
SELECT ALL + - col2 + + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1538
SELECT col2 * - CAST( NULL AS SIGNED ) - + 27 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1538
SELECT col2 * - CAST ( NULL AS INTEGER ) - + 27 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + + ( 7 ) FROM tab0 cor0
----
-79
-84
-90

query I rowsort
SELECT ALL tab0.col0 + - 49 FROM tab0, tab1 cor0
----
9 values hashing to 229706910d0097730503c43c351d76e3

query I rowsort
SELECT col0 - - col2 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1543
SELECT + cor0.col1 - + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1543
SELECT + cor0.col1 - + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + - cor0.col1 + col2 col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + - col2 * - ( + col1 ) - - col1 AS col1 FROM tab1 cor0
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1546
SELECT + + col2 + CAST( col1 AS SIGNED ) AS col2 FROM tab0 cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-1546
SELECT + + col2 + CAST ( col1 AS INTEGER ) AS col2 FROM tab0 cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1547
SELECT DISTINCT + col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1547
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col1 + ( + col0 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + + cor0.col0 - - col0 AS col2 FROM tab1 cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-1550
SELECT ALL col1 * + col0 + cor0.col0 DIV + col1 + ( col0 ) FROM tab2 AS cor0
----
1426
224
4681

skipif mysql # not compatible
query I rowsort label-1550
SELECT ALL col1 * + col0 + cor0.col0 / + col1 + ( col0 ) FROM tab2 AS cor0
----
1426
224
4681

query I rowsort
SELECT ALL col0 * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - cor0.col2 * col2 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-1553
SELECT ALL - col0 DIV - 10 + - col2 FROM tab1 AS cor0
----
-51
-54
-88

skipif mysql # not compatible
query I rowsort label-1553
SELECT ALL - col0 / - 10 + - col2 FROM tab1 AS cor0
----
-51
-54
-88

query I rowsort
SELECT DISTINCT - - col1 * - cor0.col1 + col1 AS col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT - - col0 * - col2 + + ( + cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - col1 - col2 AS col0 FROM tab1 cor0
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1557
SELECT ALL - col1 * CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-1557
SELECT ALL - col1 * CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - col0 * - 85 + - col0 FROM tab0 AS cor0
----
2016
2940
7476

query I rowsort
SELECT ALL - ( tab1.col2 ) FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1560
SELECT ALL 0 DIV + col0 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1560
SELECT ALL 0 / + col0 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col1 + ( - col2 ) * col1 AS col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT cor0.col0 + col1 + 36 * - col1 AS col0 FROM tab0 AS cor0
----
-2986
-3096
-3360

onlyif mysql # use DIV operator for integer division
query I rowsort label-1563
SELECT DISTINCT - col2 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-1563
SELECT DISTINCT - col2 / cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT ALL col0 * + 54 + col0 AS col1 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT ALL + col0 + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - col0 + col1 col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL - col0 * ( col1 ) + col2 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1570
SELECT - col0 + + CAST( NULL AS SIGNED ) + + col2 * col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1570
SELECT - col0 + + CAST ( NULL AS INTEGER ) + + col2 * col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 68 AS col2 FROM tab0
----
-68
-68
-68

query I rowsort
SELECT ALL tab0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT 46 AS col1 FROM tab0 AS cor0
----
46
46
46

query I rowsort
SELECT ( - 62 ) * + cor0.col0 FROM tab0 AS cor0
----
-1488
-2170
-5518

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1575
SELECT tab1.col0 * col0 + CAST( NULL AS SIGNED ) * col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1575
SELECT tab1.col0 * col0 + CAST ( NULL AS INTEGER ) * col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 6 AS col0 FROM tab0
----
6
6
6

query I rowsort
SELECT DISTINCT + 68 FROM tab0
----
68

query I rowsort
SELECT - 97 + col0 * col2 FROM tab2 AS cor0
----
1931
2905
92

query I rowsort
SELECT DISTINCT - + 0 * - col0 + + ( + col1 + - col2 ) AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + + col1 * - col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL col0 * + col1 + col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + + 72 * col2 FROM tab1 AS cor0
----
3888
4104
6912

query I rowsort
SELECT ALL cor0.col1 * + col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - - col2 * col2 + col2 * ( col1 ) FROM tab0 AS cor0
----
14186
3927
98

query I rowsort
SELECT ALL - 6 AS col2 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT - col0 * + col0 * + col1 + cor0.col2 FROM tab2 AS cor0
----
-106059
-1492
-358930

query I rowsort
SELECT - col2 + ( - 0 ) AS col0 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1589
SELECT DISTINCT + col0 - - 61 DIV + cor0.col0 AS col0 FROM tab2 AS cor0
----
15
78
79

skipif mysql # not compatible
query I rowsort label-1589
SELECT DISTINCT + col0 - - 61 / + cor0.col0 AS col0 FROM tab2 AS cor0
----
15
78
79

query I rowsort
SELECT ALL + - 52 * - col0 - + col0 * + col1 AS col0 FROM tab2 AS cor0
----
-546
147
2765

query I rowsort
SELECT ALL 82 - - 21 AS col1 FROM tab0 AS cor0
----
103
103
103

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * cor0.col2 + - col0 col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT - ( - col1 ) AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT 84 FROM tab1
----
84
84
84

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT ALL - 1 * col1 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1598
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1598
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 88 + - 25 AS col2 FROM tab0 cor0
----
63
63
63

query I rowsort
SELECT DISTINCT - + col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT + cor0.col1 + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col1 + + col2 FROM tab2
----
55
58
85

query I rowsort
SELECT col0 * - col2 + + 74 AS col0 FROM tab0
----
-718
-7224
39

query I rowsort
SELECT DISTINCT - tab0.col1 * col0 + ( + col1 + - col0 * - tab0.col1 ) AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT + col1 * - col2 * + tab0.col1 + - col2 AS col1 FROM tab0
----
-244101
-679124
-9410

query I rowsort
SELECT + col1 * col1 - + 10 AS col1 FROM tab1 AS cor0
----
159
666
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 * - cor0.col0 * - 7 + 78 col2 FROM tab2 cor0
----
862
8814
8926

query I rowsort
SELECT DISTINCT + 93 AS col1 FROM tab2 AS cor0
----
93

query I rowsort
SELECT ALL cor0.col1 * col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + 50 + col2 AS col0 FROM tab2 AS cor0
----
76
77
88

query I rowsort
SELECT ALL - col2 + + 59 AS col1 FROM tab2 cor0
----
21
32
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-1613
SELECT col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1613
SELECT col1 / + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT cor0.col1 + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + cor0.col2 * col2 * col1 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT col1 * cor0.col2 + cor0.col1 FROM tab2 cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-1617
SELECT DISTINCT - - col2 - + ( col0 ) DIV + col2 AS col0 FROM tab0 cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-1617
SELECT DISTINCT - - col2 - + ( col0 ) / + col2 AS col0 FROM tab0 cor0
----
-34
33
81

query I rowsort
SELECT - - col0 * col1 + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL col2 + 96 * - col1 FROM tab2 AS cor0
----
-1594
-2949
-5638

query I rowsort
SELECT ALL + col0 * col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT ALL - col2 * - cor0.col2 + col2 * - col0 FROM tab1 AS cor0
----
-399
1536
2754

query I rowsort
SELECT + col2 + 75 AS col1 FROM tab2 AS cor0
----
101
102
113

query I rowsort
SELECT ALL - col2 * - col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1624
SELECT col1 + + col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1624
SELECT col1 + + col1 / + col1 AS col2 FROM tab0 AS cor0
----
87
92
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1625
SELECT + col0 + - col0 + CAST( tab1.col2 AS SIGNED ) DIV col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1625
SELECT + col0 + - col0 + CAST ( tab1.col2 AS INTEGER ) / col0 FROM tab1
----
0
1
18

query I rowsort
SELECT - + cor0.col1 * - col0 + + col2 * col1 AS col0 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT + col2 * + 67 * col2 AS col2 FROM tab2 AS cor0
----
45292
48843
96748

query I rowsort
SELECT ALL col2 + col0 * ( + col1 ) * - col2 FROM tab2
----
-119626
-50996
-5832

query I rowsort
SELECT - tab0.col0 * tab0.col0 AS col0 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT col2 * ( + 31 ) + col1 FROM tab2 AS cor0
----
1195
865
868

query I rowsort
SELECT - col1 * cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 40e4acd618698dd2305f1f7b8b547f7a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + col1 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL tab2.col0 * 10 FROM tab2
----
70
780
790

query I rowsort
SELECT col1 * + 44 FROM tab2
----
1364
2596
748

query I rowsort
SELECT + col2 * + ( col1 ) + + col1 + 57 FROM tab1 cor0
----
1318
1487
637

query I rowsort
SELECT ALL cor0.col1 * 68 * + col0 FROM tab2 cor0
----
14756
312936
91324

query I rowsort
SELECT DISTINCT - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - + col1 * col1 + ( + col0 ) * 63 FROM tab1 AS cor0
----
-487
3932
4871

query I rowsort
SELECT - - col0 + - col1 + col0 * - col2 FROM tab1 AS cor0
----
-185
-3594
-7613

query I rowsort
SELECT col1 * col1 + + 38 AS col2 FROM tab1 AS cor0
----
138
207
714

onlyif mysql # use DIV operator for integer division
query I rowsort label-1642
SELECT col2 DIV col1 + col1 + col2 DIV col1 FROM tab2 AS cor0
----
21
31
59

skipif mysql # not compatible
query I rowsort label-1642
SELECT col2 / col1 + col1 + col2 / col1 FROM tab2 AS cor0
----
21
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1643
SELECT - col1 DIV + col0 + + col0 DIV - col1 + + col2 * col0 FROM tab2 AS cor0
----
185
2027
2998

skipif mysql # not compatible
query I rowsort label-1643
SELECT - col1 / + col0 + + col0 / - col1 + + col2 * col0 FROM tab2 AS cor0
----
185
2027
2998

query I rowsort
SELECT + tab0.col2 * col2 + - col0 + col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - + 34 * 60 + + col1 FROM tab1 cor0
----
-2014
-2027
-2030

query I rowsort
SELECT + - col2 + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + ( 34 ) * col2 + col1 + + col0 * + cor0.col2 FROM tab2 AS cor0
----
1138
2971
4311

query I rowsort
SELECT + - 3 + 61 + cor0.col2 AS col2 FROM tab1 AS cor0
----
112
115
154

query I rowsort
SELECT ALL col2 * - col2 AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL col1 * 86 AS col0 FROM tab1
----
1118
2236
860

query I rowsort
SELECT - 65 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2773
32
7397

query I rowsort
SELECT - - ( col0 ) + - col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - + ( - col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + 68 * col1 FROM tab0 AS cor0
----
5848
6188
6596

query I rowsort
SELECT 64 FROM tab0
----
64
64
64

query I rowsort
SELECT - 88 FROM tab2
----
-88
-88
-88

query I rowsort
SELECT 13 FROM tab0, tab0 cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT + 6 AS col2 FROM tab2
----
6
6
6

query I rowsort
SELECT ALL 55 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + 36 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT 66 * + col1 AS col1 FROM tab1 cor0
----
1716
660
858

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col0 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col0 col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col0 * + col2 AS col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 * + col2 + cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
2973
3370
9392

query I rowsort
SELECT DISTINCT col2 * col2 AS col0 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT ALL - - cor0.col0 * + col2 * 14 FROM tab0 AS cor0
----
102172
11088
490

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1668
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1668
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * tab0.col0 * col1 - tab0.col2 AS col0 FROM tab0
----
118824
49503
720729

query I rowsort
SELECT 56 + ( tab1.col0 ) AS col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to ac72f953f09bdccd9cdbd68f8eac915f

query I rowsort
SELECT - - col0 * + col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT 90 + col0 + col0 FROM tab0
----
138
160
268

query I rowsort
SELECT + col1 * + col1 - - ( 35 ) * - col1 AS col1 FROM tab0 cor0
----
4386
5096
6014

query I rowsort
SELECT col0 + col0 * ( col1 ) * cor0.col0 AS col0 FROM tab2 cor0
----
106176
1526
359034

query I rowsort
SELECT - + col1 * col1 + - col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-1676
SELECT col2 * + col2 DIV - cor0.col2 + - col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-1676
SELECT col2 * + col2 / - cor0.col2 + - col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - cor0.col1 * - col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + cor0.col1 * - cor0.col1 - - cor0.col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - cor0.col2 + + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 21 * + col1 - col0 AS col1 FROM tab0 cor0
----
1782
1822
2002

query I rowsort
SELECT ALL + - cor0.col1 AS col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT + - col0 + + cor0.col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL - + ( col1 ) + + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1684
SELECT + CAST( col2 AS SIGNED ) FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1684
SELECT + CAST ( col2 AS INTEGER ) FROM tab0
----
1
33
82

query I rowsort
SELECT - 62 FROM tab0 AS cor0
----
-62
-62
-62

query I rowsort
SELECT ALL + cor0.col2 + col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col2 col2 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col1 * col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1689
SELECT ALL + col0 * col1 * - CAST( col2 AS SIGNED ) + - col2 FROM tab2 AS cor0
----
-119678
-51072
-5886

skipif mysql # not compatible
query I rowsort label-1689
SELECT ALL + col0 * col1 * - CAST ( col2 AS INTEGER ) + - col2 FROM tab2 AS cor0
----
-119678
-51072
-5886

query I rowsort
SELECT + col2 * + ( 98 * + col0 ) AS col2 FROM tab2 AS cor0
----
18522
198744
294196

query I rowsort
SELECT - col2 * - col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - - col1 * col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( 68 ) * cor0.col0 col0 FROM tab2 AS cor0
----
445
5245
5355

onlyif mysql # use DIV operator for integer division
query I rowsort label-1694
SELECT DISTINCT + col0 DIV + col0 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-1694
SELECT DISTINCT + col0 / + col0 AS col0 FROM tab0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1695
SELECT + col2 DIV + col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1695
SELECT + col2 / + col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT + - col2 + + col0 * + col0 AS col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT cor0.col1 * cor0.col0 - + cor1.col0 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 8d4f60949d9ec6839de1292e9cb8f65f

query I rowsort
SELECT ALL + - cor0.col0 * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - + col0 * col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + cor1.col2 * - cor1.col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8c9123b78bd6939e7be59da36c5c5c77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT 49 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT DISTINCT 79 FROM tab2 cor0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 ) col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - ( + col2 ) + col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1706
SELECT DISTINCT + CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1706
SELECT DISTINCT + CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * + 64 col1 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT - - ( col1 ) * col1 * 22 FROM tab2 AS cor0
----
21142
6358
76582

query I rowsort
SELECT - col1 * col2 * col1 AS col0 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT + col2 * col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT 38 + + 52 AS col1 FROM tab1 AS cor0
----
90
90
90

query I rowsort
SELECT - col1 + 68 * col2 FROM tab1 cor0
----
3646
3866
6515

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col2 ) col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - 70 * col1 FROM tab2 AS cor0
----
-1190
-2170
-4130

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( 0 AS REAL ) * col0 + 66 AS col0 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT + 49 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT - + ( - col2 ) + col0 * col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + cor0.col0 + col2 * col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + col0 * + col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL ( 45 ) + col2 * 7 AS col1 FROM tab1 cor0
----
423
444
717

query I rowsort
SELECT DISTINCT - 32 FROM tab1 AS cor0
----
-32

query I rowsort
SELECT ALL 35 + - 2 FROM tab0, tab1 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT 36 * + col0 FROM tab1 AS cor0
----
108
2304
2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1724
SELECT CAST( 84 AS SIGNED ) * tab1.col1 * - 15 - + col2 AS col0 FROM tab1
----
-12657
-16476
-32814

skipif mysql # not compatible
query I rowsort label-1724
SELECT CAST ( 84 AS INTEGER ) * tab1.col1 * - 15 - + col2 AS col0 FROM tab1
----
-12657
-16476
-32814

query I rowsort
SELECT ALL - + 46 AS col0 FROM tab0 AS cor0
----
-46
-46
-46

query I rowsort
SELECT col0 + - col1 * 89 AS col0 FROM tab2 AS cor0
----
-1434
-2752
-5173

query I rowsort
SELECT - col2 * col2 + - 4 - - col1 FROM tab0 AS cor0
----
-1007
-6637
92

query I rowsort
SELECT ALL - cor0.col1 + + col0 * - ( + col1 ) FROM tab2 cor0
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-1729
SELECT + + ( col0 ) DIV cor0.col1 FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-1729
SELECT + + ( col0 ) / cor0.col1 FROM tab1 cor0
----
0
6
6

query I rowsort
SELECT ALL + + col0 * + 59 FROM tab0 cor0
----
1416
2065
5251

query I rowsort
SELECT DISTINCT - - col0 + + 61 * 48 AS col1 FROM tab0 AS cor0
----
2952
2963
3017

query I rowsort
SELECT ALL col0 * ( + col1 ) - - col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2 cor2
----
972 values hashing to 89714dd446b7a97f8787d5744bdbf323

query I rowsort
SELECT DISTINCT - + cor0.col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT tab0.col2 - + col1 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT cor0.col2 * 52 FROM tab0, tab1 AS cor0, tab2, tab2 cor1
----
81 values hashing to f2bdee9b9512a60db6a52de7fd6c1ced

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1737
SELECT CAST( 16 AS SIGNED ) * + cor0.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 541fe66bdccd5b0e268906a8a4a1d9b3

skipif mysql # not compatible
query I rowsort label-1737
SELECT CAST ( 16 AS INTEGER ) * + cor0.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 541fe66bdccd5b0e268906a8a4a1d9b3

query I rowsort
SELECT 69 - 41 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT DISTINCT col1 * 59 * + 9 FROM tab2
----
16461
31329
9027

query I rowsort
SELECT + col1 * col0 * 65 + col2 FROM tab2
----
14132
299156
87333

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 81 col2 FROM tab0 AS cor0
----
114
163
82

query I rowsort
SELECT DISTINCT - + col2 + - 64 FROM tab0 AS cor0
----
-146
-65
-97

query I rowsort
SELECT + cor0.col0 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT col2 + - col0 * col1 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-1745
SELECT ALL col1 DIV 12 col1 FROM tab1
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1745
SELECT ALL col1 / 12 col1 FROM tab1
----
0
1
2

query I rowsort
SELECT + cor0.col0 * col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-1747
SELECT + ( col1 ) DIV col1 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-1747
SELECT + ( col1 ) / col1 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + - col2 * 42 col1 FROM tab1 AS cor0
----
-2214
-2337
-3936

query I rowsort
SELECT + - cor0.col1 * col1 + col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - - col1 * + col0 * 66 - - 44 FROM tab0 AS cor0
----
136268
224114
534578

query I rowsort
SELECT - + cor0.col0 * + col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + + col0 * - cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1754
SELECT - col2 DIV col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-1754
SELECT - col2 / col0 FROM tab2
----
-3
0
0

query I rowsort
SELECT cor0.col0 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # use DIV operator for integer division
query I rowsort label-1756
SELECT DISTINCT col0 DIV tab0.col2 + col2 AS col0 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-1756
SELECT DISTINCT col0 / tab0.col2 + col2 AS col0 FROM tab0
----
33
36
83

query I rowsort
SELECT DISTINCT - col0 * + 61 + + col2 AS col0 FROM tab0
----
-1431
-2134
-5347

query I rowsort
SELECT 18 AS col1 FROM tab1
----
18
18
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1759
SELECT ALL CAST( + 37 AS SIGNED ) + - col2 + - 62 * col2 AS col1 FROM tab1
----
-3365
-3554
-6011

skipif mysql # not compatible
query I rowsort label-1759
SELECT ALL CAST ( + 37 AS INTEGER ) + - col2 + - 62 * col2 AS col1 FROM tab1
----
-3365
-3554
-6011

query I rowsort
SELECT + + col2 - col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1761
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - 61 * + col2 + ( - 68 ) col1 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1761
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - 61 * + col2 + ( - 68 ) col1 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) + - col1 col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT 21 FROM tab0
----
21

query I rowsort
SELECT + col1 + - col2 * col0 AS col2 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT col0 + + ( - 69 ) + col0 FROM tab0 cor0
----
-21
1
109

onlyif mysql # use DIV operator for integer division
query I rowsort label-1766
SELECT DISTINCT - col1 + col0 DIV col0 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-1766
SELECT DISTINCT - col1 + col0 / col0 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT DISTINCT + cor0.col1 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - col1 * col1 * + 89 FROM tab0 AS cor0
----
-658244
-737009
-837401

query I rowsort
SELECT 41 AS col2 FROM tab2 AS cor0
----
41
41
41

query I rowsort
SELECT - col1 * + col1 AS col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT 48 * - 22 FROM tab0, tab2 AS cor0
----
9 values hashing to 2193898b11a83d6d9f53c732d7ce76d8

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab1, tab1 cor1, tab1 AS cor2
----
972 values hashing to ed80235f6457dada5cbb50ce9e2a8923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1773
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1773
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1774
SELECT DISTINCT col0 + cor0.col0 DIV col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-1774
SELECT DISTINCT col0 + cor0.col0 / col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT ALL - tab0.col2 AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 69 * - col2 + - col0 FROM tab0
----
-104
-2301
-5747

query I rowsort
SELECT ALL 93 + + col2 AS col2 FROM tab1
----
147
150
189

query I rowsort
SELECT ALL + 8 + 62 * col2 AS col2 FROM tab2
----
1620
1682
2364

query I rowsort
SELECT ALL - 79 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT DISTINCT ( + ( tab1.col1 ) ) * 59 + - col2 FROM tab1
----
1480
533
671

query I rowsort
SELECT 71 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 39b7515708f32e28b7b5a1bfec0df356

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 68 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # use DIV operator for integer division
query I rowsort label-1783
SELECT DISTINCT + + 86 + - cor0.col1 DIV - col1 FROM tab2 cor0
----
87

skipif mysql # not compatible
query I rowsort label-1783
SELECT DISTINCT + + 86 + - cor0.col1 / - col1 FROM tab2 cor0
----
87

query I rowsort
SELECT DISTINCT + ( + 84 ) AS col1 FROM tab1 AS cor0
----
84

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT 18 FROM tab2, tab0 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ALL + + col2 + - col0 FROM tab2 AS cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT + col1 * - 56 FROM tab1
----
-1456
-560
-728

query I rowsort
SELECT - 35 FROM tab1
----
-35
-35
-35

query I rowsort
SELECT - 17 FROM tab0
----
-17
-17
-17

query I rowsort
SELECT ALL - ( tab0.col1 ) * + col2 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT 99 AS col0 FROM tab0 cor0
----
99
99
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * col1 col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + ( col1 ) * col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + ( + col2 ) AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT col2 + + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col1 - + col0 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ALL col0 * tab2.col2 - 4 FROM tab2
----
185
2024
2998

query I rowsort
SELECT 17 * + col0 AS col2 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT + col0 * + col0 + - 82 FROM tab1 AS cor0
----
-73
4014
6318

query I rowsort
SELECT DISTINCT - 22 + + col0 + 89 FROM tab0 AS cor0
----
102
156
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1803
SELECT DISTINCT + cor0.col2 * - CAST( NULL AS SIGNED ) FROM tab2, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1803
SELECT DISTINCT + cor0.col2 * - CAST ( NULL AS INTEGER ) FROM tab2, tab1 AS cor0
----
NULL

query I rowsort
SELECT 86 * col0 FROM tab1 cor0
----
258
5504
6880

query I rowsort
SELECT + + col0 + + col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - 84 - + col1 AS col2 FROM tab1 AS cor0
----
-110
-94
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1807
SELECT DISTINCT - col1 DIV col1 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-1807
SELECT DISTINCT - col1 / col1 FROM tab2 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + ( - 88 ) col0 FROM tab1 AS cor0
----
1144
2288
880

query I rowsort
SELECT DISTINCT - + col2 * - cor0.col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - col2 * ( col1 ) FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT 95 * - col0 AS col1 FROM tab0 cor0
----
-2280
-3325
-8455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1812
SELECT - CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1812
SELECT - CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col1 col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + ( col2 ) * + col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort
SELECT col1 * CAST ( col1 + - col1 AS REAL ) FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * tab1.col1 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 92 - cor0.col1 FROM tab1, tab1 AS cor0
----
-102
-105
-118

query I rowsort
SELECT cor0.col0 * + ( + col2 ) AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - - cor0.col1 * 84 AS col2 FROM tab0 AS cor0
----
7224
7644
8148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1820
SELECT - col2 + + CAST( col1 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
-1560
-684
-864

skipif mysql # not compatible
query I rowsort label-1820
SELECT - col2 + + CAST ( col1 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT 61 AS col0 FROM tab1
----
61
61
61

query I rowsort
SELECT 47 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT 64 + + cor1.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to fb2b68e27cc55e70db4792e082986dd6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1824
SELECT ALL + tab2.col1 + CAST( NULL AS SIGNED ) * col1 - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1824
SELECT ALL + tab2.col1 + CAST ( NULL AS INTEGER ) * col1 - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1825
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1825
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL ( + tab1.col2 ) AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 col2 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-1828
SELECT - col1 DIV - 49 AS col0 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1828
SELECT - col1 / - 49 AS col0 FROM tab2 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1829
SELECT + col1 + - col2 DIV col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1829
SELECT + col1 + - col2 / col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1830
SELECT ALL + col2 DIV - 4 FROM tab2 AS cor0
----
-6
-6
-9

skipif mysql # not compatible
query I rowsort label-1830
SELECT ALL + col2 / - 4 FROM tab2 AS cor0
----
-6
-6
-9

query I rowsort
SELECT + col2 * - col1 + + 47 AS col2 FROM tab1
----
-1201
-1357
-523

onlyif mysql # use DIV operator for integer division
query I rowsort label-1832
SELECT col1 DIV + col0 col0 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1832
SELECT col1 / + col0 col0 FROM tab2 AS cor0
----
0
0
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1833
SELECT CAST( col1 AS SIGNED ) FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1833
SELECT CAST ( col1 AS INTEGER ) FROM tab1
----
10
13
26

query I rowsort
SELECT - 95 * tab1.col2 AS col1 FROM tab1
----
-5130
-5415
-9120

query I rowsort
SELECT ALL 87 * + 68 AS col1 FROM tab1
----
5916
5916
5916

query I rowsort
SELECT DISTINCT - 23 FROM tab0
----
-23

query I rowsort
SELECT + cor0.col0 * col1 + + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL + cor0.col1 * + col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + + col2 * col2 + + col1 * - 76 FROM tab1 AS cor0
----
2489
8228
940

query I rowsort
SELECT - col1 * - col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT col0 - - col0 FROM tab1
----
128
160
6

query I rowsort
SELECT ( - 67 ) FROM tab2
----
-67
-67
-67

query I rowsort
SELECT DISTINCT col1 + - col2 AS col0 FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT 8 + + col2 * - col1 FROM tab1 AS cor0
----
-1240
-1396
-562

query I rowsort
SELECT ( + tab1.col1 * - ( col0 ) ) + - col0 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT - 90 AS col0 FROM tab0
----
-90

query I rowsort
SELECT + 66 * col0 AS col2 FROM tab2 AS cor0
----
462
5148
5214

query I rowsort
SELECT DISTINCT + ( + col1 ) * + col0 + - ( + col0 ) AS col2 FROM tab1 AS cor0
----
576
75
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 86 * + col1 col2 FROM tab1 AS cor0
----
-1118
-2236
-860

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - ( col0 ) + ( col0 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + 1 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col1 + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + - 81 AS col0 FROM tab2 AS cor0
----
-81

query I rowsort
SELECT ALL + - col0 * - col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT 44 + col2 FROM tab2
----
70
71
82

query I rowsort
SELECT ALL - + 75 * - col2 + + col1 FROM tab2 cor0
----
2009
2056
2867

query I rowsort
SELECT ALL + col0 - + col2 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col2 * - col1 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL cor0.col1 + - col1 * + ( 73 ) * col2 AS col0 FROM tab1 cor0
----
-102466
-41600
-91091

query I rowsort
SELECT DISTINCT col2 * col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + cor0.col2 - col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT col2 * - col0 * + col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT ALL - 13 * - col2 + col1 FROM tab2 AS cor0
----
382
397
511

query I rowsort
SELECT DISTINCT + 35 * + col1 + 41 * 4 FROM tab0 AS cor0
----
3174
3349
3559

onlyif mysql # use DIV operator for integer division
query I rowsort label-1867
SELECT DISTINCT col1 DIV 69 + + 37 FROM tab0 AS cor0
----
38

skipif mysql # not compatible
query I rowsort label-1867
SELECT DISTINCT col1 / 69 + + 37 FROM tab0 AS cor0
----
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - ( col2 ) col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + col2 * + cor0.col0 + + col0 AS col2 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT - - col0 + - col2 FROM tab2 cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + + col0 * ( col2 ) + col2 * - col2 FROM tab0 AS cor0
----
-297
34
574

query I rowsort
SELECT - col2 + 25 AS col1 FROM tab1 AS cor0
----
-29
-32
-71

query I rowsort
SELECT DISTINCT + col0 * - col2 - col1 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT + col1 + + ( + col2 ) AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col1 * - ( + col2 * - col2 ) + col1 FROM tab2 AS cor0
----
-22568
-24531
-39825

query I rowsort
SELECT DISTINCT + - col1 + - col0 AS col1 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - col2 + tab0.col2 * ( - col1 ) AS col1 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT col2 + col2 AS col2 FROM tab1
----
108
114
192

query I rowsort
SELECT col0 - col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL - + col0 * ( ( + col2 ) ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1882
SELECT DISTINCT + col1 DIV 53 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1882
SELECT DISTINCT + col1 / 53 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col2 * ( - col1 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1884
SELECT + col0 + + 66 DIV + col0 FROM tab1 AS cor0
----
25
65
80

skipif mysql # not compatible
query I rowsort label-1884
SELECT + col0 + + 66 / + col0 FROM tab1 AS cor0
----
25
65
80

query I rowsort
SELECT ALL + 61 + cor0.col0 * col2 AS col0 FROM tab0 AS cor0
----
7359
853
96

query I rowsort
SELECT + col0 * col0 + + col0 + + col0 * col2 AS col1 FROM tab1 AS cor0
----
14160
174
7808

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 28 col0 FROM tab0 AS cor0
----
28

query I rowsort
SELECT cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - 46 FROM tab2 AS cor0
----
-46
-46
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-1890
SELECT + - ( col1 ) DIV col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1890
SELECT + - ( col1 ) / col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col2 + - col1 * - col0 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1892
SELECT DISTINCT - CAST( col2 AS SIGNED ) * - col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-1892
SELECT DISTINCT - CAST ( col2 AS INTEGER ) * - col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - ( ( + col0 ) ) * 0 + 46 + - col1 * + col1 AS col2 FROM tab1 AS cor0
----
-123
-54
-630

query I rowsort
SELECT ALL 59 * + col1 FROM tab0 AS cor0
----
5074
5369
5723

query I rowsort
SELECT DISTINCT + col0 + - tab0.col0 FROM tab0
----
0

query I rowsort
SELECT - cor0.col2 * col1 + + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - ( col0 ) + col1 + - 41 * col1 AS col2 FROM tab2 AS cor0
----
-1247
-2438
-759

query I rowsort
SELECT DISTINCT - 27 * col0 FROM tab0 AS cor0
----
-2403
-648
-945

query I rowsort
SELECT DISTINCT - col2 * col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 34 AS col0 FROM tab2 cor0
----
34
34
34

query I rowsort
SELECT - - col2 * - col1 * + cor0.col1 AS col2 FROM tab0 cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + col0 * cor0.col1 * + col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL - ( col2 ) + cor0.col2 AS col0 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 20 + col1 col0 FROM tab0 cor0
----
106
111
117

query I rowsort
SELECT ALL - 54 AS col1 FROM tab0 AS cor0
----
-54
-54
-54

query I rowsort
SELECT - - 1 * cor0.col2 + col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1907
SELECT DISTINCT CAST( col0 AS SIGNED ) FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1907
SELECT DISTINCT CAST ( col0 AS INTEGER ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT 73 + 84 * col2 AS col1 FROM tab0 AS cor0
----
157
2845
6961

query I rowsort
SELECT ALL + - 54 FROM tab2 AS cor0
----
-54
-54
-54

onlyif mysql # use DIV operator for integer division
query I rowsort label-1910
SELECT DISTINCT col0 DIV - cor0.col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-1910
SELECT DISTINCT col0 / - cor0.col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT - ( 47 ) * - col0 AS col1 FROM tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT - + col1 * + col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + cor0.col0 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - 74 AS col2 FROM tab1 AS cor0
----
-74
-74
-74

query I rowsort
SELECT - - col1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL - cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL tab2.col1 + + cor0.col0 FROM tab2, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 559eed2100755d7b17dc2c63e1bfca8a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1918
SELECT ALL 84 * 37 + col1 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1918
SELECT ALL 84 * 37 + col1 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col0 + tab2.col1 * - tab2.col2 AS col0 FROM tab2
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 col2 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1921
SELECT ALL col0 * - col0 - - col0 DIV + col0 FROM tab2
----
-48
-6083
-6240

skipif mysql # not compatible
query I rowsort label-1921
SELECT ALL col0 * - col0 - - col0 / + col0 FROM tab2
----
-48
-6083
-6240

query I rowsort
SELECT + tab2.col0 AS col2 FROM tab2 WHERE ( col1 ) <> ( NULL )
----

query I rowsort
SELECT DISTINCT tab0.col0 * - col1 AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col0 - - col0 AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT + tab1.col2 * - col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT col0 + + col1 + col0 AS col2 FROM tab1
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-1927
SELECT col2 DIV + col1 AS col2 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-1927
SELECT col2 / + col1 AS col2 FROM tab2
----
0
0
2

query I rowsort
SELECT ALL col0 + col0 FROM tab1
----
128
160
6

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col2 NOT BETWEEN ( col1 * col1 ) AND NULL
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col1 < ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1931
SELECT col1 DIV + col1 AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1931
SELECT col1 / + col1 AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT col0 * - tab2.col2 * + col0 AS col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT + - col1 + - col2 * col0 - - 92 FROM tab1 AS cor0
----
-3566
-7601
-96

query I rowsort
SELECT col2 + + col2 AS col1 FROM tab1
----
108
114
192

query I rowsort
SELECT - col1 * tab0.col1 * - col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col2 + + col2 * col0 col0 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT ALL - col0 * + col0 AS col1 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT ALL - col0 * + col0 AS col1 FROM tab2
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - tab1.col1 col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL col0 AS col0 FROM tab2 WHERE NOT - col1 * col2 + col1 * - col2 NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT col0 - col0 * + col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT ALL - col0 * - col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col0 FROM tab0 WHERE tab0.col2 + col1 * + col2 * col0 IN ( col0 * col1 )
----

query I rowsort
SELECT - col0 * - col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col1 + - tab2.col2 + col0 FROM tab2 WHERE - col2 + - col1 * - col0 < NULL
----

query I rowsort
SELECT ALL tab1.col0 * col0 * tab1.col2 AS col0 FROM tab1
----
233472
486
614400

query III rowsort
SELECT * FROM tab0 WHERE col1 + col0 + col2 * col1 * - col2 <= NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL NOT IN ( + col2 * tab2.col0 )
----

query I rowsort
SELECT col2 + - col2 * col1 AS col1 FROM tab2 AS cor0 WHERE NOT ( - cor0.col0 ) >= ( + cor0.col0 - col2 )
----
-1508
-608

query I rowsort
SELECT ALL + col2 + col1 * + col2 AS col0 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + tab1.col1 * - tab1.col1 FROM tab1
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1954
SELECT DISTINCT - col1 DIV col0 + col2 * + col1 AS col0 FROM tab2
----
1534
646
833

skipif mysql # not compatible
query I rowsort label-1954
SELECT DISTINCT - col1 / col0 + col2 * + col1 AS col0 FROM tab2
----
1534
646
833

query I rowsort
SELECT DISTINCT col1 + + col0 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-1956
SELECT - tab0.col2 DIV + tab0.col1 + col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1956
SELECT - tab0.col2 / + tab0.col1 + col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + col1 + + col0 AS col2 FROM tab0
----
110
132
180

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) IN ( col0 )
----

query I rowsort
SELECT ALL - col0 + - col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT col0 + - tab0.col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT col0 * col1 - col0 AS col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT - col2 + tab1.col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL - col2 + col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col1 + col1 + + col1 * tab1.col2 FROM tab1
----
1274
1456
590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 col1 FROM tab1
----
162
3648
7680

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( - col2 * col2 - + col0 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE ( NULL ) <= NULL
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1968
SELECT CAST( NULL AS DECIMAL ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1968
SELECT CAST ( NULL AS REAL ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1969
SELECT CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1969
SELECT CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 25 FROM tab1, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT - col1 * + col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT - 18 AS col1 FROM tab1
----
-18
-18
-18

query I rowsort
SELECT 39 AS col1 FROM tab1 AS cor0
----
39
39
39

query I rowsort
SELECT - + ( 84 ) * - col1 AS col0 FROM tab1 AS cor0
----
1092
2184
840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 + - 8 * col2 ) col0 FROM tab1
----
-406
-446
-755

query I rowsort
SELECT DISTINCT - tab0.col1 * col2 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT + tab1.col2 * 77 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to b5e8305eda430688c218c7463b3ae3a1

query I rowsort
SELECT ALL - 71 + col0 FROM tab0 cor0
----
-36
-47
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 69 + - col2 col2 FROM tab2 cor0
----
31
42
43

query I rowsort
SELECT + + 22 + col0 AS col0 FROM tab2 AS cor0
----
100
101
29

query I rowsort
SELECT ALL - col2 + + col2 * - ( + 42 ) + col2 * - col2 FROM tab0 AS cor0
----
-10250
-2508
-44

query I rowsort
SELECT col0 * + col0 + - 72 AS col1 FROM tab0 cor0
----
1153
504
7849

onlyif mysql # use DIV operator for integer division
query I rowsort label-1983
SELECT DISTINCT + + col1 + col1 DIV 67 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1983
SELECT DISTINCT + + col1 + col1 / 67 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 38 * + cor0.col1 col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 574118fdfac5a04cb80d0667229be0c9

query I rowsort
SELECT ALL + 48 * col2 + col0 AS col0 FROM tab0 AS cor0
----
1608
4025
83

query I rowsort
SELECT 84 + + col0 FROM tab1 AS cor0
----
148
164
87

query I rowsort
SELECT + col0 * col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + + col1 * ( + cor0.col2 ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col0 + 15 FROM tab0 AS cor0
----
104
39
50

query I rowsort
SELECT DISTINCT col1 - + col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col2 * + 98 FROM tab0 AS cor0
----
-3234
-8036
-98

query I rowsort
SELECT ALL - - col1 + col0 * - col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT - col1 + - col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - col1 + - 4 AS col0 FROM tab2 AS cor0
----
-21
-35
-63

query I rowsort
SELECT + col0 + - cor0.col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1996
SELECT ALL + col1 DIV tab0.col0 + + col2 FROM tab0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-1996
SELECT ALL + col1 / tab0.col0 + + col2 FROM tab0
----
3
36
83

query I rowsort
SELECT DISTINCT 56 AS col2 FROM tab2, tab1, tab1 cor0
----
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1998
SELECT - col1 * - col2 * + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1998
SELECT - col1 * - col2 * + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( col2 ) + + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + ( col2 ) + + col1 AS col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + ( - col1 ) * + col1 col0 FROM tab0 cor0
----
-7420
-8370
-9444

query I rowsort
SELECT - col1 * + 58 AS col0 FROM tab0 cor0
----
-4988
-5278
-5626

query I rowsort
SELECT DISTINCT + col0 * 96 FROM tab0 AS cor0
----
2304
3360
8544

query I rowsort
SELECT ALL 41 AS col2 FROM tab1 AS cor0
----
41
41
41

query I rowsort
SELECT - ( - 27 ) * + col0 FROM tab1 cor0
----
1728
2160
81

query I rowsort
SELECT + - 44 * col2 * + col1 AS col1 FROM tab2 AS cor0
----
-28424
-36828
-67496

query I rowsort
SELECT + + col2 + + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2008
SELECT DISTINCT CAST( - col1 + col0 * + col2 AS SIGNED ) FROM tab1
----
136
3638
7667

skipif mysql # not compatible
query I rowsort label-2008
SELECT DISTINCT CAST ( - col1 + col0 * + col2 AS INTEGER ) FROM tab1
----
136
3638
7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT 19 FROM tab0, tab1 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT DISTINCT 82 FROM tab1, tab0 cor0
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2012
SELECT DISTINCT - 58 DIV col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-2012
SELECT DISTINCT - 58 / col2 FROM tab1
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2013
SELECT CAST( - 0 + col0 * + col1 AS SIGNED ) AS col0 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2013
SELECT CAST ( - 0 + col0 * + col1 AS INTEGER ) AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT + cor0.col1 + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - col1 + col0 * - col1 * - col2 AS col2 FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT ALL + + cor0.col1 AS col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT 98 * - cor0.col1 FROM tab0 cor0
----
-8428
-8918
-9506

query I rowsort
SELECT DISTINCT + + col0 AS col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2019
SELECT ALL - 60 + - col1 DIV col2 AS col0 FROM tab0 AS cor0
----
-157
-61
-62

skipif mysql # not compatible
query I rowsort label-2019
SELECT ALL - 60 + - col1 / col2 AS col0 FROM tab0 AS cor0
----
-157
-61
-62

query I rowsort
SELECT + + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - 19 FROM tab2
----
-19

query I rowsort
SELECT ALL - 69 + + col0 FROM tab0 AS cor0
----
-34
-45
20

query I rowsort
SELECT DISTINCT - 70 * - col0 FROM tab1 AS cor0
----
210
4480
5600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2024
SELECT ALL - CAST( + tab0.col2 * + col2 AS SIGNED ) AS col0 FROM tab0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-2024
SELECT ALL - CAST ( + tab0.col2 * + col2 AS INTEGER ) AS col0 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL tab0.col1 * + col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - ( ( + col0 ) ) FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT col1 - - 37 FROM tab2
----
54
68
96

query I rowsort
SELECT ALL col0 * 48 FROM tab1 AS cor0
----
144
3072
3840

query I rowsort
SELECT - - col0 + + ( col0 ) * col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + cor0.col1 * - ( + cor0.col2 ) + + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2032
SELECT DISTINCT col1 DIV + col1 + + col0 AS col2 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-2032
SELECT DISTINCT col1 / + col1 + + col0 AS col2 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT + + col0 * + col0 + - 17 FROM tab2 AS cor0
----
32
6067
6224

query I rowsort
SELECT col2 - + ( col1 + - cor0.col0 ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1188
3135
6528

query I rowsort
SELECT ALL + col2 * 62 + 40 FROM tab0 AS cor0
----
102
2086
5124

query I rowsort
SELECT DISTINCT + col0 * - 2 + col2 AS col1 FROM tab2 AS cor0
----
-120
-130
13

query I rowsort
SELECT ALL - + cor0.col2 + - 97 FROM tab0 AS cor0
----
-130
-179
-98

query I rowsort
SELECT - tab1.col2 * + col0 * 2 AS col0 FROM tab1
----
-15360
-324
-7296

query I rowsort
SELECT ALL - 78 FROM tab1
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2040
SELECT ALL + 41 DIV - col1 col0 FROM tab2
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2040
SELECT ALL + 41 / - col1 col0 FROM tab2
----
-1
-2
0

query I rowsort
SELECT cor1.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL col1 * + 0 AS col0 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2043
SELECT col2 + CAST( col1 AS SIGNED ) + + col2 AS col2 FROM tab1 AS cor0
----
124
134
205

skipif mysql # not compatible
query I rowsort label-2043
SELECT col2 + CAST ( col1 AS INTEGER ) + + col2 AS col2 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT - col1 + - cor0.col2 + ( col1 + col1 ) AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - col1 + col2 + + col2 AS col1 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT ALL col0 + + tab1.col0 * - col0 FROM tab1
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2047
SELECT - col1 DIV col0 + - col0 * col0 * tab2.col0 FROM tab2
----
-347
-474552
-493039

skipif mysql # not compatible
query I rowsort label-2047
SELECT - col1 / col0 + - col0 * col0 * tab2.col0 FROM tab2
----
-347
-474552
-493039

query I rowsort
SELECT tab1.col2 + col1 * - col0 + col2 FROM tab1
----
-526
-848
30

query I rowsort
SELECT + col1 * col0 AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - col0 + col1 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT col2 * + tab1.col2 + col1 * - col0 FROM tab1
----
2609
2838
8176

onlyif mysql # use DIV operator for integer division
query I rowsort label-2052
SELECT DISTINCT + col2 DIV col2 + - col1 AS col0 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-2052
SELECT DISTINCT + col2 / col2 + - col1 AS col0 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT ALL + - col0 - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL col2 * + col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col1 + tab1.col0 * col1 * + col1 AS col0 FROM tab1
----
13533
2054
6410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 + col2 * col1 col2 FROM tab2
----
1292
1674
3068

query I rowsort
SELECT tab1.col2 * + col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - col0 - - tab0.col0 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col2 + col2 * + col1 * + col0 FROM tab2
----
119678
51072
5886

query I rowsort
SELECT - col0 + + tab2.col2 * col2 FROM tab2
----
1365
598
722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 col0 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2062
SELECT DISTINCT - col2 * col2 DIV col2 + + col0 * - col2 * col0 FROM tab0
----
-1226
-19041
-649604

skipif mysql # not compatible
query I rowsort label-2062
SELECT DISTINCT - col2 * col2 / col2 + + col0 * - col2 * col0 FROM tab0
----
-1226
-19041
-649604

onlyif mysql # use DIV operator for integer division
query I rowsort label-2063
SELECT - col0 DIV - col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2063
SELECT - col0 / - col1 FROM tab2
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2064
SELECT col1 * - col0 + - col1 * - col1 + - col1 DIV + col2 FROM tab0
----
181
5330
5917

skipif mysql # not compatible
query I rowsort label-2064
SELECT col1 * - col0 + - col1 * - col1 + - col1 / + col2 FROM tab0
----
181
5330
5917

query I rowsort
SELECT ALL - col2 + + col0 * col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT - - col1 - + cor0.col1 * col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + - col1 * - col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - cor0.col1 + + col2 * + col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + cor0.col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + col0 * col2 + + col1 * cor0.col0 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT tab0.col1 + + col2 FROM tab0
----
119
173
98

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL NOT IN ( + col1 * + col0 )
----

query I rowsort
SELECT - col0 + col2 AS col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL col1 * + col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + cor0.col2 + + cor0.col1 * cor0.col1 * - col1 FROM tab0 cor0
----
-636023
-753489
-912672

query I rowsort
SELECT + col2 + col2 * col2 AS col0 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL + + col0 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col1 * col0 + col2 col1 FROM tab1 AS cor0
----
-180
-40903
-83104

query I rowsort
SELECT DISTINCT - col2 + col0 * col2 * - col2 AS col2 FROM tab0 AS cor0
----
-26169
-36
-598518

onlyif mysql # use DIV operator for integer division
query I rowsort label-2080
SELECT col1 DIV - col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2080
SELECT col1 / - col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT ALL col2 * col2 * col2 AS col1 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT - - col2 * - col1 FROM tab1 cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col0 * col1 col2 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2085
SELECT + col0 DIV - col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-2085
SELECT + col0 / - col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT ALL - col0 + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL + 84 FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT DISTINCT col0 * cor0.col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - col1 * + cor0.col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - cor0.col1 * + col2 AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - 22 * col1 FROM tab0 AS cor0
----
-1892
-2002
-2134

query I rowsort
SELECT ALL cor0.col2 * - col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - col0 + - col2 AS col0 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT ALL col2 * col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - + col0 * cor0.col2 * - col2 + + col1 AS col0 FROM tab0 AS cor0
----
132
26222
598527

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + col2 - + col1 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL - - col0 + - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 7 AS col1 FROM tab1
----
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2102
SELECT 40 DIV - tab2.col1 FROM tab2
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2102
SELECT 40 / - tab2.col1 FROM tab2
----
-1
-2
0

query I rowsort
SELECT 45 + tab1.col1 AS col1 FROM tab1
----
55
58
71

query I rowsort
SELECT col2 + + col1 * + col1 AS col2 FROM tab1
----
157
265
730

query I rowsort
SELECT ALL + + 90 * - col1 + + 17 FROM tab0 AS cor0
----
-7723
-8173
-8713

onlyif mysql # use DIV operator for integer division
query I rowsort label-2106
SELECT ALL col2 + col2 DIV ( - ( col1 ) ) FROM tab1 AS cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-2106
SELECT ALL col2 + col2 / ( - ( col1 ) ) FROM tab1 AS cor0
----
52
52
89

query I rowsort
SELECT - + col0 * + col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + + 40 AS col1 FROM tab2 AS cor0
----
40

query I rowsort
SELECT ALL + cor0.col2 + 99 - 93 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8080c87152276ef3e171b8c411981307

query I rowsort
SELECT + 95 AS col0 FROM tab0
----
95
95
95

query I rowsort
SELECT DISTINCT col2 + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - col2 + - col0 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2113
SELECT + + col1 + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2113
SELECT + + col1 + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * col1 AS col1 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col1 * col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + col1 + + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col0 * col1 + 20 FROM tab0 AS cor0
----
-2044
-3375
-8079

query I rowsort
SELECT + col2 * col2 AS col1 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT 67 * col0 FROM tab0 AS cor0
----
1608
2345
5963

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) * + col2 col0 FROM tab0 cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2123
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2123
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 29 AS col2 FROM tab2
----
29
29
29

query I rowsort
SELECT DISTINCT - col1 * 74 * col2 FROM tab1 AS cor0
----
-103896
-42180
-92352

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2126
SELECT ALL CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2126
SELECT ALL CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 4 * col2 FROM tab1 cor0
----
216
228
384

query I rowsort
SELECT DISTINCT - + 91 AS col0 FROM tab2 AS cor0
----
-91

query I rowsort
SELECT - ( col2 ) * - col0 * + col1 + col2 AS col2 FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT + ( - col0 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + - col0 AS col2 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT ALL - col0 * cor0.col1 - col0 * ( col2 + col2 ) AS col0 FROM tab0 AS cor0
----
-22695
-3465
-3648

query I rowsort
SELECT + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col0 + col0 * + ( + col2 ) + col1 AS col0 FROM tab0 AS cor0
----
7300
854
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2135
SELECT - + ( + col2 ) + 72 DIV + col1 FROM tab2 cor0
----
-25
-25
-34

skipif mysql # not compatible
query I rowsort label-2135
SELECT - + ( + col2 ) + 72 / + col1 FROM tab2 cor0
----
-25
-25
-34

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab1, tab2 AS cor1
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT + col0 + 98 AS col1 FROM tab0
----
122
133
187

query I rowsort
SELECT - 30 FROM tab0
----
-30
-30
-30

query I rowsort
SELECT col1 + + col0 + - 17 AS col0 FROM tab2 AS cor0
----
120
21
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 0 * col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 + col0 * - 12 + + cor0.col1 * - col0 * col0 AS col2 FROM tab2 cor0
----
-106966
-1596
-359814

query I rowsort
SELECT - + 50 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2143
SELECT + - 31 DIV - col0 + - cor0.col0 + col1 col0 FROM tab2 AS cor0
----
-19
-62
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2143
SELECT + - 31 / - col0 + - cor0.col0 + col1 col0 FROM tab2 AS cor0
----
-19
-62
28

query I rowsort
SELECT ( col0 ) * 87 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT + 53 * col2 + - ( - 43 ) AS col0 FROM tab0 AS cor0
----
1792
4389
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2146
SELECT + - col1 * col2 * + cor0.col0 + 54 DIV col2 FROM tab0 AS cor0
----
-3341
-664118
-68111

skipif mysql # not compatible
query I rowsort label-2146
SELECT + - col1 * col2 * + cor0.col0 + 54 / col2 FROM tab0 AS cor0
----
-3341
-664118
-68111

query I rowsort
SELECT DISTINCT + - col1 * cor0.col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + ( - col1 ) FROM tab0 cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col1 col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - 4 * col1 AS col0 FROM tab0 AS cor0
----
-344
-364
-388

query I rowsort
SELECT ( col0 ) + + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - - col0 AS col2 FROM tab0 cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * ( col1 ) col0 FROM tab1 AS cor0
----
1040
640
78

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab1 cor1, tab0 AS cor2
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

onlyif mysql # use DIV operator for integer division
query I rowsort label-2155
SELECT + + col1 DIV - col1 + 52 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1351
1403
1975

skipif mysql # not compatible
query I rowsort label-2155
SELECT + + col1 / - col1 + 52 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1351
1403
1975

query I rowsort
SELECT ALL + col0 + col2 * col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + col2 * + 66 AS col1 FROM tab1 AS cor0
----
3564
3762
6336

query I rowsort
SELECT ALL col0 * + col1 + col2 AS col2 FROM tab2 cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2159
SELECT DISTINCT - col0 + col2 DIV col0 col1 FROM tab0 AS cor0
----
-23
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2159
SELECT DISTINCT - col0 + col2 / col0 col1 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2161
SELECT + CAST( NULL AS SIGNED ) * + 81 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2161
SELECT + CAST ( NULL AS INTEGER ) * + 81 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 * cor0.col2 + col1 col2 FROM tab0 AS cor0
----
166
2363
5749

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL - cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - ( + col1 ) col1 FROM tab1
----
-23
54
67

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0, tab2, tab1 AS cor1
----
972 values hashing to 92235dbc382d83baa93d6546ed489b0c

query I rowsort
SELECT - + col0 - cor0.col2 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2168
SELECT + cor0.col1 + col0 DIV col1 AS col0 FROM tab2 cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-2168
SELECT + cor0.col1 + col0 / col1 AS col0 FROM tab2 cor0
----
21
31
60

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 803a5565701c4ced6bba69940782c17a

query I rowsort
SELECT ALL - tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT - 83 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT - col1 * - 87 FROM tab0
----
7482
7917
8439

query I rowsort
SELECT 97 - cor0.col1 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 2f8c3d812260f80e9b2e35822eb5f24d

query I rowsort
SELECT 5 FROM tab0
----
5
5
5

query I rowsort
SELECT tab0.col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + + 76 + col0 + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1380
-491
-754

query I rowsort
SELECT col2 + ( col0 ) * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT col1 * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - - cor0.col2 + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + cor0.col2 * cor0.col1 + + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT col0 * 44 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
106
2806
3507

query I rowsort
SELECT DISTINCT - col2 - 56 FROM tab0 AS cor0
----
-138
-57
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 - - 19 col2 FROM tab1 AS cor0
----
181
3667
7699

query I rowsort
SELECT DISTINCT + col1 + + ( - col1 + col0 * - cor0.col2 ) AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + tab1.col0 + col1 AS col2 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2186
SELECT + col0 - col2 DIV col0 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-2186
SELECT + col0 - col2 / col0 FROM tab2 AS cor0
----
4
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2187
SELECT ALL + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2187
SELECT ALL + CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + ( 32 ) + - col1 * ( 12 ) FROM tab0 cor0
----
-1000
-1060
-1132

query I rowsort
SELECT - 80 FROM tab0 AS cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + col2 * - col2 + col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT + col0 - - 93 * - cor0.col2 FROM tab0 AS cor0
----
-3045
-58
-7537

query I rowsort
SELECT ALL ( col2 + + col0 ) AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT cor0.col0 - - cor0.col0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 43cd4d6bf46fb9ce15caf369cb36598e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + cor0.col1 + + col1 col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ( + col2 ) + - col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2197
SELECT DISTINCT col1 * - col1 + + col1 DIV - 73 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-2197
SELECT DISTINCT col1 * - col1 + + col1 / - 73 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - + 1 * 6 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT col0 + + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + 38 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT DISTINCT - + cor0.col1 + 61 AS col0 FROM tab2 AS cor0
----
2
30
44

query I rowsort
SELECT ALL - 42 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

query I rowsort
SELECT ALL + 79 AS col0 FROM tab1 AS cor0
----
79
79
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2204
SELECT DISTINCT - col0 + + col1 DIV col0 AS col0 FROM tab1 cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-2204
SELECT DISTINCT - col0 + + col1 / col0 AS col0 FROM tab1 cor0
----
-64
-80
5

query I rowsort
SELECT DISTINCT + ( + col1 ) + + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT 28 + + col2 AS col0 FROM tab0
----
110
29
61

query I rowsort
SELECT + 74 + tab1.col1 FROM tab1
----
100
84
87

query I rowsort
SELECT DISTINCT col0 - + col0 AS col0 FROM tab2
----
0

query I rowsort
SELECT + ( - cor0.col1 ) * + col1 + col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT col0 * col1 * col2 - + col2 * + col0 FROM tab1 AS cor0
----
32832
4050
92160

query I rowsort
SELECT - 11 * - col2 FROM tab0 AS cor0
----
11
363
902

onlyif mysql # use DIV operator for integer division
query I rowsort label-2212
SELECT ALL + - 39 DIV col1 + + col1 AS col0 FROM tab1 cor0
----
10
25
7

skipif mysql # not compatible
query I rowsort label-2212
SELECT ALL + - 39 / col1 + + col1 AS col0 FROM tab1 cor0
----
10
25
7

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

query I rowsort
SELECT cor0.col1 * + col0 * + 80 AS col1 FROM tab1 AS cor0
----
51200
6240
83200

query I rowsort
SELECT ALL - ( col2 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - 23 * + col1 FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT DISTINCT ( 16 ) AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
16

query I rowsort
SELECT 36 * - col2 AS col0 FROM tab1 cor0
----
-1944
-2052
-3456

query I rowsort
SELECT ALL + col2 * + 58 AS col1 FROM tab2 AS cor0
----
1508
1566
2204

query I rowsort
SELECT - col1 * - ( col2 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - - col1 * cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2222
SELECT DISTINCT + col0 DIV 8 FROM tab1 AS cor0
----
0
10
8

skipif mysql # not compatible
query I rowsort label-2222
SELECT DISTINCT + col0 / 8 FROM tab1 AS cor0
----
0
10
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col1 + col0 col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT col0 + + 73 FROM tab2 AS cor0
----
151
152
80

query I rowsort
SELECT + + col1 + + col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2226
SELECT DISTINCT col1 + + CAST( + 45 + + col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
141
182
83

skipif mysql # not compatible
query I rowsort label-2226
SELECT DISTINCT col1 + + CAST ( + 45 + + col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
141
182
83

query I rowsort
SELECT DISTINCT - col2 * col2 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT - col1 * col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT 49 - tab1.col2 AS col1 FROM tab1
----
-47
-5
-8

query I rowsort
SELECT DISTINCT - ( - col0 ) - ( - ( col1 ) ) FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2231
SELECT ALL + col1 DIV - col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2231
SELECT ALL + col1 / - col2 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT - col1 + + col1 * col2 AS col1 FROM tab2 AS cor0
----
1475
629
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - + cor0.col2 + 23 AS col0 FROM tab0 AS cor0
----
-10
-59
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 col0 FROM tab0 cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col1 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL 98 FROM tab0, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

onlyif mysql # use DIV operator for integer division
query I rowsort label-2238
SELECT tab1.col2 DIV col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2238
SELECT tab1.col2 / col1 FROM tab1
----
2
5
7

query I rowsort
SELECT + col2 + + 93 FROM tab0
----
126
175
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2240
SELECT - col1 + col2 + + col2 DIV col0 FROM tab1
----
46
47
84

skipif mysql # not compatible
query I rowsort label-2240
SELECT - col1 + col2 + + col2 / col0 FROM tab1
----
46
47
84

query I rowsort
SELECT DISTINCT - col1 * - col2 + + col0 AS col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT - col2 * + col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT cor0.col1 + + ( - col2 ) * - col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + col1 * - ( - col0 ) + + tab0.col1 AS col0 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL + col0 + - ( col0 ) * - col1 FROM tab2
----
1422
224
4680

query I rowsort
SELECT DISTINCT col0 * - col2 + col1 * col1 + col2 FROM tab0
----
1065
6637
9375

query I rowsort
SELECT 20 + cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 15131b2f8a8fbb3498fea021d1cfc917

query I rowsort
SELECT ALL - col0 + col0 * col1 FROM tab2
----
1264
210
4524

query I rowsort
SELECT DISTINCT 2 AS col1 FROM tab1, tab1 AS cor0
----
2

query I rowsort
SELECT ALL col2 + + tab1.col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT - col0 * - col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL cor0.col2 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2253
SELECT - col0 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2253
SELECT - col0 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 95 FROM tab2 AS cor0
----
-95
-95
-95

query I rowsort
SELECT - 19 + - col0 FROM tab2 cor0
----
-26
-97
-98

query I rowsort
SELECT DISTINCT + col1 + - col2 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2257
SELECT - + ( - col1 ) + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2257
SELECT - + ( - col1 ) + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * - col2 + - 73 + col1 FROM tab2 AS cor0
----
-2042
-231
-3058

query I rowsort
SELECT tab2.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL 83 AS col0 FROM tab0
----
83
83
83

query I rowsort
SELECT + 66 + tab0.col1 AS col1 FROM tab0
----
152
157
163

onlyif mysql # use DIV operator for integer division
query I rowsort label-2262
SELECT ALL col0 DIV tab0.col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2262
SELECT ALL col0 / tab0.col0 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT - cor0.col1 * + 55 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-1705
-3245
-935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 * cor1.col0 col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cb10cde269b3bc987dceeadbf879a2a0

query I rowsort
SELECT DISTINCT + + 33 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2838
-3003
-3201

query I rowsort
SELECT ALL + 15 FROM tab1 AS cor0
----
15
15
15

query I rowsort
SELECT DISTINCT - 92 * - col0 AS col2 FROM tab2 AS cor0
----
644
7176
7268

onlyif mysql # use DIV operator for integer division
query I rowsort label-2268
SELECT + - col2 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2268
SELECT + - col2 / col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2269
SELECT + col2 DIV col0 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-2269
SELECT + col2 / col0 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT DISTINCT + cor0.col1 * col0 + col2 + cor0.col1 FROM tab0 AS cor0
----
2183
3493
8272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - cor0.col0 * col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - + cor0.col1 * col2 * 18 FROM tab1 AS cor0
----
-10260
-22464
-25272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col1 col2 FROM tab2 cor0
----
0

query I rowsort
SELECT - + 68 + + col2 FROM tab1 AS cor0
----
-11
-14
28

query I rowsort
SELECT DISTINCT + 30 AS col1 FROM tab1, tab2 AS cor0
----
30

query I rowsort
SELECT - - 95 FROM tab1 AS cor0
----
95
95
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2278
SELECT ALL - col2 DIV + ( 39 * + col1 ) AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2278
SELECT ALL - col2 / + ( 39 * + col1 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT 22 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT tab1.col1 * col1 FROM tab1
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( + col2 ) col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT ALL - col2 * + ( + tab2.col2 ) FROM tab2
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 72 AS REAL ) FROM tab0
----
72
72
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2284
SELECT ALL + CAST( + col1 AS SIGNED ) DIV - tab2.col0 AS col1 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-2284
SELECT ALL + CAST ( + col1 AS INTEGER ) / - tab2.col0 AS col1 FROM tab2
----
-4
0
0

query I rowsort
SELECT + col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + col2 + - cor0.col0 * col1 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT + 9 AS col1 FROM tab2 AS cor0
----
9

query I rowsort
SELECT DISTINCT - + cor0.col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + - col1 + col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT 67 FROM tab1 AS cor0
----
67
67
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - - 46 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1426
2714
782

onlyif mysql # use DIV operator for integer division
query I rowsort label-2293
SELECT ALL + - cor0.col0 + + col1 * - col0 DIV - ( 91 * col1 ) AS col2 FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-2293
SELECT ALL + - cor0.col0 + + col1 * - col0 / - ( 91 * col1 ) AS col2 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - col1 + col2 * + 15 AS col2 FROM tab2
----
331
374
553

query I rowsort
SELECT ALL + col2 + - col1 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL 14 * + col1 + + 97 FROM tab1 cor0
----
237
279
461

query I rowsort
SELECT DISTINCT - 60 + col0 * ( col1 * - col2 ) - - col0 AS col0 FROM tab2 AS cor0
----
-119634
-51015
-5912

onlyif mysql # use DIV operator for integer division
query I rowsort label-2298
SELECT - col2 * col0 + 4 DIV + col0 AS col1 FROM tab1 AS cor0
----
-161
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2298
SELECT - col2 * col0 + 4 / + col0 AS col1 FROM tab1 AS cor0
----
-161
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2299
SELECT ALL col0 + + col2 * CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-2299
SELECT ALL col0 + + col2 * CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT 6 - - cor0.col0 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT ALL + col0 * - cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 54 + + col1 col2 FROM tab0 cor0
----
140
145
151

query I rowsort
SELECT DISTINCT col1 + col0 * + ( - 36 ) FROM tab1 cor0
----
-2294
-2867
-82

query I rowsort
SELECT ALL - col2 * col2 + - 12 FROM tab2 AS cor0
----
-1456
-688
-741

query I rowsort
SELECT cor0.col1 * col2 * 90 + ( col1 ) * - col1 * 29 AS col2 FROM tab1 AS cor0
----
106756
107419
48400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 3 * + col0 col0 FROM tab1 AS cor0
----
-192
-240
-9

query I rowsort
SELECT DISTINCT + - col1 + - col1 * + 72 * 67 FROM tab1 AS cor0
----
-125450
-48250
-62725

query I rowsort
SELECT ALL - 67 AS col1 FROM tab1 AS cor0
----
-67
-67
-67

query I rowsort
SELECT + col2 - + col2 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col0 + - cor0.col1 col2 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT DISTINCT - col1 - + ( + col0 ) AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + + col0 + ( - col1 * col1 ) FROM tab1 cor0
----
-36
-673
-89

query I rowsort
SELECT ALL - col2 * col0 + + 10 AS col2 FROM tab2 AS cor0
----
-179
-2018
-2992

query I rowsort
SELECT - + col1 + + col0 AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL - + cor0.col2 + ( - col0 ) * + cor0.col1 * 62 FROM tab1 cor0
----
-39737
-4890
-64576

query I rowsort
SELECT ALL 31 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT + - col1 * + col0 + + col1 * cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + col2 * col1 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + - 23 col0 FROM tab1 AS cor0
----
-119
-77
-80

query I rowsort
SELECT + + col0 - ( - col2 ) FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2321
SELECT + + col2 DIV - 83 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2321
SELECT + + col2 / - 83 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + col2 * - col2 - 2 AS col1 FROM tab0 cor0
----
-1091
-3
-6726

query I rowsort
SELECT + - col1 - col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + + col1 + - 64 AS col1 FROM tab1 AS cor0
----
-38
-51
-54

query I rowsort
SELECT col2 + - ( - 86 ) FROM tab1 AS cor0
----
140
143
182

query I rowsort
SELECT - + col1 + 15 FROM tab2 AS cor0
----
-16
-2
-44

query I rowsort
SELECT DISTINCT col2 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - ( col0 ) + col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + col1 + - col2 * - col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT cor2.col1 * 61 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to ca47b1de2f6ae6d57cab2b9e4a9ec2fd

query I rowsort
SELECT col1 + + 56 AS col1 FROM tab0 AS cor0
----
142
147
153

query I rowsort
SELECT + cor1.col2 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2333
SELECT DISTINCT - + CAST( 7 AS SIGNED ) * - cor0.col1 AS col2 FROM tab0 AS cor0
----
602
637
679

skipif mysql # not compatible
query I rowsort label-2333
SELECT DISTINCT - + CAST ( 7 AS INTEGER ) * - cor0.col1 AS col2 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT 54 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to c12c2f39593b3ce157086f29d8391c32

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab1, tab0 cor2
----
3645 values hashing to 3b4587ab6c08d2179c6df094d2f76ad7

query I rowsort
SELECT col0 + + col1 AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT cor0.col1 + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 65 AS col2 FROM tab1
----
65
65
65

query I rowsort
SELECT tab2.col0 AS col2 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + col2 * cor0.col0 + + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + col2 - + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - tab1.col0 * - col1 AS col1 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 col1 FROM tab2
----
96
96
96

query I rowsort
SELECT + 27 FROM tab1
----
27
27
27

query I rowsort
SELECT ALL - + col2 + - col1 + - 91 AS col2 FROM tab2 AS cor0
----
-146
-149
-176

query I rowsort
SELECT DISTINCT - col1 + - col0 FROM tab2 AS cor0
----
-137
-38
-96

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab2 AS cor1
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

onlyif mysql # use DIV operator for integer division
query I rowsort label-2348
SELECT ALL + col1 - + col2 DIV - col1 FROM tab1
----
15
20
28

skipif mysql # not compatible
query I rowsort label-2348
SELECT ALL + col1 - + col2 / - col1 FROM tab1
----
15
20
28

query I rowsort
SELECT ALL + 16 + + col0 FROM tab1
----
19
80
96

query I rowsort
SELECT DISTINCT col2 + tab1.col0 AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT col1 * - col0 + - col2 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + col1 * col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT - 46 + col1 + col1 * col0 FROM tab0
----
2104
3446
8144

query I rowsort
SELECT + col0 * + col0 AS col1 FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-2355
SELECT ALL + col0 + + col2 DIV + 73 AS col2 FROM tab1
----
3
64
81

skipif mysql # not compatible
query I rowsort label-2355
SELECT ALL + col0 + + col2 / + 73 AS col2 FROM tab1
----
3
64
81

query I rowsort
SELECT 75 + - col0 FROM tab0
----
-14
40
51

query I rowsort
SELECT 38 + - col1 * ( col1 ) + col0 FROM tab2 cor0
----
-172
-3365
-916

query I rowsort
SELECT - cor0.col2 * col1 + col2 * - col0 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
-133
-14842
-3663

query I rowsort
SELECT ALL - col0 * + col2 * cor0.col0 + cor0.col2 FROM tab2 AS cor0
----
-1296
-158158
-237120

query I rowsort
SELECT ALL - + col0 + - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + col0 + col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - 30 * col1 + cor0.col0 * - col2 + - col1 AS col2 FROM tab1 AS cor0
----
-3958
-8083
-968

query I rowsort
SELECT + col2 + - col0 * + ( col1 ) + + col1 FROM tab0 AS cor0
----
-1945
-3297
-7926

query I rowsort
SELECT DISTINCT 82 * + col1 AS col0 FROM tab2 cor0
----
1394
2542
4838

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab1 AS cor1, tab0 cor2
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT ALL - col1 * + col2 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + + col2 + 27 AS col0 FROM tab1 AS cor0
----
123
81
84

query I rowsort
SELECT ALL + cor0.col1 + cor0.col0 * + col1 * ( col2 ) FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT DISTINCT + col1 - col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT + ( col2 ) * col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2371
SELECT DISTINCT - ( 25 ) DIV + col1 + + col2 FROM tab1 AS cor0
----
54
55
95

skipif mysql # not compatible
query I rowsort label-2371
SELECT DISTINCT - ( 25 ) / + col1 + + col2 FROM tab1 AS cor0
----
54
55
95

query I rowsort
SELECT ALL ( + 8 ) * cor0.col1 - col1 FROM tab1 AS cor0
----
182
70
91

query I rowsort
SELECT ALL + + 44 + col1 * col0 FROM tab1 AS cor0
----
1084
122
684

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2374
SELECT - - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2374
SELECT - - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2375
SELECT DISTINCT - CAST( NULL AS SIGNED ) / + col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2375
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / + col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2376
SELECT ALL - col0 DIV - 96 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2376
SELECT ALL - col0 / - 96 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( + col0 ) * - cor0.col0 + 47 * + cor0.col0 FROM tab2 AS cor0
----
-2418
-2528
280

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * cor0.col2 * col1 col0 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2379
SELECT DISTINCT - - cor0.col0 DIV col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2379
SELECT DISTINCT - - cor0.col0 / col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT DISTINCT - 51 FROM tab0 AS cor0
----
-51

query I rowsort
SELECT - cor0.col1 + + ( + 50 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 7c3ead0daf3ce64a9bf1460f70d8f4cc

query I rowsort
SELECT ALL 44 + 87 * col0 FROM tab0 AS cor0
----
2132
3089
7787

query I rowsort
SELECT - cor0.col1 * + cor0.col0 + + 10 * + cor0.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 385a5e781213f31f2e03e81dc705dfcd

query I rowsort
SELECT DISTINCT + - 9 AS col0 FROM tab1 AS cor0
----
-9

query I rowsort
SELECT ALL ( - 16 ) + col0 FROM tab0 AS cor0
----
19
73
8

query I rowsort
SELECT ALL + col0 + col0 AS col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL - ( col0 ) * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + - 21 + - 6 * - col0 FROM tab1 cor0
----
-3
363
459

query I rowsort
SELECT DISTINCT - col0 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + col1 * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + col0 * - col1 * col2 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col2 * + col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + 98 * col2 + col1 FROM tab0 AS cor0
----
195
3320
8127

query I rowsort
SELECT DISTINCT col1 AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + col0 * col0 + ( col0 ) * - col2 AS col0 FROM tab1 cor0
----
-14080
-171
-7744

query I rowsort
SELECT ( - col0 ) AS col1 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - 75 * + cor0.col2 - 0 FROM tab1 AS cor0
----
-4050
-4275
-7200

query I rowsort
SELECT + 80 AS col0 FROM tab0 AS cor0
----
80
80
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2399
SELECT ALL + + 0 + - cor0.col0 * CAST( 11 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-77
-858
-869

skipif mysql # not compatible
query I rowsort label-2399
SELECT ALL + + 0 + - cor0.col0 * CAST ( 11 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-77
-858
-869

query I rowsort
SELECT DISTINCT + col0 - col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + + 24 * col1 FROM tab2 cor0
----
1416
408
744

query I rowsort
SELECT ( col0 ) + - col0 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( tab2.col2 ) col2 FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2404
SELECT CAST( col2 AS SIGNED ) + - col1 FROM tab1
----
28
47
83

skipif mysql # not compatible
query I rowsort label-2404
SELECT CAST ( col2 AS INTEGER ) + - col1 FROM tab1
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2405
SELECT col2 DIV - ( col1 ) FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2405
SELECT col2 / - ( col1 ) FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT ALL col1 * + 74 FROM tab2 AS cor0
----
1258
2294
4366

query I rowsort
SELECT + + col1 * - col2 + col0 + - col2 AS col0 FROM tab0 AS cor0
----
-2847
-63
-7455

query I rowsort
SELECT cor0.col2 * col2 + + col1 AS col0 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL col1 * ( + col0 * - col1 ) AS col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT + col0 + col1 + col0 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT ALL + - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - col0 + col0 * - col2 FROM tab0 cor0
----
-70
-7387
-816

query I rowsort
SELECT + - col1 + 29 FROM tab2 AS cor0
----
-2
-30
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT col0 * + 91 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2417
SELECT col0 * + col2 + + col2 DIV - col0 + col0 AS col0 FROM tab1
----
147
3712
7759

skipif mysql # not compatible
query I rowsort label-2417
SELECT col0 * + col2 + + col2 / - col0 + col0 AS col0 FROM tab1
----
147
3712
7759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 83 + + col1 col2 FROM tab0 AS cor0
----
-2653
-6715
14

query I rowsort
SELECT DISTINCT + + cor0.col2 + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col2 + + cor0.col0 * col1 AS col0 FROM tab0 cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 * - col1 col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL ( col0 ) * - 11 FROM tab1
----
-33
-704
-880

query I rowsort
SELECT DISTINCT - col0 + col1 AS col1 FROM tab0
----
2
62

query I rowsort
SELECT ( + ( cor0.col2 ) ) * - 72 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 698a6a7750df7b9bd1a2af33855a552a

query I rowsort
SELECT DISTINCT + tab1.col2 * + col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ALL - tab1.col0 * - 32 AS col1 FROM tab1
----
2048
2560
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 3 col2 FROM tab1
----
192
240
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2428
SELECT DISTINCT col2 * + CAST( - ( - col1 ) AS SIGNED ) AS col0 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-2428
SELECT DISTINCT col2 * + CAST ( - ( - col1 ) AS INTEGER ) AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT col1 + 93 * - col0 * + col2 FROM tab0 AS cor0
----
-3158
-678623
-73570

query I rowsort
SELECT - col0 + ( - cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL col1 * 3 AS col1 FROM tab2 AS cor0
----
177
51
93

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab2, tab1 AS cor1, tab1, tab0 cor2
----
3645 values hashing to f99537dcc805430f79ac82ef70a4bd59

query I rowsort
SELECT ALL + 95 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT cor0.col1 * + col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT cor0.col2 + + cor0.col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT col1 * col2 FROM tab1 WHERE - col0 NOT IN ( col2 * col0 * tab1.col1 )
----
1248
1404
570

query I rowsort
SELECT col1 * col2 AS col0 FROM tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 col2 FROM tab2 AS cor0 WHERE - col0 >= NULL
----

query I rowsort
SELECT - col0 + + cor0.col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2440
SELECT + col0 DIV + col0 - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-2440
SELECT + col0 / + col0 - col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT - col0 - col2 * col2 AS col1 FROM tab0 cor0
----
-1113
-36
-6813

query III rowsort
SELECT ALL * FROM tab2 WHERE ( NULL ) NOT IN ( col1 + - col0 )
----

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col0 * cor0.col0 * + cor0.col0 - - col1 AS col0 FROM tab1 AS cor0
----
262154
512013
53

query I rowsort
SELECT col2 * + col1 * - col0 - col2 AS col1 FROM tab0
----
-3396
-664200
-68145

query I rowsort
SELECT ALL - col2 * - col0 * + col2 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT ALL col2 AS col0 FROM tab0 WHERE NOT - col0 > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col2 col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + col0 * + col1 * col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT col2 * + col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL + col0 * + tab0.col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 * col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT tab1.col2 * col1 + + col1 AS col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT DISTINCT - col1 + col1 AS col2 FROM tab2
----
0

query I rowsort
SELECT ALL + col0 + - col0 FROM tab2
----
0
0
0

query I rowsort
SELECT col1 + tab2.col1 FROM tab2
----
118
34
62

query I rowsort
SELECT - col1 + + col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT + col0 * - col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + + col1 * col2 * + col1 AS col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT - - col1 * col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query IIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 WHERE ( NULL ) > NULL
----

query I rowsort
SELECT col2 + col2 AS col2 FROM tab0
----
164
2
66

query I rowsort
SELECT ALL col0 * - col1 * + tab0.col1 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - tab2.col2 AS col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT ALL + tab2.col0 * col1 DIV - col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-2465
SELECT ALL + tab2.col0 * col1 / - col0 FROM tab2
----
-17
-31
-59

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL >= ( NULL )
----

query I rowsort
SELECT ALL col1 + col2 * col1 + col2 AS col2 FROM tab0
----
195
2957
7635

onlyif mysql # use DIV operator for integer division
query I rowsort label-2468
SELECT DISTINCT - col1 DIV + col1 + - col0 col0 FROM tab1
----
-4
-65
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2468
SELECT DISTINCT - col1 / + col1 + - col0 col0 FROM tab1
----
-4
-65
-81

query I rowsort
SELECT + + col2 * + col0 * + col0 FROM tab1 AS cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - col1 * col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2473
SELECT DISTINCT + - col0 DIV col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2473
SELECT DISTINCT + - col0 / col1 FROM tab2 AS cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - + col1 * col0 + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query III rowsort
SELECT * FROM tab1 WHERE col0 IN ( + col1 )
----

query I rowsort
SELECT ALL - col0 * col1 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * cor0.col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 35 FROM tab0
----
35

query I rowsort
SELECT col1 * col0 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2481
SELECT cor0.col2 DIV + CAST( col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2481
SELECT cor0.col2 / + CAST ( col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * cor0.col2 * - 73 AS col0 FROM tab2 AS cor0
----
-105412
-49348
-53217

query I rowsort
SELECT + col2 * + col1 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col0 * 94 * + col2 + col2 FROM tab0 cor0
----
3291
686094
74481

query I rowsort
SELECT - col0 * 40 AS col0 FROM tab0 AS cor0
----
-1400
-3560
-960

query I rowsort
SELECT DISTINCT + cor0.col2 * + col1 + - 13 FROM tab2 AS cor0
----
1521
633
824

query I rowsort
SELECT - 96 AS col1 FROM tab2
----
-96
-96
-96

query I rowsort
SELECT ALL tab2.col2 * - col0 AS col0 FROM tab2
----
-189
-2028
-3002

query IIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab2 cor1
----
54 values hashing to 018801f36b33d2fe82cb95918ba502d6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2490
SELECT + cor0.col0 * + CAST( col0 AS SIGNED ) + - col0 AS col0 FROM tab1 cor0
----
4032
6
6320

skipif mysql # not compatible
query I rowsort label-2490
SELECT + cor0.col0 * + CAST ( col0 AS INTEGER ) + - col0 AS col0 FROM tab1 cor0
----
4032
6
6320

query I rowsort
SELECT ALL + col0 * 9 - 3 AS col0 FROM tab2
----
60
699
708

query I rowsort
SELECT + col1 * 44 FROM tab2 AS cor0
----
1364
2596
748

onlyif mysql # use DIV operator for integer division
query I rowsort label-2493
SELECT - - cor0.col1 * - ( - cor0.col0 + col0 ) DIV - 23 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2493
SELECT - - cor0.col1 * - ( - cor0.col0 + col0 ) / - 23 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - + cor0.col2 + 56 * - ( - col2 ) FROM tab0 cor0
----
1815
4510
55

query I rowsort
SELECT + - cor0.col2 * + col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT - col1 NOT IN ( col0 )
----

query I rowsort
SELECT DISTINCT col1 - col2 AS col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT - col0 - + tab0.col2 AS col1 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT - col2 + - col0 * col2 FROM tab2 WHERE + col2 NOT BETWEEN NULL AND col2
----

query I rowsort
SELECT - col2 + + col2 FROM tab2
----
0
0
0

query I rowsort
SELECT - col2 * col1 + + col0 * + tab0.col1 FROM tab0
----
-774
3298
637

query I rowsort
SELECT col1 * - col0 FROM tab2 WHERE NOT + col0 BETWEEN col1 AND - col2 * - col0 + col2
----
-217

query I rowsort
SELECT ALL col2 - + col0 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT tab2.col2 FROM tab2 WHERE col1 + + col2 * col1 BETWEEN NULL AND col0 * + col0 * col0
----

query I rowsort
SELECT ALL + tab0.col0 * + col2 FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2507
SELECT - col1 DIV - col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2507
SELECT - col1 / - col1 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL - col2 * + col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT col2 FROM tab0 WHERE NOT ( col1 + tab0.col1 ) NOT IN ( col1 )
----

query I rowsort
SELECT tab2.col0 AS col2 FROM tab2 WHERE NOT NULL IN ( + tab2.col0 + col1 )
----

query I rowsort
SELECT DISTINCT + col1 * col1 AS col1 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT - col1 * - col1 FROM tab0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 * + col2 + col2 col1 FROM tab0
----
1146
37
6895

query I rowsort
SELECT ALL + col1 FROM tab0 WHERE ( NULL ) NOT IN ( + tab0.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2515
SELECT + tab0.col1 DIV - col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2515
SELECT + tab0.col1 / - col0 FROM tab0
----
-1
-2
-3

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT IN ( tab2.col2 * + col2 )
----

query I rowsort
SELECT DISTINCT + col0 * + tab0.col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT col0 - col0 AS col1 FROM tab0
----
0
0
0

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL IN ( - col1 + tab0.col1 * + col0 )
----

query I rowsort
SELECT DISTINCT + col2 - col2 FROM tab1
----
0

query I rowsort
SELECT ALL col0 AS col2 FROM tab1 WHERE NOT ( NULL ) NOT IN ( + col2 )
----

query I rowsort
SELECT - ( + col0 ) * 33 AS col1 FROM tab1 AS cor0
----
-2112
-2640
-99

query I rowsort
SELECT + - 84 FROM tab2 AS cor0
----
-84
-84
-84

query I rowsort
SELECT DISTINCT ( + col1 ) + 87 AS col0 FROM tab2 AS cor0
----
104
118
146

query I rowsort
SELECT DISTINCT tab0.col0 * col0 * col2 + + col2 * - tab0.col2 * - col2 FROM tab0
----
1200890
1226
54945

query I rowsort
SELECT - tab1.col2 * + col1 + col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT + col0 * col1 FROM tab1 cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 62 col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

query I rowsort
SELECT ALL + cor0.col0 + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col0 * + ( col2 ) + + cor0.col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * ( 43 ) col0 FROM tab1 AS cor0
----
-129
-2752
-3440

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL - col1 * 58 FROM tab2 AS cor0
----
-1798
-3422
-986

query I rowsort
SELECT ALL + + cor0.col1 + + col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT col1 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + col1 * col1 col0 FROM tab1 AS cor0
----
110
182
702

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 * + CAST ( + col1 AS REAL ) * + col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0, tab0 AS cor0, tab2 AS cor1
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2540
SELECT DISTINCT - col2 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2540
SELECT DISTINCT - col2 * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + ( 23 ) FROM tab1 AS cor0
----
119
77
80

query I rowsort
SELECT ALL col1 * + ( - 77 + col1 * - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-1770
-19578
-3198

onlyif mysql # use DIV operator for integer division
query I rowsort label-2543
SELECT - + col1 DIV col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2543
SELECT - + col1 / col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT - col1 * + col1 + - ( + col2 ) FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT col2 * 21 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT ALL - - col1 * + col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query IIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab0, tab1 cor1
----
243 values hashing to 26173f1193178352de9a2e4ca7f09d53

query I rowsort
SELECT DISTINCT col0 * - 46 AS col0 FROM tab1
----
-138
-2944
-3680

query I rowsort
SELECT DISTINCT + + cor0.col0 - col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - col1 + - col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-6143
-6258
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + cor0.col0 * - col1 - cor0.col2 * col1 col2 FROM tab1 AS cor0
----
-1267
-1536
-2384

query I rowsort
SELECT ( + 4 ) + + col2 AS col1 FROM tab2 AS cor0
----
30
31
42

query I rowsort
SELECT 58 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( tab0.col0 ) col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT 43 FROM tab2, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2556
SELECT + 51 DIV col1 AS col0 FROM tab1 AS cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-2556
SELECT + 51 / col1 AS col0 FROM tab1 AS cor0
----
1
3
5

query I rowsort
SELECT DISTINCT cor0.col1 + 25 * - cor0.col2 FROM tab2, tab1 AS cor0
----
-1324
-1415
-2387

onlyif mysql # use DIV operator for integer division
query I rowsort label-2558
SELECT DISTINCT - 91 + - col2 DIV + cor0.col0 FROM tab0 AS cor0
----
-91
-92

skipif mysql # not compatible
query I rowsort label-2558
SELECT DISTINCT - 91 + - col2 / + cor0.col0 FROM tab0 AS cor0
----
-91
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-2559
SELECT ALL col0 DIV + col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2559
SELECT ALL col0 / + col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT DISTINCT - cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2561
SELECT - col1 + - col2 DIV col0 FROM tab1 AS cor0
----
-10
-14
-44

skipif mysql # not compatible
query I rowsort label-2561
SELECT - col1 + - col2 / col0 FROM tab1 AS cor0
----
-10
-14
-44

query I rowsort
SELECT ALL + + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2563
SELECT + col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2563
SELECT + col1 / + col2 AS col0 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT + ( col1 ) * + col0 * 57 FROM tab1 AS cor0
----
36480
4446
59280

query I rowsort
SELECT DISTINCT - 5 + - tab1.col1 AS col1 FROM tab1, tab0 AS cor0, tab2, tab0 AS cor1
----
-15
-18
-31

query I rowsort
SELECT ALL + col1 * - col0 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - col0 + col0 * 68 FROM tab1
----
201
4288
5360

query I rowsort
SELECT 75 + - col0 * 28 AS col0 FROM tab2
----
-121
-2109
-2137

query I rowsort
SELECT DISTINCT 81 * - col1 + + col1 FROM tab1 AS cor0
----
-1040
-2080
-800

query I rowsort
SELECT ALL - + col0 * col0 * 93 FROM tab0 cor0
----
-113925
-53568
-736653

query I rowsort
SELECT ALL + col1 * col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT 57 AS col0 FROM tab0
----
57
57
57

query I rowsort
SELECT - col2 * cor0.col2 + + col1 FROM tab0 AS cor0
----
-1003
-6633
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2574
SELECT + col2 DIV col1 + + col2 FROM tab2
----
26
27
40

skipif mysql # not compatible
query I rowsort label-2574
SELECT + col2 / col1 + + col2 FROM tab2
----
26
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-2575
SELECT DISTINCT + col2 * col0 + - col0 DIV - cor0.col2 FROM tab1 cor0
----
162
3649
7680

skipif mysql # not compatible
query I rowsort label-2575
SELECT DISTINCT + col2 * col0 + - col0 / - cor0.col2 FROM tab1 cor0
----
162
3649
7680

query I rowsort
SELECT + - col0 + col2 * + col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT ALL - + col0 * cor0.col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT col0 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + col1 * - col2 AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT col2 * - col2 AS col0 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - + col2 * col2 + + cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
-2816
-2907
847

query I rowsort
SELECT DISTINCT col1 + col1 * + col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + col1 * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2585
SELECT DISTINCT col1 DIV col1 AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2585
SELECT DISTINCT col1 / col1 AS col2 FROM tab1
----
1

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + col2 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + col1 + col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + col1 + + col2 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col1 + + 90 FROM tab0
----
176
181
187

query I rowsort
SELECT ( col2 ) + - col0 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2592
SELECT DISTINCT col1 DIV ( col2 ) + + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2592
SELECT DISTINCT col1 / ( col2 ) + + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col0 * col0 AS REAL ) + col1 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT + ( - col0 ) + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2595
SELECT ALL + CAST( NULL AS DECIMAL ) + col2 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2595
SELECT ALL + CAST ( NULL AS REAL ) + col2 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - col1 ) + col2 * col2 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + ( col1 ) * - col0 + - col0 AS col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT ALL col1 + + col0 * + col0 AS col1 FROM tab1 AS cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 * cor0.col1 + + col2 col0 FROM tab0 AS cor0
----
1065
1165
1174

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2600
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - 9 * col0 * - col2 col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2600
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - 9 * col0 * - col2 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + - col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - 87 AS col1 FROM tab2 AS cor0
----
-87
-87
-87

query I rowsort
SELECT DISTINCT - cor0.col1 - - col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT cor0.col1 + + col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - - col0 + - col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL col1 * + col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + cor0.col0 * col0 + + col2 AS col1 FROM tab2 cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2608
SELECT DISTINCT + 57 DIV cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2608
SELECT DISTINCT + 57 / cor0.col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - 60 + + col2 * col0 FROM tab2 AS cor0
----
129
1968
2942

query I rowsort
SELECT DISTINCT - 92 + col2 * - col1 FROM tab0 AS cor0
----
-189
-2930
-7554

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + - col0 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT col1 + + 15 FROM tab2
----
32
46
74

query I rowsort
SELECT col2 + tab1.col0 AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT - 70 + - col0 FROM tab2
----
-148
-149
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-2617
SELECT col2 DIV tab1.col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2617
SELECT col2 / tab1.col1 FROM tab1
----
2
5
7

query I rowsort
SELECT - cor0.col2 * col1 + + col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT col0 - + 79 AS col1 FROM tab2
----
-1
-72
0

query I rowsort
SELECT DISTINCT tab0.col1 * + tab0.col0 FROM tab0, tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT 71 AS col1 FROM tab1
----
71
71
71

query I rowsort
SELECT ALL ( col2 ) * tab2.col1 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * ( col0 + + col0 ) col1 FROM tab2 cor0
----
-378
-4056
-6004

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2624
SELECT - CAST( col0 AS SIGNED ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2624
SELECT - CAST ( col0 AS INTEGER ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 * - tab0.col1 + col1 * col1 col1 FROM tab0
----
18818
251464
687323

query I rowsort
SELECT DISTINCT - ( + col1 * - tab1.col2 ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT - ( col1 ) AS col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + ( - col0 ) FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT + + cor0.col1 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to c6425afc100dd55de8d45dec18c469ea

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2630
SELECT ALL - CAST( col2 AS SIGNED ) col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2630
SELECT ALL - CAST ( col2 AS INTEGER ) col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT 84 - + col1 FROM tab2 AS cor0
----
25
53
67

query I rowsort
SELECT + col1 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col0 * + col2 + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - - col1 * + col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 col0 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2636
SELECT + 95 DIV - tab1.col2 AS col0 FROM tab1
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2636
SELECT + 95 / - tab1.col2 AS col0 FROM tab1
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2637
SELECT DISTINCT - 44 * + 85 / - col2 + - CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2637
SELECT DISTINCT - 44 * + 85 / - col2 + - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2638
SELECT CAST( - col0 AS SIGNED ) * col2 FROM tab1
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2638
SELECT CAST ( - col0 AS INTEGER ) * col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT - col2 + col0 * - col1 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT + col0 - cor0.col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - - col0 + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2642
SELECT CAST( col1 AS SIGNED ) * tab2.col2 AS col0 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-2642
SELECT CAST ( col1 AS INTEGER ) * tab2.col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT cor0.col2 - cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 3b143560120db39ddcee311b43b28291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + 34 col0 FROM tab1 AS cor0
----
340
442
884

query I rowsort
SELECT col2 + - col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + - ( 94 ) * col1 AS col0 FROM tab1 AS cor0
----
-1318
-2498
-997

query I rowsort
SELECT + col0 * + ( col1 ) FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2648
SELECT - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2648
SELECT - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + ( - cor0.col1 ) * - cor0.col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + + cor0.col2 * - 59 AS col1 FROM tab1 AS cor0
----
-3186
-3363
-5664

query I rowsort
SELECT ALL - - cor0.col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2652
SELECT DISTINCT + col1 DIV - col1 AS col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2652
SELECT DISTINCT + col1 / - col1 AS col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - cor0.col0 * - 16 FROM tab0 AS cor0
----
1424
384
560

query I rowsort
SELECT ALL + col2 * + ( col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + col2 * + 70 * 59 FROM tab1 AS cor0
----
223020
235410
396480

query I rowsort
SELECT DISTINCT - 21 * + col2 * col1 + + col0 + + tab2.col0 * + 26 FROM tab2
----
-11433
-17388
-30108

query I rowsort
SELECT tab1.col0 * col1 - col2 * col1 AS col1 FROM tab1
----
-1326
-208
70

query I rowsort
SELECT col0 + col0 AS col2 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2659
SELECT - - col1 DIV + 30 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2659
SELECT - - col1 / + 30 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 + col0 AS col2 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2661
SELECT - + col1 DIV col1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2661
SELECT - + col1 / col1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col1 + + col1 * + col2 AS col0 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col2 col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a464155f1f6cb07f325fb0d7a4ec61f2

query I rowsort
SELECT + 62 FROM tab0 AS cor0
----
62
62
62

query I rowsort
SELECT ALL 89 FROM tab0, tab2 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT 87 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT ALL - 23 * - 49 FROM tab0 AS cor0
----
1127
1127
1127

query I rowsort
SELECT + + ( - cor0.col1 ) * col2 * 48 FROM tab2 cor0
----
-31008
-40176
-73632

query I rowsort
SELECT ALL - 26 * - ( col2 * col2 + col1 ) AS col1 FROM tab1 AS cor0
----
239954
76492
84734

query I rowsort
SELECT ALL + 27 + col1 AS col0 FROM tab2 AS cor0
----
44
58
86

query I rowsort
SELECT DISTINCT 77 * - col1 + + col1 AS col1 FROM tab2 AS cor0
----
-1292
-2356
-4484

query I rowsort
SELECT 16 * cor0.col1 FROM tab0 AS cor0
----
1376
1456
1552

onlyif mysql # use DIV operator for integer division
query I rowsort label-2674
SELECT cor0.col0 DIV - col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2674
SELECT cor0.col0 / - col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col1 * - ( 10 * - tab1.col1 ) FROM tab1
----
-1000
-1690
-6760

query I rowsort
SELECT + + col1 + - col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT + col2 * - 10 FROM tab2 AS cor0
----
-260
-270
-380

query I rowsort
SELECT + col0 - 43 FROM tab2
----
-36
35
36

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT + col0 * + col2 + + 75 FROM tab1
----
237
3723
7755

query I rowsort
SELECT DISTINCT + 65 AS col2 FROM tab1 AS cor0
----
65

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2684
SELECT col0 DIV + cor0.col1 + 64 AS col2 FROM tab2 AS cor0
----
64
65
68

skipif mysql # not compatible
query I rowsort label-2684
SELECT col0 / + cor0.col1 + 64 AS col2 FROM tab2 AS cor0
----
64
65
68

query I rowsort
SELECT + + col0 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2686
SELECT DISTINCT + col1 DIV 48 + - col0 * col1 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-2686
SELECT DISTINCT + col1 / 48 + - col0 * col1 FROM tab1
----
-1040
-640
-78

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT + + col0 * - col2 + col2 AS col1 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + tab0.col1 FROM tab0, tab1, tab1 AS cor0
----
86
91
97

query I rowsort
SELECT col0 + - col0 FROM tab1
----
0
0
0

query I rowsort
SELECT - tab0.col0 * 4 + col0 FROM tab0
----
-105
-267
-72

query I rowsort
SELECT + cor0.col1 * - 52 + col1 * - col0 + col0 * + col0 * - col0 FROM tab1 AS cor0
----
-1457
-263304
-513716

query I rowsort
SELECT - cor0.col2 + + cor0.col1 * col0 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + col0 + + 75 AS col2 FROM tab0 AS cor0
----
110
164
99

query I rowsort
SELECT - cor0.col1 + col2 AS col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + + col0 AS col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + + col0 + - col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + - 6 * col1 FROM tab1 AS cor0
----
-156
-60
-78

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT col1 * + tab0.col0 FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 * - col0 + CAST ( + 84 AS REAL ) FROM tab1 cor0
----
-3564
-7596
-78

query I rowsort
SELECT + + cor0.col1 + - col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - col0 * cor0.col1 + col2 AS col2 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT ALL 68 - col1 FROM tab2 AS cor0
----
37
51
9

query I rowsort
SELECT - 93 + col0 FROM tab1 AS cor0
----
-13
-29
-90

query I rowsort
SELECT ALL col2 + - col1 + - col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + - col2 * - col1 + - col2 - col0 AS col0 FROM tab1 AS cor0
----
1072
1347
449

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - col0 * col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL 52 * + col2 AS col0 FROM tab2 AS cor0
----
1352
1404
1976

query I rowsort
SELECT DISTINCT + + cor0.col2 AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + col1 + col1 * - 62 + - col2 FROM tab2 AS cor0
----
-1075
-1918
-3625

query I rowsort
SELECT - - 19 AS col1 FROM tab2 AS cor0
----
19
19
19

query I rowsort
SELECT DISTINCT + + col0 + col1 AS col0 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 23 col2 FROM tab2 cor0
----
101
102
30

query I rowsort
SELECT DISTINCT - + col0 + 68 * col2 FROM tab0 AS cor0
----
2220
33
5487

query I rowsort
SELECT DISTINCT cor0.col0 + - col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - col0 * - col0 * col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT DISTINCT col1 * - col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - - cor0.col0 + 47 AS col1 FROM tab2 AS cor0
----
125
126
54

query I rowsort
SELECT - col0 + - col2 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT col1 + tab1.col1 FROM tab1
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2723
SELECT - - CAST( NULL AS SIGNED ) + 57 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2723
SELECT - - CAST ( NULL AS INTEGER ) + 57 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT ( col2 ) * + 97 FROM tab2
----
2522
2619
3686

query I rowsort
SELECT 7 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT + col0 * col2 + col0 * + ( col0 * - col1 ) AS col1 FROM tab0 AS cor0
----
-118790
-48744
-713513

query I rowsort
SELECT DISTINCT + 25 * - col2 AS col0 FROM tab0 AS cor0
----
-2050
-25
-825

query I rowsort
SELECT ALL + 27 + 48 FROM tab1 AS cor0
----
75
75
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2729
SELECT + ( cor0.col2 ) DIV col0 + col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-2729
SELECT + ( cor0.col2 ) / col0 + col0 FROM tab1 AS cor0
----
21
64
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2730
SELECT CAST( - ( - col0 ) AS SIGNED ) * 22 + + col1 * col0 DIV - 52 + col1 AS col0 FROM tab1 AS cor0
----
1406
1753
91

skipif mysql # not compatible
query I rowsort label-2730
SELECT CAST ( - ( - col0 ) AS INTEGER ) * 22 + + col1 * col0 / - 52 + col1 AS col0 FROM tab1 AS cor0
----
1406
1753
91

query I rowsort
SELECT ALL + 82 FROM tab2 cor0
----
82
82
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2733
SELECT + col0 DIV + 79 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2733
SELECT + col0 / + 79 FROM tab0
----
0
0
1

query I rowsort
SELECT DISTINCT 21 * - col0 AS col0 FROM tab2
----
-147
-1638
-1659

query I rowsort
SELECT + 96 - + tab0.col0 * col1 AS col2 FROM tab0
----
-1968
-3299
-8003

query I rowsort
SELECT + 85 - 23 AS col2 FROM tab0
----
62
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2737
SELECT - tab1.col0 DIV + ( + tab1.col2 ) - - col2 AS col1 FROM tab1
----
54
56
96

skipif mysql # not compatible
query I rowsort label-2737
SELECT - tab1.col0 / + ( + tab1.col2 ) - - col2 AS col1 FROM tab1
----
54
56
96

query I rowsort
SELECT + 43 * col2 * - tab0.col0 AS col1 FROM tab0
----
-1505
-313814
-34056

query I rowsort
SELECT tab2.col1 + + col1 AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL + 28 + + col0 AS col0 FROM tab0 AS cor0
----
117
52
63

query I rowsort
SELECT + + 5 FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT DISTINCT - col0 + 73 AS col0 FROM tab0
----
-16
38
49

query I rowsort
SELECT DISTINCT - col0 * + col1 * col0 + col1 AS col2 FROM tab0
----
-118728
-49450
-720720

query I rowsort
SELECT DISTINCT 37 + - col0 FROM tab1
----
-27
-43
34

query I rowsort
SELECT ALL col1 + - col2 + col0 FROM tab0
----
131
77
98

query I rowsort
SELECT DISTINCT + 61 AS col0 FROM tab1, tab1 AS cor0
----
61

query I rowsort
SELECT ( 51 + + col2 ) AS col0 FROM tab2
----
77
78
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2748
SELECT col1 + 90 + - tab0.col0 DIV col2 FROM tab0
----
152
176
180

skipif mysql # not compatible
query I rowsort label-2748
SELECT col1 + 90 + - tab0.col0 / col2 FROM tab0
----
152
176
180

query I rowsort
SELECT - - col0 - + col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT 53 + 14 FROM tab1
----
67
67
67

query I rowsort
SELECT ALL - 6 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT - 59 + + col2 + - col2 FROM tab0 AS cor0
----
-59
-59
-59

query I rowsort
SELECT - 77 FROM tab0, tab2 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

query I rowsort
SELECT DISTINCT + 43 * col0 + col1 FROM tab0
----
1118
1602
3918

query I rowsort
SELECT ALL - col1 + col1 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor1.col2 col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT + 43 * - cor1.col2 + - 24 AS col2 FROM tab1, tab2 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to cea1e54e6d657dec4d4448f451304328

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab2 cor0, tab2 AS cor1
----
972 values hashing to f94a4a64ac54a61fc21f78e2b831ebee

query I rowsort
SELECT DISTINCT ( - tab2.col1 ) AS col1 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT - ( + col0 ) FROM tab0
----
-24
-35
-89

query I rowsort
SELECT + tab2.col1 + - col0 FROM tab2
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 28 col2 FROM tab0 AS cor0
----
28

query I rowsort
SELECT - + col1 * + col0 + cor0.col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL - + ( + col0 ) * cor0.col0 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-2766
SELECT ALL - col0 + col0 * 61 DIV col0 AS col0 FROM tab0 cor0
----
-28
26
37

skipif mysql # not compatible
query I rowsort label-2766
SELECT ALL - col0 + col0 * 61 / col0 AS col0 FROM tab0 cor0
----
-28
26
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 18 + + col1 * col1 col1 FROM tab0 AS cor0
----
7378
8263
9391

query I rowsort
SELECT + 42 * col0 AS col0 FROM tab0
----
1008
1470
3738

query I rowsort
SELECT - 58 FROM tab0 AS cor0
----
-58
-58
-58

query I rowsort
SELECT col2 * col2 + 22 FROM tab0 AS cor0
----
1111
23
6746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2771
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab2, tab1 AS cor0, tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2771
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab2, tab1 AS cor0, tab1
----
NULL

query I rowsort
SELECT - col2 * 39 * col2 + + col2 FROM tab1
----
-113670
-126654
-359328

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 20 FROM tab0, tab1 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT DISTINCT - + col2 AS col0 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT - cor0.col0 * - col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - 80 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT ALL + + col0 + - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT col0 * - col2 * col0 AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT + col0 + + 27 * + cor0.col0 FROM tab0 AS cor0
----
2492
672
980

query I rowsort
SELECT ALL - 72 FROM tab1 cor0
----
-72
-72
-72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2782
SELECT ALL - - CAST( NULL AS SIGNED ) * 60 col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2782
SELECT ALL - - CAST ( NULL AS INTEGER ) * 60 col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 95 AS col2 FROM tab2 cor0
----
95
95
95

query I rowsort
SELECT ALL + 74 FROM tab1 AS cor0
----
74
74
74

query I rowsort
SELECT - col2 - col1 * col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT + + col2 * col2 + - cor0.col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + col0 + col0 * col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL - col1 * + col0 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-2789
SELECT DISTINCT ( + col1 ) + col1 DIV + col2 + - col1 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2789
SELECT DISTINCT ( + col1 ) + col1 / + col2 + - col1 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL col1 + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT ( col1 ) - cor0.col0 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL - 85 + col0 * - col2 + - col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1003
-2789
-4531

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col1 AS REAL ) + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT + col1 * col1 + col1 * + ( col0 ) + + col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
12298
12901
23842

query I rowsort
SELECT ALL - ( + col1 ) * col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2796
SELECT + CAST( NULL AS SIGNED ) - - col0 * + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2796
SELECT + CAST ( NULL AS INTEGER ) - - col0 * + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 + 88 AS col2 FROM tab2 AS cor0
----
105
119
147

query I rowsort
SELECT ALL - col1 * + col0 + - col2 * 33 FROM tab2 AS cor0
----
-1108
-2597
-5460

query I rowsort
SELECT col1 * + 45 + col1 * col2 FROM tab0 AS cor0
----
11557
4462
6708

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2800
SELECT DISTINCT - CAST( NULL AS SIGNED ) + 8 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2800
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 8 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + + col2 - cor0.col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ( col2 ) + col0 + 14 FROM tab2 AS cor0
----
118
131
48

query I rowsort
SELECT ALL ( 44 ) + + col2 FROM tab0 AS cor0
----
126
45
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col0 col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT col0 * + ( + col0 + - col2 ) AS col2 FROM tab2 AS cor0
----
-140
3239
4056

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * ( col0 ) col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT - col2 * - col1 AS col0 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2808
SELECT + + col0 DIV + col1 FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2808
SELECT + + col0 / + col1 FROM tab1 cor0
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2809
SELECT ALL + col2 DIV col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2809
SELECT ALL + col2 / col0 FROM tab0
----
0
0
1

query I rowsort
SELECT ALL col2 * + 63 FROM tab2
----
1638
1701
2394

query I rowsort
SELECT ALL 77 FROM tab2, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT DISTINCT tab0.col1 * col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - tab0.col0 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 97b43fbe79eecd0bc6921392403b666d

onlyif mysql # use DIV operator for integer division
query I rowsort label-2815
SELECT - - cor0.col2 DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2815
SELECT - - cor0.col2 / col0 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 13 col2 FROM tab0, tab2 AS cor0
----
13

query I rowsort
SELECT - tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2818
SELECT ALL cor0.col0 DIV 65 AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-2818
SELECT ALL cor0.col0 / 65 AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT ALL - 65 FROM tab0
----
-65
-65
-65

query I rowsort
SELECT - tab0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT - col1 * col2 + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT col2 + - col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + - 0 * col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT ( 44 ) AS col2 FROM tab2
----
44

query I rowsort
SELECT - col1 * 27 + + col0 AS col2 FROM tab1 AS cor0
----
-206
-271
-699

onlyif mysql # use DIV operator for integer division
query I rowsort label-2826
SELECT DISTINCT + ( - col1 ) DIV col1 + col0 col1 FROM tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2826
SELECT DISTINCT + ( - col1 ) / col1 + col0 col1 FROM tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 70 col2 FROM tab0 cor0
----
105
159
94

query I rowsort
SELECT - 83 FROM tab0 AS cor0
----
-83
-83
-83

query I rowsort
SELECT col1 * cor0.col2 + + ( col1 ) * cor0.col0 FROM tab1 cor0
----
1210
1482
2288

query I rowsort
SELECT col0 + - cor0.col0 * + ( cor0.col2 ) FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - 64 AS col0 FROM tab0 cor0
----
-64
-64
-64

query I rowsort
SELECT DISTINCT ( cor0.col0 ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - col1 * - col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2834
SELECT + col0 DIV col0 AS col2 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2834
SELECT + col0 / col0 AS col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - 36 FROM tab0 cor0
----
-36
-36
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2836
SELECT ( ( tab0.col0 ) ) DIV col0 + col2 AS col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2836
SELECT ( ( tab0.col0 ) ) / col0 + col2 AS col2 FROM tab0
----
2
34
83

query I rowsort
SELECT - ( ( + col2 ) ) + - tab1.col1 + - 63 FROM tab1
----
-130
-143
-172

query I rowsort
SELECT col2 + col1 * + col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT - - col0 + col0 AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - + 61 FROM tab0 AS cor0
----
-61
-61
-61

query I rowsort
SELECT - cor0.col0 * col0 + - ( col0 ) AS col1 FROM tab0 cor0
----
-1260
-600
-8010

query I rowsort
SELECT 66 + + col2 FROM tab1 AS cor0
----
120
123
162

query I rowsort
SELECT - col0 + col1 * + col1 FROM tab2
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2844
SELECT - col0 DIV col1 + - ( - 77 ) FROM tab2
----
73
76
77

skipif mysql # not compatible
query I rowsort label-2844
SELECT - col0 / col1 + - ( - 77 ) FROM tab2
----
73
76
77

query I rowsort
SELECT col1 * col1 + 89 FROM tab2
----
1050
3570
378

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2846
SELECT DISTINCT + 59 + col1 / + CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2846
SELECT DISTINCT + 59 + col1 / + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT 71 + col2 AS col0 FROM tab2
----
109
97
98

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab1 cor0, tab1 cor1
----
972 values hashing to fe55095fff3a5ecc2f113d14a8c6f823

query I rowsort
SELECT DISTINCT - - 87 * + col1 FROM tab0 AS cor0
----
7482
7917
8439

query I rowsort
SELECT DISTINCT 79 + col2 FROM tab0 AS cor0
----
112
161
80

skipif mysql # not compatible
query I rowsort
SELECT + col1 * + col2 * - CAST ( col0 AS REAL ) - + col0 AS col0 FROM tab1 AS cor0
----
-36544
-4215
-99920

query I rowsort
SELECT 35 + col2 FROM tab1 cor0
----
131
89
92

query I rowsort
SELECT + - col1 + cor0.col1 * + cor0.col0 * 57 AS col1 FROM tab0 cor0
----
117562
193418
461552

query I rowsort
SELECT DISTINCT col2 + - 74 * cor0.col1 FROM tab2 AS cor0
----
-1220
-2267
-4340

query I rowsort
SELECT ALL + + col1 * col0 + col1 + + col0 AS col2 FROM tab0 AS cor0
----
2174
3527
8279

query I rowsort
SELECT - col1 * + col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - cor0.col2 + - ( col2 ) * col1 AS col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 + 0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL col1 * - col0 + - 18 * col1 FROM tab0 AS cor0
----
-3612
-5141
-9737

onlyif mysql # use DIV operator for integer division
query I rowsort label-2860
SELECT col0 + - 8 DIV 78 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2860
SELECT col0 + - 8 / 78 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col1 * + cor0.col1 + - col2 * - col1 AS col0 FROM tab0 AS cor0
----
10234
15743
9506

query I rowsort
SELECT DISTINCT col2 + + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL col1 + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL + 61 AS col0 FROM tab0
----
61
61
61

query I rowsort
SELECT col0 + - col1 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT cor0.col0 * ( - col1 ) - cor0.col0 * + col0 * col2 FROM tab0 AS cor0
----
-21072
-4620
-657621

query I rowsort
SELECT DISTINCT col1 * + col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2868
SELECT ALL + + col1 * CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2868
SELECT ALL + + col1 * CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 96 FROM tab0, tab1, tab2 cor0
----
96

query I rowsort
SELECT ( - col2 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - + 63 * + col1 AS col0 FROM tab1 AS cor0
----
-1638
-630
-819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2872
SELECT + ( - 60 ) + col0 - + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2872
SELECT + ( - 60 ) + col0 - + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 3 - col0 * col1 FROM tab2 AS cor0
----
-1346
-220
-4605

query I rowsort
SELECT - 54 + - col1 * - col0 FROM tab1 AS cor0
----
24
586
986

query I rowsort
SELECT + col2 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col1 AS REAL ) * + cor0.col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - - col1 - + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + ( - col0 ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + 6 * - 78 AS col2 FROM tab1 AS cor0
----
-468
-468
-468

query I rowsort
SELECT DISTINCT + + col2 * cor0.col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 64 col1 FROM tab2 AS cor0
----
448
4992
5056

query I rowsort
SELECT ALL - col1 + - 6 FROM tab2 AS cor0
----
-23
-37
-65

query I rowsort
SELECT - 9 FROM tab1, tab0 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

query I rowsort
SELECT 72 AS col0 FROM tab2
----
72
72
72

query I rowsort
SELECT ALL + + 40 FROM tab0 AS cor0
----
40
40
40

query I rowsort
SELECT col2 * col0 + + 89 AS col1 FROM tab2 AS cor0
----
2117
278
3091

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
86
91
97

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

onlyif mysql # use DIV operator for integer division
query I rowsort label-2889
SELECT + col1 * ( + col0 ) DIV col0 + col2 * + col0 FROM tab1
----
188
3658
7693

skipif mysql # not compatible
query I rowsort label-2889
SELECT + col1 * ( + col0 ) / col0 + col2 * + col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT + 76 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col1 * col1 + 48 col1 FROM tab1 AS cor0
----
1048
17624
2245

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab0 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to c569638e8a09ff819458d62ddbde994c

query I rowsort
SELECT + col1 + tab1.col0 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT tab1.col0 + col0 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT col2 * + col2 + col2 * col2 AS col0 FROM tab2
----
1352
1458
2888

query I rowsort
SELECT DISTINCT col0 + col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT + - 45 AS col0 FROM tab0 AS cor0
----
-45

query I rowsort
SELECT + 10 * col0 FROM tab1 AS cor0
----
30
640
800

query I rowsort
SELECT ( + cor1.col1 ) AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col1 * 45 FROM tab0
----
-3870
-4095
-4365

query I rowsort
SELECT col0 * ( + col2 + + tab0.col2 ) FROM tab0
----
14596
1584
70

query I rowsort
SELECT - col1 + - ( - col2 ) AS col0 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL - ( 55 ) FROM tab0, tab1 AS cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

query I rowsort
SELECT col2 * ( col2 ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT cor0.col0 + + ( + 22 ) + col1 AS col1 FROM tab1 cor0
----
115
51
96

query I rowsort
SELECT col2 + - col0 * - tab2.col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT DISTINCT col0 * - col2 + + col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT ALL + col0 + 63 * + tab2.col0 FROM tab2
----
448
4992
5056

query I rowsort
SELECT DISTINCT cor0.col0 * + 8 AS col0 FROM tab2 AS cor0
----
56
624
632

query I rowsort
SELECT ALL - ( col1 ) FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2911
SELECT - col2 * 32 + cor0.col0 DIV ( col1 ) + col0 col1 FROM tab1 AS cor0
----
-1725
-1754
-2986

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2911
SELECT - col2 * 32 + cor0.col0 / ( col1 ) + col0 col1 FROM tab1 AS cor0
----
-1725
-1754
-2986

query I rowsort
SELECT DISTINCT + + col1 * cor0.col0 + - col0 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2913
SELECT ALL CAST( NULL AS SIGNED ) + - 44 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2913
SELECT ALL CAST ( NULL AS INTEGER ) + - 44 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( + col2 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + 3 * col1 FROM tab1 cor0
----
30
39
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2916
SELECT - + col1 DIV col0 + col2 * col1 FROM tab2 AS cor0
----
1534
646
833

skipif mysql # not compatible
query I rowsort label-2916
SELECT - + col1 / col0 + col2 * col1 FROM tab2 AS cor0
----
1534
646
833

query I rowsort
SELECT ALL + cor0.col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - + cor0.col2 * + 34 AS col1 FROM tab1 AS cor0
----
-1836
-1938
-3264

onlyif mysql # use DIV operator for integer division
query I rowsort label-2919
SELECT DISTINCT + col2 + + 36 DIV cor0.col1 FROM tab2 AS cor0
----
26
28
40

skipif mysql # not compatible
query I rowsort label-2919
SELECT DISTINCT + col2 + + 36 / cor0.col1 FROM tab2 AS cor0
----
26
28
40

query I rowsort
SELECT ALL - - 80 * col0 AS col1 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT - col0 + - 69 AS col2 FROM tab1 AS cor0
----
-133
-149
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 47 col1 FROM tab0 AS cor0
----
47

query I rowsort
SELECT 82 + col1 FROM tab2 cor0
----
113
141
99

query I rowsort
SELECT DISTINCT + 99 + 92 * - col2 FROM tab2 AS cor0
----
-2293
-2385
-3397

query I rowsort
SELECT DISTINCT col1 - tab1.col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT tab0.col0 * + 87 FROM tab0, tab1 AS cor0
----
9 values hashing to 43e812f295563e16ec5f372043a8e684

query I rowsort
SELECT - 90 * col1 FROM tab2 AS cor0
----
-1530
-2790
-5310

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 60 + - cor0.col1 * 8 col1 FROM tab0 AS cor0
----
-748
-788
-836

query I rowsort
SELECT ALL 40 + col1 AS col0 FROM tab0 AS cor0
----
126
131
137

query I rowsort
SELECT ALL ( + col1 ) + + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT 61 * col0 FROM tab1 AS cor0
----
183
3904
4880

query I rowsort
SELECT - - ( col1 ) * cor0.col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - col1 - col0 * ( + 57 ) FROM tab1 AS cor0
----
-197
-3658
-4573

query I rowsort
SELECT + + col2 + + ( col1 ) * - col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT cor0.col2 * - 82 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2620
-6633
15

query I rowsort
SELECT + - col1 - col0 * + col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL + col1 * cor0.col2 + col1 * cor0.col2 FROM tab0 cor0
----
14924
194
5676

query I rowsort
SELECT DISTINCT - col1 * 89 AS col0 FROM tab1 AS cor0
----
-1157
-2314
-890

query I rowsort
SELECT tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT + col0 + col2 + 9 AS col0 FROM tab0 AS cor0
----
180
45
66

query I rowsort
SELECT ALL - cor0.col0 * + 31 + 44 AS col1 FROM tab2 AS cor0
----
-173
-2374
-2405

query I rowsort
SELECT col0 + + ( col2 ) AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL 40 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT + col0 + + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - cor0.col1 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col0 + col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + col1 * col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2948
SELECT ALL + col0 + - col2 DIV 7 FROM tab0 AS cor0
----
20
35
78

skipif mysql # not compatible
query I rowsort label-2948
SELECT ALL + col0 + - col2 / 7 FROM tab0 AS cor0
----
20
35
78

query I rowsort
SELECT + - cor0.col2 * - ( + col0 ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - - col1 + + ( + col0 ) * + col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + col1 * - cor0.col1 AS col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT + cor0.col1 * ( col1 ) AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - col0 + 45 FROM tab2 AS cor0
----
-33
-34
38

query I rowsort
SELECT - cor0.col0 * 7 AS col2 FROM tab2 AS cor0
----
-49
-546
-553

query I rowsort
SELECT DISTINCT + col0 * 72 AS col2 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT + col1 * - cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 42 - cor0.col1 * col1 col0 FROM tab0 AS cor0
----
-11725
-8782
-9451

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2958
SELECT ALL col1 / - CAST( NULL AS SIGNED ) + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2958
SELECT ALL col1 / - CAST ( NULL AS INTEGER ) + col0 FROM tab2
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2, tab1 cor2
----
3645 values hashing to ae08f1949fd59e00b049f28175217e60

query I rowsort
SELECT - + cor0.col2 + + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col2 + col2 * + col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT ALL - col2 + col0 * + ( col2 ) + col0 * - 19 AS col2 FROM tab0
----
-631
303
5525

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 16 col2 FROM tab2 AS cor0
----
16

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to ea1a922b7fccb9d184b31eb4689e063b

query I rowsort
SELECT + col0 * - col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + col1 * - col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2967
SELECT + 95 * col0 * + CAST( col0 AS SIGNED ) AS col2 FROM tab0 cor0
----
116375
54720
752495

skipif mysql # not compatible
query I rowsort label-2967
SELECT + 95 * col0 * + CAST ( col0 AS INTEGER ) AS col2 FROM tab0 cor0
----
116375
54720
752495

query I rowsort
SELECT DISTINCT col1 * + col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT col0 + - col0 * - col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + + col0 * col1 - col0 AS col1 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2971
SELECT ALL - - ( + cor0.col0 ) * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2971
SELECT ALL - - ( + cor0.col0 ) * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 - col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ( - 54 ) AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

query I rowsort
SELECT ALL 88 FROM tab2
----
88
88
88

query I rowsort
SELECT DISTINCT ( col2 ) * ( col1 ) AS col1 FROM tab2
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2976
SELECT DISTINCT - col2 * col0 * CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2976
SELECT DISTINCT - col2 * col0 * CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2977
SELECT col1 * col0 DIV - col0 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-2977
SELECT col1 * col0 / - col0 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort
SELECT ( cor0.col2 ) * - col2 + CAST ( + 9 AS REAL ) + col2 FROM tab2 AS cor0
----
-1397
-641
-693

query I rowsort
SELECT - + col0 * col0 * + col2 AS col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - col0 + - col2 + col1 FROM tab2 AS cor0
----
-100
-3
-45

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query I rowsort
SELECT - tab2.col1 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT ALL - 80 FROM tab0, tab0 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT ALL col1 * + 55 AS col2 FROM tab0
----
4730
5005
5335

query I rowsort
SELECT DISTINCT 60 FROM tab2
----
60

query I rowsort
SELECT ALL - ( + col1 ) FROM tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col0 FROM tab0, tab0 cor0, tab1 AS cor1
----
-24
-35
-89

query I rowsort
SELECT 21 FROM tab2, tab1 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2989
SELECT DISTINCT + col0 DIV col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2989
SELECT DISTINCT + col0 / col1 FROM tab2
----
0
1
4

query I rowsort
SELECT - 8 FROM tab0
----
-8
-8
-8

query I rowsort
SELECT DISTINCT col0 * + col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT 40 FROM tab0
----
40
40
40

query I rowsort
SELECT col1 + + col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT col0 + - col0 AS col2 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2995
SELECT + col0 DIV + tab2.col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2995
SELECT + col0 / + tab2.col1 FROM tab2
----
0
1
4

query I rowsort
SELECT DISTINCT col1 * + col1 + col2 AS col0 FROM tab2
----
327
3507
988

query I rowsort
SELECT - col0 * + col2 - + col2 * cor0.col2 FROM tab0 AS cor0
----
-14022
-1881
-36

query I rowsort
SELECT - + col0 * - col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 3 + 14 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3000
SELECT 17 DIV 51 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-3000
SELECT 17 / 51 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT + ( + col0 ) FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3002
SELECT col0 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3002
SELECT col0 / - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + col2 * col2 AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - - col0 * + col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3005
SELECT col0 DIV tab1.col1 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-3005
SELECT col0 / tab1.col1 FROM tab1
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3006
SELECT - 72 DIV - col2 FROM tab0
----
0
2
72

skipif mysql # not compatible
query I rowsort label-3006
SELECT - 72 / - col2 FROM tab0
----
0
2
72

query I rowsort
SELECT - - col0 * 15 * col1 FROM tab1 AS cor0
----
1170
15600
9600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + col2 * - 95 FROM tab1 AS cor0
----
5130
5415
9120

query I rowsort
SELECT + col1 - - ( - 60 ) FROM tab0 AS cor0
----
26
31
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-3011
SELECT ALL col2 DIV col1 + - col2 DIV col2 + col1 FROM tab1 AS cor0
----
14
19
27

skipif mysql # not compatible
query I rowsort label-3011
SELECT ALL col2 / col1 + - col2 / col2 + col1 FROM tab1 AS cor0
----
14
19
27

query I rowsort
SELECT + col0 + ( + col1 + - col2 ) * col2 FROM tab0 AS cor0
----
131
1773
827

query I rowsort
SELECT DISTINCT col0 + + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + + col1 AS col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT 40 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT + col2 * col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ALL col0 - - 11 * + col0 FROM tab0
----
1068
288
420

query I rowsort
SELECT ALL 50 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT - 65 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

query I rowsort
SELECT - col1 + - col0 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col0 * - 55 - 55 FROM tab1
----
110
3465
4345

query I rowsort
SELECT col2 + - 18 * + col2 AS col0 FROM tab2
----
-442
-459
-646

query I rowsort
SELECT - col1 + - 49 - col0 FROM tab1
----
-123
-142
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3024
SELECT + - CAST( NULL AS DECIMAL ) + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3024
SELECT + - CAST ( NULL AS REAL ) + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + + col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT col2 AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ( 95 ) * col2 + - col1 FROM tab0 AS cor0
----
-2
3049
7699

query I rowsort
SELECT ALL + 35 + - col1 + - col2 AS col1 FROM tab2
----
-20
-23
-50

query I rowsort
SELECT - 87 AS col0 FROM tab0 AS cor0
----
-87
-87
-87

query I rowsort
SELECT col0 * 55 + col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT - col0 + 49 FROM tab1 cor0
----
-15
-31
46

query I rowsort
SELECT ALL - col1 * + col2 + col1 - + col0 AS col1 FROM tab0 AS cor0
----
-2776
-35
-7460

query I rowsort
SELECT + col0 * col1 + col0 AS col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + ( - col1 ) + + col1 + cor0.col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3036
SELECT + col2 + cor0.col1 + col0 * - CAST( NULL AS SIGNED ) col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3036
SELECT + col2 + cor0.col1 + col0 * - CAST ( NULL AS INTEGER ) col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( ( + col0 ) ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + - cor0.col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3039
SELECT ALL CAST( - 29 AS SIGNED ) + col0 FROM tab2 AS cor0
----
-22
49
50

skipif mysql # not compatible
query I rowsort label-3039
SELECT ALL CAST ( - 29 AS INTEGER ) + col0 FROM tab2 AS cor0
----
-22
49
50

query I rowsort
SELECT col0 * ( - col2 ) + + ( col0 ) AS col0 FROM tab0 cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3041
SELECT DISTINCT 76 + ( col2 ) DIV + 72 FROM tab0 AS cor0
----
76
77

skipif mysql # not compatible
query I rowsort label-3041
SELECT DISTINCT 76 + ( col2 ) / + 72 FROM tab0 AS cor0
----
76
77

query I rowsort
SELECT ALL col1 - + col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - + ( col1 ) + col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( col1 ) + - col0 col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + ( + col2 ) * + col2 + 86 AS col2 FROM tab0 cor0
----
1175
6810
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3046
SELECT CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3046
SELECT CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + col1 * + 43 col0 FROM tab1
----
-1064
-373
-463

query I rowsort
SELECT + - col0 + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 56 FROM tab2 AS cor0
----
56
56
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-3050
SELECT DISTINCT - + cor0.col1 DIV col1 AS col1 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3050
SELECT DISTINCT - + cor0.col1 / col1 AS col1 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + - cor0.col1 * + col0 + + cor0.col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT col1 * col2 * col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + 87 * + col2 FROM tab0 cor0
----
2871
7134
87

query I rowsort
SELECT - cor0.col2 * col2 * col2 AS col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3055
SELECT ALL col2 + CAST( NULL AS DECIMAL ) * + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3055
SELECT ALL col2 + CAST ( NULL AS REAL ) * + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * col0 + col2 + cor0.col0 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT col0 + 33 AS col0 FROM tab2 AS cor0
----
111
112
40

query I rowsort
SELECT ALL - col1 + + ( + col1 ) * - col0 AS col2 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT - - col2 + + 3 AS col1 FROM tab1 AS cor0
----
57
60
99

query I rowsort
SELECT col2 + 50 AS col0 FROM tab2 AS cor0
----
76
77
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-3061
SELECT ALL ( - 86 ) DIV cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3e5251d2b194f9b60423fde582dfb054

skipif mysql # not compatible
query I rowsort label-3061
SELECT ALL ( - 86 ) / cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3e5251d2b194f9b60423fde582dfb054

query I rowsort
SELECT 45 * col1 - + col2 * - col2 AS col1 FROM tab1 AS cor0
----
3699
4086
9801

query I rowsort
SELECT DISTINCT + + 47 AS col2 FROM tab0 AS cor0
----
47

query I rowsort
SELECT DISTINCT col0 + + col0 * - col1 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL + + col2 + cor0.col0 * + 51 FROM tab1 AS cor0
----
207
3321
4176

onlyif mysql # use DIV operator for integer division
query I rowsort label-3066
SELECT - col1 DIV cor0.col1 + + ( col2 ) AS col0 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3066
SELECT - col1 / cor0.col1 + + ( col2 ) AS col0 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT ALL 48 * col0 AS col0 FROM tab2 cor0
----
336
3744
3792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3068
SELECT DISTINCT col2 + col2 DIV + 91 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3068
SELECT DISTINCT col2 + col2 / + 91 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + ( col2 ) * 3 AS col1 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT ALL - + col1 * col1 + - 1 FROM tab2 AS cor0
----
-290
-3482
-962

onlyif mysql # use DIV operator for integer division
query I rowsort label-3071
SELECT col0 DIV + cor0.col0 - col1 * col0 FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-3071
SELECT col0 / + cor0.col0 - col1 * col0 FROM tab1 AS cor0
----
-1039
-639
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 17 col1 FROM tab0 cor0
----
-17

query I rowsort
SELECT - - col0 * col1 + - 91 AS col1 FROM tab2 AS cor0
----
1252
126
4511

onlyif mysql # use DIV operator for integer division
query I rowsort label-3074
SELECT ALL cor0.col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3074
SELECT ALL cor0.col0 / + col2 AS col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - 93 * col0 AS col1 FROM tab1 AS cor0
----
-279
-5952
-7440

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab2, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + 85 AS col2 FROM tab0, tab2 AS cor0
----
85

query I rowsort
SELECT + 5 + - col0 AS col0 FROM tab0
----
-19
-30
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3079
SELECT ALL + col1 DIV - 71 - - col0 DIV col1 AS col1 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-3079
SELECT ALL + col1 / - 71 - - col0 / col1 AS col1 FROM tab1
----
0
6
6

query I rowsort
SELECT DISTINCT - - cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3081
SELECT ALL + 21 DIV 64 col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3081
SELECT ALL + 21 / 64 col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - - col1 + col0 FROM tab1 cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 21 * col1 col2 FROM tab1 AS cor0
----
210
273
546

query I rowsort
SELECT ALL - - cor0.col0 AS col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - col1 * + col0 - 26 FROM tab2 AS cor0
----
-1369
-243
-4628

query I rowsort
SELECT + col0 * col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3087
SELECT ALL - col2 DIV - col2 + - 71 AS col0 FROM tab1
----
-70
-70
-70

skipif mysql # not compatible
query I rowsort label-3087
SELECT ALL - col2 / - col2 + - 71 AS col0 FROM tab1
----
-70
-70
-70

query I rowsort
SELECT DISTINCT 60 + - col2 FROM tab1 AS cor0
----
-36
3
6

query I rowsort
SELECT ALL cor0.col0 + + col2 * cor0.col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT - - 77 - + col1 FROM tab0 AS cor0
----
-14
-20
-9

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to 1a92b418ae3c05ba566f88a890a407ae

query I rowsort
SELECT + + col2 * - 69 + + col0 FROM tab0 AS cor0
----
-2253
-34
-5569

onlyif mysql # use DIV operator for integer division
query I rowsort label-3093
SELECT col2 + ( + 77 ) DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3093
SELECT col2 + ( + 77 ) / cor0.col1 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + + col0 + + 70 AS col1 FROM tab2 AS cor0
----
148
149
77

query IIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab0, tab1 cor1
----
243 values hashing to 9ed1a6a444254225f040123c46b7f70c

onlyif mysql # use DIV operator for integer division
query I rowsort label-3096
SELECT DISTINCT col2 DIV 58 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3096
SELECT DISTINCT col2 / 58 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ( - cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + + col2 + - cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3100
SELECT DISTINCT - col2 DIV - col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-3100
SELECT DISTINCT - col2 / - col1 FROM tab0
----
0

query I rowsort
SELECT - 3 + - tab1.col2 FROM tab1
----
-57
-60
-99

query I rowsort
SELECT DISTINCT - + col2 * col1 + + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + 82 FROM tab0 cor0
----
82

query I rowsort
SELECT ALL + 52 * ( col1 ) AS col0 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT ALL - 89 AS col1 FROM tab0 AS cor0
----
-89
-89
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3106
SELECT DISTINCT + ( cor0.col1 ) DIV + col1 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3106
SELECT DISTINCT + ( cor0.col1 ) / + col1 FROM tab1 AS cor0
----
1

query I rowsort
SELECT ALL + 42 AS col2 FROM tab1
----
42
42
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3108
SELECT - cor0.col2 + CAST( NULL AS SIGNED ) * 87 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3108
SELECT - cor0.col2 + CAST ( NULL AS INTEGER ) * 87 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3109
SELECT - col1 + col2 DIV col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3109
SELECT - col1 + col2 / col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT - - col1 * - 31 AS col2 FROM tab1 AS cor0
----
-310
-403
-806

query I rowsort
SELECT DISTINCT - 45 FROM tab2 AS cor0
----
-45

query I rowsort
SELECT DISTINCT - 49 FROM tab2 AS cor0
----
-49

query I rowsort
SELECT ALL + - cor0.col2 + col0 * col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3114
SELECT CAST( 27 AS SIGNED ) FROM tab1 AS cor0
----
27
27
27

skipif mysql # not compatible
query I rowsort label-3114
SELECT CAST ( 27 AS INTEGER ) FROM tab1 AS cor0
----
27
27
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + - col2 + - col0 * col1 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL - 64 + 99 * col0 AS col2 FROM tab2 AS cor0
----
629
7658
7757

query I rowsort
SELECT - cor0.col0 + + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL - col2 + 78 * - col2 AS col1 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT ALL - col1 + 10 AS col2 FROM tab2 cor0
----
-21
-49
-7

query I rowsort
SELECT ALL 34 FROM tab1 AS cor0
----
34
34
34

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT ( - ( cor0.col0 ) ) AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3124
SELECT ALL - 65 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3124
SELECT ALL - 65 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 8 * col2 - col2 AS col1 FROM tab2
----
-234
-243
-342

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
972 values hashing to 64ce0e736818e884f0a9ecd075da5eb7

query I rowsort
SELECT DISTINCT - 79 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-79

query I rowsort
SELECT + col0 + + col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - col0 * 24 AS col2 FROM tab1 AS cor0
----
-1536
-1920
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + - ( col0 ) col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT - col1 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - - col2 * col2 - - col2 * col2 AS col1 FROM tab2 cor0
----
1352
1458
2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col1 * 2 col0 FROM tab0 AS cor0
----
-16198
-4128
-6790

query I rowsort
SELECT col1 + + 49 * + 20 FROM tab2 cor0
----
1011
1039
997

query I rowsort
SELECT + col1 * col1 + + col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - 21 AS col1 FROM tab2 AS cor0
----
-21
-21
-21

query I rowsort
SELECT ALL 16 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + 16 AS REAL ) AS col1 FROM tab1 AS cor0
----
-16
-16
-16

query I rowsort
SELECT + - cor0.col2 + + cor0.col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL col1 * 20 FROM tab1
----
200
260
520

query I rowsort
SELECT ALL col2 - ( - col0 ) * + col1 FROM tab1
----
1136
132
697

query I rowsort
SELECT col1 * ( + 35 * - col0 ) - + col2 FROM tab0 cor0
----
-118826
-283547
-72273

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 col0 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3145
SELECT - col2 * - CAST( - col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-3145
SELECT - col2 * - CAST ( - col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + - 37 * 3 col2 FROM tab2 AS cor0
----
-128
-142
-170

query I rowsort
SELECT + col0 * + ( + ( - cor0.col2 ) ) + - col2 * - 17 AS col0 FROM tab1 AS cor0
----
-2679
-6048
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 col0 FROM tab0 cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3149
SELECT DISTINCT 76 DIV 87 + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3149
SELECT DISTINCT 76 / 87 + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - col1 * 94 AS col1 FROM tab0 AS cor0
----
-8084
-8554
-9118

query I rowsort
SELECT ALL - 19 AS col0 FROM tab2 AS cor0
----
-19
-19
-19

query I rowsort
SELECT + 51 + + col2 AS col2 FROM tab2 AS cor0
----
77
78
89

query I rowsort
SELECT ALL - col0 - col2 FROM tab0 AS cor0
----
-171
-36
-57

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab1 AS cor1, tab1 cor2
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query I rowsort
SELECT + col2 + - cor0.col2 * cor0.col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - 13 AS col0 FROM tab0 AS cor0
----
-13
-13
-13

query I rowsort
SELECT + col1 * cor0.col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - 1 * + col1 * 51 AS col2 FROM tab2 AS cor0
----
-1581
-3009
-867

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT DISTINCT - 59 + + col0 AS col2 FROM tab1
----
-56
21
5

query I rowsort
SELECT ALL + col1 + col0 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL - tab1.col1 AS col2 FROM tab1, tab0, tab2 cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3163
SELECT ALL - col1 * ( - col1 ) + col0 * - CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
12804
16380
9460

skipif mysql # not compatible
query I rowsort label-3163
SELECT ALL - col1 * ( - col1 ) + col0 * - CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT - col2 + 26 FROM tab1 AS cor0
----
-28
-31
-70

query I rowsort
SELECT DISTINCT + tab2.col0 FROM tab2, tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT col0 + - col0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col1 * - tab0.col2 FROM tab0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3168
SELECT ALL + ( col2 ) * - CAST( + col0 AS SIGNED ) AS col0 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-3168
SELECT ALL + ( col2 ) * - CAST ( + col0 AS INTEGER ) AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - tab0.col0 * + col2 AS col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT cor0.col1 * 6 AS col1 FROM tab1 AS cor0
----
156
60
78

query I rowsort
SELECT ALL - col0 * col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + + col2 + col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT cor0.col0 FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL + col0 - col2 AS col1 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL col2 - + ( col0 ) AS col0 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3178
SELECT ALL col1 * col0 - - 87 * col1 DIV 61 FROM tab0
----
2186
3533
8228

skipif mysql # not compatible
query I rowsort label-3178
SELECT ALL col1 * col0 - - 87 * col1 / 61 FROM tab0
----
2186
3533
8228

query I rowsort
SELECT ALL + col2 - + 8 * 22 FROM tab0
----
-143
-175
-94

query I rowsort
SELECT DISTINCT col2 * ( col2 ) AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT 99 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT + ( tab0.col2 ) FROM tab0
----
1
33
82

query I rowsort
SELECT cor1.col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL col0 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3185
SELECT - cor0.col1 DIV + col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3185
SELECT - cor0.col1 / + col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL + 49 * - col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

onlyif mysql # use DIV operator for integer division
query I rowsort label-3187
SELECT ALL - col2 DIV col2 AS col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3187
SELECT ALL - col2 / col2 AS col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT DISTINCT 39 * + col1 FROM tab2
----
1209
2301
663

query I rowsort
SELECT DISTINCT 95 + col0 FROM tab0
----
119
130
184

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab2 AS cor0, tab0 AS cor1
----
972 values hashing to 9345325155d9f4d7dc4986690c631cb9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 35 + - col0 col1 FROM tab0
----
-54
0
11

query I rowsort
SELECT DISTINCT + 37 + col1 AS col0 FROM tab0
----
123
128
134

onlyif mysql # use DIV operator for integer division
query I rowsort label-3193
SELECT ( - 17 ) DIV - col1 + + col1 * + tab2.col2 FROM tab2
----
1534
647
837

skipif mysql # not compatible
query I rowsort label-3193
SELECT ( - 17 ) / - col1 + + col1 * + tab2.col2 FROM tab2
----
1534
647
837

query I rowsort
SELECT 1 - col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT - 2 * + 2 FROM tab1
----
-4
-4
-4

query I rowsort
SELECT 69 + + col0 FROM tab1 AS cor0
----
133
149
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3197
SELECT + col1 + + col1 * + CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
-1326
-186
-4543

skipif mysql # not compatible
query I rowsort label-3197
SELECT + col1 + + col1 * + CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3198
SELECT DISTINCT CAST( 21 AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
21

skipif mysql # not compatible
query I rowsort label-3198
SELECT DISTINCT CAST ( 21 AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
21

query I rowsort
SELECT - col2 - + col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT cor0.col1 * + cor0.col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col1 * col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3202
SELECT ALL - + col2 + col0 * + CAST( - col1 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
180
40903
83104

skipif mysql # not compatible
query I rowsort label-3202
SELECT ALL - + col2 + col0 * + CAST ( - col1 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
180
40903
83104

query I rowsort
SELECT + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + + col0 + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT - col0 + col2 * col2 AS col0 FROM tab2 AS cor0
----
1365
598
722

onlyif mysql # use DIV operator for integer division
query I rowsort label-3206
SELECT ALL - 93 + - col2 DIV col1 FROM tab0 AS cor0
----
-93
-93
-93

skipif mysql # not compatible
query I rowsort label-3206
SELECT ALL - 93 + - col2 / col1 FROM tab0 AS cor0
----
-93
-93
-93

query I rowsort
SELECT DISTINCT - col1 * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - ( + col1 ) + - col2 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL - 16 + - 64 FROM tab2 cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 - - col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT + col2 + + col2 * col0 AS col2 FROM tab1
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3212
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-3212
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3213
SELECT ALL + CAST( NULL AS SIGNED ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3213
SELECT ALL + CAST ( NULL AS INTEGER ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( 79 ) * + cor0.col1 FROM tab0 AS cor0
----
6794
7189
7663

query I rowsort
SELECT ALL + - col0 * + col2 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + 39 FROM tab0, tab2 cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT + - cor0.col1 * ( col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - 39 + + 68 * col0 FROM tab0 AS cor0
----
1593
2341
6013

query I rowsort
SELECT ALL col2 - col0 * - col0 AS col2 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3220
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3220
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - 24 FROM tab0 AS cor0
----
24

query I rowsort
SELECT - - col1 - col0 * + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-3223
SELECT DISTINCT - + col2 DIV col1 AS col2 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-3223
SELECT DISTINCT - + col2 / col1 AS col2 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT + - col1 * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + col1 * + col2 + 69 * col2 FROM tab0 AS cor0
----
13120
166
5115

query I rowsort
SELECT + 54 * + col1 - col2 AS col2 FROM tab2 AS cor0
----
1647
3160
880

query I rowsort
SELECT DISTINCT + col1 + - col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT - 29 - - col2 FROM tab1 AS cor0
----
25
28
67

query I rowsort
SELECT ALL + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - 32 FROM tab0
----
-32
-32
-32

query I rowsort
SELECT DISTINCT + 77 AS col2 FROM tab1
----
77

query I rowsort
SELECT ALL ( 90 * col1 ) AS col0 FROM tab1
----
1170
2340
900

query I rowsort
SELECT + col1 + + 3 AS col1 FROM tab2 AS cor0
----
20
34
62

query I rowsort
SELECT DISTINCT - + col2 * col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3236
SELECT ALL + col1 DIV ( ( + col1 ) ) AS col2 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3236
SELECT ALL + col1 / ( ( + col1 ) ) AS col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - col0 * 30 + - col1 FROM tab0 cor0
----
-1147
-2761
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 37 + col2 col2 FROM tab2 AS cor0
----
286
2912
2961

query I rowsort
SELECT - - cor0.col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL + col0 - 53 FROM tab1 AS cor0
----
-50
11
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-3241
SELECT DISTINCT - - col2 DIV - col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3241
SELECT DISTINCT - - col2 / - col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + cor0.col1 * + ( col0 ) - cor0.col1 AS col0 FROM tab1 cor0
----
1027
52
630

query I rowsort
SELECT + tab2.col0 * + col2 * + col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - 10 + - col0 * ( col1 ) + col1 * 78 FROM tab1
----
-36
130
1940

query I rowsort
SELECT DISTINCT - + col0 + 64 AS col0 FROM tab2 AS cor0
----
-14
-15
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3246
SELECT DISTINCT col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3246
SELECT DISTINCT col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 cor2, tab1 AS cor3
----
3645 values hashing to 028fd38910121a0fa7c5b9a24c207cf0

query I rowsort
SELECT DISTINCT - col2 + 82 * - 3 FROM tab0 AS cor0
----
-247
-279
-328

query I rowsort
SELECT DISTINCT - col2 * col1 * 85 FROM tab0 AS cor0
----
-241230
-634270
-8245

query I rowsort
SELECT - cor0.col1 * col0 * col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT + col2 + 87 * col2 FROM tab1 AS cor0
----
4752
5016
8448

query I rowsort
SELECT - col2 + 8 * - 88 + - col0 AS col0 FROM tab0 AS cor0
----
-740
-761
-875

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - 73 col0 FROM tab1 AS cor0
----
-219
-4672
-5840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3254
SELECT DISTINCT - - col0 * CAST( cor0.col2 AS SIGNED ) * col1 FROM tab2 AS cor0
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-3254
SELECT DISTINCT - - col0 * CAST ( cor0.col2 AS INTEGER ) * col1 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 63 + + 98 * - col2 col2 FROM tab0
----
-13202
-161
-5313

query I rowsort
SELECT - col1 + + ( + col2 ) FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - 73 + - col2 AS col2 FROM tab0 AS cor0
----
-106
-155
-74

query I rowsort
SELECT - cor0.col0 * 75 + cor0.col0 AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 11d13b2602687ecd9414466b1fa6bb83

query I rowsort
SELECT DISTINCT col1 * + col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + - col0 * 61 * col0 FROM tab1 cor0
----
-249856
-390400
-549

query I rowsort
SELECT - ( col1 ) * - col2 AS col0 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-3262
SELECT ALL - col1 DIV - 31 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3262
SELECT ALL - col1 / - 31 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col2 * - 35 FROM tab0
----
-1155
-2870
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3264
SELECT DISTINCT + cor0.col0 DIV + 1 - cor0.col2 AS col0 FROM tab0, tab2 cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-3264
SELECT DISTINCT + cor0.col0 / + 1 - cor0.col2 AS col0 FROM tab0, tab2 cor0
----
-20
41
52

query I rowsort
SELECT ( col0 + col1 * ( - col1 ) ) AS col2 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT - cor0.col2 + cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4646ed87e8cc5aacb51f9b4e472c3c4b

query I rowsort
SELECT DISTINCT + 80 * - col0 AS col2 FROM tab2
----
-560
-6240
-6320

query I rowsort
SELECT ALL - col0 * ( - col1 ) AS col0 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 78 + - col2 * - col2 + + 14 col0 FROM tab1 AS cor0
----
2852
3185
9152

query I rowsort
SELECT + 95 FROM tab0 cor0
----
95
95
95

query I rowsort
SELECT ALL + - col0 * + col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - col0 + ( col0 ) * - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3273
SELECT col1 + 11 DIV - col2 FROM tab0 AS cor0
----
86
86
91

skipif mysql # not compatible
query I rowsort label-3273
SELECT col1 + 11 / - col2 FROM tab0 AS cor0
----
86
86
91

query I rowsort
SELECT ALL tab1.col0 + - col1 * + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL + 44 + col2 FROM tab1
----
101
140
98

query I rowsort
SELECT ALL + + 13 * col1 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
1085
1101
1260

query I rowsort
SELECT col0 + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT - + 34 - + col1 FROM tab0 AS cor0
----
-120
-125
-131

query I rowsort
SELECT DISTINCT col2 * col0 + + col1 * col2 AS col1 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT - 64 - + col2 AS col0 FROM tab1 cor0
----
-118
-121
-160

query I rowsort
SELECT + col0 * cor0.col0 - col0 * ( + col1 * - ( 30 ) ) AS col1 FROM tab0 AS cor0
----
103075
250891
62496

query I rowsort
SELECT ALL col0 + col2 + - 83 AS col1 FROM tab1 AS cor0
----
-26
38
93

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - col0 - + col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + 68 + col0 AS col2 FROM tab0 AS cor0
----
103
157
92

query I rowsort
SELECT - col0 * - col2 + - col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT - + 33 FROM tab0 cor0
----
-33
-33
-33

query I rowsort
SELECT ALL + 50 * col1 + + ( col0 ) AS col0 FROM tab1 AS cor0
----
1303
564
730

query I rowsort
SELECT + + col1 + ( + col1 ) * col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT col0 * 57 AS col1 FROM tab0 AS cor0
----
1368
1995
5073

onlyif mysql # use DIV operator for integer division
query I rowsort label-3291
SELECT DISTINCT + + col2 DIV 45 + + 35 DIV - col2 + - col0 FROM tab1 cor0
----
-2
-63
-78

skipif mysql # not compatible
query I rowsort label-3291
SELECT DISTINCT + + col2 / 45 + + 35 / - col2 + - col0 FROM tab1 cor0
----
-2
-63
-78

query I rowsort
SELECT - col1 * - col0 + col1 + col2 * + 39 FROM tab2 cor0
----
1301
2842
5675

query I rowsort
SELECT DISTINCT - col1 * + 90 FROM tab1 AS cor0
----
-1170
-2340
-900

query I rowsort
SELECT DISTINCT col2 * col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT ALL tab0.col2 * + col1 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL tab0.col1 + - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - 0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL tab2.col2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL col2 + + tab0.col0 * col0 * + 84 + 81 FROM tab0
----
102982
48498
665527

query I rowsort
SELECT - 66 FROM tab2, tab1 AS cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT + - 67 FROM tab0 cor0
----
-67
-67
-67

query I rowsort
SELECT + ( 70 ) FROM tab1 AS cor0
----
70
70
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3305
SELECT CAST( + col2 AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3305
SELECT CAST ( + col2 AS INTEGER ) FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3306
SELECT + + col0 DIV + col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3306
SELECT + + col0 / + col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + col0 + - col2 + 2 FROM tab2 AS cor0
----
-18
43
54

query I rowsort
SELECT 58 + - col1 FROM tab1 AS cor0
----
32
45
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-3309
SELECT col2 * - col1 + - col0 + - col2 DIV - col1 FROM tab2 AS cor0
----
-1612
-723
-844

skipif mysql # not compatible
query I rowsort label-3309
SELECT col2 * - col1 + - col0 + - col2 / - col1 FROM tab2 AS cor0
----
-1612
-723
-844

query I rowsort
SELECT DISTINCT col0 * col0 * 33 + col2 - col2 FROM tab0
----
19008
261393
40425

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - + col2 col1 FROM tab1 AS cor0
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( col0 ) + col1 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + col2 * - col2 + col0 + col2 * tab1.col1 FROM tab1
----
-1509
-2615
-7888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3314
SELECT + col1 / col1 + CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3314
SELECT + col1 / col1 + CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col0 col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT - col1 * - col1 + col2 * cor0.col2 FROM tab2 AS cor0
----
1690
1733
4157

query I rowsort
SELECT ALL + col1 + + ( ( - col2 ) ) - col2 FROM tab0 AS cor0
----
-73
20
95

query I rowsort
SELECT + + cor0.col2 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - - col0 * + 3 + cor0.col0 + col2 FROM tab2 AS cor0
----
338
354
55

query I rowsort
SELECT DISTINCT 39 FROM tab1, tab2 AS cor0
----
39

query I rowsort
SELECT - 69 * + 91 FROM tab1 AS cor0
----
-6279
-6279
-6279

query I rowsort
SELECT - 98 AS col2 FROM tab0 cor0
----
-98
-98
-98

query I rowsort
SELECT col2 * - ( + col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-3324
SELECT cor0.col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3324
SELECT cor0.col0 / + col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - ( + 11 ) AS col1 FROM tab1 AS cor0
----
-11
-11
-11

query I rowsort
SELECT DISTINCT - col2 * 81 FROM tab2
----
-2106
-2187
-3078

query I rowsort
SELECT DISTINCT + cor1.col1 * cor1.col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
2838
7462
97

query I rowsort
SELECT col0 AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - - col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * - col1 col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3331
SELECT ALL CAST( + 13 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
13
13
13

skipif mysql # not compatible
query I rowsort label-3331
SELECT ALL CAST ( + 13 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
13
13
13

query I rowsort
SELECT ALL 13 FROM tab0, tab2 cor0, tab0 cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT col2 DIV - 33 FROM tab1 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-3333
SELECT col2 / - 33 FROM tab1 AS cor0
----
-1
-1
-2

query I rowsort
SELECT ALL col2 * ( - col1 * + col2 + 86 * + ( + col1 ) ) AS col2 FROM tab1
----
-12480
16530
44928

query I rowsort
SELECT + 99 FROM tab2, tab1 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

onlyif mysql # use DIV operator for integer division
query I rowsort label-3336
SELECT DISTINCT + - col1 DIV 14 AS col0 FROM tab2 cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-3336
SELECT DISTINCT + - col1 / 14 AS col0 FROM tab2 cor0
----
-1
-2
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3337
SELECT ALL col0 DIV + cor0.col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3337
SELECT ALL col0 / + cor0.col2 FROM tab1 AS cor0
----
0
0
1

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT + ( - col1 ) + + col0 * 37 + - 87 AS col1 FROM tab2 AS cor0
----
141
2740
2819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3340
SELECT + CAST( - col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3340
SELECT + CAST ( - col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3341
SELECT DISTINCT - ( - ( + col2 ) ) * + CAST( col0 AS SIGNED ) AS col2 FROM tab1 cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-3341
SELECT DISTINCT - ( - ( + col2 ) ) * + CAST ( col0 AS INTEGER ) AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT - 54 FROM tab2
----
-54
-54
-54

query I rowsort
SELECT - ( + col2 ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT ( cor0.col2 ) + - col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col1 - col2 AS col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL - col1 + - col0 + - col2 AS col1 FROM tab2 AS cor0
----
-134
-163
-65

query I rowsort
SELECT + - cor0.col0 * col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + - 39 FROM tab2 AS cor0
----
-39
-39
-39

query I rowsort
SELECT ALL + col1 * col0 * - col1 + col1 FROM tab0 AS cor0
----
-177418
-329218
-736918

query I rowsort
SELECT DISTINCT + ( - ( + col2 ) ) * - tab2.col2 AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT 5 AS col0 FROM tab2, tab1 AS cor0
----
5

query I rowsort
SELECT + col2 - col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT 86 - 55 FROM tab0
----
31
31
31

query I rowsort
SELECT ALL - cor0.col0 + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * + 34 AS col1 FROM tab2 AS cor0
----
238
2652
2686

onlyif mysql # use DIV operator for integer division
query I rowsort label-3358
SELECT ALL - col2 DIV + col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-3358
SELECT ALL - col2 / + col0 FROM tab1
----
-1
-18
0

query I rowsort
SELECT ALL 76 * col0 AS col2 FROM tab1
----
228
4864
6080

query I rowsort
SELECT + + col2 * - 46 + col0 FROM tab0 AS cor0
----
-11
-1494
-3683

query I rowsort
SELECT col0 + + ( col2 ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col1 + 65 AS col0 FROM tab0 AS cor0
----
151
156
162

query I rowsort
SELECT + - col2 + 30 * col1 + col1 * ( 23 ) AS col2 FROM tab1 AS cor0
----
1324
473
593

query I rowsort
SELECT ALL - col1 + - col0 * 53 FROM tab0 AS cor0
----
-1358
-1952
-4808

onlyif mysql # use DIV operator for integer division
query I rowsort label-3365
SELECT DISTINCT - col2 * - col0 DIV col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3365
SELECT DISTINCT - col2 * - col0 / col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - 76 FROM tab0
----
-76
-76
-76

query I rowsort
SELECT ALL - col1 * - col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL - tab2.col0 * ( col2 ) + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + col0 * - 4 * - ( - col2 * cor0.col2 ) + col0 + + col1 AS col2 FROM tab0 AS cor0
----
-104434
-2393564
-8

query I rowsort
SELECT col2 + + col0 + col1 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT DISTINCT - col2 - cor0.col2 FROM tab0 AS cor0
----
-164
-2
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 - + col1 col2 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - 30 * + col2 + CAST ( 29 AS REAL ) FROM tab2 AS cor0
----
-1111
-751
-781

query I rowsort
SELECT DISTINCT - 36 AS col2 FROM tab1 AS cor0
----
-36

query I rowsort
SELECT + 3 * - col1 * - col2 + + col2 FROM tab0 AS cor0
----
22468
292
8547

query I rowsort
SELECT col0 * col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - 44 * + col0 + - 69 FROM tab1 AS cor0
----
-201
-2885
-3589

query I rowsort
SELECT DISTINCT + - col0 AS col2 FROM tab1 cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 * + ( cor0.col2 ) + col2 * - 25 * cor0.col1 + col1 col0 FROM tab1 AS cor0
----
-10991
-21971
-32158

query I rowsort
SELECT ALL - col1 + - 15 + col1 FROM tab2 AS cor0
----
-15
-15
-15

query I rowsort
SELECT - col0 + 24 FROM tab1 AS cor0
----
-40
-56
21

query I rowsort
SELECT DISTINCT - + cor0.col1 * - 43 + 0 FROM tab0 AS cor0
----
3698
3913
4171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + 49 col0 FROM tab2 AS cor0
----
-29
-30
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * - ( 30 ) col1 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT DISTINCT - + col1 + 0 + - col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + col1 * ( - col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col0 * 4 FROM tab0 AS cor0
----
140
356
96

query I rowsort
SELECT DISTINCT - + col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + col1 * 10 FROM tab1 AS cor0
----
100
130
260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - tab1.col1 * + ( 4 ) + tab1.col1 FROM tab2, tab0, tab2 AS cor0, tab1
----
-30
-39
-78

query I rowsort
SELECT 97 * tab1.col1 * + col2 + + col0 FROM tab1
----
121136
136191
55354

query I rowsort
SELECT ALL + col2 * col2 + + 60 AS col1 FROM tab1 AS cor0
----
2976
3309
9276

query I rowsort
SELECT ALL + col0 * col2 + + 79 * - col1 * - 73 AS col1 FROM tab1 cor0
----
150104
61318
82651

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 + + col0 col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT ALL + col2 * ( col2 ) - ( - col0 ) FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT - - cor0.col0 + - ( col2 ) FROM tab0 cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3399
SELECT DISTINCT + 14 DIV col1 col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3399
SELECT DISTINCT + 14 / col1 col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 17 - col1 col0 FROM tab0 AS cor0
----
-69
-74
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 - + col2 col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL - col2 + + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col2 * + col1 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - + col2 + - col2 * - col2 * + col0 FROM tab2 cor0
----
114038
5076
52702

query I rowsort
SELECT ALL - - 5 * ( col2 ) * + ( - cor0.col2 ) + col2 * col1 AS col2 FROM tab2 AS cor0
----
-1846
-2808
-6574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * 79 col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 1049f343e89f9a135d183593777b30d8

query I rowsort
SELECT DISTINCT 73 * col2 FROM tab1 cor0
----
3942
4161
7008

query I rowsort
SELECT - col1 + col2 * - cor0.col1 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3409
SELECT ALL col2 DIV 76 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3409
SELECT ALL col2 / 76 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + ( col2 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT col0 * + cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-3412
SELECT DISTINCT col1 DIV 30 FROM tab0 AS cor0
----
2
3

skipif mysql # not compatible
query I rowsort label-3412
SELECT DISTINCT col1 / 30 FROM tab0 AS cor0
----
2
3

query I rowsort
SELECT - col2 - 9 * col2 AS col1 FROM tab2 AS cor0
----
-260
-270
-380

query I rowsort
SELECT DISTINCT - col0 * col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + - col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT + col1 * ( + col0 ) + ( + 50 ) * col2 AS col1 FROM tab0 AS cor0
----
12199
3445
3714

query I rowsort
SELECT ALL - - col1 * + cor0.col2 + + cor0.col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT ( col1 ) * col0 + - cor0.col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab0 AS cor0
----
97

query I rowsort
SELECT ALL - cor0.col1 * - col2 * + col1 AS col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - ( - col0 ) * cor0.col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT col2 * + 24 + + col1 * - col2 FROM tab2
----
-189
-910
266

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL - - col0 * - col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - cor0.col1 * col2 + 98 * - 30 * + col2 AS col0 FROM tab1 AS cor0
----
-160164
-168150
-283488

query I rowsort
SELECT ALL + + col0 - col2 * 45 * 98 FROM tab0 AS cor0
----
-145506
-361531
-4375

query IIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab2 cor1
----
54 values hashing to fe43263cad63144a098cccb9cd58c32a

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0, tab1, tab0 AS cor1
----
972 values hashing to e84152c0bf436177d3b3d80e42832d4f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * + cor0.col1 + + col0 * + col2 col0 FROM tab1 cor0
----
-1242
3078
6432

query I rowsort
SELECT - cor0.col1 + col0 * ( + 78 + + col0 ) FROM tab2 AS cor0
----
12109
12386
564

query I rowsort
SELECT col1 + col2 + + 42 * col0 * + col0 FROM tab1 cor0
----
172099
268909
458

query I rowsort
SELECT ALL + 91 + col1 + col2 FROM tab2 AS cor0
----
146
149
176

query I rowsort
SELECT DISTINCT + col2 * col0 - 82 AS col2 FROM tab2 AS cor0
----
107
1946
2920

query I rowsort
SELECT DISTINCT + 13 + col0 * 58 * + 3 FROM tab2 cor0
----
1231
13585
13759

query I rowsort
SELECT DISTINCT - ( + col2 ) * + 91 - col0 AS col0 FROM tab1 AS cor0
----
-4917
-5251
-8816

query I rowsort
SELECT - - col2 + cor0.col2 * col1 AS col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL + + ( col2 ) + - 83 * col0 FROM tab0 AS cor0
----
-1959
-2904
-7305

query I rowsort
SELECT col1 * 79 * - col1 + ( + col1 ) AS col2 FROM tab1
----
-13338
-53378
-7890

query I rowsort
SELECT DISTINCT - col1 + + col1 FROM tab2
----
0

query I rowsort
SELECT - + cor0.col1 * col1 * col1 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT - col2 + + col0 * 27 FROM tab1 AS cor0
----
1671
2064
27

query I rowsort
SELECT DISTINCT - 1 + col0 + - tab0.col0 AS col1 FROM tab0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + col2 col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3445
SELECT + col0 * - col0 + CAST( NULL AS SIGNED ) + col0 * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3445
SELECT + col0 * - col0 + CAST ( NULL AS INTEGER ) + col0 * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 53 + + col2 AS col0 FROM tab0 AS cor0
----
135
54
86

query I rowsort
SELECT - col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT col0 * - col0 + - col0 * - cor0.col1 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT ALL cor0.col2 + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + cor0.col2 - + col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + + 38 AS col1 FROM tab0 AS cor0
----
38

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab2, tab1 AS cor1
----
972 values hashing to 92235dbc382d83baa93d6546ed489b0c

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1, tab0 AS cor2
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL - 97 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT - ( - col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 55 AS col0 FROM tab1 cor0
----
55
55
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-3457
SELECT ALL + tab2.col0 DIV + col0 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3457
SELECT ALL + tab2.col0 / + col0 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT - 43 FROM tab0, tab2 AS cor0
----
-43

query I rowsort
SELECT ALL 48 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT DISTINCT + - ( col0 ) * col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3461
SELECT - tab0.col1 + + ( col1 ) + CAST( tab0.col1 AS SIGNED ) * + col0 FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-3461
SELECT - tab0.col1 + + ( col1 ) + CAST ( tab0.col1 AS INTEGER ) * + col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL col2 + - col0 AS col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT DISTINCT 71 FROM tab0, tab2 cor0
----
71

query I rowsort
SELECT + ( - 89 ) + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-56
-7
-88

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 9364ef7545b07c67767dceb70f02c643

onlyif mysql # use DIV operator for integer division
query I rowsort label-3466
SELECT DISTINCT - + 37 + + col2 DIV col2 AS col0 FROM tab0 AS cor0
----
-36

skipif mysql # not compatible
query I rowsort label-3466
SELECT DISTINCT - + 37 + + col2 / col2 AS col0 FROM tab0 AS cor0
----
-36

query I rowsort
SELECT DISTINCT - ( - 1 ) AS col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL - ( + col2 ) * + col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + + col2 + - 26 AS col2 FROM tab0 AS cor0
----
-25
56
7

query I rowsort
SELECT DISTINCT col2 * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - cor0.col1 - - col1 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT cor0.col2 + ( col0 ) AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3473
SELECT ALL - - col1 DIV + 69 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3473
SELECT ALL - - col1 / + 69 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3474
SELECT DISTINCT col2 DIV tab0.col0 AS col1 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-3474
SELECT DISTINCT col2 / tab0.col0 AS col1 FROM tab0
----
0
1

query I rowsort
SELECT + - col0 * - ( - col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col2 * col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT - 97 * cor0.col0 + cor0.col2 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 2f1b462b000f8ee45505f0cb042e9a1a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3478
SELECT - cor0.col2 * CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3478
SELECT - cor0.col2 * CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + ( + 3 ) AS col2 FROM tab2 AS cor0
----
20
34
62

query I rowsort
SELECT 35 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to ca814400b6361c20866ff8fe01717430

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3481
SELECT + CAST( NULL AS DECIMAL ) AS col2 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3481
SELECT + CAST ( NULL AS REAL ) AS col2 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
243 values hashing to 042fa16c43ab365359ee93c064e44127

query I rowsort
SELECT DISTINCT ( 34 ) FROM tab1
----
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 20 col1 FROM tab0
----
20
20
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3485
SELECT - col0 DIV 26 + + cor0.col1 FROM tab0 AS cor0
----
86
88
96

skipif mysql # not compatible
query I rowsort label-3485
SELECT - col0 / 26 + + cor0.col1 FROM tab0 AS cor0
----
86
88
96

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab0, tab2 AS cor1
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT ALL tab2.col0 * - col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + - col2 + cor0.col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab0, tab2 AS cor0
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3490
SELECT col1 * - col1 + - CAST( + col2 + - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-3490
SELECT col1 * - col1 + - CAST ( + col2 + - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - tab1.col2 * - col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT 62 + col2 AS col1 FROM tab0
----
144
63
95

query I rowsort
SELECT DISTINCT + 25 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3494
SELECT - col2 + - col1 + CAST( + col1 AS SIGNED ) * + col1 AS col2 FROM tab2 AS cor0
----
234
3396
903

skipif mysql # not compatible
query I rowsort label-3494
SELECT - col2 + - col1 + CAST ( + col1 AS INTEGER ) * + col1 AS col2 FROM tab2 AS cor0
----
234
3396
903

query I rowsort
SELECT + - 23 + - col2 FROM tab0 AS cor0
----
-105
-24
-56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3496
SELECT DISTINCT + col2 * cor0.col2 + - CAST( - col1 AS SIGNED ) - col0 FROM tab2 AS cor0
----
1382
657
753

skipif mysql # not compatible
query I rowsort label-3496
SELECT DISTINCT + col2 * cor0.col2 + - CAST ( - col1 AS INTEGER ) - col0 FROM tab2 AS cor0
----
1382
657
753

query I rowsort
SELECT DISTINCT - 48 FROM tab0 AS cor0
----
-48

query I rowsort
SELECT ALL + col0 + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col0 * + col2 - + col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL - col2 + col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL col1 + + col2 * - col2 * + tab1.col0 AS col0 FROM tab1
----
-207926
-737267
-8722

query I rowsort
SELECT 95 * cor0.col0 + 62 FROM tab2 AS cor0
----
727
7472
7567

query I rowsort
SELECT DISTINCT + col1 + 6 * - col1 FROM tab1 AS cor0
----
-130
-50
-65

query I rowsort
SELECT + cor0.col1 * + cor0.col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3505
SELECT DISTINCT cor0.col2 * CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-3505
SELECT DISTINCT cor0.col2 * CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 72 FROM tab1, tab0 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

onlyif mysql # use DIV operator for integer division
query I rowsort label-3508
SELECT ALL - - cor0.col0 DIV - 21 FROM tab2 AS cor0
----
-3
-3
0

skipif mysql # not compatible
query I rowsort label-3508
SELECT ALL - - cor0.col0 / - 21 FROM tab2 AS cor0
----
-3
-3
0

query I rowsort
SELECT - col0 * - col1 + - col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT - tab2.col2 + ( col2 ) AS col2 FROM tab2
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab1 cor1, tab2 cor2
----
972 values hashing to 72eb3d4d523f5d0c69d1b855edd18f4a

query I rowsort
SELECT ALL + col0 + ( 20 * - col2 ) AS col1 FROM tab2 AS cor0
----
-442
-533
-681

query I rowsort
SELECT DISTINCT - + 92 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-92

query I rowsort
SELECT DISTINCT - col0 + - 84 FROM tab1 AS cor0
----
-148
-164
-87

query I rowsort
SELECT ALL - col1 * 66 AS col0 FROM tab2 AS cor0
----
-1122
-2046
-3894

onlyif mysql # use DIV operator for integer division
query I rowsort label-3516
SELECT ALL - col0 + 26 DIV col2 FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3516
SELECT ALL - col0 + 26 / col2 FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3517
SELECT + + CAST( - col2 AS SIGNED ) * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-3517
SELECT + + CAST ( - col2 AS INTEGER ) * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + + cor0.col1 * 60 FROM tab1, tab1 AS cor0
----
1560
600
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-3519
SELECT ALL col0 DIV + col2 - - col0 * + col2 col0 FROM tab0
----
70
7299
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3519
SELECT ALL col0 / + col2 - - col0 * + col2 col0 FROM tab0
----
70
7299
792

query I rowsort
SELECT DISTINCT col2 - col1 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT 15 FROM tab0
----
15
15
15

query I rowsort
SELECT DISTINCT tab0.col0 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
24
35
89

query I rowsort
SELECT + col1 + tab0.col2 AS col1 FROM tab0
----
119
173
98

query I rowsort
SELECT - 22 AS col2 FROM tab0 cor0
----
-22
-22
-22

query I rowsort
SELECT DISTINCT tab2.col0 - - col0 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL + 24 + col2 AS col0 FROM tab0 cor0
----
106
25
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 68 * + cor0.col1 col2 FROM tab2, tab1 AS cor0
----
-1768
-680
-884

query I rowsort
SELECT ALL + - col2 * + col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT 73 + - cor0.col0 * col2 FROM tab1 AS cor0
----
-3575
-7607
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3530
SELECT DISTINCT col0 DIV 88 + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3530
SELECT DISTINCT col0 / 88 + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + - col0 * + 75 AS col0 FROM tab1 AS cor0
----
-225
-4800
-6000

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT ALL - cor0.col1 + - ( + col1 ) * - col1 + col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT ALL + + cor0.col1 + col1 * col0 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT 21 * cor0.col2 * - cor0.col2 + - ( col1 * cor0.col1 ) + col1 FROM tab1 AS cor0
----
-193692
-61886
-68319

query I rowsort
SELECT DISTINCT + ( - col2 ) AS col1 FROM tab1 cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - - cor0.col1 col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - 20 * col2 AS col2 FROM tab2 AS cor0
----
-520
-540
-760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 * cor0.col1 + - col1 col1 FROM tab1 AS cor0
----
1144
440
572

query I rowsort
SELECT - + 71 * col0 FROM tab1 AS cor0
----
-213
-4544
-5680

query I rowsort
SELECT ALL + col0 * col0 + ( col0 * + col0 ) FROM tab2 AS cor0
----
12168
12482
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - col0 * col2 + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + + col1 + + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 10 AS col2 FROM tab2 AS cor0
----
10
10
10

query I rowsort
SELECT ALL 50 AS col0 FROM tab0 AS cor0
----
50
50
50

query I rowsort
SELECT ALL - col2 - - 19 AS col1 FROM tab0
----
-14
-63
18

query I rowsort
SELECT ALL - ( + 41 ) - tab1.col2 * col2 FROM tab1
----
-2957
-3290
-9257

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col0 + - col2 col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + col1 * + col1 + col0 + - col0 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 75 + + col1 AS col2 FROM tab0 AS cor0
----
161
166
172

query I rowsort
SELECT DISTINCT col1 * col2 AS col2 FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * - col0 * - cor0.col2 + 83 * + col2 col1 FROM tab1 AS cor0
----
-228741
-606432
3996

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to deaaa983f771be544ffdc26f04a18657

query I rowsort
SELECT + cor0.col0 + - tab1.col1 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to fb7879b4a0569d558bc2da00ecd3b07c

query I rowsort
SELECT ALL - col0 + + tab1.col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT 51 AS col2 FROM tab0, tab2 AS cor0
----
51

query I rowsort
SELECT - + 39 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 cor1, tab2 cor2
----
972 values hashing to 958533d1a7bf61199ed7c03eadf37f9a

query I rowsort
SELECT ALL cor1.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT 52 + 91 AS col2 FROM tab0
----
143
143
143

query I rowsort
SELECT ALL 76 AS col0 FROM tab2
----
76
76
76

query I rowsort
SELECT 27 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT ALL - 37 + + cor0.col2 * ( - 8 ) FROM tab2, tab0 cor0
----
9 values hashing to 228f5042aacd24524d4e261639cc2d31

query I rowsort
SELECT - 32 + col2 + - col1 FROM tab0 AS cor0
----
-128
-41
-85

query I rowsort
SELECT DISTINCT - - ( - 26 ) * - col1 FROM tab0 AS cor0
----
2236
2366
2522

query I rowsort
SELECT ALL - + 70 * - col0 FROM tab1 AS cor0
----
210
4480
5600

query I rowsort
SELECT 40 * + ( col0 ) + col2 AS col0 FROM tab0 AS cor0
----
1401
3642
993

query I rowsort
SELECT ALL cor0.col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT 62 FROM tab1
----
62
62
62

query I rowsort
SELECT DISTINCT + 77 * col2 AS col0 FROM tab1
----
4158
4389
7392

onlyif mysql # use DIV operator for integer division
query I rowsort label-3572
SELECT DISTINCT 30 DIV col0 - - col1 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-3572
SELECT DISTINCT 30 / col0 - - col1 FROM tab2
----
17
35
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3573
SELECT ALL + 38 DIV tab2.col1 - + col0 AS col2 FROM tab2
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-3573
SELECT ALL + 38 / tab2.col1 - + col0 AS col2 FROM tab2
----
-6
-77
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3574
SELECT ALL - 52 DIV + col0 AS col1 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-3574
SELECT ALL - 52 / + col0 AS col1 FROM tab0 AS cor0
----
-1
-2
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3575
SELECT - CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3575
SELECT - CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + - 19 AS col1 FROM tab2 AS cor0
----
-19
-19
-19

query I rowsort
SELECT - - col1 * + col0 + - cor0.col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + + 92 * + col2 FROM tab1 AS cor0
----
4968
5244
8832

query I rowsort
SELECT 45 FROM tab2
----
45
45
45

query I rowsort
SELECT DISTINCT - cor0.col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - + col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT + col2 * col2 - 17 AS col2 FROM tab2 AS cor0
----
1427
659
712

onlyif mysql # use DIV operator for integer division
query I rowsort label-3583
SELECT DISTINCT + col0 DIV cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3583
SELECT DISTINCT + col0 / cor0.col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - col0 * cor0.col2 * - col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3585
SELECT col1 + - col1 DIV - col1 + col2 * + col1 AS col2 FROM tab0 AS cor0
----
195
2925
7554

skipif mysql # not compatible
query I rowsort label-3585
SELECT col1 + - col1 / - col1 + col2 * + col1 AS col2 FROM tab0 AS cor0
----
195
2925
7554

query I rowsort
SELECT + tab0.col0 + col0 + 12 * - col1 AS col1 FROM tab0
----
-1094
-914
-984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + 34 * ( - col2 ) col2 FROM tab1
----
-110466
-313344
-99144

query I rowsort
SELECT ALL cor0.col2 * col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + + col2 - + col1 FROM tab2 AS cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * cor0.col2 - col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT + col2 * 19 AS col1 FROM tab0 cor0
----
1558
19
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-3593
SELECT - + col0 * 48 DIV 49 AS col2 FROM tab2 cor0
----
-6
-76
-77

skipif mysql # not compatible
query I rowsort label-3593
SELECT - + col0 * 48 / 49 AS col2 FROM tab2 cor0
----
-6
-76
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-3594
SELECT ALL - col0 DIV col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3594
SELECT ALL - col0 / col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + col2 * 39 AS col0 FROM tab0 AS cor0
----
1287
3198
39

query I rowsort
SELECT - col1 * col0 + cor0.col2 + - col1 * + col0 FROM tab0 AS cor0
----
-16116
-4095
-6789

query I rowsort
SELECT DISTINCT + col2 * + col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT col0 * col2 - col1 AS col2 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-3599
SELECT + col1 DIV tab1.col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3599
SELECT + col1 / tab1.col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * col1 AS col1 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3601
SELECT ALL + col0 DIV col0 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3601
SELECT ALL + col0 / col0 AS col2 FROM tab1
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3602
SELECT DISTINCT + - col1 + CAST( NULL AS SIGNED ) * + 65 AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3602
SELECT DISTINCT + - col1 + CAST ( NULL AS INTEGER ) * + 65 AS col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT - 51 - 53 * - col2 AS col0 FROM tab2 AS cor0
----
1327
1380
1963

query I rowsort
SELECT - - col1 - col2 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3605
SELECT + - ( 51 ) * - col0 + col0 DIV - cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
178
3273
4092

skipif mysql # not compatible
query I rowsort label-3605
SELECT + - ( 51 ) * - col0 + col0 / - cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
178
3273
4092

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT - + col0 DIV + 31 + col0 + + 19 AS col0 FROM tab2 AS cor0
----
26
95
96

skipif mysql # not compatible
query I rowsort label-3606
SELECT - + col0 / + 31 + col0 + + 19 AS col0 FROM tab2 AS cor0
----
26
95
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 - - col1 col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT + 5 + cor0.col0 FROM tab2 AS cor0
----
12
83
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col1 ) + col1 + 39 col2 FROM tab1 AS cor0
----
39
39
39

query I rowsort
SELECT - 21 FROM tab0 AS cor0
----
-21
-21
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3611
SELECT DISTINCT col1 * 1 + col1 DIV - col0 FROM tab2
----
17
27
59

skipif mysql # not compatible
query I rowsort label-3611
SELECT DISTINCT col1 * 1 + col1 / - col0 FROM tab2
----
17
27
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3612
SELECT ALL - col2 + col2 DIV col0 AS col1 FROM tab2
----
-24
-26
-38

skipif mysql # not compatible
query I rowsort label-3612
SELECT ALL - col2 + col2 / col0 AS col1 FROM tab2
----
-24
-26
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col1 + col1 col1 FROM tab1
----
0

query I rowsort
SELECT col1 + - col1 * col0 AS col1 FROM tab2
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 22 + + col0 col1 FROM tab1 AS cor0
----
102
25
86

query I rowsort
SELECT ( 15 ) FROM tab2 AS cor0
----
15
15
15

query I rowsort
SELECT DISTINCT + 90 + col0 FROM tab0 AS cor0
----
114
125
179

query I rowsort
SELECT DISTINCT - col1 * col1 + cor0.col2 - col0 FROM tab2 AS cor0
----
-330
-3533
-941

query I rowsort
SELECT ALL - 12 FROM tab0 AS cor0
----
-12
-12
-12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * col2 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 + cor0.col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT + col2 + col0 AS col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3624
SELECT DISTINCT + col0 + + col2 DIV 13 AS col0 FROM tab1 AS cor0
----
68
7
87

skipif mysql # not compatible
query I rowsort label-3624
SELECT DISTINCT + col0 + + col2 / 13 AS col0 FROM tab1 AS cor0
----
68
7
87

query I rowsort
SELECT ALL + 57 * col2 + - 43 * - col2 FROM tab1 AS cor0
----
5400
5700
9600

query I rowsort
SELECT col2 * - 61 * - col2 FROM tab2
----
41236
44469
88084

query I rowsort
SELECT - col0 + col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL - tab2.col0 * 65 FROM tab2
----
-455
-5070
-5135

query I rowsort
SELECT + col2 * col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col2 * cor0.col1 * 12 AS col1 FROM tab2 AS cor0
----
10044
18408
7752

query I rowsort
SELECT 55 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT - 87 AS col1 FROM tab1
----
-87
-87
-87

query I rowsort
SELECT DISTINCT col2 * - tab1.col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - - col1 * - col1 + + col0 AS col2 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT + col0 * + col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3636
SELECT - + col2 + col0 * cor0.col1 DIV col1 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-3636
SELECT - + col2 + col0 * cor0.col1 / col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - col0 * col1 + col1 * tab2.col0 AS col0 FROM tab2
----
0

query I rowsort
SELECT - - col1 * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + - col0 + + col0 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3640
SELECT - - col2 + col1 * - col2 DIV - cor0.col2 col1 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3640
SELECT - - col2 + col1 * - col2 / - cor0.col2 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - cor0.col1 + - col0 * + cor0.col0 AS col1 FROM tab2 cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT + - col0 * col0 + - col1 * + col1 * col1 FROM tab1 AS cor0
----
-17585
-5096
-8597

onlyif mysql # use DIV operator for integer division
query I rowsort label-3644
SELECT ALL - - cor0.col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3644
SELECT ALL - - cor0.col2 / - col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col1 * col0 * - col2 AS col0 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - col2 * col1 + col1 * col0 AS col0 FROM tab1 AS cor0
----
-1326
-208
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3648
SELECT col1 DIV col0 + col0 + - col0 * col0 FROM tab0 AS cor0
----
-1188
-549
-7831

skipif mysql # not compatible
query I rowsort label-3648
SELECT col1 / col0 + col0 + - col0 * col0 FROM tab0 AS cor0
----
-1188
-549
-7831

query I rowsort
SELECT ALL + col0 * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE - col2 IN ( + col2 * + col1 )
----

query I rowsort
SELECT DISTINCT col0 * + col1 + cor0.col2 + + col1 AS col1 FROM tab0 AS cor0
----
2183
3493
8272

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE col1 NOT BETWEEN ( + col0 + - col2 ) AND ( NULL )
----

query I rowsort
SELECT ALL col0 * tab0.col1 + col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT - col1 * col0 * - col2 + col2 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT + col1 - col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 + + col1 col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + 4 AS col2 FROM tab0
----
4
4
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3658
SELECT ALL col2 DIV col1 + col1 FROM tab2
----
19
31
59

skipif mysql # not compatible
query I rowsort label-3658
SELECT ALL col2 / col1 + col1 FROM tab2
----
19
31
59

query I rowsort
SELECT ALL - tab0.col1 * col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + - col0 * - col2 * col2 + + col2 AS col1 FROM tab2 cor0
----
114114
5130
52754

onlyif mysql # use DIV operator for integer division
query I rowsort label-3661
SELECT + col0 DIV - col0 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3661
SELECT + col0 / - col0 FROM tab2 cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3662
SELECT col2 DIV col0 AS col0 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3662
SELECT col2 / col0 AS col0 FROM tab2
----
0
0
3

query I rowsort
SELECT + col2 * col1 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col0 - tab1.col0 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT ALL + cor0.col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col0 col0 FROM tab2
----
0

query I rowsort
SELECT + tab2.col2 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT col0 * + col1 * - col0 FROM tab1
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-3669
SELECT DISTINCT tab1.col0 DIV col1 FROM tab1
----
0
6

skipif mysql # not compatible
query I rowsort label-3669
SELECT DISTINCT tab1.col0 / col1 FROM tab1
----
0
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3670
SELECT ALL - col2 DIV tab0.col0 AS col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3670
SELECT ALL - col2 / tab0.col0 AS col0 FROM tab0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3671
SELECT ALL col0 DIV col0 AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3671
SELECT ALL col0 / col0 AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT + 10 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT - col0 - col1 * - ( col0 ) AS col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT - col2 FROM tab2 WHERE NOT col0 * col0 IN ( - tab2.col0 * + tab2.col1 )
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3676
SELECT ALL col1 DIV col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3676
SELECT ALL col1 / col2 FROM tab0
----
1
2
97

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT DISTINCT col1 + + col1 * tab2.col2 * - col0 - col0 * + tab2.col0 FROM tab2
----
-125677
-57258
-5877

query I rowsort
SELECT + col2 - + tab1.col0 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3680
SELECT - col2 + - col1 DIV col1 + col0 AS col1 FROM tab1
----
-17
-52
6

skipif mysql # not compatible
query I rowsort label-3680
SELECT - col2 + - col1 / col1 + col0 AS col1 FROM tab1
----
-17
-52
6

query I rowsort
SELECT ALL - col1 * + col0 AS col1 FROM tab1 WHERE NULL NOT IN ( + col2 * col0 * - tab1.col2 )
----

query I rowsort
SELECT col1 * col0 * - col2 AS col0 FROM tab1
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 col2 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT tab0.col0 * col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3685
SELECT col1 * col0 DIV col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3685
SELECT col1 * col0 / col1 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 col1 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3687
SELECT DISTINCT tab2.col1 + col1 - - col0 DIV - col1 col2 FROM tab2
----
117
30
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3687
SELECT DISTINCT tab2.col1 + col1 - - col0 / - col1 col2 FROM tab2
----
117
30
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3688
SELECT tab1.col0 DIV col0 AS col1 FROM tab1 WHERE NOT col1 - + col2 > + col2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3688
SELECT tab1.col0 / col0 AS col1 FROM tab1 WHERE NOT col1 - + col2 > + col2
----
1
1
1

query I rowsort
SELECT ALL col2 + + col2 + col1 FROM tab1
----
124
134
205

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab1, tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + tab2.col2 ) + - tab2.col1 col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL col1 + col0 * 58 FROM tab1
----
200
3722
4653

onlyif mysql # use DIV operator for integer division
query I rowsort label-3693
SELECT - col1 DIV - cor0.col1 + - col0 + + col1 FROM tab2 AS cor0
----
-18
-61
25

skipif mysql # not compatible
query I rowsort label-3693
SELECT - col1 / - cor0.col1 + - col0 + + col1 FROM tab2 AS cor0
----
-18
-61
25

query I rowsort
SELECT - + cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ( col0 ) + - col1 * + col2 + + col1 FROM tab2
----
-1397
-550
-799

query I rowsort
SELECT 57 + tab2.col0 AS col2 FROM tab2
----
135
136
64

query I rowsort
SELECT + - col2 - col2 AS col1 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT cor0.col0 + + col0 FROM tab0 cor0
----
178
48
70

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

query I rowsort
SELECT DISTINCT + ( col0 ) * - col1 + col2 AS col2 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT + cor0.col2 * - 84 FROM tab0, tab2 AS cor0
----
-2184
-2268
-3192

query I rowsort
SELECT col2 * - col1 + - 21 + col2 * - col0 AS col1 FROM tab0 AS cor0
----
-14781
-153
-3651

query I rowsort
SELECT DISTINCT + cor0.col1 * col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3704
SELECT ALL - 7 * col1 DIV + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-18
-679
-7

skipif mysql # not compatible
query I rowsort label-3704
SELECT ALL - 7 * col1 / + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-18
-679
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + cor0.col1 col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT col1 * col0 AS col0 FROM tab2
----
1343
217
4602

query III rowsort
SELECT * FROM tab1 WHERE NULL IN ( - col2 * col0 * col1 )
----

query I rowsort
SELECT ALL tab0.col2 * + col2 + col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT + col0 + + col0 AS col1 FROM tab2
----
14
156
158

query III rowsort
SELECT * FROM tab1 WHERE NOT col2 <= NULL
----

query I rowsort
SELECT col2 * - tab0.col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + col2 + - col0 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT col1 + tab2.col0 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL tab0.col2 * - col0 * + col2 + col0 * tab0.col0 FROM tab0
----
-25560
-590515
1190

query I rowsort
SELECT - col2 * - col2 AS col1 FROM tab0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 + col0 col0 FROM tab2
----
137
38
96

query III rowsort
SELECT ALL * FROM tab0 WHERE col1 >= col1 * col0
----

query III rowsort
SELECT * FROM tab2 cor0 WHERE NOT col2 - col1 < ( NULL )
----

query I rowsort
SELECT cor0.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL col2 * - col2 + + col2 FROM tab2 AS cor0 WHERE NOT col2 * + col1 / - col0 >= ( NULL )
----

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE col1 NOT IN ( col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL = NULL
----

query I rowsort
SELECT col1 + tab0.col1 FROM tab0
----
172
182
194

query I rowsort
SELECT - tab0.col2 + col0 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL + col1 AS col1 FROM tab1 WHERE NULL < ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3727
SELECT tab2.col0 DIV - col0 + col1 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-3727
SELECT tab2.col0 / - col0 + col1 FROM tab2
----
16
30
58

query III rowsort
SELECT * FROM tab0 WHERE + col0 / - col2 + col1 * - col1 * - col1 NOT IN ( + col1 * - col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT - col0 FROM tab1 WHERE NOT col1 * col2 NOT IN ( col2 )
----

query I rowsort
SELECT ALL - tab1.col1 AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + col0 - - col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT - col1 - tab1.col2 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT col0 FROM tab1 WHERE NULL < NULL
----

query I rowsort
SELECT tab2.col0 * - col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL col2 * tab1.col2 * - col0 FROM tab1 WHERE NOT + col1 > ( NULL )
----

query I rowsort
SELECT tab2.col0 AS col0 FROM tab2 WHERE ( NULL ) >= NULL
----

query I rowsort
SELECT DISTINCT col2 * col1 - col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT ALL + col2 + cor0.col2 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-3739
SELECT - col0 DIV - col2 - col0 col1 FROM tab1 AS cor0
----
-3
-63
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3739
SELECT - col0 / - col2 - col0 col1 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT ALL - ( + col0 ) * + cor0.col1 + col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + 20 FROM tab0 AS cor0
----
20

query I rowsort
SELECT DISTINCT - 24 FROM tab0 AS cor0
----
-24

query I rowsort
SELECT DISTINCT - 52 * - col0 + - col0 AS col1 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT col1 * col0 + + cor0.col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + ( - cor0.col0 * 44 ) FROM tab0, tab2 AS cor0
----
-308
-3432
-3476

onlyif mysql # use DIV operator for integer division
query I rowsort label-3746
SELECT DISTINCT ( + col2 ) DIV col1 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-3746
SELECT DISTINCT ( + col2 ) / col1 FROM tab2
----
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3747
SELECT CAST( col2 * + col0 AS SIGNED ) - tab0.col1 AS col1 FROM tab0
----
-62
706
7207

skipif mysql # not compatible
query I rowsort label-3747
SELECT CAST ( col2 * + col0 AS INTEGER ) - tab0.col1 AS col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT + 37 - - col1 AS col0 FROM tab0 AS cor0
----
123
128
134

query I rowsort
SELECT col2 + + col1 + col0 FROM tab2
----
134
163
65

query I rowsort
SELECT + + col1 * + col1 - + 62 AS col2 FROM tab0 AS cor0
----
7334
8219
9347

query I rowsort
SELECT col0 * - col2 + + 53 * - col1 AS col2 FROM tab2
----
-1832
-3903
-5155

query I rowsort
SELECT col1 + + col0 + + col1 AS col2 FROM tab1
----
106
55
84

query I rowsort
SELECT DISTINCT + tab1.col2 + col2 FROM tab1
----
108
114
192

query I rowsort
SELECT - col0 + - col2 * + col2 AS col0 FROM tab0 AS cor0
----
-1113
-36
-6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + 80 * + col0 * - cor0.col1 col2 FROM tab0 AS cor0
----
-165144
-271635
-648009

onlyif mysql # use DIV operator for integer division
query I rowsort label-3756
SELECT tab0.col1 DIV - tab0.col0 AS col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3756
SELECT tab0.col1 / - tab0.col0 AS col0 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT - col2 + col1 AS col1 FROM tab0
----
53
9
96

query I rowsort
SELECT 12 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT DISTINCT - ( col0 ) * - col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3760
SELECT DISTINCT - col0 DIV + col1 + + CAST( - 20 AS SIGNED ) AS col1 FROM tab2
----
-20
-21
-24

skipif mysql # not compatible
query I rowsort label-3760
SELECT DISTINCT - col0 / + col1 + + CAST ( - 20 AS INTEGER ) AS col1 FROM tab2
----
-20
-21
-24

onlyif mysql # use DIV operator for integer division
query I rowsort label-3761
SELECT 51 DIV + col0 FROM tab1
----
0
0
17

skipif mysql # not compatible
query I rowsort label-3761
SELECT 51 / + col0 FROM tab1
----
0
0
17

query I rowsort
SELECT - + col2 * + col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + tab1.col2 * col2 * col1 AS col0 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT DISTINCT - tab1.col0 FROM tab1, tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col2 * tab1.col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col0 - - ( - col1 ) * - col2 * + col2 FROM tab2
----
22606
24627
39962

query I rowsort
SELECT col2 * - col2 * - col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - - ( - ( cor0.col0 ) ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT 57 AS col0 FROM tab2 AS cor0
----
57

query I rowsort
SELECT DISTINCT + col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( ( + col2 ) AS REAL ) * - CAST ( - 15 AS INTEGER ) FROM tab0 cor0
----
-1230
-15
-495

query I rowsort
SELECT DISTINCT - ( - col0 ) * + col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ( - col0 ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT 7 + - col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-182
-2021
-2995

query I rowsort
SELECT DISTINCT col2 * + col1 * + col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3776
SELECT ALL 30 DIV + tab2.col1 + cor0.col2 DIV + 88 FROM tab2, tab1 AS cor0
----
9 values hashing to 8ace2c5a21c112d4f7b84adff0037fee

skipif mysql # not compatible
query I rowsort label-3776
SELECT ALL 30 / + tab2.col1 + cor0.col2 / + 88 FROM tab2, tab1 AS cor0
----
9 values hashing to 8ace2c5a21c112d4f7b84adff0037fee

query I rowsort
SELECT col2 * - col2 * col1 - tab2.col2 AS col2 FROM tab2
----
-22626
-24586
-39910

query I rowsort
SELECT ALL 9 * 44 + + col2 FROM tab1 AS cor0
----
450
453
492

query I rowsort
SELECT DISTINCT ( - 86 ) AS col2 FROM tab0 AS cor0
----
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col2 col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT col1 * - 2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL + 85 AS col0 FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT + col1 * + col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - + ( ( col0 ) ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col2 * col0 * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL + + ( col1 ) * col0 + - col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT - col2 * cor0.col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3788
SELECT - CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3788
SELECT - CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3789
SELECT ALL - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3789
SELECT ALL - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 39 * - col0 * col0 FROM tab1 AS cor0
----
-159744
-249600
-351

query I rowsort
SELECT - ( 31 * col2 + - col1 ) AS col1 FROM tab0
----
-2451
-937
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-3792
SELECT DISTINCT + 84 DIV - col0 FROM tab2
----
-1
-12

skipif mysql # not compatible
query I rowsort label-3792
SELECT DISTINCT + 84 / - col0 FROM tab2
----
-1
-12

query I rowsort
SELECT ALL ( - 47 ) * + col1 FROM tab1
----
-1222
-470
-611

query I rowsort
SELECT + - 53 FROM tab2 cor0
----
-53
-53
-53

query I rowsort
SELECT ALL - ( col0 ) + col2 * - col2 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ( col2 ) FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3800
SELECT + - col1 * - col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3800
SELECT + - col1 * - col1 / - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL 17 AS col0 FROM tab0
----
17
17
17

query I rowsort
SELECT cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT - 72 AS col1 FROM tab2 AS cor0
----
-72
-72
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-3804
SELECT - col1 * col0 DIV col1 FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3804
SELECT - col1 * col0 / col1 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3805
SELECT + col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3805
SELECT + col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + + col2 * col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL col2 * - col2 + - cor0.col2 + col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - cor0.col0 + 23 * 55 AS col0 FROM tab0 AS cor0
----
1176
1230
1241

query I rowsort
SELECT ALL + col1 - + 76 AS col2 FROM tab1 AS cor0
----
-50
-63
-66

query I rowsort
SELECT + col1 * 76 * col1 AS col1 FROM tab1 AS cor0
----
12844
51376
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * - col0 col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 3 col2 FROM tab1 AS cor0
----
51
54
93

query I rowsort
SELECT DISTINCT - col1 - cor0.col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL col2 * + col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - - cor0.col2 + - 2 FROM tab1 AS cor0
----
52
55
94

query I rowsort
SELECT ALL + col0 * - col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col1 * - 1 - - col1 * - cor0.col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT col0 + - col0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - col0 * + ( + 31 ) FROM tab0 AS cor0
----
-1085
-2759
-744

onlyif mysql # use DIV operator for integer division
query I rowsort label-3820
SELECT DISTINCT + col1 + 47 DIV - ( - col0 ) col1 FROM tab0 AS cor0
----
87
91
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3820
SELECT DISTINCT + col1 + 47 / - ( - col0 ) col1 FROM tab0 AS cor0
----
87
91
98

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to bce5cbf48f4a41569415c085ae91ae7c

query I rowsort
SELECT - ( 16 ) + col0 FROM tab0 cor0
----
19
73
8

query I rowsort
SELECT col0 * 68 + + col0 * col1 FROM tab1 AS cor0
----
282
4992
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 69 col2 FROM tab1 AS cor0
----
69
69
69

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-3826
SELECT + col1 DIV - 39 + col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3826
SELECT + col1 / - 39 + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT - 17 FROM tab0, tab1 AS cor0
----
-17

query I rowsort
SELECT cor0.col0 + - col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - col2 - - tab0.col0 * - col0 AS col0 FROM tab0
----
-1226
-609
-8003

query I rowsort
SELECT ALL + tab0.col1 * + col2 - - 74 AS col0 FROM tab0
----
171
2912
7536

onlyif mysql # use DIV operator for integer division
query I rowsort label-3831
SELECT + ( cor0.col0 ) + col1 DIV 38 FROM tab2 cor0
----
7
79
79

skipif mysql # not compatible
query I rowsort label-3831
SELECT + ( cor0.col0 ) + col1 / 38 FROM tab2 cor0
----
7
79
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3832
SELECT - CAST( - 23 AS SIGNED ) + + col1 * - 93 + col1 AS col2 FROM tab1 AS cor0
----
-1173
-2369
-897

skipif mysql # not compatible
query I rowsort label-3832
SELECT - CAST ( - 23 AS INTEGER ) + + col1 * - 93 + col1 AS col2 FROM tab1 AS cor0
----
-1173
-2369
-897

query I rowsort
SELECT cor0.col1 + - 6 + col0 FROM tab0 AS cor0
----
104
126
174

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3834
SELECT - CAST( + col2 AS SIGNED ) * col0 + - col2 * + col0 AS col2 FROM tab2 cor0
----
-378
-4056
-6004

skipif mysql # not compatible
query I rowsort label-3834
SELECT - CAST ( + col2 AS INTEGER ) * col0 + - col2 * + col0 AS col2 FROM tab2 cor0
----
-378
-4056
-6004

query I rowsort
SELECT - col2 * col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3836
SELECT - CAST( NULL AS SIGNED ) + col1 + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3836
SELECT - CAST ( NULL AS INTEGER ) + col1 + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + col2 * - col2 + - ( - col1 ) * col2 AS col1 FROM tab1 cor0
----
-1509
-2615
-7888

query I rowsort
SELECT + col1 * - 3 AS col1 FROM tab2 AS cor0
----
-177
-51
-93

query I rowsort
SELECT DISTINCT + + ( col0 ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL col0 * col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3841
SELECT DISTINCT + 67 + + col1 * - col1 + CAST( NULL AS SIGNED ) / + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3841
SELECT DISTINCT + 67 + + col1 * - col1 + CAST ( NULL AS INTEGER ) / + col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col0 + + 5 FROM tab1 AS cor0
----
69
8
85

query I rowsort
SELECT col2 * + 15 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT ALL - - ( + col2 ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + ( - col1 ) * col0 + col2 + - 59 * + col2 * ( + col1 ) FROM tab0 AS cor0
----
-169473
-448275
-9117

query I rowsort
SELECT DISTINCT - col1 + - col1 * - col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT ALL 40 * col2 AS col2 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT - 5 * + col2 AS col1 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT DISTINCT + ( - 19 ) FROM tab0 cor0
----
-19

query I rowsort
SELECT ALL - + col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL 37 AS col1 FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT - + ( + col1 ) + - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + 0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT 86 FROM tab1 AS cor0
----
86
86
86

query I rowsort
SELECT DISTINCT + cor0.col2 AS col1 FROM tab0, tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3856
SELECT col0 + col0 DIV 37 col1 FROM tab2
----
7
80
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3856
SELECT col0 + col0 / 37 col1 FROM tab2
----
7
80
81

query I rowsort
SELECT + 66 AS col2 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT DISTINCT - - ( - cor0.col1 ) * + col0 - 91 FROM tab2 AS cor0
----
-1434
-308
-4693

query I rowsort
SELECT - 70 + col0 FROM tab2 AS cor0
----
-63
8
9

query I rowsort
SELECT + 50 FROM tab2 AS cor0
----
50
50
50

query I rowsort
SELECT + cor0.col0 + cor0.col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
1113
36
6813

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 82e15d5967b272804e574774895a0222

query I rowsort
SELECT DISTINCT - col2 * 52 AS col0 FROM tab2 AS cor0
----
-1352
-1404
-1976

query I rowsort
SELECT col1 - ( + 26 + col1 ) * - col1 AS col2 FROM tab2 AS cor0
----
1798
5074
748

query I rowsort
SELECT ALL col2 + - ( col1 ) FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT cor0.col0 * col0 + + col2 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-3867
SELECT ALL - - col0 DIV + cor0.col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3867
SELECT ALL - - col0 / + cor0.col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + col2 + col2 + ( + col1 ) FROM tab1 AS cor0
----
124
134
205

onlyif mysql # use DIV operator for integer division
query I rowsort label-3869
SELECT DISTINCT + col2 * col0 DIV col1 - + col1 AS col0 FROM tab1 AS cor0
----
-20
354
577

skipif mysql # not compatible
query I rowsort label-3869
SELECT DISTINCT + col2 * col0 / col1 - + col1 AS col0 FROM tab1 AS cor0
----
-20
354
577

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 col2 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + col1 + + ( 22 ) * + col1 FROM tab0 AS cor0
----
1978
2093
2231

query I rowsort
SELECT DISTINCT + col0 - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + cor0.col0 + - col2 * + 94 FROM tab1 cor0
----
-5073
-5294
-8944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3875
SELECT + - col2 * CAST( ( + col0 ) AS SIGNED ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-3875
SELECT + - col2 * CAST ( ( + col0 ) AS INTEGER ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - - col1 * + col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - cor0.col0 AS col0 FROM tab1, tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + 73 FROM tab1
----
73

query I rowsort
SELECT DISTINCT + 29 AS col1 FROM tab2
----
29

query I rowsort
SELECT ALL cor0.col0 * ( + col0 ) FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - cor0.col1 * - col0 + col2 + - cor0.col1 FROM tab0 AS cor0
----
2011
3299
8090

onlyif mysql # use DIV operator for integer division
query I rowsort label-3882
SELECT ALL - col0 DIV ( col0 ) - cor0.col2 col1 FROM tab0 cor0
----
-2
-34
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3882
SELECT ALL - col0 / ( col0 ) - cor0.col2 col1 FROM tab0 cor0
----
-2
-34
-83

query I rowsort
SELECT ALL + + col2 * - cor0.col2 + col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT col1 * - col0 * ( - col2 * cor0.col1 ) AS col0 FROM tab0 AS cor0
----
329315
5857632
60434738

query I rowsort
SELECT - col2 + - col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + cor0.col1 * 45 FROM tab2 AS cor0
----
1395
2655
765

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT - 78 * col2 - - col1 AS col1 FROM tab1 cor0
----
-4186
-4436
-7475

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT col2 * col1 - col2 * ( 1 ) FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + + 75 + + 54 FROM tab1 AS cor0
----
129
129
129

query I rowsort
SELECT + 78 AS col1 FROM tab0, tab1 AS cor0, tab0 cor1, tab1 AS cor2
----
81 values hashing to f0487ba81d377516702723e098c02ba1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3893
SELECT DISTINCT - cor0.col2 DIV 23 - col0 FROM tab0 AS cor0
----
-25
-35
-92

skipif mysql # not compatible
query I rowsort label-3893
SELECT DISTINCT - cor0.col2 / 23 - col0 FROM tab0 AS cor0
----
-25
-35
-92

query I rowsort
SELECT DISTINCT + tab0.col0 - - col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - 58 FROM tab2, tab0 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT - 65 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT tab2.col2 - col1 DIV + tab2.col0 AS col2 FROM tab2
----
23
26
38

skipif mysql # not compatible
query I rowsort label-3897
SELECT tab2.col2 - col1 / + tab2.col0 AS col2 FROM tab2
----
23
26
38

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to db428ec66bce13149e3129b417b0fe94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3899
SELECT ALL + cor0.col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3899
SELECT ALL + cor0.col2 / + col2 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT col1 + col1 * cor0.col0 + - ( + cor0.col2 + col0 ) FROM tab1 AS cor0
----
47
529
877

query I rowsort
SELECT ALL - - 29 + cor0.col2 AS col1 FROM tab0 AS cor0
----
111
30
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3902
SELECT ALL - + col0 DIV cor0.col2 + 43 AS col0 FROM tab1 AS cor0
----
42
43
43

skipif mysql # not compatible
query I rowsort label-3902
SELECT ALL - + col0 / cor0.col2 + 43 AS col0 FROM tab1 AS cor0
----
42
43
43

query I rowsort
SELECT col2 + - col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - cor0.col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + 35 * - col2 AS col2 FROM tab0 AS cor0
----
-1155
-2870
-35

query I rowsort
SELECT DISTINCT col1 * col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3907
SELECT ALL - - col2 DIV - col2 + col1 * + col2 FROM tab1 AS cor0
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-3907
SELECT ALL - - col2 / - col2 + col1 * + col2 FROM tab1 AS cor0
----
1247
1403
569

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab1, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

query I rowsort
SELECT ALL 92 * + col2 FROM tab2
----
2392
2484
3496

query I rowsort
SELECT ALL - 62 AS col1 FROM tab0
----
-62
-62
-62

query I rowsort
SELECT 10 AS col1 FROM tab2
----
10
10
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col1 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT - 19 FROM tab2, tab1, tab2 AS cor0
----
-19

query I rowsort
SELECT ALL - cor0.col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3915
SELECT DISTINCT + - col0 + col1 DIV col0 + col1 * - col1 AS col2 FROM tab2 cor0
----
-3559
-368
-964

skipif mysql # not compatible
query I rowsort label-3915
SELECT DISTINCT + - col0 + col1 / col0 + col1 * - col1 AS col2 FROM tab2 cor0
----
-3559
-368
-964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3916
SELECT CAST( - col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3916
SELECT CAST ( - col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 9 * - col1 + - col1 * - col0 + col1 AS col1 FROM tab0 AS cor0
----
1376
2619
7371

query I rowsort
SELECT DISTINCT + - ( + col2 ) + + col2 + col1 * col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3919
SELECT ALL + CAST( NULL AS SIGNED ) + 62 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3919
SELECT ALL + CAST ( NULL AS INTEGER ) + 62 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + 30 FROM tab0 AS cor0
----
30
30
30

query I rowsort
SELECT ALL cor0.col2 + + col0 + col2 FROM tab2 AS cor0
----
130
155
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3923
SELECT - + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3923
SELECT - + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + - col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 + + col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + col0 * col0 AS col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT col0 * + col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT cor1.col1 + + cor0.col0 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1a4f43ea4186b2b16e5524688d4e5ca6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3929
SELECT DISTINCT - cor0.col2 + CAST( - col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-3929
SELECT DISTINCT - cor0.col2 + CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 59bb9dc93b6f10de841a7db8eb3857e9

query I rowsort
SELECT DISTINCT + col0 + + ( col1 ) * col2 * col1 AS col2 FROM tab1 AS cor0
----
16304
36507
5764

query I rowsort
SELECT ALL - col1 + + col1 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT 83 + 24 FROM tab0, tab0 AS cor0
----
9 values hashing to 6f26a03989006af44e1b70d584e50047

query I rowsort
SELECT ALL + col1 - col0 * col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + + col0 + - 91 AS col0 FROM tab2 AS cor0
----
-12
-13
-84

query I rowsort
SELECT - col1 + - ( ( - col0 ) ) AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT col0 + + col2 * - 3 FROM tab2
----
-35
-74
0

query I rowsort
SELECT DISTINCT - cor0.col1 - col0 FROM tab2 cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - 76 + 88 col1 FROM tab1 cor0
----
1076
2064
848

onlyif mysql # use DIV operator for integer division
query I rowsort label-3940
SELECT - col1 DIV - col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3940
SELECT - col1 / - col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT tab1.col1 - tab1.col0 FROM tab1
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( + tab2.col1 ) + - col1 col1 FROM tab2
----
-1360
-248
-4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3943
SELECT col1 * CAST( - col0 + col0 AS SIGNED ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3943
SELECT col1 * CAST ( - col0 + col0 AS INTEGER ) FROM tab2
----
0
0
0

query I rowsort
SELECT + 51 - 29 FROM tab2, tab0 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT 24 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT ( col2 ) * col1 AS col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3947
SELECT - + CAST( NULL AS SIGNED ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3947
SELECT - + CAST ( NULL AS INTEGER ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col1 col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
26
27
38

query I rowsort
SELECT - tab2.col0 + + col0 * col1 AS col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT 59 * col2 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT + 86 FROM tab1, tab0 cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab1, tab1 cor0, tab2 cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT + - ( col0 ) + + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 + - col2 * 81 FROM tab0 AS cor0
----
-116
-2697
-6731

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT - - col2 + - col2 * - col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT + 40 * + col2 FROM tab1 AS cor0
----
2160
2280
3840

query I rowsort
SELECT 21 FROM tab0
----
21
21
21

query I rowsort
SELECT 39 + + col0 * 77 AS col1 FROM tab1
----
270
4967
6199

onlyif mysql # use DIV operator for integer division
query I rowsort label-3961
SELECT DISTINCT 80 + - col2 DIV + 6 FROM tab1
----
64
71

skipif mysql # not compatible
query I rowsort label-3961
SELECT DISTINCT 80 + - col2 / + 6 FROM tab1
----
64
71

query I rowsort
SELECT DISTINCT ( + col0 ) + + 25 FROM tab1
----
105
28
89

query I rowsort
SELECT DISTINCT 51 + col2 + tab2.col1 AS col0 FROM tab2
----
106
109
136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT col1 * cor0.col1 + col0 + - col2 AS col1 FROM tab0 AS cor0
----
7387
8288
9443

query I rowsort
SELECT - - cor0.col0 - + cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * - col1 AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + tab1.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT 57 + - col0 * - col2 + col1 FROM tab2
----
2144
277
3076

onlyif mysql # use DIV operator for integer division
query I rowsort label-3970
SELECT DISTINCT col0 DIV col1 + col1 FROM tab1
----
16
19
26

skipif mysql # not compatible
query I rowsort label-3970
SELECT DISTINCT col0 / col1 + col1 FROM tab1
----
16
19
26

query I rowsort
SELECT + col0 * tab1.col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT cor0.col1 * ( - cor0.col1 ) * col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL cor0.col0 + 15 FROM tab2 AS cor0
----
22
93
94

query I rowsort
SELECT - col2 * 99 AS col0 FROM tab2
----
-2574
-2673
-3762

query I rowsort
SELECT DISTINCT - col0 * ( col2 + + col2 ) AS col0 FROM tab0 AS cor0
----
-14596
-1584
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col2 col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT - col2 * 42 * - ( + tab1.col1 ) AS col1 FROM tab1
----
23940
52416
58968

query I rowsort
SELECT DISTINCT - col0 * ( - 85 ) AS col2 FROM tab2
----
595
6630
6715

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab0, tab0 AS cor1
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT col2 * + cor0.col2 * 32 + col0 * + col1 FROM tab1 AS cor0
----
104608
295952
93390

query I rowsort
SELECT - + col0 + + col2 + col1 AS col1 FROM tab0 AS cor0
----
63
84
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col0 * + 96 FROM tab2 AS cor0
----
672
7488
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 90 - + 38 col0 FROM tab1 AS cor0
----
-308
-5798
-7238

query I rowsort
SELECT 89 FROM tab0, tab0 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT + ( col1 + col1 ) FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT + 2 * col1 FROM tab1
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 * cor0.col1 col2 FROM tab1 cor0
----
1690
650
845

query I rowsort
SELECT ALL + - col0 * + col2 + - cor0.col1 * - 8 * - col1 + - ( + col0 ) AS col1 FROM tab0 AS cor0
----
-59984
-73635
-75342

query I rowsort
SELECT ALL - - 78 + - col1 * - cor0.col2 FROM tab0 AS cor0
----
175
2916
7540

onlyif mysql # use DIV operator for integer division
query I rowsort label-3991
SELECT ALL col2 + + col2 DIV ( - col2 * + col1 + 96 ) FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3991
SELECT ALL col2 + + col2 / ( - col2 * + col1 + 96 ) FROM tab1 cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3992
SELECT DISTINCT + CAST( - col1 AS SIGNED ) * col1 FROM tab2
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-3992
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) * col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 70 AS col1 FROM tab2
----
70

query I rowsort
SELECT DISTINCT 67 - - col2 AS col1 FROM tab1
----
121
124
163

query I rowsort
SELECT + 57 + + col2 AS col2 FROM tab0 AS cor0
----
139
58
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - col0 * col1 * 82 - 18 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-110810
-18280
-377832

query I rowsort
SELECT - col1 + - cor0.col0 * 44 FROM tab0 AS cor0
----
-1142
-1637
-4007

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col1 * col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + col2 - col0 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-4001
SELECT ALL col1 DIV + 61 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4001
SELECT ALL col1 / + 61 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL - 90 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

query I rowsort
SELECT - cor0.col2 + 62 FROM tab2 AS cor0
----
24
35
36

query I rowsort
SELECT + - col0 * - col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - cor0.col2 + + 16 AS col1 FROM tab2 AS cor0
----
-10
-11
-22

query I rowsort
SELECT + - 85 * col0 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT + 85 FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT ALL 19 AS col0 FROM tab2
----
19
19
19

query I rowsort
SELECT DISTINCT - 92 AS col2 FROM tab2, tab1 AS cor0, tab2 cor1
----
-92

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0, tab1 cor1, tab1 AS cor2
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to f8426cd4d01ba96a72d7348574fbbc8e

query I rowsort
SELECT ALL col1 + col1 * + col2 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT + ( col0 ) + col2 * col0 AS col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT 32 FROM tab1 AS cor0
----
32
32
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-4015
SELECT ALL + - CAST( col1 AS SIGNED ) + col0 DIV + 70 + col1 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4015
SELECT ALL + - CAST ( col1 AS INTEGER ) + col0 / + 70 + col1 FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT 25 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1475
425
775

query IIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0 CROSS JOIN tab2
----
243 values hashing to d489341cd587fd6eb0b972c5464c6ddc

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to 163d7732097d78f1cda7f65c2cea5a08

query I rowsort
SELECT + - col1 * - col2 + + col1 AS col0 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT + + 74 + 63 * col1 * - 23 AS col2 FROM tab1 AS cor0
----
-14416
-18763
-37600

query I rowsort
SELECT DISTINCT + col0 + - col0 * col2 AS col2 FROM tab2 cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-4022
SELECT DISTINCT + 58 DIV col2 + col1 FROM tab1 AS cor0
----
11
13
27

skipif mysql # not compatible
query I rowsort label-4022
SELECT DISTINCT + 58 / col2 + col1 FROM tab1 AS cor0
----
11
13
27

query I rowsort
SELECT ALL + col1 * cor0.col1 - col2 * 30 FROM tab1 AS cor0
----
-1610
-2711
-944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4024
SELECT - CAST( col1 AS SIGNED ) + col2 * col0 FROM tab1 AS cor0
----
136
3638
7667

skipif mysql # not compatible
query I rowsort label-4024
SELECT - CAST ( col1 AS INTEGER ) + col2 * col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT - col2 * + col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - cor0.col0 * cor0.col1 + col2 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT - + ( ( col1 ) ) + ( col1 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4029
SELECT DISTINCT - + CAST( - col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4029
SELECT DISTINCT - + CAST ( - col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - col2 - col2 AS col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL + ( + col0 ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4032
SELECT - col0 + - col1 DIV - cor0.col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-4032
SELECT - col0 + - col1 / - cor0.col0 FROM tab1 AS cor0
----
-64
-80
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 32 ) + + col2 * 71 col2 FROM tab2 AS cor0
----
1878
1949
2730

query I rowsort
SELECT DISTINCT + - 3 + - col2 + - col1 AS col1 FROM tab1 AS cor0
----
-112
-70
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 49 col0 FROM tab1 AS cor0
----
49
49
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 46 * col1 col1 FROM tab0 cor0
----
3956
4186
4462

query I rowsort
SELECT DISTINCT + 24 * + col2 AS col1 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT + ( + col2 ) * + 71 FROM tab2 AS cor0
----
1846
1917
2698

onlyif mysql # use DIV operator for integer division
query I rowsort label-4039
SELECT ALL cor0.col2 + - col2 DIV - 40 AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4039
SELECT ALL cor0.col2 + - col2 / - 40 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT cor0.col0 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL - 42 FROM tab0 cor0
----
-42
-42
-42

query I rowsort
SELECT DISTINCT - ( col0 ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + col2 * + col0 + - ( col0 ) * col0 * - col2 AS col0 FROM tab2 AS cor0
----
1512
160212
240160

query I rowsort
SELECT ALL + 53 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT ALL + col0 - + 99 * col1 FROM tab1 AS cor0
----
-1207
-2571
-926

query I rowsort
SELECT ALL - col1 * + 35 + - col1 AS col0 FROM tab2 AS cor0
----
-1116
-2124
-612

query I rowsort
SELECT ALL + - col1 - 10 AS col2 FROM tab1 AS cor0
----
-20
-23
-36

query I rowsort
SELECT 10 FROM tab0, tab2 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT col0 + ( + 19 ) * - col1 FROM tab1 AS cor0
----
-126
-167
-491

query I rowsort
SELECT DISTINCT - - col0 + col0 AS col1 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4051
SELECT CAST( NULL AS SIGNED ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4051
SELECT CAST ( NULL AS INTEGER ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - + col2 * ( + col0 ) + + col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 88 col1 FROM tab2, tab2 AS cor0
----
88

query I rowsort
SELECT - col1 + - 15 * - col1 FROM tab1 AS cor0
----
140
182
364

query I rowsort
SELECT DISTINCT cor0.col2 + - 61 AS col0 FROM tab1 AS cor0
----
-4
-7
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4056
SELECT DISTINCT - col2 + CAST( + col1 AS SIGNED ) * col2 AS col1 FROM tab2
----
1508
608
810

skipif mysql # not compatible
query I rowsort label-4056
SELECT DISTINCT - col2 + CAST ( + col1 AS INTEGER ) * col2 AS col1 FROM tab2
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-4057
SELECT ALL 60 * col2 DIV col1 AS col2 FROM tab0 AS cor0
----
0
23
54

skipif mysql # not compatible
query I rowsort label-4057
SELECT ALL 60 * col2 / col1 AS col2 FROM tab0 AS cor0
----
0
23
54

query I rowsort
SELECT ALL - ( col1 ) FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - ( - col2 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col0 * col1 AS col1 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4061
SELECT DISTINCT + col2 DIV tab1.col2 + col0 * + tab1.col0 FROM tab1
----
10
4097
6401

skipif mysql # not compatible
query I rowsort label-4061
SELECT DISTINCT + col2 / tab1.col2 + col0 * + tab1.col0 FROM tab1
----
10
4097
6401

query I rowsort
SELECT col1 * col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col1 + 55 AS col0 FROM tab0
----
-31
-36
-42

query I rowsort
SELECT DISTINCT + tab2.col1 + - ( col1 ) * col2 FROM tab2
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-4065
SELECT + col1 - + 20 DIV - tab2.col0 AS col0 FROM tab2
----
17
33
59

skipif mysql # not compatible
query I rowsort label-4065
SELECT + col1 - + 20 / - tab2.col0 AS col0 FROM tab2
----
17
33
59

query I rowsort
SELECT - col0 + - 30 + ( - col2 ) FROM tab1
----
-151
-206
-87

query I rowsort
SELECT ALL - tab2.col0 * - 65 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to dac968b8ac8be9ece31e6d5d361e05ff

query I rowsort
SELECT ALL 13 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab1, tab1 cor1
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

onlyif mysql # use DIV operator for integer division
query I rowsort label-4070
SELECT + col0 DIV + col0 + 15 FROM tab0 AS cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-4070
SELECT + col0 / + col0 + 15 FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT ALL + col1 * + col0 + 3 FROM tab2 AS cor0
----
1346
220
4605

query I rowsort
SELECT DISTINCT - + col1 * col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + col0 * + tab1.col2 AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + col1 * + col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT + tab1.col2 * tab1.col2 AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ALL col2 * + 86 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT DISTINCT - + col0 + col0 * ( - col0 ) AS col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT + - col2 + + 0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4079
SELECT + col0 DIV col0 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4079
SELECT + col0 / col0 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + col0 + 26 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-1401
-1418
-2416

query I rowsort
SELECT - + col2 * col2 * col0 AS col0 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT 50 AS col2 FROM tab1, tab2 AS cor0
----
50

query I rowsort
SELECT col2 * - col0 + col1 * + 97 FROM tab0
----
1529
7550
9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-4084
SELECT col2 * tab1.col0 DIV - col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4084
SELECT col2 * tab1.col0 / - col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + 26 AS col2 FROM tab0
----
26
26
26

query I rowsort
SELECT DISTINCT - cor0.col2 AS col0 FROM tab2, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - col2 - - col2 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 77 + col1 AS col0 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT - cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT - 71 + 49 AS col0 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT - 39 FROM tab1, tab2 cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query I rowsort
SELECT DISTINCT + col2 * - col1 + - col1 * 87 FROM tab1 AS cor0
----
-1440
-2379
-3666

onlyif mysql # use DIV operator for integer division
query I rowsort label-4093
SELECT DISTINCT 23 * 52 + - col1 DIV 91 + + 62 AS col0 FROM tab2 AS cor0
----
1258

skipif mysql # not compatible
query I rowsort label-4093
SELECT DISTINCT 23 * 52 + - col1 / 91 + + 62 AS col0 FROM tab2 AS cor0
----
1258

query I rowsort
SELECT + + ( - ( col0 ) ) + col2 * ( col2 + + col2 ) FROM tab1 AS cor0
----
18352
5829
6434

onlyif mysql # use DIV operator for integer division
query I rowsort label-4095
SELECT - - cor0.col2 + - col1 DIV + col0 AS col0 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-4095
SELECT - - cor0.col2 + - col1 / + col0 AS col0 FROM tab2 AS cor0
----
23
26
38

query I rowsort
SELECT DISTINCT col2 + - 40 AS col1 FROM tab1 AS cor0
----
14
17
56

query I rowsort
SELECT ALL + 22 + - col1 FROM tab0 AS cor0
----
-64
-69
-75

query I rowsort
SELECT ALL - ( + col2 ) + col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col0 * - col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - + 72 + + col2 * col0 + col1 * col1 * - 33 FROM tab0 AS cor0
----
-243348
-266047
-310534

onlyif mysql # use DIV operator for integer division
query I rowsort label-4102
SELECT + col2 DIV - cor0.col1 + col0 + + col1 AS col1 FROM tab2 AS cor0
----
137
38
94

skipif mysql # not compatible
query I rowsort label-4102
SELECT + col2 / - cor0.col1 + col0 + + col1 AS col1 FROM tab2 AS cor0
----
137
38
94

query I rowsort
SELECT ALL - + col0 * - col0 + + ( 97 ) FROM tab2 AS cor0
----
146
6181
6338

query I rowsort
SELECT + - col2 + col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4105
SELECT DISTINCT 46 + - col2 + + CAST( NULL AS SIGNED ) * col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4105
SELECT DISTINCT 46 + - col2 + + CAST ( NULL AS INTEGER ) * col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL 26 * col1 AS col2 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT ALL col1 * + cor0.col2 * col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT col2 + 98 FROM tab1
----
152
155
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + tab0.col0 ) * col0 + col2 col2 FROM tab0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-4110
SELECT ALL + 85 DIV + col1 + - col0 AS col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4110
SELECT ALL + 85 / + col1 + - col0 AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT + 44 + 87 * + col0 * - ( col1 * - col1 ) AS col0 FROM tab1
----
1176284
176480
556844

query I rowsort
SELECT - col2 * + cor0.col1 + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col2 ) col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - 1 * col0 AS col0 FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 30 col2 FROM tab0
----
30
30
30

query I rowsort
SELECT + col2 + - col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4117
SELECT col1 + + col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4117
SELECT col1 + + col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4118
SELECT + CAST( NULL AS SIGNED ) + 72 + col2 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4118
SELECT + CAST ( NULL AS INTEGER ) + 72 + col2 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + - 11 * col0 + col2 FROM tab1 AS cor0
----
-647
-784
21

query I rowsort
SELECT + col1 - + cor0.col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT col0 * + col0 AS col2 FROM tab1
----
4096
6400
9

query I rowsort
SELECT + - cor0.col1 * 80 + ( col0 ) * + col0 FROM tab1 AS cor0
----
-2071
3296
5360

onlyif mysql # use DIV operator for integer division
query I rowsort label-4123
SELECT + - col2 DIV + cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4123
SELECT + - col2 / + cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4124
SELECT col1 DIV col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4124
SELECT col1 / col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL 49 * col1 AS col2 FROM tab2
----
1519
2891
833

query I rowsort
SELECT + tab0.col0 * + col1 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ( + 30 ) + col2 FROM tab1 AS cor0
----
126
84
87

query I rowsort
SELECT + 84 FROM tab0 AS cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( - 4 AS REAL ) * col0 FROM tab0 AS cor0
----
140
356
96

query I rowsort
SELECT - ( 26 ) AS col0 FROM tab1 AS cor0
----
-26
-26
-26

query I rowsort
SELECT ALL - col2 * - col0 AS col1 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - ( cor0.col1 ) + - cor0.col2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 5f7b5c5678d2f6f42d8763f44ca95184

query I rowsort
SELECT DISTINCT + tab0.col1 AS col2 FROM tab0, tab2 AS cor0
----
86
91
97

query I rowsort
SELECT + col2 + tab0.col0 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT + ( + 18 ) FROM tab0 AS cor0
----
18

query I rowsort
SELECT + - col2 + + col0 AS col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL cor0.col1 * - col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4140
SELECT ALL CAST( NULL AS DECIMAL ) * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4140
SELECT ALL CAST ( NULL AS REAL ) * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + cor0.col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + - ( + col0 ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - ( 59 ) FROM tab2 cor0
----
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4144
SELECT ALL - - ( 24 ) + col0 * + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
1249
600
7945

skipif mysql # not compatible
query I rowsort label-4144
SELECT ALL - - ( 24 ) + col0 * + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
1249
600
7945

query I rowsort
SELECT + 39 * + 55 FROM tab1 AS cor0
----
2145
2145
2145

query I rowsort
SELECT + col2 - - col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + 93 * col0 * col2 FROM tab2 cor0
----
17577
188604
279186

query I rowsort
SELECT ALL col0 * cor0.col2 + col2 AS col1 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT - col1 * - col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab2, tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4151
SELECT ALL + col0 + + cor0.col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-4151
SELECT ALL + col0 + + cor0.col1 / - col1 AS col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT DISTINCT + ( col1 + tab1.col2 ) AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT col0 + + col2 AS col2 FROM tab1 cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4155
SELECT ALL col0 DIV col2 + - col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
-1
0
34

skipif mysql # not compatible
query I rowsort label-4155
SELECT ALL col0 / col2 + - col1 / + col1 AS col2 FROM tab0 AS cor0
----
-1
0
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4156
SELECT DISTINCT col1 DIV col0 AS col2 FROM tab2
----
0
4

skipif mysql # not compatible
query I rowsort label-4156
SELECT DISTINCT col1 / col0 AS col2 FROM tab2
----
0
4

query I rowsort
SELECT - - cor0.col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + - col2 * col0 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - col1 + col2 * col2 AS col0 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT ALL col2 - + col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 + + col1 * + col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 + + col2 col1 FROM tab2
----
0
0
0

query I rowsort
SELECT col0 + col0 AS col0 FROM tab0
----
178
48
70

query I rowsort
SELECT + col1 * + col1 + col2 AS col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT - col0 - col1 AS col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT ( - col0 ) + - col2 AS col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - cor0.col0 + - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - col0 + cor0.col0 FROM tab2 cor0
----
0

query I rowsort
SELECT + - 68 AS col2 FROM tab1 AS cor0
----
-68
-68
-68

query I rowsort
SELECT ALL - col1 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + - 87 - - cor0.col2 * col1 AS col1 FROM tab1 AS cor0
----
1161
1317
483

query I rowsort
SELECT + - 92 + + col2 FROM tab2 AS cor0
----
-54
-65
-66

query I rowsort
SELECT ALL - col1 + col2 * - col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-4175
SELECT DISTINCT + col2 + col2 + cor0.col1 DIV col2 FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-4175
SELECT DISTINCT + col2 + col2 + cor0.col1 / col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + 35 FROM tab1
----
35
35
35

query I rowsort
SELECT + - col1 * + col1 * + col0 AS col2 FROM tab0 AS cor0
----
-177504
-329315
-737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 * col0 + - col1 + col0 * - col0 col1 FROM tab2 AS cor0
----
113509
44776
5779

query I rowsort
SELECT ALL - - 66 AS col0 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT DISTINCT + 85 * - cor0.col1 FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT + col0 + + col1 * col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL col1 + col0 * - col2 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - ( col2 ) * col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL ( + tab0.col2 ) * + col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + 39 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT ALL - col2 * col0 + col2 - col1 AS col2 FROM tab1
----
-134
-3601
-7597

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 15 col1 FROM tab2
----
15
15
15

query I rowsort
SELECT col2 * tab1.col0 FROM tab1
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4189
SELECT DISTINCT CAST( NULL AS SIGNED ) * tab1.col0 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4189
SELECT DISTINCT CAST ( NULL AS INTEGER ) * tab1.col0 AS col0 FROM tab1
----
NULL

query I rowsort
SELECT ALL 91 * + col0 * col1 AS col1 FROM tab0
----
187824
308945
737009

query I rowsort
SELECT col0 + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col0 * col1 * col1 + col1 * col2 AS col1 FROM tab2
----
23477
273052
7564

query I rowsort
SELECT + col1 + + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 * - col2 col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col2 * - tab0.col2 * + col2 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT DISTINCT col2 * - col1 AS col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT col1 - + col1 AS col2 FROM tab1 WHERE ( + col1 + + col1 / col1 ) <> col1
----
0

query I rowsort
SELECT - col0 * col2 AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col1 * col2 FROM tab0 WHERE NULL IN ( col2 )
----

query I rowsort
SELECT DISTINCT + tab1.col1 * + col1 AS col2 FROM tab1
----
100
169
676

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) NOT IN ( - col2 * + col2 )
----

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN ( - col1 ) AND col0
----

query I rowsort
SELECT - tab1.col0 * col1 * + tab1.col0 AS col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT col1 * - col0 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col1 * - tab2.col0 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT col0 * + col2 - col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT ALL col0 * + col1 AS col2 FROM tab2 WHERE NOT ( NULL ) IN ( - col1 + col1 )
----

query I rowsort
SELECT DISTINCT - col0 * + col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL col0 * + tab0.col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT col0 * col2 * tab1.col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT ALL cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col2 * + cor0.col1 + col1 + - col2 FROM tab1 AS cor0
----
1165
1376
523

query I rowsort
SELECT - col1 * + col0 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 AS col2 FROM tab2 WHERE ( NULL ) IN ( col0 )
----

query I rowsort
SELECT ALL + col1 * - col0 * + col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - col0 * col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col2 + + col1 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT col1 AS col0 FROM tab2 WHERE NOT + col0 + + col2 * + col0 * - col1 + col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL + tab1.col2 * - col0 AS col0 FROM tab1
----
-162
-3648
-7680

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( col0 + + col0 / col2 ) <> NULL
----

query I rowsort
SELECT - col1 + col1 + - col0 FROM tab2
----
-7
-78
-79

query III rowsort
SELECT * FROM tab1 WHERE ( - col0 ) NOT IN ( col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT tab2.col0 * + col2 * + col2 + col2 * - col1 FROM tab2
----
113430
4266
51194

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL >= - col2 + col1 - + col1 * col1
----

query I rowsort
SELECT + tab2.col1 * - tab2.col1 AS col1 FROM tab2
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 col0 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT col2 + - tab2.col2 FROM tab2
----
0

query I rowsort
SELECT - tab2.col2 * col2 + + tab2.col0 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT + col2 - col0 * tab2.col0 AS col1 FROM tab2
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4230
SELECT tab2.col2 * col1 + + col2 DIV + col1 AS col0 FROM tab2
----
1534
648
837

skipif mysql # not compatible
query I rowsort label-4230
SELECT tab2.col2 * col1 + + col2 / + col1 AS col0 FROM tab2
----
1534
648
837

query III rowsort
SELECT * FROM tab1 WHERE col1 * col2 <= NULL
----

query I rowsort
SELECT DISTINCT + col0 * - col1 - col0 AS col1 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT tab2.col2 - - col0 * + tab2.col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT col2 + col0 * - col1 FROM tab0
----
-2031
-3394
-8017

query IIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT + - col1 * - cor0.col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT col2 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col0 + + col1 * col1 * + col2 AS col2 FROM tab0 AS cor0
----
244092
679131
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col0 + - col0 * - col0 * - col0 col1 FROM tab2 cor0
----
-154
-472524
-490037

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 col1 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4241
SELECT + col2 DIV + col2 AS col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4241
SELECT + col2 / + col2 AS col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + - col2 * col2 + col1 AS col1 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT ALL - - col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT col2 + + col1 * - col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT col2 + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col1 * - col2 * + cor0.col2 AS col0 FROM tab0 cor0
----
-611884
-93654
-97

query I rowsort
SELECT col1 * - col2 + col0 * col1 + col0 AS col1 FROM tab0 AS cor0
----
-750
3333
726

query I rowsort
SELECT + col1 + col0 + + col0 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 + col2 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT col2 * + col1 + col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + col1 FROM tab1 AS cor0 WHERE NOT NULL IN ( - col2 / col1 + - col1 / cor0.col0 + col1 * + cor0.col1 )
----

query I rowsort
SELECT DISTINCT + col2 + col0 * cor0.col0 * - col1 AS col2 FROM tab1 AS cor0
----
-180
-40903
-83104

query I rowsort
SELECT col0 - col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT col0 * + cor0.col0 FROM tab1 AS cor0 WHERE cor0.col0 * + col1 <> NULL
----

query I rowsort
SELECT col1 - - 34 AS col2 FROM tab2 AS cor0
----
51
65
93

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + - col1 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col0 * cor0.col1 + + col1 FROM tab0 cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 75 col0 FROM tab2 AS cor0
----
75

query I rowsort
SELECT - col0 * 23 AS col0 FROM tab0 AS cor0
----
-2047
-552
-805

query I rowsort
SELECT ALL - cor0.col2 * + cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - 98 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-294
-6272
-7840

query I rowsort
SELECT - - ( - col2 ) + + col0 * - cor0.col0 AS col1 FROM tab0 cor0
----
-1226
-609
-8003

query I rowsort
SELECT - col2 + + ( col2 ) FROM tab2
----
0
0
0

query I rowsort
SELECT col2 * + col1 + col1 + col2 * 40 AS col0 FROM tab2
----
1948
2183
2633

onlyif mysql # use DIV operator for integer division
query I rowsort label-4266
SELECT DISTINCT + col0 DIV 17 + + col1 FROM tab0
----
87
96
99

skipif mysql # not compatible
query I rowsort label-4266
SELECT DISTINCT + col0 / 17 + + col1 FROM tab0
----
87
96
99

query I rowsort
SELECT DISTINCT - col1 * - col0 + col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT cor0.col0 - 36 FROM tab2 AS cor0
----
-29
42
43

query I rowsort
SELECT + col0 * + 95 + col1 AS col2 FROM tab0 cor0
----
2366
3422
8546

query I rowsort
SELECT ALL - col1 + col0 AS col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT - 74 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
-74

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab1, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - - 90 FROM tab0 AS cor0
----
90
90
90

query I rowsort
SELECT ALL - 98 FROM tab2
----
-98
-98
-98

query I rowsort
SELECT col0 * 45 AS col0 FROM tab1
----
135
2880
3600

query I rowsort
SELECT ALL - + ( + 32 ) * - col1 - ( 35 ) AS col1 FROM tab0 AS cor0
----
2717
2877
3069

query I rowsort
SELECT + 22 * cor0.col1 + - col1 * col0 FROM tab2 AS cor0
----
-3304
-969
465

query I rowsort
SELECT 31 AS col1 FROM tab2
----
31
31
31

query I rowsort
SELECT ALL 54 * 42 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1757edd5598cc48cbcb1a1538545d21f

query I rowsort
SELECT ( col0 ) + + col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT 45 * cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
1170
450
585

query I rowsort
SELECT DISTINCT - 67 AS col2 FROM tab1, tab2 AS cor0
----
-67

query I rowsort
SELECT col0 * - col2 AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4284
SELECT col2 DIV - ( 90 ) FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4284
SELECT col2 / - ( 90 ) FROM tab1
----
-1
0
0

query I rowsort
SELECT DISTINCT + col0 * 95 + ( + col1 ) + 97 FROM tab1
----
408
6187
7710

onlyif mysql # use DIV operator for integer division
query I rowsort label-4286
SELECT col2 DIV 41 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4286
SELECT col2 / 41 AS col0 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * tab0.col0 + 2 col0 FROM tab0
----
1227
578
7923

query I rowsort
SELECT DISTINCT col2 * + col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT tab0.col1 * ( col2 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT col0 - col1 * - ( cor0.col1 + col1 ) FROM tab1 AS cor0
----
1355
264
418

onlyif mysql # use DIV operator for integer division
query I rowsort label-4291
SELECT DISTINCT + - 60 + + cor0.col0 DIV - cor0.col2 AS col1 FROM tab0, tab0 cor0
----
-60
-61
-95

skipif mysql # not compatible
query I rowsort label-4291
SELECT DISTINCT + - 60 + + cor0.col0 / - cor0.col2 AS col1 FROM tab0, tab0 cor0
----
-60
-61
-95

query I rowsort
SELECT + col1 * ( cor0.col1 ) + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - col0 + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT - + col0 * col1 + 6 FROM tab2 AS cor0
----
-1337
-211
-4596

query I rowsort
SELECT DISTINCT - 19 FROM tab1, tab2 AS cor0
----
-19

query I rowsort
SELECT DISTINCT + 70 AS col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
70

query I rowsort
SELECT - cor0.col2 * 3 AS col1 FROM tab0 cor0
----
-246
-3
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + col0 col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4299
SELECT + col2 + col0 DIV + cor0.col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4299
SELECT + col2 + col0 / + cor0.col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + - ( - col1 ) * col1 + col2 * + col2 FROM tab1 cor0
----
3349
3592
9385

query I rowsort
SELECT ALL + tab2.col1 + col1 - tab2.col0 AS col1 FROM tab2
----
-45
40
55

query I rowsort
SELECT + - 23 * col1 FROM tab0 AS cor0
----
-1978
-2093
-2231

query I rowsort
SELECT DISTINCT - cor0.col2 + + 97 * col2 AS col1 FROM tab1 cor0
----
5184
5472
9216

query I rowsort
SELECT - ( + 89 ) - col0 AS col0 FROM tab2 AS cor0
----
-167
-168
-96

query I rowsort
SELECT DISTINCT - 23 AS col2 FROM tab0 AS cor0
----
-23

query I rowsort
SELECT - ( + col2 ) + + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 37 - - 37 * - col1 AS col0 FROM tab1 cor0
----
-407
-518
-999

query I rowsort
SELECT ALL cor0.col0 * col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( - cor0.col2 ) col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - 92 AS col0 FROM tab0
----
-92
-92
-92

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 81a27955147133c47c9e8e63dacc5c37

query I rowsort
SELECT ALL cor1.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - col0 * cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - - col1 * col1 * col0 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT + + col0 + 97 FROM tab0 AS cor0
----
121
132
186

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT cor0.col1 + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 23 col2 FROM tab0
----
23
23
23

query I rowsort
SELECT 43 FROM tab0
----
43
43
43

query I rowsort
SELECT ALL + 65 FROM tab2
----
65
65
65

query I rowsort
SELECT ALL ( + col0 + + 8 ) FROM tab1
----
11
72
88

query I rowsort
SELECT + 24 FROM tab0
----
24
24
24

query I rowsort
SELECT DISTINCT - col0 * - col2 * 39 + + col2 FROM tab0
----
1366
284704
30921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4324
SELECT DISTINCT CAST( NULL AS SIGNED ) col2 FROM tab2, tab0 AS cor0, tab1 cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4324
SELECT DISTINCT CAST ( NULL AS INTEGER ) col2 FROM tab2, tab0 AS cor0, tab1 cor1
----
NULL

query I rowsort
SELECT ALL tab1.col1 + col1 AS col1 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT - 58 * col2 * + col2 + + 66 FROM tab0
----
-389926
-63096
8

query I rowsort
SELECT ALL - col0 * - col1 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + - col0 col1 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT col1 * - col1 + - col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT ALL + ( col2 ) * + 65 FROM tab0 AS cor0
----
2145
5330
65

query I rowsort
SELECT ALL - cor0.col0 + col0 * col1 - - 15 AS col0 FROM tab2 cor0
----
1279
225
4539

query I rowsort
SELECT + + col2 * col0 + 61 FROM tab0 AS cor0
----
7359
853
96

query I rowsort
SELECT - cor0.col1 + cor0.col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT col1 * + col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col1 * - cor0.col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + + cor0.col2 * - 70 FROM tab2 AS cor0
----
-1820
-1890
-2660

query I rowsort
SELECT DISTINCT + + col0 + - col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT col1 * + col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT col1 + - 79 FROM tab0 AS cor0
----
12
18
7

query I rowsort
SELECT ALL + col2 + + col2 * + col0 + col2 AS col0 FROM tab2 AS cor0
----
2080
243
3078

query I rowsort
SELECT DISTINCT col1 + + col1 * 82 AS col0 FROM tab0 AS cor0
----
7138
7553
8051

query I rowsort
SELECT DISTINCT - col0 + 67 AS col0 FROM tab1 AS cor0
----
-13
3
64

query I rowsort
SELECT ALL col1 + col2 AS col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT + col0 + + ( - 50 ) * cor0.col0 FROM tab2 AS cor0
----
-343
-3822
-3871

onlyif mysql # use DIV operator for integer division
query I rowsort label-4345
SELECT - col2 * col2 DIV col0 + col2 FROM tab2
----
-77
18
20

skipif mysql # not compatible
query I rowsort label-4345
SELECT - col2 * col2 / col0 + col2 FROM tab2
----
-77
18
20

query I rowsort
SELECT DISTINCT - col0 AS col1 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT + 71 AS col1 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 - col1 * 28 col2 FROM tab1 AS cor0
----
-4376
-6764
-737

query I rowsort
SELECT - - ( - col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + ( - col0 ) - col2 * 63 FROM tab0 AS cor0
----
-2103
-5255
-98

query I rowsort
SELECT col1 - + col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT cor0.col2 + 40 * - col0 - + 98 FROM tab2 AS cor0
----
-3192
-3220
-351

query I rowsort
SELECT ALL + 20 FROM tab0, tab0 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT col0 - col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - + 10 * - col2 + cor0.col1 AS col2 FROM tab0 AS cor0
----
107
416
911

onlyif mysql # use DIV operator for integer division
query I rowsort label-4356
SELECT DISTINCT - col1 - col2 DIV - col0 FROM tab1 AS cor0
----
-10
-12
-8

skipif mysql # not compatible
query I rowsort label-4356
SELECT DISTINCT - col1 - col2 / - col0 FROM tab1 AS cor0
----
-10
-12
-8

query I rowsort
SELECT - col2 * + col1 + + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + - 12 + 82 * col2 AS col0 FROM tab2 AS cor0
----
2120
2202
3104

query I rowsort
SELECT - 98 * cor0.col2 - + col2 AS col2 FROM tab0 AS cor0
----
-3267
-8118
-99

query I rowsort
SELECT ALL - + cor0.col2 * - col1 - - col1 AS col0 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT col0 * col1 * col2 + cor0.col0 * col0 FROM tab1 AS cor0
----
106240
40576
4221

query I rowsort
SELECT DISTINCT col0 + + col0 * - col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT - cor0.col2 + col1 AS col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + 25 - + col2 * col0 FROM tab2 AS cor0
----
-164
-2003
-2977

query I rowsort
SELECT - ( col2 ) * - tab0.col0 + col1 FROM tab0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-4366
SELECT ALL - tab2.col0 - 64 DIV + col1 AS col2 FROM tab2
----
-79
-82
-9

skipif mysql # not compatible
query I rowsort label-4366
SELECT ALL - tab2.col0 - 64 / + col1 AS col2 FROM tab2
----
-79
-82
-9

query I rowsort
SELECT + 14 + + col0 AS col2 FROM tab2
----
21
92
93

query I rowsort
SELECT + ( - col1 ) * cor0.col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT ( tab0.col1 ) AS col2 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4370
SELECT - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4370
SELECT - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 - col1 * ( col1 ) FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT + 16 + + col1 AS col2 FROM tab1 AS cor0
----
26
29
42

query I rowsort
SELECT DISTINCT + col0 * col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL col2 + col2 FROM tab0 cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4375
SELECT ALL + ( + col1 ) - CAST( ( - col0 ) AS SIGNED ) DIV col2 AS col0 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-4375
SELECT ALL + ( + col1 ) - CAST ( ( - col0 ) AS INTEGER ) / col2 AS col0 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT DISTINCT col2 * col0 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - - 93 + + col1 FROM tab1 AS cor0
----
103
106
119

onlyif mysql # use DIV operator for integer division
query I rowsort label-4378
SELECT - ( 87 ) DIV col1 - - col1 AS col1 FROM tab2
----
12
29
58

skipif mysql # not compatible
query I rowsort label-4378
SELECT - ( 87 ) / col1 - - col1 AS col1 FROM tab2
----
12
29
58

query I rowsort
SELECT ALL 34 * + 77 - - tab1.col0 FROM tab1
----
2621
2682
2698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 26 * - col0 * - 36 col0 FROM tab2 AS cor0
----
-6552
-73008
-73944

query I rowsort
SELECT ALL + 59 FROM tab1 AS cor0
----
59
59
59

query I rowsort
SELECT ALL - - ( + col1 ) * + col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + + col0 * col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + col2 + - col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL col0 * - col0 - col1 * col2 AS col2 FROM tab1 AS cor0
----
-1413
-4666
-7648

query I rowsort
SELECT col0 * + col2 + cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * col2 col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4388
SELECT ALL CAST( NULL AS SIGNED ) + - 24 - - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4388
SELECT ALL CAST ( NULL AS INTEGER ) + - 24 - - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4389
SELECT CAST( NULL AS SIGNED ) + + col1 - - col2 * - tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4389
SELECT CAST ( NULL AS INTEGER ) + + col1 - - col2 * - tab1.col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( - tab1.col1 ) * - col0 * + 22 - col2 FROM tab1
----
14023
1662
22784

query I rowsort
SELECT ALL col1 - + col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 89 + col1 FROM tab2 AS cor0
----
106
120
148

query I rowsort
SELECT DISTINCT - ( + col2 ) * - col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col2 * col0 * + ( - 91 ) + cor0.col2 * - ( col2 + + col0 ) FROM tab1 AS cor0
----
-17820
-338865
-715776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * col0 col1 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4397
SELECT DISTINCT + 90 DIV col0 FROM tab1 AS cor0
----
1
30

skipif mysql # not compatible
query I rowsort label-4397
SELECT DISTINCT + 90 / col0 FROM tab1 AS cor0
----
1
30

query I rowsort
SELECT 48 * - col0 AS col2 FROM tab2 AS cor0
----
-336
-3744
-3792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 19 * + col2 * - 51 col1 FROM tab1 AS cor0
----
-52326
-55233
-93024

query I rowsort
SELECT + cor0.col1 * col0 + - col2 * - col1 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT DISTINCT 18 * col1 - 31 * - col2 FROM tab2 AS cor0
----
1395
1484
1868

query I rowsort
SELECT col2 * + col2 + col2 AS col0 FROM tab1 cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4403
SELECT ALL + - 79 DIV col1 AS col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4403
SELECT ALL + - 79 / col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + col0 - + cor0.col2 FROM tab1 AS cor0
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4406
SELECT DISTINCT + 67 DIV - 31 AS col2 FROM tab1, tab1 cor0
----
-2

skipif mysql # not compatible
query I rowsort label-4406
SELECT DISTINCT + 67 / - 31 AS col2 FROM tab1, tab1 cor0
----
-2

query I rowsort
SELECT 73 AS col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT tab2.col0 + - ( 39 ) FROM tab2
----
-32
39
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-4409
SELECT - - cor0.col1 DIV col2 col0 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4409
SELECT - - cor0.col1 / col2 col0 FROM tab0 AS cor0
----
1
2
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4410
SELECT + col1 + + CAST( + 92 AS SIGNED ) FROM tab2 AS cor0
----
109
123
151

skipif mysql # not compatible
query I rowsort label-4410
SELECT + col1 + + CAST ( + 92 AS INTEGER ) FROM tab2 AS cor0
----
109
123
151

query I rowsort
SELECT - col2 - - col2 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT - ( + col1 ) AS col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - + 60 FROM tab1 AS cor0
----
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4414
SELECT + - CAST( + 5 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-5
-5
-5

skipif mysql # not compatible
query I rowsort label-4414
SELECT + - CAST ( + 5 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT + ( col2 ) AS col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + 16 AS col1 FROM tab1 cor0
----
16
16
16

query I rowsort
SELECT - 86 * + col2 + + tab1.col1 FROM tab1
----
-4618
-4892
-8243

query I rowsort
SELECT + 95 FROM tab2
----
95
95
95

query I rowsort
SELECT 13 * col1 AS col2 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT ALL + col0 + 82 AS col1 FROM tab0 AS cor0
----
106
117
171

query I rowsort
SELECT - col0 * - ( - cor0.col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to 2c9bc625661696fa1cf187c4d0f703a1

query I rowsort
SELECT - col2 + + col0 * - col0 * col1 AS col1 FROM tab1 cor0
----
-288
-41017
-83296

query I rowsort
SELECT 25 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query I rowsort
SELECT DISTINCT - 9 AS col2 FROM tab1 AS cor0
----
-9

query I rowsort
SELECT - cor0.col2 + - ( col2 ) * + col2 AS col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT + col2 - ( col2 + - col1 ) * 50 FROM tab2 cor0
----
-1012
1676
227

query I rowsort
SELECT DISTINCT cor0.col2 + ( col2 ) * - cor0.col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT - + col0 - + col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL cor0.col2 * 71 AS col0 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT - col0 * 5 + col1 + + col2 * 15 FROM tab2 AS cor0
----
192
401
59

query I rowsort
SELECT DISTINCT + cor0.col0 + cor0.col1 + + 93 FROM tab2 AS cor0
----
131
189
230

query I rowsort
SELECT DISTINCT + col2 * 57 + col1 AS col0 FROM tab1 AS cor0
----
3104
3259
5485

query I rowsort
SELECT - col2 + + ( - col1 ) FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + - col1 - + col2 * 95 FROM tab2 AS cor0
----
-2529
-2596
-3627

onlyif mysql # use DIV operator for integer division
query I rowsort label-4437
SELECT DISTINCT + - col1 DIV - col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4437
SELECT DISTINCT + - col1 / - col0 FROM tab0 cor0
----
1
2
3

query I rowsort
SELECT DISTINCT + cor0.col0 * - 35 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
-2183
-2704
-51

query I rowsort
SELECT - col0 + - ( col2 ) * - col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT - col1 + + 48 * col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
13855
167029
46097

query I rowsort
SELECT + 26 + col0 - col1 AS col0 FROM tab2 AS cor0
----
2
45
88

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab2 cor1, tab2 AS cor2
----
972 values hashing to a698694a7dac245e42212ff0316bdf45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4443
SELECT + CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4443
SELECT + CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 14 ) * col0 - col0 * + col0 AS col0 FROM tab2 AS cor0
----
-147
-7176
-7347

query I rowsort
SELECT cor0.col0 * - col1 + col2 * + 47 AS col1 FROM tab0 AS cor0
----
-3348
-4245
-513

query I rowsort
SELECT ALL col2 + 53 AS col2 FROM tab2
----
79
80
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-4447
SELECT ALL - col0 + + col0 DIV col1 FROM tab2
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-4447
SELECT ALL - col0 + + col0 / col1 FROM tab2
----
-7
-75
-77

query I rowsort
SELECT ALL - - ( - col2 ) * + col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4449
SELECT CAST( NULL AS SIGNED ) FROM tab2, tab0 cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4449
SELECT CAST ( NULL AS INTEGER ) FROM tab2, tab0 cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT col2 + col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4451
SELECT ALL col2 DIV + col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4451
SELECT ALL col2 / + col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT col1 + col2 AS col0 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4453
SELECT - col0 DIV col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4453
SELECT - col0 / col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col2 - - col0 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT col1 - + col2 * - col0 * - col1 FROM tab1
----
-36470
-4186
-99827

query I rowsort
SELECT col1 - + col2 AS col2 FROM tab1
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 col1 FROM tab0 WHERE col1 >= NULL
----

query I rowsort
SELECT cor0.col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT - tab0.col2 - - col2 AS col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4460
SELECT tab0.col2 DIV - col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4460
SELECT tab0.col2 / - col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT 86 AS col2 FROM tab0
----
86
86
86

query I rowsort
SELECT DISTINCT - cor0.col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - + cor0.col0 * + col1 * col0 FROM tab2 cor0
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-4464
SELECT ALL + 76 + - col1 DIV - ( col2 ) FROM tab0 AS cor0
----
173
77
78

skipif mysql # not compatible
query I rowsort label-4464
SELECT ALL + 76 + - col1 / - ( col2 ) FROM tab0 AS cor0
----
173
77
78

query I rowsort
SELECT + 52 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 col0 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL - - col1 + 13 * - col0 FROM tab0 AS cor0
----
-1066
-226
-358

query I rowsort
SELECT + 57 AS col0 FROM tab1
----
57
57
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4469
SELECT + col0 DIV + col2 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4469
SELECT + col0 / + col2 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL - tab0.col2 * + col2 AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 40 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
40

query I rowsort
SELECT - - cor0.col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT + tab0.col2 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT + col1 - + col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL col0 * ( 78 ) FROM tab1
----
234
4992
6240

query I rowsort
SELECT - 2 AS col1 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to fbbdc69ed4bc9a68f44d1ba867b620b3

query I rowsort
SELECT col0 * 33 * col0 AS col2 FROM tab2 AS cor0
----
1617
200772
205953

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab0 cor1, tab2, tab2 AS cor2
----
3645 values hashing to 17ceecc141378b185d60a17e53464c26

query I rowsort
SELECT col0 * + tab1.col2 FROM tab1
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4480
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4480
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL

query I rowsort
SELECT ALL - col1 + col1 AS col0 FROM tab2 cor0
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT - cor0.col1 + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-4484
SELECT ALL + col2 DIV - col1 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6243

skipif mysql # not compatible
query I rowsort label-4484
SELECT ALL + col2 / - col1 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6243

query I rowsort
SELECT col0 * + 45 + col2 FROM tab1 AS cor0
----
189
2937
3696

query I rowsort
SELECT + col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - 4 * + col0 FROM tab1 AS cor0
----
-12
-256
-320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4488
SELECT 81 DIV + cor0.col0 + + 3 AS col1 FROM tab0 AS cor0
----
3
5
6

skipif mysql # not compatible
query I rowsort label-4488
SELECT 81 / + cor0.col0 + + 3 AS col1 FROM tab0 AS cor0
----
3
5
6

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab2, tab0 AS cor1
----
972 values hashing to 380241bbc503a31e70494611a87ffd99

query I rowsort
SELECT col2 * + col1 * col0 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4491
SELECT + cor0.col0 DIV col1 col2 FROM tab2 AS cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4491
SELECT + cor0.col0 / col1 col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT col0 + tab1.col1 AS col2 FROM tab1
----
29
74
93

query IIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab1 cor1
----
243 values hashing to 877a8dbac0e29b86e845fb64ed9d2242

query I rowsort
SELECT 54 AS col2 FROM tab1 AS cor0
----
54
54
54

query I rowsort
SELECT col2 + + col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to c04c36412775e8805d6b3befa2f52917

query I rowsort
SELECT + - col2 * + ( - col1 ) AS col0 FROM tab2 cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4498
SELECT ALL - CAST( col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4498
SELECT ALL - CAST ( col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - - 52 + - col1 AS col1 FROM tab1 AS cor0
----
26
39
42

query I rowsort
SELECT DISTINCT + 71 * 20 AS col2 FROM tab0, tab2 AS cor0
----
1420

query I rowsort
SELECT cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 68 + col1 * - col0 + + col2 * col1 col0 FROM tab1
----
-2
1394
276

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4503
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4503
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4504
SELECT tab2.col1 * col0 + col0 DIV + 17 AS col0 FROM tab2
----
1347
217
4606

skipif mysql # not compatible
query I rowsort label-4504
SELECT tab2.col1 * col0 + col0 / + 17 AS col0 FROM tab2
----
1347
217
4606

query I rowsort
SELECT 74 FROM tab1, tab1 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT 84 AS col0 FROM tab1
----
84
84
84

query I rowsort
SELECT - col0 + - col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT tab1.col1 * col0 - col1 AS col0 FROM tab1
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4509
SELECT + 88 * - col1 * col0 + CAST( NULL AS SIGNED ) / + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4509
SELECT + 88 * - col1 * col0 + CAST ( NULL AS INTEGER ) / + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( cor0.col1 ) * cor0.col1 - cor0.col1 * 60 FROM tab2 AS cor0
----
-59
-731
-899

query I rowsort
SELECT - col0 * - col1 + col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 * col2 col2 FROM tab2 cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-4513
SELECT ALL ( col0 ) * col1 * - ( ( - col1 ) ) + col1 DIV - col1 FROM tab0 AS cor0
----
177503
329314
737008

skipif mysql # not compatible
query I rowsort label-4513
SELECT ALL ( col0 ) * col1 * - ( ( - col1 ) ) + col1 / - col1 FROM tab0 AS cor0
----
177503
329314
737008

query I rowsort
SELECT DISTINCT 83 - 44 FROM tab0 AS cor0
----
39

query I rowsort
SELECT ALL + col2 + col2 + col0 AS col1 FROM tab2 AS cor0
----
130
155
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 93 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT DISTINCT + + 83 - - col1 * - col2 AS col0 FROM tab2 AS cor0
----
-1451
-563
-754

query I rowsort
SELECT col2 + col2 * col0 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT 19 * + col1 - - col2 FROM tab1
----
247
343
548

query I rowsort
SELECT ( - col2 ) FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * + col1 - col1 col0 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT - + col2 + + col2 * - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT col1 - - col2 * - tab2.col1 AS col1 FROM tab2
----
-1475
-629
-806

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 5d64bf87effa587b137e9591cd2c54bf

query I rowsort
SELECT + 14 AS col0 FROM tab0 cor0
----
14
14
14

query I rowsort
SELECT ALL + + col0 + + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4527
SELECT col0 DIV + col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4527
SELECT col0 / + col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL - col2 * + 23 + + col1 AS col2 FROM tab1 AS cor0
----
-1216
-1301
-2195

query I rowsort
SELECT - - col2 * ( ( + col1 ) ) - - 70 * 0 * col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + cor0.col0 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + + col0 * + ( + col0 * + col0 ) FROM tab0 AS cor0
----
13824
42875
704969

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4532
SELECT ALL col2 + + CAST( NULL AS SIGNED ) * col2 * col1 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4532
SELECT ALL col2 + + CAST ( NULL AS INTEGER ) * col2 * col1 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4533
SELECT - col0 * + col0 + cor0.col2 DIV cor0.col1 FROM tab1 AS cor0
----
-4091
-6393
-7

skipif mysql # not compatible
query I rowsort label-4533
SELECT - col0 * + col0 + cor0.col2 / cor0.col1 FROM tab1 AS cor0
----
-4091
-6393
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4534
SELECT - - col0 * 28 DIV - col1 col2 FROM tab2 AS cor0
----
-130
-37
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4534
SELECT - - col0 * 28 / - col1 col2 FROM tab2 AS cor0
----
-130
-37
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4535
SELECT - + cor0.col0 DIV - col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-4535
SELECT - + cor0.col0 / - col1 FROM tab1 AS cor0
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT col2 * + 65 FROM tab0 cor0
----
2145
5330
65

query I rowsort
SELECT DISTINCT col1 * + col2 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT + 56 FROM tab0
----
56

query I rowsort
SELECT col1 + 62 FROM tab2 AS cor0
----
121
79
93

query I rowsort
SELECT cor0.col0 * + col2 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4542
SELECT DISTINCT + col1 DIV col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4542
SELECT DISTINCT + col1 / col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT + + col0 * + 85 FROM tab1 AS cor0
----
255
5440
6800

query I rowsort
SELECT ALL - col2 * - 39 FROM tab0 AS cor0
----
1287
3198
39

query I rowsort
SELECT DISTINCT + - cor0.col2 * col2 - col1 AS col2 FROM tab0 AS cor0
----
-1175
-6815
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4546
SELECT ALL col2 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4546
SELECT ALL col2 / cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - cor0.col2 AS col1 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4548
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4548
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL tab1.col2 AS col1 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 col0 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT 37 AS col0 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT DISTINCT - col2 + - 47 FROM tab2 AS cor0
----
-73
-74
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4553
SELECT - col1 DIV + col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-4553
SELECT - col1 / + col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL + cor0.col2 + 97 FROM tab1 cor0
----
151
154
193

query I rowsort
SELECT DISTINCT + col0 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ( - col2 ) + - col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT 73 + + 29 FROM tab1 cor0
----
102
102
102

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4558
SELECT - ( col2 ) + col1 * CAST( NULL AS SIGNED ) + 53 * cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4558
SELECT - ( col2 ) + col1 * CAST ( NULL AS INTEGER ) + 53 * cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * ( + col2 ) * - 83 FROM tab0 AS cor0
----
-2905
-605734
-65736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4560
SELECT + CAST( + 73 AS SIGNED ) - col2 FROM tab1 AS cor0
----
-23
16
19

skipif mysql # not compatible
query I rowsort label-4560
SELECT + CAST ( + 73 AS INTEGER ) - col2 FROM tab1 AS cor0
----
-23
16
19

query I rowsort
SELECT DISTINCT - col1 * - cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT cor0.col1 * col1 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT - + 2 FROM tab1 cor0
----
-2

query I rowsort
SELECT DISTINCT + - cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + + 38 + 26 AS col1 FROM tab1 AS cor0
----
64
64
64

query I rowsort
SELECT ALL - col1 + + cor0.col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - + ( col0 ) * + col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - tab1.col1 + - cor0.col2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0f6ec6b87929e67cae93b9c64afb5c9c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col1 ) * cor0.col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - 44 * - col1 AS col2 FROM tab1 AS cor0
----
1144
440
572

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col0 * + col1 + col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-4573
SELECT ALL + col0 * - col2 + col0 DIV col0 FROM tab2 AS cor0
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-4573
SELECT ALL + col0 * - col2 + col0 / col0 FROM tab2 AS cor0
----
-188
-2027
-3001

query I rowsort
SELECT + 3 AS col1 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT DISTINCT + col1 * col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * cor0.col0 * - ( 55 ) + - col2 * 34 col0 FROM tab0 cor0
----
112398
186691
442657

query I rowsort
SELECT + 87 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT + col2 + + col2 * 30 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT DISTINCT + + cor0.col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col0 - + col2 * col1 * + cor0.col2 AS col2 FROM tab2 cor0
----
-22592
-24469
-39806

query I rowsort
SELECT + - col2 * + col2 + col1 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT ALL ( - tab2.col1 ) * + col0 + col1 FROM tab2
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4583
SELECT DISTINCT - 32 * cor0.col2 + cor0.col0 * ( - col0 ) + CAST( - cor0.col0 AS SIGNED ) * - col1 AS col0 FROM tab0 AS cor0
----
-2446
2138
432

skipif mysql # not compatible
query I rowsort label-4583
SELECT DISTINCT - 32 * cor0.col2 + cor0.col0 * ( - col0 ) + CAST ( - cor0.col0 AS INTEGER ) * - col1 AS col0 FROM tab0 AS cor0
----
-2446
2138
432

query I rowsort
SELECT ALL 84 FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT ALL - - cor0.col0 + - col1 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT ( - col2 ) * 29 + + col0 AS col1 FROM tab2 cor0
----
-1023
-676
-776

query I rowsort
SELECT + ( col2 * 40 ) FROM tab2
----
1040
1080
1520

query I rowsort
SELECT - col0 * - col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL - ( + tab1.col1 ) FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4590
SELECT ALL - col0 * - col1 DIV + col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4590
SELECT ALL - col0 * - col1 / + col1 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4591
SELECT ALL 81 DIV col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4591
SELECT ALL 81 / col2 FROM tab1
----
0
1
1

query I rowsort
SELECT DISTINCT + 4 * tab0.col0 * col1 FROM tab0
----
13580
32396
8256

query I rowsort
SELECT DISTINCT + 91 FROM tab1 cor0
----
91

query I rowsort
SELECT DISTINCT - col1 * + 59 FROM tab2
----
-1003
-1829
-3481

query I rowsort
SELECT DISTINCT tab0.col0 FROM tab0, tab1 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - - 16 AS col0 FROM tab2 AS cor0
----
16

query I rowsort
SELECT ALL - - 73 AS col1 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT 57 FROM tab2 cor0
----
57
57
57

query I rowsort
SELECT 28 * col2 FROM tab2 AS cor0
----
1064
728
756

query I rowsort
SELECT - 82 FROM tab1 AS cor0
----
-82
-82
-82

query I rowsort
SELECT cor0.col2 * col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col2 + cor0.col2 AS col1 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT + 32 FROM tab0 AS cor0
----
32
32
32

query I rowsort
SELECT + ( col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col1 + 32 FROM tab1 AS cor0
----
19
22
6

query I rowsort
SELECT ALL + + col2 AS col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4607
SELECT DISTINCT col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4607
SELECT DISTINCT col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col0 AS col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + col1 * - tab0.col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + 68 + + 71 FROM tab2, tab2 AS cor0
----
9 values hashing to ec60c4a1fe63bc8e6608e204b0ee0405

query I rowsort
SELECT - col1 * col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4612
SELECT + col1 * CAST( NULL AS SIGNED ) / 89 + + cor0.col0 * - cor0.col0 / col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4612
SELECT + col1 * CAST ( NULL AS INTEGER ) / 89 + + cor0.col0 * - cor0.col0 / col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + - 14 AS col2 FROM tab1 AS cor0
----
-24
-27
-40

query I rowsort
SELECT ALL - cor0.col2 + 64 FROM tab2 AS cor0
----
26
37
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( col1 ) + col0 col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT + col1 + col0 * col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL cor0.col0 + + 2 FROM tab2 AS cor0
----
80
81
9

query I rowsort
SELECT col2 * - cor0.col1 * cor0.col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - - col0 * col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - ( 20 ) * + cor0.col2 + col0 AS col2 FROM tab2 cor0
----
-442
-533
-681

onlyif mysql # use DIV operator for integer division
query I rowsort label-4621
SELECT + + col1 DIV col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4621
SELECT + + col1 / col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 13 * col2 + - col2 col2 FROM tab0 AS cor0
----
12
396
984

query I rowsort
SELECT ALL + - col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ( col0 ) + col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4625
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4625
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4626
SELECT DISTINCT CAST( NULL AS SIGNED ) / col1 + - col2 * + col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4626
SELECT DISTINCT CAST ( NULL AS INTEGER ) / col1 + - col2 * + col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + cor0.col0 * ( + col0 ) AS col1 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 70 + + 9 + + col0 col2 FROM tab0 AS cor0
----
103
114
168

query I rowsort
SELECT - + 58 FROM tab2 AS cor0
----
-58
-58
-58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4630
SELECT + + CAST( NULL AS DECIMAL ) + - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4630
SELECT + + CAST ( NULL AS REAL ) + - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * + col1 + - col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT DISTINCT + cor0.col1 + 71 AS col1 FROM tab0 AS cor0
----
157
162
168

query I rowsort
SELECT - col2 + + col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( cor0.col0 ) * + col2 col2 FROM tab0 AS cor0
----
35
7298
792

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab0, tab2 AS cor1
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT ( cor0.col1 ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL - col2 * col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT ALL col0 * + col2 + col1 DIV - 24 AS col0 FROM tab0
----
31
7295
789

skipif mysql # not compatible
query I rowsort label-4638
SELECT ALL col0 * + col2 + col1 / - 24 AS col0 FROM tab0
----
31
7295
789

query I rowsort
SELECT + col2 * col0 + cor0.col1 * col0 FROM tab0 AS cor0
----
15397
2856
3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-4640
SELECT col1 DIV - col1 - ( + col1 ) AS col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-4640
SELECT col1 / - col1 - ( + col1 ) AS col0 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT - cor0.col0 * - col2 - col2 * col0 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-25344
-591138
0

query I rowsort
SELECT col0 - - ( cor0.col1 * col2 + + col2 * - 42 ) FROM tab2 AS cor0
----
-290
-871
520

query I rowsort
SELECT + 77 + 70 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7ea90b86e1b35d6116fcda7346d04909

query I rowsort
SELECT ALL col0 * - col2 + + col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT ALL - 4 FROM tab2, tab2 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT tab0.col0 * + 48 AS col0 FROM tab0
----
1152
1680
4272

skipif mysql # not compatible
query I rowsort
SELECT - col2 * CAST ( col1 AS REAL ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT col0 + cor0.col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL col1 - - col1 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL tab1.col0 - - col2 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT + col1 - col0 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT - - col0 * col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL col1 + col1 + col2 AS col1 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT DISTINCT - + 96 AS col1 FROM tab2 AS cor0
----
-96

query I rowsort
SELECT ALL - - 30 + - col0 AS col2 FROM tab1 AS cor0
----
-34
-50
27

query I rowsort
SELECT ALL 17 + - col1 AS col2 FROM tab0 AS cor0
----
-69
-74
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * col0 col0 FROM tab2 AS cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 * - cor0.col0 col2 FROM tab1 AS cor0
----
-225
-4800
-6000

query I rowsort
SELECT ALL - cor0.col1 * + cor0.col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - ( col1 ) * col0 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL tab2.col1 - - col2 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL col1 - col1 FROM tab2
----
0
0
0

query I rowsort
SELECT tab1.col0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4664
SELECT ALL 83 - col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4664
SELECT ALL 83 - col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4665
SELECT tab2.col1 + + col2 / - CAST( NULL AS SIGNED ) - ( - col0 ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4665
SELECT tab2.col1 + + col2 / - CAST ( NULL AS INTEGER ) - ( - col0 ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 80 * col0 FROM tab0
----
1920
2800
7120

query I rowsort
SELECT ALL col0 - + tab2.col1 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL - tab1.col0 - + col2 AS col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT ALL + col0 * col2 * + col2 + col1 AS col0 FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT + 51 + cor0.col1 FROM tab2 AS cor0
----
110
68
82

query I rowsort
SELECT - col2 * - cor0.col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL col0 - col2 FROM tab2
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4673
SELECT ALL col1 DIV + col0 + col0 AS col1 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-4673
SELECT ALL col1 / + col0 + col0 AS col1 FROM tab2
----
11
78
79

query I rowsort
SELECT - 91 FROM tab1
----
-91
-91
-91

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2, tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT col0 * 40 FROM tab0
----
1400
3560
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL col1 * - 55 AS col2 FROM tab2
----
-1705
-3245
-935

query I rowsort
SELECT DISTINCT 94 FROM tab1, tab2 AS cor0
----
94

query I rowsort
SELECT ALL - col0 * 49 FROM tab1 cor0
----
-147
-3136
-3920

query I rowsort
SELECT - col0 + col0 * - col2 AS col1 FROM tab0 cor0
----
-70
-7387
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4682
SELECT ALL + col2 DIV col2 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4682
SELECT ALL + col2 / col2 AS col2 FROM tab1
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4683
SELECT DISTINCT + CAST( - col2 AS SIGNED ) * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-4683
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col0 * 9 AS col2 FROM tab1
----
27
576
720

query I rowsort
SELECT - cor0.col0 + col0 + + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4686
SELECT + col0 + - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4686
SELECT + col0 + - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 + + 75 + - tab2.col0 * - tab2.col1 * - col2 col2 FROM tab2
----
-119603
-50997
-5811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 - col0 col0 FROM tab2
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4689
SELECT DISTINCT CAST( NULL AS DECIMAL ) / col0 AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4689
SELECT DISTINCT CAST ( NULL AS REAL ) / col0 AS col0 FROM tab2
----
NULL

query I rowsort
SELECT - tab1.col1 + - tab1.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 5f7b5c5678d2f6f42d8763f44ca95184

query I rowsort
SELECT + + 93 * col1 FROM tab1 AS cor0
----
1209
2418
930

query I rowsort
SELECT ALL - + 61 * col0 FROM tab1 cor0
----
-183
-3904
-4880

query I rowsort
SELECT ALL + - 70 * + col0 * cor0.col2 FROM tab1 AS cor0
----
-11340
-255360
-537600

onlyif mysql # use DIV operator for integer division
query I rowsort label-4694
SELECT DISTINCT + col0 DIV - 8 FROM tab1 AS cor0
----
-10
-8
0

skipif mysql # not compatible
query I rowsort label-4694
SELECT DISTINCT + col0 / - 8 FROM tab1 AS cor0
----
-10
-8
0

query I rowsort
SELECT DISTINCT - 48 + + col1 FROM tab2 AS cor0
----
-17
-31
11

query I rowsort
SELECT ALL col1 + 70 * - col2 AS col0 FROM tab2 AS cor0
----
-1761
-1859
-2643

query I rowsort
SELECT ( + 95 ) * col1 FROM tab1 cor0
----
1235
2470
950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4698
SELECT + CAST( NULL AS SIGNED ) * - col1 * cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4698
SELECT + CAST ( NULL AS INTEGER ) * - col1 * cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 20 FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT ALL - 23 FROM tab2 AS cor0
----
-23
-23
-23

query I rowsort
SELECT + ( - col1 ) * + col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - 42 * 34 AS col2 FROM tab2 AS cor0
----
-1428

query I rowsort
SELECT 25 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT ALL + col2 * - tab0.col1 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - col1 + - 24 FROM tab1 cor0
----
-34
-37
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-4706
SELECT ALL + col0 DIV + col2 + cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
132
2838
7463

skipif mysql # not compatible
query I rowsort label-4706
SELECT ALL + col0 / + col2 + cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
132
2838
7463

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT ALL col1 * 79 AS col2 FROM tab1
----
1027
2054
790

onlyif mysql # use DIV operator for integer division
query I rowsort label-4709
SELECT ALL + col0 DIV - 57 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4709
SELECT ALL + col0 / - 57 FROM tab2
----
-1
-1
0

query I rowsort
SELECT ALL - + ( col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - - col1 * + col1 + - col1 AS col2 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT + - 62 + + col2 FROM tab2 AS cor0
----
-24
-35
-36

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to bcf430f79386b43bc4077271fcd15cf0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col2 + col1 * + ( + cor0.col1 ) FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT + + 56 AS col1 FROM tab2 AS cor0
----
56
56
56

query I rowsort
SELECT DISTINCT col0 * col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - 39 AS col2 FROM tab1 AS cor0
----
-39
-39
-39

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) * + 52 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT DISTINCT - col2 * col2 AS col0 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + 31 * col0 AS col1 FROM tab0
----
1085
2759
744

onlyif mysql # use DIV operator for integer division
query I rowsort label-4723
SELECT DISTINCT - col0 DIV - 84 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4723
SELECT DISTINCT - col0 / - 84 FROM tab2
----
0

query I rowsort
SELECT DISTINCT 0 * col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + - col2 * - col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col2 + - col2 * + col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4727
SELECT + + cor0.col1 DIV col2 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4727
SELECT + + cor0.col1 / col2 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 - 22 col0 FROM tab2 cor0
----
16
4
5

query I rowsort
SELECT cor0.col1 + ( cor0.col0 ) AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4730
SELECT + cor0.col1 + - CAST( NULL AS SIGNED ) - - 39 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4730
SELECT + cor0.col1 + - CAST ( NULL AS INTEGER ) - - 39 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 + + 26 AS col0 FROM tab1 AS cor0
----
-136
-3622
-7654

query I rowsort
SELECT DISTINCT - - col2 * col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4733
SELECT DISTINCT - col1 DIV col2 + - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4733
SELECT DISTINCT - col1 / col2 + - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - 75 col2 FROM tab1
----
-11
-72
5

query I rowsort
SELECT ALL + + cor0.col1 + col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4736
SELECT ALL col2 * + col2 + + col2 DIV + col2 col0 FROM tab0 AS cor0
----
1090
2
6725

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4736
SELECT ALL col2 * + col2 + + col2 / + col2 col0 FROM tab0 AS cor0
----
1090
2
6725

query I rowsort
SELECT ALL col2 - ( col2 ) FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4738
SELECT DISTINCT + cor0.col2 * CAST( + col0 AS SIGNED ) + col0 * CAST( - ( cor0.col2 ) AS SIGNED ) FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4738
SELECT DISTINCT + cor0.col2 * CAST ( + col0 AS INTEGER ) + col0 * CAST ( - ( cor0.col2 ) AS INTEGER ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col1 - + 66 * + cor0.col2 FROM tab1 AS cor0
----
-3538
-3752
-6323

query I rowsort
SELECT ALL + cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + cor0.col2 + 42 AS col1 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to c3c8b12202e7b1235c296bfca2681420

query I rowsort
SELECT + col2 + + ( col0 ) AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT + col2 * ( cor0.col0 ) + col0 * col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT DISTINCT + - cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + cor0.col1 * + cor0.col0 + - 25 FROM tab0 AS cor0
----
2039
3370
8074

onlyif mysql # use DIV operator for integer division
query I rowsort label-4746
SELECT DISTINCT - col0 + + ( ( - col2 ) ) DIV cor0.col0 FROM tab1 cor0
----
-21
-64
-81

skipif mysql # not compatible
query I rowsort label-4746
SELECT DISTINCT - col0 + + ( ( - col2 ) ) / cor0.col0 FROM tab1 cor0
----
-21
-64
-81

query I rowsort
SELECT - col2 + - ( + col2 ) * cor0.col1 FROM tab0 cor0
----
-2871
-7544
-98

query I rowsort
SELECT + + col0 + - 73 FROM tab0 AS cor0
----
-38
-49
16

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to ca4c79a162f92454e0544707b897521a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col2 FROM tab0, tab2 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 969f31ae779866644763e8a07f1ec501

query I rowsort
SELECT DISTINCT col2 + - col0 * col2 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + col0 * - ( - col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - - col1 + - col2 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4754
SELECT DISTINCT col2 DIV cor0.col0 + col1 * col0 FROM tab2 AS cor0
----
1343
220
4602

skipif mysql # not compatible
query I rowsort label-4754
SELECT DISTINCT col2 / cor0.col0 + col1 * col0 FROM tab2 AS cor0
----
1343
220
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 23 col1 FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT ALL col1 * cor0.col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4757
SELECT - CAST( - ( - col0 ) AS SIGNED ) * - ( - col1 ) + col0 FROM tab1 AS cor0
----
-576
-75
-960

skipif mysql # not compatible
query I rowsort label-4757
SELECT - CAST ( - ( - col0 ) AS INTEGER ) * - ( - col1 ) + col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + 48 * + 30 - col0 AS col2 FROM tab0 AS cor0
----
1351
1405
1416

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 cor1, tab1 AS cor2
----
972 values hashing to 9af67d6f98010464af5d560bf949d487

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4760
SELECT col0 / CAST( NULL AS SIGNED ) + - col2 * - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4760
SELECT col0 / CAST ( NULL AS INTEGER ) + - col2 * - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col2 ) * + ( col1 ) + + col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL + col1 * - col1 * col2 AS col2 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT - cor0.col1 + col2 * + col2 FROM tab2 cor0
----
1427
617
698

query I rowsort
SELECT + col1 + ( + col2 ) * - col0 AS col1 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT - - col2 * - ( col0 ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + - col0 * + 42 FROM tab2 AS cor0
----
-294
-3276
-3318

query I rowsort
SELECT ALL + - col1 - - col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col2 * 13 + - col1 FROM tab2 cor0
----
-382
-397
-511

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + - col2 - col0 col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 58 + - tab2.col0 * col1 AS col2 FROM tab2
----
-1285
-159
-4544

query I rowsort
SELECT col1 - cor0.col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - 15 * - cor0.col0 AS col2 FROM tab1 cor0
----
1200
45
960

query I rowsort
SELECT 4 * 83 AS col1 FROM tab0 AS cor0
----
332
332
332

onlyif mysql # use DIV operator for integer division
query I rowsort label-4774
SELECT + + col1 * col2 * col1 - + 81 DIV ( + col2 ) FROM tab1 AS cor0
----
16224
36503
5699

skipif mysql # not compatible
query I rowsort label-4774
SELECT + + col1 * col2 * col1 - + 81 / ( + col2 ) FROM tab1 AS cor0
----
16224
36503
5699

query I rowsort
SELECT DISTINCT - - col0 + ( cor0.col2 ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - col1 + + ( - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-172
-182
-194

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col1 AS REAL ) FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4778
SELECT + - CAST( NULL AS SIGNED ) / - 98 + col2 * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4778
SELECT + - CAST ( NULL AS INTEGER ) / - 98 + col2 * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4779
SELECT DISTINCT - CAST( NULL AS DECIMAL ) + col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4779
SELECT DISTINCT - CAST ( NULL AS REAL ) + col2 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + - 55 AS col2 FROM tab2 AS cor0
----
-55
-55
-55

query I rowsort
SELECT 25 * col0 AS col2 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT ( col1 ) + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT col2 + + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 28 + col2 FROM tab1 AS cor0
----
124
82
85

query I rowsort
SELECT - 72 * col1 + col0 AS col1 FROM tab2 AS cor0
----
-1145
-2225
-4170

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4786
SELECT ALL - col1 * col0 * + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4786
SELECT ALL - col1 * col0 * + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4787
SELECT DISTINCT 9 * col0 DIV col1 FROM tab0
----
2
3
8

skipif mysql # not compatible
query I rowsort label-4787
SELECT DISTINCT 9 * col0 / col1 FROM tab0
----
2
3
8

query I rowsort
SELECT + - 84 + cor0.col1 FROM tab1 AS cor0
----
-58
-71
-74

query I rowsort
SELECT col2 - + col2 * col0 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + 7 + + col0 * col2 + + 16 * + cor0.col1 FROM tab2 AS cor0
----
2979
3281
692

onlyif mysql # use DIV operator for integer division
query I rowsort label-4791
SELECT 93 DIV cor0.col2 + col2 - cor0.col2 * + col2 FROM tab1 AS cor0
----
-2861
-3191
-9120

skipif mysql # not compatible
query I rowsort label-4791
SELECT 93 / cor0.col2 + col2 - cor0.col2 * + col2 FROM tab1 AS cor0
----
-2861
-3191
-9120

query I rowsort
SELECT col2 * + col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + 34 FROM tab0 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4794
SELECT ( - col0 ) - col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-4794
SELECT ( - col0 ) - col1 / + col1 AS col0 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT 10 * - cor0.col0 + + 85 + - col2 FROM tab2 AS cor0
----
-12
-721
-743

query I rowsort
SELECT DISTINCT 42 + 18 AS col1 FROM tab1, tab2 cor0
----
60

query I rowsort
SELECT - col2 + 76 FROM tab2 AS cor0
----
38
49
50

query I rowsort
SELECT - col0 * col0 + col0 AS col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT + + col2 * col0 + - 53 FROM tab1 AS cor0
----
109
3595
7627

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT - - col1 DIV col0 col1 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4800
SELECT - - col1 / col0 col1 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT + - col1 * ( col1 ) + + cor0.col2 * ( col0 * cor0.col1 ) FROM tab0 cor0
----
-6014
60716
655837

query I rowsort
SELECT + 47 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
-10
-13
-26

query I rowsort
SELECT ALL - col2 * + col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 0a9194f200a4220e419d35c461f9fcfe

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4806
SELECT - + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4806
SELECT - + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 cor2, tab2 AS cor3
----
3645 values hashing to 972d282d6d92f451c90dc8ca51a18f3e

query I rowsort
SELECT cor0.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to def82b52aa9c83b91991d7d043276abe

query I rowsort
SELECT - - cor0.col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4811
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 40 + col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4811
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 40 + col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + tab2.col2 ) * - tab2.col0 * + ( - col0 ) col1 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT - cor0.col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4814
SELECT DISTINCT 24 DIV - ( + col1 ) FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4814
SELECT DISTINCT 24 / - ( + col1 ) FROM tab0
----
0

query I rowsort
SELECT + col1 * + cor0.col1 + - ( 39 ) FROM tab0 cor0
----
7357
8242
9370

query I rowsort
SELECT DISTINCT - - cor0.col2 + - col1 + + 52 FROM tab0 AS cor0
----
-1
-44
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL + 18 FROM tab0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4819
SELECT + col0 * - col2 DIV col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4819
SELECT + col0 * - col2 / col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + + 69 AS col2 FROM tab2 AS cor0
----
69
69
69

query I rowsort
SELECT DISTINCT - col0 + col0 + + col0 * - col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col2 * col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + ( - col1 ) FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT + 34 * ( - col0 ) AS col0 FROM tab2 cor0
----
-238
-2652
-2686

query I rowsort
SELECT DISTINCT - col1 * col2 * - col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) * - col2 col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT + - ( col1 ) DIV col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4827
SELECT + - ( col1 ) / col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 88 + - 14 * - col2 * - ( - col2 ) AS col1 FROM tab2 AS cor0
----
10118
20128
9376

query I rowsort
SELECT col0 * 82 AS col2 FROM tab1 AS cor0
----
246
5248
6560

query I rowsort
SELECT ALL - - col2 + - ( + col1 + col0 ) AS col0 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT ALL - ( - col0 ) + - col0 * + 71 FROM tab1 AS cor0
----
-210
-4480
-5600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + - col0 col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - cor0.col1 * + 58 FROM tab1 AS cor0
----
-1508
-580
-754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4835
SELECT ALL CAST( ( + col2 ) AS SIGNED ) * - 22 * col2 FROM tab2 AS cor0
----
-14872
-16038
-31768

skipif mysql # not compatible
query I rowsort label-4835
SELECT ALL CAST ( ( + col2 ) AS INTEGER ) * - 22 * col2 FROM tab2 AS cor0
----
-14872
-16038
-31768

query I rowsort
SELECT ALL - - 80 * - col1 AS col1 FROM tab1 cor0
----
-1040
-2080
-800

query I rowsort
SELECT + - col0 + + col1 AS col1 FROM tab2 cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-4838
SELECT ALL + - ( col2 ) DIV - col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4838
SELECT ALL + - ( col2 ) / - col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT DISTINCT col2 AS col1 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4840
SELECT - + col1 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4840
SELECT - + col1 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - 7 * 6 AS col1 FROM tab0 AS cor0
----
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col0 + col0 * col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT 63 * col2 FROM tab1 AS cor0
----
3402
3591
6048

query I rowsort
SELECT + + 3 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT + col2 + - col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL + 72 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT ALL - col2 * - col0 + 80 * col1 FROM tab0 cor0
----
14578
7672
7795

query I rowsort
SELECT ALL 73 * - 83 AS col1 FROM tab0
----
-6059
-6059
-6059

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4850
SELECT + col0 + - CAST( NULL AS SIGNED ) * - 92 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4850
SELECT + col0 + - CAST ( NULL AS INTEGER ) * - 92 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * + col1 - col2 * + col2 FROM tab2 cor0
----
-1566
-2090
-2210

query I rowsort
SELECT ALL - col2 + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * + 41 + col0 * col1 FROM tab0 AS cor0
----
11748
3048
4830

query I rowsort
SELECT + col1 + 82 FROM tab1 AS cor0
----
108
92
95

query I rowsort
SELECT DISTINCT + col0 * 15 + ( - col2 * col0 ) AS col0 FROM tab0 AS cor0
----
-432
-5963
490

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 col1 FROM tab2
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4857
SELECT DISTINCT - col2 + - col2 DIV + col1 AS col0 FROM tab1 AS cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-4857
SELECT DISTINCT - col2 + - col2 / + col1 AS col0 FROM tab1 AS cor0
----
-103
-56
-62

query I rowsort
SELECT - col2 * - 5 + - col2 * - col2 AS col1 FROM tab1 AS cor0
----
3186
3534
9696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4859
SELECT col1 + + CAST( col1 * - col1 AS SIGNED ) FROM tab1
----
-156
-650
-90

skipif mysql # not compatible
query I rowsort label-4859
SELECT col1 + + CAST ( col1 * - col1 AS INTEGER ) FROM tab1
----
-156
-650
-90

query I rowsort
SELECT DISTINCT + - 80 AS col0 FROM tab2 AS cor0
----
-80

query I rowsort
SELECT DISTINCT + col2 * - col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col2 + - 29 * 85 FROM tab1
----
-2369
-2408
-2411

query I rowsort
SELECT + col1 * ( col1 ) * col0 + col1 * + col2 FROM tab2
----
23477
273052
7564

query I rowsort
SELECT + col0 * + 76 AS col1 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT DISTINCT col2 + ( 59 ) FROM tab2
----
85
86
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 59 col0 FROM tab0
----
145
150
156

query I rowsort
SELECT 13 + - col0 FROM tab1 AS cor0
----
-51
-67
10

query I rowsort
SELECT col0 * + col1 + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - col2 * 77 + 76 FROM tab2
----
-1926
-2003
-2850

query I rowsort
SELECT DISTINCT - col1 + + 89 * + col1 AS col0 FROM tab1
----
1144
2288
880

query I rowsort
SELECT - col1 + 76 * col2 FROM tab0
----
-21
2422
6141

query I rowsort
SELECT + col1 * + col2 * col2 AS col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ALL - 51 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

query I rowsort
SELECT ( - col2 ) * + cor0.col0 + + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4875
SELECT DISTINCT col2 - + col2 * col0 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4875
SELECT DISTINCT col2 - + col2 * col0 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 - + col2 AS col1 FROM tab0 cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 col2 FROM tab1
----
3
64
80

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0, tab2 AS cor0, tab2 AS cor1
----
972 values hashing to 617c9545df26d6d983e3967864e8e9e4

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT - - col0 + - cor0.col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + + ( + 41 ) + + col1 FROM tab0 AS cor0
----
127
132
138

onlyif mysql # use DIV operator for integer division
query I rowsort label-4882
SELECT ALL + 62 DIV + 26 + + col0 FROM tab1 AS cor0
----
5
66
82

skipif mysql # not compatible
query I rowsort label-4882
SELECT ALL + 62 / + 26 + + col0 FROM tab1 AS cor0
----
5
66
82

query I rowsort
SELECT ALL + col0 - + col2 * - 79 FROM tab0
----
114
2631
6567

query I rowsort
SELECT - 84 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

query I rowsort
SELECT ALL 81 AS col0 FROM tab1 cor0
----
81
81
81

query I rowsort
SELECT + 88 + + col2 * + 36 FROM tab0 AS cor0
----
124
1276
3040

query I rowsort
SELECT DISTINCT cor0.col0 * + 19 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT ALL - + cor0.col0 * cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col0 * col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - col1 + 14 * + 89 AS col2 FROM tab2 AS cor0
----
1187
1215
1229

query I rowsort
SELECT DISTINCT col1 * 60 * 82 AS col1 FROM tab2 AS cor0
----
152520
290280
83640

onlyif mysql # use DIV operator for integer division
query I rowsort label-4892
SELECT ALL col1 * CAST( + 7 AS SIGNED ) DIV col0 AS col0 FROM tab2 AS cor0
----
1
31
5

skipif mysql # not compatible
query I rowsort label-4892
SELECT ALL col1 * CAST ( + 7 AS INTEGER ) / col0 AS col0 FROM tab2 AS cor0
----
1
31
5

query I rowsort
SELECT DISTINCT col1 * col1 * 32 FROM tab2 AS cor0
----
111392
30752
9248

query I rowsort
SELECT - - col2 - 64 * - col2 AS col2 FROM tab0 AS cor0
----
2145
5330
65

query I rowsort
SELECT ALL + + col1 + + 6 AS col0 FROM tab2 AS cor0
----
23
37
65

query I rowsort
SELECT ALL col2 - 47 AS col0 FROM tab2 cor0
----
-20
-21
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 * 98 col2 FROM tab0
----
8428
8918
9506

query I rowsort
SELECT - cor0.col0 * col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT col0 * - 90 + col2 FROM tab0 AS cor0
----
-2127
-3149
-7928

onlyif mysql # use DIV operator for integer division
query I rowsort label-4900
SELECT - - col2 DIV col0 + + ( - col0 * - ( - col0 ) ) AS col0 FROM tab2 cor0
----
-46
-6084
-6241

skipif mysql # not compatible
query I rowsort label-4900
SELECT - - col2 / col0 + + ( - col0 * - ( - col0 ) ) AS col0 FROM tab2 cor0
----
-46
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col1 * + 77 col1 FROM tab0 AS cor0
----
6536
6916
7372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4902
SELECT DISTINCT - col1 * CAST( - cor0.col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4902
SELECT DISTINCT - col1 * CAST ( - cor0.col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL col1 * 4 + col2 AS col0 FROM tab0 AS cor0
----
377
389
446

query I rowsort
SELECT ALL - - col1 + + col1 * - col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT + - col0 * - ( 47 ) - col1 * + col0 * + 22 AS col2 FROM tab2 AS cor0
----
-25833
-4445
-97578

skipif mysql # not compatible
query I rowsort
SELECT - + col0 * + CAST ( col2 AS REAL ) * col2 - col1 FROM tab0 AS cor0
----
-132
-26222
-598527

query I rowsort
SELECT - + col2 + + col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * - col1 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-4909
SELECT - col0 - cor0.col1 DIV col0 FROM tab2 AS cor0
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-4909
SELECT - col0 - cor0.col1 / col0 FROM tab2 AS cor0
----
-11
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4910
SELECT + col1 DIV - col1 + - ( - col1 * col0 ) FROM tab1 cor0
----
1039
639
77

skipif mysql # not compatible
query I rowsort label-4910
SELECT + col1 / - col1 + - ( - col1 * col0 ) FROM tab1 cor0
----
1039
639
77

query I rowsort
SELECT ALL + 59 + ( cor0.col0 ) FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 5d86d180056ea3baff46d4cee7f9bca4

query I rowsort
SELECT 37 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4913
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4913
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - cor1.col2 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col2 + - col0 * - col1 col1 FROM tab2
----
-620
3068
697

query I rowsort
SELECT + 51 * col1 + col2 + - col1 AS col0 FROM tab2 AS cor0
----
1577
2976
888

query I rowsort
SELECT ALL - col0 + - col0 * + col0 + - cor0.col1 FROM tab1 AS cor0
----
-38
-4170
-6493

query I rowsort
SELECT - - col2 + + col1 * - col2 * + col2 FROM tab2 AS cor0
----
-22572
-24510
-39858

onlyif mysql # use DIV operator for integer division
query I rowsort label-4919
SELECT DISTINCT + col1 + 22 DIV col1 AS col0 FROM tab1 AS cor0
----
12
14
26

skipif mysql # not compatible
query I rowsort label-4919
SELECT DISTINCT + col1 + 22 / col1 AS col0 FROM tab1 AS cor0
----
12
14
26

query I rowsort
SELECT DISTINCT + - cor0.col2 + + 85 AS col0 FROM tab0 cor0
----
3
52
84

query I rowsort
SELECT 62 * - col1 AS col1 FROM tab2
----
-1054
-1922
-3658

query I rowsort
SELECT + col1 * - col1 + col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - col0 + - cor0.col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col2 + + 36 FROM tab2 cor0
----
62
63
74

query I rowsort
SELECT ALL tab1.col1 * - col0 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4926
SELECT ALL - col0 * col1 DIV tab1.col2 AS col0 FROM tab1
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-4926
SELECT ALL - col0 * col1 / tab1.col2 AS col0 FROM tab1
----
-1
-10
-11

query I rowsort
SELECT DISTINCT tab1.col1 * - 40 AS col1 FROM tab1, tab1 AS cor0
----
-1040
-400
-520

query I rowsort
SELECT ALL + ( - col0 ) AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT 26 AS col1 FROM tab1
----
26
26
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + - 90 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 1864f676395941e11a5fdd5c81201490

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT ALL ( - col0 ) AS col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT 44 FROM tab2
----
44
44
44

query I rowsort
SELECT + col0 + - col0 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col0 + + col1 * + tab2.col2 FROM tab2
----
1612
725
844

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL col0 * + col2 AS col0 FROM tab2 WHERE + col2 NOT IN ( col2 )
----

query I rowsort
SELECT - col1 - + col0 AS col1 FROM tab2
----
-137
-38
-96

query III rowsort
SELECT * FROM tab0 WHERE NOT ( col0 ) NOT IN ( col1 + col1 )
----

query I rowsort
SELECT ALL tab0.col2 * col0 * - col0 - col0 FROM tab0
----
-1260
-19032
-649611

query I rowsort
SELECT - col1 - + col1 * col1 FROM tab0
----
-7482
-8372
-9506

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4943
SELECT col2 DIV col2 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4943
SELECT col2 / col2 AS col0 FROM tab0
----
1
1
1

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( - col2 + col2 + col1 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT - col0 NOT BETWEEN - col1 AND NULL
----

query I rowsort
SELECT - tab1.col1 + col2 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL - col1 + col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT - tab0.col0 * + col1 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 * - col0 + col1 * + col1 + tab0.col2 AS col2 FROM tab0
----
264
5365
6015

query I rowsort
SELECT + col0 * col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col1 * col1 + + col2 AS col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT + col0 / col1 AS col2 FROM tab2 WHERE NOT NULL NOT BETWEEN + col0 AND + col1
----

query I rowsort
SELECT DISTINCT tab0.col2 - - tab0.col1 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT col0 * col1 * - tab0.col0 - col1 * - col0 AS col1 FROM tab0
----
-115430
-47472
-712712

query I rowsort
SELECT - col2 + col2 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT tab1.col2 * col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL + col0 * - tab2.col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT ALL - col1 * + col1 * tab1.col2 - - col2 FROM tab1
----
-16128
-36450
-5643

query III rowsort
SELECT * FROM tab0 WHERE ( col1 ) <> NULL
----

query I rowsort
SELECT - col0 + col1 AS col2 FROM tab0
----
2
62
62

query I rowsort
SELECT tab2.col0 FROM tab2 WHERE ( col2 ) NOT BETWEEN ( NULL ) AND - col1
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4962
SELECT ALL - col0 DIV tab0.col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4962
SELECT ALL - col0 / tab0.col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT + col2 * + col0 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT col1 + + col0 + col1 FROM tab1 WHERE - col1 * - tab1.col0 - + col2 BETWEEN + col0 AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col1 / + col0 NOT IN ( col1 )
----

query I rowsort
SELECT - 83 FROM tab2
----
-83
-83
-83

query I rowsort
SELECT + ( - col1 * - tab0.col2 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - + 38 * col0 - + ( col2 + cor0.col1 ) * - col2 FROM tab1 cor0
----
1387
4206
7424

query I rowsort
SELECT - + col1 - - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col1 * + col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - 50 + + col1 AS col1 FROM tab2 AS cor0
----
-19
-33
9

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + 56 + ( col1 * - col0 ) FROM tab0
----
-2008
-3339
-8043

query I rowsort
SELECT + 82 AS col0 FROM tab0
----
82
82
82

query I rowsort
SELECT - 40 + + col0 * 24 AS col0 FROM tab2 AS cor0
----
128
1832
1856

query I rowsort
SELECT + - ( - col1 ) * 86 FROM tab0 AS cor0
----
7396
7826
8342

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4978
SELECT DISTINCT + - col2 * col2 + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4978
SELECT DISTINCT + - col2 * col2 + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 26 + + col0 FROM tab1 cor0
----
106
29
90

query I rowsort
SELECT + cor0.col1 * cor0.col0 + + col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT col2 - - col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - cor0.col0 - col2 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + 50 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT ALL - + 73 FROM tab1, tab2 AS cor0, tab0, tab1 cor1
----
81 values hashing to b6d4a8c1826477f660e7b977a0d1fdd7

query I rowsort
SELECT - 58 FROM tab2, tab2 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4986
SELECT ALL col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4986
SELECT ALL col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 42 AS col0 FROM tab2, tab0 AS cor0
----
42

query I rowsort
SELECT - col1 * - 88 AS col0 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT col1 * - 9 * - ( - col2 ) FROM tab0 AS cor0
----
-25542
-67158
-873

onlyif mysql # use DIV operator for integer division
query I rowsort label-4990
SELECT - col2 DIV - ( 74 * - cor0.col1 ) AS col2 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4990
SELECT - col2 / - ( 74 * - cor0.col1 ) AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + col1 * - col1 AS col0 FROM tab1
----
-157
-265
-730

query I rowsort
SELECT + col1 * + col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + 91 * + ( col0 ) FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT 25 AS col2 FROM tab0 AS cor0
----
25
25
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4995
SELECT + CAST( - 9 AS SIGNED ) * - col2 FROM tab0 AS cor0
----
297
738
9

skipif mysql # not compatible
query I rowsort label-4995
SELECT + CAST ( - 9 AS INTEGER ) * - col2 FROM tab0 AS cor0
----
297
738
9

query I rowsort
SELECT ALL col1 + + cor0.col0 * - cor0.col0 * - 26 FROM tab2 AS cor0
----
1305
158243
162283

query I rowsort
SELECT - - col0 * - 22 FROM tab2 AS cor0
----
-154
-1716
-1738

query I rowsort
SELECT 29 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + 87 * - 6 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 89b4872c2faf57157786314239b5b957

query I rowsort
SELECT + col1 + col2 + col2 FROM tab2 AS cor0
----
111
85
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + + cor0.col2 * col0 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5004
SELECT DISTINCT + col2 + col2 DIV ( + col0 ) + + col0 * col1 AS col0 FROM tab0 AS cor0
----
2098
3396
8181

skipif mysql # not compatible
query I rowsort label-5004
SELECT DISTINCT + col2 + col2 / ( + col0 ) + + col0 * col1 AS col0 FROM tab0 AS cor0
----
2098
3396
8181

query I rowsort
SELECT ALL 66 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT 60 + - col2 * col2 * + col2 + col2 FROM tab1 AS cor0
----
-157350
-185076
-884580

query I rowsort
SELECT ALL + - col2 * cor0.col2 + - col2 * - 66 FROM tab2 AS cor0
----
1040
1053
1064

query I rowsort
SELECT ALL + 32 + col1 FROM tab2
----
49
63
91

query I rowsort
SELECT DISTINCT + + col1 * cor0.col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + - col1 * col0 - ( col0 ) * + col0 FROM tab2 cor0
----
-10686
-266
-7584

query I rowsort
SELECT + + cor0.col0 * - col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5012
SELECT ALL + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5012
SELECT ALL + col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col2 * col2 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5014
SELECT + - cor0.col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5014
SELECT + - cor0.col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 + - cor0.col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL col1 + 85 * + col2 AS col1 FROM tab1 cor0
----
4616
4855
8173

query I rowsort
SELECT + col1 * col1 + + col1 FROM tab1 cor0
----
110
182
702

query I rowsort
SELECT ( + col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + ( + 8 ) + - col0 AS col2 FROM tab0 AS cor0
----
-16
-27
-81

query I rowsort
SELECT ALL + ( cor0.col1 ) + - col0 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - cor0.col0 * + col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + + cor0.col2 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( ( col2 ) ) * col0 col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - ( + col0 ) + col1 * - col2 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT ( col1 ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + 82 + 35 AS col2 FROM tab1 AS cor0
----
117

query I rowsort
SELECT col0 * col2 + + col2 + - col0 * + col1 * col1 AS col1 FROM tab1 AS cor0
----
-1812
-2695
-5744

query I rowsort
SELECT DISTINCT - 69 FROM tab0 AS cor0
----
-69

query I rowsort
SELECT DISTINCT + col2 * col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT 97 * + 32 * - col2 + - ( + col1 ) + col1 FROM tab0 AS cor0
----
-102432
-254528
-3104

onlyif mysql # use DIV operator for integer division
query I rowsort label-5031
SELECT ALL 88 DIV + col1 FROM tab2 AS cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-5031
SELECT ALL 88 / + col1 FROM tab2 AS cor0
----
1
2
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + col1 * col1 + + col0 * 80 + col1 AS col2 FROM tab0 AS cor0
----
12306
15492
9402

query I rowsort
SELECT - 50 AS col1 FROM tab1 AS cor0
----
-50
-50
-50

query I rowsort
SELECT + col0 + col1 * + cor0.col1 * - cor0.col2 + col0 * + 25 * + col1 FROM tab1 AS cor0
----
-34551
10364
9856

query I rowsort
SELECT DISTINCT - - cor0.col1 + col2 * 79 AS col1 FROM tab1 AS cor0
----
4292
4513
7597

query I rowsort
SELECT DISTINCT + 74 AS col0 FROM tab1 AS cor0
----
74

query I rowsort
SELECT DISTINCT + + col2 * + col0 + 59 + col1 * + col0 AS col1 FROM tab1 AS cor0
----
299
4347
8779

query I rowsort
SELECT - cor0.col2 + - col0 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + - 29 * - col0 + - cor0.col2 FROM tab1 AS cor0
----
1799
2224
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col0 * col2 + col0 * cor0.col2 AS col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 + - 8 col1 FROM tab1 AS cor0
----
-2924
-3257
-9224

query I rowsort
SELECT ALL + + col0 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col2 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-5046
SELECT ALL col0 DIV - col1 + tab0.col0 DIV col2 - + ( col0 ) col2 FROM tab0
----
-24
-88
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5046
SELECT ALL col0 / - col1 + tab0.col0 / col2 - + ( col0 ) col2 FROM tab0
----
-24
-88
0

query I rowsort
SELECT ALL 58 FROM tab1
----
58
58
58

query I rowsort
SELECT ALL 49 * + col0 FROM tab0
----
1176
1715
4361

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT 69 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT DISTINCT col2 * col1 + cor0.col1 * 6 FROM tab2 cor0
----
1023
1888
748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col2 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + col2 + + col2 * col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL + + col1 * col2 + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + col0 * + col2 + 46 AS col0 FROM tab0 AS cor0
----
7344
81
838

query I rowsort
SELECT col1 + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5057
SELECT + col2 + col0 + col1 * CAST( + col1 AS SIGNED ) AS col1 FROM tab0
----
7453
8452
9445

skipif mysql # not compatible
query I rowsort label-5057
SELECT + col2 + col0 + col1 * CAST ( + col1 AS INTEGER ) AS col1 FROM tab0
----
7453
8452
9445

query I rowsort
SELECT - - col0 - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + col1 * - col1 + cor0.col2 AS col0 FROM tab0 cor0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT tab1.col2 * col2 + + col1 FROM tab1
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-5061
SELECT ALL tab1.col2 DIV - col1 + + col0 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-5061
SELECT ALL tab1.col2 / - col1 + + col0 FROM tab1
----
1
59
73

query I rowsort
SELECT 99 * - tab0.col1 AS col1 FROM tab0
----
-8514
-9009
-9603

query I rowsort
SELECT + 2 * + tab0.col0 AS col0 FROM tab0
----
178
48
70

query I rowsort
SELECT - col0 * + cor0.col0 * - col0 + + col2 FROM tab0 AS cor0
----
13857
42876
705051

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT tab1.col2 * - col0 * col1 + - tab1.col1 AS col2 FROM tab1
----
-36490
-4238
-99853

query I rowsort
SELECT DISTINCT - 40 FROM tab1
----
-40

query I rowsort
SELECT DISTINCT 68 AS col0 FROM tab2 cor0
----
68

query I rowsort
SELECT + - 11 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

query I rowsort
SELECT DISTINCT col1 + col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT + col2 + + tab2.col1 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT tab2.col1 + col1 FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5073
SELECT col0 DIV col2 AS col0 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5073
SELECT col0 / col2 AS col0 FROM tab0
----
0
1
35

query I rowsort
SELECT + 43 * col0 AS col0 FROM tab1
----
129
2752
3440

query I rowsort
SELECT 37 FROM tab0, tab0 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5076
SELECT ALL + + col0 DIV ( col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5076
SELECT ALL + + col0 / ( col1 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + 66 AS col1 FROM tab0 AS cor0
----
66
66
66

query I rowsort
SELECT ALL - col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT - col0 * - 43 AS col0 FROM tab2 cor0
----
301
3354
3397

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col2 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + col1 + + col2 * col1 AS col1 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT col0 * ( col0 ) FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - 2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + tab0.col0 col1 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5086
SELECT col2 + + col0 DIV col1 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-5086
SELECT col2 + + col0 / col1 FROM tab2
----
27
27
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5087
SELECT DISTINCT - col1 * CAST( + ( - col1 ) + col0 AS SIGNED ) AS col0 FROM tab1
----
-540
-871
598

skipif mysql # not compatible
query I rowsort label-5087
SELECT DISTINCT - col1 * CAST ( + ( - col1 ) + col0 AS INTEGER ) AS col0 FROM tab1
----
-540
-871
598

query I rowsort
SELECT - 50 FROM tab1
----
-50
-50
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5089
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5089
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - tab2.col1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT DISTINCT + 48 + + col2 AS col0 FROM tab0 AS cor0
----
130
49
81

query I rowsort
SELECT ALL + + 98 - - col1 AS col2 FROM tab0 AS cor0
----
184
189
195

query I rowsort
SELECT ALL - 52 - 10 AS col1 FROM tab2 AS cor0
----
-62
-62
-62

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) * + cor0.col0 + 9 FROM tab2 AS cor0
----
198
2037
3011

query I rowsort
SELECT DISTINCT - - ( col1 ) * - col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ( col0 ) AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL col2 * - 1 + + cor0.col1 AS col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + - 61 + - ( - col0 ) AS col0 FROM tab2 AS cor0
----
-54
17
18

query I rowsort
SELECT ALL col0 * - col0 - - col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT - - col1 + col0 + col1 AS col0 FROM tab2 AS cor0
----
113
196
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-5101
SELECT + tab1.col1 DIV tab1.col0 col0 FROM tab1
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5101
SELECT + tab1.col1 / tab1.col0 col0 FROM tab1
----
0
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5102
SELECT ALL + CAST( NULL AS SIGNED ) / + tab0.col2 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5102
SELECT ALL + CAST ( NULL AS INTEGER ) / + tab0.col2 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col1 * 64 * + 30 AS col2 FROM tab2
----
113280
32640
59520

onlyif mysql # use DIV operator for integer division
query I rowsort label-5104
SELECT DISTINCT col0 DIV - CAST( - 17 AS SIGNED ) FROM tab0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-5104
SELECT DISTINCT col0 / - CAST ( - 17 AS INTEGER ) FROM tab0
----
1
2
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5105
SELECT DISTINCT - col0 DIV - 69 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-5105
SELECT DISTINCT - col0 / - 69 FROM tab2
----
0
1

query I rowsort
SELECT DISTINCT - 58 AS col0 FROM tab0, tab1 AS cor0
----
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5107
SELECT DISTINCT + cor0.col2 DIV - col1 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-5107
SELECT DISTINCT + cor0.col2 / - col1 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT + col1 * + cor0.col0 + col0 + + col2 FROM tab1 AS cor0
----
1216
135
761

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5109
SELECT - CAST( col0 AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-5109
SELECT - CAST ( col0 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + - col2 * + col1 * + col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT + 44 * col2 * + col1 FROM tab2 AS cor0
----
28424
36828
67496

onlyif mysql # use DIV operator for integer division
query I rowsort label-5112
SELECT + col2 DIV + col1 + cor0.col0 + - ( - col2 ) col1 FROM tab2 cor0
----
104
119
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5112
SELECT + col2 / + col1 + cor0.col0 + - ( - col2 ) col1 FROM tab2 cor0
----
104
119
34

query I rowsort
SELECT - + col1 * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( + col1 AS REAL ) * + col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 * + ( + col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT - ( + cor0.col1 ) AS col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT - ( - ( col0 ) ) * + col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - + ( col2 ) + - col0 - - col1 AS col0 FROM tab0 cor0
----
-80
29
61

query I rowsort
SELECT ALL ( + col1 ) + ( 81 ) * + col0 FROM tab1 AS cor0
----
269
5194
6493

query I rowsort
SELECT col1 + col2 * ( col1 ) FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - - 53 FROM tab1 cor0
----
53
53
53

query I rowsort
SELECT DISTINCT - cor0.col1 + - col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT 65 AS col1 FROM tab2 AS cor0
----
65

query I rowsort
SELECT col1 + + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + col1 * col0 + + 69 AS col0 FROM tab1 AS cor0
----
1109
147
709

query I rowsort
SELECT - col1 * - col2 + - 46 AS col2 FROM tab0 cor0
----
2792
51
7416

query I rowsort
SELECT + cor0.col1 + - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - col0 * + ( - 41 ) AS col2 FROM tab1 AS cor0
----
123
2624
3280

query I rowsort
SELECT - + col1 + - col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT 48 FROM tab2
----
48
48
48

query I rowsort
SELECT 47 AS col1 FROM tab2
----
47
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 61 col2 FROM tab2
----
61
61
61

query I rowsort
SELECT ALL + cor0.col2 * + 17 AS col2 FROM tab1 AS cor0
----
1632
918
969

query I rowsort
SELECT - col0 * 9 AS col2 FROM tab0 AS cor0
----
-216
-315
-801

query I rowsort
SELECT + col2 * col1 * + col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL cor0.col0 * - 73 AS col2 FROM tab0 AS cor0
----
-1752
-2555
-6497

onlyif mysql # use DIV operator for integer division
query I rowsort label-5137
SELECT ALL + - col1 * 94 + col2 DIV + col1 AS col1 FROM tab0 AS cor0
----
-8084
-8554
-9118

skipif mysql # not compatible
query I rowsort label-5137
SELECT ALL + - col1 * 94 + col2 / + col1 AS col1 FROM tab0 AS cor0
----
-8084
-8554
-9118

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5138
SELECT - col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5138
SELECT - col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + 53 + + tab2.col0 AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 1711eaaea82111453080275a9ff9597a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5141
SELECT ALL + - col2 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5141
SELECT ALL + - col2 * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5143
SELECT DISTINCT + col1 DIV col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-5143
SELECT DISTINCT + col1 / col2 FROM tab1
----
0

query I rowsort
SELECT 4 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to d6394df0309139ffe20e7d96c77e26ee

query I rowsort
SELECT col0 * + ( col0 ) FROM tab2 AS cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 col1 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5148
SELECT col0 + - col1 DIV + col2 FROM tab0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-5148
SELECT col0 + - col1 / + col2 FROM tab0
----
-62
22
88

query I rowsort
SELECT DISTINCT + tab1.col1 AS col0 FROM tab1, tab0 AS cor0
----
10
13
26

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

query I rowsort
SELECT ALL + + col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + 14 * col2 * - col1 FROM tab0
----
-104468
-1358
-39732

query I rowsort
SELECT col2 + col0 * cor0.col2 + + 13 * col1 AS col1 FROM tab0 AS cor0
----
1297
1943
8563

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5154
SELECT DISTINCT - CAST( 65 AS SIGNED ) AS col0 FROM tab1
----
-65

skipif mysql # not compatible
query I rowsort label-5154
SELECT DISTINCT - CAST ( 65 AS INTEGER ) AS col0 FROM tab1
----
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 0 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + col2 * ( + col1 * col0 ) FROM tab1
----
36544
4215
99920

query I rowsort
SELECT - 44 * tab1.col0 + + col2 * + 71 * col1 AS col0 FROM tab1
----
37654
85088
99552

onlyif mysql # use DIV operator for integer division
query I rowsort label-5158
SELECT + - 20 DIV - col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5158
SELECT + - 20 / - col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 + col0 * col0 + + tab0.col1 AS col2 FROM tab0
----
1419
748
8103

query I rowsort
SELECT - col2 + col1 * + col0 AS col2 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT - 37 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 395d44ccbce08828bc493e93ec3d9207

query I rowsort
SELECT DISTINCT + 30 * + col2 - col2 FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT 6 * + col0 + col0 FROM tab1 AS cor0
----
21
448
560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 5 - 11 col1 FROM tab1 AS cor0
----
-16
-16
-16

query I rowsort
SELECT DISTINCT 99 + col2 * + cor0.col2 FROM tab2 AS cor0
----
1543
775
828

query I rowsort
SELECT DISTINCT - + 47 * col1 + col0 * - col2 FROM tab1 AS cor0
----
-1384
-4118
-8291

onlyif mysql # use DIV operator for integer division
query I rowsort label-5167
SELECT + - col1 * + col0 + col0 DIV 7 AS col0 FROM tab1 AS cor0
----
-1029
-631
-78

skipif mysql # not compatible
query I rowsort label-5167
SELECT + - col1 * + col0 + col0 / 7 AS col0 FROM tab1 AS cor0
----
-1029
-631
-78

query I rowsort
SELECT ALL + 91 * col0 + col2 * ( col1 ) AS col1 FROM tab1 AS cor0
----
1677
6394
8528

query I rowsort
SELECT DISTINCT - col2 * + col0 - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL col0 + 61 AS col2 FROM tab2 AS cor0
----
139
140
68

query I rowsort
SELECT DISTINCT - ( - col2 ) * col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col0 + col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT cor0.col2 + + 15 FROM tab2 AS cor0
----
41
42
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + col0 col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + + 95 * col1 + + col1 - col2 FROM tab1 AS cor0
----
1152
2442
903

query I rowsort
SELECT ALL + - 79 AS col1 FROM tab1 AS cor0
----
-79
-79
-79

query I rowsort
SELECT ALL col0 - ( tab2.col2 ) FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL + col1 - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col1 + + 5 AS col1 FROM tab0
----
-81
-86
-92

query I rowsort
SELECT col0 * + 72 FROM tab1
----
216
4608
5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5181
SELECT col2 + - col0 DIV + col1 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-5181
SELECT col2 + - col0 / + col1 FROM tab1
----
51
54
90

query I rowsort
SELECT col0 - - col2 FROM tab1
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5183
SELECT + col0 + - CAST( NULL AS SIGNED ) - + 3 * - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5183
SELECT + col0 + - CAST ( NULL AS INTEGER ) - + 3 * - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * - 92 - + 84 AS col1 FROM tab0
----
7828
8288
8840

query I rowsort
SELECT ALL col1 * + ( tab1.col2 * col2 ) - + col2 FROM tab1
----
119712
32433
75762

query I rowsort
SELECT ALL col1 - - 88 AS col0 FROM tab1
----
101
114
98

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0, tab2, tab0 cor1
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

onlyif mysql # use DIV operator for integer division
query I rowsort label-5188
SELECT DISTINCT + col2 + - col2 * col0 DIV + ( - col0 ) FROM tab0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-5188
SELECT DISTINCT + col2 + - col2 * col0 / + ( - col0 ) FROM tab0
----
164
2
66

query I rowsort
SELECT + tab1.col2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-5190
SELECT DISTINCT - tab0.col2 DIV col1 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5190
SELECT DISTINCT - tab0.col2 / col1 + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - ( 28 ) * col1 + + 79 AS col1 FROM tab2
----
-1573
-397
-789

query I rowsort
SELECT ALL - - col0 + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5193
SELECT + 73 + 34 DIV col0 FROM tab1 AS cor0
----
73
73
84

skipif mysql # not compatible
query I rowsort label-5193
SELECT + 73 + 34 / col0 FROM tab1 AS cor0
----
73
73
84

query I rowsort
SELECT DISTINCT - 37 + - col2 FROM tab0 AS cor0
----
-119
-38
-70

query I rowsort
SELECT ALL - col2 + - cor0.col0 + col1 AS col0 FROM tab2 cor0
----
-100
-3
-45

query I rowsort
SELECT + col1 * + col2 + + col1 AS col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + col2 + ( - col1 ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + 36 + col1 AS col0 FROM tab2 AS cor0
----
53
67
95

query I rowsort
SELECT ALL 84 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT 4 - - col2 FROM tab0
----
37
5
86

query I rowsort
SELECT col0 + + tab0.col0 AS col1 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL + 41 + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 6c7ea0353add2a405c19398aeb2264ab

query I rowsort
SELECT - cor0.col2 + col2 * 80 AS col2 FROM tab0 AS cor0
----
2607
6478
79

query I rowsort
SELECT + cor0.col0 * col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5205
SELECT DISTINCT ( + col1 ) * + CAST( - col1 AS SIGNED ) col0 FROM tab1
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5205
SELECT DISTINCT ( + col1 ) * + CAST ( - col1 AS INTEGER ) col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + col1 * col1 AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT - + cor0.col2 * - col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col2 * 84 FROM tab0 AS cor0
----
-2772
-6888
-84

query I rowsort
SELECT ALL + 42 + cor0.col0 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 366c143e90917fe667feaa4299f58568

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5210
SELECT DISTINCT - col2 + - CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5210
SELECT DISTINCT - col2 + - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + 43 AS col2 FROM tab0, tab0 AS cor0
----
43

query I rowsort
SELECT DISTINCT tab2.col2 * ( tab2.col0 ) + + col0 * + col0 FROM tab2
----
238
8112
9243

query I rowsort
SELECT + col1 + tab1.col2 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT - col1 + cor0.col2 + - 67 AS col0 FROM tab2 AS cor0
----
-100
-46
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + 81 col1 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT DISTINCT + - col2 * ( - 10 * - cor0.col1 + - ( col0 ) * col0 ) AS col1 FROM tab1 AS cor0
----
-13554
227772
601920

query I rowsort
SELECT DISTINCT - - col2 * 62 + col2 FROM tab0 AS cor0
----
2079
5166
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-5218
SELECT ALL - col0 DIV CAST( ( - col1 ) AS SIGNED ) + + ( + col0 ) FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-5218
SELECT ALL - col0 / CAST ( ( - col1 ) AS INTEGER ) + + ( + col0 ) FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT ALL - - col1 * col1 - 59 FROM tab1 AS cor0
----
110
41
617

query I rowsort
SELECT 83 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5221
SELECT ALL col0 DIV - col0 + ( + col1 + col2 ) * + col0 AS col2 FROM tab2 AS cor0
----
405
4344
6629

skipif mysql # not compatible
query I rowsort label-5221
SELECT ALL col0 / - col0 + ( + col1 + col2 ) * + col0 AS col2 FROM tab2 AS cor0
----
405
4344
6629

query I rowsort
SELECT ALL col1 + 49 * + col1 FROM tab1 AS cor0
----
1300
500
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5223
SELECT + cor0.col1 + - CAST( + col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-5223
SELECT + cor0.col1 + - CAST ( + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 24 + ( col2 ) col0 FROM tab0 cor0
----
-1886
-23
-759

query I rowsort
SELECT + - cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 75a813ebd5ec5ec2e67a66d0593ff763

query I rowsort
SELECT 28 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT - col1 * + ( + col1 ) AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - col1 + col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col1 * 70 FROM tab1 AS cor0
----
-1820
-700
-910

query I rowsort
SELECT + + col0 * + col2 * - ( col0 ) AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT ALL + col0 + - ( col0 ) AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5233
SELECT + col0 * + ( col2 + col0 ) * + CAST( ( - cor0.col0 ) AS SIGNED ) FROM tab0 AS cor0
----
-1354491
-32832
-44100

skipif mysql # not compatible
query I rowsort label-5233
SELECT + col0 * + ( col2 + col0 ) * + CAST ( ( - cor0.col0 ) AS INTEGER ) FROM tab0 AS cor0
----
-1354491
-32832
-44100

query I rowsort
SELECT DISTINCT + col2 * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - cor0.col1 + 92 AS col1 FROM tab2 AS cor0
----
33
61
75

query I rowsort
SELECT 58 AS col0 FROM tab0, tab2 AS cor0, tab1 cor1, tab2 AS cor2
----
81 values hashing to 793ce5fda3f22b0a251dca7e8a07baed

query I rowsort
SELECT ALL - + cor0.col2 * + 85 AS col1 FROM tab0 cor0
----
-2805
-6970
-85

query I rowsort
SELECT + 60 * - col1 FROM tab2 AS cor0
----
-1020
-1860
-3540

query I rowsort
SELECT + 0 + + 78 * - col1 AS col0 FROM tab1 cor0
----
-1014
-2028
-780

query I rowsort
SELECT DISTINCT + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + 53 AS col2 FROM tab1, tab2 AS cor0
----
53

query I rowsort
SELECT ALL 71 FROM tab0, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 + + 65 AS col2 FROM tab1 AS cor0
----
1105
143
705

query I rowsort
SELECT + col1 + + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col2 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + cor0.col2 * col0 - - col2 * col0 FROM tab2 AS cor0
----
378
4056
6004

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5247
SELECT col0 + - col1 * - CAST( col2 AS SIGNED ) * col1 AS col1 FROM tab0 cor0
----
244092
679131
9444

skipif mysql # not compatible
query I rowsort label-5247
SELECT col0 + - col1 * - CAST ( col2 AS INTEGER ) * col1 AS col1 FROM tab0 cor0
----
244092
679131
9444

query I rowsort
SELECT DISTINCT - 58 * col1 + + cor0.col1 FROM tab2 cor0
----
-1767
-3363
-969

query I rowsort
SELECT + ( col0 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0, tab2, tab2 AS cor1
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col0 * - ( col1 ) * + col2 + - col1 col1 FROM tab2
----
119593
51017
5828

query I rowsort
SELECT DISTINCT - col2 * + col2 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5253
SELECT DISTINCT 46 * - col0 + + CAST( NULL AS SIGNED ) * - col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5253
SELECT DISTINCT 46 * - col0 + + CAST ( NULL AS INTEGER ) * - col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 + - ( - col1 + + col0 ) * + ( + col0 ) col2 FROM tab2
----
-21
-3510
-7900

query I rowsort
SELECT - col2 * 35 FROM tab0 AS cor0
----
-1155
-2870
-35

query I rowsort
SELECT + col2 * col2 * + 11 FROM tab2 AS cor0
----
15884
7436
8019

query I rowsort
SELECT - + col1 AS col2 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5258
SELECT - col0 DIV 55 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5258
SELECT - col0 / 55 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT tab2.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT col2 * tab2.col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL - 87 * + col0 FROM tab1
----
-261
-5568
-6960

query I rowsort
SELECT 39 FROM tab0
----
39
39
39

query I rowsort
SELECT - col2 + col1 * 57 * 38 FROM tab0
----
186243
197024
210101

query I rowsort
SELECT DISTINCT - 94 AS col2 FROM tab1 AS cor0
----
-94

query I rowsort
SELECT cor0.col2 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - col0 + col0 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5267
SELECT DISTINCT + ( col2 ) DIV 85 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-5267
SELECT DISTINCT + ( col2 ) / 85 FROM tab2 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5268
SELECT DISTINCT - 60 DIV - col2 + + 37 FROM tab0 AS cor0
----
37
38
97

skipif mysql # not compatible
query I rowsort label-5268
SELECT DISTINCT - 60 / - col2 + + 37 FROM tab0 AS cor0
----
37
38
97

query I rowsort
SELECT - + ( col0 ) * col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab2, tab2 AS cor1
----
972 values hashing to 82def1c3361e635dd4cf447edc22edb9

query I rowsort
SELECT - 7 FROM tab2, tab2 cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT DISTINCT + 71 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
71

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

query I rowsort
SELECT ( tab2.col1 + tab2.col0 ) AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT - 51 AS col2 FROM tab1
----
-51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5276
SELECT - ( + tab2.col0 ) + + CAST( col2 * col2 AS SIGNED ) AS col2 FROM tab2
----
1365
598
722

skipif mysql # not compatible
query I rowsort label-5276
SELECT - ( + tab2.col0 ) + + CAST ( col2 * col2 AS INTEGER ) AS col2 FROM tab2
----
1365
598
722

query I rowsort
SELECT DISTINCT - 61 AS col0 FROM tab0
----
-61

query I rowsort
SELECT 13 AS col0 FROM tab1
----
13
13
13

query I rowsort
SELECT 38 * col0 AS col0 FROM tab1 AS cor0
----
114
2432
3040

query I rowsort
SELECT ALL + 6 FROM tab2, tab1 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

onlyif mysql # use DIV operator for integer division
query I rowsort label-5281
SELECT ALL col0 * col1 DIV 31 col1 FROM tab1
----
2
20
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5281
SELECT ALL col0 * col1 / 31 col1 FROM tab1
----
2
20
33

query I rowsort
SELECT - 57 AS col1 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT - col0 * tab0.col0 + - col0 * col1 FROM tab0
----
-16020
-2640
-4620

query I rowsort
SELECT tab0.col0 * col0 AS col2 FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - ( + col2 ) col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT col1 * col1 * col1 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT col1 * - tab1.col2 AS col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + col1 + col2 + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1499
761
787

query I rowsort
SELECT ALL + 87 FROM tab0, tab2 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT ALL - col1 + + col2 * - col2 AS col0 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT + - col1 * cor0.col1 AS col2 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ( col0 ) AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT 11 AS col2 FROM tab1 AS cor0
----
11
11
11

query I rowsort
SELECT + col1 * - col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - ( - col1 ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - + 40 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2876
3209
9176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * col1 + col0 * - col1 * 68 col2 FROM tab2 AS cor0
----
-14973
-317538
-92667

query I rowsort
SELECT 26 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

onlyif mysql # use DIV operator for integer division
query I rowsort label-5299
SELECT col2 DIV - col0 + + col0 FROM tab1 AS cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-5299
SELECT col2 / - col0 + + col0 FROM tab1 AS cor0
----
-15
64
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5300
SELECT - col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5300
SELECT - col0 / col0 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col1 + col1 * col0 * - ( tab1.col0 ) FROM tab1
----
-208
-40950
-83187

onlyif mysql # use DIV operator for integer division
query I rowsort label-5302
SELECT 15 + col2 DIV + col0 FROM tab2
----
15
15
18

skipif mysql # not compatible
query I rowsort label-5302
SELECT 15 + col2 / + col0 FROM tab2
----
15
15
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-5303
SELECT ALL 35 + - col1 DIV col1 AS col0 FROM tab1
----
34
34
34

skipif mysql # not compatible
query I rowsort label-5303
SELECT ALL 35 + - col1 / col1 AS col0 FROM tab1
----
34
34
34

query I rowsort
SELECT DISTINCT col1 + col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5305
SELECT ( col2 ) DIV col1 + + CAST( ( col2 ) + - ( col2 ) AS SIGNED ) FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5305
SELECT ( col2 ) / col1 + + CAST ( ( col2 ) + - ( col2 ) AS INTEGER ) FROM tab1
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 3 col1 FROM tab1
----
13
16
29

query I rowsort
SELECT DISTINCT + - ( + col2 ) * - cor0.col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5308
SELECT + col2 DIV col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5308
SELECT + col2 / col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL + + 21 * + 5 FROM tab2 AS cor0
----
105
105
105

query I rowsort
SELECT + col1 * + col2 + - col0 * col0 FROM tab2 cor0
----
-4550
-5595
788

query I rowsort
SELECT - 19 FROM tab0 cor0
----
-19
-19
-19

query I rowsort
SELECT + 53 FROM tab2 AS cor0
----
53
53
53

query I rowsort
SELECT DISTINCT - 64 AS col2 FROM tab0 AS cor0
----
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-5314
SELECT - + 65 DIV col1 AS col1 FROM tab1 AS cor0
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-5314
SELECT - + 65 / col1 AS col1 FROM tab1 AS cor0
----
-2
-5
-6

query I rowsort
SELECT ALL - - cor0.col0 + - col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + ( + col1 ) * col1 FROM tab0 cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * cor0.col1 col1 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col0 col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT 95 + - col2 AS col1 FROM tab0 AS cor0
----
13
62
94

query I rowsort
SELECT DISTINCT col1 * - col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - col0 + col2 * + ( col0 ) FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT 18 * - col0 + col1 + col2 AS col2 FROM tab0
----
-1429
-313
-532

query I rowsort
SELECT ALL col1 * col2 + col0 AS col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-5324
SELECT DISTINCT - - col1 DIV col2 AS col0 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5324
SELECT DISTINCT - - col1 / col2 AS col0 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL col1 * col1 * - 94 FROM tab0 AS cor0
----
-695224
-778414
-884446

query I rowsort
SELECT ALL - - 11 * - cor0.col1 AS col2 FROM tab0 cor0
----
-1001
-1067
-946

onlyif mysql # use DIV operator for integer division
query I rowsort label-5327
SELECT - col2 + col0 * ( + cor0.col0 ) DIV col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-5327
SELECT - col2 + col0 * ( + cor0.col0 ) / col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + + col0 + cor0.col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT col2 + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col0 - 37 AS col0 FROM tab2 AS cor0
----
-30
41
42

query I rowsort
SELECT - col0 + ( 77 ) FROM tab0 AS cor0
----
-12
42
53

query I rowsort
SELECT + col0 * - 27 - - col0 * col0 * - ( ( - col1 ) + col1 ) FROM tab1 cor0
----
-1728
-2160
-81

query I rowsort
SELECT col0 + - 57 * - col2 FROM tab2 AS cor0
----
1546
1560
2245

query I rowsort
SELECT - col2 * col2 AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL + + col1 + col0 AS col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 * col0 + - col0 col2 FROM tab1 AS cor0
----
49
566
947

query I rowsort
SELECT col2 * 95 AS col1 FROM tab2 cor0
----
2470
2565
3610

query I rowsort
SELECT ALL - + col1 * - col0 * col1 + + col2 AS col1 FROM tab1 AS cor0
----
13616
2082
6457

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col2 + 64 * + col0 col0 FROM tab2 AS cor0
----
452
5025
5035

query I rowsort
SELECT DISTINCT + - col1 + + col0 * - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-13533
-2054
-6410

query I rowsort
SELECT DISTINCT col0 + + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 37 col0 FROM tab2 cor0
----
37
37
37

query I rowsort
SELECT + col1 + 97 AS col0 FROM tab1
----
107
110
123

query IIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab2 cor1
----
54 values hashing to d8165ceb99ded93f34ad83c310a80ea7

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) * - col0 * + cor0.col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - 81 + col0 * col0 * - cor0.col1 FROM tab1 AS cor0
----
-315
-41041
-83281

query I rowsort
SELECT 82 * - col0 AS col0 FROM tab2 AS cor0
----
-574
-6396
-6478

query I rowsort
SELECT + 71 FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT ALL + 85 + + cor0.col2 AS col2 FROM tab2 cor0
----
111
112
123

query I rowsort
SELECT DISTINCT - ( + col0 ) + + col1 - col0 AS col0 FROM tab2 AS cor0
----
-141
-97
17

query I rowsort
SELECT - col1 + - col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + 88 FROM tab0 AS cor0
----
88

query I rowsort
SELECT ALL col2 + - cor0.col2 * - col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL - ( col1 ) * + col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL col1 + col2 * col2 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT + - col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT col0 * col2 - - col2 DIV col2 FROM tab1
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-5358
SELECT col0 * col2 - - col2 / col2 FROM tab1
----
163
3649
7681

query I rowsort
SELECT ( - 1 * + col0 ) AS col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ( 91 ) FROM tab0
----
91
91
91

query I rowsort
SELECT DISTINCT + + 92 + - cor0.col1 FROM tab1 cor0
----
66
79
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5362
SELECT col2 DIV col2 col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5362
SELECT col2 / col2 col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - col2 + - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 22 FROM tab2 cor0
----
22
22
22

query I rowsort
SELECT DISTINCT - + 2 * cor0.col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5367
SELECT DISTINCT col0 * col2 DIV + cor0.col2 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5367
SELECT DISTINCT col0 * col2 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - 21 - col1 AS col2 FROM tab2
----
-38
-52
-80

query I rowsort
SELECT DISTINCT col1 + + col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 - + col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + - col1 + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + - col1 AS col2 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT col1 * + tab0.col1 * col1 + - col1 * col1 * + col0 FROM tab0
----
16562
458552
583358

query I rowsort
SELECT DISTINCT col2 AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + - 7 + col1 FROM tab0 AS cor0
----
79
84
90

query I rowsort
SELECT ALL 55 FROM tab1, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT DISTINCT 68 + - 68 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - cor1.col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5379
SELECT ALL - - col1 DIV - col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5379
SELECT ALL - - col1 / - col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + + 88 + col2 FROM tab1 AS cor0
----
142
145
184

query I rowsort
SELECT 19 + 88 FROM tab0 AS cor0
----
107
107
107

query I rowsort
SELECT DISTINCT - col0 + - tab0.col2 * ( + col0 ) FROM tab0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + 90 col1 FROM tab2
----
52
63
64

query I rowsort
SELECT col2 * - col1 + col0 * - col0 FROM tab1
----
-1413
-4666
-7648

query I rowsort
SELECT - col2 + 9 * col2 AS col2 FROM tab1
----
432
456
768

query I rowsort
SELECT DISTINCT 80 AS col2 FROM tab0
----
80

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 22 + - col1 AS REAL ) FROM tab2
----
-37
-9
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5388
SELECT - CAST( col2 AS SIGNED ) + + col2 DIV col2 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5388
SELECT - CAST ( col2 AS INTEGER ) + + col2 / col2 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT + 24 FROM tab2
----
24
24
24

query I rowsort
SELECT - ( ( - col1 ) ) + col2 FROM tab1
----
109
67
80

query I rowsort
SELECT 11 AS col2 FROM tab0 AS cor0
----
11
11
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-5392
SELECT ALL + + cor0.col0 DIV + col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5392
SELECT ALL + + cor0.col0 / + col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - 95 * col2 + + col0 AS col2 FROM tab2 AS cor0
----
-2392
-2558
-3531

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) < NULL
----

query I rowsort
SELECT ALL + col1 * - col2 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col1 * + col2 * col1 FROM tab2 WHERE NULL BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT ALL - col1 * col2 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT col0 / - col0 FROM tab0 WHERE NULL IN ( - col1 * - col2 + col0 * + col2 * col2 + - col0 * - col0 / col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * col0 col2 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT + col1 * - col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5401
SELECT DISTINCT col0 * col2 DIV col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5401
SELECT DISTINCT col0 * col2 / col0 FROM tab2 AS cor0
----
26
27
38

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT - tab1.col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT - col1 NOT IN ( + cor0.col0 )
----

query I rowsort
SELECT DISTINCT - col2 * - col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + col0 * + col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col2 * col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE - col2 + - col2 BETWEEN ( + col1 ) AND NULL
----

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE + col1 = NULL
----

query IIIIII rowsort
SELECT * FROM tab2, tab1 cor0 WHERE NOT NULL BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT tab1.col0 * - col1 * - col0 AS col2 FROM tab1
----
234
40960
83200

query I rowsort
SELECT + col1 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND col1 * col2 AND NOT ( - col1 ) NOT BETWEEN col1 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT + col1 + - col0 + - col2 * col1 FROM tab1
----
-1315
-1381
-624

query I rowsort
SELECT tab2.col2 * col0 * col0 FROM tab2
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col2 + - col1 * + col0 + - col2 col0 FROM tab2
----
-1419
-271
-4654

query I rowsort
SELECT DISTINCT col2 + + col2 + col0 AS col1 FROM tab2
----
130
155
61

query I rowsort
SELECT DISTINCT + col1 + col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT col0 * + col1 - - col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-5420
SELECT ALL + - col0 DIV + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5420
SELECT ALL + - col0 / + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * col1 * - col0 FROM tab2 AS cor0
----
-106114
-1550
-359015

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + cor0.col1 col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - - col1 + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5425
SELECT DISTINCT - col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5425
SELECT DISTINCT - col0 / col0 AS col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL + - col1 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - + col2 * + col1 * col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT cor0.col0 + - cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT + col2 * - cor0.col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + + col0 + col1 * + cor0.col1 * - col0 AS col0 FROM tab1 cor0
----
-13440
-2025
-6336

query I rowsort
SELECT ALL - col2 * + col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 + - col2 + col1 * cor0.col2 col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5433
SELECT ALL col1 DIV - col0 AS col1 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-5433
SELECT ALL col1 / - col0 AS col1 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT col2 + - col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + col2 * col2 + cor0.col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT - col0 + col0 * col2 FROM tab0
----
0
7209
768

query I rowsort
SELECT ALL + col1 + col1 * - col1 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT + col1 + col2 + - col2 FROM tab0
----
86
91
97

query I rowsort
SELECT + col2 + + col0 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT col0 + + col1 AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT + col1 * col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + col0 * col2 * col2 + - col1 * - tab1.col2 FROM tab1
----
10152
208506
738528

query I rowsort
SELECT + + col2 + col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5444
SELECT + col2 * CAST( - col0 AS SIGNED ) + col1 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif mysql # not compatible
query I rowsort label-5444
SELECT + col2 * CAST ( - col0 AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT 26 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT + col2 * col1 + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL 41 + + 81 FROM tab2 AS cor0
----
122
122
122

query I rowsort
SELECT - + col0 AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT 75 FROM tab0 AS cor0
----
75

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col0 + col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT + - col0 + col2 AS col1 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5453
SELECT DISTINCT + col0 DIV 53 col1 FROM tab0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5453
SELECT DISTINCT + col0 / 53 col1 FROM tab0
----
0
1

query I rowsort
SELECT DISTINCT - col0 * - col0 * 12 AS col1 FROM tab2
----
588
73008
74892

onlyif mysql # use DIV operator for integer division
query I rowsort label-5455
SELECT col2 DIV - tab2.col0 AS col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-5455
SELECT col2 / - tab2.col0 AS col0 FROM tab2
----
-3
0
0

query I rowsort
SELECT tab2.col2 * col1 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL 52 + - 13 AS col2 FROM tab0
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-5458
SELECT 32 DIV 72 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5458
SELECT 32 / 72 AS col0 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5459
SELECT DISTINCT ( + ( - tab2.col1 ) ) + CAST( + 12 AS SIGNED ) * col1 FROM tab2
----
187
341
649

skipif mysql # not compatible
query I rowsort label-5459
SELECT DISTINCT ( + ( - tab2.col1 ) ) + CAST ( + 12 AS INTEGER ) * col1 FROM tab2
----
187
341
649

query I rowsort
SELECT 3 * col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT + col2 * - col2 - col2 * + 70 FROM tab0 AS cor0
----
-12464
-3399
-71

query I rowsort
SELECT col2 * cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5463
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5463
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5464
SELECT DISTINCT + col0 * - 40 + col1 * + CAST( 64 AS SIGNED ) + + col1 * 68 AS col1 FROM tab1
----
-1240
-1484
3312

skipif mysql # not compatible
query I rowsort label-5464
SELECT DISTINCT + col0 * - 40 + col1 * + CAST ( 64 AS INTEGER ) + + col1 * 68 AS col1 FROM tab1
----
-1240
-1484
3312

query I rowsort
SELECT DISTINCT 80 FROM tab1
----
80

query I rowsort
SELECT ALL - 56 FROM tab2
----
-56
-56
-56

query I rowsort
SELECT DISTINCT 83 AS col0 FROM tab1, tab1 AS cor0
----
83

query I rowsort
SELECT tab2.col0 * - 98 * - col0 + 48 + 99 * tab2.col0 AS col2 FROM tab2
----
5543
604002
619487

query I rowsort
SELECT - 1 FROM tab1, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT DISTINCT + 67 AS col2 FROM tab2
----
67

query I rowsort
SELECT 28 * tab1.col1 AS col2 FROM tab1
----
280
364
728

query I rowsort
SELECT col2 * - cor0.col1 + - 34 AS col1 FROM tab1 AS cor0
----
-1282
-1438
-604

query I rowsort
SELECT col2 + col0 * - ( col2 ) * - col1 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT + 65 * + col1 + + col2 * col1 * col2 FROM tab1 AS cor0
----
120653
33140
77506

query I rowsort
SELECT + - col2 * col1 + ( ( col2 ) ) * + 57 AS col0 FROM tab1 AS cor0
----
1674
2679
4224

query I rowsort
SELECT cor0.col2 + - col0 * col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - col1 * col0 + + col2 FROM tab1 AS cor0
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 13 * - col2 * - col2 col0 FROM tab0
----
13
14157
87412

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5479
SELECT ALL + col1 * col0 - - CAST( NULL AS SIGNED ) * 38 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5479
SELECT ALL + col1 * col0 - - CAST ( NULL AS INTEGER ) * 38 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * - tab2.col1 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 col0 FROM tab2, tab0, tab1 cor0
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT DISTINCT - col2 * - col2 * + col0 AS col0 FROM tab1
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 * + col0 col2 FROM tab2
----
469
5226
5293

query I rowsort
SELECT - col0 + + col1 AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT col0 + col0 - + 0 AS col1 FROM tab0
----
178
48
70

query I rowsort
SELECT - cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - 3 + col0 + col0 col0 FROM tab2 cor0
----
-21
-79
107

query I rowsort
SELECT ALL col2 * + 33 AS col2 FROM tab0 AS cor0
----
1089
2706
33

query I rowsort
SELECT DISTINCT + - col0 - - col2 * + col0 * - col1 AS col1 FROM tab2 AS cor0
----
-119730
-51113
-5866

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5490
SELECT DISTINCT col0 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5490
SELECT DISTINCT col0 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col0 + col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL col2 * 45 + col1 + + col2 FROM tab2 AS cor0
----
1255
1273
1765

query I rowsort
SELECT ALL - col2 * + 20 AS col1 FROM tab0 cor0
----
-1640
-20
-660

query I rowsort
SELECT - col2 * ( 60 ) - col0 FROM tab2 AS cor0
----
-1627
-1638
-2359

query I rowsort
SELECT - col1 + cor0.col1 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + ( - 3 ) col1 FROM tab1 AS cor0
----
0
61
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-5497
SELECT col2 DIV + ( + 15 ) + col1 FROM tab0 AS cor0
----
88
96
97

skipif mysql # not compatible
query I rowsort label-5497
SELECT col2 / + ( + 15 ) + col1 FROM tab0 AS cor0
----
88
96
97

query I rowsort
SELECT - 67 FROM tab0
----
-67
-67
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * - 46 - - col1 col1 FROM tab0 cor0
----
-3870
-4095
-4365

query I rowsort
SELECT ALL - col0 + + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + - col1 * - col0 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-5502
SELECT ALL col2 DIV + cor0.col1 + + col1 * cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-5502
SELECT ALL col2 / + cor0.col1 + + col1 * cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL col2 - + ( - cor0.col0 ) * col1 * col2 AS col2 FROM tab0 cor0
----
3396
664200
68145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + 20 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT ( - col0 ) + - col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT - col1 * 38 AS col1 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT DISTINCT - + 74 + col1 + col0 FROM tab1 AS cor0
----
-45
0
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * - cor0.col2 col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - - ( - 8 ) AS col1 FROM tab0 AS cor0
----
-8

query I rowsort
SELECT DISTINCT + + cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + + col0 * col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + col1 * - ( - col0 ) + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL 3 AS col0 FROM tab2 AS cor0
----
3
3
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5515
SELECT ALL + col0 DIV col1 + + 27 AS col0 FROM tab1 AS cor0
----
27
33
33

skipif mysql # not compatible
query I rowsort label-5515
SELECT ALL + col0 / col1 + + 27 AS col0 FROM tab1 AS cor0
----
27
33
33

query I rowsort
SELECT + - 66 - col2 AS col1 FROM tab0 AS cor0
----
-148
-67
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5517
SELECT DISTINCT - col2 * cor0.col0 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5517
SELECT DISTINCT - col2 * cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col1 + + cor0.col2 + col2 * + 45 FROM tab1 AS cor0
----
2510
2632
4429

query I rowsort
SELECT col1 + - col1 * + 22 FROM tab0 AS cor0
----
-1806
-1911
-2037

query I rowsort
SELECT DISTINCT + ( col1 ) * 51 FROM tab0 AS cor0
----
4386
4641
4947

onlyif mysql # use DIV operator for integer division
query I rowsort label-5521
SELECT + + col1 DIV cor0.col1 + 20 FROM tab2 AS cor0
----
21
21
21

skipif mysql # not compatible
query I rowsort label-5521
SELECT + + col1 / cor0.col1 + 20 FROM tab2 AS cor0
----
21
21
21

query I rowsort
SELECT - 57 * - col0 + col1 FROM tab2 AS cor0
----
430
4505
4520

query I rowsort
SELECT + 95 FROM tab2, tab1 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5524
SELECT - CAST( NULL AS SIGNED ) / 98 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5524
SELECT - CAST ( NULL AS INTEGER ) / 98 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ( - col0 ) AS col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL + ( - col2 ) AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT + col2 + 4 * col1 AS col2 FROM tab1
----
148
158
97

query I rowsort
SELECT DISTINCT col2 * 61 AS col2 FROM tab2
----
1586
1647
2318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) col1 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5530
SELECT DISTINCT + col2 DIV + col0 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5530
SELECT DISTINCT + col2 / + col0 AS col0 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5531
SELECT ALL - - CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5531
SELECT ALL - - CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort
SELECT col0 * - ( + col1 + - CAST ( + col2 AS REAL ) ) FROM tab0 cor0
----
-1272
-3360
-801

query I rowsort
SELECT DISTINCT - - cor0.col0 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT cor0.col2 + col2 * + col1 AS col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5535
SELECT ALL + CAST( + col2 AS SIGNED ) * col2 - CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5535
SELECT ALL + CAST ( + col2 AS INTEGER ) * col2 - CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - - 30 * col0 * col1 AS col1 FROM tab1 AS cor0
----
19200
2340
31200

query I rowsort
SELECT DISTINCT - + col1 * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - 70 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1190
-2170
-4130

query I rowsort
SELECT 93 * + col0 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT ALL 20 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT DISTINCT - col2 * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5543
SELECT DISTINCT - col1 DIV - col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5543
SELECT DISTINCT - col1 / - col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT - col2 * + col2 - ( col0 ) FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ALL col0 * col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + col1 + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + col2 + + col2 FROM tab1 AS cor0
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 col0 FROM tab1, tab2, tab1 AS cor0, tab2 AS cor1
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT DISTINCT col2 * - col2 AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT - - col0 + col2 * + ( - 19 ) * col0 FROM tab2 AS cor0
----
-3584
-38454
-56959

query I rowsort
SELECT ALL + col2 * 28 FROM tab1 cor0
----
1512
1596
2688

query I rowsort
SELECT - + col1 * ( - col0 ) FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL cor0.col2 + - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL col2 + - 8 AS col0 FROM tab0 AS cor0
----
-7
25
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 90 col1 FROM tab0 cor0
----
-2160
-3150
-8010

query I rowsort
SELECT ALL - col1 + 57 + 25 * - col0 FROM tab2 AS cor0
----
-149
-1935
-1952

onlyif mysql # use DIV operator for integer division
query I rowsort label-5558
SELECT DISTINCT - col2 + ( ( col2 ) ) + + col2 DIV - col0 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5558
SELECT DISTINCT - col2 + ( ( col2 ) ) + + col2 / - col0 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT - - col1 * col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - col1 * 44 AS col1 FROM tab0 AS cor0
----
-3784
-4004
-4268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5561
SELECT DISTINCT col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5561
SELECT DISTINCT col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 9 * - col2 + - col1 - col2 * col1 col0 FROM tab0 AS cor0
----
22618
59605
679

query I rowsort
SELECT ALL - - cor0.col2 * - cor0.col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col0 * + col0 + col2 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-5565
SELECT ALL + col2 * + 99 + - col2 DIV + col1 AS col1 FROM tab2 AS cor0
----
2574
2673
3760

skipif mysql # not compatible
query I rowsort label-5565
SELECT ALL + col2 * + 99 + - col2 / + col1 AS col1 FROM tab2 AS cor0
----
2574
2673
3760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5566
SELECT DISTINCT - + col0 + - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5566
SELECT DISTINCT - + col0 + - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * 26 col1 FROM tab2 AS cor0
----
182
2028
2054

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5568
SELECT - col2 - CAST( 4 AS SIGNED ) * col1 col0 FROM tab0 AS cor0
----
-377
-389
-446

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5568
SELECT - col2 - CAST ( 4 AS INTEGER ) * col1 col0 FROM tab0 AS cor0
----
-377
-389
-446

query I rowsort
SELECT DISTINCT + - col0 * 13 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT - 4 AS col2 FROM tab0 cor0
----
-4
-4
-4

query I rowsort
SELECT + - 73 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

onlyif mysql # use DIV operator for integer division
query I rowsort label-5572
SELECT ALL + cor0.col2 DIV + col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5572
SELECT ALL + cor0.col2 / + col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT cor0.col1 + col2 AS col1 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 + - col2 col1 FROM tab0 cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT + + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - 35 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT ALL + cor1.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - col2 + 99 FROM tab2
----
61
72
73

query IIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab2, tab1 AS cor1
----
243 values hashing to 098e223d780e18b6582523fd6f55eec9

query I rowsort
SELECT 65 FROM tab2 AS cor0
----
65
65
65

query I rowsort
SELECT - 7 + + col0 FROM tab2 AS cor0
----
0
71
72

query I rowsort
SELECT + 57 + + ( + col0 ) AS col0 FROM tab1 AS cor0
----
121
137
60

query I rowsort
SELECT DISTINCT - 48 * col0 FROM tab0 AS cor0
----
-1152
-1680
-4272

onlyif mysql # use DIV operator for integer division
query I rowsort label-5584
SELECT DISTINCT - col2 DIV + 84 AS col1 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5584
SELECT DISTINCT - col2 / + 84 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5585
SELECT - + CAST( NULL AS SIGNED ) + col1 * col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5585
SELECT - + CAST ( NULL AS INTEGER ) + col1 * col0 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 75 * 8 + col0 * + ( - col0 + + col0 * ( ( col2 ) ) ) AS col0 FROM tab2 AS cor0
----
151500
230317
674

query I rowsort
SELECT - + ( + col0 ) + col2 * col1 FROM tab0 cor0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col0 col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 + ( + col0 ) * col0 FROM tab0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5590
SELECT + col2 + ( + 49 ) + + col0 DIV col1 FROM tab1
----
103
112
151

skipif mysql # not compatible
query I rowsort label-5590
SELECT + col2 + ( + 49 ) + + col0 / col1 FROM tab1
----
103
112
151

query I rowsort
SELECT ALL - col0 + - col1 * col2 AS col2 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT col2 + + cor0.col2 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5593
SELECT DISTINCT - cor1.col2 DIV 61 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-5593
SELECT DISTINCT - cor1.col2 / 61 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
0

query I rowsort
SELECT - 38 * col0 AS col1 FROM tab2
----
-266
-2964
-3002

query I rowsort
SELECT DISTINCT ( 21 ) FROM tab2 cor0
----
21

query I rowsort
SELECT + + col2 * - col2 + col1 + + col1 * + col2 FROM tab2 cor0
----
-781
139
917

onlyif mysql # use DIV operator for integer division
query I rowsort label-5597
SELECT + + col2 DIV col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-5597
SELECT + + col2 / col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL - cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5599
SELECT - col0 * CAST( NULL AS SIGNED ) - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5599
SELECT - col0 * CAST ( NULL AS INTEGER ) - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * - col1 + - 48 FROM tab2 AS cor0
----
-1582
-694
-885

onlyif mysql # use DIV operator for integer division
query I rowsort label-5601
SELECT DISTINCT + col1 + - col0 DIV + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5601
SELECT DISTINCT + col1 + - col0 / + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT col0 + - tab0.col2 * - col2 * col0 FROM tab0
----
26160
598525
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + - cor0.col2 * - col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col0 * + ( col1 ) col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - + col2 + col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - 3 AS col1 FROM tab0, tab0 AS cor0
----
-3

query I rowsort
SELECT DISTINCT + col0 * col1 + + col0 * col0 FROM tab2 AS cor0
----
10686
266
7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5609
SELECT - col2 + - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5609
SELECT - col2 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5610
SELECT col0 DIV col0 + col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5610
SELECT col0 / col0 + col0 FROM tab1
----
4
65
81

query I rowsort
SELECT - col2 * - tab0.col0 * + 10 FROM tab0
----
350
72980
7920

query I rowsort
SELECT + col2 - col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - + col0 + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5614
SELECT - + col2 + - cor0.col1 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5614
SELECT - + col2 + - cor0.col1 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 42 + - col2 AS col0 FROM tab2 AS cor0
----
15
16
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 37 * col1 + + col2 col0 FROM tab0 AS cor0
----
-3149
-3285
-3588

query I rowsort
SELECT + - col2 + + ( - col0 ) FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT col0 + 82 * - ( - cor0.col1 ) FROM tab1 cor0
----
1146
2135
884

query I rowsort
SELECT - col2 + + col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT cor0.col2 AS col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 43f0c51511c8642d19190fd4dfcf905a

query I rowsort
SELECT DISTINCT col0 + - col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT 17 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5626
SELECT + CAST( - col2 AS SIGNED ) * col0 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-5626
SELECT + CAST ( - col2 AS INTEGER ) * col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + 37 AS col0 FROM tab1
----
37
37
37

query I rowsort
SELECT - + col2 + + col0 * 38 * col0 + col1 FROM tab1 AS cor0
----
155601
243117
314

query I rowsort
SELECT - + col0 * - col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL col2 * - col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col1 * col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col0 * col2 + - ( col2 ) + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-505
1184
99

query I rowsort
SELECT DISTINCT - + cor0.col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - - col1 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 62 FROM tab2
----
-62
-62
-62

query I rowsort
SELECT DISTINCT + ( col2 * col1 ) AS col1 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5637
SELECT - col1 DIV - col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5637
SELECT - col1 / - col1 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5638
SELECT 61 DIV col0 col1 FROM tab0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5638
SELECT 61 / col0 col1 FROM tab0
----
0
1
2

query I rowsort
SELECT DISTINCT - col2 * - col2 * cor0.col2 + - col1 AS col0 FROM tab0 AS cor0
----
-96
35851
551277

query I rowsort
SELECT ALL + cor0.col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + + 95 + col2 * + col2 AS col2 FROM tab2 cor0
----
1539
771
824

query I rowsort
SELECT ALL + 5 * - col0 * col2 AS col1 FROM tab2 AS cor0
----
-10140
-15010
-945

query I rowsort
SELECT ALL + + col1 * + col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + 37 * col0 AS col2 FROM tab2 AS cor0
----
259
2886
2923

query I rowsort
SELECT DISTINCT - - col1 + col1 + col1 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT - ( + col0 ) * col2 - col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT 61 + + cor0.col1 FROM tab2 AS cor0
----
120
78
92

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1, tab2 AS cor1
----
3645 values hashing to 47906197307eee6829150d762058792a

query I rowsort
SELECT 65 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT 34 FROM tab2, tab1 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT ALL - col1 * col1 - 88 FROM tab0
----
-7484
-8369
-9497

onlyif mysql # use DIV operator for integer division
query I rowsort label-5652
SELECT ALL + tab2.col2 DIV col0 - - 92 FROM tab2
----
92
92
95

skipif mysql # not compatible
query I rowsort label-5652
SELECT ALL + tab2.col2 / col0 - - 92 FROM tab2
----
92
92
95

query I rowsort
SELECT - 61 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to c91d7b51e91f33d302e697913fb438b6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5654
SELECT col2 DIV + col0 AS col0 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-5654
SELECT col2 / + col0 AS col0 FROM tab2
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 ) + - ( - col2 ) col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + col0 * 2 FROM tab1
----
192
240
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - 7 + col0 FROM tab0 AS cor0
----
17
28
82

query I rowsort
SELECT DISTINCT col1 - - col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + - 59 * - 47 AS col1 FROM tab0 AS cor0
----
2773
2773
2773

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT col0 + - 26 FROM tab1
----
-23
38
54

query I rowsort
SELECT + 52 FROM tab0, tab1 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT + + col1 + - ( - col1 ) AS col2 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5665
SELECT - CAST( + 70 AS SIGNED ) * - col1 AS col0 FROM tab1 cor0
----
1820
700
910

skipif mysql # not compatible
query I rowsort label-5665
SELECT - CAST ( + 70 AS INTEGER ) * - col1 AS col0 FROM tab1 cor0
----
1820
700
910

query I rowsort
SELECT - - cor0.col0 * col0 FROM tab2 AS cor0
----
49
6084
6241

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 cor2
----
3645 values hashing to 752ce7d2fdd0678058de6a90ff2b0f3a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5668
SELECT DISTINCT - + CAST( NULL AS SIGNED ) + + col2 * col0 * + col2 AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5668
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) + + col2 * col0 * + col2 AS col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT + - cor0.col0 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT - 50 AS col2 FROM tab0 cor0
----
-50
-50
-50

query I rowsort
SELECT ALL col0 + ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL col1 * col1 + + col0 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT - ( - cor0.col0 ) * - col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - cor0.col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col0 col2 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * ( col0 ) col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5677
SELECT DISTINCT - - col0 * 47 + - col1 DIV 61 FROM tab2 cor0
----
329
3666
3713

skipif mysql # not compatible
query I rowsort label-5677
SELECT DISTINCT - - col0 * 47 + - col1 / 61 FROM tab2 cor0
----
329
3666
3713

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5678
SELECT CAST( NULL AS DECIMAL ) * - col1 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5678
SELECT CAST ( NULL AS REAL ) * - col1 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - cor0.col2 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - 86 FROM tab1 AS cor0
----
-86

query I rowsort
SELECT DISTINCT + ( 0 ) AS col2 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL - cor0.col1 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col1 * col1 * col0 + - col2 FROM tab0 AS cor0
----
177471
329314
736927

query I rowsort
SELECT - ( - col2 ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL tab1.col1 * tab1.col1 + 16 * 4 AS col2 FROM tab1
----
164
233
740

query I rowsort
SELECT - ( col0 * 54 ) AS col1 FROM tab1
----
-162
-3456
-4320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 97 + - col2 col0 FROM tab2
----
59
70
71

query I rowsort
SELECT DISTINCT + ( - col0 * - 13 ) + 96 AS col1 FROM tab1
----
1136
135
928

query I rowsort
SELECT ALL col0 + + col2 FROM tab1
----
121
176
57

query I rowsort
SELECT + col1 * - col2 AS col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5691
SELECT + col0 * col0 DIV col2 + + col2 * col0 DIV col0 FROM tab1
----
128
162
54

skipif mysql # not compatible
query I rowsort label-5691
SELECT + col0 * col0 / col2 + + col2 * col0 / col0 FROM tab1
----
128
162
54

query I rowsort
SELECT + col2 * + col0 AS col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + 61 * - col1 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT DISTINCT - 3 + col0 AS col1 FROM tab2 AS cor0
----
4
75
76

query I rowsort
SELECT + tab0.col0 + - col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT + tab1.col0 * + col0 + - 12 FROM tab1
----
-3
4084
6388

query I rowsort
SELECT DISTINCT + col2 * + tab2.col2 + col2 * col1 AS col0 FROM tab2
----
1566
2090
2210

query I rowsort
SELECT col2 + col0 * + col0 AS col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT - col1 * + 22 - 96 AS col0 FROM tab2 AS cor0
----
-1394
-470
-778

query I rowsort
SELECT DISTINCT + col0 * - col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col2 * + 85 AS col0 FROM tab2 AS cor0
----
-2210
-2295
-3230

query I rowsort
SELECT - col1 + ( + col1 ) * - col1 AS col1 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT DISTINCT - tab0.col2 * 28 * col1 AS col0 FROM tab0
----
-208936
-2716
-79464

onlyif mysql # use DIV operator for integer division
query I rowsort label-5704
SELECT ALL - cor0.col2 DIV - 94 + cor0.col2 * col0 + + col1 * cor0.col2 FROM tab1 AS cor0
----
1566
4218
8929

skipif mysql # not compatible
query I rowsort label-5704
SELECT ALL - cor0.col2 / - 94 + cor0.col2 * col0 + + col1 * cor0.col2 FROM tab1 AS cor0
----
1566
4218
8929

onlyif mysql # use DIV operator for integer division
query I rowsort label-5705
SELECT DISTINCT - col0 DIV - col0 - 63 FROM tab1 AS cor0
----
-62

skipif mysql # not compatible
query I rowsort label-5705
SELECT DISTINCT - col0 / - col0 - 63 FROM tab1 AS cor0
----
-62

query I rowsort
SELECT DISTINCT - - col2 + 40 * col1 FROM tab0 AS cor0
----
3473
3722
3881

query I rowsort
SELECT ALL + col2 + + ( col2 ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT cor0.col2 * + ( col2 ) + - col1 AS col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL + col0 * - col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + col0 + - 49 FROM tab2 AS cor0
----
-127
-128
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-5711
SELECT DISTINCT col2 + + 55 DIV - col0 AS col2 FROM tab1 AS cor0
----
36
57
96

skipif mysql # not compatible
query I rowsort label-5711
SELECT DISTINCT col2 + + 55 / - col0 AS col2 FROM tab1 AS cor0
----
36
57
96

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) AS col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL col0 + 73 * + col0 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT + - col1 + 18 * + 33 FROM tab1 AS cor0
----
568
581
584

query I rowsort
SELECT ALL + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col0 col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + col2 * + col2 + + col1 * col2 * - 56 + col0 AS col0 FROM tab0 AS cor0
----
-157815
-411059
-5396

query I rowsort
SELECT col1 + 55 * 67 FROM tab2 cor0
----
3702
3716
3744

query I rowsort
SELECT ALL 70 + col2 * - col0 FROM tab0
----
-722
-7228
35

query I rowsort
SELECT DISTINCT - col0 * + col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col2 + - 87 * - col0 AS col1 FROM tab0 AS cor0
----
2055
3044
7661

query I rowsort
SELECT + ( 59 ) AS col1 FROM tab2 AS cor0
----
59
59
59

query I rowsort
SELECT ALL - ( + col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5724
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5724
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + 72 AS col1 FROM tab0 AS cor0
----
72
72
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5726
SELECT - - col2 * col0 * col2 - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5726
SELECT - - col2 * col0 * col2 - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5727
SELECT - 33 DIV + col2 + col2 FROM tab0 cor0
----
-32
32
82

skipif mysql # not compatible
query I rowsort label-5727
SELECT - 33 / + col2 + col2 FROM tab0 cor0
----
-32
32
82

query I rowsort
SELECT + + col2 * + col2 - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT + col1 + col0 * col0 AS col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT ( + col1 ) * col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - + 12 AS col2 FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - ( + col2 ) * + col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col2 + col0 * col0 AS col2 FROM tab2 AS cor0
----
22
6058
6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 69 AS col0 FROM tab0 AS cor0
----
69

query I rowsort
SELECT + 72 - + col2 * col0 FROM tab0 AS cor0
----
-720
-7226
37

query I rowsort
SELECT ALL + col0 + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT 62 + 68 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 243bcbbd06c49366dbe4a52c66de2a1d

query I rowsort
SELECT cor0.col0 * - col0 + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT + - col1 * cor0.col1 + - col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT ALL - col0 + - col2 * 42 FROM tab0 AS cor0
----
-1410
-3533
-77

query I rowsort
SELECT - col2 + - 58 FROM tab2
----
-84
-85
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5743
SELECT + col0 * - col1 + tab1.col0 * + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5743
SELECT + col0 * - col1 + tab1.col0 * + CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL col0 + col2 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - - 26 - col1 FROM tab1 AS cor0
----
0
13
16

query I rowsort
SELECT ALL col2 * - col0 - + col0 AS col1 FROM tab1
----
-165
-3712
-7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5748
SELECT + col2 * col2 - - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5748
SELECT + col2 * col2 - - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 62 * col1 + col0 col1 FROM tab0 AS cor0
----
5356
5731
6049

query I rowsort
SELECT DISTINCT - 85 * col1 AS col0 FROM tab1 AS cor0
----
-1105
-2210
-850

query I rowsort
SELECT DISTINCT 64 + - col0 * col2 AS col2 FROM tab2 AS cor0
----
-125
-1964
-2938

query I rowsort
SELECT ALL - 59 * - col2 + 98 FROM tab2 AS cor0
----
1632
1691
2340

query I rowsort
SELECT 37 * - col1 + + 18 FROM tab0 cor0
----
-3164
-3349
-3571

onlyif mysql # use DIV operator for integer division
query I rowsort label-5754
SELECT ALL cor0.col0 + col1 DIV col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-5754
SELECT ALL cor0.col0 + col1 / col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + 79 - - col1 AS col1 FROM tab2 AS cor0
----
110
138
96

query I rowsort
SELECT - col2 * + col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + col0 * - col2 - 44 AS col0 FROM tab0 AS cor0
----
-7342
-79
-836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * col1 * + col0 col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - - col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - + col1 + + cor0.col0 FROM tab0 cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5762
SELECT DISTINCT + + 97 * + col1 + 44 DIV 80 FROM tab2 cor0
----
1649
3007
5723

skipif mysql # not compatible
query I rowsort label-5762
SELECT DISTINCT + + 97 * + col1 + 44 / 80 FROM tab2 cor0
----
1649
3007
5723

query I rowsort
SELECT + + 55 FROM tab2 AS cor0
----
55
55
55

query I rowsort
SELECT + col2 * + col2 + + 68 + ( + col2 ) AS col0 FROM tab1 AS cor0
----
3038
3374
9380

query I rowsort
SELECT - - col1 * col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col2 * col2 + + col0 col2 FROM tab0 cor0
----
-1032
-6553
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-5767
SELECT - cor0.col2 DIV - col1 + - 59 + - col0 AS col2 FROM tab2 cor0
----
-136
-137
-66

skipif mysql # not compatible
query I rowsort label-5767
SELECT - cor0.col2 / - col1 + - 59 + - col0 AS col2 FROM tab2 cor0
----
-136
-137
-66

query I rowsort
SELECT DISTINCT 29 + - col2 AS col1 FROM tab1
----
-25
-28
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 col1 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5770
SELECT ALL cor1.col2 * + CAST( NULL AS SIGNED ) + 36 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5770
SELECT ALL cor1.col2 * + CAST ( NULL AS INTEGER ) + 36 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - ( + col0 ) * col1 * + col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5772
SELECT DISTINCT + CAST( col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5772
SELECT DISTINCT + CAST ( col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + col2 * 57 FROM tab2 cor0
----
1482
1539
2166

query I rowsort
SELECT - ( - 20 ) FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT DISTINCT - col1 + + 50 FROM tab1 AS cor0
----
24
37
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-5776
SELECT DISTINCT - + col2 * + 86 + col1 DIV - 1 AS col0 FROM tab1 AS cor0
----
-4670
-4912
-8269

skipif mysql # not compatible
query I rowsort label-5776
SELECT DISTINCT - + col2 * + 86 + col1 / - 1 AS col0 FROM tab1 AS cor0
----
-4670
-4912
-8269

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2
----
972 values hashing to 09b120a8ff13ebafea7af10c2152241b

query I rowsort
SELECT ALL - ( 17 ) FROM tab2
----
-17
-17
-17

query I rowsort
SELECT ALL ( - 28 ) FROM tab1
----
-28
-28
-28

query I rowsort
SELECT + cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT + 79 + ( + cor0.col2 ) * col2 AS col1 FROM tab0 AS cor0
----
1168
6803
80

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab1, tab1 cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT 60 AS col0 FROM tab1
----
60
60
60

query I rowsort
SELECT DISTINCT + 71 AS col1 FROM tab1
----
71

query I rowsort
SELECT ALL - col1 * 63 AS col0 FROM tab2
----
-1071
-1953
-3717

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5786
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5786
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0 cor0
----
NULL

query I rowsort
SELECT ALL + + 1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT - ( - 70 ) FROM tab2, tab0 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT + 44 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
44

query I rowsort
SELECT - - 82 + col0 FROM tab1 cor0
----
146
162
85

query I rowsort
SELECT 99 + - col1 AS col1 FROM tab0 cor0
----
13
2
8

query I rowsort
SELECT ALL - 83 - - tab2.col2 FROM tab2
----
-45
-56
-57

query I rowsort
SELECT col1 * - 85 AS col2 FROM tab0
----
-7310
-7735
-8245

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5795
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5795
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5796
SELECT ( col2 ) - col1 DIV col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5796
SELECT ( col2 ) - col1 / col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - ( + col1 ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT - + col2 * - col2 + + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL + ( + col2 ) - cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( + col1 ) + col0 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - col1 * + col0 - - col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + 3 * col2 FROM tab2 cor0
----
114
78
81

query I rowsort
SELECT + + col0 * - col0 * + col1 + + col1 * 96 AS col1 FROM tab1 AS cor0
----
-40000
-81952
2262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 + - col1 col0 FROM tab2 AS cor0
----
-11
-39
3

query I rowsort
SELECT ALL 66 AS col1 FROM tab1
----
66
66
66

query I rowsort
SELECT 70 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT DISTINCT + tab2.col1 FROM tab2, tab1 cor0
----
17
31
59

query I rowsort
SELECT ( col0 ) * col2 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col2 + - col2 * cor0.col1 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5810
SELECT - + col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5810
SELECT - + col0 / + col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5811
SELECT + col1 * CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5811
SELECT + col1 * CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * + col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 * + ( + col1 * col1 ) AS col0 FROM tab0 AS cor0
----
636056
753571
912673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 col0 FROM tab0
----
54
54
54

query I rowsort
SELECT DISTINCT col0 * + col0 AS col1 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL - 20 * col0 FROM tab1
----
-1280
-1600
-60

query I rowsort
SELECT + col0 * + col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col2 * col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col2 * 51 + + 60 FROM tab0 AS cor0
----
-1623
-4122
9

query I rowsort
SELECT DISTINCT 37 FROM tab2, tab1 AS cor0
----
37

query I rowsort
SELECT - - col2 * col2 * cor0.col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + ( col1 ) FROM tab2
----
17
31
59

query I rowsort
SELECT + 11 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT DISTINCT + col0 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL col0 * - ( col1 ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 19 + + col1 FROM tab2 AS cor0
----
-2
12
40

query I rowsort
SELECT DISTINCT 84 + cor0.col1 FROM tab0 AS cor0
----
170
175
181

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + 42 AS REAL ) AS col1 FROM tab0 AS cor0
----
42

query I rowsort
SELECT - 38 * col2 FROM tab0 AS cor0
----
-1254
-3116
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5830
SELECT 37 DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5830
SELECT 37 / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT ALL + ( 82 ) * - cor0.col2 + cor0.col1 * - 88 * col0 FROM tab2 cor0
----
-121300
-21310
-407108

query I rowsort
SELECT DISTINCT + - 34 AS col0 FROM tab2 AS cor0
----
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5833
SELECT + + col1 + col2 DIV col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-5833
SELECT + + col1 + col2 / col1 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT col0 - col2 * + col1 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT + col0 + tab2.col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT - col2 * 16 FROM tab2
----
-416
-432
-608

query I rowsort
SELECT + col1 + col1 AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT col1 + 95 FROM tab2
----
112
126
154

query I rowsort
SELECT DISTINCT - - 80 - col2 FROM tab1 AS cor0
----
-16
23
26

query I rowsort
SELECT ALL - + col2 + + col0 * + cor0.col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + + col1 * + col0 * + col0 + - col1 AS col0 FROM tab2 AS cor0
----
106080
1488
358897

onlyif mysql # use DIV operator for integer division
query I rowsort label-5842
SELECT ALL - col2 + - col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-54
-58
-96

skipif mysql # not compatible
query I rowsort label-5842
SELECT ALL - col2 + - col0 / col2 AS col0 FROM tab1 AS cor0
----
-54
-58
-96

query I rowsort
SELECT ALL col0 + cor0.col0 * col1 * + col1 AS col2 FROM tab2 AS cor0
----
22910
271596
6734

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5845
SELECT DISTINCT col2 DIV col1 - 82 AS col1 FROM tab2 cor0
----
-80
-82

skipif mysql # not compatible
query I rowsort label-5845
SELECT DISTINCT col2 / col1 - 82 AS col1 FROM tab2 cor0
----
-80
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5846
SELECT + col2 + col1 * CAST( 36 + - col0 * col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-40543
-82636
756

skipif mysql # not compatible
query I rowsort label-5846
SELECT + col2 + col1 * CAST ( 36 + - col0 * col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-40543
-82636
756

query I rowsort
SELECT - + cor0.col1 * col2 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5848
SELECT ALL col1 + - col1 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5848
SELECT ALL col1 + - col1 * + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL - col2 * col2 + + 5 AS col0 FROM tab1 AS cor0
----
-2911
-3244
-9211

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 - col2 col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT cor0.col1 * + col0 * ( col0 * - col2 ) AS col1 FROM tab1 AS cor0
----
-12636
-2334720
-7987200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 * + col1 col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - 13 FROM tab0
----
-13
-13
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL 84 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT tab2.col0 * col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT 28 AS col1 FROM tab2
----
28
28
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-5859
SELECT + 97 DIV + col0 + + 53 FROM tab2 AS cor0
----
54
54
66

skipif mysql # not compatible
query I rowsort label-5859
SELECT + 97 / + col0 + + 53 FROM tab2 AS cor0
----
54
54
66

query I rowsort
SELECT - + 43 FROM tab2 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - cor0.col1 + + col0 * 12 AS col0 FROM tab1 AS cor0
----
10
758
947

onlyif mysql # use DIV operator for integer division
query I rowsort label-5862
SELECT DISTINCT ( + col2 ) DIV - col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5862
SELECT DISTINCT ( + col2 ) / - col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL - + col2 + + cor0.col0 * + col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - 20 + + cor0.col1 + - col2 AS col0 FROM tab0 cor0
----
-11
33
76

query I rowsort
SELECT ALL + 91 * cor0.col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
4459
553644
567931

query I rowsort
SELECT DISTINCT - col1 * + cor0.col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT 13 * ( col2 ) AS col0 FROM tab0 AS cor0
----
1066
13
429

query I rowsort
SELECT ( + col2 ) + cor0.col0 * col0 + cor0.col1 * - col0 FROM tab1 AS cor0
----
-15
3513
5456

query I rowsort
SELECT ALL - 93 FROM tab0, tab2 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT DISTINCT - ( + 14 ) * - cor0.col0 FROM tab1 cor0
----
1120
42
896

query IIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
243 values hashing to 5d85c5683e3ffd6d68920690d7302f7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5872
SELECT CAST( NULL AS SIGNED ) * - col2 - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5872
SELECT CAST ( NULL AS INTEGER ) * - col2 - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - 70 col0 FROM tab1 AS cor0
----
-124
-127
-166

query I rowsort
SELECT - 98 AS col0 FROM tab0
----
-98
-98
-98

query I rowsort
SELECT DISTINCT 18 + - 0 FROM tab2
----
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 57 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT ALL - tab0.col2 AS col0 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 + col2 col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - - col0 + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - tab0.col1 + - col1 * - col2 FROM tab0
----
0
2752
7371

query I rowsort
SELECT - 7 + col1 * - col2 FROM tab0
----
-104
-2845
-7469

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 97 * - tab2.col1 * + col1 col1 FROM tab2
----
28033
337657
93217

query I rowsort
SELECT DISTINCT ( - 27 ) AS col0 FROM tab0
----
-27

query I rowsort
SELECT ALL tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT col2 * 46 FROM tab0
----
1518
3772
46

query I rowsort
SELECT col0 + 70 FROM tab1
----
134
150
73

query I rowsort
SELECT col1 * + col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - tab1.col0 + tab1.col1 * col0 FROM tab1
----
576
75
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 53 col2 FROM tab0
----
-53
-53
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-5890
SELECT ( + col2 ) DIV + col0 + + col1 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5890
SELECT ( + col2 ) / + col0 + + col1 FROM tab2
----
17
34
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 * col0 ) + tab1.col0 col0 FROM tab1
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * col1 + + col2 col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - col0 * - ( col2 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col0 * ( col0 ) AS col1 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5895
SELECT DISTINCT + - col0 * + ( col2 ) + col1 DIV col1 FROM tab1 AS cor0
----
-161
-3647
-7679

skipif mysql # not compatible
query I rowsort label-5895
SELECT DISTINCT + - col0 * + ( col2 ) + col1 / col1 FROM tab1 AS cor0
----
-161
-3647
-7679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + ( - col0 ) col1 FROM tab0 AS cor0
----
-178
-48
-70

skipif mysql # not compatible
query I rowsort
SELECT ALL col1 + CAST ( cor0.col0 AS REAL ) * col2 AS col1 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT 18 FROM tab2, tab0, tab0 AS cor0
----
18

query I rowsort
SELECT ( - col2 ) * tab2.col1 + + 54 * - tab2.col0 AS col2 FROM tab2
----
-1215
-4912
-5746

query I rowsort
SELECT col1 * tab2.col1 - + 14 FROM tab2
----
275
3467
947

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 + - col1 col2 FROM tab0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5902
SELECT - CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5902
SELECT - CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT cor0.col1 * - 72 AS col1 FROM tab0 AS cor0
----
-6192
-6552
-6984

query I rowsort
SELECT ALL col1 * - col2 + col0 * - col0 FROM tab2 cor0
----
-6887
-7618
-886

onlyif mysql # use DIV operator for integer division
query I rowsort label-5906
SELECT ALL - - col0 DIV - 80 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5906
SELECT ALL - - col0 / - 80 AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5909
SELECT DISTINCT + col1 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5909
SELECT DISTINCT + col1 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 AS col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - col2 * + 49 - + col0 AS col0 FROM tab0 cor0
----
-1641
-4107
-84

query I rowsort
SELECT ALL col0 * + col2 + - ( + col0 ) FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT + - col2 * + cor0.col2 + ( col0 ) * + col1 FROM tab2 AS cor0
----
-101
-512
3926

query I rowsort
SELECT ALL col0 * col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT + tab2.col1 AS col0 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col2 col0 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * col0 * - col2 col1 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col2 col0 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 * + tab2.col1 col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT - col2 - + col1 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT - col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - + col0 + col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL col2 * col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5926
SELECT DISTINCT - cor0.col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-5926
SELECT DISTINCT - cor0.col0 / - col1 AS col0 FROM tab1 AS cor0
----
0
6

query I rowsort
SELECT ALL - col0 * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5928
SELECT - col1 DIV - col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5928
SELECT - col1 / - col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT tab2.col0 + + tab2.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 882fef197e3b41358c58e24f2db2f2e1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 97 * + col2 col1 FROM tab2 AS cor0
----
-2522
-2619
-3686

query I rowsort
SELECT col2 + cor0.col2 * + cor0.col1 + + col2 FROM tab1 AS cor0
----
1440
1512
684

query I rowsort
SELECT ALL - 78 FROM tab0 AS cor0
----
-78
-78
-78

query I rowsort
SELECT DISTINCT col0 + col2 * col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + col2 * col0 AS col2 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5935
SELECT 49 DIV col2 FROM tab0 AS cor0
----
0
1
49

skipif mysql # not compatible
query I rowsort label-5935
SELECT 49 / col2 FROM tab0 AS cor0
----
0
1
49

query I rowsort
SELECT DISTINCT + 93 * - col2 + col0 FROM tab1 AS cor0
----
-5019
-5237
-8848

onlyif mysql # use DIV operator for integer division
query I rowsort label-5937
SELECT ALL - + col0 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5937
SELECT ALL - + col0 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT - col1 * col2 * - col2 + col2 AS col1 FROM tab1 AS cor0
----
119904
32547
75870

query I rowsort
SELECT cor0.col0 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT - col2 * col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL - ( col2 ) + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * col1 + - col2 AS col0 FROM tab1 cor0
----
24
583
944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 col0 FROM tab0 AS cor0
----
-5
-5
-5

query I rowsort
SELECT ALL 6 AS col2 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT - - 2 FROM tab1 AS cor0
----
2
2
2

query I rowsort
SELECT ALL 3 + - col0 FROM tab0 cor0
----
-21
-32
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 88 + col2 col2 FROM tab0 AS cor0
----
-55
-6
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5949
SELECT DISTINCT col1 DIV col1 + - col2 * col1 * + cor0.col2 FROM tab0 AS cor0
----
-611883
-93653
-96

skipif mysql # not compatible
query I rowsort label-5949
SELECT DISTINCT col1 / col1 + - col2 * col1 * + cor0.col2 FROM tab0 AS cor0
----
-611883
-93653
-96

query I rowsort
SELECT - 89 FROM tab1 AS cor0
----
-89
-89
-89

query I rowsort
SELECT + ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - col1 * col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 28 AS col2 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT DISTINCT tab1.col1 AS col0 FROM tab1, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL tab1.col0 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - ( ( - col1 ) ) AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT - - col2 * - col1 + cor0.col0 * ( col1 + + col2 ) * col1 AS col2 FROM tab2 AS cor0
----
11749
389636
73219

query I rowsort
SELECT ALL 80 AS col0 FROM tab2
----
80
80
80

query I rowsort
SELECT ALL + 11 FROM tab0 AS cor0
----
11
11
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 col0 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5961
SELECT DISTINCT + 49 DIV cor0.col2 FROM tab0, tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5961
SELECT DISTINCT + 49 / cor0.col2 FROM tab0, tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5962
SELECT DISTINCT + col0 DIV col1 AS col0 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5962
SELECT DISTINCT + col0 / col1 AS col0 FROM tab2
----
0
1
4

query I rowsort
SELECT + 60 * col2 * - 39 FROM tab2 AS cor0
----
-60840
-63180
-88920

query I rowsort
SELECT DISTINCT 67 AS col0 FROM tab0, tab2 AS cor0
----
67

query I rowsort
SELECT ALL - ( - 22 ) FROM tab0 AS cor0
----
22
22
22

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT DISTINCT + tab2.col0 AS col0 FROM tab2, tab0 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 col2 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5969
SELECT ALL 35 * + 56 + + col2 DIV + col1 AS col0 FROM tab0
----
1960
1960
1960

skipif mysql # not compatible
query I rowsort label-5969
SELECT ALL 35 * + 56 + + col2 / + col1 AS col0 FROM tab0
----
1960
1960
1960

query I rowsort
SELECT DISTINCT - col2 + - col1 AS col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - 57 + tab1.col0 FROM tab1
----
-54
23
7

query I rowsort
SELECT + + ( 15 ) * + col0 + 88 * - col1 FROM tab0 AS cor0
----
-6673
-7208
-8011

query I rowsort
SELECT ALL ( 68 ) AS col0 FROM tab2
----
68
68
68

query I rowsort
SELECT ( + col1 ) - col1 * - col0 AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT - col2 - + col2 * col0 AS col1 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT tab2.col1 - col0 AS col0 FROM tab2
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5977
SELECT - CAST( NULL AS SIGNED ) - - tab0.col1 col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5977
SELECT - CAST ( NULL AS INTEGER ) - - tab0.col1 col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL tab1.col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + + 38 * col1 + + col2 FROM tab1 AS cor0
----
1042
437
590

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT DISTINCT - ( col1 ) + + col1 FROM tab1
----
0

query I rowsort
SELECT col0 - - 97 FROM tab0
----
121
132
186

query I rowsort
SELECT - ( col0 ) + + col2 * + 69 AS col2 FROM tab2
----
1716
1856
2543

query I rowsort
SELECT 62 - col2 AS col0 FROM tab1
----
-34
5
8

query I rowsort
SELECT DISTINCT - col1 - - 59 FROM tab0 AS cor0
----
-27
-32
-38

query I rowsort
SELECT ALL - 61 + 83 AS col1 FROM tab2 AS cor0
----
22
22
22

query I rowsort
SELECT - - 13 + col1 FROM tab2 AS cor0
----
30
44
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5988
SELECT ALL - - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5988
SELECT ALL - - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - col1 + col0 + col2 AS col1 FROM tab1 AS cor0
----
111
163
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col2 ) * col0 - + cor0.col2 col2 FROM tab1 cor0
----
-216
-3705
-7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5992
SELECT DISTINCT col2 * col1 DIV 26 FROM tab1 AS cor0
----
21
48
54

skipif mysql # not compatible
query I rowsort label-5992
SELECT DISTINCT col2 * col1 / 26 FROM tab1 AS cor0
----
21
48
54

query I rowsort
SELECT DISTINCT + 10 - + col0 FROM tab2 AS cor0
----
-68
-69
3

query I rowsort
SELECT + - col2 * col1 + + 39 AS col1 FROM tab1 AS cor0
----
-1209
-1365
-531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 57 col2 FROM tab2
----
57
57
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5996
SELECT ALL - col0 - cor0.col2 * - CAST( NULL AS SIGNED ) * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5996
SELECT ALL - col0 - cor0.col2 * - CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 94 + col0 * + ( + col2 ) AS col0 FROM tab2 AS cor0
----
1934
2908
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + col0 * col2 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - col2 * - 11 * + col1 AS col0 FROM tab1 AS cor0
----
13728
15444
6270

query I rowsort
SELECT - col1 * + col2 - col2 AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL col2 * + col1 + col1 * - col1 AS col2 FROM tab0
----
-4558
-819
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 11 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT ALL - col0 + tab1.col0 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6006
SELECT - col2 * - CAST( col2 AS SIGNED ) - col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-34
-574
297

skipif mysql # not compatible
query I rowsort label-6006
SELECT - col2 * - CAST ( col2 AS INTEGER ) - col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-34
-574
297

query I rowsort
SELECT + col0 - + 86 * - col2 FROM tab2 AS cor0
----
2314
2329
3347

query I rowsort
SELECT ALL + col1 + 28 * 56 FROM tab1 cor0
----
1578
1581
1594

query I rowsort
SELECT + - col0 * col2 - - col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col0 * - 66 AS col2 FROM tab0 AS cor0
----
-1584
-2310
-5874

query I rowsort
SELECT col2 * ( col2 ) + col2 AS col1 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT - col1 * ( col1 ) + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * - col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6015
SELECT col0 + col0 DIV - col2 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-6015
SELECT col0 + col0 / - col2 FROM tab1 AS cor0
----
3
63
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6016
SELECT DISTINCT cor0.col2 * CAST( NULL AS SIGNED ) + 88 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6016
SELECT DISTINCT cor0.col2 * CAST ( NULL AS INTEGER ) + 88 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL - col1 + 53 FROM tab1 AS cor0
----
27
40
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 66 col0 FROM tab1 AS cor0
----
-66
-66
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 76 * - col2 col0 FROM tab1 cor0
----
4104
4332
7296

query I rowsort
SELECT ALL - 40 AS col1 FROM tab2 AS cor0
----
-40
-40
-40

query I rowsort
SELECT ALL - - cor0.col0 * 5 AS col0 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT DISTINCT col2 * 47 AS col2 FROM tab0
----
1551
3854
47

query I rowsort
SELECT DISTINCT ( - col2 ) FROM tab1 cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + col2 col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL ( + col2 ) * col0 * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT + ( - col2 ) + - col2 * col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL - col0 * ( - col1 * ( col1 ) ) + - col2 + col1 AS col1 FROM tab2 AS cor0
----
22810
271551
6731

query I rowsort
SELECT ALL + ( - col0 ) + + col2 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + + col1 * + col0 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + ( 2 ) * col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL col2 - + col1 * col2 AS col2 FROM tab2
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col1 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col1 col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - col2 * - col0 * 4 FROM tab2
----
12008
756
8112

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT ALL col0 DIV 54 FROM tab2
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6035
SELECT ALL col0 / 54 FROM tab2
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6036
SELECT col0 / + CAST( NULL AS SIGNED ) + + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6036
SELECT col0 / + CAST ( NULL AS INTEGER ) + + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 7 * cor1.col2 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 78842a90a157a59490ffd43288254f32

onlyif mysql # use DIV operator for integer division
query I rowsort label-6038
SELECT col1 * + col1 DIV col1 col2 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6038
SELECT col1 * + col1 / col1 col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col2 * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query IIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 WHERE NULL = NULL
----

query I rowsort
SELECT col2 + + col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT + col2 * - ( - ( + col2 ) ) AS col1 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * ( + col0 ) col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT + col1 * - ( cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col2 * - col0 FROM tab0 cor0
----
-35
-7298
-792

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 8bda8b9cf32f196464e0ee0b41a5162d

query I rowsort
SELECT DISTINCT cor0.col0 * col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6048
SELECT + ( ( + col0 / - CAST( NULL AS SIGNED ) ) ) * - col0 / - col2 - ( - col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6048
SELECT + ( ( + col0 / - CAST ( NULL AS INTEGER ) ) ) * - col0 / - col2 - ( - col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - 23 ) * - col1 FROM tab2 AS cor0
----
1357
391
713

query I rowsort
SELECT col1 + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6051
SELECT col1 DIV - col0 - + col1 AS col1 FROM tab1 AS cor0
----
-10
-13
-34

skipif mysql # not compatible
query I rowsort label-6051
SELECT col1 / - col0 - + col1 AS col1 FROM tab1 AS cor0
----
-10
-13
-34

query I rowsort
SELECT + 91 * 95 * + cor0.col0 FROM tab1 AS cor0
----
25935
553280
691600

query I rowsort
SELECT col1 * - col1 + col2 * + 99 AS col1 FROM tab1 AS cor0
----
4670
5543
9335

query I rowsort
SELECT DISTINCT + cor0.col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - 57 * + col0 * cor0.col1 FROM tab2 AS cor0
----
-12369
-262314
-76551

query I rowsort
SELECT - - col2 * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + tab0.col1 * col2 + - col2 * + col0 * 81 FROM tab0
----
-2738
-583676
-61314

onlyif mysql # use DIV operator for integer division
query I rowsort label-6058
SELECT ALL col2 + - col1 - + col0 DIV + col0 AS col2 FROM tab0
----
-10
-54
-97

skipif mysql # not compatible
query I rowsort label-6058
SELECT ALL col2 + - col1 - + col0 / + col0 AS col2 FROM tab0
----
-10
-54
-97

query I rowsort
SELECT ALL col2 - + 26 AS col2 FROM tab1
----
28
31
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6060
SELECT ALL tab0.col0 DIV ( + col1 ) - + tab0.col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6060
SELECT ALL tab0.col0 / ( + col1 ) - + tab0.col0 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6061
SELECT DISTINCT + + col2 + - col0 DIV + 60 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-6061
SELECT DISTINCT + + col2 + - col0 / + 60 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT ALL + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col1 * col1 + - col2 AS col2 FROM tab0 cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT + 45 * - col2 + col1 * + 68 AS col1 FROM tab0 AS cor0
----
2498
4363
6551

query I rowsort
SELECT DISTINCT + col2 * - col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6066
SELECT ALL 61 DIV col0 FROM tab2 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-6066
SELECT ALL 61 / col0 FROM tab2 AS cor0
----
0
0
8

query I rowsort
SELECT - col0 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 1 + + col0 FROM tab1 cor0
----
4
65
81

query I rowsort
SELECT + - 16 FROM tab1 AS cor0
----
-16
-16
-16

query I rowsort
SELECT ALL - + col0 + + col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL - 22 AS col2 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT + 57 * - col0 AS col2 FROM tab0 AS cor0
----
-1368
-1995
-5073

onlyif mysql # use DIV operator for integer division
query I rowsort label-6073
SELECT ALL + col0 * - cor0.col0 + 3 DIV col0 FROM tab1 cor0
----
-4096
-6400
-8

skipif mysql # not compatible
query I rowsort label-6073
SELECT ALL + col0 * - cor0.col0 + 3 / col0 FROM tab1 cor0
----
-4096
-6400
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * col2 col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + ( col2 ) + 69 FROM tab0 cor0
----
102
151
70

query I rowsort
SELECT - 10 + + col2 FROM tab0
----
-9
23
72

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 61 AS REAL ) + col2 FROM tab0
----
143
62
94

query I rowsort
SELECT ALL - col2 - - col2 * + ( col2 ) AS col1 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT DISTINCT + col1 * col0 + col1 * 51 + + col1 AS col1 FROM tab2 AS cor0
----
1829
2227
7670

query I rowsort
SELECT ALL + 94 * + col2 + - col2 * + ( - col1 ) + col0 AS col2 FROM tab2
----
3382
4056
4297

query I rowsort
SELECT ALL col2 + + ( - col2 ) * ( ( col0 ) ) AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - ( tab0.col1 ) + col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL - 19 AS col2 FROM tab2
----
-19
-19
-19

query I rowsort
SELECT - 35 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT ALL - 0 * col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - + 77 * + col1 * cor0.col1 FROM tab1 AS cor0
----
-13013
-52052
-7700

query I rowsort
SELECT ALL - col1 * - col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 9 * col1 AS col1 FROM tab2 AS cor0
----
153
279
531

query I rowsort
SELECT DISTINCT + 48 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col0 col2 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT - 91 AS col0 FROM tab0
----
-91
-91
-91

query I rowsort
SELECT + col0 * - cor0.col0 * + ( col0 ) + + 35 FROM tab2 AS cor0
----
-308
-474517
-493004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + 22 col0 FROM tab2 AS cor0
----
100
101
29

query I rowsort
SELECT DISTINCT col1 * - col1 * - 90 AS col2 FROM tab0
----
665640
745290
846810

onlyif mysql # use DIV operator for integer division
query I rowsort label-6095
SELECT - col2 DIV - col1 + 13 * col1 FROM tab1
----
135
176
340

skipif mysql # not compatible
query I rowsort label-6095
SELECT - col2 / - col1 + 13 * col1 FROM tab1
----
135
176
340

onlyif mysql # use DIV operator for integer division
query I rowsort label-6096
SELECT 77 DIV + col1 + col1 * + col0 FROM tab2
----
1347
219
4603

skipif mysql # not compatible
query I rowsort label-6096
SELECT 77 / + col1 + col1 * + col0 FROM tab2
----
1347
219
4603

query I rowsort
SELECT + 85 * col0 AS col0 FROM tab1
----
255
5440
6800

query I rowsort
SELECT tab0.col0 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT + 74 + col1 AS col1 FROM tab1
----
100
84
87

query I rowsort
SELECT DISTINCT + 73 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
73

query I rowsort
SELECT ALL + cor0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT - + col0 * 35 AS col0 FROM tab2 AS cor0
----
-245
-2730
-2765

query I rowsort
SELECT ALL col1 - - col1 FROM tab0 AS cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + 62 col0 FROM tab1
----
116
119
158

query I rowsort
SELECT ALL - ( - tab0.col1 ) * col0 + col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT + col2 * col1 + + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + - ( + 85 ) AS col2 FROM tab1 AS cor0
----
-85
-85
-85

query I rowsort
SELECT DISTINCT - ( col1 ) + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT - col2 - col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + col0 * - col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 + + ( + col2 ) col1 FROM tab1 AS cor0
----
102
141
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-6112
SELECT ALL + col1 + col0 DIV - cor0.col0 + + 33 FROM tab0 AS cor0
----
118
123
129

skipif mysql # not compatible
query I rowsort label-6112
SELECT ALL + col1 + col0 / - cor0.col0 + + 33 FROM tab0 AS cor0
----
118
123
129

query I rowsort
SELECT - - 99 + + cor0.col2 + cor0.col0 FROM tab2 AS cor0
----
133
203
216

query I rowsort
SELECT ALL - col1 * - cor0.col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 24 + col1 * col0 FROM tab0 AS cor0
----
2088
3419
8123

query I rowsort
SELECT DISTINCT - col2 - col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT + - col0 * + col0 + col2 * + col2 FROM tab0 AS cor0
----
-1197
-1224
513

query I rowsort
SELECT DISTINCT col0 + - col0 FROM tab1
----
0

query I rowsort
SELECT - col2 + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 * - col1 NOT IN ( - col0 * col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - col2 * col1 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + tab2.col2 - col2 AS col0 FROM tab2
----
0

query I rowsort
SELECT tab0.col1 * col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + tab2.col2 * + col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL col0 * col0 AS col1 FROM tab1
----
4096
6400
9

query I rowsort
SELECT col1 * + col1 AS col1 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6127
SELECT + col0 DIV - col1 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-6127
SELECT + col0 / - col1 FROM tab1
----
-6
-6
0

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT col2 + tab1.col1 FROM tab1
----
109
67
80

query I rowsort
SELECT + col0 - + col2 * - col2 FROM tab0
----
1113
36
6813

query I rowsort
SELECT col1 * + col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT - col1 - + col2 AS col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT - col1 + col2 AS col2 FROM tab1
----
28
47
83

query I rowsort
SELECT col1 * col0 AS col2 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6135
SELECT 26 + cor0.col2 DIV - col1 AS col0 FROM tab0 AS cor0
----
26
26
26

skipif mysql # not compatible
query I rowsort label-6135
SELECT 26 + cor0.col2 / - col1 AS col0 FROM tab0 AS cor0
----
26
26
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6136
SELECT DISTINCT + + 4 DIV col0 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6136
SELECT DISTINCT + + 4 / col0 FROM tab1 cor0
----
0
1

query I rowsort
SELECT col1 + + col2 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT - cor0.col1 * + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 73 * - col2 FROM tab0 AS cor0
----
2409
5986
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6140
SELECT col1 DIV col1 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6140
SELECT col1 / col1 AS col0 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL tab1.col1 * + col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT col1 * - col1 AS col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT col0 * - col1 FROM tab2 WHERE NOT NULL NOT IN ( col2 / + col0 )
----

query I rowsort
SELECT DISTINCT + col2 - col2 FROM tab2
----
0

query I rowsort
SELECT DISTINCT tab2.col1 - + tab2.col1 * + col0 * col1 AS col1 FROM tab2
----
-22814
-271459
-6696

query I rowsort
SELECT + cor0.col1 + - cor0.col2 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5fc5fcec216468c99d1c0eaf371b3149

query I rowsort
SELECT cor0.col0 + + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL col1 - - col2 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - col1 + col2 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - col2 - + col2 FROM tab0 AS cor0
----
-164
-2
-66

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE ( NULL ) > ( col2 * - col2 * - cor0.col0 )
----

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT ( NULL ) IN ( + col2 + - col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( - col1 ) IN ( col1 )
----

query I rowsort
SELECT DISTINCT + col0 + - col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT col0 * col0 - col2 * - col2 AS col0 FROM tab1
----
15616
2925
7345

query I rowsort
SELECT col1 FROM tab1 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT col2 * + col1 - col0 * tab1.col0 FROM tab1
----
-3526
-5152
1395

query I rowsort
SELECT - cor0.col1 FROM tab2, tab2 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6159
SELECT DISTINCT + col1 DIV - col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6159
SELECT DISTINCT + col1 / - col0 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT tab2.col0 + tab2.col2 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT col1 * col0 + tab1.col0 * col1 * col0 + col0 AS col0 FROM tab1
----
315
41664
84320

query I rowsort
SELECT - col0 + col2 + + col2 * col1 AS col0 FROM tab0
----
2847
63
7455

query I rowsort
SELECT ALL + col1 * + col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col0 * - col0 AS col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + col2 * tab1.col2 * col1 AS col1 FROM tab1
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-6166
SELECT + col2 DIV + col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6166
SELECT + col2 / + col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 FROM tab2 WHERE NOT NULL >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6168
SELECT + tab1.col2 DIV col1 + + col0 + col2 FROM tab1
----
126
183
59

skipif mysql # not compatible
query I rowsort label-6168
SELECT + tab1.col2 / col1 + + col0 + col2 FROM tab1
----
126
183
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6169
SELECT DISTINCT - CAST( 56 AS SIGNED ) FROM tab0, tab1 AS cor0
----
-56

skipif mysql # not compatible
query I rowsort label-6169
SELECT DISTINCT - CAST ( 56 AS INTEGER ) FROM tab0, tab1 AS cor0
----
-56

query I rowsort
SELECT col0 + + 70 * col2 * - col2 FROM tab0
----
-35
-470591
-76206

query I rowsort
SELECT col2 - col0 FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 80 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT ALL tab1.col1 * - 97 + tab1.col1 FROM tab1
----
-1248
-2496
-960

query I rowsort
SELECT - tab2.col1 * col0 + tab2.col2 AS col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT + 67 + - col1 AS col1 FROM tab1
----
41
54
57

query I rowsort
SELECT - 26 + ( - col0 ) FROM tab0
----
-115
-50
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * col0 + + col1 * + 35 col0 FROM tab2 AS cor0
----
-2537
-748
868

query I rowsort
SELECT + ( - col2 ) + - cor0.col2 * - 16 FROM tab2 AS cor0
----
390
405
570

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 9046c86f4ecdb3416770671e3173d46c

query I rowsort
SELECT ALL cor0.col2 + + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL + col0 * - col1 + + cor0.col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT 27 * - col1 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1534
-442
-806

query I rowsort
SELECT col2 + cor0.col1 AS col1 FROM tab0 AS cor0
----
119
173
98

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT ALL + col0 + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col2 + 1 AS col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL + 68 FROM tab2 AS cor0
----
68
68
68

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab0 cor1
----
243 values hashing to 021da207cdc2a046fb0a79bf7cfc38ae

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 90 col0 FROM tab2
----
90

query I rowsort
SELECT - 26 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

query I rowsort
SELECT ALL 76 * col1 FROM tab0
----
6536
6916
7372

query I rowsort
SELECT 17 - + col2 FROM tab2
----
-10
-21
-9

query I rowsort
SELECT + ( - col1 ) + 99 FROM tab2 AS cor0
----
40
68
82

query I rowsort
SELECT + - col0 * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + col1 * + col1 + - col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT - col2 - 20 FROM tab1 AS cor0
----
-116
-74
-77

query I rowsort
SELECT DISTINCT + col0 * + 74 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT + col2 - col0 * + 62 AS col1 FROM tab2 AS cor0
----
-407
-4810
-4860

query I rowsort
SELECT ALL + + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col2 * - col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - col2 * - col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6202
SELECT col1 + - CAST( NULL AS SIGNED ) * 65 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6202
SELECT col1 + - CAST ( NULL AS INTEGER ) * 65 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * - col0 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6204
SELECT cor0.col0 - CAST( - col0 AS SIGNED ) * - col2 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif mysql # not compatible
query I rowsort label-6204
SELECT cor0.col0 - CAST ( - col0 AS INTEGER ) * - col2 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT 25 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT DISTINCT ( + col1 ) FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6209
SELECT col0 * + CAST( 98 AS SIGNED ) + col2 * 15 FROM tab2 cor0
----
1091
8034
8312

skipif mysql # not compatible
query I rowsort label-6209
SELECT col0 * + CAST ( 98 AS INTEGER ) + col2 * 15 FROM tab2 cor0
----
1091
8034
8312

query I rowsort
SELECT DISTINCT col2 * + 45 FROM tab1 AS cor0
----
2430
2565
4320

query I rowsort
SELECT ALL - col0 * - 46 AS col2 FROM tab2 AS cor0
----
322
3588
3634

query I rowsort
SELECT - col0 * col1 + col1 AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col0 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - + col0 * 12 FROM tab1 AS cor0
----
-36
-768
-960

query I rowsort
SELECT ALL + col2 * - col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - + col1 + + 94 + col2 AS col0 FROM tab0 AS cor0
----
-2
41
85

query I rowsort
SELECT ALL + + cor0.col1 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col0 + - col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - + col0 + cor0.col1 * col2 FROM tab2 AS cor0
----
1456
567
830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 47 col2 FROM tab0
----
1128
1645
4183

query I rowsort
SELECT DISTINCT + - 74 * col2 - col0 * col1 FROM tab1 AS cor0
----
-4074
-4858
-8144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col0 col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + 59 AS col0 FROM tab1
----
59

query I rowsort
SELECT - ( col1 ) + + 76 FROM tab2 AS cor0
----
17
45
59

query I rowsort
SELECT + col2 * - col1 + - col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT + 17 AS col1 FROM tab2 cor0
----
17
17
17

query I rowsort
SELECT DISTINCT + col0 + + col0 * col0 FROM tab0 cor0
----
1260
600
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6228
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab2, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6228
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab2, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6229
SELECT tab2.col0 + + CAST( + ( + col1 ) AS SIGNED ) * 14 + - col1 DIV + col1 AS col1 FROM tab2
----
316
440
903

skipif mysql # not compatible
query I rowsort label-6229
SELECT tab2.col0 + + CAST ( + ( + col1 ) AS INTEGER ) * 14 + - col1 / + col1 AS col1 FROM tab2
----
316
440
903

onlyif mysql # use DIV operator for integer division
query I rowsort label-6230
SELECT col1 DIV 97 + - 75 * tab0.col2 FROM tab0
----
-2475
-6150
-74

skipif mysql # not compatible
query I rowsort label-6230
SELECT col1 / 97 + - 75 * tab0.col2 FROM tab0
----
-2475
-6150
-74

query I rowsort
SELECT ALL + col2 * col1 + + col1 AS col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT DISTINCT col2 * + 57 AS col0 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT ALL + col0 + + col1 * cor0.col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT + cor0.col1 + col0 + col2 AS col0 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # use DIV operator for integer division
query I rowsort label-6235
SELECT + - col2 * 42 * col2 - - col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
-282407
-45736
55

skipif mysql # not compatible
query I rowsort label-6235
SELECT + - col2 * 42 * col2 - - col1 / + col2 AS col0 FROM tab0 AS cor0
----
-282407
-45736
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + cor0.col2 * 84 + cor0.col1 col2 FROM tab2 AS cor0
----
2302
2330
3226

query I rowsort
SELECT + col0 + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - col0 * + cor0.col1 + col0 + - col1 AS col1 FROM tab2 AS cor0
----
-1281
-241
-4583

query I rowsort
SELECT DISTINCT + - 90 + - cor0.col1 FROM tab0 AS cor0
----
-176
-181
-187

query I rowsort
SELECT + - ( - 76 ) + - col2 * cor0.col0 AS col0 FROM tab2 cor0
----
-113
-1952
-2926

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6241
SELECT ALL - + ( - 16 ) - + col2 * CAST( col2 * col2 AS SIGNED ) FROM tab1 cor0
----
-157448
-185177
-884720

skipif mysql # not compatible
query I rowsort label-6241
SELECT ALL - + ( - 16 ) - + col2 * CAST ( col2 * col2 AS INTEGER ) FROM tab1 cor0
----
-157448
-185177
-884720

query I rowsort
SELECT DISTINCT - 70 + 12 AS col2 FROM tab2 AS cor0
----
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6243
SELECT ALL + ( cor0.col2 ) + col2 * + col0 - col0 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
215
3704
7775

skipif mysql # not compatible
query I rowsort label-6243
SELECT ALL + ( cor0.col2 ) + col2 * + col0 - col0 / cor0.col0 AS col0 FROM tab1 AS cor0
----
215
3704
7775

query I rowsort
SELECT 38 AS col0 FROM tab1 AS cor0
----
38
38
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6245
SELECT ALL + CAST( NULL AS SIGNED ) + - col1 + + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6245
SELECT ALL + CAST ( NULL AS INTEGER ) + - col1 + + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - col2 + ( col0 ) * + col1 FROM tab2
----
1305
190
4576

query I rowsort
SELECT DISTINCT col2 + 12 * col2 FROM tab0
----
1066
13
429

query I rowsort
SELECT - col1 * 77 * col1 + col2 FROM tab0 AS cor0
----
-569459
-637555
-724492

query I rowsort
SELECT - 62 + - col0 + + col2 * col1 FROM tab2 AS cor0
----
1394
505
768

query I rowsort
SELECT ( col0 ) * col2 FROM tab2 AS cor0
----
189
2028
3002

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2, tab2 AS cor0, tab0 AS cor1
----
972 values hashing to deaaa983f771be544ffdc26f04a18657

query I rowsort
SELECT ALL + 19 + 90 AS col0 FROM tab2
----
109
109
109

query I rowsort
SELECT 84 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col1 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + 16 * + col2 + - col0 + + 6 * + 0 AS col1 FROM tab1 AS cor0
----
1456
848
861

query I rowsort
SELECT + ( + col0 ) + - cor0.col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6258
SELECT - - col0 + col0 DIV col0 AS col2 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-6258
SELECT - - col0 + col0 / col0 AS col2 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT DISTINCT 8 FROM tab2 AS cor0
----
8

query I rowsort
SELECT - - 40 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT ALL + - ( col0 ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - ( col0 ) * col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col1 * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col0 + - col1 * 86 FROM tab1 AS cor0
----
-1038
-2233
-796

query I rowsort
SELECT 44 * + col0 FROM tab0
----
1056
1540
3916

query I rowsort
SELECT 25 FROM tab2
----
25
25
25

query I rowsort
SELECT - cor0.col1 * + col0 + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT 66 + + col1 FROM tab1 AS cor0
----
76
79
92

query I rowsort
SELECT + col2 + col2 * + 89 AS col0 FROM tab2 AS cor0
----
2340
2430
3420

query I rowsort
SELECT col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL + col1 * + tab1.col2 AS col0 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6272
SELECT CAST( + 55 AS SIGNED ) * + tab2.col1 AS col1 FROM tab2
----
1705
3245
935

skipif mysql # not compatible
query I rowsort label-6272
SELECT CAST ( + 55 AS INTEGER ) * + tab2.col1 AS col1 FROM tab2
----
1705
3245
935

query I rowsort
SELECT DISTINCT cor1.col2 * 72 FROM tab1, tab1 AS cor0, tab0 cor1
----
2376
5904
72

query I rowsort
SELECT col2 * col0 + col0 * cor0.col1 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT - - col1 + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 - col1 * - col0 AS col0 FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col2 + col0 col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col1 * 50 - col1 FROM tab0 AS cor0
----
4214
4459
4753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6279
SELECT col1 / + CAST( NULL AS DECIMAL ) + - ( col0 ) + + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6279
SELECT col1 / + CAST ( NULL AS REAL ) + - ( col0 ) + + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6280
SELECT cor0.col2 / CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6280
SELECT cor0.col2 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - tab2.col0 ) col2 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT 55 FROM tab1, tab2, tab2 AS cor0
----
55

query I rowsort
SELECT col1 * - col2 - col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL - + col1 + + col2 * col2 FROM tab0 cor0
----
-96
1003
6633

query I rowsort
SELECT col1 * - 83 AS col1 FROM tab1 AS cor0
----
-1079
-2158
-830

query I rowsort
SELECT DISTINCT col0 * - col1 + ( col1 ) AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-6287
SELECT - col1 DIV cor0.col0 - col1 FROM tab0 cor0
----
-89
-92
-99

skipif mysql # not compatible
query I rowsort label-6287
SELECT - col1 / cor0.col0 - col1 FROM tab0 cor0
----
-89
-92
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 * col2 - col1 col0 FROM tab1
----
-233482
-512
-614413

query I rowsort
SELECT - tab2.col0 * col1 * tab2.col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ALL + ( col0 ) FROM tab2
----
7
78
79

query I rowsort
SELECT + col0 * tab0.col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - 45 FROM tab1
----
-45

query I rowsort
SELECT + 86 * col0 FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT ALL - 62 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 + 64 col1 FROM tab1, tab0 cor0
----
9 values hashing to bfb30617e19fcad46b160c3739ca5da3

query I rowsort
SELECT ALL + 74 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

query I rowsort
SELECT ALL col0 + + col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT + - col2 + 11 AS col0 FROM tab0 AS cor0
----
-22
-71
10

query I rowsort
SELECT ALL - + col1 + col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 * ( cor0.col1 ) - col2 * - col0 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT + col0 * + col2 + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - cor0.col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT col1 * - col2 * col1 AS col0 FROM tab0 AS cor0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6304
SELECT DISTINCT col1 DIV + ( + col1 ) + - col0 FROM tab0 cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-6304
SELECT DISTINCT col1 / + ( + col1 ) + - col0 FROM tab0 cor0
----
-23
-34
-88

query I rowsort
SELECT + col0 + + 48 FROM tab1 AS cor0
----
112
128
51

query I rowsort
SELECT ALL 2 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-6307
SELECT DISTINCT + col0 DIV col1 + col1 + col2 * + 17 AS col2 FROM tab1 AS cor0
----
1651
944
985

skipif mysql # not compatible
query I rowsort label-6307
SELECT DISTINCT + col0 / col1 + col1 + col2 * + 17 AS col2 FROM tab1 AS cor0
----
1651
944
985

query I rowsort
SELECT ALL - - cor0.col1 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col0 + 66 FROM tab0 AS cor0
----
-23
31
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + col2 col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * + col2 + - 83 * - col2 col2 FROM tab0 AS cor0
----
1650
82

query I rowsort
SELECT - + col2 * 49 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT - col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + - col0 + + 20 FROM tab1 AS cor0
----
-44
-60
17

query I rowsort
SELECT + - col1 * - cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - ( tab2.col0 ) - col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT col0 * - col0 * + col1 AS col2 FROM tab0 cor0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL - cor0.col2 + - col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT 46 AS col0 FROM tab2 AS cor0
----
46
46
46

query I rowsort
SELECT ALL col0 * + col0 * + col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT - + ( col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col0 col1 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT - 89 * + 59 AS col1 FROM tab2 AS cor0
----
-5251
-5251
-5251

query I rowsort
SELECT + col1 * 55 FROM tab2 AS cor0
----
1705
3245
935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + ( col0 * col0 ) col1 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT - 17 AS col2 FROM tab2 AS cor0
----
-17

query I rowsort
SELECT DISTINCT - 52 FROM tab2 AS cor0
----
-52

query I rowsort
SELECT - + col0 - - col0 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6330
SELECT + col2 * - col2 - - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-1113
-36
-6813

skipif mysql # not compatible
query I rowsort label-6330
SELECT + col2 * - col2 - - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT DISTINCT + + col1 * + col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + 8 * + col1 FROM tab2 cor0
----
-136
-248
-472

query I rowsort
SELECT ALL + col1 + col2 * - ( ( - cor0.col2 ) ) FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL + cor0.col2 - + col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6335
SELECT - col2 * + col2 - + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6335
SELECT - col2 * + col2 - + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 96 * cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
8280
8825
9347

query I rowsort
SELECT ALL - 89 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

query I rowsort
SELECT ALL - 1 AS col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT + + ( col1 ) + ( + col0 ) * col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT + + cor0.col0 + + col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6341
SELECT + 49 * - col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6341
SELECT + 49 * - col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col0 * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col0 * col0 * + 19 FROM tab1 AS cor0
----
121600
171
77824

query I rowsort
SELECT DISTINCT - col1 * col1 + + 3 * col1 AS col1 FROM tab0
----
-7138
-8008
-9118

query I rowsort
SELECT 42 * cor0.col0 * + col1 + cor0.col0 FROM tab1 AS cor0
----
26944
3279
43760

query I rowsort
SELECT DISTINCT - col0 * col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 col0 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT - 55 FROM tab2 cor0
----
-55
-55
-55

query I rowsort
SELECT ALL + col0 * col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL 4 * col0 FROM tab2 AS cor0
----
28
312
316

query I rowsort
SELECT ALL - 79 * cor0.col2 + - col1 FROM tab0 cor0
----
-176
-2693
-6569

query I rowsort
SELECT col0 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6354
SELECT CAST( NULL AS DECIMAL ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6354
SELECT CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + ( col1 ) FROM tab1
----
29
74
93

query I rowsort
SELECT ALL 88 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6357
SELECT ALL 46 DIV col1 col2 FROM tab1 AS cor0
----
1
3
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6357
SELECT ALL 46 / col1 col2 FROM tab1 AS cor0
----
1
3
4

query I rowsort
SELECT ALL - - 12 + + col1 FROM tab0 cor0
----
103
109
98

query I rowsort
SELECT - cor0.col2 + col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + 4 FROM tab1 AS cor0
----
4

query I rowsort
SELECT DISTINCT - col1 * col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - 85 FROM tab0 AS cor0
----
-85
-85
-85

query I rowsort
SELECT ALL 78 + + col1 * - col2 FROM tab1 AS cor0
----
-1170
-1326
-492

query I rowsort
SELECT DISTINCT - col0 * col0 * ( col2 ) - col2 AS col2 FROM tab0
----
-1226
-19041
-649604

query I rowsort
SELECT ALL + 43 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 199105619049271147956de52e7f5ed4

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab1 cor1
----
243 values hashing to 098e223d780e18b6582523fd6f55eec9

query I rowsort
SELECT DISTINCT + + 82 FROM tab1 AS cor0
----
82

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
17
31
59

query I rowsort
SELECT DISTINCT - - col2 * + 90 FROM tab1 AS cor0
----
4860
5130
8640

query I rowsort
SELECT DISTINCT - col1 + col2 * - cor0.col2 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT - + cor0.col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT col0 + + tab0.col1 AS col1 FROM tab0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 col0 FROM tab2, tab1, tab2 cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT - col1 - + col1 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT 73 AS col2 FROM tab2
----
73
73
73

query I rowsort
SELECT DISTINCT 48 FROM tab2
----
48

query I rowsort
SELECT ALL + + 5 FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT ALL + 94 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-2
37
40

query I rowsort
SELECT + cor0.col2 * + cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col1 * 58 + + col1 + col2 FROM tab0 AS cor0
----
5107
5451
5724

query I rowsort
SELECT - + col0 + - ( + cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL - ( + cor0.col2 ) * + 76 FROM tab0, tab1 AS cor0
----
9 values hashing to 7c7275be2a652135d8807f37aa5bda8f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6383
SELECT col2 + - col1 DIV 76 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6383
SELECT col2 + - col1 / 76 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6384
SELECT ALL - 8 DIV + col1 + - 39 FROM tab0
----
-39
-39
-39

skipif mysql # not compatible
query I rowsort label-6384
SELECT ALL - 8 / + col1 + - 39 FROM tab0
----
-39
-39
-39

query I rowsort
SELECT ALL - col1 + + col2 * col1 FROM tab2
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6386
SELECT col1 DIV col0 + - col0 FROM tab2
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-6386
SELECT col1 / col0 + - col0 FROM tab2
----
-3
-78
-79

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT cor0.col0 * 35 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 18baf8aa12bceafb74e273208d5c2d18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 col1 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6391
SELECT ALL + col0 DIV - col0 + + col0 AS col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6391
SELECT ALL + col0 / - col0 + + col0 AS col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT ALL + col1 + - 11 * - 38 AS col0 FROM tab2 AS cor0
----
435
449
477

onlyif mysql # use DIV operator for integer division
query I rowsort label-6393
SELECT ALL col0 DIV + 86 - + col0 col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6393
SELECT ALL col0 / + 86 - + col0 col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col1 + + 91 FROM tab2
----
108
122
150

query I rowsort
SELECT ALL ( + col0 ) - - col2 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - tab2.col1 * - col0 - col1 AS col0 FROM tab2
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-6397
SELECT col0 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6397
SELECT col0 / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 * - 57 AS col2 FROM tab0 AS cor0
----
1368
1995
5073

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 5342fb4caf4767cb98bd21989bad099f

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to 86dbd337f00ab84c613ad03d6fc06e28

query I rowsort
SELECT + tab1.col0 * - col0 + tab1.col1 * - 50 + - 20 * - col2 AS col2 FROM tab1
----
-229
-3456
-5130

query I rowsort
SELECT ALL + 90 FROM tab0, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT ALL - ( + 35 ) * col0 FROM tab0
----
-1225
-3115
-840

query I rowsort
SELECT ALL + + cor0.col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - cor0.col2 + col2 - 15 FROM tab0 AS cor0
----
-15

query I rowsort
SELECT - 96 + col2 FROM tab2 cor0
----
-58
-69
-70

query I rowsort
SELECT ALL + 11 + - cor0.col1 FROM tab1 cor0
----
-15
-2
1

query I rowsort
SELECT 5 + col1 FROM tab0 AS cor0
----
102
91
96

query I rowsort
SELECT 67 * col2 FROM tab0 AS cor0
----
2211
5494
67

query I rowsort
SELECT - col2 * + col2 + col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - 57 AS col0 FROM tab2 cor0
----
-57
-57
-57

query I rowsort
SELECT ALL col0 * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + 66 + col0 * 43 AS col1 FROM tab1 AS cor0
----
195
2818
3506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6414
SELECT ALL + cor0.col0 * col0 - CAST( NULL AS SIGNED ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6414
SELECT ALL + cor0.col0 * col0 - CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col1 * cor0.col2 + + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT col1 + - col2 * cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - col2 * + col0 + col2 * 26 - + col1 FROM tab2 AS cor0
----
-1411
-2031
482

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT + col0 * + col2 + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT 79 FROM tab1
----
79
79
79

query I rowsort
SELECT 78 * col1 AS col2 FROM tab2
----
1326
2418
4602

query I rowsort
SELECT 33 * + col0 FROM tab1
----
2112
2640
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-6423
SELECT ALL col1 DIV col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6423
SELECT ALL col1 / col1 FROM tab0
----
1
1
1

query I rowsort
SELECT 88 * col1 FROM tab1
----
1144
2288
880

query I rowsort
SELECT + ( + col2 ) FROM tab1
----
54
57
96

query I rowsort
SELECT 61 - 2 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT col0 * col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT col0 + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col0 + - col0 * ( - ( + col2 ) ) AS col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + cor0.col0 + - cor0.col1 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d924577a04b3a692cbbd2348e6f8e88f

query I rowsort
SELECT + + col2 * - 4 FROM tab2 cor0
----
-104
-108
-152

onlyif mysql # use DIV operator for integer division
query I rowsort label-6433
SELECT - col2 + + 32 DIV col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6433
SELECT - col2 + + 32 / col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT col1 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT 9 + col2 FROM tab2
----
35
36
47

query I rowsort
SELECT col1 + + col0 * - col0 + - col0 FROM tab1
----
-4150
-6467
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-6437
SELECT 65 DIV tab1.col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6437
SELECT 65 / tab1.col2 FROM tab1
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 98 col1 FROM tab2
----
98

query I rowsort
SELECT - cor0.col0 * col1 + + 19 * col2 AS col1 FROM tab2 AS cor0
----
-4108
-621
296

onlyif mysql # use DIV operator for integer division
query I rowsort label-6440
SELECT + col1 * ( 48 ) DIV - col2 + - 42 AS col2 FROM tab1 AS cor0
----
-48
-50
-65

skipif mysql # not compatible
query I rowsort label-6440
SELECT + col1 * ( 48 ) / - col2 + - 42 AS col2 FROM tab1 AS cor0
----
-48
-50
-65

query I rowsort
SELECT - col0 + ( - 23 ) FROM tab2 AS cor0
----
-101
-102
-30

query I rowsort
SELECT + ( 9 ) AS col1 FROM tab1 AS cor0
----
9
9
9

query I rowsort
SELECT DISTINCT 44 + col1 FROM tab2 AS cor0
----
103
61
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6444
SELECT + col2 * - col2 DIV + col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6444
SELECT + col2 * - col2 / + col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - 40 * col1 FROM tab1 AS cor0
----
-1040
-400
-520

query I rowsort
SELECT DISTINCT - col1 + ( cor0.col2 ) FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + 9 + col2 * col1 FROM tab1 AS cor0
----
1257
1413
579

query I rowsort
SELECT ALL 74 * col0 FROM tab0 AS cor0
----
1776
2590
6586

onlyif mysql # use DIV operator for integer division
query I rowsort label-6449
SELECT col2 DIV + 99 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6449
SELECT col2 / + 99 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 * 70 AS col1 FROM tab0 cor0
----
2310
5740
70

query I rowsort
SELECT + col0 + - col2 FROM tab0
----
-9
34
7

skipif mysql # not compatible
query I rowsort
SELECT col2 + - CAST ( - col0 AS REAL ) * col2 FROM tab1
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6453
SELECT - - CAST( NULL AS SIGNED ) * - 0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6453
SELECT - - CAST ( NULL AS INTEGER ) * - 0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
243 values hashing to 2ba47a833971d4c4b0287e849fb0cfb8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6455
SELECT DISTINCT CAST( 19 AS SIGNED ) * - col2 * - ( + col0 ) FROM tab0
----
138662
15048
665

skipif mysql # not compatible
query I rowsort label-6455
SELECT DISTINCT CAST ( 19 AS INTEGER ) * - col2 * - ( + col0 ) FROM tab0
----
138662
15048
665

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT col0 + + col1 * col1 AS col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT tab0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
3645 values hashing to bb6428239bf7f3ea361f6a10500a581d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6460
SELECT DISTINCT - col1 * - col2 DIV - col2 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6460
SELECT DISTINCT - col1 * - col2 / - col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - + col2 + - cor0.col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6462
SELECT col0 DIV + tab2.col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6462
SELECT col0 / + tab2.col1 FROM tab2
----
0
1
4

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0, tab1 AS cor0, tab1 AS cor1
----
972 values hashing to 0be13143d898cc667fe1a2dd93b34703

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6464
SELECT DISTINCT - - CAST( + col1 AS SIGNED ) + + col2 * + ( - cor0.col1 * - col1 ) AS col2 FROM tab0 AS cor0
----
244154
679133
9506

skipif mysql # not compatible
query I rowsort label-6464
SELECT DISTINCT - - CAST ( + col1 AS INTEGER ) + + col2 * + ( - cor0.col1 * - col1 ) AS col2 FROM tab0 AS cor0
----
244154
679133
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6465
SELECT DISTINCT col2 * + col1 + col0 DIV cor0.col0 FROM tab2 AS cor0
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-6465
SELECT DISTINCT col2 * + col1 + col0 / cor0.col0 FROM tab2 AS cor0
----
1535
647
838

query I rowsort
SELECT ALL - + cor0.col0 AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ( + col2 ) - col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL col1 + cor0.col1 * col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL - col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + - ( col0 ) FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6472
SELECT - col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6472
SELECT - col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - 46 - col1 * - tab2.col1 FROM tab2
----
243
3435
915

query I rowsort
SELECT ( col1 ) + - col1 AS col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 col0 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6476
SELECT - CAST( NULL AS DECIMAL ) - + 38 * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6476
SELECT - CAST ( NULL AS REAL ) - + 38 * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * + col0 * col0 + ( + 52 ) + - col1 FROM tab2 AS cor0
----
364
474545
493074

query I rowsort
SELECT DISTINCT - 93 * col0 FROM tab1 cor0
----
-279
-5952
-7440

query I rowsort
SELECT 92 * col2 FROM tab0 AS cor0
----
3036
7544
92

query I rowsort
SELECT - 60 * col0 - col2 FROM tab1 AS cor0
----
-234
-3897
-4896

onlyif mysql # use DIV operator for integer division
query I rowsort label-6481
SELECT - 44 * col1 - col1 DIV col0 AS col0 FROM tab2 cor0
----
-1368
-2596
-748

skipif mysql # not compatible
query I rowsort label-6481
SELECT - 44 * col1 - col1 / col0 AS col0 FROM tab2 cor0
----
-1368
-2596
-748

query I rowsort
SELECT + - 3 * - col1 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT DISTINCT col0 * 45 AS col0 FROM tab1 AS cor0
----
135
2880
3600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6484
SELECT ALL col2 DIV - col0 AS col2 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6484
SELECT ALL col2 / - col0 AS col2 FROM tab0 cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + 50 col0 FROM tab1 AS cor0
----
104
107
146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 col0 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6487
SELECT DISTINCT cor0.col1 DIV + ( cor0.col2 ) FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6487
SELECT DISTINCT cor0.col1 / + ( cor0.col2 ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col2 AS col0 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT + col2 * ( 4 ) AS col2 FROM tab2 AS cor0
----
104
108
152

onlyif mysql # use DIV operator for integer division
query I rowsort label-6490
SELECT cor0.col1 DIV + 74 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6490
SELECT cor0.col1 / + 74 AS col0 FROM tab1 AS cor0
----
0
0
0

query IIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 cor1
----
243 values hashing to 2464a6f4cfabe66aeca50fcb4cd85bf5

query I rowsort
SELECT + cor0.col2 * - ( + col1 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6493
SELECT DISTINCT col0 * CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6493
SELECT DISTINCT col0 * CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT - - cor0.col0 * ( col2 ) * + cor0.col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + cor0.col1 + - ( col0 ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - col0 * + col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * + 86 * - col2 col0 FROM tab1 cor0
----
-107328
-120744
-49020

query I rowsort
SELECT - col1 * + col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - + col1 + col0 AS col2 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6501
SELECT + - col1 DIV + cor0.col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6501
SELECT + - col1 / + cor0.col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT DISTINCT - + col2 * 33 AS col1 FROM tab2 AS cor0
----
-1254
-858
-891

query I rowsort
SELECT ALL + + cor0.col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT col0 * ( 73 ) AS col0 FROM tab2 AS cor0
----
511
5694
5767

onlyif mysql # use DIV operator for integer division
query I rowsort label-6505
SELECT ALL + - col0 DIV - cor0.col2 AS col0 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6505
SELECT ALL + - col0 / - cor0.col2 AS col0 FROM tab0 cor0
----
0
1
35

query I rowsort
SELECT cor1.col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 43 + - col2 * col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-119851
-32533
-75859

query I rowsort
SELECT DISTINCT - + 12 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-1032
-1092
-1164

query I rowsort
SELECT - col0 * 11 FROM tab2 AS cor0
----
-77
-858
-869

query I rowsort
SELECT ALL 26 * - col1 + col2 AS col1 FROM tab2 AS cor0
----
-1508
-404
-779

query I rowsort
SELECT DISTINCT - + col2 * col1 + + col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL - col2 + 23 AS col2 FROM tab0 AS cor0
----
-10
-59
22

query I rowsort
SELECT ALL col0 + ( + cor0.col0 ) + - col1 FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT ALL 77 * + 43 FROM tab2 AS cor0
----
3311
3311
3311

query I rowsort
SELECT + col0 + ( col2 * col1 ) FROM tab1
----
1328
1407
634

query I rowsort
SELECT - 8 * col1 * - col0 FROM tab1 AS cor0
----
5120
624
8320

query I rowsort
SELECT DISTINCT col2 * ( - col1 ) AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL 5 * + col1 + - ( 46 * - cor0.col0 ) + col1 * col2 AS col2 FROM tab1 AS cor0
----
1672
3564
4993

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6519
SELECT + cor0.col1 + - CAST( NULL AS SIGNED ) col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6519
SELECT + cor0.col1 + - CAST ( NULL AS INTEGER ) col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT 14 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

query I rowsort
SELECT ALL col0 + + cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + 43 + cor0.col0 AS col0 FROM tab1 AS cor0
----
107
123
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + col1 + + col2 col1 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT DISTINCT - col2 * col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col0 + col1 AS col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT DISTINCT 43 + col1 AS col0 FROM tab2 AS cor0
----
102
60
74

query I rowsort
SELECT DISTINCT + 83 * col1 * col1 FROM tab1 AS cor0
----
14027
56108
8300

query I rowsort
SELECT DISTINCT + + col1 FROM tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6530
SELECT ALL - col2 + col1 + CAST( + col1 AS SIGNED ) DIV col1 FROM tab0 AS cor0
----
10
54
97

skipif mysql # not compatible
query I rowsort label-6530
SELECT ALL - col2 + col1 + CAST ( + col1 AS INTEGER ) / col1 FROM tab0 AS cor0
----
10
54
97

query I rowsort
SELECT ALL 97 FROM tab1, tab1 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 - - col2 * col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT cor0.col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 82 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 * - col1 - col2 col0 FROM tab0
----
-7773
-8272
-8731

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + cor0.col0 col2 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6538
SELECT DISTINCT + col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6538
SELECT DISTINCT + col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6539
SELECT ALL 4 DIV col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6539
SELECT ALL 4 / col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col0 * tab1.col2 + col1 AS col2 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT + col2 + + col0 + col2 * - col0 FROM tab0
----
-7127
-735
1

query I rowsort
SELECT 99 * col2 AS col0 FROM tab1
----
5346
5643
9504

query I rowsort
SELECT ALL col0 + + col2 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col0 col2 FROM tab1, tab2 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 82 + col1 AS col1 FROM tab0
----
168
173
179

query I rowsort
SELECT ALL + col2 + col2 AS col0 FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT 11 + - col1 AS col2 FROM tab2
----
-20
-48
-6

query I rowsort
SELECT + 85 * col1 FROM tab0
----
7310
7735
8245

query I rowsort
SELECT + 22 + col0 FROM tab2 AS cor0
----
100
101
29

query I rowsort
SELECT DISTINCT 11 AS col0 FROM tab0 AS cor0
----
11

query I rowsort
SELECT DISTINCT - - 49 + - cor0.col1 * col1 FROM tab2 AS cor0
----
-240
-3432
-912

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6552
SELECT + cor0.col1 - + cor0.col2 * + CAST( col0 * + col2 + col0 AS SIGNED ) AS col2 FROM tab1 cor0
----
-211574
-744947
-8884

skipif mysql # not compatible
query I rowsort label-6552
SELECT + cor0.col1 - + cor0.col2 * + CAST ( col0 * + col2 + col0 AS INTEGER ) AS col2 FROM tab1 cor0
----
-211574
-744947
-8884

query I rowsort
SELECT + col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT col1 * col0 + col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + col1 * cor0.col2 + ( col2 ) FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-6556
SELECT - col1 DIV col1 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6556
SELECT - col1 / col1 FROM tab0 cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6557
SELECT + col1 * cor0.col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6557
SELECT + col1 * cor0.col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - col2 FROM tab2 AS cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6559
SELECT - col1 + col2 DIV 59 col1 FROM tab0 cor0
----
-86
-90
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6559
SELECT - col1 + col2 / 59 col1 FROM tab0 cor0
----
-86
-90
-97

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab0 cor1, tab1, tab2 AS cor2
----
3645 values hashing to 47906197307eee6829150d762058792a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6562
SELECT - cor0.col0 DIV - col1 + + cor0.col1 * col1 FROM tab1 cor0
----
106
175
676

skipif mysql # not compatible
query I rowsort label-6562
SELECT - cor0.col0 / - col1 + + cor0.col1 * col1 FROM tab1 cor0
----
106
175
676

query I rowsort
SELECT - col0 * + 48 + col1 AS col0 FROM tab0 AS cor0
----
-1066
-1583
-4181

query I rowsort
SELECT ALL col0 * col0 AS col2 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL + 71 AS col0 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT ALL + + ( + 42 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # use DIV operator for integer division
query I rowsort label-6567
SELECT ALL col1 + col0 DIV ( + col1 ) AS col1 FROM tab2
----
21
31
60

skipif mysql # not compatible
query I rowsort label-6567
SELECT ALL col1 + col0 / ( + col1 ) AS col1 FROM tab2
----
21
31
60

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * + 14 col1 FROM tab1 AS cor0
----
1120
42
896

query I rowsort
SELECT + 88 + + col0 AS col2 FROM tab2 AS cor0
----
166
167
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6571
SELECT ALL col2 DIV 66 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6571
SELECT ALL col2 / 66 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT col0 * col1 AS col0 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 56 * col0 col0 FROM tab1 AS cor0
----
168
3584
4480

query I rowsort
SELECT DISTINCT + + 34 FROM tab2 AS cor0
----
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6575
SELECT CAST( cor0.col1 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6575
SELECT CAST ( cor0.col1 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 + ( 43 ) col2 FROM tab0 AS cor0
----
7439
8324
9452

query I rowsort
SELECT col1 * col0 + col2 + 8 FROM tab0
----
2105
3404
8189

onlyif mysql # use DIV operator for integer division
query I rowsort label-6578
SELECT - col2 DIV + col0 AS col1 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6578
SELECT - col2 / + col0 AS col1 FROM tab0
----
-1
0
0

query I rowsort
SELECT + 79 AS col1 FROM tab1
----
79
79
79

query I rowsort
SELECT col2 + + col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col2 + cor0.col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - 7 * - col2 AS col0 FROM tab1
----
378
399
672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + col0 col2 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT 84 FROM tab1 AS cor0
----
84
84
84

query I rowsort
SELECT DISTINCT + + ( - col1 ) * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6586
SELECT - col0 DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6586
SELECT - col0 / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab0, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT tab2.col1 + col1 AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT + col2 - col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT tab2.col1 * col1 + 13 * col0 * tab2.col0 AS col1 FROM tab2
----
1598
81422
82573

onlyif mysql # use DIV operator for integer division
query I rowsort label-6591
SELECT DISTINCT col2 DIV + col1 AS col0 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-6591
SELECT DISTINCT col2 / + col1 AS col0 FROM tab2
----
0
2

query I rowsort
SELECT - ( + col2 ) * col1 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT - col0 * + col2 * - col2 FROM tab2
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-6594
SELECT + col2 DIV col0 AS col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6594
SELECT + col2 / col0 AS col1 FROM tab0
----
0
0
1

query I rowsort
SELECT - - col0 + col0 AS col1 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL tab0.col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif mysql # not compatible
query I rowsort
SELECT col2 * + CAST ( col2 AS REAL ) FROM tab0
----
1
1089
6724

query I rowsort
SELECT col2 * 29 * - 20 FROM tab0
----
-19140
-47560
-580

query I rowsort
SELECT ALL col0 * - col1 + + col2 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - col0 * 97 AS col2 FROM tab1 AS cor0
----
-291
-6208
-7760

query I rowsort
SELECT + col2 + cor0.col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT col1 + col0 FROM tab1 AS cor0 WHERE cor0.col0 BETWEEN NULL AND NULL
----

query I rowsort
SELECT col0 + - tab0.col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 * col2 * + col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT + col2 * cor0.col2 AS col1 FROM tab1 cor0
----
2916
3249
9216

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) > col1 - + col2
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL >= col0 * col2 - + col1
----

query I rowsort
SELECT ALL + col1 AS col2 FROM tab1 WHERE NOT NULL BETWEEN col2 AND - col2
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL = col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6610
SELECT col2 DIV col0 col2 FROM tab2
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6610
SELECT col2 / col0 col2 FROM tab2
----
0
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6611
SELECT + col0 + col1 + col1 DIV col2 FROM tab1
----
29
74
93

skipif mysql # not compatible
query I rowsort label-6611
SELECT + col0 + col1 + col1 / col2 FROM tab1
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 + col1 * col2 col0 FROM tab2
----
1619
701
895

query I rowsort
SELECT DISTINCT col0 - - col2 FROM tab0
----
171
36
57

query I rowsort
SELECT + col1 + col2 + - col2 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT + col0 * col2 + col1 AS col2 FROM tab1 AS cor0
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 * + col1 col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL cor0.col1 * - cor0.col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT col1 + - col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + + col1 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col0 + col0 * col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT cor0.col1 + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - col2 + col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + col1 * + col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 * col1 FROM tab1 AS cor0
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * col0 + + col0 * col1 * col2 col0 FROM tab2 AS cor0
----
115050
49691
5642

query I rowsort
SELECT + col0 * + col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - tab2.col2 - col2 AS col1 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT ALL col0 + col2 + col2 * + col0 FROM tab2
----
2132
223
3119

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col2 col2 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6631
SELECT - - col0 DIV col1 + + col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6631
SELECT - - col0 / col1 + + col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + - cor0.col2 + - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL col0 + tab2.col1 + col2 FROM tab2
----
134
163
65

query I rowsort
SELECT + 0 * - tab1.col1 - - col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + col1 + col0 * col0 AS col0 FROM tab0
----
1322
662
8012

query I rowsort
SELECT + 15 FROM tab0
----
15
15
15

query I rowsort
SELECT + col1 * + col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT ALL - col1 * + col2 + + col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT + 43 * col1 + - col2 * + col0 FROM tab1
----
-3218
-7121
956

query I rowsort
SELECT 61 FROM tab0
----
61
61
61

query I rowsort
SELECT + 12 * + tab0.col0 + col2 AS col1 FROM tab0
----
1150
321
421

query I rowsort
SELECT 15 + col1 * tab0.col1 FROM tab0
----
7411
8296
9424

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab0, tab2 cor1
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT + col1 * ( 83 ) AS col1 FROM tab0
----
7138
7553
8051

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6645
SELECT DISTINCT + col2 + + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6645
SELECT DISTINCT + col2 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6646
SELECT ALL - col1 * - CAST( NULL AS SIGNED ) * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6646
SELECT ALL - col1 * - CAST ( NULL AS INTEGER ) * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6647
SELECT DISTINCT col0 DIV tab2.col0 AS col0 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-6647
SELECT DISTINCT col0 / tab2.col0 AS col0 FROM tab2
----
1

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 9600bdf5bac0caec3229e87170cc40b3

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col0 * - 21 FROM tab1 cor0
----
1344
1680
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-6651
SELECT + - col0 * - ( + cor0.col1 ) + col2 DIV ( - 5 * - col2 ) AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6651
SELECT + - col0 * - ( + cor0.col1 ) + col2 / ( - 5 * - col2 ) AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col1 - ( col1 + - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col2 * ( 58 ) + - col0 + col1 * 65 AS col2 FROM tab1 AS cor0
----
3892
4819
6333

query I rowsort
SELECT ALL - + col0 + col0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 + + 78 * + ( - col2 + ( - 9 ) ) FROM tab0 AS cor0
----
-3309
-7180
-781

query I rowsort
SELECT DISTINCT + - col1 * col1 + col0 AS col0 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6657
SELECT ALL - col0 * col1 - + 44 DIV col1 AS col2 FROM tab1 AS cor0
----
-1043
-644
-79

skipif mysql # not compatible
query I rowsort label-6657
SELECT ALL - col0 * col1 - + 44 / col1 AS col2 FROM tab1 AS cor0
----
-1043
-644
-79

query I rowsort
SELECT DISTINCT col2 * col1 + tab0.col2 + col1 AS col1 FROM tab0
----
195
2957
7635

onlyif mysql # use DIV operator for integer division
query I rowsort label-6659
SELECT col1 * col0 DIV tab0.col0 + col1 AS col1 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-6659
SELECT col1 * col0 / tab0.col0 + col1 AS col1 FROM tab0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 * + col0 col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT tab0.col1 * - col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL col1 * tab1.col1 FROM tab1
----
100
169
676

query I rowsort
SELECT col2 * + col1 * col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT ALL col1 * - col0 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - col0 + - col1 AS col2 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ALL - col0 * col2 * - tab0.col0 FROM tab0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - + col1 col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT col1 - + tab2.col1 * tab2.col1 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT ALL + tab1.col1 AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT col0 * + col0 * - col0 AS col2 FROM tab2
----
-343
-474552
-493039

query I rowsort
SELECT DISTINCT col1 + col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT col0 * - col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col0 * + col2 FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col2 * + col2 * - col0 col0 FROM tab0 AS cor0
----
-26112
-598347
0

query I rowsort
SELECT - 56 + cor0.col2 AS col1 FROM tab1 AS cor0
----
-2
1
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6676
SELECT DISTINCT + + col0 * cor0.col1 - + CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-6676
SELECT DISTINCT + + col0 * cor0.col1 - + CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT - + col2 + - col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + 5 * - col0 - col0 FROM tab1 AS cor0
----
-18
-384
-480

query I rowsort
SELECT ALL + + 62 + col1 * - ( col2 * col1 ) FROM tab0 AS cor0
----
-244006
-678980
-9347

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL col2 + + col1 * col1 AS col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL - 63 + + col2 AS col0 FROM tab2 AS cor0
----
-25
-36
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 - + ( col0 ) col2 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL + + cor0.col0 * cor0.col2 + + 15 FROM tab0 cor0
----
50
7313
807

onlyif mysql # use DIV operator for integer division
query I rowsort label-6685
SELECT col2 * col0 + - col1 DIV col2 FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-6685
SELECT col2 * col0 + - col1 / col2 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6686
SELECT DISTINCT - tab0.col1 DIV + col2 AS col1 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-6686
SELECT DISTINCT - tab0.col1 / + col2 AS col1 FROM tab0
----
-1
-2
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6687
SELECT col1 + + col0 DIV col1 + - col2 FROM tab0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-6687
SELECT col1 + + col0 / col1 + - col2 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL col1 + col0 FROM tab1 WHERE NOT ( NULL ) NOT IN ( - tab1.col1 + col1 * - col1 )
----

query I rowsort
SELECT DISTINCT col1 * col2 + col0 + + tab1.col1 FROM tab1
----
1341
1433
644

query I rowsort
SELECT + col2 FROM tab2 WHERE NULL IN ( - col1 )
----

query I rowsort
SELECT DISTINCT col1 * - col0 + col1 - - tab0.col0 FROM tab0
----
-1954
-3263
-7919

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - tab0.col1 col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col1 * + col2 + + col1 AS col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT - 86 + col0 FROM tab1 AS cor0
----
-22
-6
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6695
SELECT DISTINCT + col2 DIV col2 - - col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6695
SELECT DISTINCT + col2 / col2 - - col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT - 97 * col0 FROM tab0 cor0
----
-2328
-3395
-8633

query I rowsort
SELECT ALL - 98 + + col0 * + col1 FROM tab1 AS cor0
----
-20
542
942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 88 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT 93 * 81 FROM tab2, tab1 AS cor0
----
9 values hashing to 76c60c788d67e30a268b3ec1ab4f5bf7

query I rowsort
SELECT 4 FROM tab1, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT ALL + + 68 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6702
SELECT ALL + col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6702
SELECT ALL + col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6703
SELECT + col2 DIV + col0 AS col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6703
SELECT + col2 / + col0 AS col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - cor0.col2 * + 88 FROM tab0 AS cor0
----
-2904
-7216
-88

query I rowsort
SELECT + col1 + + 45 * - col1 FROM tab0 AS cor0
----
-3784
-4004
-4268

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 FROM tab2 cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6707
SELECT + col0 + - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6707
SELECT + col0 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + + cor0.col1 col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + + ( col1 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - + col0 * + col0 + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT - - col1 + - 43 AS col0 FROM tab0 AS cor0
----
43
48
54

query I rowsort
SELECT ALL col0 + col0 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT 96 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT - col2 + col2 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - 45 * + col0 AS col1 FROM tab0 AS cor0
----
-1080
-1575
-4005

onlyif mysql # use DIV operator for integer division
query I rowsort label-6716
SELECT DISTINCT - col0 DIV col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6716
SELECT DISTINCT - col0 / col2 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL + 4 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT + 90 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT - ( 17 ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 28cd5b4c959cb41fbc56389ab43d167e

query I rowsort
SELECT - + col2 + - col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT col2 + + cor0.col1 * 70 AS col2 FROM tab2 AS cor0
----
1228
2197
4156

query I rowsort
SELECT - 98 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab1 cor1, tab1 AS cor2
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

onlyif mysql # use DIV operator for integer division
query I rowsort label-6724
SELECT col2 * cor0.col1 DIV - 27 AS col2 FROM tab0 AS cor0
----
-105
-276
-3

skipif mysql # not compatible
query I rowsort label-6724
SELECT col2 * cor0.col1 / - 27 AS col2 FROM tab0 AS cor0
----
-105
-276
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6725
SELECT ALL col0 * + col0 * CAST( NULL AS SIGNED ) + + ( col0 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6725
SELECT ALL col0 * + col0 * CAST ( NULL AS INTEGER ) + + ( col0 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col0 * col1 + cor0.col1 + + 7 * col2 AS col2 FROM tab1 AS cor0
----
1049
1725
482

onlyif mysql # use DIV operator for integer division
query I rowsort label-6728
SELECT - 42 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6728
SELECT - 42 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col1 AS col1 FROM tab2, tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT col1 + - cor0.col0 * col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT + col0 + col1 FROM tab2
----
137
38
96

query I rowsort
SELECT col2 + col1 * + 25 FROM tab2 AS cor0
----
1501
463
802

query I rowsort
SELECT DISTINCT + col0 * + col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT - 5 AS col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
-5

query I rowsort
SELECT ALL tab1.col0 + 20 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 15131b2f8a8fbb3498fea021d1cfc917

query I rowsort
SELECT 44 + + col0 AS col0 FROM tab2
----
122
123
51

query I rowsort
SELECT col2 * + cor0.col2 FROM tab2 AS cor0
----
1444
676
729

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 35707ade138fec4b370f5140a4cd2963

query I rowsort
SELECT col2 * 66 * 84 AS col1 FROM tab2 AS cor0
----
144144
149688
210672

query I rowsort
SELECT - col1 * 44 + col1 AS col0 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT - cor0.col0 * - col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - col1 * - 28 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT 89 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6745
SELECT ALL tab1.col1 * CAST( - col2 AS SIGNED ) FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-6745
SELECT ALL tab1.col1 * CAST ( - col2 AS INTEGER ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - + ( 44 ) FROM tab2 AS cor0
----
-44

query I rowsort
SELECT ALL - - col1 + 87 * + col0 FROM tab2 AS cor0
----
640
6845
6890

query I rowsort
SELECT 78 * 21 FROM tab1 AS cor0
----
1638
1638
1638

query I rowsort
SELECT cor0.col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-6750
SELECT ALL col1 DIV col2 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6750
SELECT ALL col1 / col2 AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6751
SELECT DISTINCT - col0 DIV - col0 AS col2 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-6751
SELECT DISTINCT - col0 / - col0 AS col2 FROM tab2
----
1

query I rowsort
SELECT + 74 FROM tab0
----
74
74
74

query I rowsort
SELECT ALL ( col1 ) + - tab0.col0 AS col0 FROM tab0
----
2
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6754
SELECT CAST( col1 AS SIGNED ) * + col1 AS col0 FROM tab0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-6754
SELECT CAST ( col1 AS INTEGER ) * + col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + - 40 + cor0.col0 FROM tab2 AS cor0
----
-33
38
39

query I rowsort
SELECT col1 * tab0.col2 AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + ( + col0 ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + 86 AS col2 FROM tab2
----
86
86
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6760
SELECT col2 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6760
SELECT col2 / - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 * + col2 AS col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 * col0 ) col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL 12 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT - col0 * col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col2 * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col0 * + col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT + 14 AS col0 FROM tab0 AS cor0
----
14
14
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-6768
SELECT 92 + + cor0.col2 DIV + ( + col0 + cor0.col0 * - ( - col0 ) ) AS col0 FROM tab1 AS cor0
----
92
92
96

skipif mysql # not compatible
query I rowsort label-6768
SELECT 92 + + cor0.col2 / + ( + col0 + cor0.col0 * - ( - col0 ) ) AS col0 FROM tab1 AS cor0
----
92
92
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6769
SELECT 64 DIV col2 AS col0 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6769
SELECT 64 / col2 AS col0 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT 75 + col2 AS col1 FROM tab1 AS cor0
----
129
132
171

query I rowsort
SELECT - 34 FROM tab0 AS cor0
----
-34
-34
-34

query I rowsort
SELECT + col0 + col0 FROM tab0
----
178
48
70

query I rowsort
SELECT + ( + col2 ) * col1 AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col0 * - col1 + + col2 AS col1 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL - + col2 AS col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT + col2 * + cor0.col0 + + col0 + col2 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT ALL - - col0 * 69 AS col0 FROM tab0 AS cor0
----
1656
2415
6141

query I rowsort
SELECT ALL - 13 FROM tab1 AS cor0
----
-13
-13
-13

query I rowsort
SELECT DISTINCT + ( col0 ) - + col0 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL - - col0 * - 21 FROM tab0 AS cor0
----
-1869
-504
-735

query I rowsort
SELECT - col2 + col1 + - col0 * col1 FROM tab2 AS cor0
----
-1364
-213
-4569

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab1 AS cor1, tab0 cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

onlyif mysql # use DIV operator for integer division
query I rowsort label-6783
SELECT ALL - 80 DIV + cor0.col2 + col2 * - 44 col2 FROM tab1 AS cor0
----
-2377
-2509
-4224

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6783
SELECT ALL - 80 / + cor0.col2 + col2 * - 44 col2 FROM tab1 AS cor0
----
-2377
-2509
-4224

query I rowsort
SELECT - col2 * col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT - - 94 + - col2 FROM tab0 AS cor0
----
12
61
93

query I rowsort
SELECT ALL - + col1 * col1 - - ( ( cor0.col1 ) ) FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT 19 * - col1 FROM tab0 AS cor0
----
-1634
-1729
-1843

query I rowsort
SELECT + 5 * col0 AS col0 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - col1 + col2 * 72 * 55 AS col1 FROM tab1 AS cor0
----
213814
225710
380147

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - - 48 AS col1 FROM tab2 AS cor0
----
48
48
48

query I rowsort
SELECT ALL + 59 * - col1 FROM tab0 AS cor0
----
-5074
-5369
-5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + + col2 col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL 48 + cor0.col2 * col2 FROM tab1 AS cor0
----
2964
3297
9264

query I rowsort
SELECT DISTINCT - + col2 * col1 + - col0 * + 91 FROM tab1 AS cor0
----
-1677
-6394
-8528

query I rowsort
SELECT 91 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT ALL col2 * cor0.col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - 24 + col2 FROM tab2 AS cor0
----
14
2
3

query I rowsort
SELECT DISTINCT + 25 AS col2 FROM tab0 AS cor0
----
25

query I rowsort
SELECT DISTINCT + col2 * col2 + 37 FROM tab0 AS cor0
----
1126
38
6761

query I rowsort
SELECT ALL - + 84 - - col0 * col0 FROM tab0 cor0
----
1141
492
7837

query I rowsort
SELECT ALL tab2.col1 * 46 FROM tab2
----
1426
2714
782

onlyif mysql # use DIV operator for integer division
query I rowsort label-6804
SELECT ALL 20 * col1 DIV tab0.col0 FROM tab0
----
20
55
71

skipif mysql # not compatible
query I rowsort label-6804
SELECT ALL 20 * col1 / tab0.col0 FROM tab0
----
20
55
71

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6806
SELECT + col1 DIV - col1 + col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-6806
SELECT + col1 / - col1 + col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT ALL + + 31 + + col0 AS col0 FROM tab1 AS cor0
----
111
34
95

query I rowsort
SELECT - + cor0.col2 + 71 FROM tab2 AS cor0
----
33
44
45

query I rowsort
SELECT col1 * + 46 + - col2 + col2 AS col0 FROM tab2 AS cor0
----
1426
2714
782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + + cor0.col1 * + cor0.col0 * + cor0.col2 + col0 FROM tab1 AS cor0
----
36544
4215
99920

query I rowsort
SELECT DISTINCT col1 * + 49 AS col2 FROM tab1 AS cor0
----
1274
490
637

query I rowsort
SELECT + - col2 * 2 + col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + col1 + + col1 + col0 * col1 * 63 AS col0 FROM tab2 AS cor0
----
13733
290044
84643

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6815
SELECT + col0 * - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6815
SELECT + col0 * - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6816
SELECT - + col0 + CAST( NULL AS SIGNED ) + + col0 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6816
SELECT - + col0 + CAST ( NULL AS INTEGER ) + + col0 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6817
SELECT - 44 DIV col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6817
SELECT - 44 / col2 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6818
SELECT - col2 * CAST( NULL AS DECIMAL ) * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6818
SELECT - col2 * CAST ( NULL AS REAL ) * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 - - 56 FROM tab2 AS cor0
----
-3
25
39

query I rowsort
SELECT DISTINCT + col1 * col0 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - col1 * col0 + - 39 FROM tab2 AS cor0
----
-1382
-256
-4641

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + col0 col2 FROM tab1 cor0
----
29
74
93

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab0, tab1 AS cor1
----
972 values hashing to 9af67d6f98010464af5d560bf949d487

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab1, tab1 cor1
----
972 values hashing to fe55095fff3a5ecc2f113d14a8c6f823

query I rowsort
SELECT ALL + ( 85 ) AS col0 FROM tab0 AS cor0
----
85
85
85

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col0 col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT col0 * col2 * - col2 + col2 FROM tab0
----
-26103
-34
-598354

query I rowsort
SELECT col0 + + col0 + - col0 * + cor0.col1 FROM tab1 AS cor0
----
-512
-72
-880

query I rowsort
SELECT ALL - col2 + col2 * - col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT + 8 * cor0.col2 + + cor0.col2 + - col1 FROM tab0 AS cor0
----
-88
211
647

onlyif mysql # use DIV operator for integer division
query I rowsort label-6832
SELECT ALL + col1 + - col1 DIV - cor0.col1 + - col1 * col1 FROM tab0 AS cor0
----
-7309
-8189
-9311

skipif mysql # not compatible
query I rowsort label-6832
SELECT ALL + col1 + - col1 / - cor0.col1 + - col1 * col1 FROM tab0 AS cor0
----
-7309
-8189
-9311

query I rowsort
SELECT DISTINCT col2 * col2 * col0 AS col1 FROM tab0 cor0
----
26136
35
598436

query I rowsort
SELECT col0 * col1 + cor0.col1 * 59 FROM tab0 AS cor0
----
13468
7138
9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-6835
SELECT - ( + 87 ) + + col1 DIV 91 - col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
1447
559
750

skipif mysql # not compatible
query I rowsort label-6835
SELECT - ( + 87 ) + + col1 / 91 - col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
1447
559
750

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 * col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-6837
SELECT DISTINCT col1 DIV 50 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6837
SELECT DISTINCT col1 / 50 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + ( + ( col0 ) ) FROM tab0 cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6839
SELECT ALL CAST( NULL AS SIGNED ) * 90 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6839
SELECT ALL CAST ( NULL AS INTEGER ) * 90 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 93 + cor0.col0 * col1 * col0 + + col1 * - col0 col1 FROM tab2 AS cor0
----
104661
1209
354261

query I rowsort
SELECT DISTINCT - cor0.col1 AS col0 FROM tab1 cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + 27 col2 FROM tab1
----
107
30
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-6843
SELECT ALL col1 * col1 DIV col1 - tab0.col0 FROM tab0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-6843
SELECT ALL col1 * col1 / col1 - tab0.col0 FROM tab0
----
2
62
62

query I rowsort
SELECT ALL col1 + + 12 * - 87 FROM tab0
----
-947
-953
-958

query I rowsort
SELECT DISTINCT + col1 - + ( + tab0.col2 ) AS col1 FROM tab0
----
53
9
96

query I rowsort
SELECT + col1 + + col2 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL tab1.col0 - - ( col1 ) FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT - col0 * + col2 - + col2 * - col0 FROM tab2
----
0

query I rowsort
SELECT - 82 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT DISTINCT - 75 AS col0 FROM tab1 AS cor0
----
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6851
SELECT cor0.col2 DIV cor0.col0 + col1 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-6851
SELECT cor0.col2 / cor0.col0 + col1 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT DISTINCT + col0 + ( col0 ) FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + - col2 + 76 FROM tab1 AS cor0
----
-20
19
22

query I rowsort
SELECT DISTINCT ( - col1 ) * - col1 + - ( 41 ) * col1 AS col2 FROM tab0 AS cor0
----
3870
4550
5432

query I rowsort
SELECT ALL ( col2 ) + + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT 85 * col0 AS col2 FROM tab1 AS cor0
----
255
5440
6800

query IIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0 CROSS JOIN tab1 AS cor1
----
243 values hashing to 4fe4780e49e612b93957f575d9b3e89f

query I rowsort
SELECT ALL + 21 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT + + 74 * + cor0.col0 * - col1 + + col2 FROM tab1 AS cor0
----
-47303
-5718
-76864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6860
SELECT ALL col1 * - col0 * + cor0.col1 + CAST( + cor0.col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-177471
-329314
-736927

skipif mysql # not compatible
query I rowsort label-6860
SELECT ALL col1 * - col0 * + cor0.col1 + CAST ( + cor0.col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-177471
-329314
-736927

query I rowsort
SELECT DISTINCT + col0 + 20 AS col2 FROM tab0 cor0
----
109
44
55

query I rowsort
SELECT + 37 * col1 + 17 * 31 * + col0 AS col1 FROM tab1
----
2543
34098
42641

query I rowsort
SELECT ALL tab1.col1 + ( col2 + col0 ) * 11 FROM tab1
----
1341
1949
653

query I rowsort
SELECT - + col0 + - col0 AS col0 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT ALL - - cor0.col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - - cor0.col1 AS col2 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6867
SELECT + - col2 DIV + 37 + - col1 AS col0 FROM tab0 AS cor0
----
-86
-93
-97

skipif mysql # not compatible
query I rowsort label-6867
SELECT + - col2 / + 37 + - col1 AS col0 FROM tab0 AS cor0
----
-86
-93
-97

query I rowsort
SELECT ALL col1 + + 31 AS col1 FROM tab0 AS cor0
----
117
122
128

onlyif mysql # use DIV operator for integer division
query I rowsort label-6869
SELECT ALL col0 DIV tab1.col2 + 44 + col0 FROM tab1
----
109
124
47

skipif mysql # not compatible
query I rowsort label-6869
SELECT ALL col0 / tab1.col2 + 44 + col0 FROM tab1
----
109
124
47

query I rowsort
SELECT + - col2 * col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + + cor0.col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + - col0 + col2 + + 96 FROM tab0 AS cor0
----
105
62
89

query I rowsort
SELECT DISTINCT col1 + + ( col2 * col0 ) AS col1 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-6874
SELECT ALL + col1 DIV 97 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6874
SELECT ALL + col1 / 97 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * 61 + col1 FROM tab1 AS cor0
----
-3268
-3467
-5843

query I rowsort
SELECT DISTINCT col0 * cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT ALL - - col0 + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - col1 + ( col1 * + col1 ) FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT + 39 * col0 AS col0 FROM tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT - - col1 + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT 63 * - col1 AS col0 FROM tab1 AS cor0
----
-1638
-630
-819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 * col1 col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT 37 AS col1 FROM tab0
----
37
37
37

query I rowsort
SELECT col1 * - tab1.col2 + - col0 AS col1 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT - 27 FROM tab0
----
-27

query I rowsort
SELECT - ( + 62 * - col0 ) + col2 AS col1 FROM tab2
----
461
4862
4936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col1 * col1 col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT - 2 + cor0.col2 FROM tab2 AS cor0
----
24
25
36

query I rowsort
SELECT - 84 + cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
105
1944
2918

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 cor1
----
243 values hashing to ce53c0e8839c969b0513568da6eb2c4b

query I rowsort
SELECT 93 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6892
SELECT DISTINCT + col0 * CAST( NULL AS SIGNED ) + + 0 - + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6892
SELECT DISTINCT + col0 * CAST ( NULL AS INTEGER ) + + 0 - + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + col1 * ( 16 * col0 ) FROM tab0 AS cor0
----
-129584
-33024
-54320

query I rowsort
SELECT ALL + col1 * col1 + + col0 * col2 AS col2 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT col1 * 13 - - ( cor0.col2 + + col2 ) * col2 FROM tab1 AS cor0
----
18601
6170
6628

query I rowsort
SELECT ALL cor0.col0 + ( - col2 ) FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - col0 * - 8 + 95 AS col1 FROM tab2 AS cor0
----
151
719
727

onlyif mysql # use DIV operator for integer division
query I rowsort label-6898
SELECT DISTINCT - 27 * - 89 * col2 + + col0 DIV col1 AS col1 FROM tab1 AS cor0
----
129762
136977
230694

skipif mysql # not compatible
query I rowsort label-6898
SELECT DISTINCT - 27 * - 89 * col2 + + col0 / col1 AS col1 FROM tab1 AS cor0
----
129762
136977
230694

query I rowsort
SELECT cor0.col1 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT - 10 * + col0 + col1 AS col0 FROM tab1 AS cor0
----
-4
-630
-787

query I rowsort
SELECT + ( + col0 ) + col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 96 AS col0 FROM tab0
----
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6903
SELECT ALL + CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6903
SELECT ALL + CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 5 AS col2 FROM tab0 AS cor0
----
-5
-5
-5

query I rowsort
SELECT - col0 * + col1 + col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT cor1.col2 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT + col2 * col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6908
SELECT + - col0 DIV col2 - col2 DIV col2 FROM tab1 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-6908
SELECT + - col0 / col2 - col2 / col2 FROM tab1 AS cor0
----
-1
-1
-2

query I rowsort
SELECT - - col1 + col1 * - col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + col0 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6911
SELECT - col0 * - 29 + - col2 + - col2 DIV 85 FROM tab1 AS cor0
----
1799
2223
33

skipif mysql # not compatible
query I rowsort label-6911
SELECT - col0 * - 29 + - col2 + - col2 / 85 FROM tab1 AS cor0
----
1799
2223
33

query I rowsort
SELECT + col1 * + 17 * col1 FROM tab0 AS cor0
----
125732
140777
159953

query I rowsort
SELECT - + ( col0 ) + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7372
8192
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 87 col1 FROM tab1, tab1 cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT DISTINCT - 16 FROM tab1 AS cor0
----
-16

query I rowsort
SELECT 8 AS col0 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT 68 * cor0.col0 FROM tab1 AS cor0
----
204
4352
5440

query I rowsort
SELECT + cor0.col0 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + 78 AS col2 FROM tab0
----
78
78
78

query I rowsort
SELECT DISTINCT - 65 - col1 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
1999
3330
8034

query I rowsort
SELECT ALL - 24 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT + - 30 AS col0 FROM tab1 AS cor0
----
-30
-30
-30

query I rowsort
SELECT ALL - col1 * cor0.col2 + col2 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6925
SELECT + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6925
SELECT + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT + + col2 * - 5 * col2 AS col2 FROM tab2 AS cor0
----
-3380
-3645
-7220

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + 13 - + col1 AS col0 FROM tab2 AS cor0
----
-18
-4
-46

query I rowsort
SELECT ALL - 3 AS col0 FROM tab0 AS cor0
----
-3
-3
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6932
SELECT ALL - col1 DIV cor0.col2 - + col0 * - CAST( + 52 + col0 AS SIGNED ) col1 FROM tab1 AS cor0
----
10560
165
7424

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6932
SELECT ALL - col1 / cor0.col2 - + col0 * - CAST ( + 52 + col0 AS INTEGER ) col1 FROM tab1 AS cor0
----
10560
165
7424

query I rowsort
SELECT ALL 51 * 42 * - col2 - - 76 AS col1 FROM tab0 AS cor0
----
-175568
-2066
-70610

onlyif mysql # use DIV operator for integer division
query I rowsort label-6934
SELECT - col2 DIV ( - 21 ) AS col0 FROM tab0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-6934
SELECT - col2 / ( - 21 ) AS col0 FROM tab0
----
0
1
3

query I rowsort
SELECT col2 * - tab1.col0 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT tab2.col2 * ( - col1 ) FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT 95 FROM tab0, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 64 col1 FROM tab2
----
1664
1728
2432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 + tab1.col1 col2 FROM tab1, tab1 cor0
----
9 values hashing to 35cd26f33597c096312fa50511b41cbe

query I rowsort
SELECT DISTINCT - col2 - + col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT col2 - - tab1.col1 * + 16 FROM tab1
----
217
304
470

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6942
SELECT ALL + col0 + CAST( NULL AS SIGNED ) - cor0.col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6942
SELECT ALL + col0 + CAST ( NULL AS INTEGER ) - cor0.col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + col1 * + col0 FROM tab2
----
1305
190
4576

query I rowsort
SELECT DISTINCT tab1.col2 + col1 FROM tab1
----
109
67
80

query I rowsort
SELECT col1 + - col1 + col0 * - col1 AS col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6946
SELECT ALL + + col0 * + CAST( NULL AS DECIMAL ) + - col0 * col2 + 2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6946
SELECT ALL + + col0 * + CAST ( NULL AS REAL ) + - col0 * col2 + 2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 + - 88 * col2 * col2 FROM tab2 AS cor0
----
-127089
-59547
-64183

query I rowsort
SELECT DISTINCT tab1.col0 + - col2 AS col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT col0 * 44 + - 50 + col1 * tab1.col1 AS col1 FROM tab1
----
2866
3639
758

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 + - col2 col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - + col2 + 6 AS col0 FROM tab1 AS cor0
----
-48
-51
-90

query I rowsort
SELECT + - col0 + + 19 * ( col2 * col0 ) FROM tab2 AS cor0
----
3584
38454
56959

onlyif mysql # use DIV operator for integer division
query I rowsort label-6953
SELECT DISTINCT col1 DIV - col1 + - 50 FROM tab0 AS cor0
----
-51

skipif mysql # not compatible
query I rowsort label-6953
SELECT DISTINCT col1 / - col1 + - 50 FROM tab0 AS cor0
----
-51

query I rowsort
SELECT DISTINCT - col0 * 30 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-179
-2281
-2353

query I rowsort
SELECT ALL col1 * ( col0 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col2 + col2 * col0 FROM tab1 AS cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + col1 * + 87 col2 FROM tab2 cor0
----
1496
2728
5192

query I rowsort
SELECT ALL + col1 * - col2 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6959
SELECT DISTINCT col1 * col0 DIV 75 + + col1 + ( + col1 ) * - col2 AS col2 FROM tab2 AS cor0
----
-1414
-612
-804

skipif mysql # not compatible
query I rowsort label-6959
SELECT DISTINCT col1 * col0 / 75 + + col1 + ( + col1 ) * - col2 AS col2 FROM tab2 AS cor0
----
-1414
-612
-804

query I rowsort
SELECT col0 * + col2 * col2 - - col2 AS col2 FROM tab2
----
114114
5130
52754

query I rowsort
SELECT - tab0.col2 + 98 AS col2 FROM tab0
----
16
65
97

query I rowsort
SELECT ( col1 ) AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT + 89 * + col1 - tab1.col0 FROM tab1
----
1077
2311
826

query I rowsort
SELECT + col1 + tab2.col1 AS col1 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT + tab0.col0 FROM tab0, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT tab2.col2 + 37 FROM tab2
----
63
64
75

query I rowsort
SELECT col0 * - cor0.col2 AS col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL 89 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT 90 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT ALL ( + col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col0 * - col0 + - col1 * - col0 FROM tab1 AS cor0
----
-3456
-5360
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6972
SELECT DISTINCT cor0.col1 * - col1 * CAST( col0 AS SIGNED ) FROM tab2 cor0
----
-22831
-271518
-6727

skipif mysql # not compatible
query I rowsort label-6972
SELECT DISTINCT cor0.col1 * - col1 * CAST ( col0 AS INTEGER ) FROM tab2 cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6973
SELECT ALL - col0 * - cor0.col2 * CAST( NULL AS SIGNED ) + 30 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6973
SELECT ALL - col0 * - cor0.col2 * CAST ( NULL AS INTEGER ) + 30 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 59 FROM tab1 AS cor0
----
-59
-59
-59

query I rowsort
SELECT ALL - 65 + - col1 AS col1 FROM tab2 AS cor0
----
-124
-82
-96

query I rowsort
SELECT DISTINCT - - cor0.col1 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * + col1 col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT col0 * col0 + - col2 FROM tab0 AS cor0
----
1224
543
7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-6979
SELECT - 99 DIV - cor0.col1 + CAST( - col1 AS SIGNED ) * cor0.col1 * - 97 - ( col1 ) FROM tab1 AS cor0
----
16387
65549
9699

skipif mysql # not compatible
query I rowsort label-6979
SELECT - 99 / - cor0.col1 + CAST ( - col1 AS INTEGER ) * cor0.col1 * - 97 - ( col1 ) FROM tab1 AS cor0
----
16387
65549
9699

query I rowsort
SELECT + - cor0.col0 * + col1 + + cor0.col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6981
SELECT DISTINCT + + col0 + col0 * CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6981
SELECT DISTINCT + + col0 + col0 * CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 * cor0.col0 - col2 * 44 AS col1 FROM tab2 cor0
----
-1237
-7228
-7913

query I rowsort
SELECT ALL - col2 + + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - + col0 + + col0 + + col0 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT 94 FROM tab2 AS cor0
----
94
94
94

query I rowsort
SELECT DISTINCT col1 + col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + col0 * col2 * col1 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 31 col1 FROM tab2
----
-31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 33 + col1 col2 FROM tab0 AS cor0
----
53
58
64

query I rowsort
SELECT ALL - 29 FROM tab0 AS cor0
----
-29
-29
-29

query I rowsort
SELECT - 69 AS col0 FROM tab0
----
-69
-69
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col1 col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL 75 FROM tab0
----
75
75
75

query I rowsort
SELECT + + col0 * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 29 + + col2 AS col0 FROM tab1 cor0
----
125
83
86

query I rowsort
SELECT + + cor0.col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT 81 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81

query I rowsort
SELECT + - col0 - col2 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + cor0.col1 + ( cor0.col0 ) * + col0 AS col2 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT + col2 * col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 - 60 col0 FROM tab1 AS cor0
----
-57
20
4

query I rowsort
SELECT cor0.col1 * + col1 + 51 * col1 FROM tab0 AS cor0
----
11782
12922
14356

query I rowsort
SELECT ALL - tab0.col2 + - col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT ALL 63 AS col2 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT ALL - tab0.col1 - tab0.col0 * - ( col2 ) AS col0 FROM tab0
----
-62
706
7207

query I rowsort
SELECT ALL col1 + - col2 * 77 AS col1 FROM tab1
----
-4132
-4379
-7379

query I rowsort
SELECT ALL - col1 * col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - + ( + 11 ) * + col1 + 45 FROM tab0 AS cor0
----
-1022
-901
-956

query I rowsort
SELECT ALL + ( + col1 ) + + col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + + col0 + 35 AS col1 FROM tab0 AS cor0
----
124
59
70

query I rowsort
SELECT + cor0.col1 * 61 AS col0 FROM tab0 AS cor0
----
5246
5551
5917

query I rowsort
SELECT ALL - + col0 + col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 * + 85 FROM tab2 AS cor0
----
1445
2635
5015

query I rowsort
SELECT DISTINCT + - ( 36 ) * col0 + 72 FROM tab2 AS cor0
----
-180
-2736
-2772

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col0 AS REAL ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 83 col2 FROM tab2 cor0
----
83
83
83

query I rowsort
SELECT ALL - ( + col1 ) * + col1 * + col2 AS col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT DISTINCT + col0 + - ( + col0 ) AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - ( col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col0 + 41 FROM tab2 AS cor0
----
-37
-38
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7023
SELECT ALL + + CAST( - col0 AS SIGNED ) * cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-7023
SELECT ALL + + CAST ( - col0 AS INTEGER ) * cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7024
SELECT CAST( NULL AS SIGNED ) * 30 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7024
SELECT CAST ( NULL AS INTEGER ) * 30 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col0 + - 72 * + cor0.col2 FROM tab0 AS cor0
----
-107
-2400
-5993

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7026
SELECT - CAST( NULL AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7026
SELECT - CAST ( NULL AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col0 + + col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL - tab2.col1 + ( col0 ) + - col2 FROM tab2
----
-51
-7
24

query I rowsort
SELECT + col1 + col0 FROM tab2
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 89 * col1 col2 FROM tab0
----
7654
8099
8633

onlyif mysql # use DIV operator for integer division
query I rowsort label-7032
SELECT + + col1 * col2 DIV + 91 AS col1 FROM tab0 AS cor0
----
1
31
82

skipif mysql # not compatible
query I rowsort label-7032
SELECT + + col1 * col2 / + 91 AS col1 FROM tab0 AS cor0
----
1
31
82

query I rowsort
SELECT DISTINCT 1 FROM tab1, tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT + - ( - col1 ) * + cor0.col0 + + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7035
SELECT ALL + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7035
SELECT ALL + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + ( col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 50 * ( col2 ) AS col2 FROM tab2 AS cor0
----
1300
1350
1900

query I rowsort
SELECT ( + tab2.col0 ) + col2 FROM tab2
----
104
117
34

query I rowsort
SELECT - - col2 * - col2 + 35 AS col2 FROM tab0 AS cor0
----
-1054
-6689
34

query I rowsort
SELECT ALL + + col1 * 45 AS col0 FROM tab0 cor0
----
3870
4095
4365

onlyif mysql # use DIV operator for integer division
query I rowsort label-7041
SELECT + - col2 * ( - col2 ) DIV col0 + col0 AS col0 FROM tab0 AS cor0
----
164
35
69

skipif mysql # not compatible
query I rowsort label-7041
SELECT + - col2 * ( - col2 ) / col0 + col0 AS col0 FROM tab0 AS cor0
----
164
35
69

query I rowsort
SELECT DISTINCT - col2 + + col0 * ( col1 ) FROM tab0
----
2031
3394
8017

query I rowsort
SELECT + col0 + tab2.col0 AS col2 FROM tab2
----
14
156
158

query I rowsort
SELECT ( col0 ) * col0 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * tab1.col2 col1 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT col0 * tab0.col1 * - col0 AS col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT + - col0 + col0 * col1 * + col1 FROM tab1 AS cor0
----
13440
2025
6336

query I rowsort
SELECT ALL + col0 * + col2 + 4 FROM tab0 AS cor0
----
39
7302
796

query I rowsort
SELECT - cor0.col2 * col2 + - 54 * col0 FROM tab2 AS cor0
----
-1107
-4888
-5710

query I rowsort
SELECT DISTINCT col2 + + col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - ( + col0 ) - - tab2.col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + ( col0 ) + tab2.col1 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT col2 * - col1 - - col2 * + col1 * - col2 AS col0 FROM tab0 AS cor0
----
-194
-619346
-96492

onlyif mysql # use DIV operator for integer division
query I rowsort label-7054
SELECT - col1 + col2 DIV 12 + col1 AS col0 FROM tab1 AS cor0
----
4
4
8

skipif mysql # not compatible
query I rowsort label-7054
SELECT - col1 + col2 / 12 + col1 AS col0 FROM tab1 AS cor0
----
4
4
8

query I rowsort
SELECT DISTINCT 58 FROM tab2, tab2 AS cor0
----
58

query I rowsort
SELECT 9 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1, tab1 AS cor2
----
13122 values hashing to 10314a0767de9146be3f42497c0a19d4

query I rowsort
SELECT 59 FROM tab1, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

onlyif mysql # use DIV operator for integer division
query I rowsort label-7059
SELECT ALL col2 * col0 DIV - CAST( + col1 AS SIGNED ) FROM tab0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-7059
SELECT ALL col2 * col0 / - CAST ( + col1 AS INTEGER ) FROM tab0
----
-80
-9
0

query I rowsort
SELECT col1 * - col2 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT 57 * col1 * - col1 AS col2 FROM tab2
----
-16473
-198417
-54777

query I rowsort
SELECT col2 * + col1 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT + tab0.col0 * col1 * + ( col0 ) AS col2 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT + col0 + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-7065
SELECT - cor0.col1 DIV + col0 - - col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
957

skipif mysql # not compatible
query I rowsort label-7065
SELECT - cor0.col1 / + col0 - - col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
957

query I rowsort
SELECT ALL + col0 AS col0 FROM tab2 cor0
----
7
78
79

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT DISTINCT - col0 + - col1 + - col2 FROM tab1 AS cor0
----
-131
-189
-83

query I rowsort
SELECT ALL 39 AS col1 FROM tab1
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-7070
SELECT col0 DIV + tab1.col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7070
SELECT col0 / + tab1.col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - col1 * cor0.col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col0 + col1 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + col0 + col1 * - col1 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT cor0.col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL col0 + + col0 AS col2 FROM tab2
----
14
156
158

query I rowsort
SELECT + - col1 - col1 * + col2 AS col0 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - - cor0.col1 - cor0.col2 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7079
SELECT DISTINCT col1 DIV col2 - - col2 AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7079
SELECT DISTINCT col1 / col2 - - col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - cor0.col1 * col1 + col2 FROM tab0 cor0
----
-7363
-8199
-9408

query I rowsort
SELECT - col1 - col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL col2 + + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-7083
SELECT DISTINCT - col2 * col2 - col0 DIV - cor0.col1 FROM tab2 AS cor0
----
-1440
-675
-729

skipif mysql # not compatible
query I rowsort label-7083
SELECT DISTINCT - col2 * col2 - col0 / - cor0.col1 FROM tab2 AS cor0
----
-1440
-675
-729

query I rowsort
SELECT ALL col0 * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col1 * col2 + + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 44 * + col2 col2 FROM tab2 AS cor0
----
-1144
-1188
-1672

query I rowsort
SELECT + cor0.col0 + tab1.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 4a01ecc2037eb425b02feee67266c705

onlyif mysql # use DIV operator for integer division
query I rowsort label-7088
SELECT col0 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7088
SELECT col0 / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - col1 * 23 + + col2 FROM tab2 AS cor0
----
-1331
-353
-686

query I rowsort
SELECT + 94 * 52 AS col0 FROM tab0 AS cor0
----
4888
4888
4888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7091
SELECT CAST( cor0.col2 AS SIGNED ) * - cor0.col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-7091
SELECT CAST ( cor0.col2 AS INTEGER ) * - cor0.col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col0 + + col2 * col2 FROM tab0 AS cor0
----
-34
1065
6635

onlyif mysql # use DIV operator for integer division
query I rowsort label-7093
SELECT ALL col2 DIV - cor0.col2 - col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-7093
SELECT ALL col2 / - cor0.col2 - col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT + 24 * col0 AS col0 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT + - ( col1 ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7096
SELECT DISTINCT + col2 DIV - 28 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-7096
SELECT DISTINCT + col2 / - 28 FROM tab0
----
-1
-2
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7097
SELECT ALL + CAST( col1 AS SIGNED ) * tab2.col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-7097
SELECT ALL + CAST ( col1 AS INTEGER ) * tab2.col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT + 64 + col2 FROM tab0 AS cor0
----
146
65
97

query I rowsort
SELECT ALL col0 * col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - col2 * col0 + col0 * + col1 AS col1 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT ALL ( col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to c04c36412775e8805d6b3befa2f52917

query I rowsort
SELECT ALL col2 + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col2 * - 13 FROM tab1 AS cor0
----
1248
702
741

query I rowsort
SELECT 73 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT - col0 * 19 FROM tab0 AS cor0
----
-1691
-456
-665

query I rowsort
SELECT ALL - col1 + + cor0.col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col0 + + 86 + col1 FROM tab2 AS cor0
----
124
182
223

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + col2 AS col1 FROM tab1 AS cor0
----
-43
-622
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7110
SELECT ALL 12 * cor0.col2 * - CAST( NULL AS DECIMAL ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7110
SELECT ALL 12 * cor0.col2 * - CAST ( NULL AS REAL ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-7111
SELECT DISTINCT col0 DIV 64 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-7111
SELECT DISTINCT col0 / 64 FROM tab0
----
0
1

query I rowsort
SELECT DISTINCT ( + 53 ) + + col2 AS col1 FROM tab1
----
107
110
149

query I rowsort
SELECT ( + 55 ) - tab2.col0 * + col2 * col2 FROM tab2
----
-114021
-5048
-52673

query I rowsort
SELECT ALL ( + 16 ) - - col2 FROM tab2
----
42
43
54

query I rowsort
SELECT DISTINCT col0 * + col0 + + col0 - col0 FROM tab1
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7116
SELECT CAST( NULL AS SIGNED ) - + 8 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7116
SELECT CAST ( NULL AS INTEGER ) - + 8 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 41 FROM tab0, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT + col0 + - col0 + - col1 * 85 AS col0 FROM tab1
----
-1105
-2210
-850

query I rowsort
SELECT - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT ALL 45 + tab2.col0 AS col1 FROM tab2
----
123
124
52

query I rowsort
SELECT DISTINCT + - 98 FROM tab2, tab0, tab0 AS cor0
----
-98

query I rowsort
SELECT - 10 AS col1 FROM tab0, tab0 cor0, tab0 cor1
----
27 values hashing to bb7f754a7a056e665155ed52a63f5bc0

query I rowsort
SELECT ALL 36 + - col2 * - col1 AS col2 FROM tab0
----
133
2874
7498

onlyif mysql # use DIV operator for integer division
query I rowsort label-7124
SELECT ALL cor0.col1 * col0 + + cor0.col2 DIV + col1 AS col0 FROM tab1 AS cor0
----
1047
645
80

skipif mysql # not compatible
query I rowsort label-7124
SELECT ALL cor0.col1 * col0 + + cor0.col2 / + col1 AS col0 FROM tab1 AS cor0
----
1047
645
80

query I rowsort
SELECT ALL col2 + - col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - - col0 * - 99 AS col2 FROM tab0 AS cor0
----
-2376
-3465
-8811

query I rowsort
SELECT col0 * tab0.col2 * tab0.col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ( - tab2.col1 ) * 51 + col2 FROM tab2
----
-1554
-2983
-829

query I rowsort
SELECT + + 56 + col2 + 7 FROM tab2 cor0
----
101
89
90

query I rowsort
SELECT DISTINCT tab0.col2 + col1 FROM tab0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7131
SELECT ALL - ( col0 ) * + CAST( NULL AS DECIMAL ) * - col0 + col2 / col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7131
SELECT ALL - ( col0 ) * + CAST ( NULL AS REAL ) * - col0 + col2 / col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + col0 AS col1 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7133
SELECT col2 DIV tab1.col2 + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-7133
SELECT col2 / tab1.col2 + col2 FROM tab1
----
55
58
97

query I rowsort
SELECT ALL - 85 * + col1 + - col0 AS col0 FROM tab1
----
-1185
-2213
-914

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 cor2
----
972 values hashing to 72eb3d4d523f5d0c69d1b855edd18f4a

query I rowsort
SELECT DISTINCT + col1 * 81 * col2 + - col2 AS col1 FROM tab2 AS cor0
----
124228
52288
67770

query I rowsort
SELECT ALL - + col2 + + cor0.col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL - col1 - 21 AS col1 FROM tab0 AS cor0
----
-107
-112
-118

query I rowsort
SELECT DISTINCT - col2 * + col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT col1 * + col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + ( - col0 ) * col0 col1 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT ALL col2 + cor0.col2 * + ( - cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT - - col2 * cor0.col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT + - col0 + 46 AS col0 FROM tab1 AS cor0
----
-18
-34
43

query I rowsort
SELECT DISTINCT + + cor0.col0 + col0 AS col1 FROM tab2 cor0
----
14
156
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7146
SELECT DISTINCT - col0 + + CAST( + col2 + - col0 AS SIGNED ) FROM tab1 cor0
----
-64
-71
48

skipif mysql # not compatible
query I rowsort label-7146
SELECT DISTINCT - col0 + + CAST ( + col2 + - col0 AS INTEGER ) FROM tab1 cor0
----
-64
-71
48

query I rowsort
SELECT ALL - col2 * col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7148
SELECT ALL - - col1 DIV col0 col1 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7148
SELECT ALL - - col1 / col0 col1 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 5 AS col1 FROM tab1, tab0 AS cor0
----
5

query I rowsort
SELECT - col0 + 98 AS col1 FROM tab2
----
19
20
91

query I rowsort
SELECT + col0 + + col0 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7153
SELECT ALL + col0 DIV col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7153
SELECT ALL + col0 / col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col1 * - col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - col1 + 88 FROM tab0 AS cor0
----
-3
-9
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7157
SELECT ALL + 90 DIV + 60 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-7157
SELECT ALL + 90 / + 60 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT + tab0.col1 * - col0 * + col1 + + col1 * col0 FROM tab0
----
-175440
-325920
-728910

query I rowsort
SELECT ALL tab2.col2 * col0 AS col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - tab1.col1 AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL - + 84 + - col0 * col0 AS col0 FROM tab1 AS cor0
----
-4180
-6484
-93

query I rowsort
SELECT ALL + + 26 + col1 FROM tab1 AS cor0
----
36
39
52

query I rowsort
SELECT DISTINCT + + col1 + col2 * col2 * + col2 + col0 AS col1 FROM tab2 cor0
----
17713
19721
54968

query I rowsort
SELECT ALL - cor0.col2 + col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT 39 AS col1 FROM tab1 AS cor0
----
39

query I rowsort
SELECT DISTINCT 11 + + cor0.col0 * + col2 AS col1 FROM tab1 AS cor0
----
173
3659
7691

query I rowsort
SELECT - - ( 93 ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
2418
2511
3534

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7169
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col0 / + col1 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7169
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col0 / + col1 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - ( + col1 ) + col1 FROM tab2 cor0
----
0

query I rowsort
SELECT - + col0 + 68 * + col2 FROM tab1 AS cor0
----
3669
3812
6448

query I rowsort
SELECT ALL cor0.col2 * + col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT col2 * + 40 * + col0 AS col2 FROM tab0 AS cor0
----
1400
291920
31680

query I rowsort
SELECT - - col0 * + col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + 44 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to a2f6e2dede0e5618df35bee9c606a24c

query I rowsort
SELECT - 40 AS col0 FROM tab1 cor0
----
-40
-40
-40

query I rowsort
SELECT DISTINCT - col1 + + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + 12 + col2 AS col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT ALL - - cor0.col2 * col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL + ( cor0.col2 ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT 25 AS col2 FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT ALL + col0 * cor0.col2 * col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT ALL col2 + col0 * col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL - + cor0.col1 + col0 AS col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + - col2 * + col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + 3 AS col2 FROM tab0 AS cor0
----
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col1 col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + ( - col2 ) * ( col1 ) + + col2 + - col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col1 + + col2 * - col1 AS col2 FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT - 54 + + col1 + - col1 FROM tab0 AS cor0
----
-54
-54
-54

query I rowsort
SELECT DISTINCT - col1 * - cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 col0 FROM tab2 cor0
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7193
SELECT ALL + - col1 DIV - col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-7193
SELECT ALL + - col1 / - col0 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL + - col1 AS col1 FROM tab2 cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * + col2 col1 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-7196
SELECT + col2 DIV - col0 + col2 + + col2 AS col2 FROM tab0 AS cor0
----
164
2
65

skipif mysql # not compatible
query I rowsort label-7196
SELECT + col2 / - col0 + col2 + + col2 AS col2 FROM tab0 AS cor0
----
164
2
65

query I rowsort
SELECT + - col2 + + col1 + col1 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT ALL - + col2 * + col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - - cor0.col2 + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7200
SELECT DISTINCT - + cor0.col2 DIV col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7200
SELECT DISTINCT - + cor0.col2 / col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - col2 + col2 * col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL - col0 + col0 * col2 AS col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT - + 60 * col0 + 92 + + cor0.col1 FROM tab0 AS cor0
----
-1262
-1911
-5157

query I rowsort
SELECT ALL + col0 * + cor0.col1 * col2 AS col0 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT - col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col0 + - col2 * ( 20 ) FROM tab0
----
-1729
-55
-684

onlyif mysql # use DIV operator for integer division
query I rowsort label-7207
SELECT col0 DIV + col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7207
SELECT col0 / + col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 94 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
94

query I rowsort
SELECT 2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT + cor0.col1 + 18 AS col0 FROM tab0 AS cor0
----
104
109
115

query I rowsort
SELECT + 79 - - col0 FROM tab0
----
103
114
168

query I rowsort
SELECT DISTINCT - col0 + col2 AS col0 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7213
SELECT DISTINCT 71 + col1 DIV - 19 AS col1 FROM tab2
----
68
70
71

skipif mysql # not compatible
query I rowsort label-7213
SELECT DISTINCT 71 + col1 / - 19 AS col1 FROM tab2
----
68
70
71

query I rowsort
SELECT ALL + col2 * col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT + 67 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7216
SELECT - col2 DIV col2 AS col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7216
SELECT - col2 / col2 AS col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT col1 * - col0 + + 22 * col1 AS col0 FROM tab1 AS cor0
----
-420
-754
494

query I rowsort
SELECT - cor0.col2 + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + + cor0.col0 - - col2 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col1 * cor0.col1 + + col1 * col0 AS col0 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT col1 + 42 * 61 FROM tab2 cor0
----
2579
2593
2621

query I rowsort
SELECT + col2 * ( 73 ) * col0 + + col1 AS col0 FROM tab2 AS cor0
----
13828
148103
219163

query I rowsort
SELECT ALL - 91 FROM tab1
----
-91
-91
-91

query I rowsort
SELECT col0 * col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL - col1 * col0 AS col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - col1 + col0 * + col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + 73 * - col0 FROM tab1 AS cor0
----
-219
-4672
-5840

query I rowsort
SELECT + + col2 * col0 AS col2 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * cor0.col2 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col1 + + ( col0 ) * + ( col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
-118728
-49450
-720720

query I rowsort
SELECT ALL + col0 + + col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7232
SELECT + CAST( NULL AS DECIMAL ) * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7232
SELECT + CAST ( NULL AS REAL ) * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + ( 47 ) AS col2 FROM tab1 AS cor0
----
47

query I rowsort
SELECT DISTINCT col0 * col1 - - cor0.col2 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT + + 25 * cor0.col1 * col2 FROM tab0 cor0
----
186550
2425
70950

query I rowsort
SELECT DISTINCT col1 * ( - col2 * tab1.col1 ) AS col2 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT + tab1.col0 + + 62 FROM tab1
----
126
142
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7238
SELECT CAST( NULL AS SIGNED ) + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7238
SELECT CAST ( NULL AS INTEGER ) + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + 57 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7241
SELECT CAST( + col0 AS SIGNED ) AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7241
SELECT CAST ( + col0 AS INTEGER ) AS col2 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col0 + cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + + cor0.col0 + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT + + 36 AS col2 FROM tab0 AS cor0
----
36

query I rowsort
SELECT DISTINCT + cor0.col2 * col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - 56 + col1 * col0 * + col1 AS col1 FROM tab0 cor0
----
177448
329259
736953

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7248
SELECT DISTINCT 93 + + col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7248
SELECT DISTINCT 93 + + col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL 70 AS col2 FROM tab0 AS cor0
----
70
70
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7250
SELECT - col2 DIV + col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-7250
SELECT - col2 / + col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT + 75 * + col0 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT ALL col1 * + cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - col2 AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT - 89 FROM tab0 cor0
----
-89
-89
-89

query I rowsort
SELECT ALL col0 * - ( col2 ) AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL - ( tab1.col0 ) AS col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT - col1 + + col2 * + ( col0 * + col2 + 85 ) AS col1 FROM tab0 AS cor0
----
23
28855
605315

query I rowsort
SELECT - col2 * col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + 45 FROM tab2 AS cor0
----
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7260
SELECT - col2 * + col0 DIV - cor0.col0 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7260
SELECT - col2 * + col0 / - cor0.col0 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col0 * 99 * + cor0.col1 FROM tab0 AS cor0
----
204336
336105
801801

onlyif mysql # use DIV operator for integer division
query I rowsort label-7262
SELECT + ( col1 ) + + ( 41 ) DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
17
36
59

skipif mysql # not compatible
query I rowsort label-7262
SELECT + ( col1 ) + + ( 41 ) / cor0.col0 AS col2 FROM tab2 AS cor0
----
17
36
59

query I rowsort
SELECT + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT col1 * + col0 * col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT ALL - 28 AS col0 FROM tab0 AS cor0
----
-28
-28
-28

query I rowsort
SELECT - col0 * - 90 + col0 FROM tab0 AS cor0
----
2184
3185
8099

query I rowsort
SELECT + 24 * + 18 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 48b71d232f6aafe607354db08bd58d2a

query I rowsort
SELECT 87 - - col2 AS col2 FROM tab0
----
120
169
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 29 ) * - tab1.col0 col1 FROM tab1
----
-1856
-2320
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-7270
SELECT + ( 12 ) DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7270
SELECT + ( 12 ) / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 41 AS col0 FROM tab0
----
-41
-41
-41

query I rowsort
SELECT - 35 AS col0 FROM tab2 cor0
----
-35
-35
-35

query I rowsort
SELECT DISTINCT 97 AS col2 FROM tab1, tab1 AS cor0
----
97

query I rowsort
SELECT ( col2 ) + cor0.col0 * - col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ( + col0 ) FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - 18 FROM tab0 cor0
----
-18

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT DISTINCT - col0 + - col2 FROM tab1 cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT col0 * + col2 + col0 * col0 FROM tab1 AS cor0
----
14080
171
7744

query I rowsort
SELECT ALL + col0 + 55 FROM tab2 AS cor0
----
133
134
62

query I rowsort
SELECT ALL + col0 - col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * + ( col2 ) FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL - col0 * col1 + col0 * col0 AS col2 FROM tab1 AS cor0
----
-69
3456
5360

query I rowsort
SELECT DISTINCT + col2 - cor0.col2 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT - col2 + 58 AS col0 FROM tab2 AS cor0
----
20
31
32

query I rowsort
SELECT ALL + col2 * + ( - 33 ) FROM tab2 AS cor0
----
-1254
-858
-891

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7288
SELECT CAST( + col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7288
SELECT CAST ( + col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - - col1 * cor0.col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - - 13 AS col0 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT ALL cor1.col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ( cor0.col0 ) AS col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT - 7 * + ( col2 ) FROM tab1 AS cor0
----
-378
-399
-672

query I rowsort
SELECT DISTINCT + 84 + + 49 * cor0.col0 * cor0.col1 + 19 FROM tab2 AS cor0
----
10736
225601
65910

query I rowsort
SELECT - + col0 + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + col0 * - cor0.col2 * col2 + col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT DISTINCT - col0 + col2 * col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7298
SELECT + CAST( NULL AS SIGNED ) FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7298
SELECT + CAST ( NULL AS INTEGER ) FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - - col1 + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL ( - col2 ) * + col0 * 18 FROM tab1 cor0
----
-138240
-2916
-65664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7301
SELECT + + 62 * col2 + - CAST( - ( - col0 ) AS DECIMAL ) + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7301
SELECT + + 62 * col2 + - CAST ( - ( - col0 ) AS REAL ) + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7302
SELECT ALL cor0.col0 DIV - col1 AS col1 FROM tab1 cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-7302
SELECT ALL cor0.col0 / - col1 AS col1 FROM tab1 cor0
----
-6
-6
0

query I rowsort
SELECT + col2 + col2 * - col2 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL ( + col0 * col1 + 73 ) AS col1 FROM tab1
----
1113
151
713

query I rowsort
SELECT DISTINCT - cor1.col0 * cor0.col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
9 values hashing to 5ac8aba7baafe9bd6ceb7b5654f2c0b7

query I rowsort
SELECT + - col2 + - col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - + 18 AS col1 FROM tab1 AS cor0
----
-18

onlyif mysql # use DIV operator for integer division
query I rowsort label-7308
SELECT + + 68 DIV col1 + ( ( - col0 ) ) + 38 FROM tab0 AS cor0
----
-51
14
3

skipif mysql # not compatible
query I rowsort label-7308
SELECT + + 68 / col1 + ( ( - col0 ) ) + 38 FROM tab0 AS cor0
----
-51
14
3

query I rowsort
SELECT DISTINCT col1 * col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7310
SELECT cor0.col0 DIV + col0 col1 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7310
SELECT cor0.col0 / + col0 col1 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 14 + - col2 * 83 col0 FROM tab0
----
-2725
-6792
-69

query I rowsort
SELECT DISTINCT + col2 * + col0 + col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT col1 + tab0.col0 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL - col0 * 43 FROM tab2 AS cor0
----
-301
-3354
-3397

query I rowsort
SELECT ALL + col1 + + col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - col0 * - ( col1 + col2 ) FROM tab1 AS cor0
----
240
4288
8720

onlyif mysql # use DIV operator for integer division
query I rowsort label-7317
SELECT DISTINCT + col1 DIV 85 AS col0 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-7317
SELECT DISTINCT + col1 / 85 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT + col1 + - tab1.col2 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT + col1 * - col1 + + 95 * + 99 AS col2 FROM tab1
----
8729
9236
9305

query I rowsort
SELECT DISTINCT 9 * + col1 AS col0 FROM tab1
----
117
234
90

query I rowsort
SELECT ALL - 69 * col0 + - col1 AS col0 FROM tab2
----
-514
-5441
-5468

query I rowsort
SELECT DISTINCT col1 * - col0 + - tab1.col0 FROM tab1
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7323
SELECT DISTINCT - col1 + - tab0.col1 DIV + ( col2 ) AS col1 FROM tab0
----
-194
-88
-92

skipif mysql # not compatible
query I rowsort label-7323
SELECT DISTINCT - col1 + - tab0.col1 / + ( col2 ) AS col1 FROM tab0
----
-194
-88
-92

query I rowsort
SELECT ALL cor1.col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT + col1 + 70 * 66 FROM tab2 AS cor0
----
4637
4651
4679

query I rowsort
SELECT DISTINCT tab0.col1 + col1 AS col2 FROM tab0
----
172
182
194

query I rowsort
SELECT - col1 + - col2 * + tab0.col0 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT - + cor0.col1 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT DISTINCT - tab1.col1 FROM tab1, tab2 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col1 col1 FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7331
SELECT DISTINCT + col1 DIV ( 99 ) FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-7331
SELECT DISTINCT + col1 / ( 99 ) FROM tab1
----
0

query I rowsort
SELECT + - col1 + col0 AS col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + 74 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

query I rowsort
SELECT - col2 * - col0 + - col0 AS col1 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7335
SELECT DISTINCT - col0 + + CAST( NULL AS SIGNED ) * + col0 col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7335
SELECT DISTINCT - col0 + + CAST ( NULL AS INTEGER ) * + col0 col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 * 21 FROM tab1
----
1134
1197
2016

query I rowsort
SELECT ALL - - col1 + 30 AS col1 FROM tab1 AS cor0
----
40
43
56

query I rowsort
SELECT - tab0.col2 + - col0 - + col1 FROM tab0
----
-133
-143
-262

query I rowsort
SELECT 69 FROM tab0, tab2 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT 61 - - col0 FROM tab1
----
125
141
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-7341
SELECT ALL + ( col2 ) DIV col2 + tab0.col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-7341
SELECT ALL + ( col2 ) / col2 + tab0.col2 FROM tab0
----
2
34
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7342
SELECT + cor0.col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7342
SELECT + cor0.col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL 4 * - col2 + - tab2.col2 AS col1 FROM tab2
----
-130
-135
-190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 44 + col2 * + col0 col1 FROM tab1
----
206
3692
7724

query I rowsort
SELECT ALL + 42 AS col2 FROM tab1 cor0
----
42
42
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - col0 + - 29 col0 FROM tab0 AS cor0
----
-207
-77
-99

query I rowsort
SELECT DISTINCT + cor0.col0 * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7348
SELECT DISTINCT + cor0.col0 + + col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7348
SELECT DISTINCT + cor0.col0 + + col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL 85 * - col0 AS col1 FROM tab1 AS cor0
----
-255
-5440
-6800

query I rowsort
SELECT ALL + col0 * col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - 41 + - col1 FROM tab0 AS cor0
----
-127
-132
-138

query I rowsort
SELECT - col0 * - col0 + col1 AS col1 FROM tab2 cor0
----
6143
6258
80

query I rowsort
SELECT col1 - col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - - cor0.col2 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + col1 + col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + col0 * + col2 - col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL - 75 + cor0.col2 FROM tab2 AS cor0
----
-37
-48
-49

query I rowsort
SELECT DISTINCT 25 AS col1 FROM tab0, tab1 AS cor0
----
25

query I rowsort
SELECT DISTINCT ( - tab2.col2 ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-26
-27
-38

query I rowsort
SELECT ALL col2 * + col1 AS col2 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 col2 FROM tab0
----
86
91
97

query I rowsort
SELECT 93 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * col1 col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - 88 FROM tab0, tab0 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7367
SELECT - 64 + + col2 DIV col1 + ( col0 ) FROM tab2 AS cor0
----
-57
14
17

skipif mysql # not compatible
query I rowsort label-7367
SELECT - 64 + + col2 / col1 + ( col0 ) FROM tab2 AS cor0
----
-57
14
17

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab1, tab0 AS cor1
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT ( - col1 ) AS col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT - 91 * col1 AS col2 FROM tab2 cor0
----
-1547
-2821
-5369

query I rowsort
SELECT col1 * col2 - + col0 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ( - col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 - + col1 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7375
SELECT DISTINCT col2 - - cor0.col1 DIV - col0 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-7375
SELECT DISTINCT col2 - - cor0.col1 / - col0 FROM tab0 AS cor0
----
-1
30
81

query I rowsort
SELECT - col2 * col1 * - col1 AS col0 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT - col2 + - col0 * col1 AS col2 FROM tab0 cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( - col0 ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT - col1 + + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7381
SELECT ALL + - 80 + + col1 DIV 56 AS col0 FROM tab1 AS cor0
----
-80
-80
-80

skipif mysql # not compatible
query I rowsort label-7381
SELECT ALL + - 80 + + col1 / 56 AS col0 FROM tab1 AS cor0
----
-80
-80
-80

query I rowsort
SELECT ALL - 18 * - col2 + col1 FROM tab0 AS cor0
----
115
1567
680

query I rowsort
SELECT DISTINCT + - col1 + + cor0.col1 - col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7384
SELECT - 76 + col2 * - CAST( cor0.col2 + + cor0.col2 AS SIGNED ) FROM tab1 AS cor0
----
-18508
-5908
-6574

skipif mysql # not compatible
query I rowsort label-7384
SELECT - 76 + col2 * - CAST ( cor0.col2 + + cor0.col2 AS INTEGER ) FROM tab1 AS cor0
----
-18508
-5908
-6574

query I rowsort
SELECT DISTINCT 61 + cor0.col2 FROM tab1 AS cor0
----
115
118
157

query I rowsort
SELECT ALL + 19 AS col1 FROM tab1 cor0
----
19
19
19

query I rowsort
SELECT + cor0.col0 + col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT + col0 + 43 * - col0 FROM tab1 AS cor0
----
-126
-2688
-3360

query I rowsort
SELECT - cor0.col1 * col2 FROM tab1 cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * 76 col1 FROM tab2 AS cor0
----
-1292
-2356
-4484

query I rowsort
SELECT + col2 + - cor0.col1 AS col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ALL + 2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to b2fa3f9d060540fe1eb4ad1c0754e163

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - 28 col0 FROM tab0 AS cor0
----
-27
5
54

query I rowsort
SELECT ALL + col2 * + col0 + + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + - col0 + - col2 * col0 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + - col2 + + col1 + col0 AS col2 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT DISTINCT + col1 * 16 AS col2 FROM tab2 AS cor0
----
272
496
944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + + col0 * - col0 col0 FROM tab1 AS cor0
----
-4153
-63
-6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col2 col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + + col0 + + col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7402
SELECT cor0.col0 + 11 DIV col0 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7402
SELECT cor0.col0 + 11 / col0 FROM tab0 cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7403
SELECT - cor0.col1 + - ( col0 ) + col2 DIV - ( ( col2 ) ) col1 FROM tab1 AS cor0
----
-30
-75
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7403
SELECT - cor0.col1 + - ( col0 ) + col2 / - ( ( col2 ) ) col1 FROM tab1 AS cor0
----
-30
-75
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 col2 FROM tab0 AS cor0
----
73
73
73

query I rowsort
SELECT DISTINCT - col2 * + col1 + - cor0.col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT + - col2 * col0 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7408
SELECT DISTINCT - - CAST( NULL AS DECIMAL ) / + 93 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7408
SELECT DISTINCT - - CAST ( NULL AS REAL ) / + 93 AS col0 FROM tab1 AS cor0
----
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab0 cor1, tab0 AS cor2
----
972 values hashing to 8420206d6932c454f05a38de634b3cb5

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab1, tab0 AS cor1
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 9600bdf5bac0caec3229e87170cc40b3

query I rowsort
SELECT DISTINCT - 95 * + col2 + 5 * + col0 FROM tab0 AS cor0
----
-3015
-7345
80

query I rowsort
SELECT - col1 * col1 * col0 - - col1 FROM tab1 AS cor0
----
-13507
-2002
-6390

query I rowsort
SELECT - col2 + cor0.col2 * cor0.col2 * - cor0.col1 FROM tab2 AS cor0
----
-22626
-24586
-39910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + cor0.col0 - - col0 * col1 col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-7416
SELECT DISTINCT + col1 * - tab1.col0 DIV - col0 col0 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7416
SELECT DISTINCT + col1 * - tab1.col0 / - col0 col0 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - col2 * + col1 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT + 95 AS col0 FROM tab1
----
95
95
95

query I rowsort
SELECT + col1 * - col2 + col1 * - 48 AS col0 FROM tab0 AS cor0
----
-11830
-4753
-6966

onlyif mysql # use DIV operator for integer division
query I rowsort label-7420
SELECT - - col1 DIV - col1 + + col2 * - col2 + - col2 AS col1 FROM tab0 cor0
----
-1123
-3
-6807

skipif mysql # not compatible
query I rowsort label-7420
SELECT - - col1 / - col1 + + col2 * - col2 + - col2 AS col1 FROM tab0 cor0
----
-1123
-3
-6807

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 9 * col2 + col2 col2 FROM tab0 cor0
----
10
330
820

query I rowsort
SELECT DISTINCT ( - 82 ) AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-82

query I rowsort
SELECT DISTINCT col0 * - col2 + + col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT - col1 * - 96 + - tab2.col0 FROM tab2
----
1553
2969
5586

query I rowsort
SELECT DISTINCT + 92 * col2 + - col2 + col2 FROM tab2 AS cor0
----
2392
2484
3496

query I rowsort
SELECT DISTINCT + - cor0.col2 AS col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT - 4 FROM tab2 cor0
----
-4
-4
-4

query I rowsort
SELECT ALL + + 62 * - col1 - col2 FROM tab1 AS cor0
----
-1666
-677
-902

query I rowsort
SELECT ALL col2 * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - 69 * col1 AS col2 FROM tab2 AS cor0
----
-1173
-2139
-4071

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col0 col2 FROM tab1
----
3
64
80

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab0, tab0 AS cor1
----
972 values hashing to b2fa3f9d060540fe1eb4ad1c0754e163

query I rowsort
SELECT DISTINCT - + ( col2 ) AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT - + 38 FROM tab2 AS cor0
----
-38
-38
-38

query I rowsort
SELECT 98 FROM tab0 cor0
----
98
98
98

query I rowsort
SELECT DISTINCT - 9 * col0 * 48 AS col1 FROM tab0 AS cor0
----
-10368
-15120
-38448

query I rowsort
SELECT ALL ( - cor0.col1 ) AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT tab0.col2 * - col0 + - col1 AS col1 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT ALL + col0 * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL col2 + + col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 ) col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + - col0 + col2 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7444
SELECT DISTINCT col1 DIV 66 + + 98 FROM tab2
----
98

skipif mysql # not compatible
query I rowsort label-7444
SELECT DISTINCT col1 / 66 + + 98 FROM tab2
----
98

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to bcf430f79386b43bc4077271fcd15cf0

query I rowsort
SELECT ALL + - col0 + + col2 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT + - col1 * - col0 + 65 FROM tab0 AS cor0
----
2129
3460
8164

query I rowsort
SELECT col1 * 22 FROM tab1
----
220
286
572

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col2 + col2 + - col1 FROM tab1
----
104
179
82

query I rowsort
SELECT ALL + tab0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL - col1 + + ( - col0 ) * - col0 AS col0 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT ALL + col2 * - col2 + + tab1.col2 FROM tab1
----
-2862
-3192
-9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7454
SELECT ALL + col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7454
SELECT ALL + col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab0 cor1, tab1 AS cor2
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

query I rowsort
SELECT - cor0.col2 - 0 AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - - cor0.col0 * - col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - + col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col0 * - cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - cor0.col2 + + ( - col1 ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + col1 - 55 AS col2 FROM tab1 AS cor0
----
-29
-42
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7462
SELECT + + cor0.col0 + 27 DIV + 22 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7462
SELECT + + cor0.col0 + 27 / + 22 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - 83 * - col1 + col0 AS col0 FROM tab0 AS cor0
----
7162
7642
8086

query I rowsort
SELECT ALL + - 3 * 38 FROM tab1 AS cor0
----
-114
-114
-114

query I rowsort
SELECT ALL col2 + + 59 * col2 AS col1 FROM tab2 AS cor0
----
1560
1620
2280

query I rowsort
SELECT - + ( col0 ) + col2 * + col1 * col2 FROM tab1 AS cor0
----
119728
32426
75813

query I rowsort
SELECT ALL - 52 + + col2 * col0 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-52
7157
716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7468
SELECT DISTINCT - CAST( NULL AS SIGNED ) - 76 * col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7468
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - 76 * col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT tab1.col0 * 81 AS col1 FROM tab1
----
243
5184
6480

query I rowsort
SELECT DISTINCT - 73 + - col2 AS col2 FROM tab1 AS cor0
----
-127
-130
-169

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col2 col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - 52 * col0 + + col0 + 56 AS col0 FROM tab1 AS cor0
----
-3208
-4024
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col1 ) col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + - col1 - 11 AS col1 FROM tab2 AS cor0
----
-28
-42
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT col0 - 93 AS col0 FROM tab1
----
-13
-29
-90

query I rowsort
SELECT ALL + + 27 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT ALL - col1 * 49 FROM tab0 AS cor0
----
-4214
-4459
-4753

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1, tab0 cor2
----
3645 values hashing to e660b5944e34dd8d75740286862b3252

onlyif mysql # use DIV operator for integer division
query I rowsort label-7480
SELECT ( + tab0.col0 ) DIV col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7480
SELECT ( + tab0.col0 ) / col0 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL + + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL 9 * col1 * col0 AS col1 FROM tab0 cor0
----
18576
30555
72891

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 60 + - col2 + - col1 col0 FROM tab0 AS cor0
----
5041
5287
5722

onlyif mysql # use DIV operator for integer division
query I rowsort label-7484
SELECT ALL + ( 44 ) DIV + col2 - + col0 FROM tab0 AS cor0
----
-23
-89
9

skipif mysql # not compatible
query I rowsort label-7484
SELECT ALL + ( 44 ) / + col2 - + col0 FROM tab0 AS cor0
----
-23
-89
9

query I rowsort
SELECT ALL + 32 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 cor2
----
81 values hashing to 6bef041528d0147be26f7de162c66a5f

query I rowsort
SELECT DISTINCT - col2 + - col2 * - tab2.col1 FROM tab2
----
1508
608
810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 59 * cor0.col0 - + col1 col2 FROM tab1 AS cor0
----
-203
-3786
-4733

query I rowsort
SELECT + ( + cor0.col1 ) + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + + 63 + + col0 * col0 FROM tab0 cor0
----
1288
639
7984

query I rowsort
SELECT col0 * col0 + cor0.col1 * + 32 * - col2 AS col0 FROM tab1 AS cor0
----
-14144
-33536
-44919

query I rowsort
SELECT 86 + 61 * col2 * col0 AS col0 FROM tab0
----
2221
445264
48398

query I rowsort
SELECT + + ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT cor0.col2 + - col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - ( ( col1 ) ) FROM tab2
----
-17
-31
-59

query I rowsort
SELECT DISTINCT 31 * col1 AS col2 FROM tab1
----
310
403
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7496
SELECT CAST( - col2 AS SIGNED ) FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-7496
SELECT CAST ( - col2 AS INTEGER ) FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL ( + tab2.col2 ) FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT ( + col2 ) FROM tab1
----
54
57
96

query I rowsort
SELECT col1 * - 50 AS col2 FROM tab2
----
-1550
-2950
-850

query I rowsort
SELECT ALL 48 * + 74 + col0 FROM tab1
----
3555
3616
3632

query I rowsort
SELECT 13 AS col1 FROM tab0
----
13
13
13

query I rowsort
SELECT DISTINCT col2 * - col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7503
SELECT - col2 + - CAST( NULL AS SIGNED ) * + col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7503
SELECT - col2 + - CAST ( NULL AS INTEGER ) * + col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - cor0.col2 * - col2 + cor0.col0 * col0 FROM tab0 AS cor0
----
1226
14645
1665

query I rowsort
SELECT + col1 + col2 * + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col1 * + col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7507
SELECT DISTINCT col2 DIV - col1 + - 75 FROM tab2 AS cor0
----
-75
-77

skipif mysql # not compatible
query I rowsort label-7507
SELECT DISTINCT col2 / - col1 + - 75 FROM tab2 AS cor0
----
-75
-77

query I rowsort
SELECT ALL col0 * 52 AS col2 FROM tab2 AS cor0
----
364
4056
4108

query I rowsort
SELECT col0 * 83 AS col1 FROM tab0 AS cor0
----
1992
2905
7387

query I rowsort
SELECT + 83 + + col2 * tab2.col1 AS col1 FROM tab2
----
1617
729
920

query I rowsort
SELECT col2 + - col1 FROM tab1
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT tab1.col2 AS col2 FROM tab1, tab2, tab0 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - col1 * - 62 + col0 FROM tab1
----
1615
684
886

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7515
SELECT DISTINCT CAST( NULL AS SIGNED ) * 31 * + tab2.col0 AS col2 FROM tab2, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7515
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 31 * + tab2.col0 AS col2 FROM tab2, tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT cor0.col0 * 87 FROM tab0, tab2 AS cor0
----
609
6786
6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-7517
SELECT + col0 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7517
SELECT + col0 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL col1 + 32 AS col0 FROM tab2 AS cor0
----
49
63
91

query I rowsort
SELECT ALL + col1 + - 47 * col0 AS col2 FROM tab0 AS cor0
----
-1042
-1548
-4092

query I rowsort
SELECT DISTINCT + col0 * + 6 AS col1 FROM tab1 AS cor0
----
18
384
480

query I rowsort
SELECT - cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT - cor0.col1 + cor0.col0 * - 89 AS col1 FROM tab1 AS cor0
----
-293
-5706
-7133

query I rowsort
SELECT ALL + col1 + - col1 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + cor0.col1 ) * 24 col1 FROM tab1 AS cor0
----
-240
-312
-624

query I rowsort
SELECT cor0.col2 * - col0 * col2 FROM tab1 cor0
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-7526
SELECT - col2 * col1 DIV ( col1 + + col0 ) FROM tab2 AS cor0
----
-11
-22
-6

skipif mysql # not compatible
query I rowsort label-7526
SELECT - col2 * col1 / ( col1 + + col0 ) FROM tab2 AS cor0
----
-11
-22
-6

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab1, tab0 AS cor1
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT + - col0 * - col0 * - 49 FROM tab0 AS cor0
----
-28224
-388129
-60025

query I rowsort
SELECT + col2 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - - col0 * col0 * - cor0.col0 FROM tab1 AS cor0
----
-262144
-27
-512000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 36 col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col2 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL 62 FROM tab1
----
62
62
62

query I rowsort
SELECT ALL + - col1 AS col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT - col1 * col1 * - ( col0 ) FROM tab1 cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-7537
SELECT DISTINCT - - cor0.col0 DIV col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-7537
SELECT DISTINCT - - cor0.col0 / col0 FROM tab0 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + ( - col1 ) * + col1 col0 FROM tab2 AS cor0
----
-272
-3422
-930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + - 11 col1 FROM tab1 AS cor0
----
-21
-24
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-7540
SELECT ALL col2 DIV col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7540
SELECT ALL col2 / col2 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL + ( - tab2.col2 ) * + ( - 37 ) AS col0 FROM tab2
----
1406
962
999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7542
SELECT ALL - col0 * tab1.col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7542
SELECT ALL - col0 * tab1.col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + 78 FROM tab1 AS cor0
----
-18
21
24

query I rowsort
SELECT col0 * ( - col1 + col0 ) FROM tab1
----
-69
3456
5360

query I rowsort
SELECT 81 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT + 42 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

query I rowsort
SELECT - - col0 * 54 * col1 AS col0 FROM tab0 AS cor0
----
111456
183330
437346

query I rowsort
SELECT + 56 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT + 3 + - col1 + - col0 AS col1 FROM tab0 AS cor0
----
-107
-129
-177

query I rowsort
SELECT - 23 + col2 FROM tab1 AS cor0
----
31
34
73

query I rowsort
SELECT - cor0.col2 * col2 + col0 FROM tab0 AS cor0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7553
SELECT + 27 * col0 DIV col2 AS col2 FROM tab1 AS cor0
----
1
22
30

skipif mysql # not compatible
query I rowsort label-7553
SELECT + 27 * col0 / col2 AS col2 FROM tab1 AS cor0
----
1
22
30

query I rowsort
SELECT - col2 * 65 + + col1 * + col1 + 72 FROM tab0 AS cor0
----
3023
5323
9416

query I rowsort
SELECT + 93 + - ( col1 ) FROM tab1 AS cor0
----
67
80
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7556
SELECT col2 + + col2 DIV col1 AS col0 FROM tab1 cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-7556
SELECT col2 + + col2 / col1 AS col0 FROM tab1 cor0
----
103
56
62

query I rowsort
SELECT + col0 + - ( col2 ) - - col2 AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT - 96 + col2 FROM tab2
----
-58
-69
-70

query I rowsort
SELECT ALL col1 + tab2.col2 FROM tab2
----
55
58
85

query I rowsort
SELECT 82 * + col2 AS col2 FROM tab1
----
4428
4674
7872

query I rowsort
SELECT - 55 * - col0 AS col1 FROM tab0
----
1320
1925
4895

query I rowsort
SELECT DISTINCT 71 AS col0 FROM tab1
----
71

query IIIIII rowsort
SELECT * FROM tab1, tab2 cor0 WHERE NOT ( NULL ) = NULL
----

query I rowsort
SELECT + 80 + col2 FROM tab2 AS cor0
----
106
107
118

query I rowsort
SELECT 51 + - 12 FROM tab1
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-7566
SELECT ALL + 70 * 9 + + tab0.col0 DIV + col2 FROM tab0
----
630
631
665

skipif mysql # not compatible
query I rowsort label-7566
SELECT ALL + 70 * 9 + + tab0.col0 / + col2 FROM tab0
----
630
631
665

query I rowsort
SELECT - - 98 + + col2 * cor0.col0 FROM tab0 AS cor0
----
133
7396
890

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7569
SELECT + - col1 DIV - cor0.col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-7569
SELECT + - col1 / - cor0.col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - + cor0.col2 * col1 * - cor0.col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT + + cor0.col1 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT col2 + col1 * - col1 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + + col1 + - col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - col0 * col2 + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + - 35 * - col1 FROM tab0 cor0
----
3010
3185
3395

query I rowsort
SELECT ALL + + 96 + col2 * col2 AS col0 FROM tab0 AS cor0
----
1185
6820
97

query I rowsort
SELECT DISTINCT - 43 FROM tab0 AS cor0
----
-43

query I rowsort
SELECT ALL 97 * - col0 FROM tab2 AS cor0
----
-679
-7566
-7663

onlyif mysql # use DIV operator for integer division
query I rowsort label-7579
SELECT + col1 * - col1 + - cor0.col1 * col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

skipif mysql # not compatible
query I rowsort label-7579
SELECT + col1 * - col1 + - cor0.col1 * col0 / - col0 AS col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL col0 * + col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - + col1 * - col2 + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - col2 * col1 + + col2 * col0 FROM tab2 cor0
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-7583
SELECT DISTINCT 55 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-7583
SELECT DISTINCT 55 / - col0 AS col0 FROM tab0 AS cor0
----
-1
-2
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7584
SELECT - + 7 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7584
SELECT - + 7 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 + + col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7586
SELECT col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-7586
SELECT col0 / - col2 AS col0 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT ALL + col2 + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + 35 * col2 + + col0 FROM tab1 AS cor0
----
1893
2059
3440

query I rowsort
SELECT ALL + col0 + - col2 * + col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT 86 * col2 * cor0.col1 FROM tab0 AS cor0
----
244068
641732
8342

query I rowsort
SELECT ALL + col0 - - col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT - + col0 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col1 * col1 FROM tab1 cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col0 * cor0.col1 col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + col0 + + 48 * col0 * cor0.col1 AS col0 FROM tab2 AS cor0
----
10423
220974
64543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7596
SELECT ALL + - col1 + - CAST( 39 AS SIGNED ) FROM tab1 AS cor0
----
-49
-52
-65

skipif mysql # not compatible
query I rowsort label-7596
SELECT ALL + - col1 + - CAST ( 39 AS INTEGER ) FROM tab1 AS cor0
----
-49
-52
-65

query I rowsort
SELECT + 57 - col1 FROM tab2 AS cor0
----
-2
26
40

query I rowsort
SELECT DISTINCT - - col0 + cor0.col1 AS col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT col0 * col0 + + col1 AS col0 FROM tab2 cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7600
SELECT ALL 42 DIV ( - col0 ) AS col1 FROM tab2 AS cor0
----
-6
0
0

skipif mysql # not compatible
query I rowsort label-7600
SELECT ALL 42 / ( - col0 ) AS col1 FROM tab2 AS cor0
----
-6
0
0

query I rowsort
SELECT - col0 * col0 + col1 AS col2 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT cor1.col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - col2 + 92 FROM tab2 AS cor0
----
54
65
66

query I rowsort
SELECT ALL - - 95 + + col1 AS col1 FROM tab0 AS cor0
----
181
186
192

query I rowsort
SELECT + col0 * col1 + col2 AS col2 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7606
SELECT DISTINCT + CAST( col2 AS SIGNED ) - - col2 FROM tab2 AS cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort label-7606
SELECT DISTINCT + CAST ( col2 AS INTEGER ) - - col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL + 88 * col2 - - cor0.col1 * - col0 FROM tab0 AS cor0
----
-3307
-883
840

query I rowsort
SELECT 13 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
30
44
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor1.col1 col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL cor1.col0 * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 6a95e15f430b2932fa5393d3187190ee

onlyif mysql # use DIV operator for integer division
query I rowsort label-7611
SELECT 9 DIV + 71 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7611
SELECT 9 / + 71 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL - 29 + + 58 * col0 AS col0 FROM tab2 AS cor0
----
377
4495
4553

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + col2 * + col1 * col0 AS col1 FROM tab2 cor0
----
121186
51680
6696

query I rowsort
SELECT - col1 * 33 AS col0 FROM tab0 AS cor0
----
-2838
-3003
-3201

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * cor0.col2 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + col2 + - 3 FROM tab1 AS cor0
----
51
54
93

query I rowsort
SELECT ALL + col1 * 63 + - col1 * col1 FROM tab1 AS cor0
----
530
650
962

query I rowsort
SELECT ALL + col2 * 35 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT cor0.col2 * - ( - 23 ) FROM tab1 cor0
----
1242
1311
2208

query I rowsort
SELECT ALL col2 * 98 FROM tab0 AS cor0
----
3234
8036
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7622
SELECT + - col0 DIV 94 + 64 + + col1 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-7332
-8217
-9345

skipif mysql # not compatible
query I rowsort label-7622
SELECT + - col0 / 94 + 64 + + col1 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-7332
-8217
-9345

query I rowsort
SELECT DISTINCT + - col0 + + 69 FROM tab1 AS cor0
----
-11
5
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col0 + + col0 col0 FROM tab0
----
105
267
72

query I rowsort
SELECT DISTINCT col0 * - tab2.col0 + col0 AS col0 FROM tab2
----
-42
-6006
-6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 col2 FROM tab1
----
68
68
68

query I rowsort
SELECT - col1 * col2 + col0 FROM tab1
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-7628
SELECT - tab2.col0 + + col0 DIV + col0 AS col0 FROM tab2
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-7628
SELECT - tab2.col0 + + col0 / + col0 AS col0 FROM tab2
----
-6
-77
-78

query I rowsort
SELECT DISTINCT + ( + tab0.col0 ) * + ( + col1 ) * - col1 + - tab0.col1 * - col2 AS col1 FROM tab0
----
-174666
-329218
-729547

query I rowsort
SELECT DISTINCT + - 48 FROM tab1, tab0, tab2 AS cor0
----
-48

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab0, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT 41 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 0733f496a5445ffeac9d19797afe4831

query I rowsort
SELECT + col1 + - ( + col1 + col2 ) AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col2 + - 11 * - col1 AS col0 FROM tab2
----
149
314
623

query I rowsort
SELECT ALL + - cor0.col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col1 + col2 AS col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL cor0.col2 * cor0.col2 + - col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT cor0.col0 * 80 AS col0 FROM tab1 AS cor0
----
240
5120
6400

query I rowsort
SELECT DISTINCT - cor0.col1 AS col2 FROM tab2, tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col1 * - col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL 78 + col0 * 22 FROM tab0 AS cor0
----
2036
606
848

query I rowsort
SELECT ALL + col0 + col2 * col0 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT - col2 + 99 * col0 AS col0 FROM tab0 AS cor0
----
2343
3464
8729

query I rowsort
SELECT ALL - ( col2 ) AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - + 71 * col1 AS col1 FROM tab0 AS cor0
----
-6106
-6461
-6887

query I rowsort
SELECT DISTINCT + 55 * - col2 FROM tab1 AS cor0
----
-2970
-3135
-5280

onlyif mysql # use DIV operator for integer division
query I rowsort label-7647
SELECT ALL - 55 DIV col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7647
SELECT ALL - 55 / col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + ( col0 ) * col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - col2 + col2 * col0 AS col0 FROM tab1
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 + - col0 col1 FROM tab1 cor0
----
-102
-25
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7651
SELECT ALL + cor0.col1 + - col0 / CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7651
SELECT ALL + cor0.col1 + - col0 / CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 26 AS col0 FROM tab0 AS cor0
----
26
26
26

query I rowsort
SELECT ALL + 68 AS col0 FROM tab0 cor0
----
68
68
68

query I rowsort
SELECT + 41 - + col1 AS col1 FROM tab0 AS cor0
----
-45
-50
-56

query I rowsort
SELECT ALL + col1 * + col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT col0 + - col1 + col0 FROM tab1 cor0
----
-20
118
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-7658
SELECT DISTINCT - + 73 + col0 DIV 43 FROM tab0 cor0
----
-71
-73

skipif mysql # not compatible
query I rowsort label-7658
SELECT DISTINCT - + 73 + col0 / 43 FROM tab0 cor0
----
-71
-73

query I rowsort
SELECT DISTINCT 48 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
48

query I rowsort
SELECT 79 AS col1 FROM tab2
----
79
79
79

query I rowsort
SELECT DISTINCT - 77 * col2 * ( col1 ) + + col0 + ( cor0.col2 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
-217710
-567187
-7399

query I rowsort
SELECT ALL + 20 FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT + - cor0.col1 * - col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - col2 + col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT ALL - - col1 * - col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col1 * + col1 + + cor0.col2 + - ( - col2 ) * - cor0.col1 FROM tab2 AS cor0
----
-1771
-4989
-897

query I rowsort
SELECT + + col2 + cor0.col1 + 43 AS col2 FROM tab2 AS cor0
----
101
128
98

query I rowsort
SELECT DISTINCT + col1 + - ( 14 + - col1 ) * col1 AS col1 FROM tab0 AS cor0
----
6278
7098
8148

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + + col1 * + ( col0 ) + - col1 + ( col0 ) FROM tab2 AS cor0
----
1405
193
4621

query I rowsort
SELECT col0 + + ( 16 ) FROM tab0 cor0
----
105
40
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7672
SELECT - col1 * - col1 + - col0 DIV - col2 FROM tab1 AS cor0
----
101
169
676

skipif mysql # not compatible
query I rowsort label-7672
SELECT - col1 * - col1 + - col0 / - col2 FROM tab1 AS cor0
----
101
169
676

query I rowsort
SELECT - col0 - cor0.col1 * col2 * - col1 AS col2 FROM tab1 AS cor0
----
16144
36501
5636

onlyif mysql # use DIV operator for integer division
query I rowsort label-7674
SELECT + col2 DIV col1 - col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7674
SELECT + col2 / col1 - col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT 95 + ( col0 ) * col1 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-22736
-271423
-6632

query I rowsort
SELECT - cor0.col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT 1 + col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT ALL + 14 FROM tab0, tab0 cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT DISTINCT + + 11 * 54 AS col0 FROM tab2 AS cor0
----
594

query I rowsort
SELECT DISTINCT + - col1 - - col1 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - col2 + - 39 AS col0 FROM tab2 cor0
----
-65
-66
-77

query I rowsort
SELECT 87 + + 83 AS col1 FROM tab2
----
170
170
170

query I rowsort
SELECT ( 24 ) FROM tab0
----
24
24
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col1 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + col1 + + col1 * - col1 AS col1 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT 83 + - col0 FROM tab2
----
4
5
76

query I rowsort
SELECT DISTINCT + ( + ( col0 ) + 30 ) * - tab2.col2 FROM tab2
----
-2808
-4142
-999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7689
SELECT CAST( + 41 + col0 AS SIGNED ) FROM tab2
----
119
120
48

skipif mysql # not compatible
query I rowsort label-7689
SELECT CAST ( + 41 + col0 AS INTEGER ) FROM tab2
----
119
120
48

query I rowsort
SELECT col2 * - col2 + - col2 AS col1 FROM tab2
----
-1482
-702
-756

query I rowsort
SELECT 83 FROM tab2
----
83
83
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * ( + col2 * ( 49 ) ) col1 FROM tab1
----
27930
61152
68796

query I rowsort
SELECT - cor0.col1 * - 94 + col1 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT ALL + col1 + col0 + - col2 * + col2 AS col1 FROM tab2
----
-1348
-539
-691

query I rowsort
SELECT DISTINCT - col1 + col0 * col1 FROM tab0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col0 col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - col1 ) + - col2 col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT 45 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ALL + 71 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to 39b7515708f32e28b7b5a1bfec0df356

query I rowsort
SELECT ALL + 19 + col1 FROM tab1 cor0
----
29
32
45

query I rowsort
SELECT ALL - - 0 * - col2 + + 68 AS col0 FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT + cor0.col2 + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + col1 + col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7704
SELECT DISTINCT col1 DIV - col0 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-7704
SELECT DISTINCT col1 / - col0 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT cor0.col1 + col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + 60 * col2 FROM tab1 cor0
----
3240
3420
5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7707
SELECT - col0 DIV + col1 + ( - col1 * + col0 + col1 ) FROM tab2 AS cor0
----
-1330
-186
-4544

skipif mysql # not compatible
query I rowsort label-7707
SELECT - col0 / + col1 + ( - col1 * + col0 + col1 ) FROM tab2 AS cor0
----
-1330
-186
-4544

query I rowsort
SELECT 7 FROM tab2
----
7
7
7

query I rowsort
SELECT DISTINCT + col2 * col2 * tab0.col0 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL + 74 * tab2.col2 AS col1 FROM tab2
----
1924
1998
2812

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT DISTINCT + tab0.col0 * cor0.col0 * 50 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to b85bfddf74f45662d9957189a60e8e55

query I rowsort
SELECT tab1.col0 * - col0 * + col0 AS col2 FROM tab1
----
-262144
-27
-512000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + col1 col0 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT col0 * - col1 * + col1 AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT - col0 - - col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT - + col2 * + col0 - + col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT col2 - - col1 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col2 * - ( 46 + cor0.col0 ) FROM tab0 AS cor0
----
-11070
-2310
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 - 41 col0 FROM tab1 AS cor0
----
-203
-3689
-7721

query I rowsort
SELECT ALL 54 * + col0 FROM tab2
----
378
4212
4266

query I rowsort
SELECT cor0.col0 * + 76 FROM tab1, tab1 AS cor0
----
9 values hashing to 178b3e0ee15057d04451026d55623cc0

query I rowsort
SELECT tab1.col1 AS col2 FROM tab2, tab0, tab0 AS cor0, tab1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

onlyif mysql # use DIV operator for integer division
query I rowsort label-7724
SELECT DISTINCT + col1 DIV col1 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-7724
SELECT DISTINCT + col1 / col1 AS col0 FROM tab0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7725
SELECT DISTINCT - - col2 DIV + 58 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7725
SELECT DISTINCT - - col2 / + 58 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT 5 FROM tab2, tab0 cor0
----
5

query I rowsort
SELECT col0 + col1 * + ( col0 ) FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - col2 + - 33 + + 73 AS col1 FROM tab1 cor0
----
-14
-17
-56

query I rowsort
SELECT + - cor0.col2 * cor0.col0 * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 45 ) col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT + col0 * col1 AS col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-7733
SELECT + col0 DIV col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7733
SELECT + col0 / col0 FROM tab2
----
1
1
1

query I rowsort
SELECT - 89 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( col0 ) col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 8 * cor0.col1 FROM tab1 AS cor0
----
104
208
80

query I rowsort
SELECT ALL - 6 + cor0.col2 FROM tab0 cor0
----
-5
27
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7738
SELECT DISTINCT - col2 * 92 - col0 DIV 58 FROM tab0 AS cor0
----
-3036
-7545
-92

skipif mysql # not compatible
query I rowsort label-7738
SELECT DISTINCT - col2 * 92 - col0 / 58 FROM tab0 AS cor0
----
-3036
-7545
-92

query I rowsort
SELECT DISTINCT - 7 * col0 FROM tab0 AS cor0
----
-168
-245
-623

query I rowsort
SELECT ALL + + col2 * + col0 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT tab0.col2 * col2 - + col1 * col0 FROM tab0
----
-1375
-3394
-975

query I rowsort
SELECT + col0 + ( col1 ) - + col2 * - col2 AS col2 FROM tab1
----
2945
3323
9309

query I rowsort
SELECT col1 * tab0.col0 + - col1 + col0 FROM tab0
----
2002
3333
8097

query I rowsort
SELECT - col0 + + col0 AS col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7746
SELECT col2 * + col0 - + col1 DIV ( - col1 ) col0 FROM tab1
----
163
3649
7681

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7746
SELECT col2 * + col0 - + col1 / ( - col1 ) col0 FROM tab1
----
163
3649
7681

query I rowsort
SELECT 20 FROM tab0
----
20
20
20

query I rowsort
SELECT DISTINCT + tab1.col2 * + col2 + col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT ALL + 21 AS col1 FROM tab0 cor0
----
21
21
21

query I rowsort
SELECT DISTINCT cor0.col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + 52 FROM tab0 AS cor0
----
52
52
52

query I rowsort
SELECT - 73 + col2 * col1 AS col0 FROM tab0 AS cor0
----
24
2765
7389

query I rowsort
SELECT DISTINCT 38 * - col1 AS col1 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT ALL + ( 89 ) + + cor0.col1 * col2 FROM tab0 cor0
----
186
2927
7551

query I rowsort
SELECT + 23 + - col1 * col1 FROM tab1 AS cor0
----
-146
-653
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7756
SELECT + col0 DIV col0 - col0 * col0 AS col1 FROM tab0 AS cor0
----
-1224
-575
-7920

skipif mysql # not compatible
query I rowsort label-7756
SELECT + col0 / col0 - col0 * col0 AS col1 FROM tab0 AS cor0
----
-1224
-575
-7920

query I rowsort
SELECT - 33 + ( - col0 * 77 ) + - col0 FROM tab2 AS cor0
----
-579
-6117
-6195

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7758
SELECT + 52 * - col2 - CAST( + 93 AS SIGNED ) * + col2 FROM tab0
----
-11890
-145
-4785

skipif mysql # not compatible
query I rowsort label-7758
SELECT + 52 * - col2 - CAST ( + 93 AS INTEGER ) * + col2 FROM tab0
----
-11890
-145
-4785

query I rowsort
SELECT + + cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - - 15 AS col2 FROM tab2 cor0
----
15
15
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7761
SELECT + ( col2 ) * CAST( cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7761
SELECT + ( col2 ) * CAST ( cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7762
SELECT + cor0.col0 DIV + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7762
SELECT + cor0.col0 / + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT col1 + 7 FROM tab0 AS cor0
----
104
93
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7764
SELECT DISTINCT col0 + 36 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
78
8
81

skipif mysql # not compatible
query I rowsort label-7764
SELECT DISTINCT col0 + 36 / cor0.col1 AS col1 FROM tab2 AS cor0
----
78
8
81

query I rowsort
SELECT + - col1 + + cor0.col2 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7766
SELECT DISTINCT + + col1 DIV - 63 + col2 AS col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-7766
SELECT DISTINCT + + col1 / - 63 + col2 AS col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT DISTINCT + + col2 + col0 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

query I rowsort
SELECT ALL - col2 * col0 + + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + col2 + - col0 FROM tab2 AS cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * - col1 - col0 * + col0 col0 FROM tab1 AS cor0
----
-3456
-5360
69

query I rowsort
SELECT col1 + col2 * + col2 FROM tab2 cor0
----
1461
735
760

query I rowsort
SELECT ALL - - col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 * col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-7776
SELECT ALL col0 DIV - col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7776
SELECT ALL col0 / - col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7777
SELECT ALL + cor0.col1 + col0 DIV col0 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-7777
SELECT ALL + cor0.col1 + col0 / col0 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT DISTINCT + tab1.col1 + - col1 * - col1 * - tab1.col0 AS col0 FROM tab1
----
-13507
-2002
-6390

query I rowsort
SELECT col2 + + col1 * col0 AS col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL + - cor0.col2 + col2 * col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT col1 * + col0 - - col1 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + cor0.col2 + + cor0.col1 * col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL - col1 * + col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - cor0.col0 + - col0 - - col0 * + cor0.col0 AS col0 FROM tab1 cor0
----
3
3968
6240

query I rowsort
SELECT + + col0 + - col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT col1 - col2 AS col2 FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + cor0.col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - cor0.col1 * - col1 AS col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-7791
SELECT ALL - col2 DIV + cor0.col2 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7791
SELECT ALL - col2 / + cor0.col2 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL col2 * + col1 - col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT - col2 - + col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT tab2.col2 * - col0 AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT col1 + col2 AS col2 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7796
SELECT DISTINCT + col0 + - col0 DIV col2 FROM tab1
----
3
63
80

skipif mysql # not compatible
query I rowsort label-7796
SELECT DISTINCT + col0 + - col0 / col2 FROM tab1
----
3
63
80

query I rowsort
SELECT DISTINCT - col0 * - col0 * col0 + - col1 AS col2 FROM tab2
----
312
474493
493022

query I rowsort
SELECT col2 * col0 + + tab2.col0 AS col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-7799
SELECT tab2.col0 DIV - col1 + tab2.col2 * col0 * col1 AS col0 FROM tab2
----
119651
51030
5859

skipif mysql # not compatible
query I rowsort label-7799
SELECT tab2.col0 / - col1 + tab2.col2 * col0 * col1 AS col0 FROM tab2
----
119651
51030
5859

query I rowsort
SELECT DISTINCT col2 + - col0 AS col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL + col1 + cor0.col0 * col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + - cor0.col1 + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + 95 AS col1 FROM tab2
----
95

query I rowsort
SELECT + col2 - col1 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL col1 + - col0 + + col1 FROM tab0
----
148
159
93

query I rowsort
SELECT - col2 + col0 AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT tab0.col0 * + col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7808
SELECT col2 DIV tab1.col1 - col0 * - tab1.col0 FROM tab1
----
11
4101
6407

skipif mysql # not compatible
query I rowsort label-7808
SELECT col2 / tab1.col1 - col0 * - tab1.col0 FROM tab1
----
11
4101
6407

query I rowsort
SELECT - - cor0.col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT col2 + - tab1.col2 AS col0 FROM tab1 WHERE NOT NULL IN ( col1 ) AND NULL NOT IN ( + col2 )
----

query I rowsort
SELECT DISTINCT col0 * + col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT col2 * col1 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - tab1.col1 * col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT tab1.col2 + col1 * + col0 FROM tab1
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col1 col2 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 * + col0 col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT - tab2.col0 - col2 * col2 AS col0 FROM tab2
----
-1523
-736
-754

query I rowsort
SELECT - col0 + col0 FROM tab2 WHERE NOT ( NULL ) = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + tab2.col2 col2 FROM tab2
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 col0 FROM tab1 WHERE NOT ( NULL ) BETWEEN col2 AND ( NULL )
----

query III rowsort
SELECT * FROM tab0 WHERE NULL BETWEEN col2 * col0 AND NULL
----

query I rowsort
SELECT ALL - col2 + - col2 AS col2 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT DISTINCT tab2.col1 + - col2 * col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT - + col2 + col2 * - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-7825
SELECT DISTINCT + col1 DIV col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7825
SELECT DISTINCT + col1 / col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - ( cor0.col0 ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL 1 AS col2 FROM tab1
----
1
1
1

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab2 AS cor0, tab1 AS cor1
----
972 values hashing to 75a813ebd5ec5ec2e67a66d0593ff763

query I rowsort
SELECT + 63 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT - col1 / tab0.col1 FROM tab0 WHERE NOT col2 < col0 * col2 + col1
----

query I rowsort
SELECT DISTINCT col0 + + col1 / col2 FROM tab1 WHERE ( + col0 ) >= ( NULL )
----

query I rowsort
SELECT ALL - col1 * - col1 - col1 FROM tab1
----
156
650
90

query I rowsort
SELECT ALL - col2 * - col0 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + col1 * - tab2.col1 AS col0 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT col1 * - tab1.col0 FROM tab1 WHERE NOT NULL IN ( + col1 * col0 + col0 / col0 )
----

query I rowsort
SELECT ALL col2 - - col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT + col1 FROM tab2 AS cor0 WHERE NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL - cor0.col1 + - col1 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT - col2 - col2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT col0 * col1 - col2 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7841
SELECT DISTINCT col0 * cor0.col0 DIV cor0.col0 + col2 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-7841
SELECT DISTINCT col0 * cor0.col0 / cor0.col0 + col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7842
SELECT col2 + - col1 DIV - col1 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-7842
SELECT col2 + - col1 / - col1 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT col1 + + col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL + col0 + col1 AS col2 FROM tab1 AS cor0 WHERE NOT NULL BETWEEN - cor0.col1 AND col2 * col2 + col2 - cor0.col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col0 + - col0 col2 FROM tab1 cor0
----
-165
-3712
-7760

query I rowsort
SELECT ALL + col1 * - tab1.col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - col1 * tab2.col0 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col1 * col2 AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - col2 / col0 FROM tab0 WHERE NULL BETWEEN ( + col1 ) AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7850
SELECT + tab0.col1 DIV col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7850
SELECT + tab0.col1 / col1 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7851
SELECT ALL - col1 DIV col2 - col2 * - col2 FROM tab0
----
-96
1087
6723

skipif mysql # not compatible
query I rowsort label-7851
SELECT ALL - col1 / col2 - col2 * - col2 FROM tab0
----
-96
1087
6723

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) > NULL
----

query I rowsort
SELECT ALL + col2 * - tab2.col1 - + col2 FROM tab2
----
-1560
-684
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7854
SELECT DISTINCT col0 * col1 DIV + col2 - col0 * - col0 AS col2 FROM tab0
----
4620
638
8019

skipif mysql # not compatible
query I rowsort label-7854
SELECT DISTINCT col0 * col1 / + col2 - col0 * - col0 AS col2 FROM tab0
----
4620
638
8019

query I rowsort
SELECT - col2 + - col1 * col1 AS col2 FROM tab0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL - col2 * col0 * - col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT - tab1.col2 * col2 * col1 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT - col1 * col0 AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL tab0.col2 * col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + col1 + + col2 * col1 * - col2 AS col1 FROM tab0
----
-611793
-93568
0

query I rowsort
SELECT col2 + - col0 * col0 - tab0.col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT col2 * col0 * - col2 + - col1 + - col2 * + col1 FROM tab1
----
-10178
-208516
-738541

query I rowsort
SELECT DISTINCT col0 * - col0 AS col1 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT col2 * - col0 + col2 + tab0.col2 FROM tab0
----
-33
-7134
-726

query I rowsort
SELECT ALL col2 * tab0.col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL + col1 * col0 * col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT ALL - + 58 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT - cor0.col0 + - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT cor0.col2 - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + 91 * col2 + col0 AS col2 FROM tab1 AS cor0
----
4917
5251
8816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7871
SELECT ALL col0 - + col1 DIV + col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7871
SELECT ALL col0 - + col1 / + col2 FROM tab1
----
3
64
80

query I rowsort
SELECT + col2 + - 4 * - col2 AS col0 FROM tab1 AS cor0
----
270
285
480

query I rowsort
SELECT ALL + tab2.col2 + 94 + - tab2.col1 AS col1 FROM tab2
----
115
61
90

query I rowsort
SELECT DISTINCT + + col0 + 0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col0 + col1 * - col1 FROM tab1 AS cor0
----
-36
-673
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col0 + + col2 + cor0.col1 col1 FROM tab0 cor0
----
-1945
-3297
-7926

query I rowsort
SELECT 12 + - cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 6d516d261b36b9c2e7c4f4adeca8cbf5

query I rowsort
SELECT - + col1 + - col0 + col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + 98 col2 FROM tab0
----
184
189
195

query I rowsort
SELECT DISTINCT + ( + 97 ) AS col0 FROM tab2
----
97

query I rowsort
SELECT cor0.col2 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 36 col0 FROM tab2, tab0, tab0 AS cor0, tab0 AS cor1
----
81 values hashing to e09b197365a04fabbaaf0718d2ae88c5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 54 col2 FROM tab0 cor0
----
-54
-54
-54

query I rowsort
SELECT - ( ( - col1 ) ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - + col2 * - col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL col1 + - col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - - 1 * + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - 85 AS col2 FROM tab0 AS cor0
----
-85
-85
-85

query I rowsort
SELECT DISTINCT 91 FROM tab2, tab2 AS cor0
----
91

query I rowsort
SELECT ALL 83 AS col0 FROM tab2
----
83
83
83

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 + - ( 42 ) FROM tab0 cor0
----
2796
55
7420

query I rowsort
SELECT - cor0.col2 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col0 ) col2 FROM tab0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7894
SELECT DISTINCT - CAST( NULL AS SIGNED ) + 68 FROM tab2, tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7894
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 68 FROM tab2, tab0, tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 88 AS col2 FROM tab1, tab1 AS cor0
----
88

query I rowsort
SELECT + + cor0.col2 * cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + + cor0.col0 + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT 0 * + col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 88 + + cor0.col2 FROM tab0 AS cor0
----
-55
-6
-87

query I rowsort
SELECT + 41 + tab1.col2 * - col1 * - 33 FROM tab1
----
18851
41225
46373

query I rowsort
SELECT 61 FROM tab1
----
61
61
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - cor0.col2 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 75 FROM tab0, tab2 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT - 24 AS col2 FROM tab0 AS cor0
----
-24
-24
-24

query I rowsort
SELECT + + 78 AS col2 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT ALL + 53 * cor0.col0 * - 43 + col0 + cor0.col0 * - col1 FROM tab2 AS cor0
----
-16163
-181305
-182286

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7907
SELECT ALL - 96 / cor0.col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7907
SELECT ALL - 96 / cor0.col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 37 FROM tab2 AS cor0
----
37
37
37

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab2 AS cor1, tab1, tab0 cor2
----
3645 values hashing to 95cc5fe1844e2fb00b447bbee94ccc5e

query I rowsort
SELECT DISTINCT col0 * ( + col1 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col2 * + 10 FROM tab0 AS cor0
----
10
330
820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7912
SELECT col2 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7912
SELECT col2 + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + tab2.col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7914
SELECT col2 + tab0.col2 DIV col2 AS col0 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-7914
SELECT col2 + tab0.col2 / col2 AS col0 FROM tab0
----
2
34
83

query I rowsort
SELECT col1 * + col1 - - col0 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT - col0 + - 87 * - col1 AS col2 FROM tab2 AS cor0
----
1400
2690
5055

query I rowsort
SELECT DISTINCT col1 + - col0 * - col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + - col2 * - cor0.col0 - - col1 * - col2 AS col1 FROM tab0 cor0
----
-164
-2046
-62

query I rowsort
SELECT + - cor0.col1 + + col0 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7920
SELECT DISTINCT + col0 DIV ( + 92 ) + col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7920
SELECT DISTINCT + col0 / ( + 92 ) + col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - col2 * col2 + + col1 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7922
SELECT DISTINCT - col2 * + CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-7922
SELECT DISTINCT - col2 * + CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT 74 AS col2 FROM tab0
----
74

query I rowsort
SELECT tab1.col0 + - col2 * - 98 FROM tab1
----
5295
5650
9488

query I rowsort
SELECT DISTINCT - 77 AS col1 FROM tab2
----
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7926
SELECT DISTINCT + 26 DIV - tab2.col1 col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7926
SELECT DISTINCT + 26 / - tab2.col1 col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
-1
0

query I rowsort
SELECT - col1 + - col2 * + col1 * 53 AS col1 FROM tab2
----
-34255
-44392
-81361

onlyif mysql # use DIV operator for integer division
query I rowsort label-7928
SELECT + col0 DIV + 50 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7928
SELECT + col0 / + 50 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT ALL - col0 + - col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT col2 * - col0 + + col1 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( ( - col0 ) AS REAL ) + + 94 AS col1 FROM tab1 AS cor0
----
14
30
91

query I rowsort
SELECT - + 13 FROM tab2 AS cor0
----
-13
-13
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * + ( cor0.col2 * col0 ) col2 FROM tab1 AS cor0
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 + col0 col1 FROM tab0 cor0
----
115
50
61

query I rowsort
SELECT DISTINCT ( + 65 ) * + col2 FROM tab2 cor0
----
1690
1755
2470

query I rowsort
SELECT DISTINCT 70 FROM tab2 AS cor0
----
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7937
SELECT + col1 DIV + col1 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7937
SELECT + col1 / + col1 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT + 27 + col1 FROM tab0 AS cor0
----
113
118
124

query I rowsort
SELECT ALL + col2 * - col0 + - cor0.col0 * cor0.col0 + + col2 FROM tab0 AS cor0
----
-1259
-1335
-15137

query I rowsort
SELECT - col0 * 31 AS col2 FROM tab1
----
-1984
-2480
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col2 + + col0 col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT + col1 * col0 * - col0 AS col2 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT - 6 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

query I rowsort
SELECT tab1.col2 * ( col2 * - col2 ) FROM tab1
----
-157464
-185193
-884736

query I rowsort
SELECT + tab2.col2 * col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT col0 * + 16 * col0 AS col1 FROM tab1
----
102400
144
65536

query I rowsort
SELECT + tab0.col2 - - 86 FROM tab0
----
119
168
87

query I rowsort
SELECT 25 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
243 values hashing to 60bd71ee2159222231bb3b5819bc5dca

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col2 col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( col1 + 26 ) col1 FROM tab2 AS cor0
----
26
26
26

query I rowsort
SELECT - ( - col0 ) * col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 24 AS col0 FROM tab1 AS cor0
----
24
24
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7954
SELECT CAST( NULL AS SIGNED ) + col1 * tab0.col1 * ( 57 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7954
SELECT CAST ( NULL AS INTEGER ) + col1 * tab0.col1 * ( 57 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * 12 + col2 FROM tab0 cor0
----
-255
-419
-986

query I rowsort
SELECT + col2 + col2 FROM tab1
----
108
114
192

query I rowsort
SELECT col0 + + col2 * col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL - + cor0.col1 * - col1 FROM tab0 AS cor0
----
7396
8281
9409

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to fa0488bdae83f58c7ffa92505e928570

query I rowsort
SELECT DISTINCT - 50 + + cor0.col1 AS col0 FROM tab1, tab2 AS cor0
----
-19
-33
9

query I rowsort
SELECT - col2 * 77 FROM tab0 AS cor0
----
-2541
-6314
-77

query I rowsort
SELECT ALL col0 + ( col0 + + col0 ) * ( ( col1 ) ) AS col1 FROM tab1 AS cor0
----
1344
159
2160

query I rowsort
SELECT DISTINCT + 80 FROM tab1, tab0 AS cor0
----
80

query I rowsort
SELECT ALL col0 * tab1.col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL - - 90 AS col0 FROM tab1 AS cor0
----
90
90
90

query I rowsort
SELECT DISTINCT + + ( 41 ) + - col2 AS col2 FROM tab0 AS cor0
----
-41
40
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7967
SELECT DISTINCT + CAST( NULL AS DECIMAL ) * + 16 + - col0 * - col0 col2 FROM tab2 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7967
SELECT DISTINCT + CAST ( NULL AS REAL ) * + 16 + - col0 * - col0 col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL col1 * - col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - 23 AS col2 FROM tab1 AS cor0
----
-23
-23
-23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7970
SELECT - + ( col2 ) + col1 * - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7970
SELECT - + ( col2 ) + col1 * - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 69 AS col2 FROM tab2 AS cor0
----
69
69
69

query I rowsort
SELECT ALL - ( col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) col0 FROM tab1 cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7974
SELECT DISTINCT + + cor0.col2 + - col0 * - col1 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7974
SELECT DISTINCT + + cor0.col2 + - col0 * - col1 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( col0 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + col2 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 * - col2 col2 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT - col0 * col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT + - cor0.col0 * - col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT 46 FROM tab0 AS cor0
----
46
46
46

query I rowsort
SELECT DISTINCT - 78 FROM tab2 AS cor0
----
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7982
SELECT 39 DIV col0 + + col2 + 46 AS col2 FROM tab0 AS cor0
----
128
48
80

skipif mysql # not compatible
query I rowsort label-7982
SELECT 39 / col0 + + col2 + 46 AS col2 FROM tab0 AS cor0
----
128
48
80

query I rowsort
SELECT - - 51 FROM tab0 AS cor0
----
51
51
51

query I rowsort
SELECT - - 13 + + col1 * col1 + cor0.col0 FROM tab1 AS cor0
----
177
262
692

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col2 col1 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + cor0.col0 * 48 col2 FROM tab0 AS cor0
----
1680
350304
38016

query I rowsort
SELECT DISTINCT - + ( col0 ) + 9 AS col2 FROM tab0 AS cor0
----
-15
-26
-80

query I rowsort
SELECT ( - col2 ) * - ( - 9 ) + + col1 FROM tab2 AS cor0
----
-175
-212
-325

query I rowsort
SELECT ALL - - col0 + + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + col1 * col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL col0 * col1 - 54 * 85 FROM tab0 AS cor0
----
-1195
-2526
3509

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + cor0.col1 col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL - col1 * col2 + - col1 AS col2 FROM tab1 cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT + col2 - col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + - 48 FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT ALL col0 + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - 93 * col0 AS col0 FROM tab2 AS cor0
----
-651
-7254
-7347

onlyif mysql # use DIV operator for integer division
query I rowsort label-7998
SELECT + cor0.col0 * + col1 + + 82 DIV 82 AS col0 FROM tab0 cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-7998
SELECT + cor0.col0 * + col1 + + 82 / 82 AS col0 FROM tab0 cor0
----
2065
3396
8100

query I rowsort
SELECT ALL - - 42 AS col0 FROM tab0 AS cor0
----
42
42
42

query I rowsort
SELECT col1 + cor0.col0 AS col1 FROM tab2 cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 52 col2 FROM tab0 AS cor0
----
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8002
SELECT DISTINCT + cor0.col2 + + cor0.col1 * CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
7429
8363
9410

skipif mysql # not compatible
query I rowsort label-8002
SELECT DISTINCT + cor0.col2 + + cor0.col1 * CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + + 48 + col0 AS col1 FROM tab0 AS cor0
----
137
72
83

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 - 35 * col0 FROM tab2 AS cor0
----
-241
-2697
-2786

onlyif mysql # use DIV operator for integer division
query I rowsort label-8005
SELECT ALL col2 DIV + col0 + + col0 FROM tab0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-8005
SELECT ALL col2 / + col0 + + col0 FROM tab0
----
25
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8006
SELECT + 48 * tab0.col1 * + CAST( - 65 AS SIGNED ) AS col1 FROM tab0
----
-268320
-283920
-302640

skipif mysql # not compatible
query I rowsort label-8006
SELECT + 48 * tab0.col1 * + CAST ( - 65 AS INTEGER ) AS col1 FROM tab0
----
-268320
-283920
-302640

query I rowsort
SELECT + 44 AS col1 FROM tab1
----
44
44
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * - ( col0 ) + col0 + - col2 * col0 col1 FROM tab1 AS cor0
----
-237
-4224
-8640

onlyif mysql # use DIV operator for integer division
query I rowsort label-8009
SELECT col1 + + col0 + + 54 DIV - col0 AS col2 FROM tab2 AS cor0
----
137
31
96

skipif mysql # not compatible
query I rowsort label-8009
SELECT col1 + + col0 + + 54 / - col0 AS col2 FROM tab2 AS cor0
----
137
31
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - col2 col1 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-8011
SELECT ALL - col0 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8011
SELECT ALL - col0 / cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 + + CAST ( 42 AS REAL ) FROM tab1 AS cor0
----
16
29
32

query I rowsort
SELECT - + col0 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 + - cor0.col2 * col2 col0 FROM tab2 AS cor0
----
-1499
-761
-787

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT 50 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT ALL tab2.col1 * col0 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8018
SELECT + col1 DIV + col1 + col1 col1 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8018
SELECT + col1 / + col1 + col1 col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT - - col1 + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8020
SELECT col0 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8020
SELECT col0 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 + + 30 * col0 * + col2 + cor0.col1 col1 FROM tab0 AS cor0
----
1112
211733
23054

query I rowsort
SELECT + col0 * + col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1, tab1 cor2
----
3645 values hashing to 028fd38910121a0fa7c5b9a24c207cf0

query I rowsort
SELECT DISTINCT 50 * - 40 AS col2 FROM tab1, tab1 AS cor0
----
-2000

query I rowsort
SELECT ALL + - col0 * - 93 AS col1 FROM tab0 AS cor0
----
2232
3255
8277

query I rowsort
SELECT + - col0 + col0 * - col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT - + ( col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - 76 - + col1 FROM tab1 AS cor0
----
-102
-86
-89

query I rowsort
SELECT - col0 * - col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ( + 85 ) * + tab0.col2 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 8a6bbdecdd24b0062023f0f6c0cac73a

query I rowsort
SELECT 97 * col0 * + col0 FROM tab1
----
397312
620800
873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + tab2.col0 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + col2 * - tab0.col2 * + col1 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT ALL 46 * col1 * - 85 FROM tab0
----
-336260
-355810
-379270

query I rowsort
SELECT + col0 * - col1 * - 47 AS col1 FROM tab1
----
30080
3666
48880

query I rowsort
SELECT + ( + col0 ) * 5 + cor0.col1 * col0 + cor0.col0 * - col0 FROM tab2 AS cor0
----
-1092
-4503
203

onlyif mysql # use DIV operator for integer division
query I rowsort label-8038
SELECT - col2 DIV + col0 + col2 + 79 FROM tab0 AS cor0
----
111
161
80

skipif mysql # not compatible
query I rowsort label-8038
SELECT - col2 / + col0 + col2 + 79 FROM tab0 AS cor0
----
111
161
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * cor0.col2 + - col1 * cor0.col0 + + col2 col2 FROM tab2 AS cor0
----
-1
-2548
1697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + tab2.col1 col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ( - cor0.col0 ) AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL - 64 * col1 FROM tab1 AS cor0
----
-1664
-640
-832

query I rowsort
SELECT + - col0 + - col0 * + ( cor0.col2 ) + col2 FROM tab0 AS cor0
----
-69
-7305
-783

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - 24 AS col0 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT + 91 AS col0 FROM tab2 AS cor0
----
91
91
91

query I rowsort
SELECT - 61 * 58 AS col1 FROM tab1 AS cor0
----
-3538
-3538
-3538

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT DISTINCT - 24 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
-24

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0, tab1 cor1, tab2 AS cor2
----
972 values hashing to f0b9665afa0b835e4e5097af17c51766

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8052
SELECT DISTINCT + CAST( cor0.col0 AS SIGNED ) + + col1 * 75 FROM tab2 AS cor0
----
1354
2332
4503

skipif mysql # not compatible
query I rowsort label-8052
SELECT DISTINCT + CAST ( cor0.col0 AS INTEGER ) + + col1 * 75 FROM tab2 AS cor0
----
1354
2332
4503

query I rowsort
SELECT DISTINCT tab2.col2 * 82 FROM tab2
----
2132
2214
3116

query I rowsort
SELECT - col0 + col0 - col1 * + col1 AS col2 FROM tab1
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 - col1 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 + 80 * - tab1.col1 AS col2 FROM tab1
----
-2077
-736
-960

query I rowsort
SELECT - 16 * - 74 FROM tab1
----
1184
1184
1184

query I rowsort
SELECT + 1 AS col1 FROM tab2
----
1
1
1

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab2 cor1, tab2 AS cor2
----
972 values hashing to f94a4a64ac54a61fc21f78e2b831ebee

query I rowsort
SELECT col2 * - 20 + col0 + col0 FROM tab2
----
-364
-526
-602

query I rowsort
SELECT + col2 * - ( - col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 43 AS col2 FROM tab1
----
-43
-43
-43

query I rowsort
SELECT + 44 AS col1 FROM tab0
----
44
44
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8064
SELECT - col2 * col2 * - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8064
SELECT - col2 * col2 * - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col1 * + col1 ) AS col0 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL 37 FROM tab2
----
37
37
37

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab1, tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + col2 + - 51 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1650
-4100
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-8069
SELECT - cor0.col2 DIV - cor0.col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-8069
SELECT - cor0.col2 / - cor0.col0 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT col2 * col0 - col0 AS col1 FROM tab0
----
0
7209
768

query I rowsort
SELECT + col0 + - col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 * + col0 + - col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT col2 + - 54 FROM tab1 AS cor0
----
0
3
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 32 col2 FROM tab0
----
-32
-32
-32

query I rowsort
SELECT col0 + col1 * + ( - cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * - cor0.col1 col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * col2 + + col1 col0 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL col1 + - ( + 53 ) - + col1 FROM tab2 AS cor0
----
-53
-53
-53

query I rowsort
SELECT + + cor0.col1 + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - 40 + 92 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL - col0 - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT + + col1 + + col0 AS col0 FROM tab1 cor0
----
29
74
93

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 6726a15019c52908f1f1d0df0cd4c1b8

query I rowsort
SELECT ALL + col2 - + 23 AS col2 FROM tab2 AS cor0
----
15
3
4

query I rowsort
SELECT + col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT 29 * + cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 5319314427cff452ca112595a8b96825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8087
SELECT DISTINCT - + CAST( col0 AS SIGNED ) + - col0 * col2 FROM tab2 AS cor0
----
-196
-2106
-3081

skipif mysql # not compatible
query I rowsort label-8087
SELECT DISTINCT - + CAST ( col0 AS INTEGER ) + - col0 * col2 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-8088
SELECT DISTINCT - 67 * + 9 - col0 * col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
-604
-613
-614

skipif mysql # not compatible
query I rowsort label-8088
SELECT DISTINCT - 67 * + 9 - col0 * col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
-604
-613
-614

query I rowsort
SELECT ALL col0 * - col2 AS col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col1 + + col0 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8091
SELECT - col0 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8091
SELECT - col0 / col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8092
SELECT ALL - col2 * col1 + col2 + + col2 DIV col1 FROM tab2 AS cor0
----
-1508
-606
-810

skipif mysql # not compatible
query I rowsort label-8092
SELECT ALL - col2 * col1 + col2 + + col2 / col1 FROM tab2 AS cor0
----
-1508
-606
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + 27 * + 54 FROM tab0 AS cor0
----
1458

query I rowsort
SELECT + 93 AS col0 FROM tab1 AS cor0
----
93
93
93

query I rowsort
SELECT ALL - col2 + 1 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT - ( - col2 ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT col0 + cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - 12 + col0 FROM tab2 AS cor0
----
-5
66
67

query I rowsort
SELECT ALL + - ( col2 ) + - col1 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 75 AS REAL ) AS col2 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT DISTINCT 97 * + ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT DISTINCT + - 76 - col0 AS col1 FROM tab0 AS cor0
----
-100
-111
-165

onlyif mysql # use DIV operator for integer division
query I rowsort label-8104
SELECT ALL + CAST( + col0 AS SIGNED ) DIV col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8104
SELECT ALL + CAST ( + col0 AS INTEGER ) / col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT 90 FROM tab2 AS cor0
----
90
90
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8106
SELECT ALL 7 + - col1 DIV + col1 AS col1 FROM tab0 AS cor0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-8106
SELECT ALL 7 + - col1 / + col1 AS col1 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT 11 - - tab2.col0 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
18
89
90

query I rowsort
SELECT DISTINCT + + 34 * - col0 + - col2 + ( + col0 ) FROM tab2 AS cor0
----
-258
-2600
-2645

query I rowsort
SELECT ALL + + 73 FROM tab1 AS cor0
----
73
73
73

query I rowsort
SELECT ALL - - col0 + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - cor0.col0 + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * - ( col0 ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8113
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + 44 + + col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8113
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + 44 + + col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 56 + + col0 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT col1 * cor0.col1 - - 6 FROM tab2 AS cor0
----
295
3487
967

query I rowsort
SELECT DISTINCT + 0 * - col0 - col1 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL col0 + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - + 35 - - col2 * col0 FROM tab1 AS cor0
----
127
3613
7645

query I rowsort
SELECT DISTINCT - 22 * + col2 - col2 * col0 * col0 FROM tab0 AS cor0
----
-1247
-19734
-651326

query I rowsort
SELECT + col2 + col0 * col0 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8121
SELECT - 26 * + col2 - + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8121
SELECT - 26 * + col2 - + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT 5 * col1 + col2 * col0 FROM tab2 AS cor0
----
2323
3087
344

query I rowsort
SELECT + - col2 * col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - col0 * 76 AS col2 FROM tab2
----
-532
-5928
-6004

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8126
SELECT CAST( - col2 AS SIGNED ) AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8126
SELECT CAST ( - col2 AS INTEGER ) AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + 87 + col0 AS col1 FROM tab1 AS cor0
----
151
167
90

query I rowsort
SELECT col1 - col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + col0 * + 7 AS col1 FROM tab2 AS cor0
----
572
591
76

query I rowsort
SELECT ALL col1 * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 21 AS col2 FROM tab2 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT + 18 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ALL - tab0.col1 + - tab0.col2 * - col2 + - 97 FROM tab0
----
-193
6536
906

query I rowsort
SELECT ( 67 ) * - col2 + ( - col1 ) AS col1 FROM tab0
----
-164
-2297
-5585

query I rowsort
SELECT - cor0.col0 * col0 * + ( 94 ) + col0 AS col2 FROM tab1 AS cor0
----
-384960
-601520
-843

query I rowsort
SELECT 61 AS col0 FROM tab0 AS cor0
----
61
61
61

query I rowsort
SELECT 87 * 15 FROM tab0
----
1305
1305
1305

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 col1 FROM tab0
----
-164
-2
-66

query I rowsort
SELECT col2 + + col1 * ( + col1 ) FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL + - col2 * - cor0.col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT - col1 * + col2 + - ( col2 ) FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT col0 * - col0 * + col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT - 26 AS col2 FROM tab1 AS cor0
----
-26

query I rowsort
SELECT + col1 * + cor0.col0 * 75 FROM tab1 cor0
----
48000
5850
78000

query I rowsort
SELECT DISTINCT - - 19 AS col2 FROM tab2 cor0
----
19

query I rowsort
SELECT DISTINCT + cor0.col2 * - col0 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8147
SELECT ALL + ( - col0 ) * + CAST( - 56 AS SIGNED ) FROM tab2 AS cor0
----
392
4368
4424

skipif mysql # not compatible
query I rowsort label-8147
SELECT ALL + ( - col0 ) * + CAST ( - 56 AS INTEGER ) FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT - 4 + + cor0.col1 FROM tab2 AS cor0
----
13
27
55

query I rowsort
SELECT + - col2 + - col2 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT - col1 * col0 * + ( 2 ) AS col0 FROM tab1 AS cor0
----
-1280
-156
-2080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + - ( + col0 ) FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT 13 + - col2 * + cor0.col2 FROM tab2 AS cor0
----
-1431
-663
-716

query I rowsort
SELECT ALL + - cor0.col1 + - col1 * - ( + col0 ) AS col0 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-8156
SELECT ALL - col0 DIV cor0.col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-8156
SELECT ALL - col0 / cor0.col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT DISTINCT + col2 * - col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col0 + col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - 23 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT ALL + col2 * + col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - + cor0.col2 + - ( col1 + col1 ) AS col1 FROM tab1 AS cor0
----
-106
-122
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-8162
SELECT DISTINCT - col1 DIV + 54 - col0 * col0 * - ( + col1 ) FROM tab0 AS cor0
----
118824
49535
720810

skipif mysql # not compatible
query I rowsort label-8162
SELECT DISTINCT - col1 / + 54 - col0 * col0 * - ( + col1 ) FROM tab0 AS cor0
----
118824
49535
720810

query I rowsort
SELECT DISTINCT - + col2 * - 74 + - col0 + col0 FROM tab1 AS cor0
----
3996
4218
7104

query I rowsort
SELECT + col1 * - cor0.col1 + col1 * col0 FROM tab1 cor0
----
-598
540
871

query I rowsort
SELECT ALL col1 * ( col1 ) + cor0.col1 * - ( - col1 + col0 ) AS col0 FROM tab0 cor0
----
12728
15423
8463

query I rowsort
SELECT ALL + - col2 + col2 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8167
SELECT DISTINCT + col1 DIV col1 + col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-8167
SELECT DISTINCT + col1 / col1 + col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL + col1 + 91 FROM tab0 AS cor0
----
177
182
188

query I rowsort
SELECT ALL + - ( 24 ) + + col1 AS col0 FROM tab1 AS cor0
----
-11
-14
2

query I rowsort
SELECT DISTINCT + + ( col1 ) AS col2 FROM tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 - + col0 col2 FROM tab0 AS cor0
----
2
62
62

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 5acb69cde71208fe580e10b8b669428e

query I rowsort
SELECT ALL + col1 + 89 * col2 AS col1 FROM tab0 AS cor0
----
186
3023
7389

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # use DIV operator for integer division
query I rowsort label-8175
SELECT + - col2 DIV ( - col2 ) + + 98 * + col2 FROM tab1 AS cor0
----
5293
5587
9409

skipif mysql # not compatible
query I rowsort label-8175
SELECT + - col2 / ( - col2 ) + + 98 * + col2 FROM tab1 AS cor0
----
5293
5587
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + col0 col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - + col0 + + 94 FROM tab1 AS cor0
----
14
30
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - 12 ) * - col2 + col2 col2 FROM tab0 AS cor0
----
1066
13
429

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8179
SELECT ALL - CAST( NULL AS SIGNED ) + 95 - + col2 / 1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8179
SELECT ALL - CAST ( NULL AS INTEGER ) + 95 - + col2 / 1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col1 + col2 col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL + - col2 * + ( col2 * + col2 ) + - 93 * col1 FROM tab0 cor0
----
-43935
-559831
-9022

query I rowsort
SELECT + 60 * - col0 - col2 AS col0 FROM tab0 AS cor0
----
-1473
-2101
-5422

query I rowsort
SELECT DISTINCT + + ( 12 ) FROM tab1 AS cor0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + 26 col2 FROM tab0 cor0
----
2236
2366
2522

query I rowsort
SELECT col1 * - col1 AS col2 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col0 * ( + col1 ) + ( 22 ) FROM tab0 AS cor0
----
2086
3417
8121

query I rowsort
SELECT ALL ( col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8188
SELECT - CAST( NULL AS SIGNED ) - + col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8188
SELECT - CAST ( NULL AS INTEGER ) - + col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col0 * col0 + + col1 * + col0 FROM tab1 cor0
----
4736
7440
87

query I rowsort
SELECT + ( col1 ) * + col0 + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL ( + col1 * - col2 ) AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - tab0.col1 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + 8 * - 23 AS col0 FROM tab2 AS cor0
----
-184
-184
-184

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 44 * + cor0.col2 col2 FROM tab1 AS cor0
----
2376
2508
4224

onlyif mysql # use DIV operator for integer division
query I rowsort label-8195
SELECT - + 94 DIV + col2 - + col1 * - ( col2 * - col0 ) AS col0 FROM tab0 AS cor0
----
-3489
-664119
-68114

skipif mysql # not compatible
query I rowsort label-8195
SELECT - + 94 / + col2 - + col1 * - ( col2 * - col0 ) AS col0 FROM tab0 AS cor0
----
-3489
-664119
-68114

query I rowsort
SELECT col1 + - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + 27 + 16 * col2 * 66 FROM tab1 AS cor0
----
101403
57051
60219

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + col1 col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - + ( ( - col2 ) ) * col0 * - col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - - 0 + col1 FROM tab0 cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8201
SELECT - CAST( + cor0.col2 AS SIGNED ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

skipif mysql # not compatible
query I rowsort label-8201
SELECT - CAST ( + cor0.col2 AS INTEGER ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # use DIV operator for integer division
query I rowsort label-8202
SELECT col0 + - col1 DIV cor0.col2 AS col0 FROM tab0 cor0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-8202
SELECT col0 + - col1 / cor0.col2 AS col0 FROM tab0 cor0
----
-62
22
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8203
SELECT + cor0.col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8203
SELECT + cor0.col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8204
SELECT - cor0.col1 DIV 9 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 10b036f2ba8017dde5ac20e9592ddc6a

skipif mysql # not compatible
query I rowsort label-8204
SELECT - cor0.col1 / 9 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 10b036f2ba8017dde5ac20e9592ddc6a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - cor0.col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col2 * + ( + col0 ) * + col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL + - col0 + - 4 FROM tab0 AS cor0
----
-28
-39
-93

query I rowsort
SELECT - cor0.col2 * col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL 50 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT ALL col2 * col0 * - col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + 71 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT ALL 49 * col0 FROM tab2
----
343
3822
3871

query I rowsort
SELECT + cor0.col0 * - col0 * + col0 AS col2 FROM tab1 cor0
----
-262144
-27
-512000

query I rowsort
SELECT + col1 * col0 + ( 50 ) AS col2 FROM tab0
----
2114
3445
8149

query I rowsort
SELECT DISTINCT tab2.col1 + - col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL col0 * ( + col2 ) + - tab1.col0 + ( - col0 ) AS col0 FROM tab1
----
156
3520
7520

query I rowsort
SELECT + col2 * col1 + cor0.col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + - col1 * col2 - + col1 AS col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT - 24 FROM tab2, tab0 AS cor0
----
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - cor0.col2 col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + 40 FROM tab0, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT ALL col2 * + 63 * col2 FROM tab2
----
42588
45927
90972

onlyif mysql # use DIV operator for integer division
query I rowsort label-8223
SELECT - 93 DIV 44 FROM tab0, tab1 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

skipif mysql # not compatible
query I rowsort label-8223
SELECT - 93 / 44 FROM tab0, tab1 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT - cor0.col2 + col1 * col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT + - col1 + ( col0 ) AS col0 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT ALL - + col2 * cor0.col2 * - col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT DISTINCT + col1 * - col0 + col1 * + cor0.col1 FROM tab2 cor0
----
-1054
-1121
744

query I rowsort
SELECT ALL - col2 * 61 + - col0 - col1 FROM tab2 AS cor0
----
-1685
-1723
-2414

query I rowsort
SELECT DISTINCT + tab2.col2 AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + - col0 - col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - - col0 + + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + col1 + 88 FROM tab0 AS cor0
----
174
179
185

onlyif mysql # use DIV operator for integer division
query I rowsort label-8233
SELECT DISTINCT - cor0.col0 + col1 DIV col0 + col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8233
SELECT DISTINCT - cor0.col0 + col1 / col0 + col0 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - col2 + - cor0.col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + col2 + - col0 AS col1 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - cor0.col1 + - cor0.col0 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT + - 74 * col1 + + cor0.col0 * - 23 AS col1 FROM tab0 AS cor0
----
-6916
-7983
-8781

query I rowsort
SELECT ALL + - 68 + cor0.col0 FROM tab1 cor0
----
-4
-65
12

query I rowsort
SELECT DISTINCT ( - col1 ) - col1 AS col1 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8240
SELECT + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8240
SELECT + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8241
SELECT DISTINCT - - CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8241
SELECT DISTINCT - - CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8242
SELECT ALL CAST( NULL AS SIGNED ) * + col2 * cor0.col0 + - col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8242
SELECT ALL CAST ( NULL AS INTEGER ) * + col2 * cor0.col0 + - col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 41 * - 19 + + col0 FROM tab2 AS cor0
----
786
857
858

query I rowsort
SELECT tab1.col1 - 54 AS col0 FROM tab1
----
-28
-41
-44

query I rowsort
SELECT 67 FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 09fa7af42010457bb3c6ffd0dfea3bc8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8246
SELECT + + 52 + col0 + CAST( col2 AS SIGNED ) DIV - col1 FROM tab2 AS cor0
----
129
130
59

skipif mysql # not compatible
query I rowsort label-8246
SELECT + + 52 + col0 + CAST ( col2 AS INTEGER ) / - col1 FROM tab2 AS cor0
----
129
130
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8247
SELECT ALL + col1 * col2 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8247
SELECT ALL + col1 * col2 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col1 * col1 + + 89 AS col2 FROM tab0 AS cor0
----
-7307
-8192
-9320

query I rowsort
SELECT - 42 * + 9 AS col1 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to b64666bb637dcc34752894944bcbce1d

onlyif mysql # use DIV operator for integer division
query I rowsort label-8250
SELECT ALL - 58 * + col2 + 87 DIV + col2 FROM tab0 AS cor0
----
-1912
-4755
29

skipif mysql # not compatible
query I rowsort label-8250
SELECT ALL - 58 * + col2 + 87 / + col2 FROM tab0 AS cor0
----
-1912
-4755
29

query I rowsort
SELECT ( 7 ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT - col2 * - cor0.col1 - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL - col0 * col1 + col1 FROM tab0 WHERE - col1 <= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8254
SELECT - tab1.col2 DIV col1 + + col2 AS col1 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-8254
SELECT - tab1.col2 / col1 + + col2 AS col1 FROM tab1
----
52
52
89

query I rowsort
SELECT ALL + col0 + + col0 * + col0 FROM tab2
----
56
6162
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8256
SELECT ALL - - cor0.col0 * + tab2.col2 - - CAST( NULL AS DECIMAL ) * - tab2.col0 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8256
SELECT ALL - - cor0.col0 * + tab2.col2 - - CAST ( NULL AS REAL ) * - tab2.col0 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + col0 + + cor0.col2 AS col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT cor0.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - col0 + col2 AS col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL col0 * col0 * col1 + col1 FROM tab0
----
118922
49622
720902

onlyif mysql # use DIV operator for integer division
query I rowsort label-8261
SELECT ALL col0 DIV - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-8261
SELECT ALL col0 / - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT - col1 + 66 AS col0 FROM tab2 AS cor0
----
35
49
7

query I rowsort
SELECT - tab0.col2 + - tab0.col1 * + col2 AS col1 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1, tab2, tab0 cor0
----
86
91
97

query I rowsort
SELECT tab2.col2 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - tab2.col0 + col0 * + 83 * col2 FROM tab2
----
15680
168246
249087

onlyif mysql # use DIV operator for integer division
query I rowsort label-8267
SELECT col0 + ( + 66 ) DIV col2 + col0 AS col0 FROM tab0 cor0
----
136
178
50

skipif mysql # not compatible
query I rowsort label-8267
SELECT col0 + ( + 66 ) / col2 + col0 AS col0 FROM tab0 cor0
----
136
178
50

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col0 * + CAST ( col2 AS REAL ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col1 * col2 + - col2 FROM tab1 cor0
----
1152
1350
513

query I rowsort
SELECT + col0 + + col1 + - col2 * + col1 FROM tab2 AS cor0
----
-1397
-550
-799

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * - col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8272
SELECT + col2 * - CAST( NULL AS SIGNED ) * ( - col2 + col0 ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8272
SELECT + col2 * - CAST ( NULL AS INTEGER ) * ( - col2 + col0 ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * - ( 92 ) AS col2 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT col0 * - 40 * col0 + - col1 FROM tab1 cor0
----
-163850
-256013
-386

onlyif mysql # use DIV operator for integer division
query I rowsort label-8275
SELECT 54 + + 53 DIV + tab2.col0 AS col0 FROM tab2
----
54
54
61

skipif mysql # not compatible
query I rowsort label-8275
SELECT 54 + + 53 / + tab2.col0 AS col0 FROM tab2
----
54
54
61

query I rowsort
SELECT ALL - col2 - ( tab1.col1 + col2 ) AS col0 FROM tab1
----
-124
-134
-205

query I rowsort
SELECT ALL ( col2 ) AS col2 FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8278
SELECT - CAST( NULL AS DECIMAL ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8278
SELECT - CAST ( NULL AS REAL ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * col1 + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-8280
SELECT + 40 DIV - 30 + + col1 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-8280
SELECT + 40 / - 30 + + col1 FROM tab2
----
16
30
58

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
24
35
89

query I rowsort
SELECT + col0 + cor0.col2 * col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT col0 - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL - col2 + col2 * 83 * + 52 AS col1 FROM tab1 AS cor0
----
233010
245955
414240

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8285
SELECT DISTINCT + col1 + + col2 + CAST( + col1 AS SIGNED ) AS col0 FROM tab1 cor0
----
106
122
77

skipif mysql # not compatible
query I rowsort label-8285
SELECT DISTINCT + col1 + + col2 + CAST ( + col1 AS INTEGER ) AS col0 FROM tab1 cor0
----
106
122
77

query I rowsort
SELECT ALL + ( + col0 ) * 43 FROM tab1 AS cor0
----
129
2752
3440

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col1 - ( ( + col1 ) + - col1 ) * + col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + + col1 + col2 * col2 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT 22 + 15 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 - + col2 col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT 14 AS col0 FROM tab2 AS cor0
----
14

query I rowsort
SELECT ALL - - 73 + col2 AS col1 FROM tab1 AS cor0
----
127
130
169

query I rowsort
SELECT + col0 + + col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + - col1 + cor0.col1 AS col2 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL - col2 * + cor0.col1 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + ( col0 ) + col0 * - col2 + - col1 AS col0 FROM tab2 AS cor0
----
-2009
-213
-2940

query I rowsort
SELECT ALL + ( ( col1 ) ) FROM tab1
----
10
13
26

query I rowsort
SELECT - - col1 * col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + 67 FROM tab2 AS cor0
----
67

query I rowsort
SELECT DISTINCT - - col1 * - cor0.col0 + + ( + col1 ) AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 col2 FROM tab1 AS cor0
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) * col2 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + 8 * + col2 - - ( + ( + col0 ) ) FROM tab1 AS cor0
----
435
520
848

query I rowsort
SELECT DISTINCT - col0 * + col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - - col0 + col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - col0 * col1 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL cor0.col0 + - cor0.col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + col1 + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - + col1 * cor0.col0 + + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL col1 * + cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - col1 * - col0 + - col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-8312
SELECT DISTINCT col1 + - cor0.col2 DIV - cor0.col1 FROM tab1 cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-8312
SELECT DISTINCT col1 + - cor0.col2 / - cor0.col1 FROM tab1 cor0
----
15
20
28

query I rowsort
SELECT - col1 + col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL col0 + col2 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT + col0 * col1 * col2 + col1 AS col1 FROM tab0
----
3492
664209
68198

query I rowsort
SELECT col0 + + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - col0 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL - col0 + - col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT ALL - tab0.col1 + col2 AS col1 FROM tab0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8320
SELECT ALL col1 + col1 DIV + col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-8320
SELECT ALL col1 + col1 / + col1 FROM tab1
----
11
14
27

query I rowsort
SELECT ALL tab1.col2 + + col2 FROM tab1
----
108
114
192

query I rowsort
SELECT - col1 * + tab0.col0 * tab0.col1 + - tab0.col1 FROM tab0
----
-177590
-329412
-737100

query I rowsort
SELECT + col1 * + cor0.col2 + cor0.col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + tab0.col1 * - col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col2 * col1 AS col0 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 col1 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT + col1 + - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - col1 * col0 * + col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ALL col0 * + ( col2 ) FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8330
SELECT DISTINCT - col1 DIV - col1 AS col1 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-8330
SELECT DISTINCT - col1 / - col1 AS col1 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 40 * - cor0.col0 col2 FROM tab0 AS cor0
----
1400
3560
960

query I rowsort
SELECT ALL - - 1 + col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT + - 20 * col0 FROM tab2 AS cor0
----
-140
-1560
-1580

query I rowsort
SELECT DISTINCT - - col1 * - col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT tab1.col1 * tab1.col2 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - 69 FROM tab2
----
-69
-69
-69

query I rowsort
SELECT DISTINCT ( tab2.col2 ) * col2 AS col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT + ( col2 ) AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT - ( - col1 ) * - col1 * tab0.col0 + + col2 FROM tab0
----
-177471
-329314
-736927

query I rowsort
SELECT DISTINCT - 30 AS col0 FROM tab0, tab0 AS cor0
----
-30

query I rowsort
SELECT DISTINCT 19 FROM tab0
----
19

query I rowsort
SELECT + 47 + col2 AS col0 FROM tab0
----
129
48
80

query I rowsort
SELECT - col0 + 44 AS col1 FROM tab2
----
-34
-35
37

query I rowsort
SELECT - tab2.col1 + col0 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT + 60 AS col1 FROM tab0
----
60
60
60

query I rowsort
SELECT DISTINCT 53 + col1 FROM tab2
----
112
70
84

query I rowsort
SELECT + ( - col2 ) AS col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT 25 FROM tab0
----
25
25
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 12 + col0 col2 FROM tab0
----
12
23
77

query I rowsort
SELECT cor0.col2 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL - col2 * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + - col2 * col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-8354
SELECT DISTINCT + col2 DIV + cor0.col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8354
SELECT DISTINCT + col2 / + cor0.col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - 66 * - col0 AS col0 FROM tab1 AS cor0
----
198
4224
5280

query I rowsort
SELECT col0 + - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8358
SELECT ALL - + col2 DIV + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-8358
SELECT ALL - + col2 / + col0 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT - - cor0.col0 + - col0 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL cor1.col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT - col2 * col0 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT DISTINCT - cor0.col2 * + col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - tab0.col2 + tab0.col1 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT col1 * col1 - col0 FROM tab1
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8365
SELECT DISTINCT + col0 DIV - cor0.col0 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8365
SELECT DISTINCT + col0 / - cor0.col0 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - col0 + + col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT + col0 + tab2.col1 * col1 + + col0 AS col2 FROM tab2
----
3637
447
975

onlyif mysql # use DIV operator for integer division
query I rowsort label-8368
SELECT ALL - col1 * + col2 DIV - col2 AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8368
SELECT ALL - col1 * + col2 / - col2 AS col2 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8369
SELECT ALL - col0 DIV col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8369
SELECT ALL - col0 / col1 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - tab1.col0 * - col1 col1 FROM tab1
----
234
40960
83200

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL IN ( col0 / - col1 )
----

query I rowsort
SELECT + col2 + col2 * - col2 * - col2 AS col2 FROM tab2
----
17602
19710
54910

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL NOT IN ( col0 )
----

query I rowsort
SELECT ALL col0 - col2 AS col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT col0 + + col1 * - col2 * col2 FROM tab1
----
-119728
-32426
-75813

query I rowsort
SELECT - col2 FROM tab0 WHERE - col0 * - col2 + col0 BETWEEN - col2 + col1 AND ( + col2 )
----

query I rowsort
SELECT DISTINCT - col2 * col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + col2 + - col1 - - col1 AS col2 FROM tab1
----
54
57
96

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) IN ( + tab0.col2 )
----

query I rowsort
SELECT DISTINCT - col0 * tab2.col2 * col0 FROM tab2
----
-1323
-158184
-237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + + col1 col2 FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-8382
SELECT DISTINCT + col2 DIV col2 AS col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-8382
SELECT DISTINCT + col2 / col2 AS col2 FROM tab0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8383
SELECT col0 + col2 + + col2 DIV + col1 AS col0 FROM tab1
----
126
183
59

skipif mysql # not compatible
query I rowsort label-8383
SELECT col0 + col2 + + col2 / + col1 AS col0 FROM tab1
----
126
183
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8384
SELECT DISTINCT - col2 DIV col2 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-8384
SELECT DISTINCT - col2 / col2 FROM tab1
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8385
SELECT ALL + col0 DIV + col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8385
SELECT ALL + col0 / + col1 FROM tab2
----
0
1
4

query I rowsort
SELECT col0 FROM tab2 WHERE col2 - + col2 / col0 < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8387
SELECT ALL + col1 DIV col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-8387
SELECT ALL + col1 / col0 FROM tab1
----
0
0
8

query I rowsort
SELECT col0 AS col0 FROM tab1 WHERE ( NULL ) IN ( col1 / + col1 )
----

query I rowsort
SELECT ALL + col2 - + col0 FROM tab1 AS cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col1 + + tab2.col1 col1 FROM tab2 WHERE ( col2 + col1 + col1 ) IN ( tab2.col0 * col1 )
----

query I rowsort
SELECT DISTINCT col2 + + col0 AS col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - col1 * col2 * col2 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT - col2 * - col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + col2 * col2 + col0 * cor0.col0 FROM tab1 AS cor0
----
15616
2925
7345

query I rowsort
SELECT ALL col2 + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col1 + + col2 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL cor0.col2 * col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col1 * col1 + col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT cor0.col0 * - col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT NULL BETWEEN - col0 AND NULL
----

query I rowsort
SELECT - col1 FROM tab1 WHERE NULL IN ( - col1 * tab1.col2 )
----

query I rowsort
SELECT col1 * col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col2 + - col2 FROM tab0 cor0 WHERE NOT NULL NOT BETWEEN ( NULL ) AND + col2 / col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 3 col2 FROM tab1
----
30
39
78

query I rowsort
SELECT DISTINCT - col0 + tab0.col0 AS col2 FROM tab0
----
0

query I rowsort
SELECT tab1.col0 - 35 * - tab1.col1 FROM tab1
----
414
535
913

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - + ( + 39 ) FROM tab1 AS cor0
----
-39
-39
-39

query I rowsort
SELECT + 90 + ( cor0.col2 ) * + 62 FROM tab0 AS cor0
----
152
2136
5174

query I rowsort
SELECT + + 59 + - col2 AS col0 FROM tab0 AS cor0
----
-23
26
58

query I rowsort
SELECT 85 FROM tab1 cor0
----
85
85
85

query I rowsort
SELECT ALL - 81 * col1 - 68 AS col0 FROM tab2 cor0
----
-1445
-2579
-4847

query I rowsort
SELECT DISTINCT - col0 * - col0 FROM tab0 AS cor0
----
1225
576
7921

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 9600bdf5bac0caec3229e87170cc40b3

query I rowsort
SELECT ALL - 81 FROM tab1 cor0
----
-81
-81
-81

query I rowsort
SELECT ( col0 ) AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - - 5 + col2 * col2 FROM tab1 AS cor0
----
2921
3254
9221

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab1, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

query I rowsort
SELECT 20 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

onlyif mysql # use DIV operator for integer division
query I rowsort label-8422
SELECT - ( + col1 ) DIV 49 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8422
SELECT - ( + col1 ) / 49 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8423
SELECT DISTINCT + 24 + cor0.col1 * - CAST( + col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-1224
-1380
-546

skipif mysql # not compatible
query I rowsort label-8423
SELECT DISTINCT + 24 + cor0.col1 * - CAST ( + col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-1224
-1380
-546

query I rowsort
SELECT DISTINCT - ( col0 ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - col0 + - col0 * - 17 AS col2 FROM tab0 cor0
----
1424
384
560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 - 46 col0 FROM tab2
----
1297
171
4556

query I rowsort
SELECT + tab2.col0 + + 54 FROM tab2
----
132
133
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8428
SELECT + - col2 * CAST( col2 AS SIGNED ) * col1 + - col2 AS col2 FROM tab0 cor0
----
-611966
-93687
-98

skipif mysql # not compatible
query I rowsort label-8428
SELECT + - col2 * CAST ( col2 AS INTEGER ) * col1 + - col2 AS col2 FROM tab0 cor0
----
-611966
-93687
-98

query I rowsort
SELECT + col0 + 67 AS col2 FROM tab1 AS cor0
----
131
147
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + - ( 67 + col0 ) col2 FROM tab0 AS cor0
----
-5
-5
-65

query I rowsort
SELECT ALL 38 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT ALL 74 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 + col2 col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL - - 97 * ( col2 ) FROM tab1 cor0
----
5238
5529
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-8435
SELECT ALL - col0 DIV - col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8435
SELECT ALL - col0 / - col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + ( - col1 ) - - col0 * 85 * + col1 FROM tab1 AS cor0
----
54390
6604
88387

query I rowsort
SELECT DISTINCT + col1 + ( + col0 * 99 ) FROM tab0 AS cor0
----
2462
3562
8902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 + - col2 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * - col2 + col1 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT + - 87 + - ( + col1 ) * col1 AS col2 FROM tab1 AS cor0
----
-187
-256
-763

query I rowsort
SELECT - + cor0.col2 * - col0 * col2 + + col2 AS col0 FROM tab0 AS cor0
----
26169
36
598518

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) + col2 col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8443
SELECT ALL 14 DIV cor0.col1 - col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8443
SELECT ALL 14 / cor0.col1 - col2 / - col2 AS col2 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8444
SELECT - ( - 82 ) DIV + cor0.col0 + 62 * col1 FROM tab1 AS cor0
----
1639
621
807

skipif mysql # not compatible
query I rowsort label-8444
SELECT - ( - 82 ) / + cor0.col0 + 62 * col1 FROM tab1 AS cor0
----
1639
621
807

query I rowsort
SELECT DISTINCT col1 - - ( + 32 ) FROM tab1
----
42
45
58

query I rowsort
SELECT DISTINCT - 18 AS col2 FROM tab0 AS cor0
----
-18

query I rowsort
SELECT col1 - + col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col1 + - 70 * - col2 AS col2 FROM tab2 AS cor0
----
1761
1859
2643

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 * + col0 + col2 AS col0 FROM tab1 AS cor0
----
-36423
-4158
-99744

query I rowsort
SELECT DISTINCT col1 + - ( - col1 ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - - col2 - ( - col0 ) * + 94 FROM tab0 cor0
----
2289
3291
8448

query I rowsort
SELECT 49 * + 30 - - col2 AS col1 FROM tab2 AS cor0
----
1496
1497
1508

query I rowsort
SELECT ALL - ( - col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 98 + col2 AS col1 FROM tab0 AS cor0
----
131
180
99

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT DISTINCT 21 AS col2 FROM tab2 cor0
----
21

query I rowsort
SELECT ( - col2 ) + col2 * col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL cor1.col2 AS col1 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT 69 + cor0.col1 AS col2 FROM tab0, tab2 cor0
----
100
128
86

query I rowsort
SELECT + ( col1 ) - col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT 0 * + col0 + + col1 + + ( - col1 ) FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8464
SELECT - col2 * - col1 + - tab2.col0 * + col1 - col1 DIV col1 AS col2 FROM tab2
----
-3069
-698
619

skipif mysql # not compatible
query I rowsort label-8464
SELECT - col2 * - col1 + - tab2.col0 * + col1 - col1 / col1 AS col2 FROM tab2
----
-3069
-698
619

query I rowsort
SELECT - col1 * col2 + + col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT ( + 20 ) * col2 - + 88 FROM tab2
----
432
452
672

query I rowsort
SELECT ALL - cor1.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8468
SELECT ( col1 ) + - col1 + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8468
SELECT ( col1 ) + - col1 + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 63 col1 FROM tab2 AS cor0
----
63

query I rowsort
SELECT ALL 6 FROM tab1
----
6
6
6

query I rowsort
SELECT DISTINCT + col0 + + 42 * 70 FROM tab1 AS cor0
----
2943
3004
3020

query I rowsort
SELECT + col2 * - cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - - cor0.col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + col2 * col2 + + col1 AS col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT cor0.col1 * col1 + + 55 AS col1 FROM tab1 AS cor0
----
155
224
731

query I rowsort
SELECT + col0 + col1 * - col1 AS col1 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - col0 * + col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + ( - tab0.col0 ) FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT + 47 AS col0 FROM tab0
----
47

query I rowsort
SELECT 8 + + col1 * col1 FROM tab1
----
108
177
684

query I rowsort
SELECT - 18 FROM tab0
----
-18
-18
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - col0 + col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + + cor0.col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8487
SELECT + col0 DIV - ( 90 ) col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8487
SELECT + col0 / - ( 90 ) col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + ( - col0 ) + col0 * col0 col0 FROM tab2 cor0
----
11
5947
6145

query I rowsort
SELECT DISTINCT + col0 * col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - + col2 * col1 * - cor0.col1 AS col2 FROM tab2 cor0
----
10982
25947
90506

query I rowsort
SELECT + col0 * + col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8492
SELECT ALL + - col2 DIV - col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8492
SELECT ALL + - col2 / - col2 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT cor0.col0 * col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - + cor0.col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + col1 * col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col1 * col2 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT + - 59 * + col1 AS col0 FROM tab1 AS cor0
----
-1534
-590
-767

onlyif mysql # use DIV operator for integer division
query I rowsort label-8498
SELECT ALL - col2 * col2 + - col0 + + cor0.col1 DIV cor0.col1 AS col0 FROM tab1 AS cor0
----
-2918
-3312
-9295

skipif mysql # not compatible
query I rowsort label-8498
SELECT ALL - col2 * col2 + - col0 + + cor0.col1 / cor0.col1 AS col0 FROM tab1 AS cor0
----
-2918
-3312
-9295

query I rowsort
SELECT + col1 * cor0.col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL cor0.col0 * - col1 + - col1 AS col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT + col2 * col2 - col2 * - col1 AS col2 FROM tab0 AS cor0
----
14186
3927
98

query I rowsort
SELECT + - col2 * ( col1 * col1 ) FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT - col1 + 8 * + col2 FROM tab1 AS cor0
----
406
446
755

query I rowsort
SELECT ALL ( + col0 * + col1 ) + + ( tab1.col2 ) FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL - cor0.col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + 84 * - tab2.col2 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to a6cafc9ad23ef1c4dd08283a485b33d0

query I rowsort
SELECT DISTINCT tab2.col2 * - tab2.col0 AS col1 FROM tab2, tab1 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8508
SELECT ALL col2 * col1 + ( + tab0.col0 ) DIV col0 FROM tab0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-8508
SELECT ALL col2 * col1 + ( + tab0.col0 ) / col0 FROM tab0
----
2839
7463
98

query I rowsort
SELECT ALL + 33 + col2 AS col1 FROM tab0
----
115
34
66

query I rowsort
SELECT col0 + col2 + ( + 69 ) * col2 FROM tab1
----
3783
4054
6800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + col1 * - col0 col0 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT ( col0 ) + 36 FROM tab0
----
125
60
71

query I rowsort
SELECT DISTINCT col1 + 55 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-4644
-4914
-5238

onlyif mysql # use DIV operator for integer division
query I rowsort label-8514
SELECT DISTINCT + - cor0.col0 * 64 DIV - col2 AS col2 FROM tab0 AS cor0
----
2240
46
69

skipif mysql # not compatible
query I rowsort label-8514
SELECT DISTINCT + - cor0.col0 * 64 / - col2 AS col2 FROM tab0 AS cor0
----
2240
46
69

query I rowsort
SELECT - 51 * 66 + col0 * col1 FROM tab2 AS cor0
----
-2023
-3149
1236

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col1 * + col1 col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT 5 + col1 AS col1 FROM tab2 AS cor0
----
22
36
64

query I rowsort
SELECT ALL + - col1 * col0 + cor0.col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT + col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - + 66 * - col0 - cor0.col0 * col0 FROM tab2 AS cor0
----
-1027
-936
413

query I rowsort
SELECT + col1 * + col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT 67 AS col1 FROM tab0 AS cor0
----
67
67
67

query I rowsort
SELECT 49 * - cor0.col2 FROM tab0 AS cor0
----
-1617
-4018
-49

query I rowsort
SELECT - ( - col2 ) * + col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - 0 + + ( col0 ) FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 * + col2 col0 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT ALL + 20 AS col0 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT ALL - - ( + col1 ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT + 9 * - ( col0 ) FROM tab0 AS cor0
----
-216
-315
-801

query I rowsort
SELECT ALL + 25 AS col1 FROM tab2 AS cor0
----
25
25
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col2 col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT ( cor0.col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - col2 * + col2 * col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8534
SELECT + CAST( + 43 AS SIGNED ) * col0 FROM tab0 AS cor0
----
1032
1505
3827

skipif mysql # not compatible
query I rowsort label-8534
SELECT + CAST ( + 43 AS INTEGER ) * col0 FROM tab0 AS cor0
----
1032
1505
3827

query I rowsort
SELECT ALL col0 * 22 + - col0 FROM tab2
----
147
1638
1659

query I rowsort
SELECT + tab0.col0 - + col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT 91 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 20 * - col0 col2 FROM tab0 AS cor0
----
1780
480
700

query I rowsort
SELECT + 34 FROM tab1, tab2 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8540
SELECT ALL - + CAST( NULL AS SIGNED ) * - col0 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8540
SELECT ALL - + CAST ( NULL AS INTEGER ) * - col0 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 79 + + col0 FROM tab0 AS cor0
----
103
114
168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + tab2.col1 * + col2 col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT + + cor0.col1 * + cor0.col1 * col2 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT + col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-8545
SELECT cor0.col0 DIV cor0.col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8545
SELECT cor0.col0 / cor0.col2 FROM tab1 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8547
SELECT - col0 * col2 DIV - col0 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8547
SELECT - col0 * col2 / - col0 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + 17 * col0 FROM tab0
----
1513
408
595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8549
SELECT - CAST( + ( - col0 ) AS SIGNED ) AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8549
SELECT - CAST ( + ( - col0 ) AS INTEGER ) AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL - 98 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT ALL 13 * col1 * - col2 FROM tab0
----
-1261
-36894
-97006

query I rowsort
SELECT ALL tab1.col0 * ( 77 ) FROM tab1, tab1 cor0
----
9 values hashing to 7c1ff6c601ea3444149c9d4ede391467

query I rowsort
SELECT 77 + + cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 941165c8423ac305a6a0066f40747e79

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab2, tab2 cor1
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

query I rowsort
SELECT DISTINCT col0 + 7 AS col2 FROM tab1 AS cor0
----
10
71
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-8556
SELECT - col2 DIV CAST( col1 AS SIGNED ) - + cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8556
SELECT - col2 / CAST ( col1 AS INTEGER ) - + cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8557
SELECT ALL + cor0.col0 * - 85 + ( col2 + CAST( - col2 AS SIGNED ) ) FROM tab1 AS cor0
----
-255
-5440
-6800

skipif mysql # not compatible
query I rowsort label-8557
SELECT ALL + cor0.col0 * - 85 + ( col2 + CAST ( - col2 AS INTEGER ) ) FROM tab1 AS cor0
----
-255
-5440
-6800

query I rowsort
SELECT DISTINCT + - cor0.col0 * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + + col1 + 4 * + col2 * col2 AS col0 FROM tab1 cor0
----
11690
13006
36877

query I rowsort
SELECT DISTINCT + + cor0.col2 * - ( 31 ) + + col2 + col2 FROM tab1 AS cor0
----
-1566
-1653
-2784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 * 7 + 92 col2 FROM tab0 cor0
----
-139
-482
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-8562
SELECT ALL tab2.col0 DIV + tab2.col1 AS col2 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8562
SELECT ALL tab2.col0 / + tab2.col1 AS col2 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL - col1 * - ( + col0 ) FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL + + 21 * col2 + + col2 * + 87 FROM tab2 AS cor0
----
2808
2916
4104

query I rowsort
SELECT - cor0.col2 * col1 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col1 FROM tab2, tab2 AS cor0 WHERE NULL = ( NULL )
----

query I rowsort
SELECT DISTINCT + tab1.col1 FROM tab1, tab2 AS cor0
----
10
13
26

query I rowsort
SELECT 69 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8569
SELECT ALL + 85 DIV cor0.col2 + col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1248
1405
571

skipif mysql # not compatible
query I rowsort label-8569
SELECT ALL + 85 / cor0.col2 + col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1248
1405
571

query I rowsort
SELECT 94 + + cor0.col2 * + col2 FROM tab1 cor0
----
3010
3343
9310

query I rowsort
SELECT 32 FROM tab0, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8572
SELECT CAST( NULL AS SIGNED ) + - cor0.col2 * col2 + ( col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8572
SELECT CAST ( NULL AS INTEGER ) + - cor0.col2 * col2 + ( col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col1 * cor0.col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-8574
SELECT + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-8574
SELECT + col2 / col0 AS col1 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT + ( + col2 ) + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + + col0 - col0 * + 97 FROM tab0 AS cor0
----
-2304
-3360
-8544

query I rowsort
SELECT ALL - col2 + + col1 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 48 col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT - col1 * col1 * col1 AS col0 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT + col1 * + col1 - - col0 FROM tab0 AS cor0
----
7420
8370
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL col1 * - col2 + 59 AS col1 FROM tab0 AS cor0
----
-2779
-38
-7403

query I rowsort
SELECT cor0.col1 * - ( - cor0.col2 ) FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 96 col0 FROM tab0, tab1, tab2 AS cor0
----
96

query I rowsort
SELECT DISTINCT ( col2 ) - col2 AS col1 FROM tab2
----
0

query I rowsort
SELECT - col1 * col2 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + col2 * 88 col2 FROM tab2
----
-2210
-2369
-3265

onlyif mysql # use DIV operator for integer division
query I rowsort label-8588
SELECT tab1.col0 DIV col1 + ( + col0 ) + col2 AS col2 FROM tab1
----
127
182
57

skipif mysql # not compatible
query I rowsort label-8588
SELECT tab1.col0 / col1 + ( + col0 ) + col2 AS col2 FROM tab1
----
127
182
57

query I rowsort
SELECT 80 * tab2.col0 * + 30 FROM tab2
----
16800
187200
189600

onlyif mysql # use DIV operator for integer division
query I rowsort label-8590
SELECT DISTINCT + col0 + - col1 - - col1 DIV tab0.col2 AS col2 FROM tab0
----
-1
-60
35

skipif mysql # not compatible
query I rowsort label-8590
SELECT DISTINCT + col0 + - col1 - - col1 / tab0.col2 AS col2 FROM tab0
----
-1
-60
35

query I rowsort
SELECT ALL - tab2.col2 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT - col2 * col0 * + tab0.col1 + col1 FROM tab0
----
-3298
-664027
-68026

query IIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
243 values hashing to ce53c0e8839c969b0513568da6eb2c4b

query I rowsort
SELECT col1 * 74 * - col1 - + col0 * + ( 96 ) FROM tab2
----
-265082
-28970
-71786

query I rowsort
SELECT + + cor0.col1 * - 54 * + col0 + + cor0.col2 AS col1 FROM tab0 cor0
----
-111423
-183329
-437264

onlyif mysql # use DIV operator for integer division
query I rowsort label-8596
SELECT DISTINCT col1 DIV - 4 FROM tab0 AS cor0
----
-21
-22
-24

skipif mysql # not compatible
query I rowsort label-8596
SELECT DISTINCT col1 / - 4 FROM tab0 AS cor0
----
-21
-22
-24

query I rowsort
SELECT col0 * + col2 + + ( - col0 ) * cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * 2 AS col1 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT col1 + - col2 + + col2 * col1 AS col1 FROM tab0
----
193
2891
7471

query I rowsort
SELECT - col1 * col2 + - col0 * col2 * + col2 FROM tab2 AS cor0
----
-114722
-54262
-5940

query I rowsort
SELECT cor0.col0 * 24 - 70 AS col2 FROM tab0 cor0
----
2066
506
770

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8602
SELECT ALL + - col1 - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8602
SELECT ALL + - col1 - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col0 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - + 81 AS col1 FROM tab0 AS cor0
----
-81
-81
-81

query I rowsort
SELECT 60 FROM tab2 AS cor0
----
60
60
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * tab0.col1 col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - cor0.col1 * + col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ( + cor0.col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 94 FROM tab1 AS cor0
----
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-8610
SELECT DISTINCT + ( 10 ) DIV col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-8610
SELECT DISTINCT + ( 10 ) / col0 FROM tab0
----
0

query I rowsort
SELECT DISTINCT - + 75 * col2 + 39 AS col0 FROM tab2 AS cor0
----
-1911
-1986
-2811

query I rowsort
SELECT + 90 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
1179
6814
91

query I rowsort
SELECT DISTINCT + - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + 18 * + col1 FROM tab0 AS cor0
----
1548
1638
1746

onlyif mysql # use DIV operator for integer division
query I rowsort label-8615
SELECT DISTINCT col1 DIV - cor0.col2 + - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-8615
SELECT DISTINCT col1 / - cor0.col2 + - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + - 0 + + col2 * col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - cor0.col1 * + col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-8618
SELECT DISTINCT - col0 DIV + col1 + - col0 * col2 FROM tab1 AS cor0
----
-162
-3654
-7686

skipif mysql # not compatible
query I rowsort label-8618
SELECT DISTINCT - col0 / + col1 + - col0 * col2 FROM tab1 AS cor0
----
-162
-3654
-7686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 66 * col0 + col1 col1 FROM tab1 AS cor0
----
224
4234
5293

query I rowsort
SELECT DISTINCT cor0.col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + + 72 * + col1 + + 28 FROM tab0 AS cor0
----
6220
6580
7012

query I rowsort
SELECT DISTINCT 68 * col1 * ( - col1 ) + cor0.col0 * 38 AS col2 FROM tab0 cor0
----
-502016
-559726
-638482

query I rowsort
SELECT ALL 21 FROM tab2 AS cor0
----
21
21
21

query I rowsort
SELECT DISTINCT - col1 * col2 + + 98 FROM tab0 AS cor0
----
-2740
-7364
1

query I rowsort
SELECT ALL cor0.col2 * col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT 85 * col1 AS col0 FROM tab1 AS cor0
----
1105
2210
850

query I rowsort
SELECT - - col1 + col2 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 56 col0 FROM tab1 AS cor0
----
-56
-56
-56

query I rowsort
SELECT DISTINCT + + col0 * col1 + 73 AS col1 FROM tab1 AS cor0
----
1113
151
713

query I rowsort
SELECT DISTINCT - col0 + + col0 * - col0 AS col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT - col0 * 49 + + col2 FROM tab2 AS cor0
----
-316
-3796
-3833

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + - cor0.col2 + cor0.col2 * cor0.col2 + + col0 FROM tab0 AS cor0
----
1080
35
6731

onlyif mysql # use DIV operator for integer division
query I rowsort label-8634
SELECT ALL - col0 DIV 32 FROM tab1 AS cor0
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-8634
SELECT ALL - col0 / 32 FROM tab1 AS cor0
----
-2
-2
0

query I rowsort
SELECT - cor0.col0 + - ( col0 ) AS col2 FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8636
SELECT DISTINCT col0 DIV col1 AS col2 FROM tab1
----
0
6

skipif mysql # not compatible
query I rowsort label-8636
SELECT DISTINCT col0 / col1 AS col2 FROM tab1
----
0
6

query I rowsort
SELECT - ( - col1 ) + col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT 63 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

onlyif mysql # use DIV operator for integer division
query I rowsort label-8639
SELECT DISTINCT + 75 * 63 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
48
51
54

skipif mysql # not compatible
query I rowsort label-8639
SELECT DISTINCT + 75 * 63 / cor0.col1 AS col1 FROM tab0 AS cor0
----
48
51
54

query I rowsort
SELECT - 2 * - col1 + col1 + col2 AS col1 FROM tab0 AS cor0
----
291
292
355

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8641
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8641
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + 62 * 96 + col0 AS col0 FROM tab1 AS cor0
----
5955
6016
6032

query I rowsort
SELECT ALL - cor0.col0 + - col2 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - + col0 - 76 AS col2 FROM tab1 AS cor0
----
-140
-156
-79

query I rowsort
SELECT DISTINCT + - 45 AS col2 FROM tab1 AS cor0
----
-45

query I rowsort
SELECT ALL - 40 FROM tab2 AS cor0
----
-40
-40
-40

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 40a052eaf1d698dbf3ba319dc3e245ee

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab2 cor1, tab2, tab1 AS cor2
----
3645 values hashing to 97b2ae21242e1e40418ee2ad06544f7a

query I rowsort
SELECT ALL + 92 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL - 2 * 10 FROM tab1 AS cor0
----
-20
-20
-20

query I rowsort
SELECT DISTINCT - + col2 * col2 - col0 AS col2 FROM tab1 cor0
----
-2919
-3313
-9296

query I rowsort
SELECT 25 + 56 AS col2 FROM tab2 AS cor0
----
81
81
81

query I rowsort
SELECT DISTINCT cor0.col2 * - cor0.col0 AS col0 FROM tab1, tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + cor0.col0 + - col0 * + col2 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-8656
SELECT ALL + col1 + + col2 DIV + col1 col0 FROM tab1
----
15
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8656
SELECT ALL + col1 + + col2 / + col1 col0 FROM tab1
----
15
20
28

query I rowsort
SELECT ALL + 23 + ( col1 * ( - col2 ) ) AS col0 FROM tab1
----
-1225
-1381
-547

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 48 ) * col0 + col0 col2 FROM tab1
----
-141
-3008
-3760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 34 + + col2 col0 FROM tab2
----
60
61
72

query I rowsort
SELECT ALL 94 FROM tab1
----
94
94
94

query I rowsort
SELECT DISTINCT - col2 + + col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT 91 AS col1 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT ALL col2 * col2 + + col1 + 31 AS col1 FROM tab1 cor0
----
2973
3290
9260

onlyif mysql # use DIV operator for integer division
query I rowsort label-8664
SELECT DISTINCT col0 DIV - col2 FROM tab1 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-8664
SELECT DISTINCT col0 / - col2 FROM tab1 cor0
----
-1
0

query I rowsort
SELECT ALL col2 * - col1 + + 23 * 89 FROM tab0 AS cor0
----
-5415
-791
1950

query I rowsort
SELECT + - 47 AS col2 FROM tab1 AS cor0
----
-47
-47
-47

query I rowsort
SELECT ALL 24 + tab0.col1 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to b22a3503dd14e347e4bb910d6fa9098e

query I rowsort
SELECT DISTINCT + cor0.col0 + tab2.col2 AS col1 FROM tab2, tab0, tab0 cor0
----
115
116
127
50
51
61
62
73

query I rowsort
SELECT 34 AS col1 FROM tab0
----
34
34
34

query I rowsort
SELECT DISTINCT 87 AS col1 FROM tab1
----
87

query I rowsort
SELECT - col1 * - tab0.col2 + col2 AS col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL tab2.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2, tab1 cor3
----
3645 values hashing to 93e5b836e3f52f458344e73ebce589b5

query I rowsort
SELECT DISTINCT 78 FROM tab1, tab0 cor0
----
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8675
SELECT ALL + col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8675
SELECT ALL + col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 6193516da5556fc054f35e0d2f4e5372

query I rowsort
SELECT DISTINCT col1 * - col1 * tab0.col1 FROM tab0
----
-636056
-753571
-912673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 16 * - col1 ) col2 FROM tab0
----
1376
1456
1552

query I rowsort
SELECT ALL - + 35 * col2 FROM tab1 AS cor0
----
-1890
-1995
-3360

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col0 AS REAL ) AS col1 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8681
SELECT + 29 DIV col2 FROM tab0 AS cor0
----
0
0
29

skipif mysql # not compatible
query I rowsort label-8681
SELECT + 29 / col2 FROM tab0 AS cor0
----
0
0
29

query I rowsort
SELECT cor1.col2 * + 17 * 76 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 72550a594d32841492117acb121611ed

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8683
SELECT CAST( - col0 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-8683
SELECT CAST ( - col0 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - 57 FROM tab1 AS cor0
----
-57
-57
-57

query I rowsort
SELECT ALL + cor1.col1 AS col2 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to 09b120a8ff13ebafea7af10c2152241b

query I rowsort
SELECT 81 FROM tab1
----
81
81
81

query I rowsort
SELECT - tab0.col0 * col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ( col2 ) AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT ( - tab1.col2 + 44 ) FROM tab1
----
-10
-13
-52

query I rowsort
SELECT ALL - col2 * - col0 + col0 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
378
4056
6004

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8692
SELECT DISTINCT col2 + + cor0.col2 * CAST( + col0 * + col1 AS SIGNED ) FROM tab0 cor0
----
3396
664200
68145

skipif mysql # not compatible
query I rowsort label-8692
SELECT DISTINCT col2 + + cor0.col2 * CAST ( + col0 * + col1 AS INTEGER ) FROM tab0 cor0
----
3396
664200
68145

query I rowsort
SELECT - - col1 - + cor0.col2 * + col2 * + col0 FROM tab2 cor0
----
-114059
-5072
-52669

query I rowsort
SELECT DISTINCT + - 98 + col0 * 72 AS col0 FROM tab2 AS cor0
----
406
5518
5590

query I rowsort
SELECT DISTINCT - ( + col1 ) * 90 FROM tab2 AS cor0
----
-1530
-2790
-5310

query I rowsort
SELECT ALL + col1 * + col0 + 81 FROM tab1 AS cor0
----
1121
159
721

query I rowsort
SELECT ALL col1 + col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + 31 + + cor0.col0 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to a22956071ce0b91a919017c6cd209a7c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8699
SELECT DISTINCT + - col1 + col1 DIV + ( - col0 ) FROM tab0 AS cor0
----
-89
-92
-99

skipif mysql # not compatible
query I rowsort label-8699
SELECT DISTINCT + - col1 + col1 / + ( - col0 ) FROM tab0 AS cor0
----
-89
-92
-99

query I rowsort
SELECT ALL - col1 + col2 AS col1 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8701
SELECT col2 DIV - col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-8701
SELECT col2 / - col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT + cor0.col2 + 75 * col1 * col0 AS col1 FROM tab2 AS cor0
----
100763
16302
345176

onlyif mysql # use DIV operator for integer division
query I rowsort label-8703
SELECT - col1 DIV + 76 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8703
SELECT - col1 / + 76 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8705
SELECT - cor0.col1 DIV ( col2 + + cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-8705
SELECT - cor0.col1 / ( col2 + + cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL - col0 + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 19 * + col0 + + col2 FROM tab2
----
1508
1539
160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8708
SELECT + + col2 DIV col2 col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8708
SELECT + + col2 / col2 col2 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8709
SELECT + col2 DIV 31 + + ( cor0.col1 ) col1 FROM tab1 AS cor0
----
11
16
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8709
SELECT + col2 / 31 + + ( cor0.col1 ) col1 FROM tab1 AS cor0
----
11
16
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 65 ) col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT col0 + - 56 AS col0 FROM tab0 AS cor0
----
-21
-32
33

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT col1 + 66 * col0 AS col0 FROM tab2 AS cor0
----
493
5207
5231

query I rowsort
SELECT ALL - col1 * 67 + + cor0.col1 FROM tab1 cor0
----
-1716
-660
-858

query I rowsort
SELECT col2 + - col0 * col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT 25 AS col0 FROM tab2 AS cor0
----
25

query I rowsort
SELECT ALL - col0 - - col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 * col1 + + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 26 col2 FROM tab2 AS cor0
----
-26
-26
-26

query I rowsort
SELECT ALL - ( + 71 ) AS col2 FROM tab1 AS cor0
----
-71
-71
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8721
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8721
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + + col1 + col2 AS col2 FROM tab0 cor0
----
133
143
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8723
SELECT DISTINCT CAST( NULL AS SIGNED ) * 35 + cor0.col1 + col1 col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8723
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 35 + cor0.col1 + col1 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - ( cor0.col2 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - col2 * col1 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL + tab2.col2 * ( + col1 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL 29 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - col1 * col2 * - col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT col2 * col1 + ( + col1 ) * - col2 AS col1 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8731
SELECT - col0 * col0 DIV cor0.col1 AS col1 FROM tab2 cor0
----
-1
-103
-367

skipif mysql # not compatible
query I rowsort label-8731
SELECT - col0 * col0 / cor0.col1 AS col1 FROM tab2 cor0
----
-1
-103
-367

query I rowsort
SELECT + 59 + - col0 AS col0 FROM tab1 AS cor0
----
-21
-5
56

query I rowsort
SELECT 22 + col0 * - ( - col0 ) AS col0 FROM tab1 AS cor0
----
31
4118
6422

query I rowsort
SELECT + cor0.col0 * - col1 - 43 AS col1 FROM tab0 AS cor0
----
-2107
-3438
-8142

query I rowsort
SELECT + 59 + - col0 * col0 AS col2 FROM tab1
----
-4037
-6341
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-8736
SELECT DISTINCT - 1 DIV - cor0.col1 col1 FROM tab1, tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8736
SELECT DISTINCT - 1 / - cor0.col1 col1 FROM tab1, tab0 AS cor0
----
0

query I rowsort
SELECT 14 + cor0.col0 AS col2 FROM tab1 cor0
----
17
78
94

query I rowsort
SELECT - col1 + - col0 * col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT + col0 + + 14 AS col0 FROM tab2
----
21
92
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8740
SELECT col1 + col0 * col0 DIV + col0 + - ( - col2 ) * col0 AS col0 FROM tab1
----
191
3722
7773

skipif mysql # not compatible
query I rowsort label-8740
SELECT col1 + col0 * col0 / + col0 + - ( - col2 ) * col0 AS col0 FROM tab1
----
191
3722
7773

query I rowsort
SELECT ALL col2 + + col1 * col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT 71 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 14 * + 55 * col0 col0 FROM tab0 AS cor0
----
18480
26950
68530

query I rowsort
SELECT + col1 + col2 * col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + - 5 AS col0 FROM tab1 AS cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT + col1 + + cor0.col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - + col0 * 59 + col1 AS col2 FROM tab1 AS cor0
----
-151
-3766
-4707

query I rowsort
SELECT + 90 * 82 FROM tab1 AS cor0
----
7380
7380
7380

query I rowsort
SELECT DISTINCT - 99 * col1 FROM tab0 AS cor0
----
-8514
-9009
-9603

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8750
SELECT - CAST( NULL AS SIGNED ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8750
SELECT - CAST ( NULL AS INTEGER ) * col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + + 58 FROM tab0 AS cor0
----
58
58
58

query I rowsort
SELECT DISTINCT + cor0.col0 * col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col2 * col0 * ( - col1 ) FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT tab2.col0 AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL - cor0.col1 * + 23 * - col0 FROM tab1 AS cor0
----
14720
1794
23920

onlyif mysql # use DIV operator for integer division
query I rowsort label-8757
SELECT DISTINCT - col1 * col0 DIV + col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-8757
SELECT DISTINCT - col1 * col0 / + col0 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8758
SELECT ALL - col0 DIV col2 - - col2 col2 FROM tab1 AS cor0
----
54
56
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8758
SELECT ALL - col0 / col2 - - col2 col2 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT DISTINCT - - 87 + - ( - col0 ) FROM tab1 cor0
----
151
167
90

query I rowsort
SELECT ALL col1 * - 96 FROM tab2
----
-1632
-2976
-5664

query I rowsort
SELECT DISTINCT 97 - - 51 AS col0 FROM tab2
----
148

query I rowsort
SELECT ALL + ( - 49 ) - tab1.col0 AS col1 FROM tab1
----
-113
-129
-52

query I rowsort
SELECT DISTINCT col0 + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT 32 - col2 FROM tab0 AS cor0
----
-1
-50
31

query I rowsort
SELECT - - cor0.col1 * - col1 * + col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT - - 43 AS col1 FROM tab1 AS cor0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-8767
SELECT col0 DIV col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8767
SELECT col0 / col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL + col0 * 87 + + col1 AS col2 FROM tab0 AS cor0
----
2174
3142
7834

query I rowsort
SELECT DISTINCT + col0 + + ( - col2 ) FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT ALL col0 * + col1 AS col0 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8771
SELECT + col2 DIV col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-8771
SELECT + col2 / col0 FROM tab2 AS cor0
----
0
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8772
SELECT ALL col1 DIV + col1 + 59 * col2 + tab2.col0 FROM tab2
----
1601
1613
2322

skipif mysql # not compatible
query I rowsort label-8772
SELECT ALL col1 / + col1 + 59 * col2 + tab2.col0 FROM tab2
----
1601
1613
2322

query I rowsort
SELECT + ( tab0.col2 ) * col0 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + + col0 + + col2 * col2 AS col1 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL + col2 * + col1 * 80 FROM tab2
----
122720
51680
66960

query I rowsort
SELECT - 72 * - 37 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 23f53365d117c4459e3a18f0036c184c

query I rowsort
SELECT - col0 - 77 FROM tab0
----
-101
-112
-166

query I rowsort
SELECT - col1 * col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT - col0 + - ( col1 ) * + col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8781
SELECT ALL + col2 DIV ( col1 ) AS col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-8781
SELECT ALL + col2 / ( col1 ) AS col1 FROM tab2 AS cor0
----
0
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8782
SELECT + CAST( NULL AS SIGNED ) * 80 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8782
SELECT + CAST ( NULL AS INTEGER ) * 80 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query IIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 cor1
----
243 values hashing to 3581f59ff9574f9d6290fc6bca0b5e4d

query I rowsort
SELECT - + col0 * + 4 FROM tab2 AS cor0
----
-28
-312
-316

onlyif mysql # use DIV operator for integer division
query I rowsort label-8785
SELECT DISTINCT - - col0 + + col0 DIV + 9 FROM tab2 AS cor0
----
7
86
87

skipif mysql # not compatible
query I rowsort label-8785
SELECT DISTINCT - - col0 + + col0 / + 9 FROM tab2 AS cor0
----
7
86
87

query I rowsort
SELECT + - col0 + + 49 AS col2 FROM tab0 AS cor0
----
-40
14
25

query I rowsort
SELECT + col0 + cor0.col2 * - 90 * + col0 AS col2 FROM tab2 AS cor0
----
-17003
-182442
-270101

onlyif mysql # use DIV operator for integer division
query I rowsort label-8788
SELECT ALL + col1 DIV ( - 36 ) + + col2 AS col0 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8788
SELECT ALL + col1 / ( - 36 ) + + col2 AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - col2 * 2 * col0 AS col0 FROM tab1 AS cor0
----
-15360
-324
-7296

query I rowsort
SELECT cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT + 12 AS col2 FROM tab0 AS cor0
----
12
12
12

query IIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 32 + 42 col1 FROM tab2 AS cor0
----
74

query I rowsort
SELECT DISTINCT col1 * + ( + col2 ) AS col2 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8795
SELECT DISTINCT - ( - col2 ) DIV + col0 AS col2 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-8795
SELECT DISTINCT - ( - col2 ) / + col0 AS col2 FROM tab0
----
0
1

query I rowsort
SELECT + 68 FROM tab0
----
68
68
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-8797
SELECT ALL + + ( col0 ) DIV col2 + - col0 FROM tab0 AS cor0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-8797
SELECT ALL + + ( col0 ) / col2 + - col0 FROM tab0 AS cor0
----
-24
-88
0

query I rowsort
SELECT ALL + col2 + - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - + cor0.col2 * + 92 FROM tab2 AS cor0
----
-2392
-2484
-3496

onlyif mysql # use DIV operator for integer division
query I rowsort label-8800
SELECT ALL + 95 DIV + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

skipif mysql # not compatible
query I rowsort label-8800
SELECT ALL + 95 / + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8801
SELECT DISTINCT + col1 + - ( col0 ) DIV + tab2.col1 AS col2 FROM tab2
----
13
31
58

skipif mysql # not compatible
query I rowsort label-8801
SELECT DISTINCT + col1 + - ( col0 ) / + tab2.col1 AS col2 FROM tab2
----
13
31
58

query I rowsort
SELECT ALL - 13 AS col0 FROM tab2 AS cor0
----
-13
-13
-13

query I rowsort
SELECT ALL - ( cor0.col2 ) AS col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT cor0.col1 * + 31 AS col1 FROM tab0, tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT ALL cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL + col0 * + col1 + 73 FROM tab2
----
1416
290
4675

query I rowsort
SELECT ALL - cor0.col1 + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col2 ) - - 23 col0 FROM tab1 AS cor0
----
119
77
80

query I rowsort
SELECT - + col2 * - col1 - ( - cor0.col1 ) FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ( col1 ) * + 20 - col0 FROM tab0 AS cor0
----
1696
1731
1905

query I rowsort
SELECT ALL - 57 * col2 + + col1 AS col0 FROM tab2 AS cor0
----
-1423
-1508
-2149

query I rowsort
SELECT DISTINCT + 95 - + col1 FROM tab0 AS cor0
----
-2
4
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8814
SELECT + col2 DIV col1 + + col0 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-8814
SELECT + col2 / col1 + + col0 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT ALL + 29 + col2 AS col1 FROM tab2 AS cor0
----
55
56
67

query I rowsort
SELECT DISTINCT col1 + col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT - - col2 * - col1 + ( col0 * - cor0.col1 ) FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT + cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 43 col0 FROM tab2 cor0
----
43

query I rowsort
SELECT ALL col2 * col0 * - col2 + + col1 FROM tab1 AS cor0
----
-207926
-737267
-8722

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 * CAST ( col2 AS REAL ) + - col1 * + col1 AS col0 FROM tab2 AS cor0
----
-124
-1947
357

onlyif mysql # use DIV operator for integer division
query I rowsort label-8822
SELECT ALL - - col0 - + ( + col1 ) DIV + col1 AS col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-8822
SELECT ALL - - col0 - + ( + col1 ) / + col1 AS col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT ALL col0 + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col2 - + col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col0 * - col2 * col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - cor0.col1 * + 50 + + ( - col2 ) AS col2 FROM tab2 cor0
----
-1577
-2976
-888

query I rowsort
SELECT + - col2 + cor0.col0 AS col1 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 90 col0 FROM tab2 AS cor0
----
1530
2790
5310

query I rowsort
SELECT DISTINCT + + col0 + 17 * + 90 FROM tab1 AS cor0
----
1533
1594
1610

query I rowsort
SELECT ALL col1 - + 65 AS col0 FROM tab0 AS cor0
----
21
26
32

query I rowsort
SELECT DISTINCT - ( col1 ) + tab1.col0 AS col2 FROM tab1
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + tab0.col1 col1 FROM tab0
----
119
173
98

query I rowsort
SELECT + col1 * - tab1.col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col2 + - col2 col1 FROM tab0
----
-164
-2
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8835
SELECT DISTINCT ( + col1 ) + CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8835
SELECT DISTINCT ( + col1 ) + CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL

query I rowsort
SELECT 76 FROM tab2
----
76
76
76

query I rowsort
SELECT 93 + - col2 * col0 AS col1 FROM tab1
----
-3555
-69
-7587

query I rowsort
SELECT + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + ( - col2 ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + 59 + col2 AS col0 FROM tab1 AS cor0
----
113
116
155

query I rowsort
SELECT DISTINCT 82 FROM tab1
----
82

query I rowsort
SELECT ( 31 ) + - tab0.col1 FROM tab0
----
-55
-60
-66

query I rowsort
SELECT DISTINCT col1 + 38 FROM tab1
----
48
51
64

query I rowsort
SELECT DISTINCT + ( + col2 ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT + 80 FROM tab0
----
80
80
80

query I rowsort
SELECT col1 + + col1 * col1 AS col1 FROM tab2
----
306
3540
992

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab0 AS cor0, tab2 AS cor1
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT 62 * col1 FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT DISTINCT - + col2 * + col0 - - 32 * 52 * - cor0.col0 FROM tab1 AS cor0
----
-110144
-140800
-5154

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - cor0.col1 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8852
SELECT col1 * - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8852
SELECT col1 * - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + + col1 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT + tab0.col0 * col1 * tab0.col0 + col1 AS col1 FROM tab0
----
118922
49622
720902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col0 col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8856
SELECT ALL col1 + col2 DIV ( - col0 ) AS col0 FROM tab2
----
17
28
59

skipif mysql # not compatible
query I rowsort label-8856
SELECT ALL col1 + col2 / ( - col0 ) AS col0 FROM tab2
----
17
28
59

query I rowsort
SELECT DISTINCT col1 + col0 FROM tab1
----
29
74
93

query I rowsort
SELECT tab2.col2 + col1 + - col1 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL - col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8860
SELECT DISTINCT + col2 DIV CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-8860
SELECT DISTINCT + col2 / CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT ALL - col1 * + col0 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - - col1 + ( - col0 ) * - col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - + col0 * col2 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col2 + + col0 FROM tab2
----
104
117
34

query I rowsort
SELECT col1 + col2 + - 57 AS col1 FROM tab0
----
116
41
62

query I rowsort
SELECT ALL col2 + + 69 AS col0 FROM tab2
----
107
95
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8867
SELECT ALL + + CAST( cor0.col1 AS SIGNED ) col1 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8867
SELECT ALL + + CAST ( cor0.col1 AS INTEGER ) col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - col0 + - ( + cor0.col1 ) + - col2 AS col0 FROM tab1 AS cor0
----
-131
-189
-83

query I rowsort
SELECT ALL - 71 + + col2 FROM tab2 AS cor0
----
-33
-44
-45

query I rowsort
SELECT + ( col2 ) + - col1 * ( ( col0 ) + - col1 ) * col0 FROM tab0 AS cor0
----
128001
16280
210491

query I rowsort
SELECT ALL ( - col1 ) * - col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ( col1 ) * tab1.col0 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL tab2.col0 * - col1 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - 50 + ( - col1 * col2 ) + + col2 FROM tab2 AS cor0
----
-1558
-658
-860

query I rowsort
SELECT + cor0.col1 + - col1 * - col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - 58 FROM tab2 AS cor0
----
-58
-58
-58

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - cor0.col1 * col0 * col1 + CAST ( + col1 AS REAL ) + + col0 FROM tab0 AS cor0
----
-177394
-329183
-736829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 75 * - 38 col1 FROM tab0 cor0
----
2850
2850
2850

query I rowsort
SELECT DISTINCT - 22 AS col2 FROM tab0 cor0
----
-22

query I rowsort
SELECT DISTINCT - + 88 * - col1 FROM tab0 AS cor0
----
7568
8008
8536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8881
SELECT + CAST( col1 AS SIGNED ) + col2 + - cor0.col2 * + 87 * + col0 FROM tab2 AS cor0
----
-16385
-176351
-261119

skipif mysql # not compatible
query I rowsort label-8881
SELECT + CAST ( col1 AS INTEGER ) + col2 + - cor0.col2 * + 87 * + col0 FROM tab2 AS cor0
----
-16385
-176351
-261119

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col0 col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + cor0.col0 * + 43 * - col0 - - 38 FROM tab0 cor0
----
-24730
-340565
-52637

query I rowsort
SELECT + - cor0.col1 + 15 * col0 FROM tab0 AS cor0
----
1244
274
428

query I rowsort
SELECT - col0 * - tab0.col0 AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + ( - tab2.col2 ) FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab1, tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8888
SELECT CAST( - col0 AS SIGNED ) * - col2 FROM tab2
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-8888
SELECT CAST ( - col0 AS INTEGER ) * - col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col2 * - col2 AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT + - ( + cor0.col0 ) AS col0 FROM tab2, tab1, tab0 cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT - col2 - col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT - ( 35 ) - col1 * col0 AS col1 FROM tab0
----
-2099
-3430
-8134

onlyif mysql # use DIV operator for integer division
query I rowsort label-8893
SELECT - col0 + + col2 DIV - col0 FROM tab2 AS cor0
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-8893
SELECT - col0 + + col2 / - col0 FROM tab2 AS cor0
----
-10
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 37 * + col0 + + col1 col2 FROM tab2 AS cor0
----
-228
-2827
-2906

query I rowsort
SELECT + 3 * col0 + - col2 * - col1 AS col0 FROM tab0 AS cor0
----
202
2910
7729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 + - col2 * col0 * + 13 + + col1 col2 FROM tab2 AS cor0
----
-2472
-26351
-39055

query I rowsort
SELECT DISTINCT col1 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL + tab2.col0 * + col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - + 8 + + col0 AS col0 FROM tab2 AS cor0
----
-1
70
71

query I rowsort
SELECT DISTINCT + - 77 FROM tab2 cor0
----
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-8901
SELECT + col1 DIV + col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-8901
SELECT + col1 / + col0 FROM tab1 AS cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8902
SELECT DISTINCT - col0 + + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-8902
SELECT DISTINCT - col0 + + col1 / col2 AS col0 FROM tab0 AS cor0
----
-22
-88
62

query I rowsort
SELECT - col2 * + ( + 92 ) AS col2 FROM tab2 AS cor0
----
-2392
-2484
-3496

query I rowsort
SELECT ALL + col1 - col1 * - ( - col2 ) FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT col1 * - 1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col1 * + col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL col2 * + col0 + + 11 + + col0 FROM tab1 AS cor0
----
176
3723
7771

query I rowsort
SELECT col0 + - col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + col1 * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + col0 + col2 * col1 FROM tab0 cor0
----
132
2862
7551

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab0 cor1, tab1 AS cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8912
SELECT + CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8912
SELECT + CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + 46 AS col0 FROM tab2 cor0
----
105
63
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * - ( cor0.col0 ) col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 18f45a7edd86e3eccc832dcdb6123662

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 cor2
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

query I rowsort
SELECT col2 + + 15 FROM tab0
----
16
48
97

query I rowsort
SELECT - col2 + 65 FROM tab2
----
27
38
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8918
SELECT ALL col0 * CAST( ( - col1 ) AS SIGNED ) FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-8918
SELECT ALL col0 * CAST ( ( - col1 ) AS INTEGER ) FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT col0 * ( - col2 * - col2 ) - + ( col2 + + col2 ) * - 69 AS col0 FROM tab2
----
119320
56316
8829

query I rowsort
SELECT DISTINCT + col1 + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + + cor0.col0 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + col1 + col2 * + 42 FROM tab0 AS cor0
----
139
1472
3535

query I rowsort
SELECT DISTINCT + col0 * + col0 + - col0 FROM tab0 cor0
----
1190
552
7832

query I rowsort
SELECT + 55 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT cor0.col0 * 35 + + col1 FROM tab1 AS cor0
----
131
2250
2813

query I rowsort
SELECT DISTINCT - - col1 * cor0.col2 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT col2 * - 8 FROM tab0 AS cor0
----
-264
-656
-8

query I rowsort
SELECT ALL + + 92 * - col1 AS col1 FROM tab2 AS cor0
----
-1564
-2852
-5428

query I rowsort
SELECT DISTINCT + - 21 FROM tab2 AS cor0
----
-21

query I rowsort
SELECT ALL cor0.col0 + col1 * + col0 + + col2 FROM tab0 AS cor0
----
2121
3431
8270

query I rowsort
SELECT ALL - - col0 * - cor0.col2 + - col1 AS col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT - 3 FROM tab0 AS cor0
----
-3
-3
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8933
SELECT ALL - 31 * + col0 + + col1 DIV + col1 FROM tab2 AS cor0
----
-216
-2417
-2448

skipif mysql # not compatible
query I rowsort label-8933
SELECT ALL - 31 * + col0 + + col1 / + col1 FROM tab2 AS cor0
----
-216
-2417
-2448

query I rowsort
SELECT DISTINCT - + col1 * - cor0.col0 FROM tab0 cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 68 * - col1 col0 FROM tab2 AS cor0
----
-1156
-2108
-4012

query I rowsort
SELECT ALL - col2 + + col1 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + 21 * + col1 FROM tab1 AS cor0
----
210
273
546

query I rowsort
SELECT ALL 86 AS col0 FROM tab2 AS cor0
----
86
86
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-8939
SELECT - - 71 DIV + col0 FROM tab0 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-8939
SELECT - - 71 / + col0 FROM tab0 AS cor0
----
0
2
2

query I rowsort
SELECT ALL - col0 + + col1 * col1 AS col0 FROM tab0 cor0
----
7372
8192
9374

query I rowsort
SELECT + 76 * + 54 AS col2 FROM tab2 AS cor0
----
4104
4104
4104

query I rowsort
SELECT DISTINCT + 23 + + cor0.col1 * + col0 FROM tab0 AS cor0
----
2087
3418
8122

query I rowsort
SELECT col2 * 33 - - 56 FROM tab0
----
1145
2762
89

query I rowsort
SELECT DISTINCT + col1 + + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + ( + col0 ) AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + ( col2 ) + + cor0.col1 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + 45 FROM tab0 AS cor0
----
45

query I rowsort
SELECT DISTINCT + col0 + 94 + cor0.col1 AS col2 FROM tab2 AS cor0
----
132
190
231

query I rowsort
SELECT col2 + + 79 AS col1 FROM tab0 AS cor0
----
112
161
80

query I rowsort
SELECT - - col0 + col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - - col0 * - col0 * - 59 + col2 * + col1 FROM tab2 AS cor0
----
360490
368865
3728

query I rowsort
SELECT col1 * col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 51 AS col1 FROM tab2 AS cor0
----
51
51
51

query I rowsort
SELECT ALL - col1 * + col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 97 * col1 col0 FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT ALL - col0 * col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + ( col1 ) + - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col0 * col0 + + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT + + col1 * + col2 - col1 AS col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT col1 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT 17 + col2 FROM tab0 AS cor0
----
18
50
99

query I rowsort
SELECT - 65 * col1 AS col1 FROM tab0
----
-5590
-5915
-6305

query I rowsort
SELECT DISTINCT col2 + cor0.col0 AS col1 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( + cor0.col2 ) + + ( 41 ) * - col2 col2 FROM tab2 AS cor0
----
-1092
-1134
-1596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 col2 FROM tab0 AS cor0
----
18

query I rowsort
SELECT ALL + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + 86 * col2 + + cor0.col1 FROM tab1 cor0
----
4670
4912
8269

query I rowsort
SELECT ALL + + ( col0 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - cor0.col0 * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT col0 * col1 + + ( col0 ) FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - 82 * + col1 * col0 + - ( col1 ) AS col0 FROM tab2
----
-110143
-17825
-377423

query I rowsort
SELECT 89 FROM tab1
----
89
89
89

query I rowsort
SELECT DISTINCT col2 * col0 + - col0 AS col0 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - ( cor0.col2 ) col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8976
SELECT + cor0.col0 * + col2 + + col1 DIV - col0 + col0 FROM tab1 AS cor0
----
157
3712
7760

skipif mysql # not compatible
query I rowsort label-8976
SELECT + cor0.col0 * + col2 + + col1 / - col0 + col0 FROM tab1 AS cor0
----
157
3712
7760

query I rowsort
SELECT - col1 * - col0 + + col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + + cor0.col0 * cor0.col0 * - col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT col2 * + ( 38 ) * col0 FROM tab0 AS cor0
----
1330
277324
30096

query I rowsort
SELECT ALL col1 + - col0 AS col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT - + col0 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - + col0 * col0 + col0 * - col1 AS col0 FROM tab2 AS cor0
----
-10686
-266
-7584

query I rowsort
SELECT col0 * 88 + cor0.col1 * - col2 + col2 AS col2 FROM tab1 AS cor0
----
-1086
5119
5888

query I rowsort
SELECT - col2 * + 92 AS col0 FROM tab1 cor0
----
-4968
-5244
-8832

query I rowsort
SELECT - 16 + + col1 + - ( + col0 ) AS col0 FROM tab2
----
-35
-78
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8986
SELECT - col0 DIV + col1 - + ( col1 ) * tab2.col2 AS col0 FROM tab2
----
-1535
-650
-837

skipif mysql # not compatible
query I rowsort label-8986
SELECT - col0 / + col1 - + ( col1 ) * tab2.col2 AS col0 FROM tab2
----
-1535
-650
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 + col1 col1 FROM tab0
----
2150
3492
8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8988
SELECT ALL - CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8988
SELECT ALL - CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 + col0 * - 38 col2 FROM tab1
----
-117
-2496
-3120

query I rowsort
SELECT ALL - - col1 + 66 FROM tab2 AS cor0
----
125
83
97

query I rowsort
SELECT DISTINCT - col1 * - col1 + col0 AS col2 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT ALL + col2 * + col2 - col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT + col0 - - 16 FROM tab2 AS cor0
----
23
94
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8994
SELECT ALL tab2.col1 DIV + tab2.col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8994
SELECT ALL tab2.col1 / + tab2.col1 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8995
SELECT 99 DIV + 51 + col0 DIV + col2 col0 FROM tab1
----
1
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8995
SELECT 99 / + 51 + col0 / + col2 col0 FROM tab1
----
1
1
2

query I rowsort
SELECT DISTINCT 49 AS col2 FROM tab2, tab0 cor0
----
49

query I rowsort
SELECT - ( + col0 ) * + 92 FROM tab0 AS cor0
----
-2208
-3220
-8188

query I rowsort
SELECT + 16 - + col0 FROM tab1
----
-48
-64
13

query I rowsort
SELECT + 72 FROM tab0 AS cor0
----
72
72
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9000
SELECT ALL col0 * - tab1.col0 * CAST( NULL AS DECIMAL ) + - 60 * - col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9000
SELECT ALL col0 * - tab1.col0 * CAST ( NULL AS REAL ) + - 60 * - col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9001
SELECT - tab1.col0 DIV col0 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9001
SELECT - tab1.col0 / col0 AS col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT + col1 * + col0 * + ( + col1 ) + col0 FROM tab0 AS cor0
----
177528
329350
737098

query I rowsort
SELECT DISTINCT - col0 + - cor0.col0 * ( - col1 ) FROM tab2 cor0
----
1264
210
4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * - tab0.col2 * col2 + - col0 col0 FROM tab0
----
-35961
-36
-551457

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col2 * 99 + col0 col1 FROM tab2
----
2626
2653
3803

query I rowsort
SELECT DISTINCT + 82 AS col2 FROM tab0 cor0
----
82

query I rowsort
SELECT col1 * cor0.col1 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
110
182
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9008
SELECT ALL col0 * col2 + + CAST( - 14 AS SIGNED ) AS col1 FROM tab0 cor0
----
21
7284
778

skipif mysql # not compatible
query I rowsort label-9008
SELECT ALL col0 * col2 + + CAST ( - 14 AS INTEGER ) AS col1 FROM tab0 cor0
----
21
7284
778

query I rowsort
SELECT ALL - col2 * + col1 * + 30 FROM tab0 AS cor0
----
-223860
-2910
-85140

onlyif mysql # use DIV operator for integer division
query I rowsort label-9010
SELECT - + col2 + - col1 * col0 + col0 DIV col2 AS col2 FROM tab0 AS cor0
----
-2097
-3361
-8180

skipif mysql # not compatible
query I rowsort label-9010
SELECT - + col2 + - col1 * col0 + col0 / col2 AS col2 FROM tab0 AS cor0
----
-2097
-3361
-8180

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 1d38a1a4aacea9827ed2338191291f0e

query I rowsort
SELECT ALL - - cor0.col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - + cor0.col1 * col1 + col0 * col1 FROM tab1 AS cor0
----
-598
540
871

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 * col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT col1 - col1 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ( - 10 ) * + cor0.col1 FROM tab0 AS cor0
----
-860
-910
-970

query I rowsort
SELECT 28 * 77 AS col1 FROM tab1
----
2156
2156
2156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + 35 - + col2 * 98 * col2 col0 FROM tab2 AS cor0
----
-141398
-66135
-71400

query I rowsort
SELECT + 35 AS col0 FROM tab2 AS cor0
----
35
35
35

query I rowsort
SELECT col1 * 10 - col0 FROM tab2 AS cor0
----
303
512
91

query I rowsort
SELECT col1 + 35 FROM tab1 AS cor0
----
45
48
61

query I rowsort
SELECT - cor0.col2 + - cor0.col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + ( + 99 ) - - col1 FROM tab2 AS cor0
----
116
130
158

query I rowsort
SELECT - 70 AS col2 FROM tab0 AS cor0
----
-70
-70
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9025
SELECT - 92 DIV + col1 + 96 * 45 FROM tab2 AS cor0
----
4315
4318
4319

skipif mysql # not compatible
query I rowsort label-9025
SELECT - 92 / + col1 + 96 * 45 FROM tab2 AS cor0
----
4315
4318
4319

query I rowsort
SELECT cor0.col2 * 19 FROM tab2, tab0 AS cor0
----
9 values hashing to 747894a9126ad3d3f44cf80b407a42e9

query I rowsort
SELECT DISTINCT - col2 * + 36 AS col1 FROM tab1
----
-1944
-2052
-3456

query I rowsort
SELECT DISTINCT - ( - tab1.col1 ) FROM tab1
----
10
13
26

query I rowsort
SELECT - 26 AS col0 FROM tab0
----
-26
-26
-26

query I rowsort
SELECT DISTINCT - col2 * + 21 + + ( - col2 * + ( - col1 ) ) FROM tab1 AS cor0
----
-627
-768
270

query I rowsort
SELECT - col1 + col2 * cor0.col0 * - col2 AS col0 FROM tab2 AS cor0
----
-114093
-5134
-52787

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 62 * - col1 col0 FROM tab2
----
-1016
-1895
-3632

query I rowsort
SELECT DISTINCT 37 + 5 AS col2 FROM tab0, tab1 AS cor0
----
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - 58 col0 FROM tab0
----
-25
-57
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9035
SELECT col2 * tab0.col2 DIV col0 FROM tab0
----
0
45
75

skipif mysql # not compatible
query I rowsort label-9035
SELECT col2 * tab0.col2 / col0 FROM tab0
----
0
45
75

query I rowsort
SELECT + ( col2 ) + col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9037
SELECT - cor0.col1 * + col1 - col0 DIV - ( - col2 ) AS col0 FROM tab0 AS cor0
----
-7396
-8282
-9444

skipif mysql # not compatible
query I rowsort label-9037
SELECT - cor0.col1 * + col1 - col0 / - ( - col2 ) AS col0 FROM tab0 AS cor0
----
-7396
-8282
-9444

query I rowsort
SELECT DISTINCT - 74 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-74

query I rowsort
SELECT ALL + + col1 * 94 FROM tab2 AS cor0
----
1598
2914
5546

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col1 * col2 col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT + col2 * + col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 96 FROM tab2 AS cor0
----
96

query I rowsort
SELECT - + col0 * + col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - + cor0.col2 * - col1 * + col0 AS col0 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT col2 - + 81 AS col1 FROM tab0
----
-48
-80
1

query I rowsort
SELECT DISTINCT - col2 - col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT - 6 * col0 AS col1 FROM tab1
----
-18
-384
-480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9048
SELECT CAST( + 38 AS SIGNED ) + - col0 AS col1 FROM tab2
----
-40
-41
31

skipif mysql # not compatible
query I rowsort label-9048
SELECT CAST ( + 38 AS INTEGER ) + - col0 AS col1 FROM tab2
----
-40
-41
31

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab0 cor1
----
243 values hashing to 3a953203ced079e372111d61dbd9e35f

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT + ( col2 ) AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT 44 * - cor0.col2 + cor0.col1 FROM tab0 AS cor0
----
-1366
-3517
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9053
SELECT col2 + col2 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9053
SELECT col2 + col2 * + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + + tab0.col2 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT - col1 * 89 AS col2 FROM tab1 AS cor0
----
-1157
-2314
-890

query I rowsort
SELECT cor0.col0 + + col1 * + 4 AS col1 FROM tab0 AS cor0
----
368
423
453

query I rowsort
SELECT 12 + - cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to d6a74666e1b7efcd0b579ebe35ee0017

query I rowsort
SELECT ( + 43 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT ALL col0 * col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - cor0.col2 * cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - - col1 * - col2 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9062
SELECT + col2 + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9062
SELECT + col2 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL col2 + tab2.col0 AS col0 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9065
SELECT DISTINCT + ( + col1 * + col2 ) + + CAST( 9 AS SIGNED ) + col2 DIV + col1 FROM tab1
----
1264
1415
584

skipif mysql # not compatible
query I rowsort label-9065
SELECT DISTINCT + ( + col1 * + col2 ) + + CAST ( 9 AS INTEGER ) + col2 / + col1 FROM tab1
----
1264
1415
584

query I rowsort
SELECT - 52 * - col1 FROM tab2
----
1612
3068
884

query I rowsort
SELECT + 5 + - 22 + col1 * col1 AS col0 FROM tab1 AS cor0
----
152
659
83

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

query I rowsort
SELECT col2 * + col0 + col1 AS col2 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT ALL + 58 + 94 * - tab0.col0 AS col0 FROM tab0
----
-2198
-3232
-8308

query I rowsort
SELECT - col0 * - 13 * + col0 + col0 FROM tab2
----
644
79170
81212

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( + 52 AS REAL ) + + col0 + + 40 FROM tab1
----
-9
52
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-9073
SELECT 79 DIV col1 AS col1 FROM tab1 cor0
----
3
6
7

skipif mysql # not compatible
query I rowsort label-9073
SELECT 79 / col1 AS col1 FROM tab1 cor0
----
3
6
7

query I rowsort
SELECT ALL col0 * col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT + 4 * col2 + + cor0.col1 + - col2 AS col2 FROM tab2 AS cor0
----
112
131
137

query I rowsort
SELECT DISTINCT 58 * col0 FROM tab1
----
174
3712
4640

query I rowsort
SELECT DISTINCT + + col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9078
SELECT + cor0.col1 + + cor0.col2 DIV - col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-9078
SELECT + cor0.col1 + + cor0.col2 / - col2 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL - 74 FROM tab1 AS cor0
----
-74
-74
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-9080
SELECT - col2 DIV cor0.col0 + col1 * 80 AS col1 FROM tab0 AS cor0
----
6879
7280
7760

skipif mysql # not compatible
query I rowsort label-9080
SELECT - col2 / cor0.col0 + col1 * 80 AS col1 FROM tab0 AS cor0
----
6879
7280
7760

query I rowsort
SELECT DISTINCT + ( col1 ) AS col2 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT 80 * col0 AS col0 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT DISTINCT - 91 AS col1 FROM tab0 AS cor0
----
-91

query I rowsort
SELECT ALL cor0.col1 * - cor0.col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col2 * + col0 + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + 17 * cor0.col1 FROM tab2 AS cor0
----
1003
289
527

query IIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab2, tab1 AS cor1
----
243 values hashing to 877a8dbac0e29b86e845fb64ed9d2242

query I rowsort
SELECT col1 - - 25 AS col0 FROM tab2 AS cor0
----
42
56
84

query I rowsort
SELECT ALL - col1 - + 27 AS col1 FROM tab1
----
-37
-40
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-9091
SELECT DISTINCT + col0 DIV 24 + col1 FROM tab0 AS cor0
----
87
94
98

skipif mysql # not compatible
query I rowsort label-9091
SELECT DISTINCT + col0 / 24 + col1 FROM tab0 AS cor0
----
87
94
98

query I rowsort
SELECT ALL + + col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL col1 + 13 AS col2 FROM tab2 AS cor0
----
30
44
72

query I rowsort
SELECT DISTINCT - + col1 * - col1 + col1 * cor0.col0 FROM tab2 AS cor0
----
1178
1632
8083

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 + - col2 * + col2 + - col2 col2 FROM tab0 AS cor0
----
-1155
-3
-6888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9096
SELECT ALL cor0.col2 + - CAST( NULL AS SIGNED ) / - col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9096
SELECT ALL cor0.col2 + - CAST ( NULL AS INTEGER ) / - col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * ( + cor0.col1 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - 84 * + col2 + + col2 AS col2 FROM tab1 cor0
----
-4482
-4731
-7968

query I rowsort
SELECT - + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + - col1 * + 22 + - col1 AS col2 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT DISTINCT + 53 + col2 * col0 + + ( - col1 ) * col2 * - col0 FROM tab1 AS cor0
----
107573
40181
4427

query I rowsort
SELECT DISTINCT - + col0 * col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT 91 FROM tab0, tab2 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT + 56 - - cor0.col1 * col0 AS col1 FROM tab0 AS cor0
----
2120
3451
8155

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab0 cor1, tab0 AS cor2
----
972 values hashing to 3a31dab513390ca6bd05c71a3d9c50f0

query I rowsort
SELECT + col2 * + col0 + - col0 + col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - - cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - 82 * 73 + - col1 + 95 AS col0 FROM tab2 AS cor0
----
-5908
-5922
-5950

query I rowsort
SELECT 11 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT ALL - + col1 + - col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 42e69ecdafb3c81046bc5cb4c98b1666

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9112
SELECT ALL - col1 * col2 - col0 * CAST( NULL AS SIGNED ) * - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9112
SELECT ALL - col1 * col2 - col0 * CAST ( NULL AS INTEGER ) * - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col0 + col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
16896
3078
6897

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9114
SELECT DISTINCT - CAST( 67 AS SIGNED ) FROM tab0 cor0
----
-67

skipif mysql # not compatible
query I rowsort label-9114
SELECT DISTINCT - CAST ( 67 AS INTEGER ) FROM tab0 cor0
----
-67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9115
SELECT DISTINCT + CAST( + cor0.col0 AS SIGNED ) * cor0.col2 + - ( - col0 ) AS col1 FROM tab1 AS cor0
----
165
3712
7760

skipif mysql # not compatible
query I rowsort label-9115
SELECT DISTINCT + CAST ( + cor0.col0 AS INTEGER ) * cor0.col2 + - ( - col0 ) AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - ( col2 ) * - col0 + ( cor0.col1 * col1 ) FROM tab1 AS cor0
----
3748
7849
838

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9117
SELECT - - CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-9117
SELECT - - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + col1 - - col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL - - col0 + col1 * col0 AS col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT - 27 FROM tab0 cor0
----
-27

query I rowsort
SELECT ALL col0 * + col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + ( - col2 ) + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + col2 * col0 + + col1 * + 32 AS col0 FROM tab1 AS cor0
----
3968
8096
994

query I rowsort
SELECT ALL + + ( + col1 ) * - col0 + - col1 * - col2 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT + 40 AS col0 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT ALL cor0.col0 - - col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - 4 AS col2 FROM tab0 AS cor0
----
-4
-4
-4

query I rowsort
SELECT + 55 FROM tab2 AS cor0
----
55
55
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9129
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9129
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 * 2 * col2 FROM tab1 cor0
----
-15360
-324
-7296

query I rowsort
SELECT ALL + 8 + col0 AS col0 FROM tab0 AS cor0
----
32
43
97

query I rowsort
SELECT col1 * + ( - col1 + + col2 ) AS col2 FROM tab1 cor0
----
1079
470
728

query I rowsort
SELECT DISTINCT - col1 * - col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9134
SELECT + + CAST( - 80 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-80
-80
-80

skipif mysql # not compatible
query I rowsort label-9134
SELECT + + CAST ( - 80 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-80
-80
-80

query I rowsort
SELECT ALL + col2 + - 39 FROM tab0 AS cor0
----
-38
-6
43

query I rowsort
SELECT ALL ( col2 ) + tab1.col2 * 22 AS col1 FROM tab1
----
1242
1311
2208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1 cor1
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

query I rowsort
SELECT 76 * + tab1.col0 FROM tab1
----
228
4864
6080

query I rowsort
SELECT ALL tab2.col2 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL + + cor0.col2 * col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT col0 + - col0 * 5 FROM tab1
----
-12
-256
-320

query I rowsort
SELECT col1 - + col0 * - 38 * - 3 AS col2 FROM tab1
----
-316
-7286
-9107

query I rowsort
SELECT + ( - 51 ) AS col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

query I rowsort
SELECT ALL - + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT + col2 * col2 * - tab2.col2 AS col0 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab1, tab2 AS cor0
----
92

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT col0 + + ( col0 ) AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort
SELECT ALL - + col1 + - CAST ( col1 AS REAL ) * + col2 AS col0 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9152
SELECT ALL col2 + CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9152
SELECT ALL col2 + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 AS col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT - col1 * - ( - col2 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT col1 + col1 AS col2 FROM tab2
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9156
SELECT DISTINCT + tab2.col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9156
SELECT DISTINCT + tab2.col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT + - col1 + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT 24 AS col1 FROM tab2
----
24
24
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 col0 FROM tab2
----
60
60
60

query I rowsort
SELECT DISTINCT - - cor0.col0 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - + col2 + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) * col1 * cor0.col1 col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9164
SELECT ALL + col1 / - col1 + CAST( NULL AS SIGNED ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9164
SELECT ALL + col1 / - col1 + CAST ( NULL AS INTEGER ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 82 FROM tab1 AS cor0
----
-82
-82
-82

query I rowsort
SELECT + col1 + - col2 * + cor0.col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - - col1 - col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT col1 * cor0.col1 + - 41 + - col0 * col2 * - 17 AS col2 FROM tab0 AS cor0
----
132306
20819
9963

onlyif mysql # use DIV operator for integer division
query I rowsort label-9169
SELECT + col0 DIV 50 + cor0.col1 FROM tab2 AS cor0
----
18
31
60

skipif mysql # not compatible
query I rowsort label-9169
SELECT + col0 / 50 + cor0.col1 FROM tab2 AS cor0
----
18
31
60

query I rowsort
SELECT DISTINCT col0 * - ( - col2 + tab1.col1 ) FROM tab1
----
3008
6640
84

query I rowsort
SELECT DISTINCT - + col0 * col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT cor0.col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9173
SELECT col1 - - 35 DIV col1 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9173
SELECT col1 - - 35 / col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT 55 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT DISTINCT + col2 * - ( + cor0.col0 ) FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - ( col0 ) * + col1 - + col1 FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - 23 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
-23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9178
SELECT ALL - CAST( NULL AS SIGNED ) / + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9178
SELECT ALL - CAST ( NULL AS INTEGER ) / + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col2 ) * + col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT cor2.col2 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
1
33
82

query I rowsort
SELECT ALL 55 FROM tab2 AS cor0
----
55
55
55

query I rowsort
SELECT + cor1.col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + - ( col0 ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 18 FROM tab0 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + + 64 * col0 AS col0 FROM tab2 AS cor0
----
448
4992
5056

query I rowsort
SELECT - + col2 + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT cor0.col0 * + col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - col1 + tab0.col2 * + col2 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT ALL tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT 0 AS col2 FROM tab0
----
0

query I rowsort
SELECT + ( tab2.col1 ) FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 15 + col2 col2 FROM tab2
----
11
12
23

query I rowsort
SELECT DISTINCT + 81 AS col2 FROM tab0
----
81

query I rowsort
SELECT tab2.col2 + col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT + col0 + - col1 * col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT 29 * + col2 + col2 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT - 11 FROM tab2, tab1 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT DISTINCT ( - col0 ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col0 + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - - col1 * col0 + - col0 * + col0 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT - 18 FROM tab0, tab2 cor0, tab0 cor1
----
27 values hashing to 2dbe09d9295cfd52d854fefabf2cec4e

query I rowsort
SELECT DISTINCT + + cor0.col1 + col2 * 11 FROM tab2 AS cor0
----
328
345
435

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL tab0.col1 * + col0 AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - 24 FROM tab0 AS cor0
----
-24
-24
-24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9206
SELECT CAST( NULL AS DECIMAL ) * + 69 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9206
SELECT CAST ( NULL AS REAL ) * + 69 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 66 AS col2 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9208
SELECT DISTINCT col1 * - CAST( NULL AS SIGNED ) * 46 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9208
SELECT DISTINCT col1 * - CAST ( NULL AS INTEGER ) * 46 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9209
SELECT + col2 DIV ( - col2 ) col1 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9209
SELECT + col2 / ( - col2 ) col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - col0 * 79 * col0 FROM tab0
----
-45504
-625759
-96775

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9211
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9211
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + ( 73 ) - - col1 FROM tab1
----
83
86
99

query I rowsort
SELECT ALL 8 AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

onlyif mysql # use DIV operator for integer division
query I rowsort label-9214
SELECT + 57 + col1 * col2 DIV col2 AS col1 FROM tab1 AS cor0
----
67
70
83

skipif mysql # not compatible
query I rowsort label-9214
SELECT + 57 + col1 * col2 / col2 AS col1 FROM tab1 AS cor0
----
67
70
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9215
SELECT col2 + col1 DIV - col1 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-9215
SELECT col2 + col1 / - col1 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT + - cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + + 88 * cor0.col1 * col1 + + 70 FROM tab1 AS cor0
----
14942
59558
8870

query I rowsort
SELECT + - col0 + - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + 73 FROM tab0 AS cor0
----
73
73
73

query I rowsort
SELECT - 47 * + cor0.col2 + + cor0.col1 FROM tab0 AS cor0
----
-1465
-3763
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * col1 * - col0 + col1 * 75 col2 FROM tab0 cor0
----
-61662
-657293
3880

query I rowsort
SELECT + + cor0.col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col1 * 88 - - 94 * + cor0.col1 FROM tab2 AS cor0
----
10738
3094
5642

query I rowsort
SELECT DISTINCT col1 + col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL - cor0.col0 * + col0 + - 72 AS col1 FROM tab0 AS cor0
----
-1297
-648
-7993

query I rowsort
SELECT ALL + + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + col2 col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL + col0 + + 38 AS col1 FROM tab0 cor0
----
127
62
73

query I rowsort
SELECT DISTINCT + + cor0.col1 + - col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + col0 * - 73 + + col2 AS col1 FROM tab1 cor0
----
-165
-4615
-5744

query I rowsort
SELECT + + col0 * col0 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL + + 22 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT DISTINCT - col0 - + col2 * col1 AS col2 FROM tab0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-9234
SELECT cor0.col1 - cor0.col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-9234
SELECT cor0.col1 - cor0.col2 / - col1 AS col2 FROM tab2 AS cor0
----
19
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9235
SELECT DISTINCT + col2 DIV col1 AS col2 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-9235
SELECT DISTINCT + col2 / col1 AS col2 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT - tab2.col2 + 62 + tab2.col1 * tab2.col2 FROM tab2
----
1570
670
872

query I rowsort
SELECT + col1 + col2 AS col0 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9238
SELECT col2 DIV + ( - col0 * col1 ) + + col1 * - 53 * - col1 FROM tab2
----
15317
184493
50933

skipif mysql # not compatible
query I rowsort label-9238
SELECT col2 / + ( - col0 * col1 ) + + col1 * - 53 * - col1 FROM tab2
----
15317
184493
50933

query I rowsort
SELECT + 72 + - col1 AS col0 FROM tab1 cor0
----
46
59
62

query I rowsort
SELECT - col0 * + col0 * col0 + tab1.col2 FROM tab1
----
-262087
-511904
27

query I rowsort
SELECT DISTINCT - tab2.col1 + - col1 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9243
SELECT + col2 * CAST( - col0 AS SIGNED ) FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-9243
SELECT + col2 * CAST ( - col0 AS INTEGER ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col2 - 18 AS col1 FROM tab2
----
20
8
9

query I rowsort
SELECT - col2 + - col2 FROM tab0
----
-164
-2
-66

query I rowsort
SELECT col2 + - tab2.col0 * col2 AS col0 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT + col1 * - 3 FROM tab1
----
-30
-39
-78

query I rowsort
SELECT ALL col1 + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9249
SELECT DISTINCT + - cor0.col2 * ( + 71 ) + col2 DIV - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1846
-1917
-2700

skipif mysql # not compatible
query I rowsort label-9249
SELECT DISTINCT + - cor0.col2 * ( + 71 ) + col2 / - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1846
-1917
-2700

query I rowsort
SELECT ALL - col2 + 0 * + 44 FROM tab2
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 36 col2 FROM tab0
----
118
37
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-9252
SELECT col1 DIV col1 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9252
SELECT col1 / col1 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT - 31 AS col0 FROM tab2
----
-31
-31
-31

query I rowsort
SELECT 52 AS col2 FROM tab0
----
52
52
52

query I rowsort
SELECT ALL col2 * - 86 * col0 AS col2 FROM tab0
----
-3010
-627628
-68112

query I rowsort
SELECT cor0.col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + - col1 + - col0 AS col1 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT col2 + - cor0.col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + 58 * + cor0.col1 FROM tab2 AS cor0
----
1798
3422
986

query I rowsort
SELECT ALL - - col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + 68 FROM tab2, tab1 cor0, tab1 AS cor1, tab0 AS cor2
----
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9262
SELECT ALL + CAST( NULL AS SIGNED ) * - tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9262
SELECT ALL + CAST ( NULL AS INTEGER ) * - tab1.col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - - 1 * col2 AS col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9264
SELECT ALL + col1 * col1 + + CAST( col1 AS SIGNED ) * col2 FROM tab2 AS cor0
----
1798
5015
935

skipif mysql # not compatible
query I rowsort label-9264
SELECT ALL + col1 * col1 + + CAST ( col1 AS INTEGER ) * col2 FROM tab2 AS cor0
----
1798
5015
935

onlyif mysql # use DIV operator for integer division
query I rowsort label-9265
SELECT + - col1 + - col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-9265
SELECT + - col1 + - col2 / + col2 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT ALL - col1 * - col2 + cor0.col0 * col2 AS col0 FROM tab2 cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT - col0 - col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - col1 * + col2 * col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL col1 + - col0 * col1 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT 86 * - col0 FROM tab1 AS cor0
----
-258
-5504
-6880

query I rowsort
SELECT DISTINCT col0 + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL + col1 * col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col2 * col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-9274
SELECT col0 DIV tab0.col0 + ( - tab0.col2 ) AS col0 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-9274
SELECT col0 / tab0.col0 + ( - tab0.col2 ) AS col0 FROM tab0
----
-32
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT 70 FROM tab1
----
70
70
70

query I rowsort
SELECT + col0 + + col2 AS col0 FROM tab1
----
121
176
57

query I rowsort
SELECT + 85 FROM tab0
----
85
85
85

query I rowsort
SELECT + 10 FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT ALL - + col0 * col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 11 FROM tab1 AS cor0
----
11

query I rowsort
SELECT DISTINCT + 73 AS col1 FROM tab2 AS cor0
----
73

query I rowsort
SELECT ALL col2 + - col2 * 20 FROM tab0 cor0
----
-1558
-19
-627

query I rowsort
SELECT DISTINCT 59 AS col1 FROM tab2
----
59

query I rowsort
SELECT DISTINCT + - col1 + - cor0.col0 * - col1 FROM tab1 AS cor0
----
1027
52
630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col1 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9287
SELECT ALL - + col1 DIV col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9287
SELECT ALL - + col1 / col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9288
SELECT - - col2 + cor0.col1 DIV - col2 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9288
SELECT - - col2 + cor0.col1 / - col2 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 59 col2 FROM tab1 AS cor0
----
113
116
155

query I rowsort
SELECT DISTINCT col2 * ( col1 ) FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9291
SELECT - col2 DIV + 99 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9291
SELECT - col2 / + 99 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col2 * + 88 FROM tab0 AS cor0
----
2904
7216
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - ( - 7 ) col1 FROM tab1 AS cor0
----
-182
-70
-91

query I rowsort
SELECT DISTINCT + col0 + 28 AS col1 FROM tab2 cor0
----
106
107
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 * + col1 col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-9297
SELECT col2 DIV - col0 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-9297
SELECT col2 / - col0 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT ALL 10 * col2 + col2 FROM tab0 AS cor0
----
11
363
902

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9299
SELECT ALL + + CAST( - col0 AS SIGNED ) * - cor0.col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-9299
SELECT ALL + + CAST ( - col0 AS INTEGER ) * - cor0.col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - 90 + + 15 AS col0 FROM tab2 cor0
----
-75
-75
-75

query I rowsort
SELECT ALL + cor0.col0 + + ( col1 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT ( 56 ) * col1 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT DISTINCT col0 * + ( - col0 ) FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + - 92 + + 17 * cor0.col0 FROM tab2 AS cor0
----
1234
1251
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-9306
SELECT DISTINCT - - col1 DIV - 91 - + col1 * col2 FROM tab0 AS cor0
----
-2838
-7463
-98

skipif mysql # not compatible
query I rowsort label-9306
SELECT DISTINCT - - col1 / - 91 - + col1 * col2 FROM tab0 AS cor0
----
-2838
-7463
-98

query I rowsort
SELECT DISTINCT + 95 * - 99 * + col2 FROM tab2 AS cor0
----
-244530
-253935
-357390

query I rowsort
SELECT DISTINCT col1 + + col0 AS col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT 14 * col2 AS col2 FROM tab0 AS cor0
----
1148
14
462

query I rowsort
SELECT ALL - cor0.col1 * col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 + + 1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT DISTINCT - - col0 * - col0 - cor0.col2 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT DISTINCT - + ( - ( + col1 ) ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 26 * col1 + col2 FROM tab0 AS cor0
----
-2203
-2284
-2521

query I rowsort
SELECT ALL 41 + + col0 AS col2 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT 32 * col2 AS col2 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT + ( cor0.col1 ) * + col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT ( col1 ) * - col0 FROM tab1 AS cor0
----
-1040
-640
-78

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to db56d052e81a1ceebb4c3aea124670be

query I rowsort
SELECT ALL 26 AS col1 FROM tab0 cor0
----
26
26
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9321
SELECT DISTINCT tab0.col1 DIV col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-9321
SELECT DISTINCT tab0.col1 / col0 FROM tab0
----
1
2
3

query I rowsort
SELECT + 81 FROM tab2
----
81
81
81

query I rowsort
SELECT - 88 FROM tab2, tab2 cor0 CROSS JOIN tab1
----
27 values hashing to eb8cbefa7d831e1a0183e919e2caef32

query I rowsort
SELECT + 91 * + col1 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT DISTINCT - col2 * - col2 AS col1 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT + col0 * col2 + - 32 AS col1 FROM tab1
----
130
3616
7648

query I rowsort
SELECT + col2 + + col0 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9328
SELECT DISTINCT + col1 DIV + 10 FROM tab0
----
8
9

skipif mysql # not compatible
query I rowsort label-9328
SELECT DISTINCT + col1 / + 10 FROM tab0
----
8
9

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT - ( tab0.col1 ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT - 4 * ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-344
-364
-388

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col0 + 55 * col2 FROM tab0 AS cor0
----
1791
20
4421

query I rowsort
SELECT - - col0 * + col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query IIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab1 cor1
----
54 values hashing to b010e320d66ab5b2711fc14e8fb58b01

query I rowsort
SELECT DISTINCT + - col2 * - col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT col2 * cor0.col1 + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + + 90 AS col0 FROM tab1 AS cor0
----
90
90
90

query I rowsort
SELECT DISTINCT - cor0.col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + + 40 + - col0 FROM tab1 AS cor0
----
-24
-40
37

query I rowsort
SELECT ALL - col2 + col2 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9343
SELECT DISTINCT col2 DIV col2 AS col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-9343
SELECT DISTINCT col2 / col2 AS col2 FROM tab0
----
1

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab2 cor1
----
243 values hashing to 2248b8c3b6efacb4e8fc6d9f81b7df8b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 81 col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-81

query I rowsort
SELECT DISTINCT + col0 * + col1 AS col1 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort
SELECT - col1 + + CAST ( - 65 AS REAL ) AS col0 FROM tab1 cor0
----
-75
-78
-91

query I rowsort
SELECT + cor0.col0 + col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT + 3 * 49 FROM tab0, tab1 cor0
----
9 values hashing to 7ea90b86e1b35d6116fcda7346d04909

query I rowsort
SELECT ALL - col1 * col0 AS col2 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9351
SELECT ALL - col2 + 12 + - ( col1 ) DIV + col1 AS col2 FROM tab0
----
-22
-71
10

skipif mysql # not compatible
query I rowsort label-9351
SELECT ALL - col2 + 12 + - ( col1 ) / + col1 AS col2 FROM tab0
----
-22
-71
10

query I rowsort
SELECT - - col2 + - col1 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT + col0 + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + - col2 * col2 * 14 AS col2 FROM tab0 AS cor0
----
-14
-15246
-94136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9355
SELECT - col2 * + CAST( NULL AS SIGNED ) + - 75 + + col0 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9355
SELECT - col2 * + CAST ( NULL AS INTEGER ) + - 75 + + col0 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 * - 84 + + 55 * - col0 FROM tab1 AS cor0
----
-2349
-4360
-5492

query I rowsort
SELECT - col2 + + ( 6 ) FROM tab0 AS cor0
----
-27
-76
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 81 + col0 col2 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT + + col0 * - col0 + 56 FROM tab2 AS cor0
----
-6028
-6185
7

query I rowsort
SELECT ALL - + 23 FROM tab1 AS cor0
----
-23
-23
-23

query I rowsort
SELECT DISTINCT + - col0 + 95 * col0 FROM tab1 AS cor0
----
282
6016
7520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - 8 * col1 col1 FROM tab0 AS cor0
----
-22704
-59696
-776

onlyif mysql # use DIV operator for integer division
query I rowsort label-9363
SELECT DISTINCT + col0 DIV col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9363
SELECT DISTINCT + col0 / col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT + 8 * - 64 AS col0 FROM tab1 AS cor0
----
-512
-512
-512

onlyif mysql # use DIV operator for integer division
query I rowsort label-9365
SELECT - col0 DIV ( - cor0.col0 ) FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9365
SELECT - col0 / ( - cor0.col0 ) FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT + cor0.col1 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to f655b6f4c5b9ff73813030f2822ea1fd

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT - 51 AS col2 FROM tab1, tab0 AS cor0
----
-51

query I rowsort
SELECT col1 * 19 AS col1 FROM tab2 AS cor0
----
1121
323
589

query I rowsort
SELECT ALL + - ( col0 ) + cor0.col2 * - ( - col1 * col1 ) FROM tab0 AS cor0
----
244044
678953
9374

query I rowsort
SELECT DISTINCT - col2 * + 22 AS col0 FROM tab1 AS cor0
----
-1188
-1254
-2112

query I rowsort
SELECT 28 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to f1fc3f16747aca82b54b2b759d1f5ea2

query I rowsort
SELECT ALL ( ( - col0 ) ) + - col2 * + col2 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT col0 + - cor0.col0 * ( col2 ) AS col1 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9377
SELECT + col2 DIV - col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9377
SELECT + col2 / - col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT col0 + tab0.col2 + tab0.col1 * 80 * + tab0.col1 FROM tab0
----
591737
662651
752756

query I rowsort
SELECT - + col0 + - col0 FROM tab0 AS cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 44 col2 FROM tab1, tab2 AS cor0
----
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 28 + + col1 col0 FROM tab1 AS cor0
----
38
41
54

query I rowsort
SELECT DISTINCT - col1 + col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 89 FROM tab1, tab0 AS cor0, tab2 cor1
----
89

query I rowsort
SELECT cor0.col2 * ( cor0.col2 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 50c4b0a13fc95d13442dcf4b04857ce8

query I rowsort
SELECT ALL + ( 21 ) AS col2 FROM tab0
----
21
21
21

query I rowsort
SELECT + col2 * - col0 - col1 AS col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT col1 + + col1 * + cor0.col2 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ALL - - ( col0 ) * + col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL col1 * + col2 + col0 AS col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-9390
SELECT ALL + + col2 DIV col1 + col0 * - cor0.col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-9390
SELECT ALL + + col2 / col1 + col0 * - cor0.col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT 48 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * - ( col1 ) col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + - col0 AS col0 FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9394
SELECT - col0 * - CAST( + 42 AS SIGNED ) + + col1 * ( - col2 ) FROM tab0 AS cor0
----
-1830
-3724
1373

skipif mysql # not compatible
query I rowsort label-9394
SELECT - col0 * - CAST ( + 42 AS INTEGER ) + + col1 * ( - col2 ) FROM tab0 AS cor0
----
-1830
-3724
1373

query I rowsort
SELECT ALL col0 + 85 * - 36 FROM tab1 AS cor0
----
-2980
-2996
-3057

query I rowsort
SELECT ALL 59 + col0 - col1 FROM tab1
----
113
126
36

query I rowsort
SELECT DISTINCT + col0 * + col1 - + ( col0 ) * + col2 FROM tab2
----
-1659
2574
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-9398
SELECT - col2 * col0 DIV + col1 FROM tab1
----
-364
-590
-6

skipif mysql # not compatible
query I rowsort label-9398
SELECT - col2 * col0 / + col1 FROM tab1
----
-364
-590
-6

query I rowsort
SELECT tab2.col1 + col2 + col2 FROM tab2
----
111
85
93

query I rowsort
SELECT - col0 + + col2 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT 7 - col0 AS col2 FROM tab0
----
-17
-28
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9402
SELECT + col0 DIV - col0 col2 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9402
SELECT + col0 / - col0 col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL + 84 + - col2 * cor0.col1 FROM tab0 AS cor0
----
-13
-2754
-7378

query I rowsort
SELECT - + col1 + cor0.col0 FROM tab2 AS cor0
----
-24
19
62

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to 0fcd8d0934383dd58863be894b07a6ed

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0, tab0 cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

query I rowsort
SELECT ( + col0 ) AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT col2 * + col0 + + col2 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT DISTINCT - 99 FROM tab2
----
-99

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - 95 AS col0 FROM tab2 AS cor0
----
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9412
SELECT DISTINCT col2 + col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9412
SELECT DISTINCT col2 + col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query III rowsort
SELECT * FROM tab1 WHERE + col0 <= ( - col2 )
----

query I rowsort
SELECT + cor0.col1 * col1 + - col2 AS col0 FROM tab0 cor0
----
7363
8199
9408

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-9416
SELECT DISTINCT - 59 DIV col2 + 80 FROM tab0 AS cor0
----
21
79
80

skipif mysql # not compatible
query I rowsort label-9416
SELECT DISTINCT - 59 / col2 + 80 FROM tab0 AS cor0
----
21
79
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + + cor0.col1 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-9419
SELECT DISTINCT - - 26 + col2 DIV col0 FROM tab2 cor0
----
26
29

skipif mysql # not compatible
query I rowsort label-9419
SELECT DISTINCT - - 26 + col2 / col0 FROM tab2 cor0
----
26
29

query I rowsort
SELECT ALL + col1 + 79 FROM tab0 AS cor0
----
165
170
176

query I rowsort
SELECT DISTINCT col1 + - col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 - col2 col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL + cor0.col2 * - col0 + + col0 * col1 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT - col0 + col1 + col1 FROM tab0 AS cor0
----
148
159
93

query I rowsort
SELECT ALL + cor0.col0 + + ( 91 ) * + col2 FROM tab0 AS cor0
----
126
3027
7551

query I rowsort
SELECT 31 + - col2 * 0 AS col1 FROM tab1
----
31
31
31

query I rowsort
SELECT + col2 * col0 + col1 * 97 * + col0 AS col2 FROM tab1
----
108560
65728
7728

query I rowsort
SELECT 67 FROM tab2
----
67
67
67

query I rowsort
SELECT - col0 * + col2 - col1 FROM tab0
----
-132
-7389
-878

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col0 * - col0 NOT IN ( + col2 * + col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col1 FROM tab1 WHERE NOT NULL <= - col0
----

query I rowsort
SELECT col2 * - col1 + - col1 FROM tab2
----
-1593
-663
-868

query III rowsort
SELECT * FROM tab1 WHERE col0 NOT BETWEEN col0 * col0 + col0 AND NULL
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 col0 FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 col1 FROM tab1
----
29
74
93

query I rowsort
SELECT - col0 + - col0 AS col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT ALL col0 * - col2 AS col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL col0 AS col1 FROM tab1 WHERE - col1 + - col1 * - col2 NOT IN ( + col1 * col2 )
----
3
64
80

query I rowsort
SELECT ALL col0 * + col0 * + col2 AS col1 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT - col1 * - col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 + + col2 * + col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT + tab1.col2 AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT col2 * + tab1.col0 + col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT col1 * col2 AS col2 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9445
SELECT ALL + col0 DIV + col1 + + col2 * col1 FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-9445
SELECT ALL + col0 / + col1 + + col2 * col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col1 + + col2 AS col2 FROM tab1
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9447
SELECT ALL + col0 + - col0 DIV col0 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-9447
SELECT ALL + col0 + - col0 / col0 FROM tab0
----
23
34
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-9448
SELECT DISTINCT - col0 DIV col1 + col1 * col2 AS col0 FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-9448
SELECT DISTINCT - col0 / col1 + col1 * col2 AS col0 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9449
SELECT col0 DIV col0 + - col2 + col2 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9449
SELECT col0 / col0 + - col2 + col2 FROM tab0
----
1
1
1

query I rowsort
SELECT + col2 * - col0 + col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT col1 * + tab1.col1 * col1 + - tab1.col1 + col2 FROM tab1
----
1047
17604
2280

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( col0 + tab2.col2 )
----

query I rowsort
SELECT DISTINCT col2 - col2 FROM tab0
----
0

query I rowsort
SELECT DISTINCT - col0 - + col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT + ( + col2 ) + - col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT 39 AS col2 FROM tab1 AS cor0
----
39
39
39

query I rowsort
SELECT + - col2 * col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT cor1.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - 28 AS col2 FROM tab2, tab0, tab1 AS cor0, tab1 AS cor1
----
81 values hashing to 70e92c218433163922867899a16e1269

query I rowsort
SELECT col2 * ( - col2 ) FROM tab1
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-9461
SELECT ALL col2 DIV 33 AS col2 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-9461
SELECT ALL col2 / 33 AS col2 FROM tab0
----
0
1
2

query I rowsort
SELECT DISTINCT - 88 - cor0.col1 FROM tab0, tab0 cor0
----
-174
-179
-185

onlyif mysql # use DIV operator for integer division
query I rowsort label-9463
SELECT col0 DIV + col2 + col0 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-9463
SELECT col0 / + col2 + col0 FROM tab0
----
24
70
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9464
SELECT ALL + + col0 + - col0 DIV - col1 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-9464
SELECT ALL + + col0 + - col0 / - col1 FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT DISTINCT + 78 FROM tab0 cor0
----
78

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT 77 + col1 AS col2 FROM tab1 AS cor0
----
103
87
90

query I rowsort
SELECT ALL - - col1 * - cor0.col2 + cor0.col1 + col1 FROM tab1 cor0
----
-1222
-1352
-550

query I rowsort
SELECT DISTINCT - col1 - col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL col2 * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + cor0.col0 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 AS col0 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT col0 * + cor0.col2 AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + + col0 * - cor0.col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 72 + + col1 col0 FROM tab1 AS cor0
----
-46
-59
-62

query I rowsort
SELECT ALL col0 * - col0 + 63 FROM tab2 AS cor0
----
-6021
-6178
14

query I rowsort
SELECT DISTINCT + 22 * cor0.col0 FROM tab0 AS cor0
----
1958
528
770

onlyif mysql # use DIV operator for integer division
query I rowsort label-9478
SELECT - + 21 DIV + col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-9478
SELECT - + 21 / + col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT DISTINCT col1 + ( + col0 ) FROM tab1
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9480
SELECT col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9480
SELECT col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + 25 FROM tab1
----
105
28
89

query I rowsort
SELECT DISTINCT - col1 * - ( ( col2 ) ) + - col1 AS col2 FROM tab1
----
1235
1378
560

query I rowsort
SELECT DISTINCT + col2 AS col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT col0 + - col2 - - cor0.col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - + col1 + 94 * + 95 AS col0 FROM tab1 AS cor0
----
8904
8917
8920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9486
SELECT DISTINCT + col2 + CAST( NULL AS SIGNED ) * + col1 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9486
SELECT DISTINCT + col2 + CAST ( NULL AS INTEGER ) * + col1 AS col0 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9487
SELECT - col2 * CAST( col0 AS SIGNED ) + col2 + cor0.col0 col2 FROM tab0 AS cor0
----
-7127
-735
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9487
SELECT - col2 * CAST ( col0 AS INTEGER ) + col2 + cor0.col0 col2 FROM tab0 AS cor0
----
-7127
-735
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 69 + - col2 + + col2 * - col0 col2 FROM tab2 AS cor0
----
-2079
-3848
-5662

query I rowsort
SELECT DISTINCT - + col0 + 67 FROM tab0 AS cor0
----
-22
32
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-9490
SELECT DISTINCT + + col2 DIV col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-9490
SELECT DISTINCT + + col2 / col1 FROM tab0 cor0
----
0

query I rowsort
SELECT - col1 * col1 + ( col1 ) FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL + - cor0.col2 * 65 + - cor0.col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT col2 + ( col0 * - col1 ) AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-9494
SELECT - col2 DIV col0 + + col0 FROM tab1 AS cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-9494
SELECT - col2 / col0 + + col0 FROM tab1 AS cor0
----
-15
64
79

query I rowsort
SELECT DISTINCT + col1 * + 75 AS col0 FROM tab0 AS cor0
----
6450
6825
7275

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9496
SELECT ALL + col2 + CAST( - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9496
SELECT ALL + col2 + CAST ( - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9497
SELECT + 57 DIV - 91 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9497
SELECT + 57 / - 91 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - - col1 + + 53 + col1 * + col2 * + col0 FROM tab1 AS cor0
----
36543
4291
99906

onlyif mysql # use DIV operator for integer division
query I rowsort label-9500
SELECT + ( col1 ) DIV col1 + - 49 * + ( cor0.col1 ) + 96 * + 46 AS col1 FROM tab0 AS cor0
----
-336
-42
203

skipif mysql # not compatible
query I rowsort label-9500
SELECT + ( col1 ) / col1 + - 49 * + ( cor0.col1 ) + 96 * + 46 AS col1 FROM tab0 AS cor0
----
-336
-42
203

query I rowsort
SELECT ALL + col0 * 73 AS col1 FROM tab0 cor0
----
1752
2555
6497

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT DISTINCT + ( 3 ) * + cor0.col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT DISTINCT + 26 * col1 AS col1 FROM tab0 AS cor0
----
2236
2366
2522

onlyif mysql # use DIV operator for integer division
query I rowsort label-9505
SELECT - - 75 DIV col0 AS col1 FROM tab1 AS cor0
----
0
1
25

skipif mysql # not compatible
query I rowsort label-9505
SELECT - - 75 / col0 AS col1 FROM tab1 AS cor0
----
0
1
25

query I rowsort
SELECT DISTINCT + 64 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + + cor0.col1 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 0bd022e691ee49f12c598975818ed537

query I rowsort
SELECT ALL ( - col0 ) * cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9509
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9509
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 13 + + col0 AS col1 FROM tab0 AS cor0
----
102
37
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 4 col0 FROM tab2 AS cor0
----
4
4
4

query I rowsort
SELECT - 59 FROM tab2 AS cor0
----
-59
-59
-59

query I rowsort
SELECT cor0.col0 * + col2 * col0 + col1 * col1 FROM tab2 AS cor0
----
161665
2284
237447

query I rowsort
SELECT - 2 + - col1 AS col2 FROM tab2 AS cor0
----
-19
-33
-61

query I rowsort
SELECT + col2 * + col0 + - col0 * col2 * + col0 AS col2 FROM tab2 AS cor0
----
-1134
-156156
-234156

query I rowsort
SELECT - 56 * col1 * - col1 FROM tab0
----
414176
463736
526904

query I rowsort
SELECT ALL 37 AS col1 FROM tab1
----
37
37
37

query I rowsort
SELECT + 78 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT - 82 + - tab0.col0 FROM tab0
----
-106
-117
-171

query I rowsort
SELECT DISTINCT + 78 AS col1 FROM tab1
----
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9521
SELECT + cor0.col2 DIV cor0.col1 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9521
SELECT + cor0.col2 / cor0.col1 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + 52 AS col0 FROM tab0
----
52

query I rowsort
SELECT + 9 FROM tab2
----
9
9
9

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1
----
243 values hashing to 3581f59ff9574f9d6290fc6bca0b5e4d

query I rowsort
SELECT - cor0.col2 + col2 AS col1 FROM tab1 cor0
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 88213a0de4c0a44aaefe8bbffbcaf44a

query I rowsort
SELECT DISTINCT col0 * + ( col0 ) + + col1 AS col0 FROM tab0
----
1322
662
8012

query I rowsort
SELECT + col0 + + col0 * + col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT ALL col1 + + col0 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT + cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT - col1 * 12 FROM tab1
----
-120
-156
-312

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col0 AS REAL ) FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT - 5 + - cor0.col1 FROM tab0, tab2 AS cor0
----
-22
-36
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * col0 col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT DISTINCT ( - tab0.col1 ) * col2 AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - ( + tab2.col2 ) * + tab2.col2 FROM tab2
----
-1444
-676
-729

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0, tab1 cor1
----
243 values hashing to 877a8dbac0e29b86e845fb64ed9d2242

query I rowsort
SELECT 15 FROM tab1, tab0 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT + col0 + 56 + - col1 AS col0 FROM tab2 AS cor0
----
118
32
75

query I rowsort
SELECT ALL + + col2 * col0 AS col0 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 col2 FROM tab1 AS cor0
----
96
96
96

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT + col2 NOT IN ( col2 + col0 )
----

query I rowsort
SELECT ALL + col0 - tab1.col0 * tab1.col1 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT + col0 * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col1 + col0 * col0 + + col2 AS col2 FROM tab0 AS cor0
----
1323
695
8094

query I rowsort
SELECT ALL col1 - tab2.col0 * + col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT ALL - col1 - + col1 * + col0 FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT cor0.col2 * - col0 + - col0 * - col2 + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col0 + - col2 + col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab1, tab1 AS cor0 WHERE ( NULL ) >= ( NULL )
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT ( NULL ) NOT IN ( - col1 + col1 )
----

query I rowsort
SELECT col2 + col1 + - col2 * col0 FROM tab2
----
-131
-1943
-2947

query I rowsort
SELECT DISTINCT col2 * tab0.col0 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + col2 * col1 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT col0 * tab0.col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT col2 * + col1 + + col0 * + col2 * col0 AS col1 FROM tab0
----
1322
21846
656984

query I rowsort
SELECT ALL - col0 * col2 AS col0 FROM tab2
----
-189
-2028
-3002

query III rowsort
SELECT ALL * FROM tab0 WHERE col2 + col2 * col2 IN ( - col1 )
----

query I rowsort
SELECT ALL cor0.col2 - col2 FROM tab1 AS cor0
----
0
0
0

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT ( NULL ) >= ( NULL )
----

query I rowsort
SELECT ALL + col1 * + col0 * col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT col2 * col2 + col1 FROM tab2
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9563
SELECT col0 DIV col0 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9563
SELECT col0 / col0 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + col1 * col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + col0 + - col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col2 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - - col0 + cor0.col0 AS col1 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT col0 * + col0 * col0 AS col2 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT cor0.col2 - col1 * - col2 * col1 FROM tab1 cor0
----
16320
36558
5757

query I rowsort
SELECT cor0.col1 + cor0.col1 * col1 * - col2 AS col0 FROM tab1 AS cor0
----
-16211
-36478
-5690

onlyif mysql # use DIV operator for integer division
query I rowsort label-9571
SELECT DISTINCT col0 DIV + col0 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-9571
SELECT DISTINCT col0 / + col0 FROM tab2
----
1

query I rowsort
SELECT ALL - tab2.col2 * col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL - - cor0.col0 + - col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + + col2 * col2 AS col1 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT ALL col2 + + col0 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - col1 * col2 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col0 * - col1 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col2 + cor0.col0 AS col1 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9579
SELECT DISTINCT - cor0.col1 + CAST( NULL AS SIGNED ) * - col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9579
SELECT DISTINCT - cor0.col1 + CAST ( NULL AS INTEGER ) * - col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col0 + 70 * + col1 AS col1 FROM tab0 AS cor0
----
5996
6281
6755

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + col2 col2 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-9582
SELECT + + col0 DIV + col1 + - ( col2 + 25 ) * col0 FROM tab2 AS cor0
----
-364
-3977
-4973

skipif mysql # not compatible
query I rowsort label-9582
SELECT + + col0 / + col1 + - ( col2 + 25 ) * col0 FROM tab2 AS cor0
----
-364
-3977
-4973

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * 25 col0 FROM tab1 AS cor0
----
250
325
650

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 944e54872ec2718f5c1c2710e1806e36

query I rowsort
SELECT ALL tab1.col0 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT - + cor0.col2 * - 26 AS col0 FROM tab1 AS cor0
----
1404
1482
2496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9587
SELECT DISTINCT CAST( col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9587
SELECT DISTINCT CAST ( col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + col1 + ( cor0.col1 ) * 78 FROM tab2 AS cor0
----
1343
2449
4661

query I rowsort
SELECT DISTINCT + 82 FROM tab0
----
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9590
SELECT ALL CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9590
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 35 * col0 + + col1 col1 FROM tab2
----
-214
-2671
-2748

query I rowsort
SELECT + 26 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT - ( + col0 ) * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL ( + col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * 77 FROM tab1 AS cor0
----
231
4928
6160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9596
SELECT DISTINCT - 35 DIV 95 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-9596
SELECT DISTINCT - 35 / 95 FROM tab0 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 12 col2 FROM tab2, tab1 AS cor0
----
12

query I rowsort
SELECT DISTINCT - 78 * tab1.col2 FROM tab1, tab1 AS cor0
----
-4212
-4446
-7488

query I rowsort
SELECT ALL - 26 FROM tab1, tab0 cor0
----
9 values hashing to 47d0574274146de273829785364ada39

query I rowsort
SELECT 91 FROM tab2, tab0 cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT ALL - 30 * + col1 AS col2 FROM tab1 AS cor0
----
-300
-390
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-9602
SELECT 83 + col1 DIV + cor0.col1 AS col2 FROM tab1 AS cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort label-9602
SELECT 83 + col1 / + cor0.col1 AS col2 FROM tab1 AS cor0
----
84
84
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9603
SELECT ALL + + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9603
SELECT ALL + + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + - col2 * + ( 43 ) AS col0 FROM tab1 cor0
----
-2268
-2394
-4032

query I rowsort
SELECT DISTINCT 28 * col0 + - 70 FROM tab1 AS cor0
----
14
1722
2170

query I rowsort
SELECT 81 + col0 - col1 FROM tab1
----
135
148
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-9607
SELECT ALL col0 DIV col0 + col2 * + col0 AS col2 FROM tab1
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-9607
SELECT ALL col0 / col0 + col2 * + col0 AS col2 FROM tab1
----
163
3649
7681

query I rowsort
SELECT ALL - col2 + - tab1.col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT ALL cor0.col2 + col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ( - 53 ) FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 2876418587c77a182d88db2907b0a51a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9611
SELECT ALL + 24 * col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9611
SELECT ALL + 24 * col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + + col1 + 14 FROM tab1 cor0
----
-14
-33
-69

query I rowsort
SELECT + + col2 - col1 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 * col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + ( - col0 ) + cor0.col2 + col0 * col1 * + 74 AS col2 FROM tab1 cor0
----
47353
5823
76976

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - cor0.col2 col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL col1 + + ( col2 ) FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9618
SELECT + + col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9618
SELECT + + col0 / - col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + cor0.col1 + - col2 * col0 AS col0 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + col0 + + 49 * + ( col1 ) * 41 FROM tab1 AS cor0
----
20154
26197
52237

query I rowsort
SELECT col1 * 43 + col2 + col2 FROM tab1 AS cor0
----
1226
544
751

onlyif mysql # use DIV operator for integer division
query I rowsort label-9622
SELECT - col1 DIV + 96 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9622
SELECT - col1 / + 96 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col0 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL col2 * + col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + + col1 * - 40 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-11560
-139240
-38440

query I rowsort
SELECT + col2 + + col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-9628
SELECT col1 DIV 99 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9628
SELECT col1 / 99 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT col1 * col1 + + 90 AS col2 FROM tab2
----
1051
3571
379

query I rowsort
SELECT DISTINCT 39 * col1 + 94 FROM tab0
----
3448
3643
3877

query I rowsort
SELECT DISTINCT + col1 * col2 + - col2 FROM tab1 AS cor0
----
1152
1350
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-9633
SELECT - col1 DIV + 80 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9633
SELECT - col1 / + 80 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + tab0.col1 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 * - col1 col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + + col1 + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col2 + col1 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + col2 + - col0 FROM tab1 cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-9639
SELECT DISTINCT col0 + - col1 DIV 90 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9639
SELECT DISTINCT col0 + - col1 / 90 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 col1 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + ( col2 ) + - col0 col0 FROM tab0 AS cor0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - 55 col0 FROM tab1 AS cor0
----
-52
25
9

query I rowsort
SELECT - col1 - + 48 FROM tab0 AS cor0
----
-134
-139
-145

query I rowsort
SELECT ALL tab1.col1 + col1 * - col0 AS col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT ALL col2 * tab1.col2 + + ( 64 * col0 ) FROM tab1
----
14336
3108
7345

query I rowsort
SELECT + - col2 * col1 - + cor0.col1 * + col0 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT + + col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9648
SELECT + cor0.col0 + - col2 DIV - col1 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-9648
SELECT + cor0.col0 + - col2 / - col1 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT col0 + 78 AS col1 FROM tab1 AS cor0
----
142
158
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 + col1 col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 4 col2 FROM tab0 cor0
----
4
4
4

query I rowsort
SELECT ALL cor1.col2 * cor0.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 11fb95e355e995b05aff375a305225c2

query I rowsort
SELECT DISTINCT col0 * + col0 + - 91 - 94 * - col1 FROM tab2 cor0
----
11539
2872
7748

query I rowsort
SELECT + + col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9655
SELECT - 23 DIV + col0 + + col2 * 2 AS col1 FROM tab1
----
101
114
192

skipif mysql # not compatible
query I rowsort label-9655
SELECT - 23 / + col0 + + col2 * 2 AS col1 FROM tab1
----
101
114
192

query I rowsort
SELECT DISTINCT 63 * 84 AS col2 FROM tab0
----
5292

query I rowsort
SELECT DISTINCT - tab0.col2 * ( + col0 ) * col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT - 66 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + col2 + col2 FROM tab0
----
164
2
66

query I rowsort
SELECT - col2 * + col1 - ( cor0.col2 ) AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT + - 83 * + col2 AS col1 FROM tab0 AS cor0
----
-2739
-6806
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col1 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 90 FROM tab0 cor0
----
-90
-90
-90

query I rowsort
SELECT col0 - col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 50 + - col0 AS col2 FROM tab0 AS cor0
----
-39
15
26

query I rowsort
SELECT - col0 * - col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - 94 AS col2 FROM tab0 AS cor0
----
-94
-94
-94

query I rowsort
SELECT - 49 * col1 - - ( col1 ) * col0 FROM tab2 AS cor0
----
-1302
1711
510

query I rowsort
SELECT DISTINCT + 80 FROM tab0 AS cor0
----
80

query I rowsort
SELECT + col1 + + col2 * 38 FROM tab2 AS cor0
----
1047
1057
1461

query I rowsort
SELECT - 54 - col1 AS col2 FROM tab1 AS cor0
----
-64
-67
-80

query I rowsort
SELECT DISTINCT - col2 * + 31 * col2 AS col0 FROM tab2
----
-20956
-22599
-44764

query I rowsort
SELECT ALL cor0.col2 FROM tab0, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ( col2 + col1 ) * + col1 * tab1.col2 FROM tab1
----
112320
136032
38190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9676
SELECT DISTINCT + ( col1 ) * col1 * + CAST( + col1 AS SIGNED ) + + col1 - - col0 * - col2 AS col0 FROM tab2
----
1928
203410
29633

skipif mysql # not compatible
query I rowsort label-9676
SELECT DISTINCT + ( col1 ) * col1 * + CAST ( + col1 AS INTEGER ) + + col1 - - col0 * - col2 AS col0 FROM tab2
----
1928
203410
29633

query I rowsort
SELECT ALL 35 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT ALL tab1.col1 * col1 * - col1 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT col2 * tab2.col2 AS col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT - col1 + + ( col0 + col1 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - col0 - + col0 AS col1 FROM tab0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9682
SELECT + ( col2 ) * col0 + + col1 DIV + col2 + col0 DIV - ( + col2 * col1 ) FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-9682
SELECT + ( col2 ) * col0 + + col1 / + col2 + col0 / - ( + col2 * col1 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - - 55 + + col0 AS col1 FROM tab2 cor0
----
133
134
62

query I rowsort
SELECT col0 + col2 + col0 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT - 53 AS col2 FROM tab0 cor0
----
-53
-53
-53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9687
SELECT ( + cor0.col1 ) * CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9687
SELECT ( + cor0.col1 ) * CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 19 * - col1 + + col1 FROM tab2 AS cor0
----
1180
340
620

query I rowsort
SELECT - - ( - cor0.col0 ) + + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col1 * - col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 24 * + cor0.col1 FROM tab2, tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT ALL + 62 FROM tab2
----
62
62
62

query I rowsort
SELECT + 10 + cor0.col1 * 55 FROM tab2 AS cor0
----
1715
3255
945

query I rowsort
SELECT - 95 * col0 + - col0 FROM tab0 AS cor0
----
-2304
-3360
-8544

onlyif mysql # use DIV operator for integer division
query I rowsort label-9696
SELECT - + col0 DIV col0 + - col1 + col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9696
SELECT - + col0 / col0 + - col1 + col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL ( + col0 ) * + 36 FROM tab0 cor0
----
1260
3204
864

query I rowsort
SELECT - col2 * + col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT col2 + - 81 * + col1 FROM tab2 AS cor0
----
-1339
-2484
-4753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + 22 * - 6 col0 FROM tab1 AS cor0
----
-129
-52
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-9701
SELECT - cor0.col2 * col0 DIV 70 FROM tab1 AS cor0
----
-109
-2
-52

skipif mysql # not compatible
query I rowsort label-9701
SELECT - cor0.col2 * col0 / 70 FROM tab1 AS cor0
----
-109
-2
-52

query I rowsort
SELECT col1 * - cor0.col2 + col0 * ( ( col0 ) ) + + col1 AS col1 FROM tab1 AS cor0
----
-1369
3536
5165

query I rowsort
SELECT + 85 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT - 87 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT ALL col0 + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - ( col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - col2 + + 98 AS col2 FROM tab0 AS cor0
----
16
65
97

query I rowsort
SELECT DISTINCT + col0 - - col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + + ( col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 82 FROM tab0 cor0
----
82
82
82

query I rowsort
SELECT ALL 69 + - col2 + col1 * col1 FROM tab1 AS cor0
----
112
142
691

query I rowsort
SELECT + 24 + cor0.col2 FROM tab1 AS cor0
----
120
78
81

query I rowsort
SELECT ALL - - col1 * - ( - col2 ) + col2 * col2 + col2 FROM tab0 AS cor0
----
14268
3960
99

query I rowsort
SELECT ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + col1 + col2 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9716
SELECT + CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9716
SELECT + CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col2 + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT col2 + col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - ( col1 ) * col2 + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT + + col1 * + col0 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + 60 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT ALL 96 * + ( - col0 ) * col2 AS col1 FROM tab0 AS cor0
----
-3360
-700608
-76032

query I rowsort
SELECT + col1 * + col0 * col1 FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT + + col2 + - col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - + 36 * - col2 + col2 * + col1 AS col2 FROM tab1 AS cor0
----
2622
3348
4704

query I rowsort
SELECT DISTINCT ( col2 ) * col2 - col1 AS col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT - col0 * + 34 + + col2 * + 81 + + 99 AS col2 FROM tab0 AS cor0
----
-1010
1956
3715

query I rowsort
SELECT ( ( + cor0.col0 ) ) * + 74 * - col0 AS col2 FROM tab1 AS cor0
----
-303104
-473600
-666

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col0 AS REAL ) / - col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT 4 - - tab2.col2 * col0 FROM tab2
----
193
2032
3006

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
3645 values hashing to 51e2051aff75c58a5edaa314f1412983

query I rowsort
SELECT ALL - ( col0 ) - - col2 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + + 11 * + col0 FROM tab0 AS cor0
----
264
385
979

query I rowsort
SELECT ALL - + cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9735
SELECT ALL 77 DIV - col2 + ( 45 ) FROM tab1 cor0
----
44
44
45

skipif mysql # not compatible
query I rowsort label-9735
SELECT ALL 77 / - col2 + ( 45 ) FROM tab1 cor0
----
44
44
45

query I rowsort
SELECT - 70 FROM tab2, tab1 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

query I rowsort
SELECT 26 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT ALL ( - col0 ) - tab1.col0 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT - 34 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

query I rowsort
SELECT DISTINCT - col1 + 59 AS col1 FROM tab0 AS cor0
----
-27
-32
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9741
SELECT DISTINCT + + col2 DIV - ( col0 ) FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-9741
SELECT DISTINCT + + col2 / - ( col0 ) FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT ALL 47 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT + col2 * + ( - col2 ) * col0 AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT + col0 + ( - 76 ) FROM tab2
----
-69
2
3

query I rowsort
SELECT + tab0.col2 * col2 + tab0.col2 * - col0 AS col1 FROM tab0
----
-34
-574
297

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9746
SELECT + col1 * CAST( NULL AS SIGNED ) - col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9746
SELECT + col1 * CAST ( NULL AS INTEGER ) - col0 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 * + ( col1 + - col1 ) * col1 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * ( - 45 ) FROM tab2 AS cor0
----
-1395
-2655
-765

query I rowsort
SELECT ALL - - col2 + - col0 * col0 AS col1 FROM tab2 cor0
----
-22
-6058
-6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + ( col0 ) col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + + cor0.col2 * - ( - col0 ) AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ( - col0 ) + 54 AS col2 FROM tab1 AS cor0
----
-10
-26
51

query I rowsort
SELECT ALL col2 - col1 * + col0 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT - col2 + + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + cor1.col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT 66 AS col1 FROM tab2, tab2 AS cor0
----
66

query I rowsort
SELECT - ( + 46 ) * + col1 FROM tab1
----
-1196
-460
-598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9758
SELECT DISTINCT CAST( NULL AS DECIMAL ) + - 28 * + tab0.col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-9758
SELECT DISTINCT CAST ( NULL AS REAL ) + - 28 * + tab0.col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query IIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
243 values hashing to 26173f1193178352de9a2e4ca7f09d53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 65 col2 FROM tab2
----
65
65
65

query I rowsort
SELECT - col1 * col2 + ( col0 ) FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT col1 * tab0.col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL ( tab2.col0 ) * col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - cor0.col0 FROM tab0, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT DISTINCT ( col1 ) * - col1 AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT + col1 + + col1 * col1 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - col2 + - col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL - col0 * + col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT col1 + col2 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL + 56 * + col0 AS col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT ALL - col0 * col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9772
SELECT - col0 + col2 + + col0 * col2 * + CAST( 70 + col0 * col0 AS SIGNED ) col2 FROM tab0
----
45291
511641
58318311

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9772
SELECT - col0 + col2 + + col0 * col2 * + CAST ( 70 + col0 * col0 AS INTEGER ) col2 FROM tab0
----
45291
511641
58318311

query I rowsort
SELECT DISTINCT col2 - 52 FROM tab0
----
-19
-51
30

query I rowsort
SELECT col2 * ( + col2 ) + col1 + 60 * - 24 AS col0 FROM tab1
----
1502
1819
7789

query I rowsort
SELECT + col0 * col2 - ( + col2 ) AS col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT col1 + col1 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT tab2.col0 * + 83 - - 50 * - col0 AS col1 FROM tab2
----
231
2574
2607

query I rowsort
SELECT ALL col0 + + col2 * col1 - - col2 AS col0 FROM tab2
----
1638
763
871

query I rowsort
SELECT ALL + - col0 + + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + - cor0.col1 * 24 AS col0 FROM tab1 AS cor0
----
-240
-312
-624

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9781
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) / - col1 AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9781
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) / - col1 AS col2 FROM tab0 cor0
----
NULL

query I rowsort
SELECT col0 * - col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - cor0.col0 * - col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + - col0 + - 13 AS col0 FROM tab1 AS cor0
----
-16
-77
-93

query I rowsort
SELECT - tab1.col1 + + ( tab1.col0 ) FROM tab1
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-9786
SELECT DISTINCT + col0 DIV + col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9786
SELECT DISTINCT + col0 / + col2 FROM tab1 AS cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9787
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9787
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9788
SELECT ALL CAST( col2 AS SIGNED ) * col2 col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9788
SELECT ALL CAST ( col2 AS INTEGER ) * col2 col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT cor0.col2 * + ( col1 ) + ( - col0 * col1 ) FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT ALL + - col1 * + cor0.col0 + + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT + col2 * 30 - col0 FROM tab2 AS cor0
----
1061
702
803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - + ( + col2 ) + - col1 + ( + 25 * + col1 ) FROM tab0 AS cor0
----
2031
2102
2327

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9794
SELECT ALL + CAST( NULL AS SIGNED ) col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9794
SELECT ALL + CAST ( NULL AS INTEGER ) col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 12 + + col2 AS col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT col0 * - 91 - - col0 AS col2 FROM tab0 AS cor0
----
-2160
-3150
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT cor0.col2 * col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 * col2 + + col2 col0 FROM tab1 AS cor0
----
5292
5586
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 92 * - col2 + col0 col0 FROM tab0 cor0
----
-3012
-57
-7455

query I rowsort
SELECT DISTINCT + tab2.col2 AS col1 FROM tab2, tab1 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - col2 * col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT - 91 + cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1339
-1495
-661

onlyif mysql # use DIV operator for integer division
query I rowsort label-9804
SELECT DISTINCT + col1 DIV - col1 AS col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9804
SELECT DISTINCT + col1 / - col1 AS col1 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT col1 + col2 + col2 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT ALL 85 * cor0.col2 AS col2 FROM tab0 AS cor0
----
2805
6970
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9807
SELECT + CAST( col0 AS SIGNED ) * + col2 * + col1 + col0 + + col1 FROM tab0 AS cor0
----
3527
664298
68222

skipif mysql # not compatible
query I rowsort label-9807
SELECT + CAST ( col0 AS INTEGER ) * + col2 * + col1 + col0 + + col1 FROM tab0 AS cor0
----
3527
664298
68222

query I rowsort
SELECT ALL - ( col0 ) AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL - - col1 + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL 42 AS col2 FROM tab2
----
42
42
42

query I rowsort
SELECT ALL col0 * + col1 * col0 AS col0 FROM tab0
----
118825
49536
720811

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT DISTINCT 14 FROM tab2, tab2 cor0
----
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-9814
SELECT + col0 DIV col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-9814
SELECT + col0 / col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT ALL - 98 * + 67 * - col1 FROM tab2 cor0
----
111622
203546
387394

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9816
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + 76 AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9816
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + 76 AS col2 FROM tab1 cor0
----
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0 cor2
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT + col2 + col1 * col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9819
SELECT DISTINCT - + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9819
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - + col0 * - col0 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - 77 + col0 * col2 - + cor0.col1 AS col1 FROM tab1 AS cor0
----
3561
59
7590

onlyif mysql # use DIV operator for integer division
query I rowsort label-9823
SELECT - col2 * col1 * 71 + col0 DIV - col1 + 12 FROM tab0 cor0
----
-201486
-529790
-6875

skipif mysql # not compatible
query I rowsort label-9823
SELECT - col2 * col1 * 71 + col0 / - col1 + 12 FROM tab0 cor0
----
-201486
-529790
-6875

query I rowsort
SELECT 47 + col1 FROM tab1 AS cor0
----
57
60
73

query I rowsort
SELECT ALL + 93 * col0 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT + 7 FROM tab2 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT col1 * - tab0.col2 + - col0 AS col1 FROM tab0
----
-132
-2862
-7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9828
SELECT ALL + col0 + col0 + + tab1.col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9828
SELECT ALL + col0 + col0 + + tab1.col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 63 + col2 * col1 FROM tab0
----
2775
34
7399

query I rowsort
SELECT - + 84 * col1 + col2 FROM tab0 cor0
----
-7191
-7562
-8147

onlyif mysql # use DIV operator for integer division
query I rowsort label-9831
SELECT - col0 DIV - col2 AS col1 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-9831
SELECT - col0 / - col2 AS col1 FROM tab0
----
0
1
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9832
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + ( tab2.col1 ) * col0 * col1 col0 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9832
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + ( tab2.col1 ) * col0 * col1 col0 FROM tab2
----
NULL

query I rowsort
SELECT + col1 + 68 AS col2 FROM tab2
----
127
85
99

query I rowsort
SELECT - - col1 * 50 + + col2 FROM tab0 cor0
----
4333
4632
4851

query I rowsort
SELECT ALL + col1 + - ( col0 ) FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9836
SELECT DISTINCT col1 - ( col2 ) DIV col1 FROM tab1 AS cor0
----
24
5
6

skipif mysql # not compatible
query I rowsort label-9836
SELECT DISTINCT col1 - ( col2 ) / col1 FROM tab1 AS cor0
----
24
5
6

query I rowsort
SELECT + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL col2 * - col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-9839
SELECT DISTINCT + + cor0.col1 DIV + cor0.col2 - - cor0.col1 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9839
SELECT DISTINCT + + cor0.col1 / + cor0.col2 - - cor0.col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL cor0.col0 * col1 * - 33 AS col2 FROM tab2 AS cor0
----
-151866
-44319
-7161

query I rowsort
SELECT DISTINCT - col0 + ( + col0 ) AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + col1 * 15 FROM tab1 AS cor0
----
150
195
390

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9843
SELECT ALL - + col1 * - CAST( 99 AS SIGNED ) + col1 FROM tab0 AS cor0
----
8600
9100
9700

skipif mysql # not compatible
query I rowsort label-9843
SELECT ALL - + col1 * - CAST ( 99 AS INTEGER ) + col1 FROM tab0 AS cor0
----
8600
9100
9700

query I rowsort
SELECT ALL + cor0.col0 + 68 AS col2 FROM tab2 AS cor0
----
146
147
75

query I rowsort
SELECT DISTINCT + + col2 * col0 * col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL + col0 * 9 * col1 + cor0.col2 * - col0 * - col1 FROM tab0 AS cor0
----
33950
737009
86688

query I rowsort
SELECT + 98 FROM tab0
----
98
98
98

query I rowsort
SELECT + col2 * - cor0.col2 + - col0 FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-9849
SELECT + - col2 DIV - ( - col2 ) AS col0 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9849
SELECT + - col2 / - ( - col2 ) AS col0 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + 84 FROM tab0, tab0 AS cor0, tab1, tab1 AS cor1
----
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9851
SELECT + CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9851
SELECT + CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9852
SELECT ALL CAST( - ( + cor0.col1 ) AS SIGNED ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

skipif mysql # not compatible
query I rowsort label-9852
SELECT ALL CAST ( - ( + cor0.col1 ) AS INTEGER ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query IIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1
----
243 values hashing to 5c33e96b85afe1ea51bb6d4e9fa6f993

query I rowsort
SELECT 10 AS col2 FROM tab2
----
10
10
10

query I rowsort
SELECT DISTINCT cor0.col1 + ( + cor0.col0 ) * col2 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9856
SELECT - col0 - CAST( - ( + col1 ) + 57 AS SIGNED ) * col1 col0 FROM tab2 AS cor0
----
-759
-813
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9856
SELECT - col0 - CAST ( - ( + col1 ) + 57 AS INTEGER ) * col1 col0 FROM tab2 AS cor0
----
-759
-813
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * cor0.col0 + - 25 * col1 col2 FROM tab1 AS cor0
----
-488
3398
7355

query I rowsort
SELECT DISTINCT + col1 * col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col0 * tab0.col2 AS col2 FROM tab0
----
-35
-7298
-792

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab0 cor0, tab2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col0 col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT col2 * col1 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT - - col2 * + 18 AS col1 FROM tab2 AS cor0
----
468
486
684

query I rowsort
SELECT col0 * - ( col0 ) - cor0.col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT - + col0 * - cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9866
SELECT - col1 - CAST( NULL AS SIGNED ) * - 92 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9866
SELECT - col1 - CAST ( NULL AS INTEGER ) * - 92 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + 24 * + 84 * col1 FROM tab1 cor0
----
20217
26304
52470

query I rowsort
SELECT - cor0.col1 * 15 FROM tab0 AS cor0
----
-1290
-1365
-1455

query I rowsort
SELECT - - cor0.col1 * 92 FROM tab2 AS cor0
----
1564
2852
5428

query I rowsort
SELECT col2 * ( col1 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + col2 - + 93 * + 94 FROM tab1 AS cor0
----
-8796
-8799
-8838

query I rowsort
SELECT DISTINCT + col2 * - col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + + col2 * - col1 + col1 * - 26 AS col2 FROM tab1 AS cor0
----
-1586
-2080
-830

query I rowsort
SELECT - - 31 FROM tab2 cor0
----
31
31
31

query I rowsort
SELECT col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - 78 + - 20 * col0 FROM tab2 cor0
----
-1638
-1658
-218

query I rowsort
SELECT ALL - 55 + + col2 + + col0 AS col0 FROM tab1 AS cor0
----
121
2
66

query I rowsort
SELECT ALL - ( + 61 ) AS col1 FROM tab2 AS cor0
----
-61
-61
-61

query I rowsort
SELECT + - 51 * - col0 AS col1 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT - + col1 + - 89 * cor0.col2 AS col0 FROM tab2 cor0
----
-2373
-2434
-3399

query I rowsort
SELECT + - col1 * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 6 FROM tab0 cor0
----
-6
-6
-6

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 28412d50061391eec23a02d0efcfb3f9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
26
27
38

query I rowsort
SELECT - - 51 + col2 AS col1 FROM tab0 AS cor0
----
133
52
84

query I rowsort
SELECT + ( 41 ) AS col2 FROM tab2
----
41
41
41

query I rowsort
SELECT ALL - 61 * cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 279894020b0205c1e491a444893c80a9

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
1
33
82

query I rowsort
SELECT - + ( col0 ) * - col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ( + col0 ) AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT - 91 + col2 FROM tab0 AS cor0
----
-58
-9
-90

query I rowsort
SELECT - cor0.col2 + col2 * col0 * col1 FROM tab0 AS cor0
----
3394
664036
68079

onlyif mysql # use DIV operator for integer division
query I rowsort label-9893
SELECT DISTINCT + col1 - col2 DIV - 41 col0 FROM tab1 AS cor0
----
11
15
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9893
SELECT DISTINCT + col1 - col2 / - 41 col0 FROM tab1 AS cor0
----
11
15
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 * col1 + + ( - col0 + ( col2 ) ) * - col0 col2 FROM tab1 AS cor0
----
14944
36351
6148

query I rowsort
SELECT DISTINCT + 84 + + col1 AS col2 FROM tab0 AS cor0
----
170
175
181

query I rowsort
SELECT DISTINCT + 30 FROM tab0 AS cor0
----
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 80 * - col2 + - 98 - col2 col0 FROM tab1 AS cor0
----
-4472
-4715
-7874

query I rowsort
SELECT ALL 89 + col2 * col1 + + col1 * col1 FROM tab1 AS cor0
----
1506
2169
759

query I rowsort
SELECT ALL + + cor0.col2 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - - 41 * col2 FROM tab1 AS cor0
----
2214
2337
3936

query I rowsort
SELECT ALL + cor0.col2 + + cor0.col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT cor0.col0 * ( col2 ) FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 + - col2 col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT col1 + - col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + 10 FROM tab0
----
10
10
10

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) AS col2 FROM tab2, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - 61 * col2 - col2 AS col1 FROM tab0 AS cor0
----
-2046
-5084
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 - col0 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 65 AS col1 FROM tab0 AS cor0
----
65
65
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9910
SELECT + CAST( NULL AS SIGNED ) * + col1 * + col0 + - col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9910
SELECT + CAST ( NULL AS INTEGER ) * + col1 * + col0 + - col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT + ( - col0 ) * col2 + CAST ( 12 AS REAL ) FROM tab0 AS cor0
----
-23
-7286
-780

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to e3f81e329d34d83e4528a9ef7b933946

query I rowsort
SELECT ( - cor0.col2 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - 69 + + 44 FROM tab0
----
-25
-25
-25

query I rowsort
SELECT + 54 * tab0.col0 FROM tab0
----
1296
1890
4806

query I rowsort
SELECT + col2 * + 33 * col1 AS col0 FROM tab0
----
246246
3201
93654

query I rowsort
SELECT DISTINCT 77 AS col2 FROM tab2, tab0, tab1 AS cor0
----
77

query I rowsort
SELECT col0 + - col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * - col2 * col2 + 82 FROM tab2
----
-17494
-19601
-54790

query I rowsort
SELECT - col2 + col2 * col1 FROM tab0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 col1 FROM tab0 WHERE ( NULL ) = ( + col1 / col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT col2 * col0 + - col2 * - col2 FROM tab0
----
14022
1881
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-9924
SELECT col1 DIV col1 + - col2 * tab2.col2 FROM tab2
----
-1443
-675
-728

skipif mysql # not compatible
query I rowsort label-9924
SELECT col1 / col1 + - col2 * tab2.col2 FROM tab2
----
-1443
-675
-728

onlyif mysql # use DIV operator for integer division
query I rowsort label-9925
SELECT DISTINCT col0 DIV - col2 AS col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-9925
SELECT DISTINCT col0 / - col2 AS col2 FROM tab1
----
-1
0

query I rowsort
SELECT ALL col2 - + tab0.col1 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT ALL col0 - col2 * - col2 FROM tab1
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-9929
SELECT tab0.col0 DIV col1 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9929
SELECT tab0.col0 / col1 + col1 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9930
SELECT + col2 DIV - col0 + + col2 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-9930
SELECT + col2 / - col0 + + col2 FROM tab2
----
24
26
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9931
SELECT DISTINCT + col1 DIV col1 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-9931
SELECT DISTINCT + col1 / col1 FROM tab2
----
1

query I rowsort
SELECT - col2 * tab0.col2 + col0 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT col2 * + col2 + col2 - col2 AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT col2 * col0 * col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col0 * + tab0.col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL col2 * - col0 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9937
SELECT DISTINCT + col0 * col1 DIV col0 - - col1 AS col0 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-9937
SELECT DISTINCT + col0 * col1 / col0 - - col1 AS col0 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL tab1.col1 - - tab1.col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL tab2.col1 * col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL tab0.col2 * col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT col2 * - col1 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT col2 * + col2 * + col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT ALL col1 * col0 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL col1 - - tab1.col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL col0 + col1 * col1 AS col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT ALL col1 * - col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + - col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT cor0.col0 AS col0 FROM tab0 AS cor0 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL cor0.col1 * col0 + - cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT cor0.col2 + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NULL NOT IN ( - col2 + col1 * cor0.col0 )
----

query I rowsort
SELECT tab2.col2 + - col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL col1 * - tab2.col2 AS col0 FROM tab2
----
-1534
-646
-837

query III rowsort
SELECT * FROM tab2 WHERE ( - col1 ) < NULL
----

query I rowsort
SELECT - col0 + - col0 * col2 AS col2 FROM tab0
----
-70
-7387
-816

query III rowsort
SELECT * FROM tab0 WHERE ( + col1 ) IN ( - col1 )
----

query I rowsort
SELECT - col2 * col2 AS col0 FROM tab0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-9958
SELECT col1 + col2 DIV col0 AS col0 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-9958
SELECT col1 + col2 / col0 AS col0 FROM tab2
----
17
34
59

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( tab1.col1 ) > NULL
----

query I rowsort
SELECT ALL + col1 FROM tab1 WHERE NOT NULL NOT BETWEEN + col2 AND col0 * + col2
----

query I rowsort
SELECT DISTINCT + col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT col0 + col0 * - col1 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NULL IN ( - col0 + col1 + - cor0.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col0 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - col0 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col1 - - col0 FROM tab0
----
110
132
180

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1, tab0 cor1
----
972 values hashing to e84152c0bf436177d3b3d80e42832d4f

query I rowsort
SELECT DISTINCT - col1 * 91 AS col2 FROM tab1
----
-1183
-2366
-910

query I rowsort
SELECT - 12 * - tab1.col2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 125f2f3fb2d94b0cc3f62e6ce4a3f314

query I rowsort
SELECT + 20 + - 5 AS col0 FROM tab1 AS cor0
----
15
15
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-9971
SELECT - col2 DIV col2 col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9971
SELECT - col2 / col2 col0 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9972
SELECT DISTINCT - + col2 * + col1 - - col0 DIV col2 AS col2 FROM tab0 AS cor0
----
-2838
-62
-7461

skipif mysql # not compatible
query I rowsort label-9972
SELECT DISTINCT - + col2 * + col1 - - col0 / col2 AS col2 FROM tab0 AS cor0
----
-2838
-62
-7461

query I rowsort
SELECT DISTINCT + 29 FROM tab0, tab2, tab0 AS cor0
----
29

query I rowsort
SELECT - - ( ( + col2 ) ) * + col2 * col0 AS col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT - ( + col2 ) * - cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT 42 * + 8 AS col1 FROM tab0 AS cor0
----
336
336
336

query I rowsort
SELECT + - 88 * + col2 FROM tab1 cor0
----
-4752
-5016
-8448

query I rowsort
SELECT - 95 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

query I rowsort
SELECT cor0.col0 AS col1 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col2 + + col0 + - ( + col2 ) FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 1 + col2 col1 FROM tab2 AS cor0
----
25
26
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 68 * + col1 col1 FROM tab0
----
5848
6188
6596

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9983
SELECT + cor0.col1 * col1 + - CAST( NULL AS SIGNED ) + + ( + col2 ) * + 99 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9983
SELECT + cor0.col1 * col1 + - CAST ( NULL AS INTEGER ) + + ( + col2 ) * + 99 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9985
SELECT CAST( NULL AS SIGNED ) / tab1.col1 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9985
SELECT CAST ( NULL AS INTEGER ) / tab1.col1 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9986
SELECT - col2 DIV col0 + 72 FROM tab2 cor0
----
69
72
72

skipif mysql # not compatible
query I rowsort label-9986
SELECT - col2 / col0 + 72 FROM tab2 cor0
----
69
72
72

query I rowsort
SELECT ALL - col1 + - col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - col0 * + col0 AS col2 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-9989
SELECT + col1 DIV 66 + - 41 FROM tab0 AS cor0
----
-40
-40
-40

skipif mysql # not compatible
query I rowsort label-9989
SELECT + col1 / 66 + - 41 FROM tab0 AS cor0
----
-40
-40
-40

query I rowsort
SELECT col1 * - col2 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col2 + col2 AS col0 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL cor0.col0 - col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT col2 * + ( - col2 ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT col1 + + ( - cor0.col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 col0 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9996
SELECT - col2 * CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9996
SELECT - col2 * CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9997
SELECT - + col0 * + CAST( NULL AS DECIMAL ) * - col0 + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9997
SELECT - + col0 * + CAST ( NULL AS REAL ) * - col0 + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9998
SELECT + cor0.col2 DIV col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9998
SELECT + cor0.col2 / col2 FROM tab0 AS cor0
----
1
1
1