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 + col0 + + col2 * col1 + - col0 * 5 AS col1 FROM tab2 cor0
----
1222
330
809

onlyif mysql # use DIV operator for integer division
query I rowsort label-1
SELECT + - col0 DIV col0 - + col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-1
SELECT + - col0 / col0 - + col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT col0 + col1 * 88 FROM tab1 AS cor0
----
1224
2291
944

query I rowsort
SELECT - col2 * cor0.col2 + col0 - + col2 FROM tab1 AS cor0
----
-2967
-3242
-9232

query I rowsort
SELECT ALL col2 + - col1 + col1 * + col2 AS col0 FROM tab1
----
1331
1432
617

query I rowsort
SELECT ALL ( col0 ) * ( + col2 ) * col2 + col0 * - col1 * col1 FROM tab0
----
-138573
-151368
-329280

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

query I rowsort
SELECT ALL tab2.col0 + - 69 FROM tab2
----
-62
10
9

query I rowsort
SELECT 82 * tab2.col2 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to bedf1656ba6e9f073c9bbf579ae1f860

query I rowsort
SELECT - cor0.col1 - - ( - 46 ) AS col0 FROM tab0 AS cor0
----
-132
-137
-143

query I rowsort
SELECT cor0.col1 - - cor0.col0 * col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-11
SELECT ALL - - col1 * - ( + col1 ) + col0 DIV + 98 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-11
SELECT ALL - - col1 * - ( + col1 ) + col0 / + 98 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - + col1 * + 56 + col1 + + col1 AS col1 FROM tab2 AS cor0
----
-1674
-3186
-918

query I rowsort
SELECT 39 * - col1 + col1 * - 57 FROM tab1 AS cor0
----
-1248
-2496
-960

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

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

query I rowsort
SELECT ALL - 95 + cor0.col0 FROM tab0 AS cor0
----
-6
-60
-71

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

query I rowsort
SELECT + ( ( tab0.col0 ) ) FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - + 73 + col2 FROM tab1 AS cor0
----
-16
-19
23

query I rowsort
SELECT DISTINCT + 14 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
14

query I rowsort
SELECT + + 61 AS col1 FROM tab1 AS cor0
----
61
61
61

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

query I rowsort
SELECT DISTINCT + - 72 * col1 FROM tab2 AS cor0
----
-1224
-2232
-4248

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-24
SELECT ALL + CAST( + col0 AS SIGNED ) + col0 * ( + 60 ) FROM tab2 cor0
----
427
4758
4819

skipif mysql # not compatible
query I rowsort label-24
SELECT ALL + CAST ( + col0 AS INTEGER ) + col0 * ( + 60 ) FROM tab2 cor0
----
427
4758
4819

query I rowsort
SELECT tab0.col2 * 87 AS col2 FROM tab0
----
2871
7134
87

query I rowsort
SELECT DISTINCT + ( tab2.col2 + - col2 ) * + tab2.col1 AS col0 FROM tab2
----
0

query I rowsort
SELECT + col0 + - 92 FROM tab1
----
-12
-28
-89

query I rowsort
SELECT ( cor0.col0 ) * + 12 FROM tab2, tab0 cor0
----
9 values hashing to 8e5ea344e010f81883d3febf1b417e51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-29
SELECT ALL CAST( col0 AS SIGNED ) * - col1 col0 FROM tab0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-29
SELECT ALL CAST ( col0 AS INTEGER ) * - col1 col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 + ( col0 * col1 ) FROM tab1 AS cor0
----
104
1053
650

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

query I rowsort
SELECT col1 + 74 * col1 FROM tab2
----
1275
2325
4425

query I rowsort
SELECT DISTINCT ( + col0 ) + + col0 AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT + - 14 * col1 FROM tab1 AS cor0
----
-140
-182
-364

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-36
SELECT - 43 DIV col1 FROM tab2 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-36
SELECT - 43 / col1 FROM tab2 cor0
----
-1
-2
0

query I rowsort
SELECT - 28 * - col0 FROM tab2 AS cor0
----
196
2184
2212

query I rowsort
SELECT - 95 AS col2 FROM tab2 cor0
----
-95
-95
-95

query I rowsort
SELECT 60 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

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

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

query I rowsort
SELECT DISTINCT + 48 AS col1 FROM tab0 AS cor0
----
48

query I rowsort
SELECT - ( col2 ) * + col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT ( cor0.col2 ) * + 55 * - col1 FROM tab2 AS cor0
----
-35530
-46035
-84370

query I rowsort
SELECT ALL + col0 - cor0.col2 * col0 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT + - col1 + col1 * 21 * col0 AS col1 FROM tab0 AS cor0
----
169988
43258
71198

query I rowsort
SELECT ALL - cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + 85 * col1 + col2 * - col0 + col1 AS col1 FROM tab2 cor0
----
-1540
2477
3046

query I rowsort
SELECT ALL 18 * col1 + col1 AS col1 FROM tab1 cor0
----
190
247
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-50
SELECT + col1 DIV + col2 + + 47 + col0 FROM tab0 AS cor0
----
137
179
73

skipif mysql # not compatible
query I rowsort label-50
SELECT + col1 / + col2 + + 47 + col0 FROM tab0 AS cor0
----
137
179
73

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

skipif mysql # not compatible
query I rowsort label-51
SELECT ALL - tab1.col2 + + 87 / col0 AS col0 FROM tab1
----
-25
-56
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-52
SELECT DISTINCT - col2 + - col0 DIV 5 AS col1 FROM tab0
----
-37
-8
-99

skipif mysql # not compatible
query I rowsort label-52
SELECT DISTINCT - col2 + - col0 / 5 AS col1 FROM tab0
----
-37
-8
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-53
SELECT ALL + col1 DIV + 12 FROM tab1 cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-53
SELECT ALL + col1 / + 12 FROM tab1 cor0
----
0
1
2

query I rowsort
SELECT col2 - + 99 FROM tab1 AS cor0
----
-3
-42
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-55
SELECT ALL col1 DIV ( + col1 ) - col2 AS col0 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-55
SELECT ALL col1 / ( + col1 ) - col2 AS col0 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT col2 * + 27 + col1 * col2 * + 97 FROM tab1 AS cor0
----
123648
137646
56829

query I rowsort
SELECT DISTINCT col0 + 14 FROM tab1 AS cor0
----
17
78
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-58
SELECT - - col2 * - ( 43 ) + col0 DIV - col1 + col0 FROM tab0 AS cor0
----
-1395
-3437
-8

skipif mysql # not compatible
query I rowsort label-58
SELECT - - col2 * - ( 43 ) + col0 / - col1 + col0 FROM tab0 AS cor0
----
-1395
-3437
-8

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col2 col1 FROM tab2 cor0
----
-52
-54
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + - 76 col0 FROM tab2 AS cor0
----
-154
-155
-83

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

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

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

query I rowsort
SELECT DISTINCT + + col1 * - ( - col1 ) AS col0 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-67
SELECT DISTINCT - col1 DIV col1 + + col1 - cor0.col2 * col2 FROM tab2 AS cor0
----
-1428
-618
-699

skipif mysql # not compatible
query I rowsort label-67
SELECT DISTINCT - col1 / col1 + + col1 - cor0.col2 * col2 FROM tab2 AS cor0
----
-1428
-618
-699

query I rowsort
SELECT DISTINCT + + cor0.col1 + ( col0 ) AS col0 FROM tab2 AS cor0
----
137
38
96

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

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

query I rowsort
SELECT ALL - col0 + col0 * 93 FROM tab2
----
644
7176
7268

query I rowsort
SELECT ALL col0 * - ( + 56 ) FROM tab1
----
-168
-3584
-4480

query I rowsort
SELECT + col1 + - 23 AS col0 FROM tab0
----
63
68
74

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

skipif mysql # not compatible
query I rowsort label-73
SELECT DISTINCT col0 * CAST ( col2 AS INTEGER ) FROM tab2
----
189
2028
3002

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

query I rowsort
SELECT DISTINCT - col0 + 34 AS col2 FROM tab1 AS cor0
----
-30
-46
31

query I rowsort
SELECT ALL 1 - - tab2.col1 FROM tab2, tab1 cor0
----
9 values hashing to 2036013494344f92349618089e7342a0

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

query I rowsort
SELECT ( - tab0.col2 ) + col1 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT col0 + 54 AS col2 FROM tab0 AS cor0
----
143
78
89

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

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

query I rowsort
SELECT DISTINCT 29 + col2 AS col1 FROM tab2 AS cor0
----
55
56
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-82
SELECT tab2.col2 DIV + 82 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-82
SELECT tab2.col2 / + 82 FROM tab2
----
0
0
0

query I rowsort
SELECT + ( col1 ) + - col0 + 40 AS col2 FROM tab0
----
102
102
42

query I rowsort
SELECT ALL col2 * + col2 + col2 * col0 FROM tab1
----
16896
3078
6897

query I rowsort
SELECT + ( col0 ) + 56 AS col0 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT DISTINCT + 61 + + col2 AS col1 FROM tab1 cor0
----
115
118
157

onlyif mysql # use DIV operator for integer division
query I rowsort label-87
SELECT DISTINCT - col0 + cor0.col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-87
SELECT DISTINCT - col0 + cor0.col0 / - col0 AS col1 FROM tab0 AS cor0
----
-25
-36
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-88
SELECT ALL + col1 DIV cor0.col0 + + col2 AS col1 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-88
SELECT ALL + col1 / cor0.col0 + + col2 AS col1 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT DISTINCT + - 64 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-5504
-5824
-6208

query I rowsort
SELECT ALL - 60 * - col1 + + col0 * col0 * - cor0.col2 FROM tab2 AS cor0
----
-154644
-236138
537

query I rowsort
SELECT + col2 * cor0.col2 + + col1 AS col0 FROM tab2 AS cor0
----
1461
735
760

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

query I rowsort
SELECT ALL - + 50 * + col1 FROM tab1 AS cor0
----
-1300
-500
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-94
SELECT DISTINCT - ( cor0.col2 ) * col0 * - col2 + + col1 DIV - 24 FROM tab2 AS cor0
----
114076
5102
52726

skipif mysql # not compatible
query I rowsort label-94
SELECT DISTINCT - ( cor0.col2 ) * col0 * - col2 + + col1 / - 24 FROM tab2 AS cor0
----
114076
5102
52726

query I rowsort
SELECT ALL + cor0.col2 + col1 * - col0 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT 31 * col1 + col0 FROM tab0 AS cor0
----
2690
2910
3042

query I rowsort
SELECT + + 34 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-25
17
3

query I rowsort
SELECT - 85 + + col0 AS col1 FROM tab1 AS cor0
----
-21
-5
-82

query I rowsort
SELECT ALL - - 74 + - col1 * - 40 AS col2 FROM tab0 AS cor0
----
3514
3714
3954

query I rowsort
SELECT DISTINCT - - 19 AS col2 FROM tab0 AS cor0
----
19

query I rowsort
SELECT ALL + 5 + - cor0.col0 + - col0 AS col2 FROM tab1 cor0
----
-1
-123
-155

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

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

query I rowsort
SELECT ALL - + cor0.col1 + + col0 * - 2 AS col1 FROM tab2 AS cor0
----
-175
-215
-45

query I rowsort
SELECT DISTINCT 6 * + col2 - - ( + 27 ) * + col2 FROM tab0 AS cor0
----
1089
2706
33

query I rowsort
SELECT - 15 + col1 AS col2 FROM tab2 AS cor0
----
16
2
44

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-107
SELECT DISTINCT + 51 DIV + col1 + - col0 * + col0 * + col1 AS col2 FROM tab0 AS cor0
----
-118825
-49536
-720811

skipif mysql # not compatible
query I rowsort label-107
SELECT DISTINCT + 51 / + col1 + - col0 * + col0 * + col1 AS col2 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT 81 AS col1 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT + 64 * - col0 AS col0 FROM tab2
----
-448
-4992
-5056

onlyif mysql # use DIV operator for integer division
query I rowsort label-110
SELECT ALL col0 DIV cor0.col0 AS col1 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-110
SELECT ALL col0 / cor0.col0 AS col1 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT + + col0 + - ( - ( + cor0.col0 ) + + col2 ) * col0 AS col0 FROM tab0 AS cor0
----
-192
1225
712

query I rowsort
SELECT cor0.col2 + - ( col2 + - cor0.col1 ) * ( 16 ) AS col0 FROM tab0 AS cor0
----
1537
226
881

query I rowsort
SELECT col1 * - 63 + + col0 AS col1 FROM tab0 AS cor0
----
-5394
-5644
-6076

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

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

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

query I rowsort
SELECT col1 * - col0 * 34 FROM tab1
----
-21760
-2652
-35360

query I rowsort
SELECT + + col2 * cor0.col2 + col1 * col0 FROM tab2 cor0
----
2787
5278
946

query I rowsort
SELECT - col0 + + col1 * cor0.col0 FROM tab2 AS cor0
----
1264
210
4524

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

query I rowsort
SELECT - ( + ( col1 ) + - col2 * col0 ) AS col2 FROM tab1
----
136
3638
7667

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

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

query I rowsort
SELECT DISTINCT + col0 * col0 + - col1 AS col2 FROM tab2 AS cor0
----
18
6025
6224

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

query I rowsort
SELECT ( cor0.col2 ) AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - + 51 * + 27 FROM tab2 AS cor0
----
-1377
-1377
-1377

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-128
SELECT + + 74 DIV 55 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-128
SELECT + + 74 / 55 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col1 * - 27 + ( + col2 ) FROM tab1
----
-213
-255
-648

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

skipif mysql # not compatible
query I rowsort label-130
SELECT + - CAST ( col0 AS INTEGER ) * + col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - 67 * 85 + col2 AS col0 FROM tab0 cor0
----
-5613
-5662
-5694

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 19 * tab2.col2 + - col0 col2 FROM tab2
----
416
506
643

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-135
SELECT DISTINCT - CAST( + col1 AS SIGNED ) AS col2 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-135
SELECT DISTINCT - CAST ( + col1 AS INTEGER ) AS col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - ( 76 ) * col1 FROM tab0 AS cor0
----
-6536
-6916
-7372

query I rowsort
SELECT DISTINCT col0 * + 24 AS col1 FROM tab0
----
2136
576
840

query I rowsort
SELECT ALL - ( 67 * + col2 ) FROM tab0
----
-2211
-5494
-67

query I rowsort
SELECT col2 * col2 + + col2 * 27 FROM tab0
----
1980
28
8938

query I rowsort
SELECT DISTINCT + 29 + + cor0.col0 FROM tab2, tab0 AS cor0
----
118
53
64

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

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 # support for MySQL specific system types and syntax
query I rowsort label-143
SELECT + CAST( col1 AS SIGNED ) * col2 FROM tab1 cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-143
SELECT + CAST ( col1 AS INTEGER ) * col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - - 52 FROM tab2 cor0
----
52
52
52

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

query I rowsort
SELECT DISTINCT - col2 + cor0.col2 * 40 FROM tab0 AS cor0
----
1287
3198
39

query I rowsort
SELECT ALL + - col0 + - col0 + - ( + ( col2 ) ) AS col2 FROM tab0 AS cor0
----
-260
-71
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-148
SELECT DISTINCT + col1 DIV + col0 - - cor0.col2 * col0 col0 FROM tab1 AS cor0
----
170
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-148
SELECT DISTINCT + col1 / + col0 - - cor0.col2 * col0 col0 FROM tab1 AS cor0
----
170
3648
7680

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col0 * + 0 col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col0 + 34 AS col2 FROM tab2
----
112
113
41

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

query I rowsort
SELECT DISTINCT - col2 * - col1 + - ( 17 ) AS col1 FROM tab0 AS cor0
----
2821
7445
80

query I rowsort
SELECT ALL - - 62 * col1 - col0 AS col1 FROM tab0 cor0
----
5308
5553
5979

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col0 * ( col0 ) + col0 AS col2 FROM tab2 cor0
----
-42
-6006
-6162

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

query I rowsort
SELECT + + col0 * - 90 + col2 + col1 FROM tab2 AS cor0
----
-572
-6935
-7055

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

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

query I rowsort
SELECT + col2 + ( + 93 + cor0.col2 ) * cor0.col1 FROM tab0 AS cor0
----
10869
16007
9119

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

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

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * + col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT col1 * - col1 * - col0 + + col2 * col2 AS col2 FROM tab2 AS cor0
----
24275
272194
7456

query I rowsort
SELECT 15 + tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 92bd1b84eff45bee265b432e74f8dc37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-165
SELECT + CAST( - cor0.col2 AS SIGNED ) FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-165
SELECT + CAST ( - cor0.col2 AS INTEGER ) FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-166
SELECT col2 DIV - ( col1 * col1 ) FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-166
SELECT col2 / - ( col1 * col1 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT col1 * tab0.col2 + + col0 AS col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT col2 + col0 * + col1 * - col1 AS col2 FROM tab2
----
-22793
-271492
-6700

query I rowsort
SELECT col2 - 35 FROM tab0
----
-2
-34
47

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( - col1 AS REAL ) * col1 FROM tab1 AS cor0
----
100
169
676

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-171
SELECT + + ( + col0 ) / col2 col0 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-172
SELECT DISTINCT - CAST( + col0 AS SIGNED ) + - cor0.col2 * col0 FROM tab2 AS cor0
----
-196
-2106
-3081

skipif mysql # not compatible
query I rowsort label-172
SELECT DISTINCT - CAST ( + col0 AS INTEGER ) + - cor0.col2 * col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT + col0 + + col1 * col1 * + col1 FROM tab0 AS cor0
----
636080
753660
912708

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col1 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - 39 + - col1 * col2 AS col0 FROM tab1 cor0
----
-1287
-1443
-609

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + ( col2 + + col2 ) col2 FROM tab2 AS cor0
----
130
155
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-178
SELECT DISTINCT 40 DIV - 4 AS col0 FROM tab1 AS cor0
----
-10

skipif mysql # not compatible
query I rowsort label-178
SELECT DISTINCT 40 / - 4 AS col0 FROM tab1 AS cor0
----
-10

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

query I rowsort
SELECT ALL - col1 + 68 FROM tab2 AS cor0
----
37
51
9

query I rowsort
SELECT DISTINCT tab1.col0 + col0 * - col0 - - col1 * col1 FROM tab1
----
-3932
-6151
670

onlyif mysql # use DIV operator for integer division
query I rowsort label-182
SELECT col1 DIV - 73 + tab0.col2 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-182
SELECT col1 / - 73 + tab0.col2 FROM tab0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-183
SELECT + col2 * col1 DIV col0 FROM tab2 AS cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-183
SELECT + col2 * col1 / col0 FROM tab2 AS cor0
----
119
19
8

query I rowsort
SELECT + 79 + + col2 FROM tab1 AS cor0
----
133
136
175

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

query I rowsort
SELECT DISTINCT + - cor0.col1 * 9 FROM tab2 AS cor0
----
-153
-279
-531

onlyif mysql # use DIV operator for integer division
query I rowsort label-187
SELECT ALL CAST( col1 AS SIGNED ) DIV + col0 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-187
SELECT ALL CAST ( col1 AS INTEGER ) / + col0 FROM tab2
----
0
0
4

query I rowsort
SELECT + col0 * 32 - col0 FROM tab1 cor0
----
1984
2480
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-189
SELECT ALL + + col0 + CAST( + col0 AS SIGNED ) DIV - col0 col1 FROM tab2 AS cor0
----
6
77
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-189
SELECT ALL + + col0 + CAST ( + col0 AS INTEGER ) / - col0 col1 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT ALL + col2 * cor0.col0 + 78 AS col2 FROM tab2 AS cor0
----
2106
267
3080

query I rowsort
SELECT DISTINCT col0 + + 87 FROM tab0
----
111
122
176

query I rowsort
SELECT ALL + col0 + 44 AS col2 FROM tab1
----
108
124
47

query I rowsort
SELECT - col0 * + col2 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - - col2 * 58 + col0 * col0 + + 44 AS col2 FROM tab2 AS cor0
----
1659
7636
8489

query I rowsort
SELECT ALL + col1 + + 32 AS col1 FROM tab1 AS cor0
----
42
45
58

query I rowsort
SELECT 47 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT - col1 + - 81 AS col1 FROM tab1 AS cor0
----
-107
-91
-94

query I rowsort
SELECT col2 * 78 + + cor0.col1 FROM tab0 AS cor0
----
175
2660
6487

onlyif mysql # use DIV operator for integer division
query I rowsort label-199
SELECT DISTINCT - col2 + - col2 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-199
SELECT DISTINCT - col2 + - col2 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-103
-56
-62

query I rowsort
SELECT - + col0 + + ( col2 + + col1 ) FROM tab1 AS cor0
----
29
3
77

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

query I rowsort
SELECT DISTINCT cor0.col2 * 56 + col0 * + col0 AS col2 FROM tab1 AS cor0
----
11776
3033
7288

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

query I rowsort
SELECT DISTINCT + 35 * + col2 + - ( + ( col1 ) ) * + ( ( + col2 ) ) * - ( col0 * - col2 ) AS col1 FROM tab0 AS cor0
----
-2246541
-3360
-54454806

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT 71 + col0 * + col1 FROM tab0 AS cor0
----
2135
3466
8170

query I rowsort
SELECT DISTINCT col1 * col0 + 63 + col2 AS col0 FROM tab2 AS cor0
----
1444
307
4691

query I rowsort
SELECT - 72 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

query I rowsort
SELECT col1 * - col2 + ( + col1 * col2 ) + 95 AS col2 FROM tab2 AS cor0
----
95
95
95

query I rowsort
SELECT + cor0.col0 * + col1 + + col0 * 78 * - col2 FROM tab0 AS cor0
----
-561145
-59712
665

query I rowsort
SELECT ALL + 2 - col2 FROM tab0 cor0
----
-31
-80
1

query I rowsort
SELECT + 71 + + cor0.col1 * + col0 AS col0 FROM tab2 AS cor0
----
1414
288
4673

query I rowsort
SELECT col2 * col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - 57 + + col1 * col0 FROM tab1
----
21
583
983

query I rowsort
SELECT DISTINCT + col1 + + tab2.col2 * + col0 FROM tab2
----
2087
220
3019

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

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

query I rowsort
SELECT ALL + cor1.col2 AS col0 FROM tab2, tab2 cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL + ( - col0 ) + + col1 * + ( col1 ) * col2 AS col2 FROM tab2
----
10903
25940
90428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-221
SELECT DISTINCT - + CAST( - col2 AS SIGNED ) AS col1 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-221
SELECT DISTINCT - + CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL 95 * col1 AS col2 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT ALL + 3 * 83 AS col1 FROM tab2 cor0
----
249
249
249

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-224
SELECT CAST( col1 * col2 AS SIGNED ) + - ( tab2.col2 ) FROM tab2
----
1508
608
810

skipif mysql # not compatible
query I rowsort label-224
SELECT CAST ( col1 * col2 AS INTEGER ) + - ( tab2.col2 ) FROM tab2
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-225
SELECT ALL 34 DIV - ( tab2.col0 ) FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-225
SELECT ALL 34 / - ( tab2.col0 ) FROM tab2
----
-4
0
0

query I rowsort
SELECT ALL 5 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

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

skipif mysql # not compatible
query I rowsort label-227
SELECT - col0 / - col1 AS col0 FROM tab1
----
0
6
6

query I rowsort
SELECT + 90 * - col0 * - col1 FROM tab0
----
185760
305550
728910

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

skipif mysql # not compatible
query I rowsort label-229
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT + col0 * + col1 + - ( + col1 ) + - col0 AS col2 FROM tab2 AS cor0
----
1247
179
4465

query I rowsort
SELECT - - col2 + - col2 * col0 + col0 AS col0 FROM tab2 AS cor0
----
-155
-1924
-2885

onlyif mysql # use DIV operator for integer division
query I rowsort label-232
SELECT - col2 * cor0.col2 + ( col2 ) DIV + col2 + 30 FROM tab1 AS cor0
----
-2885
-3218
-9185

skipif mysql # not compatible
query I rowsort label-232
SELECT - col2 * cor0.col2 + ( col2 ) / + col2 + 30 FROM tab1 AS cor0
----
-2885
-3218
-9185

query I rowsort
SELECT tab0.col1 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT + - tab0.col2 * cor0.col0 FROM tab0, tab1, tab0 AS cor0
----
9 values hashing to 5a475cfe41f7ddfc26a553f412abc75a

query I rowsort
SELECT DISTINCT 72 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
72

query I rowsort
SELECT ALL - col1 + - 90 AS col2 FROM tab1 AS cor0
----
-100
-103
-116

query I rowsort
SELECT DISTINCT + cor0.col2 * 39 AS col0 FROM tab0, tab1 AS cor0
----
2106
2223
3744

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

query I rowsort
SELECT + col2 * 78 * 24 FROM tab1 AS cor0
----
101088
106704
179712

onlyif mysql # use DIV operator for integer division
query I rowsort label-240
SELECT ALL + - col1 DIV + col0 + 86 AS col0 FROM tab1 AS cor0
----
78
86
86

skipif mysql # not compatible
query I rowsort label-240
SELECT ALL + - col1 / + col0 + 86 AS col0 FROM tab1 AS cor0
----
78
86
86

query I rowsort
SELECT + + 80 FROM tab1 cor0
----
80
80
80

query I rowsort
SELECT DISTINCT - col0 + 44 AS col2 FROM tab1 AS cor0
----
-20
-36
41

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

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

query I rowsort
SELECT - - 60 FROM tab0 AS cor0
----
60
60
60

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

query I rowsort
SELECT - 22 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

onlyif mysql # use DIV operator for integer division
query I rowsort label-247
SELECT + col1 + - cor0.col1 DIV + col1 + + col2 FROM tab1 cor0
----
108
66
79

skipif mysql # not compatible
query I rowsort label-247
SELECT + col1 + - cor0.col1 / + col1 + + col2 FROM tab1 cor0
----
108
66
79

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

query I rowsort
SELECT 74 * col0 * col0 AS col2 FROM tab2
----
3626
450216
461834

onlyif mysql # use DIV operator for integer division
query I rowsort label-250
SELECT ALL - col0 DIV + 94 col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-250
SELECT ALL - col0 / + 94 col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 86 col0 FROM tab0 AS cor0
----
172
177
183

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

query I rowsort
SELECT DISTINCT - col0 + - cor0.col2 + - cor0.col2 FROM tab0 AS cor0
----
-253
-37
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-254
SELECT DISTINCT + col0 - col2 DIV 49 AS col2 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-254
SELECT DISTINCT + col0 - col2 / 49 AS col2 FROM tab0 AS cor0
----
24
35
88

query I rowsort
SELECT DISTINCT - col1 * - ( cor0.col1 * col1 ) + col1 + 98 FROM tab1 AS cor0
----
1108
17700
2308

query I rowsort
SELECT DISTINCT ( col2 ) * + ( - 75 ) * tab1.col2 FROM tab1
----
-218700
-243675
-691200

query I rowsort
SELECT + + col2 * - ( + 4 ) + + col0 AS col2 FROM tab0 AS cor0
----
-108
-239
31

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

query I rowsort
SELECT ALL + col2 * + col0 + - col1 + col0 * + col2 * + col0 FROM tab1 AS cor0
----
237110
622
622067

query I rowsort
SELECT - - 89 * + col2 + - col1 AS col1 FROM tab0 AS cor0
----
-8
2851
7207

query I rowsort
SELECT ( + col1 ) * col1 FROM tab2 cor0
----
289
3481
961

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

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

query I rowsort
SELECT - + ( 5 ) + col1 * col2 AS col1 FROM tab2 AS cor0
----
1529
641
832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-264
SELECT CAST( + col0 AS SIGNED ) * col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-264
SELECT CAST ( + col0 AS INTEGER ) * col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-265
SELECT ALL + - cor0.col2 + col0 DIV + col1 FROM tab2 AS cor0
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-265
SELECT ALL + - cor0.col2 + col0 / + col1 FROM tab2 AS cor0
----
-25
-27
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 64 ) * cor0.col1 col2 FROM tab2 cor0
----
1088
1984
3776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-267
SELECT + + CAST( NULL AS DECIMAL ) + ( - cor0.col2 ) * ( + 42 * col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-267
SELECT + + CAST ( NULL AS REAL ) + ( - cor0.col2 ) * ( + 42 * col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

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

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

query I rowsort
SELECT col2 + col0 * + 55 FROM tab0 AS cor0
----
1353
1926
4977

query I rowsort
SELECT ALL col1 * + col2 * 98 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
278091
731194
9505

query I rowsort
SELECT DISTINCT + ( 4 ) * cor0.col0 + 84 FROM tab1, tab2 AS cor0
----
112
396
400

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

query I rowsort
SELECT DISTINCT col1 + + col1 + 86 * - 7 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
-19694
-408
-49182

query I rowsort
SELECT ALL + 99 AS col1 FROM tab1
----
99
99
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-276
SELECT ALL + CAST( - 39 + col1 AS SIGNED ) * - 27 FROM tab2
----
-540
216
594

skipif mysql # not compatible
query I rowsort label-276
SELECT ALL + CAST ( - 39 + col1 AS INTEGER ) * - 27 FROM tab2
----
-540
216
594

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

query I rowsort
SELECT ALL - - 73 * col0 AS col0 FROM tab2 AS cor0
----
511
5694
5767

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 31 * cor0.col2 - col0 col1 FROM tab1 AS cor0
----
-1677
-1831
-3056

query I rowsort
SELECT - ( + col0 ) + 56 + - col2 AS col1 FROM tab1 AS cor0
----
-1
-120
-65

query I rowsort
SELECT DISTINCT + col0 - cor0.col1 * col1 FROM tab2 AS cor0
----
-210
-3403
-954

onlyif mysql # use DIV operator for integer division
query I rowsort label-283
SELECT col0 DIV col1 - ( col2 ) * col0 DIV + 62 FROM tab2 cor0
----
-3
-31
-44

skipif mysql # not compatible
query I rowsort label-283
SELECT col0 / col1 - ( col2 ) * col0 / + 62 FROM tab2 cor0
----
-3
-31
-44

query I rowsort
SELECT ALL - 78 + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-1118
-156
-718

query I rowsort
SELECT + 55 + - col2 * col1 FROM tab1 AS cor0
----
-1193
-1349
-515

query I rowsort
SELECT 46 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT ALL + - col2 + + col0 * + 58 FROM tab1 cor0
----
120
3655
4544

query I rowsort
SELECT 53 * + col1 * col2 AS col1 FROM tab1 AS cor0
----
30210
66144
74412

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

query I rowsort
SELECT DISTINCT 34 * col0 FROM tab1 AS cor0
----
102
2176
2720

query I rowsort
SELECT - - col1 + + col1 + + col2 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT + ( + 80 ) * - cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to acfa33daa371f695a0045a73d68e09ff

onlyif mysql # use DIV operator for integer division
query I rowsort label-293
SELECT - col0 * col2 DIV col0 + + col1 * - cor0.col2 + + col1 * - col2 FROM tab0 AS cor0
----
-15006
-195
-5709

skipif mysql # not compatible
query I rowsort label-293
SELECT - col0 * col2 / col0 + + col1 * - cor0.col2 + + col1 * - col2 FROM tab0 AS cor0
----
-15006
-195
-5709

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

query I rowsort
SELECT + col2 * 16 + col0 * + col0 FROM tab1 AS cor0
----
5008
7936
873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 11 col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

onlyif mysql # use DIV operator for integer division
query I rowsort label-297
SELECT ALL + - 75 * cor0.col1 DIV + col0 AS col0 FROM tab1 AS cor0
----
-11
-12
-650

skipif mysql # not compatible
query I rowsort label-297
SELECT ALL + - 75 * cor0.col1 / + col0 AS col0 FROM tab1 AS cor0
----
-11
-12
-650

query I rowsort
SELECT ALL - col1 * + 68 AS col0 FROM tab1 cor0
----
-1768
-680
-884

query I rowsort
SELECT - 85 + + cor0.col2 FROM tab2, tab2 cor0
----
9 values hashing to 01c9f5c8590e3d6473ce5c7944c8c877

query I rowsort
SELECT ALL + 11 FROM tab1, tab2 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

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

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

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

skipif mysql # not compatible
query I rowsort label-302
SELECT ALL CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + 85 ) + col0 FROM tab1 AS cor0
----
149
165
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-304
SELECT ALL + 85 + cor0.col0 DIV 11 FROM tab0, tab2 AS cor0
----
9 values hashing to e977563139b66b4b801e3b19409cb6db

skipif mysql # not compatible
query I rowsort label-304
SELECT ALL + 85 + cor0.col0 / 11 FROM tab0, tab2 AS cor0
----
9 values hashing to e977563139b66b4b801e3b19409cb6db

query I rowsort
SELECT ALL 14 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT - col2 * col0 + + 95 FROM tab2
----
-1933
-2907
-94

query I rowsort
SELECT DISTINCT + - col2 * 73 - 86 * - col1 AS col0 FROM tab0 AS cor0
----
1840
4987
8269

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

query I rowsort
SELECT DISTINCT col0 + 60 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
1627
1638
2359

query I rowsort
SELECT DISTINCT - - col2 * ( 7 ) AS col2 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT - col0 * 74 FROM tab2 AS cor0
----
-518
-5772
-5846

query I rowsort
SELECT DISTINCT - col2 * - 53 + col1 - + col0 * col2 AS col0 FROM tab0 AS cor0
----
-2861
1043
115

query I rowsort
SELECT cor1.col1 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT ( col0 ) + - col1 * + col1 AS col2 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-316
SELECT + ( + col0 ) + + col0 * + ( + col1 ) DIV + col1 AS col0 FROM tab1 AS cor0
----
128
160
6

skipif mysql # not compatible
query I rowsort label-316
SELECT + ( + col0 ) + + col0 * + ( + col1 ) / + col1 AS col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-317
SELECT col2 DIV 38 AS col1 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-317
SELECT col2 / 38 AS col1 FROM tab2 cor0
----
0
0
1

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

skipif mysql # not compatible
query I rowsort label-318
SELECT DISTINCT - CAST ( NULL AS REAL ) + col1 FROM tab2 AS cor0
----
NULL

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

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

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

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

query I rowsort
SELECT col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + + ( cor0.col1 ) - + col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT col2 + cor0.col1 * 86 * col1 AS col0 FROM tab2 AS cor0
----
24892
299392
82673

query I rowsort
SELECT DISTINCT + col0 + - ( + col1 * tab1.col0 ) AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - 33 * - col2 + col1 * + cor0.col1 FROM tab0 AS cor0
----
10987
8485
9442

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

query I rowsort
SELECT - col1 + + ( - 63 ) FROM tab2 AS cor0
----
-122
-80
-94

query I rowsort
SELECT DISTINCT ( col2 ) * col2 FROM tab2
----
1444
676
729

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-331
SELECT - col0 + - 40 DIV col0 AS col0 FROM tab2 AS cor0
----
-12
-78
-79

skipif mysql # not compatible
query I rowsort label-331
SELECT - col0 + - 40 / col0 AS col0 FROM tab2 AS cor0
----
-12
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-332
SELECT DISTINCT + col1 * ( - col2 + col1 ) DIV 97 FROM tab1
----
-11
-4
-7

skipif mysql # not compatible
query I rowsort label-332
SELECT DISTINCT + col1 * ( - col2 + col1 ) / 97 FROM tab1
----
-11
-4
-7

query I rowsort
SELECT ALL + col2 * 79 AS col2 FROM tab2
----
2054
2133
3002

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

skipif mysql # not compatible
query I rowsort label-334
SELECT DISTINCT 52 + col2 / col1 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT - ( col2 ) + + tab0.col0 * + ( - col1 ) + col0 FROM tab0
----
-2073
-3361
-8092

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

query I rowsort
SELECT ALL col2 + + col1 + - col0 * 80 FROM tab0
----
-1801
-2702
-6947

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-338
SELECT - CAST( - 87 AS SIGNED ) * - tab1.col1 AS col1 FROM tab1
----
-1131
-2262
-870

skipif mysql # not compatible
query I rowsort label-338
SELECT - CAST ( - 87 AS INTEGER ) * - tab1.col1 AS col1 FROM tab1
----
-1131
-2262
-870

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

skipif mysql # not compatible
query I rowsort label-339
SELECT + CAST ( + 67 AS INTEGER ) FROM tab1
----
67
67
67

query I rowsort
SELECT ( ( - col0 ) ) * - col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL 61 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT ( col2 ) * + 81 * 48 AS col2 FROM tab1
----
209952
221616
373248

query I rowsort
SELECT DISTINCT 51 * + col1 FROM tab0 AS cor0
----
4386
4641
4947

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-345
SELECT - col1 DIV - col0 + ( + 83 ) AS col0 FROM tab1 AS cor0
----
83
83
91

skipif mysql # not compatible
query I rowsort label-345
SELECT - col1 / - col0 + ( + 83 ) AS col0 FROM tab1 AS cor0
----
83
83
91

query I rowsort
SELECT ALL - cor0.col0 * + col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-347
SELECT DISTINCT - + 77 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-347
SELECT DISTINCT - + 77 / col1 AS col2 FROM tab2 AS cor0
----
-1
-2
-4

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

query I rowsort
SELECT ALL 82 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + col0 + col2 + + col0 FROM tab2 AS cor0
----
182
196
41

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 79 ) + + col2 + - col0 * + col0 * - cor0.col1 col0 FROM tab1 AS cor0
----
209
40938
83217

query I rowsort
SELECT - ( 17 ) + cor0.col0 FROM tab0 cor0
----
18
7
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-354
SELECT ALL col0 - 58 DIV col0 AS col0 FROM tab0
----
22
34
89

skipif mysql # not compatible
query I rowsort label-354
SELECT ALL col0 - 58 / col0 AS col0 FROM tab0
----
22
34
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-355
SELECT ALL col0 DIV 29 FROM tab2
----
0
2
2

skipif mysql # not compatible
query I rowsort label-355
SELECT ALL col0 / 29 FROM tab2
----
0
2
2

query I rowsort
SELECT - tab1.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL 23 FROM tab0, tab2 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT 3 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT ALL ( col0 ) + tab2.col2 * 70 AS col2 FROM tab2
----
1897
1898
2739

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 31 + col1 col1 FROM tab0
----
117
122
128

query I rowsort
SELECT col1 + col0 + cor0.col0 * + col1 FROM tab2 AS cor0
----
1439
255
4739

onlyif mysql # use DIV operator for integer division
query I rowsort label-362
SELECT DISTINCT + - ( col2 ) DIV - col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-362
SELECT DISTINCT + - ( col2 ) / - col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL + 47 * tab0.col0 + col1 + - col0 * col0 * + col1 FROM tab0
----
-117083
-48322
-716537

query I rowsort
SELECT ALL + 47 + 49 FROM tab0
----
96
96
96

query I rowsort
SELECT ALL 40 + + 70 FROM tab1
----
110
110
110

query I rowsort
SELECT ALL - 13 + - col2 AS col0 FROM tab0
----
-14
-46
-95

query I rowsort
SELECT - ( + 29 ) * col0 AS col0 FROM tab2
----
-203
-2262
-2291

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

query I rowsort
SELECT DISTINCT - + col2 * 29 + col0 AS col2 FROM tab0 AS cor0
----
-2289
-933
6

query I rowsort
SELECT ALL - col2 * 69 FROM tab0 AS cor0
----
-2277
-5658
-69

query I rowsort
SELECT col0 + col2 * 10 FROM tab1
----
1040
543
634

query I rowsort
SELECT - 31 + - col0 AS col0 FROM tab0
----
-120
-55
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-373
SELECT ALL 91 DIV - 36 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

skipif mysql # not compatible
query I rowsort label-373
SELECT ALL 91 / - 36 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab0, tab1, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + cor0.col0 AS col1 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 ALL + + col1 + col2 * 28 col0 FROM tab2 cor0
----
1081
787
787

query I rowsort
SELECT DISTINCT + col0 * 18 + - col1 AS col1 FROM tab2 AS cor0
----
1345
1405
95

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-379
SELECT - col1 * col2 DIV 2 AS col1 FROM tab1 AS cor0
----
-285
-624
-702

skipif mysql # not compatible
query I rowsort label-379
SELECT - col1 * col2 / 2 AS col1 FROM tab1 AS cor0
----
-285
-624
-702

query I rowsort
SELECT + col0 * - 94 AS col1 FROM tab2 AS cor0
----
-658
-7332
-7426

query I rowsort
SELECT ALL - col2 * + ( + col2 ) * - col1 + 3 AS col2 FROM tab1 AS cor0
----
119811
32493
75819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col0 FROM tab2, tab1 AS cor0
----
67

query I rowsort
SELECT ALL + tab0.col0 * + 51 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 3aec83df1f446131fa0aa88f77fa3f6c

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

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

query I rowsort
SELECT ALL + col1 * - 70 + - col0 FROM tab1 AS cor0
----
-1823
-764
-990

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

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

query I rowsort
SELECT - 6 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 8be8910507908e6353d02a545b748252

query I rowsort
SELECT ALL + 34 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT ALL + + 9 FROM tab0 cor0
----
9
9
9

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

query I rowsort
SELECT ALL - - col0 + 36 * - col2 AS col1 FROM tab2 AS cor0
----
-1289
-858
-965

query I rowsort
SELECT DISTINCT + col1 + + 89 * col2 * + 87 AS col0 FROM tab1 AS cor0
----
418148
441361
743341

onlyif mysql # use DIV operator for integer division
query I rowsort label-394
SELECT 19 DIV + col2 - - cor0.col2 * + ( col2 ) AS col0 FROM tab0 cor0
----
1089
20
6724

skipif mysql # not compatible
query I rowsort label-394
SELECT 19 / + col2 - - cor0.col2 * + ( col2 ) AS col0 FROM tab0 cor0
----
1089
20
6724

query I rowsort
SELECT + col2 * cor0.col2 - col0 FROM tab0 AS cor0
----
-34
1065
6635

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-397
SELECT DISTINCT CAST ( NULL AS INTEGER ) - cor0.col2 * - col2 col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT 20 * - 72 + col2 AS col2 FROM tab1 AS cor0
----
-1344
-1383
-1386

query I rowsort
SELECT 72 * + col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
2520
525456
57024

onlyif mysql # use DIV operator for integer division
query I rowsort label-400
SELECT col2 + + ( - col1 ) * col1 DIV - 37 FROM tab0
----
232
255
305

skipif mysql # not compatible
query I rowsort label-400
SELECT col2 + + ( - col1 ) * col1 / - 37 FROM tab0
----
232
255
305

query I rowsort
SELECT DISTINCT col2 * + 16 * col1 FROM tab0 cor0
----
119392
1552
45408

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

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

query I rowsort
SELECT ALL - + 9 + col0 AS col2 FROM tab0 AS cor0
----
15
26
80

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

skipif mysql # not compatible
query I rowsort label-405
SELECT DISTINCT + 95 * + col0 - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col2 col1 FROM tab1 AS cor0
----
108
114
192

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

query I rowsort
SELECT DISTINCT + 64 * + col1 - col1 AS col1 FROM tab0 cor0
----
5418
5733
6111

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

query I rowsort
SELECT ALL - - col1 + cor0.col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT + cor1.col2 AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - + col2 * + col1 * - 90 FROM tab2 AS cor0
----
138060
58140
75330

query I rowsort
SELECT ALL + + 77 FROM tab2 AS cor0
----
77
77
77

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

query I rowsort
SELECT 42 * + col2 * ( col0 ) + col2 + - ( + 81 ) * + col2 FROM tab0 AS cor0
----
1390
299956
30624

query I rowsort
SELECT col1 * 61 AS col0 FROM tab1
----
1586
610
793

query I rowsort
SELECT + col1 * - col0 + + col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 - + col1 * cor0.col2 * - ( - col0 ) col0 FROM tab2 AS cor0
----
-119678
-51072
-5886

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

query I rowsort
SELECT ALL + - 78 * + col2 AS col1 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT ALL - ( col0 ) * col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

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

query I rowsort
SELECT - col2 * - 98 FROM tab1 cor0
----
5292
5586
9408

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

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

query I rowsort
SELECT 75 - col1 AS col0 FROM tab0
----
-11
-16
-22

query I rowsort
SELECT ( col2 ) + - col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT - ( - ( col2 ) ) FROM tab2
----
26
27
38

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

query I rowsort
SELECT 25 AS col0 FROM tab1
----
25
25
25

query I rowsort
SELECT - 90 * col2 AS col1 FROM tab2 AS cor0
----
-2340
-2430
-3420

query I rowsort
SELECT 30 + col0 * col1 AS col0 FROM tab0 AS cor0
----
2094
3425
8129

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-432
SELECT - CAST( NULL AS SIGNED ) + + 91 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-432
SELECT - CAST ( NULL AS INTEGER ) + + 91 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-433
SELECT + 9 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-433
SELECT + 9 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + ( - col1 ) * - 75 AS col0 FROM tab0 AS cor0
----
-6450
-6825
-7275

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 94 col0 FROM tab0 cor0
----
-94
-94
-94

query I rowsort
SELECT DISTINCT + - 18 * + col1 AS col0 FROM tab0 AS cor0
----
-1548
-1638
-1746

query I rowsort
SELECT - col0 + - 75 * + col0 FROM tab0
----
-1824
-2660
-6764

query I rowsort
SELECT ALL + 90 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

onlyif mysql # use DIV operator for integer division
query I rowsort label-439
SELECT ALL cor0.col1 DIV + 50 + - col2 + col2 * 89 * + col0 AS col1 FROM tab1 AS cor0
----
14364
324615
683424

skipif mysql # not compatible
query I rowsort label-439
SELECT ALL cor0.col1 / + 50 + - col2 + col2 * 89 * + col0 AS col1 FROM tab1 AS cor0
----
14364
324615
683424

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

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

query I rowsort
SELECT + col2 + - 13 * col0 FROM tab2 AS cor0
----
-64
-988
-989

query I rowsort
SELECT DISTINCT col1 + 77 AS col2 FROM tab1 AS cor0
----
103
87
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( col1 + + col0 ) col1 FROM tab0
----
-16020
-2640
-4620

query I rowsort
SELECT + 64 + - col2 * + col2 FROM tab1 AS cor0
----
-2852
-3185
-9152

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0 WHERE NULL > NULL
----

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - col2 * col0 col0 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-449
SELECT + CAST( 16 AS SIGNED ) AS col2 FROM tab0, tab2 cor0 CROSS JOIN tab2, tab1, tab2 AS cor1
----
243 values hashing to 80627f1b002697f113dfef55dcca461f

skipif mysql # not compatible
query I rowsort label-449
SELECT + CAST ( 16 AS INTEGER ) AS col2 FROM tab0, tab2 cor0 CROSS JOIN tab2, tab1, tab2 AS cor1
----
243 values hashing to 80627f1b002697f113dfef55dcca461f

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-450
SELECT - + col2 * col1 / + col2 + + cor0.col1 / col2 col0 FROM tab1 cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col2 ) * col2 * + col0 + col2 col1 FROM tab0
----
26169
36
598518

query I rowsort
SELECT col2 * - 70 + col2 FROM tab0 AS cor0
----
-2277
-5658
-69

query I rowsort
SELECT + 64 + + col1 * col0 FROM tab1 AS cor0
----
1104
142
704

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

query I rowsort
SELECT - + col0 + col2 + + col2 * col0 FROM tab0 AS cor0
----
1
7291
801

query I rowsort
SELECT 82 * cor0.col0 FROM tab2 AS cor0
----
574
6396
6478

query I rowsort
SELECT - col1 * + col0 + + col2 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - col1 + + col0 * 91 AS col0 FROM tab0 AS cor0
----
2098
3088
8008

query I rowsort
SELECT + col1 + + cor0.col0 * col2 + - col2 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
14851
229
3716

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 * col2 + col2 + col1 * + cor0.col0 col2 FROM tab1 AS cor0
----
208633
738416
8880

query I rowsort
SELECT + - cor0.col1 * 39 AS col1 FROM tab1 AS cor0
----
-1014
-390
-507

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

query I rowsort
SELECT + - cor1.col1 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab0 AS cor2
----
243 values hashing to dba0629212dd6bf03c2834a27d0b07fb

query I rowsort
SELECT - col1 - - col1 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-465
SELECT DISTINCT + 86 DIV + tab2.col0 FROM tab2
----
1
12

skipif mysql # not compatible
query I rowsort label-465
SELECT DISTINCT + 86 / + tab2.col0 FROM tab2
----
1
12

query I rowsort
SELECT col1 * tab1.col0 * + col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT - col0 + - 93 AS col0 FROM tab0 AS cor0
----
-117
-128
-182

query I rowsort
SELECT + + col1 * + col1 + col1 + - 86 FROM tab0 cor0
----
7396
8286
9420

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

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

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

query I rowsort
SELECT DISTINCT 31 FROM tab2, tab2 AS cor0
----
31

query I rowsort
SELECT + ( - 53 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

query I rowsort
SELECT DISTINCT col0 * - col0 * + col2 AS col0 FROM tab1
----
-233472
-486
-614400

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

query I rowsort
SELECT col1 * - 52 AS col0 FROM tab0
----
-4472
-4732
-5044

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-477
SELECT - col0 DIV - ( col1 * col0 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-477
SELECT - col0 / - ( col1 * col0 ) AS col1 FROM tab1
----
0
0
0

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

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT + col2 = ( NULL )
----

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

query I rowsort
SELECT ALL col1 * - tab2.col1 + + col1 FROM tab2
----
-272
-3422
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-482
SELECT col1 DIV col0 + + tab2.col0 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-482
SELECT col1 / col0 + + tab2.col0 FROM tab2
----
11
78
79

query I rowsort
SELECT DISTINCT col0 * + col1 + + col0 * + col0 FROM tab2
----
10686
266
7584

query I rowsort
SELECT col2 FROM tab2 WHERE NOT NULL NOT IN ( col0 )
----

query I rowsort
SELECT + col2 * tab1.col1 + - col2 * + col0 FROM tab1
----
-3078
-6432
1242

onlyif mysql # use DIV operator for integer division
query I rowsort label-486
SELECT col0 * tab2.col1 DIV + col1 AS col2 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-486
SELECT col0 * tab2.col1 / + col1 AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL col1 + + col1 + - col2 FROM tab2
----
-4
35
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-488
SELECT DISTINCT col1 DIV - col0 + tab1.col2 * - col0 + + col2 FROM tab1
----
-116
-3591
-7584

skipif mysql # not compatible
query I rowsort label-488
SELECT DISTINCT col1 / - col0 + tab1.col2 * - col0 + + col2 FROM tab1
----
-116
-3591
-7584

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

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

query I rowsort
SELECT ALL - col1 + col2 * - col2 AS col0 FROM tab2 AS cor0
----
-1461
-735
-760

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

skipif mysql # not compatible
query I rowsort label-491
SELECT ALL - + col0 / + col2 AS col1 FROM tab1 cor0
----
-1
0
0

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

query I rowsort
SELECT DISTINCT + col0 * - col0 * col2 + + col0 AS col2 FROM tab1 AS cor0
----
-233408
-483
-614320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col0 * - col2 col2 FROM tab0 cor0
----
-35
-7298
-792

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

query I rowsort
SELECT ALL + col2 * - col1 + col0 * col1 AS col0 FROM tab0
----
-774
3298
637

onlyif mysql # use DIV operator for integer division
query I rowsort label-497
SELECT ALL col2 DIV - col1 AS col0 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-497
SELECT ALL col2 / - col1 AS col0 FROM tab1
----
-2
-5
-7

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

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

query I rowsort
SELECT DISTINCT - col1 + + col1 AS col0 FROM tab2
----
0

query I rowsort
SELECT DISTINCT - col0 * - 50 + + cor0.col2 FROM tab0 cor0
----
1233
1751
4532

query I rowsort
SELECT cor0.col0 + - 31 FROM tab2 AS cor0
----
-24
47
48

query I rowsort
SELECT + 81 * col0 AS col2 FROM tab1
----
243
5184
6480

query I rowsort
SELECT DISTINCT + col0 * col1 + 59 * col2 + + col1 * - col2 AS col0 FROM tab0 AS cor0
----
1173
3357
5475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-504
SELECT ( 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-504
SELECT ( col2 ) + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 * - 14 AS col1 FROM tab0 AS cor0
----
1148
14
462

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

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

query I rowsort
SELECT ALL col0 * col1 + + cor0.col1 * + col0 FROM tab1 AS cor0
----
1280
156
2080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * - 64 col0 FROM tab2 AS cor0
----
448
4992
5056

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col1 + + 99 * col2 FROM tab0 AS cor0
----
2
429
656

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-512
SELECT ALL - - col0 + + 29 DIV col0 AS col1 FROM tab1 AS cor0
----
12
64
80

skipif mysql # not compatible
query I rowsort label-512
SELECT ALL - - col0 + + 29 / col0 AS col1 FROM tab1 AS cor0
----
12
64
80

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

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

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL IN ( col1 * col2 )
----

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

query I rowsort
SELECT ALL + tab2.col1 FROM tab2 WHERE NOT NULL >= ( col1 * - col2 )
----

query I rowsort
SELECT DISTINCT col0 * + col0 * col2 FROM tab1
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col0 col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT col0 * col0 * + col0 AS col1 FROM tab1
----
262144
27
512000

query I rowsort
SELECT ALL col0 FROM tab0 WHERE NOT ( col1 * + col1 + + col1 ) = ( col2 )
----
24
35
89

query I rowsort
SELECT + tab0.col2 * + col0 + - col2 + - col1 AS col2 FROM tab0
----
-63
673
7125

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

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

query III rowsort
SELECT * FROM tab2 WHERE - col1 + col0 > - col0 * col2 * col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT - tab1.col2 + - tab1.col1 * - tab1.col1 FROM tab1
----
43
622
73

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

query I rowsort
SELECT ALL col2 * + tab2.col0 + + col1 * col0 AS col1 FROM tab2
----
406
4345
6630

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

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

query I rowsort
SELECT ALL + col1 + - tab1.col1 * col1 AS col0 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT col1 + col1 + - ( + col1 + - col1 ) AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + cor0.col1 * - col0 FROM tab1 cor0
----
-104
-1053
-650

query I rowsort
SELECT - 73 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT ALL + 68 - col2 FROM tab2 AS cor0
----
30
41
42

query I rowsort
SELECT DISTINCT + col2 * - col1 + + 9 AS col0 FROM tab1 AS cor0
----
-1239
-1395
-561

onlyif mysql # use DIV operator for integer division
query I rowsort label-537
SELECT ALL - + cor0.col1 + col2 DIV - col0 FROM tab0 AS cor0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-537
SELECT ALL - + cor0.col1 + col2 / - col0 FROM tab0 AS cor0
----
-87
-91
-97

query I rowsort
SELECT DISTINCT + col0 * tab0.col1 + + col0 * + col0 - col0 AS col1 FROM tab0
----
15931
2616
4585

query I rowsort
SELECT - tab2.col0 + - col2 + + col2 * col0 FROM tab2
----
155
1924
2885

query I rowsort
SELECT tab2.col2 * col2 + - tab2.col2 * + col0 FROM tab2
----
-1352
-1558
540

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 * 16 col2 FROM tab1 AS cor0
----
1088
1360
51

query I rowsort
SELECT + cor0.col2 + - col1 * 78 AS col1 FROM tab2 AS cor0
----
-1288
-2391
-4576

query I rowsort
SELECT DISTINCT + + 5 + col1 * - 6 * - col0 FROM tab1 AS cor0
----
3845
473
6245

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 71 * - ( + col2 + - col2 ) col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT cor0.col0 + col1 * 96 FROM tab0 AS cor0
----
8280
8825
9347

onlyif mysql # use DIV operator for integer division
query I rowsort label-548
SELECT - col1 * 25 DIV + 85 + - col2 * + col1 * col2 AS col2 FROM tab2 AS cor0
----
-22608
-24553
-39901

skipif mysql # not compatible
query I rowsort label-548
SELECT - col1 * 25 / + 85 + - col2 * + col1 * col2 AS col2 FROM tab2 AS cor0
----
-22608
-24553
-39901

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * + 3 col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT DISTINCT - col0 * - 57 AS col2 FROM tab0 AS cor0
----
1368
1995
5073

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

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

query I rowsort
SELECT col1 * + 64 AS col0 FROM tab0 AS cor0
----
5504
5824
6208

query I rowsort
SELECT + cor0.col2 + + col1 * + 54 AS col2 FROM tab2 AS cor0
----
1701
3212
956

onlyif mysql # use DIV operator for integer division
query I rowsort label-554
SELECT ALL - col1 DIV - col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-554
SELECT ALL - col1 / - col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - 31 col0 FROM tab0 AS cor0
----
-2666
-2821
-3007

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-557
SELECT DISTINCT + 54 + col1 + + 68 * ( - col0 ) DIV - col0 AS col2 FROM tab0
----
208
213
219

skipif mysql # not compatible
query I rowsort label-557
SELECT DISTINCT + 54 + col1 + + 68 * ( - col0 ) / - col0 AS col2 FROM tab0
----
208
213
219

onlyif mysql # use DIV operator for integer division
query I rowsort label-558
SELECT DISTINCT col2 * col0 DIV col2 + col1 FROM tab1
----
29
74
93

skipif mysql # not compatible
query I rowsort label-558
SELECT DISTINCT col2 * col0 / col2 + col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL + col0 * col2 + - col2 + - 9 AS col2 FROM tab1
----
3582
7575
99

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-561
SELECT + CAST( cor0.col0 AS SIGNED ) + col0 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-561
SELECT + CAST ( cor0.col0 AS INTEGER ) + col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-562
SELECT + + col1 * - CAST( + col2 AS SIGNED ) + - col1 * + col1 AS col1 FROM tab2 AS cor0
----
-1798
-5015
-935

skipif mysql # not compatible
query I rowsort label-562
SELECT + + col1 * - CAST ( + col2 AS INTEGER ) + - col1 * + col1 AS col1 FROM tab2 AS cor0
----
-1798
-5015
-935

query I rowsort
SELECT ALL 49 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col0 + - col2 + col1 * - col2 col1 FROM tab2
----
-1081
-2027
-6162

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

query I rowsort
SELECT - 58 + - col1 AS col2 FROM tab2 AS cor0
----
-117
-75
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-567
SELECT ALL - ( col0 ) DIV col0 + col0 FROM tab2 cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-567
SELECT ALL - ( col0 ) / col0 + col0 FROM tab2 cor0
----
6
77
78

query I rowsort
SELECT - col0 * col1 + - col0 FROM tab2 AS cor0
----
-1422
-224
-4680

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

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

query I rowsort
SELECT 66 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT 94 * col2 + col0 AS col0 FROM tab2 AS cor0
----
2522
2545
3651

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

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

query I rowsort
SELECT - col0 * + col0 * col0 + col0 * col2 * col2 FROM tab1
----
-54208
225280
8721

query I rowsort
SELECT ALL col1 * col0 + - col1 FROM tab2
----
1326
186
4543

query I rowsort
SELECT - col2 + col2 * cor0.col2 * - col2 FROM tab1 cor0
----
-157518
-185250
-884832

query I rowsort
SELECT - col1 * - col0 - col1 AS col0 FROM tab1 AS cor0
----
1027
52
630

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

query I rowsort
SELECT ( - col2 * col2 ) AS col1 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT col1 * + 10 * + col1 FROM tab2
----
2890
34810
9610

query I rowsort
SELECT ALL 98 * - col1 AS col0 FROM tab1
----
-1274
-2548
-980

query I rowsort
SELECT - 13 + + ( + col2 ) * col2 FROM tab0 AS cor0
----
-12
1076
6711

query I rowsort
SELECT + 32 + col0 * col0 AS col0 FROM tab2 AS cor0
----
6116
6273
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 * col2 * - col0 - + col0 col0 FROM tab1 AS cor0
----
-233536
-489
-614480

query I rowsort
SELECT DISTINCT 96 FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-586
SELECT ALL col0 DIV - 5 col0 FROM tab0
----
-17
-4
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-586
SELECT ALL col0 / - 5 col0 FROM tab0
----
-17
-4
-7

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

query I rowsort
SELECT ALL - - 60 * col1 + col2 FROM tab2 cor0
----
1058
1887
3566

query I rowsort
SELECT DISTINCT - 36 * + col1 + col1 * - col2 AS col1 FROM tab1 cor0
----
-1716
-2340
-930

query I rowsort
SELECT ALL + 62 AS col0 FROM tab0 AS cor0
----
62
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-591
SELECT - + 89 + - cor0.col2 DIV cor0.col0 FROM tab0 AS cor0
----
-89
-89
-90

skipif mysql # not compatible
query I rowsort label-591
SELECT - + 89 + - cor0.col2 / cor0.col0 FROM tab0 AS cor0
----
-89
-89
-90

query I rowsort
SELECT DISTINCT + col0 + col2 * 95 AS col0 FROM tab2 cor0
----
2548
2572
3689

query I rowsort
SELECT 76 * col1 + + col1 FROM tab2 AS cor0
----
1309
2387
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 26 * col2 col0 FROM tab1 AS cor0
----
1404
1482
2496

query I rowsort
SELECT ALL ( - col0 ) + - col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 + 14 AS col2 FROM tab0 AS cor0
----
-72
-77
-83

query I rowsort
SELECT col0 + - ( - col1 * + col0 ) FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL col1 * ( + col1 ) + - col2 * ( + col1 ) FROM tab2
----
-357
124
1947

onlyif mysql # use DIV operator for integer division
query I rowsort label-599
SELECT ALL - col1 * col1 + + col2 DIV col0 col0 FROM tab1
----
-100
-168
-658

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-599
SELECT ALL - col1 * col1 + + col2 / col0 col0 FROM tab1
----
-100
-168
-658

query I rowsort
SELECT ALL + col1 + + ( col2 + col1 ) * - 11 FROM tab2
----
-588
-607
-876

query I rowsort
SELECT ALL cor0.col2 + - ( 21 ) AS col2 FROM tab0 AS cor0
----
-20
12
61

query I rowsort
SELECT DISTINCT - cor0.col0 - + col0 * - col0 AS col1 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT + cor0.col0 * - col1 * + col0 + - col1 AS col1 FROM tab2 AS cor0
----
-106114
-1550
-359015

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

query I rowsort
SELECT DISTINCT cor0.col0 + 43 AS col1 FROM tab2 cor0
----
121
122
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + 72 * + col0 + col0 col0 FROM tab1 AS cor0
----
222
4736
5920

query I rowsort
SELECT DISTINCT + + col2 * ( 4 * - col0 ) - col2 AS col1 FROM tab2 AS cor0
----
-12046
-783
-8138

query I rowsort
SELECT ALL + col2 * ( + col0 ) + + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + 48 + col0 * cor0.col0 - 99 * + 27 AS col2 FROM tab1 cor0
----
-2616
1471
3775

query I rowsort
SELECT DISTINCT col2 * 5 + - col2 * 2 AS col0 FROM tab1 AS cor0
----
162
171
288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + 86 ) col1 FROM tab0 AS cor0
----
86
86
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-612
SELECT DISTINCT + CAST( 89 AS SIGNED ) * + col0 * 84 AS col2 FROM tab2 AS cor0
----
52332
583128
590604

skipif mysql # not compatible
query I rowsort label-612
SELECT DISTINCT + CAST ( 89 AS INTEGER ) * + col0 * 84 AS col2 FROM tab2 AS cor0
----
52332
583128
590604

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 26 * col2 col2 FROM tab2 AS cor0
----
676
702
988

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

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

query I rowsort
SELECT DISTINCT 61 * col0 + + col0 FROM tab1 cor0
----
186
3968
4960

query I rowsort
SELECT DISTINCT 35 * 3 + col1 + - 37 * - col0 AS col0 FROM tab0 AS cor0
----
1079
1497
3489

query I rowsort
SELECT - tab2.col1 - - ( + col2 + col0 ) FROM tab2
----
100
3
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-618
SELECT - col2 * CAST( + col1 AS SIGNED ) AS col2 FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-618
SELECT - col2 * CAST ( + col1 AS INTEGER ) AS col2 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 * 34 col1 FROM tab1, tab1 AS cor0
----
1632

query I rowsort
SELECT - + 34 * - col2 + + col2 FROM tab1 AS cor0
----
1890
1995
3360

query I rowsort
SELECT ALL + - 65 AS col0 FROM tab0 cor0
----
-65
-65
-65

query I rowsort
SELECT 47 * col1 + + col2 AS col2 FROM tab2 AS cor0
----
1484
2799
837

query I rowsort
SELECT DISTINCT + - 8 * cor0.col1 AS col0 FROM tab1 cor0
----
-104
-208
-80

query I rowsort
SELECT + 24 + + 77 * col0 * col0 AS col1 FROM tab1 AS cor0
----
315416
492824
717

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

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

query I rowsort
SELECT col2 + tab0.col2 * + col1 AS col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL - 45 + 36 * col2 AS col1 FROM tab2
----
1323
891
927

query I rowsort
SELECT - col1 * 8 AS col2 FROM tab1
----
-104
-208
-80

query I rowsort
SELECT col2 * 97 * - col2 AS col1 FROM tab0
----
-105633
-652228
-97

query I rowsort
SELECT + 1 * ( col1 + - col0 ) * col2 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT + col2 + col0 + 65 * col2 * - ( + col1 + - col2 ) AS col0 FROM tab2 AS cor0
----
-55666
-6986
51987

query I rowsort
SELECT col2 * cor0.col2 - - col0 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-634
SELECT - - col1 DIV + col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-634
SELECT - - col1 / + col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT col0 + 99 * - col2 AS col1 FROM tab2 AS cor0
----
-2496
-2666
-3683

query I rowsort
SELECT ALL + col0 + + ( - col0 ) * + col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - col0 + col1 * 13 AS col2 FROM tab0 AS cor0
----
1094
1094
1226

query I rowsort
SELECT ALL 4 + 3 AS col0 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT ALL + ( tab0.col0 + 21 ) * col0 FROM tab0
----
1080
1960
9790

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-641
SELECT ( - col2 ) + - CAST( NULL AS DECIMAL ) / col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-641
SELECT ( - col2 ) + - CAST ( NULL AS REAL ) / col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + tab1.col0 * col1 FROM tab1
----
1136
132
697

query I rowsort
SELECT col2 * - 81 * col0 - - col0 AS col0 FROM tab0 AS cor0
----
-2800
-591049
-64128

query I rowsort
SELECT + col0 * + ( 34 ) FROM tab0 cor0
----
1190
3026
816

query I rowsort
SELECT - col0 - - 52 FROM tab0 AS cor0
----
-37
17
28

query I rowsort
SELECT ALL - col1 * 48 * col0 FROM tab1 AS cor0
----
-30720
-3744
-49920

onlyif mysql # use DIV operator for integer division
query I rowsort label-647
SELECT col1 DIV - 18 - - 80 * cor0.col1 FROM tab2 AS cor0
----
1360
2479
4717

skipif mysql # not compatible
query I rowsort label-647
SELECT col1 / - 18 - - 80 * cor0.col1 FROM tab2 AS cor0
----
1360
2479
4717

query I rowsort
SELECT + col1 * - 22 + col1 * col0 FROM tab0 AS cor0
----
1261
172
6097

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

query I rowsort
SELECT + 38 * + col0 + col1 AS col0 FROM tab1 AS cor0
----
140
2442
3053

query I rowsort
SELECT DISTINCT + 96 * col1 FROM tab1 AS cor0
----
1248
2496
960

query I rowsort
SELECT ALL ( + cor0.col2 ) * - 31 + col1 FROM tab2 AS cor0
----
-1161
-747
-806

query I rowsort
SELECT col1 * col0 * + 37 FROM tab0 cor0
----
125615
299663
76368

query I rowsort
SELECT - col0 + cor0.col0 * col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT + cor0.col2 + + 79 AS col0 FROM tab0 AS cor0
----
112
161
80

query I rowsort
SELECT - tab1.col2 * - col0 + - tab1.col2 * col1 FROM tab1
----
-1242
3078
6432

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

query I rowsort
SELECT + col1 * 20 + - col1 * col2 FROM tab2 AS cor0
----
-217
-306
-354

query I rowsort
SELECT ALL + + col2 * 89 AS col1 FROM tab2 AS cor0
----
2314
2403
3382

query I rowsort
SELECT DISTINCT + + col0 * 47 FROM tab1 cor0
----
141
3008
3760

query I rowsort
SELECT 1 * + col1 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 col2 FROM tab0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-663
SELECT CAST( 77 AS SIGNED ) * - col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

skipif mysql # not compatible
query I rowsort label-663
SELECT CAST ( 77 AS INTEGER ) * - col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 34 * col2 + + tab1.col2 col2 FROM tab1
----
-1782
-1881
-3168

query I rowsort
SELECT + col0 - col0 * - col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT + col0 * - col1 * - cor0.col1 - - col1 AS col0 FROM tab2 AS cor0
----
22848
271577
6758

query I rowsort
SELECT DISTINCT - col1 * col1 + col0 AS col2 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT + col1 * cor0.col1 * 23 AS col1 FROM tab1 AS cor0
----
15548
2300
3887

query I rowsort
SELECT ALL - ( col2 ) + - 46 * col1 FROM tab0 cor0
----
-3989
-4268
-4463

query I rowsort
SELECT ALL - col1 - col0 * - ( col1 * col0 ) AS col1 FROM tab0 AS cor0
----
118728
49450
720720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 29 + col2 * 52 col2 FROM tab1 AS cor0
----
2837
2993
5021

query I rowsort
SELECT DISTINCT 14 + - cor0.col0 FROM tab1 AS cor0
----
-50
-66
11

query I rowsort
SELECT ( col1 ) * - cor0.col0 * ( col2 ) FROM tab0 AS cor0
----
-3395
-664118
-68112

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-676
SELECT col1 / + col1 col1 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-677
SELECT + tab1.col1 - CAST( NULL AS SIGNED ) FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-677
SELECT + tab1.col1 - CAST ( NULL AS INTEGER ) FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - 10 * col2 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT DISTINCT + + 96 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
96

query I rowsort
SELECT ALL + col1 * - 13 FROM tab1 AS cor0
----
-130
-169
-338

query I rowsort
SELECT - + col1 * + col1 + cor0.col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT ALL col2 - - col0 * - col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT tab2.col1 * + col1 AS col2 FROM tab2
----
289
3481
961

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + + 78 col0 FROM tab2 AS cor0
----
-1
0
71

query I rowsort
SELECT 85 + + col2 * + col0 FROM tab1 AS cor0
----
247
3733
7765

query I rowsort
SELECT ( 25 ) FROM tab0
----
25
25
25

query I rowsort
SELECT ALL ( - col1 ) * col1 FROM tab1
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-689
SELECT DISTINCT 28 * tab2.col2 DIV col1 col2 FROM tab2
----
12
24
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-689
SELECT DISTINCT 28 * tab2.col2 / col1 col2 FROM tab2
----
12
24
62

query I rowsort
SELECT ALL 3 FROM tab0, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT - cor0.col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + ( 5 ) * col1 * + col1 AS col1 FROM tab1 AS cor0
----
3380
500
845

onlyif mysql # use DIV operator for integer division
query I rowsort label-693
SELECT ALL - + col2 DIV 59 + col1 FROM tab0 AS cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-693
SELECT ALL - + col2 / 59 + col1 FROM tab0 AS cor0
----
86
90
97

query I rowsort
SELECT DISTINCT + cor0.col2 * - 72 + 46 * col2 FROM tab2 AS cor0
----
-676
-702
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 + ( 99 ) col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3f8c14f15ad691fefd21e3d536593297

query I rowsort
SELECT DISTINCT tab0.col0 * + col0 + col1 FROM tab0
----
1322
662
8012

query I rowsort
SELECT + col2 + 84 AS col0 FROM tab0
----
117
166
85

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

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

query I rowsort
SELECT DISTINCT - + col0 + - 51 AS col2 FROM tab1 AS cor0
----
-115
-131
-54

query I rowsort
SELECT ALL + cor0.col1 * 95 FROM tab0 AS cor0
----
8170
8645
9215

query I rowsort
SELECT ALL - - col1 + + ( - col0 ) * cor0.col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT + col1 * - col2 + - col2 * - col2 * 72 AS col2 FROM tab0 AS cor0
----
-25
476666
75570

query I rowsort
SELECT DISTINCT - col0 - - tab1.col1 FROM tab1
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-704
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * - 65 - + col1 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-704
SELECT DISTINCT - CAST ( NULL AS REAL ) * - 65 - + col1 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT 35 * col0 FROM tab1
----
105
2240
2800

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 67 col2 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 09fa7af42010457bb3c6ffd0dfea3bc8

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

query I rowsort
SELECT - cor0.col0 * - col1 + 44 AS col2 FROM tab0 cor0
----
2108
3439
8143

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

query I rowsort
SELECT DISTINCT + 79 AS col0 FROM tab2 AS cor0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - - cor0.col2 * + 16 * 78 col1 FROM tab2 AS cor0
----
32526
33703
47503

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

query I rowsort
SELECT + ( col1 ) * col2 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT 28 * + col2 AS col2 FROM tab1
----
1512
1596
2688

query I rowsort
SELECT - + 32 + col2 * col1 - - col2 FROM tab0 AS cor0
----
2839
66
7512

query I rowsort
SELECT DISTINCT + col2 * col2 + cor0.col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL 49 AS col0 FROM tab2 cor0
----
49
49
49

query I rowsort
SELECT + 83 * - col1 + + ( - cor0.col0 ) FROM tab1 AS cor0
----
-1159
-2161
-894

onlyif mysql # use DIV operator for integer division
query I rowsort label-721
SELECT - ( - cor0.col0 ) - cor0.col1 DIV col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-721
SELECT - ( - cor0.col0 ) - cor0.col1 / col0 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT DISTINCT ( 34 ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
34

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

query I rowsort
SELECT ALL cor0.col1 + + cor0.col0 * + 25 AS col0 FROM tab0 AS cor0
----
2316
686
972

query I rowsort
SELECT + 72 + + cor0.col0 * + ( cor0.col2 * col0 ) AS col1 FROM tab1 AS cor0
----
233544
558
614472

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-727
SELECT DISTINCT + col0 + + col2 * + CAST( 42 AS SIGNED ) AS col0 FROM tab2
----
1141
1170
1675

skipif mysql # not compatible
query I rowsort label-727
SELECT DISTINCT + col0 + + col2 * + CAST ( 42 AS INTEGER ) AS col0 FROM tab2
----
1141
1170
1675

query I rowsort
SELECT DISTINCT - ( col1 ) + - 14 * - col1 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT + 13 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
102
37
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-730
SELECT ALL - col1 + col2 * col1 DIV + col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-730
SELECT ALL - col1 + col2 * col1 / + col2 AS col2 FROM tab1 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT - - col0 * col2 + ( col2 ) AS col2 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + + col1 * 11 * + col2 col0 FROM tab2 AS cor0
----
16796
7027
9200

query I rowsort
SELECT DISTINCT - col1 + col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - col2 - - ( 30 ) AS col0 FROM tab1 AS cor0
----
-24
-27
-66

query I rowsort
SELECT ALL + col2 + + ( - col1 + + col2 ) AS col0 FROM tab1 AS cor0
----
104
179
82

query I rowsort
SELECT ALL + col0 * col1 + + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL - 72 + col1 * + ( col0 ) FROM tab0
----
1992
3323
8027

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col0 + ( col0 ) * col1 col1 FROM tab1
----
1280
156
2080

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

query I rowsort
SELECT DISTINCT + + col2 + col2 + col2 AS col0 FROM tab2 AS cor0
----
114
78
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-743
SELECT ALL + col0 - - col2 DIV col2 AS col1 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-743
SELECT ALL + col0 - - col2 / col2 AS col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT DISTINCT 98 AS col0 FROM tab0 cor0
----
98

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

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

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

query I rowsort
SELECT ALL - + 90 + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-89
6634
999

query I rowsort
SELECT DISTINCT + col2 * + col0 + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL 8 * 81 FROM tab1 cor0
----
648
648
648

query I rowsort
SELECT DISTINCT + col0 * - col1 + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-752
SELECT - col0 * 86 DIV - col0 FROM tab0 AS cor0
----
86
86
86

skipif mysql # not compatible
query I rowsort label-752
SELECT - col0 * 86 / - col0 FROM tab0 AS cor0
----
86
86
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 * + cor0.col2 col1 FROM tab0 AS cor0
----
2409
5986
73

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-754
SELECT DISTINCT - + 41 / + col0 col1 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT ( + cor0.col0 ) * - col2 + col0 * col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + col1 + + col0 * col0 * 35 FROM tab0 AS cor0
----
20246
277326
42972

query I rowsort
SELECT + - 52 AS col1 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT + col0 * - col2 * + col0 + - 27 AS col2 FROM tab2
----
-1350
-158211
-237185

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

query I rowsort
SELECT + + col0 + col1 * col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - cor0.col0 * + 18 AS col2 FROM tab0 AS cor0
----
-1602
-432
-630

query I rowsort
SELECT ALL col1 + - 5 * - tab0.col2 AS col2 FROM tab0
----
102
251
501

query I rowsort
SELECT ALL + 29 FROM tab1, tab2 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

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

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
10
13
26

query I rowsort
SELECT ALL - col2 * 15 * col0 FROM tab1 AS cor0
----
-115200
-2430
-54720

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

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

query I rowsort
SELECT 76 * + 77 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to e9a43556c7b984f967bb744582670cdf

query I rowsort
SELECT + + ( - col2 ) * + cor0.col2 + - 13 * col2 - + col2 FROM tab2 AS cor0
----
-1040
-1107
-1976

query I rowsort
SELECT ALL + 30 * + ( + col1 ) * col1 FROM tab0 AS cor0
----
221880
248430
282270

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

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

query I rowsort
SELECT 37 * - col1 + - col0 + 43 FROM tab2 AS cor0
----
-1111
-2218
-665

query I rowsort
SELECT 99 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2, tab2 AS cor3
----
13122 values hashing to 2d110b23c1122e3f5196f4356e847210

query I rowsort
SELECT ( + col1 ) + - col2 + col0 AS col2 FROM tab2 AS cor0
----
11
111
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-776
SELECT cor0.col2 + - ( col2 ) * + col1 DIV + col1 - col1 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-776
SELECT cor0.col2 + - ( col2 ) * + col1 / + col1 - col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT - ( cor0.col2 ) + col1 + col1 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT - - col2 + + 92 * col0 AS col1 FROM tab0 AS cor0
----
2241
3221
8270

query I rowsort
SELECT DISTINCT + - 24 + 55 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
31

query I rowsort
SELECT - + 41 + col1 FROM tab1 AS cor0
----
-15
-28
-31

query I rowsort
SELECT ALL - 91 + - col0 FROM tab2 cor0
----
-169
-170
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 99 * col0 col2 FROM tab2 AS cor0
----
693
7722
7821

query I rowsort
SELECT col0 * + col2 + col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - + 45 * - col1 + + 12 AS col0 FROM tab1 cor0
----
1182
462
597

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * col2 * col1 FROM tab1 AS cor0
----
36470
4186
99827

query I rowsort
SELECT ALL + 48 * - cor0.col0 - col2 FROM tab1 AS cor0
----
-198
-3129
-3936

onlyif mysql # use DIV operator for integer division
query I rowsort label-787
SELECT DISTINCT - + 52 * col1 DIV 3 AS col2 FROM tab2 cor0
----
-1022
-294
-537

skipif mysql # not compatible
query I rowsort label-787
SELECT DISTINCT - + 52 * col1 / 3 AS col2 FROM tab2 cor0
----
-1022
-294
-537

query I rowsort
SELECT DISTINCT ( col2 ) * + cor0.col0 + + 16 AS col0 FROM tab2 AS cor0
----
2044
205
3018

query I rowsort
SELECT ALL - - col2 * + col0 + - cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
-448
1280
153

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 + + col1 * col2 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT + col0 + col0 * - 62 * col2 FROM tab1 AS cor0
----
-10041
-226112
-476080

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

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

query I rowsort
SELECT + col2 + ( 65 ) AS col2 FROM tab1
----
119
122
161

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

query I rowsort
SELECT ALL + - col2 + 30 FROM tab1 AS cor0
----
-24
-27
-66

query I rowsort
SELECT col2 * ( - 36 ) * col0 AS col0 FROM tab0 cor0
----
-1260
-262728
-28512

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

skipif mysql # not compatible
query I rowsort label-797
SELECT 6 * - col1 + + CAST ( NULL AS INTEGER ) * - 63 AS col2 FROM tab1
----
NULL
NULL
NULL

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

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

query I rowsort
SELECT DISTINCT 45 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
45

query I rowsort
SELECT - 28 * + col2 FROM tab2 AS cor0
----
-1064
-728
-756

onlyif mysql # use DIV operator for integer division
query I rowsort label-801
SELECT 97 DIV + col1 + col1 AS col0 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-801
SELECT 97 / + col1 + col1 AS col0 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT 97 * col1 AS col1 FROM tab1
----
1261
2522
970

query I rowsort
SELECT DISTINCT 13 * col2 AS col1 FROM tab2
----
338
351
494

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-804
SELECT CAST( NULL AS SIGNED ) FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-804
SELECT CAST ( NULL AS INTEGER ) FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + col2 * col2 * + col1 AS col0 FROM tab1 AS cor0
----
119808
32490
75816

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

query I rowsort
SELECT ALL - col2 * col2 * col1 + - col1 FROM tab2 AS cor0
----
-22630
-24565
-39943

query I rowsort
SELECT - col1 * + col0 + col2 + col0 FROM tab0 AS cor0
----
-2007
-3359
-7928

query I rowsort
SELECT DISTINCT col1 * col2 - col1 * - col0 AS col0 FROM tab1 AS cor0
----
1210
1482
2288

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

query I rowsort
SELECT + col1 * + col0 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - + cor0.col0 - - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col2 * + col0 col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT DISTINCT col2 * + col0 + col1 * col0 AS col2 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT DISTINCT col1 + + col1 * col2 * + tab2.col1 FROM tab2
----
10999
25978
90565

onlyif mysql # use DIV operator for integer division
query I rowsort label-817
SELECT col0 DIV tab1.col2 + col1 AS col0 FROM tab1
----
11
13
26

skipif mysql # not compatible
query I rowsort label-817
SELECT col0 / tab1.col2 + col1 AS col0 FROM tab1
----
11
13
26

query I rowsort
SELECT col0 * tab0.col0 + - col0 AS col0 FROM tab0
----
1190
552
7832

query I rowsort
SELECT DISTINCT + col2 * col2 + col0 * + col2 AS col2 FROM tab1
----
16896
3078
6897

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

query I rowsort
SELECT + 66 + col1 FROM tab1
----
76
79
92

query I rowsort
SELECT - col2 + col0 * col0 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT col1 * - col0 + col1 * - col1 FROM tab1
----
-1209
-740
-754

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

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

query I rowsort
SELECT ALL + col1 - - col0 * - tab1.col1 * col1 AS col2 FROM tab1
----
-13507
-2002
-6390

query I rowsort
SELECT col1 AS col1 FROM tab1 WHERE NULL NOT IN ( + col0 )
----

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

query I rowsort
SELECT DISTINCT col1 * col0 + col0 AS col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - col1 FROM tab0 WHERE col1 * + col0 IN ( col0 )
----

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

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

query I rowsort
SELECT - - col0 + - col1 * + ( col2 ) * + col0 FROM tab2 AS cor0
----
-119574
-50955
-5852

query I rowsort
SELECT + cor0.col2 * cor0.col2 * + col2 FROM tab2 AS cor0
----
17576
19683
54872

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

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

query I rowsort
SELECT col2 * + col0 - col2 FROM tab2
----
162
2002
2964

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-839
SELECT ALL col1 * col1 * col2 + - tab2.col2 DIV col1 FROM tab2
----
10980
25947
90506

skipif mysql # not compatible
query I rowsort label-839
SELECT ALL col1 * col1 * col2 + - tab2.col2 / col1 FROM tab2
----
10980
25947
90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-840
SELECT DISTINCT col1 DIV + col1 + + cor0.col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-840
SELECT DISTINCT col1 / + col1 + + cor0.col2 FROM tab2 AS cor0
----
27
28
39

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

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

query I rowsort
SELECT ALL - col1 * + col1 + col2 AS col0 FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT + col2 - + tab1.col1 * col0 FROM tab1
----
-24
-583
-944

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

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

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL = ( + col2 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE + col1 IN ( col1 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-849
SELECT col2 + - col0 DIV - col1 AS col0 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-849
SELECT col2 + - col0 / - col1 AS col0 FROM tab2
----
27
27
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-850
SELECT DISTINCT col2 * col0 + - col2 DIV col2 FROM tab0
----
34
7297
791

skipif mysql # not compatible
query I rowsort label-850
SELECT DISTINCT col2 * col0 + - col2 / col2 FROM tab0
----
34
7297
791

query I rowsort
SELECT tab0.col0 * - col0 FROM tab0 WHERE NOT NULL = NULL
----

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

query I rowsort
SELECT col1 * - col1 + tab0.col1 * + col2 * col2 + - col0 FROM tab0
----
-9347
603514
86234

query I rowsort
SELECT DISTINCT - col2 * - col2 + col1 FROM tab2
----
1461
735
760

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col0 + - col1 * + col0 + col2 IN ( - col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col1 FROM tab0 WHERE NOT NULL BETWEEN ( NULL ) AND col0
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col1 + - tab2.col1 IN ( col1 + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * col1 + - col1 + col2 col2 FROM tab1
----
147
252
704

query I rowsort
SELECT ALL + ( + col1 ) * tab1.col2 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL + 54 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT ALL - col0 * 84 - cor0.col2 FROM tab2 AS cor0
----
-615
-6578
-6674

onlyif mysql # use DIV operator for integer division
query I rowsort label-862
SELECT 6 DIV col1 + + ( col1 ) * + col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-862
SELECT 6 / col1 + + ( col1 ) * + col2 FROM tab2
----
1534
646
837

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

query I rowsort
SELECT ALL + col0 + col0 + col1 AS col2 FROM tab1
----
138
173
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 68 col1 FROM tab0
----
2244
5576
68

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

query I rowsort
SELECT tab1.col0 * - 94 FROM tab1
----
-282
-6016
-7520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT col1 * 57 FROM tab2
----
1767
3363
969

query I rowsort
SELECT + ( col1 ) * col1 FROM tab1
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-871
SELECT - CAST( col2 AS SIGNED ) col1 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-871
SELECT - CAST ( col2 AS INTEGER ) col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT ALL - - cor0.col0 + - col1 + col0 * ( + cor0.col2 ) FROM tab1 AS cor0
----
139
3702
7747

query I rowsort
SELECT - 39 * + col0 FROM tab2 AS cor0
----
-273
-3042
-3081

query I rowsort
SELECT - + 86 * - col2 AS col0 FROM tab1 AS cor0
----
4644
4902
8256

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-875
SELECT - - CAST ( - col0 AS INTEGER ) * + col2 + col1 col2 FROM tab0 cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-876
SELECT CAST( + 72 AS SIGNED ) * - col1 + col0 * - cor0.col2 FROM tab1 AS cor0
----
-2034
-4368
-8616

skipif mysql # not compatible
query I rowsort label-876
SELECT CAST ( + 72 AS INTEGER ) * - col1 + col0 * - cor0.col2 FROM tab1 AS cor0
----
-2034
-4368
-8616

query I rowsort
SELECT + + ( - col0 ) + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL tab1.col2 * - tab1.col0 + + col2 * + col1 FROM tab1
----
-3078
-6432
1242

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 50 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

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

query I rowsort
SELECT + col2 * 47 AS col1 FROM tab0
----
1551
3854
47

query I rowsort
SELECT + 14 AS col2 FROM tab0
----
14
14
14

query I rowsort
SELECT + - 41 * - col2 + + col1 * + col2 FROM tab2 AS cor0
----
1944
2204
2600

onlyif mysql # use DIV operator for integer division
query I rowsort label-884
SELECT + + col1 + 97 DIV - col0 FROM tab0 AS cor0
----
82
90
95

skipif mysql # not compatible
query I rowsort label-884
SELECT + + col1 + 97 / - col0 FROM tab0 AS cor0
----
82
90
95

query I rowsort
SELECT ALL col0 + + col2 + col0 FROM tab0
----
260
71
81

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-887
SELECT col1 + - col1 DIV col2 col1 FROM tab0 cor0
----
0
84
90

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

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

query I rowsort
SELECT - cor0.col0 + col1 + cor0.col0 FROM tab1 AS cor0
----
10
13
26

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

query I rowsort
SELECT DISTINCT + - col1 * cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - col1 * - col0 + col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-894
SELECT + - ( + col1 ) DIV cor0.col0 AS col2 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-894
SELECT + - ( + col1 ) / cor0.col0 AS col2 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT - + ( - col0 ) + - col2 * col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL + col0 - - 52 FROM tab0
----
141
76
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-897
SELECT + col1 DIV + col1 - col0 AS col1 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-897
SELECT + col1 / + col1 - col0 AS col1 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT - col0 + col2 * - col2 AS col1 FROM tab0
----
-1113
-36
-6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * cor0.col0 + 46 * col2 * col1 col1 FROM tab2 AS cor0
----
35957
38551
76648

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

query I rowsort
SELECT - col0 - + 7 AS col2 FROM tab2 AS cor0
----
-14
-85
-86

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

query I rowsort
SELECT DISTINCT 84 - + 34 FROM tab2 AS cor0
----
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-904
SELECT DISTINCT - cor0.col2 DIV 1 + col1 * col1 FROM tab0 cor0
----
7363
8199
9408

skipif mysql # not compatible
query I rowsort label-904
SELECT DISTINCT - cor0.col2 / 1 + col1 * col1 FROM tab0 cor0
----
7363
8199
9408

query I rowsort
SELECT + 15 * - col0 + - col1 FROM tab2 cor0
----
-1202
-1229
-136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col2 FROM tab0, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT - col0 * + col1 + + col2 AS col0 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT 70 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
70

query I rowsort
SELECT - col2 + - 1 * + 23 AS col2 FROM tab2
----
-49
-50
-61

query I rowsort
SELECT ALL cor0.col1 * 9 FROM tab2 AS cor0
----
153
279
531

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-912
SELECT ALL col2 * + CAST( col0 AS SIGNED ) - col1 AS col2 FROM tab1 AS cor0
----
136
3638
7667

skipif mysql # not compatible
query I rowsort label-912
SELECT ALL col2 * + CAST ( col0 AS INTEGER ) - col1 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL + + col0 + col2 + col2 FROM tab2 AS cor0
----
130
155
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-914
SELECT ALL + - col0 - CAST( cor0.col1 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
-1422
-224
-4680

skipif mysql # not compatible
query I rowsort label-914
SELECT ALL + - col0 - CAST ( cor0.col1 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT + + cor0.col0 * col1 + + cor0.col2 * + col0 AS col1 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT DISTINCT - + col2 * + ( + col2 ) + + cor0.col0 + 78 AS col0 FROM tab0 AS cor0
----
-6557
-987
112

query I rowsort
SELECT DISTINCT - col2 * + 47 + - col1 FROM tab0 AS cor0
----
-144
-1637
-3945

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

skipif mysql # not compatible
query I rowsort label-918
SELECT - - CAST ( col1 AS INTEGER ) - + cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - 99 * cor0.col0 AS col0 FROM tab2 AS cor0
----
693
7722
7821

query I rowsort
SELECT DISTINCT + ( + col1 ) + col1 + - col2 AS col0 FROM tab2 cor0
----
-4
35
92

query I rowsort
SELECT ALL - - cor0.col0 * col1 + - col2 AS col0 FROM tab2 AS cor0
----
1305
190
4576

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

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

query I rowsort
SELECT ALL - 30 + col2 AS col0 FROM tab0 AS cor0
----
-29
3
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-924
SELECT ALL + col0 DIV + col1 + - col1 AS col1 FROM tab2 AS cor0
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-924
SELECT ALL + col0 / + col1 + - col1 AS col1 FROM tab2 AS cor0
----
-13
-31
-58

query I rowsort
SELECT - ( cor0.col2 ) - col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT + - cor0.col0 * - col0 + col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + 10 + col2 AS col1 FROM tab0 AS cor0
----
11
43
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - + col1 col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - + 84 * - col0 FROM tab2 AS cor0
----
588
6552
6636

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

query I rowsort
SELECT cor1.col1 * - cor0.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 633f70c5ab9666b0cc9ce993d5e4f469

query I rowsort
SELECT ALL - 59 * col0 AS col1 FROM tab0 AS cor0
----
-1416
-2065
-5251

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

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

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

query I rowsort
SELECT ALL - - col1 * col1 * - col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT - cor0.col1 * 37 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a071cba3adf7afa21d98e376e0c27356

query I rowsort
SELECT - 91 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6ec4feac5c635ab8e5da71006896acab

query I rowsort
SELECT ( tab2.col2 ) + - col1 * + 64 FROM tab2
----
-1050
-1957
-3750

query I rowsort
SELECT + tab1.col2 + col2 * - col1 AS col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL + 56 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT + 82 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-942
SELECT ( col0 * CAST( NULL AS DECIMAL ) ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-942
SELECT ( col0 * CAST ( NULL AS REAL ) ) FROM tab0
----
NULL
NULL
NULL

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

skipif mysql # not compatible
query I rowsort label-943
SELECT ALL + col0 * + col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + cor0.col0 AS col0 FROM tab0, tab1, tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-945
SELECT DISTINCT col1 DIV + 74 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-945
SELECT DISTINCT col1 / + 74 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-946
SELECT ALL tab0.col1 DIV col0 AS col1 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-946
SELECT ALL tab0.col1 / col0 AS col1 FROM tab0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 23 - cor1.col0 col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
-55
-56
16

query I rowsort
SELECT + col2 * + 17 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT ALL col1 * + 10 FROM tab2
----
170
310
590

query I rowsort
SELECT + 55 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT - col1 * 87 + col2 FROM tab0 AS cor0
----
-7449
-7835
-8438

query I rowsort
SELECT DISTINCT + 50 AS col1 FROM tab0 AS cor0
----
50

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

query I rowsort
SELECT ALL col0 + + col0 * + col0 FROM tab0
----
1260
600
8010

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

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

query I rowsort
SELECT DISTINCT + ( + 12 ) + - col0 FROM tab1
----
-52
-68
9

query I rowsort
SELECT DISTINCT + + col0 * col0 + + col2 AS col1 FROM tab2 AS cor0
----
6110
6279
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 56 * col1 col1 FROM tab0 AS cor0
----
-4816
-5096
-5432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - col1 + ( col2 ) col2 FROM tab1 AS cor0
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-960
SELECT + col2 DIV col1 + + ( col0 ) DIV - cor0.col2 FROM tab1 AS cor0
----
2
4
7

skipif mysql # not compatible
query I rowsort label-960
SELECT + col2 / col1 + + ( col0 ) / - cor0.col2 FROM tab1 AS cor0
----
2
4
7

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

query I rowsort
SELECT - 22 * col2 * ( col1 * - col1 ) FROM tab1 AS cor0
----
125400
356928
803088

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

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

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

query I rowsort
SELECT ALL + col1 * - col0 * - col0 FROM tab0 AS cor0
----
118825
49536
720811

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 + 32 * + col1 + - col0 FROM tab1 AS cor0
----
256
336
829

query I rowsort
SELECT cor0.col2 * col2 + - 85 FROM tab0 cor0
----
-84
1004
6639

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

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

skipif mysql # not compatible
query I rowsort label-970
SELECT CAST ( + 58 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
58
58
58

query I rowsort
SELECT ALL + 69 * col1 AS col2 FROM tab0
----
5934
6279
6693

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

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

query I rowsort
SELECT DISTINCT 69 * cor0.col0 AS col0 FROM tab0, tab1 AS cor0
----
207
4416
5520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - col0 * - col1 col2 FROM tab0 AS cor0
----
2150
3492
8190

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

query I rowsort
SELECT ALL ( cor0.col1 ) * + ( ( - col2 ) ) * - ( col1 ) FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT + + 63 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT ALL + ( 75 ) FROM tab2
----
75
75
75

query I rowsort
SELECT + + col1 * 81 * - col1 AS col1 FROM tab0 cor0
----
-599076
-670761
-762129

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

query I rowsort
SELECT + cor0.col0 + 7 + - col1 * - col1 FROM tab1 AS cor0
----
171
256
686

onlyif mysql # use DIV operator for integer division
query I rowsort label-983
SELECT - + col2 DIV col2 + - 29 FROM tab1 AS cor0
----
-30
-30
-30

skipif mysql # not compatible
query I rowsort label-983
SELECT - + col2 / col2 + - 29 FROM tab1 AS cor0
----
-30
-30
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + + 24 * + 90 + + col0 col0 FROM tab1 AS cor0
----
2109
2144
2167

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

query I rowsort
SELECT - col2 + - cor0.col2 + col1 AS col0 FROM tab1 AS cor0
----
-104
-179
-82

query I rowsort
SELECT DISTINCT - tab0.col0 FROM tab0, tab1, tab1 cor0
----
-24
-35
-89

query I rowsort
SELECT - - col2 + cor0.col1 * + col1 AS col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL + tab1.col0 + - col2 * + 63 FROM tab1
----
-3399
-3527
-5968

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

skipif mysql # not compatible
query I rowsort label-990
SELECT 64 / + col2 FROM tab1
----
0
1
1

query I rowsort
SELECT ALL 69 FROM tab0, tab0 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT - col1 + + 31 AS col1 FROM tab1
----
18
21
5

query I rowsort
SELECT - col1 * 54 + 47 + + col0 AS col0 FROM tab1 AS cor0
----
-1354
-429
-575

query I rowsort
SELECT col0 - + ( - 68 ) * col2 FROM tab2 cor0
----
1843
1846
2663

query I rowsort
SELECT col0 * cor0.col1 + + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT 6 * - col2 * - col1 FROM tab2 AS cor0
----
3876
5022
9204

query I rowsort
SELECT DISTINCT - 58 + - col2 FROM tab1 cor0
----
-112
-115
-154

query I rowsort
SELECT ALL - - ( 81 ) + - col2 AS col0 FROM tab0 AS cor0
----
-1
48
80

query I rowsort
SELECT DISTINCT - + 82 + cor0.col2 * col1 + + ( - col2 ) * col1 * col1 FROM tab1 cor0
----
-15058
-35182
-5212

query I rowsort
SELECT ALL col1 * - 93 FROM tab1 AS cor0
----
-1209
-2418
-930

query I rowsort
SELECT + col1 + col1 * - tab1.col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT - col2 - 37 AS col1 FROM tab1
----
-133
-91
-94

query I rowsort
SELECT ALL + 64 FROM tab2, tab1 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT DISTINCT + col1 + 34 * + tab1.col2 + 2 FROM tab1
----
1864
1950
3279

query I rowsort
SELECT - 67 + col0 AS col1 FROM tab1
----
-3
-64
13

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * 97 col2 FROM tab2 AS cor0
----
1649
3007
5723

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

query I rowsort
SELECT - col1 * col1 + - col2 + - 85 FROM tab1 AS cor0
----
-242
-350
-815

query I rowsort
SELECT ALL + + 70 + col1 AS col2 FROM tab0 AS cor0
----
156
161
167

query I rowsort
SELECT ALL ( - 50 ) * col1 FROM tab2 AS cor0
----
-1550
-2950
-850

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( + col2 AS REAL ) * col1 + - col1 FROM tab2 AS cor0
----
-1593
-663
-868

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

query I rowsort
SELECT DISTINCT + 26 + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
115
50
61

query I rowsort
SELECT + col0 * cor0.col0 + - cor0.col1 AS col1 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT + col1 + + 23 FROM tab0 AS cor0
----
109
114
120

query I rowsort
SELECT ALL - col1 - + col2 * ( col1 ) FROM tab0
----
-194
-2924
-7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * 31 + col0 col0 FROM tab0 cor0
----
1120
2848
768

query I rowsort
SELECT ALL + 97 AS col1 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

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

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

query I rowsort
SELECT cor0.col1 * - 30 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 4f1fa1f5bd8b920fd5b85d06436a680e

query I rowsort
SELECT ALL + col0 * - 59 AS col1 FROM tab2 AS cor0
----
-413
-4602
-4661

query I rowsort
SELECT ALL - + col2 + ( 99 ) AS col2 FROM tab2 AS cor0
----
61
72
73

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + 53 ) col1 FROM tab2
----
53
53
53

query I rowsort
SELECT ALL ( - ( col2 ) ) * - tab2.col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT - col1 * cor0.col1 * col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT - ( 59 ) * col0 FROM tab2
----
-413
-4602
-4661

query I rowsort
SELECT 43 AS col1 FROM tab2
----
43
43
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 col2 FROM tab2
----
89
89
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1033
SELECT DISTINCT CAST( NULL AS DECIMAL ) / + col1 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-1033
SELECT DISTINCT CAST ( NULL AS REAL ) / + col1 AS col2 FROM tab2
----
NULL

query I rowsort
SELECT + 15 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT DISTINCT ( col1 ) * col1 AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col1 * col1 + - col2 AS col2 FROM tab2 AS cor0
----
251
3455
934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * + col2 * 50 col2 FROM tab1 cor0
----
145774
162440
460787

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

query I rowsort
SELECT DISTINCT - 42 * col0 AS col0 FROM tab0
----
-1008
-1470
-3738

query I rowsort
SELECT - 66 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT - 61 * + cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
11529
123708
183122

query I rowsort
SELECT ALL - col1 * col1 + - 34 AS col0 FROM tab1 AS cor0
----
-134
-203
-710

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 + ( col1 ) FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT col1 + + col1 * + 94 AS col0 FROM tab2 AS cor0
----
1615
2945
5605

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

query I rowsort
SELECT - col2 + cor0.col1 * - ( col1 ) AS col2 FROM tab1 AS cor0
----
-157
-265
-730

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1048
SELECT ALL col1 DIV + col0 + + 79 FROM tab2 AS cor0
----
79
79
83

skipif mysql # not compatible
query I rowsort label-1048
SELECT ALL col1 / + col0 + + 79 FROM tab2 AS cor0
----
79
79
83

query I rowsort
SELECT 75 * col2 FROM tab2 AS cor0
----
1950
2025
2850

query I rowsort
SELECT DISTINCT col2 + + col1 * 54 AS col1 FROM tab0 AS cor0
----
4677
4996
5239

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + 31 + 98 col2 FROM tab0
----
-2661
-646
-987

query I rowsort
SELECT tab1.col1 * - 22 * + col1 + - col2 FROM tab1
----
-14926
-2257
-3814

query I rowsort
SELECT ALL + tab1.col1 * + col1 + - col2 FROM tab1
----
43
622
73

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

query I rowsort
SELECT - - col1 + - 97 FROM tab1 AS cor0
----
-71
-84
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 88 col0 FROM tab1 AS cor0
----
101
114
98

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1058
SELECT col0 DIV col1 + 8 AS col1 FROM tab1 cor0
----
14
14
8

skipif mysql # not compatible
query I rowsort label-1058
SELECT col0 / col1 + 8 AS col1 FROM tab1 cor0
----
14
14
8

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

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

query I rowsort
SELECT DISTINCT - col0 + col2 * + 95 FROM tab0 cor0
----
3111
60
7701

query I rowsort
SELECT - + col0 * + 59 - col0 AS col2 FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT - col1 + + 89 FROM tab2 cor0
----
30
58
72

query I rowsort
SELECT - col2 * 34 + + 13 - - col2 AS col1 FROM tab0 AS cor0
----
-1076
-20
-2693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col1 + - 55 col0 FROM tab1 AS cor0
----
114
45
621

query I rowsort
SELECT + ( col0 ) + + col1 * ( cor0.col2 ) AS col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL - ( - col1 ) + col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + - cor0.col1 * 48 + - col2 FROM tab2 AS cor0
----
-1515
-2858
-854

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

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

query I rowsort
SELECT DISTINCT - 34 + + col1 FROM tab1 AS cor0
----
-21
-24
-8

query I rowsort
SELECT ALL + - cor0.col2 * - col2 + + col0 * + col0 FROM tab1 AS cor0
----
15616
2925
7345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 53 * + col1 + col0 col2 FROM tab2 AS cor0
----
-1636
-3049
-822

query I rowsort
SELECT cor0.col0 * + 40 + col2 AS col2 FROM tab1 AS cor0
----
174
2617
3296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1074
SELECT - col0 / CAST( NULL AS SIGNED ) + 21 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1074
SELECT - col0 / CAST ( NULL AS INTEGER ) + 21 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab1.col1 * col2 + col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT + 87 * col0 FROM tab1 cor0
----
261
5568
6960

query I rowsort
SELECT DISTINCT + cor0.col2 * 88 FROM tab2 AS cor0
----
2288
2376
3344

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

query I rowsort
SELECT - 59 + col1 * col1 FROM tab2 AS cor0
----
230
3422
902

onlyif mysql # use DIV operator for integer division
query I rowsort label-1080
SELECT ALL col0 DIV 13 FROM tab0 AS cor0
----
1
2
6

skipif mysql # not compatible
query I rowsort label-1080
SELECT ALL col0 / 13 FROM tab0 AS cor0
----
1
2
6

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1082
SELECT - CAST( - col1 AS SIGNED ) - col0 * - col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif mysql # not compatible
query I rowsort label-1082
SELECT - CAST ( - col1 AS INTEGER ) - col0 * - col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - 69 * col0 + + col1 AS col0 FROM tab2 cor0
----
-452
-5323
-5434

query I rowsort
SELECT ALL 96 * 9 * col1 + cor0.col1 * cor0.col1 + col2 * ( + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
84538
93314
94367

query I rowsort
SELECT DISTINCT - col2 * col2 * col0 AS col1 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT + + col2 + - 21 FROM tab2 AS cor0
----
17
5
6

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

query I rowsort
SELECT ( + 89 ) AS col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 90 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

query I rowsort
SELECT ALL + col1 + 0 * + col1 + col1 FROM tab2
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( ( cor0.col0 ) ) * col0 * col2 + + col2 col2 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT ALL tab0.col0 * 45 + + col2 * col0 AS col1 FROM tab0
----
11303
1610
1872

query I rowsort
SELECT + col1 + - ( col2 ) * + col2 + - col2 * + col1 AS col0 FROM tab1
----
-10451
-3809
-4294

query I rowsort
SELECT ALL cor0.col0 * - col1 + col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL + + col0 * + ( - 98 * col1 ) FROM tab2 AS cor0
----
-131614
-21266
-450996

onlyif mysql # use DIV operator for integer division
query I rowsort label-1096
SELECT - tab1.col2 DIV + 97 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1096
SELECT - tab1.col2 / + 97 AS col1 FROM tab1
----
0
0
0

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

query I rowsort
SELECT col0 + col1 - col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT - 55 + - tab1.col1 FROM tab1
----
-65
-68
-81

query I rowsort
SELECT col2 + + col2 * - 80 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT ALL + col1 + - 83 + col1 FROM tab0
----
111
89
99

query I rowsort
SELECT + 35 + cor1.col0 * - 97 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 2cf98e7f9a6680402333bd51ab65d606

query I rowsort
SELECT DISTINCT + col1 * col1 * + 32 FROM tab1 AS cor0
----
21632
3200
5408

query I rowsort
SELECT + + cor0.col0 * + 66 + + col0 FROM tab0 AS cor0
----
1608
2345
5963

query I rowsort
SELECT col1 * - col2 + 6 FROM tab2 cor0
----
-1528
-640
-831

query I rowsort
SELECT col1 + - 22 AS col0 FROM tab1 AS cor0
----
-12
-9
4

query I rowsort
SELECT - 60 FROM tab1, tab1 cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 17ea60db8bdc9b534fe91b7fd55df3f9

query I rowsort
SELECT 22 AS col0 FROM tab1 AS cor0
----
22
22
22

query I rowsort
SELECT + - 16 * col2 - col2 FROM tab0 AS cor0
----
-1394
-17
-561

query I rowsort
SELECT + col2 + col2 AS col2 FROM tab1 cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-1111
SELECT - 21 DIV col0 - + col2 * ( col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-1111
SELECT - 21 / col0 - + col2 * ( col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 * - col1 col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT tab1.col1 * 25 * col1 FROM tab1
----
16900
2500
4225

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

query I rowsort
SELECT DISTINCT - ( col2 ) * + col1 FROM tab0
----
-2838
-7462
-97

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

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

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

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

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

query I rowsort
SELECT DISTINCT - + col1 * col0 * + cor0.col2 + - 58 * + col2 + - col1 FROM tab0 AS cor0
----
-3550
-668965
-70112

query I rowsort
SELECT ALL - cor0.col1 + + ( - ( col0 ) ) * 80 FROM tab0 AS cor0
----
-2006
-2897
-7211

query I rowsort
SELECT DISTINCT + col2 * col0 - + col1 * col1 AS col0 FROM tab1 AS cor0
----
-514
3548
7511

query I rowsort
SELECT DISTINCT ( - col0 ) * + tab0.col2 * + col2 - - col2 AS col1 FROM tab0
----
-26103
-34
-598354

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

query I rowsort
SELECT DISTINCT 78 - - col1 AS col1 FROM tab1
----
104
88
91

query I rowsort
SELECT + + ( cor0.col0 ) + col0 * col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL - + ( cor0.col1 ) * cor0.col0 * + 77 FROM tab2 cor0
----
-103411
-16709
-354354

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

skipif mysql # not compatible
query I rowsort label-1130
SELECT + + col1 / - 40 AS col2 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT col2 * - 7 FROM tab2 AS cor0
----
-182
-189
-266

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1133
SELECT - 22 DIV 9 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

skipif mysql # not compatible
query I rowsort label-1133
SELECT - 22 / 9 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

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

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

query I rowsort
SELECT col2 * col2 + col0 * - col1 AS col0 FROM tab1 AS cor0
----
2609
2838
8176

query I rowsort
SELECT DISTINCT - col2 * ( 39 ) AS col2 FROM tab1 AS cor0
----
-2106
-2223
-3744

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1137
SELECT - col0 + - CAST( NULL AS SIGNED ) 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-1137
SELECT - col0 + - CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * ( - col0 ) AS col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - cor0.col2 * 98 + 53 FROM tab2 AS cor0
----
-2495
-2593
-3671

query I rowsort
SELECT ALL + col1 * + ( - col2 * - col1 ) FROM tab2 AS cor0
----
10982
25947
90506

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

query I rowsort
SELECT DISTINCT + col2 + + col2 * + col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT - 75 + col1 * + col2 AS col1 FROM tab0
----
22
2763
7387

query I rowsort
SELECT DISTINCT - col0 * - col1 * col2 + 33 FROM tab1
----
36513
4245
99873

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to 283f1c907a0999dbd972d3bd45746c06

query I rowsort
SELECT ALL col0 - + 9 * - ( cor0.col2 ) * + 34 AS col1 FROM tab2 AS cor0
----
11707
8034
8269

query I rowsort
SELECT - col0 * 58 + col0 FROM tab1 AS cor0
----
-171
-3648
-4560

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1149
SELECT ALL CAST( - col1 AS SIGNED ) AS col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1149
SELECT ALL CAST ( - col1 AS INTEGER ) AS col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + - cor0.col1 * col1 * + col1 AS col2 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT + col1 * 61 AS col2 FROM tab0 cor0
----
5246
5551
5917

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

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

query I rowsort
SELECT ALL col2 + col0 * 80 + - col0 * col1 FROM tab2
----
1664
370
5015

query I rowsort
SELECT DISTINCT cor0.col0 * 83 FROM tab1, tab1 AS cor0
----
249
5312
6640

query I rowsort
SELECT - + ( cor0.col2 ) + + cor0.col1 - cor0.col0 FROM tab2 AS cor0
----
-100
-3
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-1157
SELECT col1 DIV - col1 + + ( 56 ) * col1 * 93 AS col1 FROM tab0 AS cor0
----
447887
473927
505175

skipif mysql # not compatible
query I rowsort label-1157
SELECT col1 / - col1 + + ( 56 ) * col1 * 93 AS col1 FROM tab0 AS cor0
----
447887
473927
505175

onlyif mysql # use DIV operator for integer division
query I rowsort label-1158
SELECT ALL col1 * col0 DIV ( col1 ) AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1158
SELECT ALL col1 * col0 / ( col1 ) AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col0 * + col0 + 56 FROM tab1 AS cor0
----
4152
6456
65

query I rowsort
SELECT DISTINCT - col2 + col1 * - col1 AS col1 FROM tab2 AS cor0
----
-327
-3507
-988

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1162
SELECT + col2 * col1 * + ( col2 ) + col1 DIV 28 AS col0 FROM tab0
----
100
611887
93657

skipif mysql # not compatible
query I rowsort label-1162
SELECT + col2 * col1 * + ( col2 ) + col1 / 28 AS col0 FROM tab0
----
100
611887
93657

query I rowsort
SELECT DISTINCT 41 + tab1.col2 AS col0 FROM tab1
----
137
95
98

query I rowsort
SELECT - 68 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT ALL 56 + cor0.col1 + + 56 * col2 FROM tab0 AS cor0
----
1990
209
4739

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

query I rowsort
SELECT DISTINCT - + 72 AS col0 FROM tab0 AS cor0
----
-72

query I rowsort
SELECT ALL + 98 + + col1 AS col0 FROM tab1 AS cor0
----
108
111
124

query I rowsort
SELECT ALL - ( col1 ) * + ( 15 ) + + col1 AS col0 FROM tab0 AS cor0
----
-1204
-1274
-1358

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

query I rowsort
SELECT + - col0 * - ( 47 ) - - col0 * 72 * col2 FROM tab0 AS cor0
----
4165
529639
58152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - col0 col2 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1173
SELECT ALL - - col1 + + CAST( - 25 AS SIGNED ) FROM tab0 AS cor0
----
61
66
72

skipif mysql # not compatible
query I rowsort label-1173
SELECT ALL - - col1 + + CAST ( - 25 AS INTEGER ) FROM tab0 AS cor0
----
61
66
72

query I rowsort
SELECT DISTINCT + col2 * - col2 + + cor0.col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT col1 * col1 * 27 + col1 * - 80 FROM tab1 AS cor0
----
16172
1900
3523

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + + col0 col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1177
SELECT + cor0.col1 * col0 + ( + col0 + CAST( + col1 AS SIGNED ) ) * col2 AS col2 FROM tab1 AS cor0
----
1644
4858
9968

skipif mysql # not compatible
query I rowsort label-1177
SELECT + cor0.col1 * col0 + ( + col0 + CAST ( + col1 AS INTEGER ) ) * col2 AS col2 FROM tab1 AS cor0
----
1644
4858
9968

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

query I rowsort
SELECT ALL 62 * + 63 AS col0 FROM tab0 AS cor0
----
3906
3906
3906

query I rowsort
SELECT ALL ( 8 ) FROM tab1
----
8
8
8

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

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

query I rowsort
SELECT 19 * col1 FROM tab2 cor0
----
1121
323
589

query I rowsort
SELECT ALL 92 + col1 * col0 AS col1 FROM tab2 AS cor0
----
1435
309
4694

query I rowsort
SELECT + + ( + 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-1186
SELECT + ( cor0.col0 ) * + CAST( + 54 AS SIGNED ) col0 FROM tab0 AS cor0
----
1296
1890
4806

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1186
SELECT + ( cor0.col0 ) * + CAST ( + 54 AS INTEGER ) col0 FROM tab0 AS cor0
----
1296
1890
4806

onlyif mysql # use DIV operator for integer division
query I rowsort label-1187
SELECT + 4 DIV + col1 + + tab2.col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1187
SELECT + 4 / + col1 + + tab2.col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1188
SELECT col0 + - 7 DIV col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1188
SELECT col0 + - 7 / col1 FROM tab2
----
7
78
79

query I rowsort
SELECT - 77 + 13 FROM tab0
----
-64
-64
-64

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

query I rowsort
SELECT cor0.col0 + - col1 * - col1 + col1 FROM tab1 AS cor0
----
174
262
705

query I rowsort
SELECT tab1.col0 * - tab1.col0 * - col1 FROM tab1
----
234
40960
83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1193
SELECT 99 * + ( col2 ) * + CAST( NULL AS DECIMAL ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1193
SELECT 99 * + ( col2 ) * + CAST ( NULL AS REAL ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * + ( col0 * - 42 + - tab2.col1 ) FROM tab2
----
-2275
-260130
-263465

query I rowsort
SELECT DISTINCT - 26 * ( + col0 ) FROM tab2
----
-182
-2028
-2054

query I rowsort
SELECT DISTINCT - 66 * - col1 - col1 FROM tab0
----
5590
5915
6305

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

query I rowsort
SELECT - ( + col2 * - col2 ) FROM tab0
----
1
1089
6724

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

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

query I rowsort
SELECT + 55 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query IIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 WHERE NULL = NULL
----

query I rowsort
SELECT - 38 + - col1 FROM tab1 AS cor0
----
-48
-51
-64

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

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

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

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

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

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

query I rowsort
SELECT 8 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT DISTINCT col1 * ( + col2 * tab2.col0 + + col2 ) FROM tab2
----
121186
51680
6696

query I rowsort
SELECT DISTINCT - + col1 * + ( 37 ) * + col0 AS col0 FROM tab0 cor0
----
-125615
-299663
-76368

query I rowsort
SELECT + 50 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT DISTINCT + 52 AS col0 FROM tab1 AS cor0
----
52

query I rowsort
SELECT DISTINCT ( 49 ) * - col0 FROM tab0 cor0
----
-1176
-1715
-4361

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 33 * - 27 + col2 * - col1 * col1 col0 FROM tab0 AS cor0
----
-10300
-244959
-679933

query I rowsort
SELECT ALL - 33 + col1 FROM tab1 AS cor0
----
-20
-23
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + + col2 col2 FROM tab0 AS cor0
----
171
36
57

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

query I rowsort
SELECT + + 76 AS col2 FROM tab0 AS cor0
----
76
76
76

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * 18 + + col1 col0 FROM tab0 AS cor0
----
1634
1729
1843

query I rowsort
SELECT ALL + ( - cor0.col2 ) + + cor0.col2 * + col1 * + col1 FROM tab0 AS cor0
----
244035
678960
9408

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

query I rowsort
SELECT col2 * + cor0.col1 * 14 + + col2 AS col0 FROM tab2 AS cor0
----
11745
21502
9082

query I rowsort
SELECT - 45 + + col0 AS col0 FROM tab1 AS cor0
----
-42
19
35

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

query I rowsort
SELECT DISTINCT - 42 * col1 FROM tab0
----
-3612
-3822
-4074

onlyif mysql # use DIV operator for integer division
query I rowsort label-1228
SELECT ( - col1 ) DIV tab1.col1 AS col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1228
SELECT ( - col1 ) / tab1.col1 AS col1 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 43 * + col0 col1 FROM tab1 AS cor0
----
129
2752
3440

query I rowsort
SELECT ALL 57 + + col1 FROM tab2 AS cor0
----
116
74
88

query I rowsort
SELECT + col2 * - col1 + + col2 * 26 FROM tab0 AS cor0
----
-1980
-5330
-71

query I rowsort
SELECT ALL 25 + col0 + ( + cor0.col2 + col1 ) * + ( + cor0.col2 + col0 ) FROM tab1 AS cor0
----
19289
4588
8196

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col0 - col2 col2 FROM tab0 AS cor0
----
-36
-7380
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 + + cor1.col1 col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1edafae27e0cf081741125357f35abd8

query I rowsort
SELECT ALL - cor0.col1 * ( 67 ) FROM tab2 AS cor0
----
-1139
-2077
-3953

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

query I rowsort
SELECT - col1 * + col2 + 57 FROM tab1
----
-1191
-1347
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 19 + - col1 col1 FROM tab0
----
-105
-110
-116

query I rowsort
SELECT - col2 + - col2 * 80 FROM tab1
----
-4374
-4617
-7776

query I rowsort
SELECT ALL ( - col1 * + 16 ) + col2 FROM tab1
----
-103
-112
-362

query I rowsort
SELECT 25 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT + 46 + - col0 FROM tab0 AS cor0
----
-43
11
22

query I rowsort
SELECT DISTINCT - 29 * - col1 * cor0.col2 FROM tab2 cor0
----
18734
24273
44486

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

query I rowsort
SELECT DISTINCT 48 * - col1 + ( col0 ) AS col0 FROM tab1 AS cor0
----
-1245
-416
-544

query I rowsort
SELECT ALL + - col0 + cor0.col2 * ( + 66 ) AS col1 FROM tab0 AS cor0
----
2154
31
5323

query I rowsort
SELECT - - 50 * col0 FROM tab1 AS cor0
----
150
3200
4000

onlyif mysql # use DIV operator for integer division
query I rowsort label-1248
SELECT + col2 DIV col1 + CAST( - col0 + col0 AS SIGNED ) * col2 col1 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1248
SELECT + col2 / col1 + CAST ( - col0 + col0 AS INTEGER ) * col2 col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT DISTINCT - + 86 AS col2 FROM tab0 AS cor0
----
-86

query I rowsort
SELECT DISTINCT - 60 * - col0 + col2 AS col1 FROM tab0 cor0
----
1473
2101
5422

query I rowsort
SELECT - 22 * col1 + 20 - col0 FROM tab1 cor0
----
-264
-346
-555

query I rowsort
SELECT - - col0 + - cor0.col1 * + col1 * + col2 AS col2 FROM tab1 AS cor0
----
-16144
-36501
-5636

query I rowsort
SELECT + - cor0.col1 + col1 * col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT + cor0.col2 + + col1 * col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL - cor0.col1 * - col1 + + col1 * col0 AS col1 FROM tab1 AS cor0
----
1209
740
754

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1257
SELECT + col1 + - CAST( col0 AS SIGNED ) FROM tab1 cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-1257
SELECT + col1 + - CAST ( col0 AS INTEGER ) FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT ALL - + col1 + 64 FROM tab2 AS cor0
----
33
47
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1259
SELECT col2 * + col2 DIV - col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1259
SELECT col2 * + col2 / - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - col1 * - 76 + - col0 FROM tab0 AS cor0
----
6512
6827
7337

onlyif mysql # use DIV operator for integer division
query I rowsort label-1261
SELECT col1 + col1 DIV ( col2 ) col0 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1261
SELECT col1 + col1 / ( col2 ) col0 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1262
SELECT ALL + col2 DIV - tab2.col0 + col0 FROM tab2
----
4
78
79

skipif mysql # not compatible
query I rowsort label-1262
SELECT ALL + col2 / - tab2.col0 + col0 FROM tab2
----
4
78
79

query I rowsort
SELECT col0 + col2 - - col1 FROM tab2
----
134
163
65

query I rowsort
SELECT DISTINCT + 97 + col1 * 3 + + tab0.col1 AS col1 FROM tab0
----
441
461
485

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

skipif mysql # not compatible
query I rowsort label-1265
SELECT ALL col1 + - tab1.col0 + tab1.col0 * + ( col2 ) * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - 56 ) * col1 - col0 FROM tab2 cor0
----
1729
3226
873

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + 99 col0 FROM tab2 AS cor0
----
-2574
-2673
-3762

onlyif mysql # use DIV operator for integer division
query I rowsort label-1269
SELECT DISTINCT - + col1 + 95 DIV col0 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-1269
SELECT DISTINCT - + col1 + 95 / col0 FROM tab0 AS cor0
----
-83
-90
-95

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

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

query I rowsort
SELECT + + ( + 36 ) * col0 FROM tab0 AS cor0
----
1260
3204
864

query I rowsort
SELECT ALL - 96 + + col0 + - col1 * 48 * col1 FROM tab1 AS cor0
----
-32541
-4832
-8128

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

query I rowsort
SELECT - - 5 * + col1 AS col2 FROM tab1 AS cor0
----
130
50
65

query I rowsort
SELECT DISTINCT - + ( - col0 ) * col0 + cor0.col2 FROM tab0 AS cor0
----
1226
609
8003

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

query I rowsort
SELECT DISTINCT + 80 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
115
7378
872

onlyif mysql # use DIV operator for integer division
query I rowsort label-1278
SELECT ALL + + col2 + + col2 DIV col1 FROM tab1 cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-1278
SELECT ALL + + col2 + + col2 / col1 FROM tab1 cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 85 AS REAL ) * cor0.col0 + + CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT DISTINCT - - 60 * cor0.col2 AS col2 FROM tab1 AS cor0
----
3240
3420
5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1281
SELECT - col0 DIV + tab1.col1 - tab1.col2 AS col2 FROM tab1
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-1281
SELECT - col0 / + tab1.col1 - tab1.col2 AS col2 FROM tab1
----
-102
-54
-63

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

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

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

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

query I rowsort
SELECT ALL 21 AS col2 FROM tab1
----
21
21
21

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + + cor0.col1 * 62 * col1 col1 FROM tab1 AS cor0
----
10491
41938
6210

query I rowsort
SELECT ALL ( 68 * + col1 ) FROM tab2
----
1156
2108
4012

query I rowsort
SELECT DISTINCT + 14 * + 45 FROM tab0
----
630

query I rowsort
SELECT DISTINCT ( col2 * col2 ) FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ( ( col1 ) + col0 ) FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT + 20 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
20

query I rowsort
SELECT DISTINCT - tab1.col0 AS col1 FROM tab1, tab0 AS cor0, tab0, tab0 AS cor1
----
-3
-64
-80

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

query I rowsort
SELECT ALL + col0 + + col2 * + 24 FROM tab0 AS cor0
----
2057
59
816

query I rowsort
SELECT ALL 34 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT - col2 * 19 + 93 * col0 FROM tab1 AS cor0
----
-747
4869
5616

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

query I rowsort
SELECT ALL + + col1 * 26 + col0 AS col1 FROM tab2 AS cor0
----
1612
521
813

query I rowsort
SELECT DISTINCT + + col2 * + 35 AS col2 FROM tab0 AS cor0
----
1155
2870
35

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

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

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

query I rowsort
SELECT + col0 + col1 * col0 AS col0 FROM tab2
----
1422
224
4680

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1305
SELECT col2 + ( - 1 + - col2 ) / CAST( NULL AS DECIMAL ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1305
SELECT col2 + ( - 1 + - col2 ) / CAST ( NULL AS REAL ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 47 col2 FROM tab0 cor0
----
133
138
144

query I rowsort
SELECT DISTINCT - col0 * + ( + 93 ) FROM tab0 AS cor0
----
-2232
-3255
-8277

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

query I rowsort
SELECT DISTINCT + - col2 * + col0 + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL - + col1 + + 63 * col1 FROM tab1 AS cor0
----
1612
620
806

query I rowsort
SELECT DISTINCT ( col2 ) + cor0.col2 + + ( + 83 + col2 ) * - col1 * - col1 FROM tab0 AS cor0
----
1366529
790358
858002

query I rowsort
SELECT DISTINCT - 88 * cor0.col2 + + cor0.col1 FROM tab1 cor0
----
-4726
-5006
-8435

query I rowsort
SELECT DISTINCT + col0 * col0 * - col0 + col2 * col1 FROM tab0 AS cor0
----
-10986
-42778
-697507

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

query I rowsort
SELECT + 60 * 78 FROM tab1 AS cor0
----
4680
4680
4680

query I rowsort
SELECT + - cor0.col2 + + cor0.col1 + + col2 * - col1 FROM tab1 AS cor0
----
-1331
-1432
-617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 29 col2 FROM tab2, tab0 cor0, tab0 AS cor1
----
29

query I rowsort
SELECT col2 - col0 AS col2 FROM tab0 WHERE NOT NULL NOT BETWEEN col2 * - col0 AND ( NULL )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 - + col1 col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT ALL + col0 - + col1 * col1 FROM tab0
----
-7372
-8192
-9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT DISTINCT - 92 AS col1 FROM tab0, tab0 AS cor0
----
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-1324
SELECT + col0 DIV CAST( 50 AS SIGNED ) + col2 FROM tab2 AS cor0
----
27
27
39

skipif mysql # not compatible
query I rowsort label-1324
SELECT + col0 / CAST ( 50 AS INTEGER ) + col2 FROM tab2 AS cor0
----
27
27
39

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

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

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

query I rowsort
SELECT ALL + tab0.col2 FROM tab0, tab0 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT DISTINCT 30 AS col1 FROM tab1, tab1 AS cor0, tab0 cor1
----
30

query I rowsort
SELECT ALL + cor0.col1 + - cor0.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 0bd022e691ee49f12c598975818ed537

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1330
SELECT col0 * - CAST( + 58 AS SIGNED ) AS col0 FROM tab2
----
-406
-4524
-4582

skipif mysql # not compatible
query I rowsort label-1330
SELECT col0 * - CAST ( + 58 AS INTEGER ) AS col0 FROM tab2
----
-406
-4524
-4582

query I rowsort
SELECT - col1 + - 90 FROM tab0
----
-176
-181
-187

query I rowsort
SELECT + col2 * ( + col0 ) + tab2.col0 FROM tab2
----
196
2106
3081

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

query I rowsort
SELECT DISTINCT col1 * + 19 FROM tab0 AS cor0
----
1634
1729
1843

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

query I rowsort
SELECT DISTINCT + col0 + - ( - 17 ) FROM tab2 AS cor0
----
24
95
96

query I rowsort
SELECT col0 * + col0 + + col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT - col2 * + 96 + + col2 AS col1 FROM tab1 AS cor0
----
-5130
-5415
-9120

query I rowsort
SELECT ALL + col1 * + ( col2 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + cor0.col0 * 71 - cor0.col2 AS col2 FROM tab0 AS cor0
----
1671
2484
6237

query I rowsort
SELECT + 96 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

onlyif mysql # use DIV operator for integer division
query I rowsort label-1342
SELECT + 7 * col1 DIV col2 FROM tab1
----
0
1
3

skipif mysql # not compatible
query I rowsort label-1342
SELECT + 7 * col1 / col2 FROM tab1
----
0
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 54 + 21 * + col2 - + col0 * 75 col1 FROM tab2
----
-5073
-5250
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1344
SELECT DISTINCT 61 DIV col0 AS col2 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1344
SELECT DISTINCT 61 / col0 AS col2 FROM tab0
----
0
1
2

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 - ( 5 * + col1 ) - col2 AS col0 FROM tab2
----
-123
-182
-321

query I rowsort
SELECT ALL - 41 + + col2 * - col0 * col2 FROM tab1 AS cor0
----
-207977
-737321
-8789

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

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

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

query I rowsort
SELECT ALL + col1 * col2 * 27 FROM tab2 cor0
----
17442
22599
41418

onlyif mysql # use DIV operator for integer division
query I rowsort label-1351
SELECT ALL - col0 + - col0 DIV col0 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-1351
SELECT ALL - col0 + - col0 / col0 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT DISTINCT 43 AS col0 FROM tab2 AS cor0
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-1353
SELECT ALL cor0.col1 DIV + col0 + - 62 FROM tab2 cor0
----
-58
-62
-62

skipif mysql # not compatible
query I rowsort label-1353
SELECT ALL cor0.col1 / + col0 + - 62 FROM tab2 cor0
----
-58
-62
-62

query I rowsort
SELECT - + 7 + - col2 * col0 + 43 AS col0 FROM tab1 AS cor0
----
-126
-3612
-7644

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1357
SELECT 31 * col0 + col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
217
2418
2451

skipif mysql # not compatible
query I rowsort label-1357
SELECT 31 * col0 + col2 / + col1 AS col2 FROM tab2 AS cor0
----
217
2418
2451

query I rowsort
SELECT DISTINCT + + 76 + col0 AS col0 FROM tab1 AS cor0
----
140
156
79

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

query I rowsort
SELECT ALL + cor0.col1 * + col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 69 AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT + 87 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT - col0 + 63 AS col2 FROM tab2
----
-15
-16
56

query I rowsort
SELECT + tab2.col1 + ( col0 ) AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT col2 * ( + 23 ) FROM tab0 AS cor0
----
1886
23
759

query I rowsort
SELECT DISTINCT - col0 * + col2 + - col0 AS col1 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL + + col1 + + col1 * - col0 AS col1 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - ( - col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL col0 * 72 + + col1 FROM tab2 AS cor0
----
535
5675
5705

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + col1 - - 76 AS col2 FROM tab2 AS cor0
----
107
135
93

query I rowsort
SELECT ALL + + 75 + + cor0.col0 FROM tab1 AS cor0
----
139
155
78

query I rowsort
SELECT ALL ( + cor0.col2 ) + - 33 FROM tab0, tab2 cor0
----
9 values hashing to d999f039cc3905924bb4af9e01412460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + - 50 * cor0.col2 col0 FROM tab1 AS cor0
----
-2697
-2786
-4720

query I rowsort
SELECT - ( 70 ) - col0 * + col0 AS col2 FROM tab2 AS cor0
----
-119
-6154
-6311

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1377
SELECT col0 - col0 DIV col1 AS col2 FROM tab1
----
3
58
74

skipif mysql # not compatible
query I rowsort label-1377
SELECT col0 - col0 / col1 AS col2 FROM tab1
----
3
58
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-1378
SELECT - col1 DIV - col0 + col2 * col2 AS col2 FROM tab2
----
1444
676
733

skipif mysql # not compatible
query I rowsort label-1378
SELECT - col1 / - col0 + col2 * col2 AS col2 FROM tab2
----
1444
676
733

query I rowsort
SELECT DISTINCT col0 * 20 AS col1 FROM tab2 cor0
----
140
1560
1580

query I rowsort
SELECT + - col2 * col2 * col1 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT - 51 + col2 * col1 FROM tab2 AS cor0
----
1483
595
786

query I rowsort
SELECT ALL col2 + + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - ( + col2 ) AS col2 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1384
SELECT DISTINCT - col0 * cor0.col0 * - col1 + + 56 DIV col0 AS col2 FROM tab2 cor0
----
106097
1527
358956

skipif mysql # not compatible
query I rowsort label-1384
SELECT DISTINCT - col0 * cor0.col0 * - col1 + + 56 / col0 AS col2 FROM tab2 cor0
----
106097
1527
358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 82 * + col0 + - ( col2 ) - col2 col0 FROM tab0 AS cor0
----
1902
2868
7134

query I rowsort
SELECT ALL + + 11 * col1 + - ( + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
108
334
571

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1387
SELECT DISTINCT - col1 + - cor0.col2 + + CAST( 36 AS SIGNED ) col1 FROM tab0 cor0
----
-137
-62
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1387
SELECT DISTINCT - col1 + - cor0.col2 + + CAST ( 36 AS INTEGER ) col1 FROM tab0 cor0
----
-137
-62
-83

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

query I rowsort
SELECT + 96 + col1 FROM tab2 cor0
----
113
127
155

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1391
SELECT DISTINCT 77 + - col0 DIV + 72 - col1 FROM tab1 AS cor0
----
51
63
67

skipif mysql # not compatible
query I rowsort label-1391
SELECT DISTINCT 77 + - col0 / + 72 - col1 FROM tab1 AS cor0
----
51
63
67

query I rowsort
SELECT col2 * - col2 * 70 + + ( + col0 ) FROM tab0 AS cor0
----
-35
-470591
-76206

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

query I rowsort
SELECT + - 46 + cor0.col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1271
-622
-7967

query I rowsort
SELECT 12 * col0 AS col2 FROM tab0 AS cor0
----
1068
288
420

onlyif mysql # use DIV operator for integer division
query I rowsort label-1396
SELECT DISTINCT - + ( + col2 ) * CAST( cor0.col2 AS SIGNED ) + col0 * ( - cor0.col0 ) - + col0 DIV col1 FROM tab1 AS cor0
----
-15622
-2925
-7351

skipif mysql # not compatible
query I rowsort label-1396
SELECT DISTINCT - + ( + col2 ) * CAST ( cor0.col2 AS INTEGER ) + col0 * ( - cor0.col0 ) - + col0 / col1 FROM tab1 AS cor0
----
-15622
-2925
-7351

query I rowsort
SELECT DISTINCT - - 60 * - col2 AS col1 FROM tab2 cor0
----
-1560
-1620
-2280

query I rowsort
SELECT ALL + 49 * + col2 FROM tab2 AS cor0
----
1274
1323
1862

query I rowsort
SELECT ALL 74 + + col2 + col1 AS col2 FROM tab1 AS cor0
----
141
154
183

query I rowsort
SELECT + 10 FROM tab1, tab0 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # use DIV operator for integer division
query I rowsort label-1401
SELECT DISTINCT col1 DIV tab2.col0 AS col0 FROM tab2
----
0
4

skipif mysql # not compatible
query I rowsort label-1401
SELECT DISTINCT col1 / tab2.col0 AS col0 FROM tab2
----
0
4

query I rowsort
SELECT ALL + + col0 + col0 * cor0.col1 + col0 AS col2 FROM tab0 AS cor0
----
2112
3465
8277

query I rowsort
SELECT DISTINCT + col2 * - 62 + col0 FROM tab0 AS cor0
----
-2022
-27
-4995

query I rowsort
SELECT DISTINCT col2 * 16 FROM tab0 AS cor0
----
1312
16
528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + + col1 * 53 + + col1 FROM tab1
----
1350
483
606

query I rowsort
SELECT - - col2 * col2 + col2 * col0 FROM tab1 cor0
----
16896
3078
6897

query I rowsort
SELECT DISTINCT - tab2.col2 * - 98 FROM tab2, tab1, tab1 AS cor0, tab0
----
2548
2646
3724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 49 col0 FROM tab1, tab1 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to e587c122dea39a2488ff88b884cea462

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

query I rowsort
SELECT DISTINCT + + cor0.col1 * ( + ( - col0 ) ) - + 8 * 86 AS col2 FROM tab1 AS cor0
----
-1328
-1728
-766

query I rowsort
SELECT ALL - col0 * + 87 + col0 AS col2 FROM tab2 AS cor0
----
-602
-6708
-6794

query I rowsort
SELECT ALL - - 96 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT col0 * col2 * - 20 + 13 FROM tab0 AS cor0
----
-145947
-15827
-687

query I rowsort
SELECT + cor0.col2 + col1 + 30 AS col0 FROM tab2 AS cor0
----
115
85
88

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 4 AS REAL ) AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1417
SELECT ( - tab0.col0 * - col2 + + CAST( col2 AS SIGNED ) ) AS col0 FROM tab0
----
36
7380
825

skipif mysql # not compatible
query I rowsort label-1417
SELECT ( - tab0.col0 * - col2 + + CAST ( col2 AS INTEGER ) ) AS col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT - col0 * 41 FROM tab1
----
-123
-2624
-3280

query I rowsort
SELECT 89 * + col0 AS col2 FROM tab1
----
267
5696
7120

query I rowsort
SELECT + 97 + + col1 FROM tab1
----
107
110
123

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

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

skipif mysql # not compatible
query I rowsort label-1422
SELECT + ( - col1 ) * CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( - tab2.col2 ) * 91 AS col1 FROM tab2
----
-2366
-2457
-3458

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

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

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

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

query I rowsort
SELECT ALL col2 + col0 * - col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT + + col1 + + col2 FROM tab0 cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1429
SELECT ALL col1 + col0 DIV - cor0.col2 - col2 * - col1 FROM tab0 AS cor0
----
159
2924
7552

skipif mysql # not compatible
query I rowsort label-1429
SELECT ALL col1 + col0 / - cor0.col2 - col2 * - col1 FROM tab0 AS cor0
----
159
2924
7552

query I rowsort
SELECT + col1 + + col2 * col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 + + col1 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT col2 * + col0 * - col2 AS col1 FROM tab0
----
-26136
-35
-598436

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1434
SELECT col2 * + col2 + + col0 * - CAST( cor0.col0 AS SIGNED ) + col2 FROM tab0 AS cor0
----
-1115
-1223
546

skipif mysql # not compatible
query I rowsort label-1434
SELECT col2 * + col2 + + col0 * - CAST ( cor0.col0 AS INTEGER ) + col2 FROM tab0 AS cor0
----
-1115
-1223
546

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 + col1 col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT 74 * - tab0.col1 AS col1 FROM tab0
----
-6364
-6734
-7178

query I rowsort
SELECT - 82 * tab2.col0 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 42b59a367fa225585638578814d78b30

query I rowsort
SELECT col0 - col1 * 79 FROM tab1 AS cor0
----
-2051
-726
-947

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

query I rowsort
SELECT + + col0 * 91 + - col2 AS col2 FROM tab2 AS cor0
----
610
7072
7151

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

skipif mysql # not compatible
query I rowsort label-1441
SELECT col2 - cor0.col1 / + ( col0 ) AS col1 FROM tab2 AS cor0
----
23
26
38

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

skipif mysql # not compatible
query I rowsort label-1442
SELECT + col1 * - CAST ( NULL AS REAL ) - - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( 24 ) * - cor0.col0 + + 59 FROM tab1 AS cor0
----
131
1595
1979

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

query I rowsort
SELECT col2 * - col1 * tab2.col2 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-1446
SELECT tab2.col0 DIV - ( - tab2.col1 ) FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-1446
SELECT tab2.col0 / - ( - tab2.col1 ) FROM tab2
----
0
1
4

query I rowsort
SELECT col1 * + 61 AS col1 FROM tab1
----
1586
610
793

query I rowsort
SELECT col0 * + 93 - + cor0.col1 AS col0 FROM tab2 AS cor0
----
620
7195
7330

onlyif mysql # use DIV operator for integer division
query I rowsort label-1449
SELECT ALL CAST( col0 AS SIGNED ) DIV col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1449
SELECT ALL CAST ( col0 AS INTEGER ) / col0 FROM tab1 AS cor0
----
1
1
1

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1451
SELECT ALL ( ( col1 ) ) DIV 60 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1451
SELECT ALL ( ( col1 ) ) / 60 AS col0 FROM tab1 AS cor0
----
0
0
0

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

query I rowsort
SELECT + ( + 90 ) FROM tab1 cor0
----
90
90
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 41 col0 FROM tab1 AS cor0
----
-41
-41
-41

query I rowsort
SELECT ALL + col1 - - 59 * 15 FROM tab2
----
902
916
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-1456
SELECT - - cor0.col0 DIV + col0 - - col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-1456
SELECT - - cor0.col0 / + col0 - - col0 FROM tab2 AS cor0
----
79
8
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( 61 ) + col1 col1 FROM tab1 AS cor0
----
-35
-48
-51

query I rowsort
SELECT - tab1.col2 + + tab1.col0 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a62a6691988eb243604ec6133ae5eae4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 + - tab1.col2 col1 FROM tab1, tab2, tab0 AS cor0
----
-16
-51
7

query I rowsort
SELECT + 48 * + ( tab2.col0 ) AS col1 FROM tab2
----
336
3744
3792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 44 + col1 col2 FROM tab1
----
-18
-31
-34

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

query I rowsort
SELECT cor0.col2 AS col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT + 95 * - col2 - cor0.col0 FROM tab2 AS cor0
----
-2548
-2572
-3689

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1466
SELECT - col1 + - col2 DIV 95 AS col1 FROM tab1
----
-10
-14
-26

skipif mysql # not compatible
query I rowsort label-1466
SELECT - col1 + - col2 / 95 AS col1 FROM tab1
----
-10
-14
-26

query I rowsort
SELECT ( col0 ) + 83 AS col2 FROM tab2
----
161
162
90

query I rowsort
SELECT ALL + ( tab0.col2 ) * + col0 FROM tab0
----
35
7298
792

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

query I rowsort
SELECT + col0 + + 48 FROM tab0
----
137
72
83

query I rowsort
SELECT ALL - tab0.col2 - 54 AS col1 FROM tab0
----
-136
-55
-87

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

query I rowsort
SELECT col1 + + 75 AS col0 FROM tab0 AS cor0
----
161
166
172

query I rowsort
SELECT ALL + col1 * + col0 - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + col0 + - 69 * + col1 AS col2 FROM tab0 AS cor0
----
-5910
-6190
-6658

query I rowsort
SELECT - ( + col2 ) * ( 70 ) AS col2 FROM tab1 AS cor0
----
-3780
-3990
-6720

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 94 col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT + 78 * cor0.col1 + - ( col1 ) FROM tab0 AS cor0
----
6622
7007
7469

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 93 * - col0 ) col2 FROM tab0
----
2232
3255
8277

query IIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0 CROSS JOIN tab1 AS cor1
----
243 values hashing to 877a8dbac0e29b86e845fb64ed9d2242

query I rowsort
SELECT - col2 + col0 * ( col2 + + col2 ) FROM tab2
----
351
4030
5966

onlyif mysql # use DIV operator for integer division
query I rowsort label-1483
SELECT + 51 DIV - cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-1483
SELECT + 51 / - cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT col1 + col1 * tab1.col1 * tab1.col1 FROM tab1
----
1010
17602
2210

query I rowsort
SELECT ALL + col1 * - ( - col0 ) + + col1 * ( col2 ) AS col2 FROM tab2
----
1054
1989
6136

query I rowsort
SELECT DISTINCT col1 + - 7 AS col0 FROM tab2
----
10
24
52

query I rowsort
SELECT - col1 * - ( col0 ) + col1 FROM tab2 AS cor0
----
1360
248
4661

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

skipif mysql # not compatible
query I rowsort label-1488
SELECT - col1 + - CAST ( col2 AS INTEGER ) * - col2 AS col2 FROM tab0
----
-96
1003
6633

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

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

query I rowsort
SELECT ALL col2 * - ( col0 ) * cor0.col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 * col1 + ( col1 ) col2 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL col0 + 71 AS col2 FROM tab2
----
149
150
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1493
SELECT DISTINCT + CAST( - col1 AS SIGNED ) AS col2 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-1493
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
-10
-13
-26

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

query I rowsort
SELECT cor0.col1 * + ( + col1 ) + + 25 AS col0 FROM tab0 cor0
----
7421
8306
9434

query I rowsort
SELECT - + 74 + col1 AS col2 FROM tab1 AS cor0
----
-48
-61
-64

query I rowsort
SELECT ALL - 24 * 65 FROM tab0 AS cor0
----
-1560
-1560
-1560

query I rowsort
SELECT DISTINCT + 42 AS col2 FROM tab1 cor0
----
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT + 62 * col0 AS col0 FROM tab0 cor0
----
1488
2170
5518

query I rowsort
SELECT DISTINCT col2 * + 82 AS col1 FROM tab0 AS cor0
----
2706
6724
82

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1504
SELECT DISTINCT - CAST( - 24 AS SIGNED ) + col0 FROM tab2 AS cor0
----
102
103
31

skipif mysql # not compatible
query I rowsort label-1504
SELECT DISTINCT - CAST ( - 24 AS INTEGER ) + col0 FROM tab2 AS cor0
----
102
103
31

query I rowsort
SELECT ( - col0 + + col2 ) * - col2 AS col0 FROM tab2
----
-540
1352
1558

query I rowsort
SELECT ALL + cor0.col0 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * 11 col2 FROM tab1
----
110
143
286

query I rowsort
SELECT + ( + col0 ) * col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + ( col2 ) + col1 * + col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL - col2 * + col1 + - col0 * - col2 * col0 FROM tab2 AS cor0
----
156650
236512
486

query I rowsort
SELECT - - 73 * - cor0.col1 + - col0 FROM tab2 AS cor0
----
-1320
-2270
-4385

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

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

query I rowsort
SELECT + 73 + cor0.col1 FROM tab2 AS cor0
----
104
132
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1514
SELECT + + col2 + col1 * CAST( - cor0.col0 * col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-22793
-271492
-6700

skipif mysql # not compatible
query I rowsort label-1514
SELECT + + col2 + col1 * CAST ( - cor0.col0 * col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-22793
-271492
-6700

query I rowsort
SELECT + col2 + col1 * + 64 FROM tab0 AS cor0
----
5537
5906
6209

query I rowsort
SELECT 41 * col2 FROM tab2 AS cor0
----
1066
1107
1558

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1518
SELECT + 43 * + col2 DIV - col2 FROM tab1 AS cor0
----
-43
-43
-43

skipif mysql # not compatible
query I rowsort label-1518
SELECT + 43 * + col2 / - col2 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT + 54 + + cor0.col1 FROM tab0 AS cor0
----
140
145
151

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

query I rowsort
SELECT + col0 * cor0.col1 + - cor0.col2 AS col0 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + col2 + - 90 * 51 * - col1 AS col0 FROM tab2 AS cor0
----
142317
270836
78068

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

query I rowsort
SELECT DISTINCT - col2 + + col1 - 41 FROM tab1 AS cor0
----
-124
-69
-88

query I rowsort
SELECT ALL 24 AS col0 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT 8 * col1 + + 19 * - col2 * + col0 FROM tab0
----
-137934
-14360
111

query I rowsort
SELECT 19 - + col1 AS col1 FROM tab2 AS cor0
----
-12
-40
2

query I rowsort
SELECT + col0 + 36 - cor0.col2 FROM tab2 AS cor0
----
16
77
88

query I rowsort
SELECT + col1 * cor0.col0 + col2 * col2 * + col0 FROM tab1 AS cor0
----
208576
738320
8826

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 9 - - ( cor0.col0 ) col2 FROM tab0 AS cor0
----
240
350
890

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1532
SELECT ALL + col0 * 57 - - col1 DIV col2 AS col1 FROM tab1 AS cor0
----
171
3648
4560

skipif mysql # not compatible
query I rowsort label-1532
SELECT ALL + col0 * 57 - - col1 / col2 AS col1 FROM tab1 AS cor0
----
171
3648
4560

query I rowsort
SELECT + tab0.col1 * + col0 * ( col1 ) FROM tab0
----
177504
329315
737009

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

query I rowsort
SELECT DISTINCT tab0.col2 - col2 FROM tab0
----
0

query I rowsort
SELECT 39 * col2 + 18 + - col2 AS col1 FROM tab1
----
2070
2184
3666

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

query I rowsort
SELECT + col0 + col1 + - 92 FROM tab0
----
18
40
88

query I rowsort
SELECT DISTINCT - tab2.col2 + 10 FROM tab2
----
-16
-17
-28

query I rowsort
SELECT col0 * + col0 + col2 AS col2 FROM tab2
----
6110
6279
76

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 * CAST ( col1 AS REAL ) + col2 * CAST ( col0 AS INTEGER ) - - col1 FROM tab0 AS cor0
----
15670
8274
9541

query I rowsort
SELECT DISTINCT col0 * + 91 + col1 + + col0 FROM tab1 AS cor0
----
302
5898
7373

query I rowsort
SELECT - - col2 * 17 * - col0 + col1 FROM tab0 cor0
----
-123975
-13378
-498

query I rowsort
SELECT ALL + col0 * + 69 + 82 * + col0 FROM tab2 cor0
----
1057
11778
11929

query I rowsort
SELECT - col0 * - ( tab1.col2 ) AS col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT - col0 + + 54 + col2 FROM tab1 AS cor0
----
105
47
70

query I rowsort
SELECT cor0.col0 + - ( - col1 ) * col2 + col1 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT cor0.col2 * cor0.col1 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to f5605ce6cbd6ecc79a4a887488bb6947

query I rowsort
SELECT + + col1 * 51 * - col1 FROM tab0 cor0
----
-377196
-422331
-479859

query I rowsort
SELECT - - col0 * 33 FROM tab2 AS cor0
----
231
2574
2607

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

skipif mysql # not compatible
query I rowsort label-1551
SELECT + CAST ( 43 AS INTEGER ) FROM tab2 cor0
----
43
43
43

query I rowsort
SELECT + - col0 + col2 * col0 + col2 AS col2 FROM tab0 AS cor0
----
1
7291
801

query I rowsort
SELECT - 74 * - col2 AS col0 FROM tab1 AS cor0
----
3996
4218
7104

query I rowsort
SELECT - + 47 * col2 + col2 + - 8 FROM tab1 AS cor0
----
-2492
-2630
-4424

query I rowsort
SELECT + col1 + + cor0.col0 * - 62 * - col2 AS col2 FROM tab0 AS cor0
----
2267
452567
49190

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

query I rowsort
SELECT ALL + + 48 * col1 + 27 FROM tab1 cor0
----
1275
507
651

query I rowsort
SELECT + 43 + col2 AS col2 FROM tab1
----
100
139
97

query I rowsort
SELECT ALL 93 * col2 AS col0 FROM tab2 AS cor0
----
2418
2511
3534

onlyif mysql # use DIV operator for integer division
query I rowsort label-1560
SELECT - cor0.col2 DIV + col1 AS col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-1560
SELECT - cor0.col2 / + col1 AS col1 FROM tab1 cor0
----
-2
-5
-7

query I rowsort
SELECT DISTINCT - - 51 * + col1 + ( + cor0.col0 ) FROM tab1 AS cor0
----
1329
574
743

query I rowsort
SELECT + col1 + col0 * + 76 AS col2 FROM tab0 AS cor0
----
1910
2757
6855

query I rowsort
SELECT ALL - + 96 + + col2 AS col2 FROM tab2 AS cor0
----
-58
-69
-70

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1565
SELECT ALL - 14 + - cor0.col1 + + ( - 35 ) DIV + col1 FROM tab1 cor0
----
-27
-29
-41

skipif mysql # not compatible
query I rowsort label-1565
SELECT ALL - 14 + - cor0.col1 + + ( - 35 ) / + col1 FROM tab1 cor0
----
-27
-29
-41

query I rowsort
SELECT DISTINCT + col0 * + cor0.col2 + 73 AS col0 FROM tab2 AS cor0
----
2101
262
3075

query I rowsort
SELECT DISTINCT + - 6 * col1 FROM tab2 AS cor0
----
-102
-186
-354

onlyif mysql # use DIV operator for integer division
query I rowsort label-1568
SELECT ALL + + col2 + col1 DIV col1 AS col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-1568
SELECT ALL + + col2 + col1 / col1 AS col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT - col2 + - col1 - col1 FROM tab2 AS cor0
----
-144
-72
-89

query I rowsort
SELECT ALL + - col0 + col0 * + col0 FROM tab1 AS cor0
----
4032
6
6320

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

query I rowsort
SELECT + - cor0.col2 + - 22 * col0 + + col2 * col2 AS col0 FROM tab0 AS cor0
----
-770
4684
528

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

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

query I rowsort
SELECT cor0.col1 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT + col2 * 72 + col1 FROM tab2 AS cor0
----
1931
1975
2753

onlyif mysql # use DIV operator for integer division
query I rowsort label-1577
SELECT DISTINCT cor0.col2 DIV ( cor0.col1 * + cor0.col0 ) FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1577
SELECT DISTINCT cor0.col2 / ( cor0.col1 * + cor0.col0 ) FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1578
SELECT col2 + + ( - cor0.col2 ) DIV - col0 + - 27 AS col0 FROM tab0 AS cor0
----
-26
55
7

skipif mysql # not compatible
query I rowsort label-1578
SELECT col2 + + ( - cor0.col2 ) / - col0 + - 27 AS col0 FROM tab0 AS cor0
----
-26
55
7

query I rowsort
SELECT ALL - - col0 + cor0.col2 * col0 + col0 FROM tab1 AS cor0
----
168
3776
7840

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

query I rowsort
SELECT ALL + - ( col2 ) - + col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT + 62 * - col2 * + col1 + ( + col2 + - col1 ) FROM tab1 AS cor0
----
-35293
-77293
-87020

query I rowsort
SELECT ALL - + 57 - + cor0.col2 AS col0 FROM tab0 AS cor0
----
-139
-58
-90

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

query I rowsort
SELECT ALL + 87 + cor1.col2 - + 75 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2262c2f3e3d5cc56cd9d52c97ca1ab4a

query I rowsort
SELECT + col1 * + 58 AS col0 FROM tab2 AS cor0
----
1798
3422
986

query I rowsort
SELECT DISTINCT - + 65 * col0 * - col2 FROM tab1 AS cor0
----
10530
237120
499200

query I rowsort
SELECT ALL + 61 * col1 AS col2 FROM tab2 AS cor0
----
1037
1891
3599

query I rowsort
SELECT ALL + 11 + col2 * + col0 AS col0 FROM tab0 AS cor0
----
46
7309
803

onlyif mysql # use DIV operator for integer division
query I rowsort label-1590
SELECT DISTINCT + col2 DIV col2 + - 46 AS col1 FROM tab1 AS cor0
----
-45

skipif mysql # not compatible
query I rowsort label-1590
SELECT DISTINCT + col2 / col2 + - 46 AS col1 FROM tab1 AS cor0
----
-45

query I rowsort
SELECT DISTINCT - 56 * col2 * + col1 + col2 AS col0 FROM tab2 cor0
----
-36138
-46845
-85878

query I rowsort
SELECT ALL 8 AS col0 FROM tab1
----
8
8
8

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

query I rowsort
SELECT ( cor0.col0 ) * - 32 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f47532f5ec797870d70f0ae11e382976

query I rowsort
SELECT ALL - 33 * col0 FROM tab1
----
-2112
-2640
-99

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

query I rowsort
SELECT ALL + col0 * cor0.col2 + col0 + col1 FROM tab1 cor0
----
191
3722
7773

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

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

skipif mysql # not compatible
query I rowsort label-1599
SELECT DISTINCT + + col1 / - col0 - col1 FROM tab2 AS cor0
----
-17
-35
-59

query I rowsort
SELECT - col1 * - col1 + - cor0.col0 FROM tab2 AS cor0
----
210
3403
954

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

query I rowsort
SELECT ALL col0 + col1 - col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT cor0.col1 * col1 + col0 * + col2 FROM tab1 AS cor0
----
3748
7849
838

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT ( NULL ) = ( + col2 ) OR ( + col2 ) NOT IN ( col1 + - col2 + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - tab1.col0 * + col2 * col1 AS col1 FROM tab1
----
-36480
-4212
-99840

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 66 * - col1 * col0 col2 FROM tab2 AS cor0
----
14322
303732
88638

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1608
SELECT DISTINCT - CAST( + col0 + - col0 AS SIGNED ) FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-1608
SELECT DISTINCT - CAST ( + col0 + - col0 AS INTEGER ) FROM tab1
----
0

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

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

query I rowsort
SELECT + 73 * col0 + - cor0.col0 * col2 FROM tab1 AS cor0
----
-1840
1024
57

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

query I rowsort
SELECT + + 36 + - cor0.col2 + col2 * col1 FROM tab0 cor0
----
132
2841
7416

query I rowsort
SELECT col2 * - col1 * tab2.col0 + + col0 * col1 FROM tab2
----
-115050
-49691
-5642

query I rowsort
SELECT 56 + - col1 FROM tab0
----
-30
-35
-41

query I rowsort
SELECT ALL col0 * ( + col0 ) FROM tab1
----
4096
6400
9

query I rowsort
SELECT 74 + + col0 AS col1 FROM tab2
----
152
153
81

query I rowsort
SELECT ALL 53 * - col2 AS col2 FROM tab0
----
-1749
-4346
-53

query I rowsort
SELECT col0 + + col2 * col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT DISTINCT ( + 30 ) * col0 AS col1 FROM tab2
----
210
2340
2370

query I rowsort
SELECT col2 * - col0 * - col1 + col0 AS col2 FROM tab2
----
119730
51113
5866

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 * col1 col1 FROM tab1
----
1066
2132
820

query I rowsort
SELECT DISTINCT + 34 + + col1 * - col1 AS col1 FROM tab0
----
-7362
-8247
-9375

query I rowsort
SELECT DISTINCT 85 * col2 + tab1.col2 * col2 FROM tab1
----
17376
7506
8094

query I rowsort
SELECT tab1.col0 * - col2 + col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + col2 * col1 - + cor0.col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - 24 * col1 + + col0 AS col0 FROM tab2 AS cor0
----
-1338
-329
-737

query I rowsort
SELECT - col0 - - col0 * col0 * cor0.col2 FROM tab1 AS cor0
----
233408
483
614320

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 * col2 + + col0 col1 FROM tab1 AS cor0
----
-213
-3641
-7696

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

query I rowsort
SELECT DISTINCT + 14 - col1 FROM tab0 AS cor0
----
-72
-77
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1634
SELECT - col0 DIV tab1.col1 + col2 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-1634
SELECT - col0 / tab1.col1 + col2 FROM tab1
----
51
54
90

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

query III rowsort
SELECT ALL * FROM tab0 WHERE + col0 / - col1 + + col1 * + col1 + col2 >= NULL
----

query I rowsort
SELECT - tab0.col1 * - col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + tab2.col0 * - col0 * col2 FROM tab2
----
-1323
-158184
-237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 col1 FROM tab0 AS cor0 WHERE NOT col0 <> ( NULL )
----

query I rowsort
SELECT ALL + tab2.col0 + - tab2.col1 * col0 * col0 FROM tab2
----
-106018
-1512
-358878

query I rowsort
SELECT ALL + col2 + + col2 + col0 FROM tab1
----
111
178
272

onlyif mysql # use DIV operator for integer division
query I rowsort label-1642
SELECT DISTINCT - tab0.col0 DIV - col0 AS col1 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-1642
SELECT DISTINCT - tab0.col0 / - col0 AS col1 FROM tab0
----
1

query I rowsort
SELECT col1 * col1 - col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT ALL col1 + + col1 * col1 * + col2 + + col1 FROM tab2
----
11016
26009
90624

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

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL IN ( + col1 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 * col1 col1 FROM tab0
----
3395
664118
68112

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

query I rowsort
SELECT tab0.col2 + - col2 * - col1 AS col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL col0 + col0 + col2 AS col0 FROM tab2
----
182
196
41

query I rowsort
SELECT col0 * col1 * col1 AS col1 FROM tab1
----
13520
2028
6400

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

query I rowsort
SELECT DISTINCT + col1 * tab0.col1 + tab0.col1 + col0 AS col2 FROM tab0
----
7506
8461
9541

query I rowsort
SELECT col2 FROM tab1 WHERE NOT col0 * col2 = NULL
----

query I rowsort
SELECT + + col1 + col1 * + col0 FROM tab2 AS cor0
----
1360
248
4661

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) IN ( + col1 / + col1 )
----

query III rowsort
SELECT * FROM tab2 WHERE + col0 + - col0 BETWEEN col0 AND + col2
----

query I rowsort
SELECT + col0 + col1 * col0 + - col2 * - col1 * cor0.col2 AS col1 FROM tab1 AS cor0
----
120928
33194
75897

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1661
SELECT - col2 DIV cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-1661
SELECT - col2 / cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
23
35
89

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

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

query I rowsort
SELECT ALL col1 * + col0 * cor0.col2 + + col2 FROM tab0 AS cor0
----
3396
664200
68145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 col2 FROM tab2 WHERE ( NULL ) IN ( col1 + - col1 )
----

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

query I rowsort
SELECT 88 + ( - cor0.col0 ) AS col1 FROM tab1 AS cor0
----
24
8
85

query I rowsort
SELECT ALL + col1 + + 83 * col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-235468
-619255
-7954

query I rowsort
SELECT DISTINCT - - cor0.col1 * 21 - - col0 AS col1 FROM tab2 cor0
----
1317
436
658

query I rowsort
SELECT DISTINCT - ( - col1 ) + col2 * cor0.col1 - cor0.col0 * - col2 AS col2 FROM tab1 cor0
----
1592
4228
8941

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

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

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

query I rowsort
SELECT DISTINCT + 54 * + col0 AS col1 FROM tab2 AS cor0
----
378
4212
4266

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 99 col0 FROM tab0 cor0
----
-99
-99
-99

query I rowsort
SELECT - ( 49 ) AS col0 FROM tab2 AS cor0
----
-49
-49
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-1677
SELECT + ( 23 ) DIV - tab2.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 1313fe5a78d4cb52a368eb751ada9cfa

skipif mysql # not compatible
query I rowsort label-1677
SELECT + ( 23 ) / - tab2.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 1313fe5a78d4cb52a368eb751ada9cfa

query I rowsort
SELECT DISTINCT - 57 * - 62 FROM tab1 cor0
----
3534

query I rowsort
SELECT ALL + col1 * - 75 FROM tab1 AS cor0
----
-1950
-750
-975

query I rowsort
SELECT - col0 + - col2 * col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT - cor0.col2 + - 26 FROM tab2 AS cor0
----
-52
-53
-64

query I rowsort
SELECT - col1 + 89 * col1 AS col0 FROM tab1 cor0
----
1144
2288
880

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

skipif mysql # not compatible
query I rowsort label-1683
SELECT - ( - col2 ) / col0 - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1685
SELECT DISTINCT - 38 DIV + tab2.col1 col0 FROM tab2
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1685
SELECT DISTINCT - 38 / + tab2.col1 col0 FROM tab2
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 * col0 col0 FROM tab0
----
1968
2870
7298

query I rowsort
SELECT DISTINCT col2 * 42 FROM tab2
----
1092
1134
1596

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

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

query I rowsort
SELECT col0 + - col0 * 89 AS col0 FROM tab1
----
-264
-5632
-7040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * tab1.col2 + + 53 col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to cdcf34348629d1bd1879bf4d4a4d8658

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

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

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

skipif mysql # not compatible
query I rowsort label-1693
SELECT + cor0.col2 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col1 + 97 AS col1 FROM tab2
----
114
128
156

query I rowsort
SELECT DISTINCT - col2 * 29 * + 67 FROM tab2
----
-50518
-52461
-73834

query I rowsort
SELECT - col1 * cor0.col0 + - 41 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-2828
-5319
-987

query I rowsort
SELECT DISTINCT col2 + col1 * + 66 AS col0 FROM tab2 cor0
----
1160
2073
3920

query I rowsort
SELECT + col0 + + cor0.col2 + + col2 FROM tab1 cor0
----
111
178
272

query I rowsort
SELECT col0 * ( col1 * col1 ) AS col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT - + 70 * cor0.col0 FROM tab0 cor0
----
-1680
-2450
-6230

query I rowsort
SELECT - tab2.col1 * + 17 + col1 AS col0 FROM tab2
----
-272
-496
-944

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 52 col2 FROM tab2 cor0
----
52
52
52

query I rowsort
SELECT 51 * - col0 AS col0 FROM tab2 AS cor0
----
-357
-3978
-4029

query I rowsort
SELECT DISTINCT + + col2 * 95 + - col0 FROM tab0 AS cor0
----
3111
60
7701

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1709
SELECT DISTINCT + col1 * col1 + CAST( cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
110
182
702

skipif mysql # not compatible
query I rowsort label-1709
SELECT DISTINCT + col1 * col1 + CAST ( cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL 92 + col2 FROM tab2 AS cor0
----
118
119
130

query I rowsort
SELECT DISTINCT + - 52 + col1 AS col0 FROM tab1 AS cor0
----
-26
-39
-42

onlyif mysql # use DIV operator for integer division
query I rowsort label-1712
SELECT + - col1 DIV col2 + 70 FROM tab1 AS cor0
----
70
70
70

skipif mysql # not compatible
query I rowsort label-1712
SELECT + - col1 / col2 + 70 FROM tab1 AS cor0
----
70
70
70

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

query I rowsort
SELECT - col1 + - col2 * 50 AS col2 FROM tab0 AS cor0
----
-147
-1736
-4191

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( - col1 ) * + 13 + + col0 col2 FROM tab1 AS cor0
----
194
249
341

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 * col2 + col2 col0 FROM tab2 AS cor0
----
17602
19710
54910

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

query I rowsort
SELECT + col0 + + 1 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT - col0 + col1 * + col2 * + col0 FROM tab1 AS cor0
----
36416
4209
99760

query I rowsort
SELECT DISTINCT + col0 * + 22 AS col0 FROM tab0 AS cor0
----
1958
528
770

onlyif mysql # use DIV operator for integer division
query I rowsort label-1721
SELECT ALL - + col2 DIV - ( + 25 ) + col1 AS col0 FROM tab1 AS cor0
----
12
16
28

skipif mysql # not compatible
query I rowsort label-1721
SELECT ALL - + col2 / - ( + 25 ) + col1 AS col0 FROM tab1 AS cor0
----
12
16
28

query I rowsort
SELECT + - col2 * ( 95 ) * col2 AS col0 FROM tab2 AS cor0
----
-137180
-64220
-69255

query I rowsort
SELECT DISTINCT + + cor0.col0 * - 99 + col0 FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT ALL ( col0 ) + 89 * + col0 + col1 AS col0 FROM tab1
----
296
5770
7213

onlyif mysql # use DIV operator for integer division
query I rowsort label-1725
SELECT col1 * + col0 + - col2 DIV - col0 FROM tab0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-1725
SELECT col1 * + col0 + - col2 / - col0 FROM tab0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort
SELECT col0 * + col1 + CAST ( - 40 AS REAL ) * col0 + - col0 FROM tab2
----
-1896
-70
1404

query I rowsort
SELECT + 21 * + col2 AS col0 FROM tab1
----
1134
1197
2016

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1728
SELECT col2 * col1 + - CAST( + col1 AS SIGNED ) + col0 FROM tab2
----
1553
708
813

skipif mysql # not compatible
query I rowsort label-1728
SELECT col2 * col1 + - CAST ( + col1 AS INTEGER ) + col0 FROM tab2
----
1553
708
813

query I rowsort
SELECT - col1 * - col1 * ( - cor0.col2 ) FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL - 27 * col2 * - ( col0 ) AS col2 FROM tab0 cor0
----
197046
21384
945

query I rowsort
SELECT ALL + ( col0 ) + 27 + - col1 FROM tab0 AS cor0
----
-35
-35
25

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 11 * col1 - col2 col1 FROM tab0 AS cor0
----
1066
913
919

onlyif mysql # use DIV operator for integer division
query I rowsort label-1734
SELECT - + col2 DIV 77 + - ( - col1 ) * col1 * col2 AS col0 FROM tab1 AS cor0
----
16223
36504
5700

skipif mysql # not compatible
query I rowsort label-1734
SELECT - + col2 / 77 + - ( - col1 ) * col1 * col2 AS col0 FROM tab1 AS cor0
----
16223
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-1735
SELECT - col0 + 64 DIV col0 AS col1 FROM tab0 AS cor0
----
-22
-34
-89

skipif mysql # not compatible
query I rowsort label-1735
SELECT - col0 + 64 / col0 AS col1 FROM tab0 AS cor0
----
-22
-34
-89

query I rowsort
SELECT ALL + col0 + - ( cor0.col1 ) * col1 AS col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT - + col2 + 27 * + cor0.col1 FROM tab1 AS cor0
----
213
255
648

query I rowsort
SELECT DISTINCT - col2 + 52 * col2 AS col1 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT + col2 * col0 + ( + col0 ) AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + + 78 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
78

query I rowsort
SELECT col1 + - 90 - col1 AS col1 FROM tab1 AS cor0
----
-90
-90
-90

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

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

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

query I rowsort
SELECT DISTINCT + cor0.col0 * ( + cor0.col1 * - 65 ) FROM tab2 AS cor0
----
-14105
-299130
-87295

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

query I rowsort
SELECT ALL 7 * tab0.col1 AS col2 FROM tab0
----
602
637
679

query I rowsort
SELECT DISTINCT - - 17 FROM tab0, tab1, tab2 cor0, tab2
----
17

query I rowsort
SELECT - col0 * col0 + - col2 AS col2 FROM tab1 AS cor0
----
-4153
-63
-6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-1749
SELECT - + col1 DIV + col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1749
SELECT - + col1 / + col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

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

skipif mysql # not compatible
query I rowsort label-1750
SELECT ( + col2 ) / - ( - col2 ) AS col0 FROM tab0 AS cor0
----
1
1
1

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1753
SELECT CAST ( NULL AS INTEGER ) / + 86 + + col1 col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 71 ) FROM tab1
----
-71
-71
-71

query I rowsort
SELECT - 59 + 30 * + tab0.col1 FROM tab0
----
2521
2671
2851

query I rowsort
SELECT 45 AS col2 FROM tab2 cor0
----
45
45
45

query I rowsort
SELECT DISTINCT + col0 + - col0 * col0 + col2 AS col0 FROM tab0 AS cor0
----
-1189
-519
-7750

query I rowsort
SELECT cor0.col2 + + ( col0 ) - - col1 AS col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL col1 + 20 + - col2 FROM tab2 AS cor0
----
-1
24
53

query I rowsort
SELECT + - 54 + + 92 * + col2 AS col2 FROM tab1 AS cor0
----
4914
5190
8778

query I rowsort
SELECT + 1 FROM tab1, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * col1 col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - col0 * + ( + 96 + col2 ) AS col2 FROM tab1
----
-15360
-450
-9792

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

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

query I rowsort
SELECT - 18 * - col0 AS col1 FROM tab0 cor0
----
1602
432
630

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

query I rowsort
SELECT cor0.col1 + cor0.col1 * - cor0.col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT + ( cor0.col1 ) * + col2 + - col0 * col2 AS col2 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT + col0 + + 8 AS col2 FROM tab2
----
15
86
87

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

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

query I rowsort
SELECT 1 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1774
SELECT cor0.col0 + + CAST( col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-1774
SELECT cor0.col0 + + CAST ( col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL 86 * cor0.col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c1ffe1d49dc434366f4e5a12cf3dd55a

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1778
SELECT ALL - CAST( 82 AS SIGNED ) * - col2 AS col1 FROM tab2 AS cor0
----
2132
2214
3116

skipif mysql # not compatible
query I rowsort label-1778
SELECT ALL - CAST ( 82 AS INTEGER ) * - col2 AS col1 FROM tab2 AS cor0
----
2132
2214
3116

onlyif mysql # use DIV operator for integer division
query I rowsort label-1779
SELECT - col0 * col1 DIV + col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-1779
SELECT - col0 * col1 / + col1 FROM tab2 AS cor0
----
-7
-78
-79

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 20 * - cor0.col1 col0 FROM tab0 AS cor0
----
1720
1820
1940

query I rowsort
SELECT ALL - col0 * 69 FROM tab1 cor0
----
-207
-4416
-5520

query I rowsort
SELECT - col0 * 71 FROM tab0 AS cor0
----
-1704
-2485
-6319

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

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

query I rowsort
SELECT ALL + - col1 + cor0.col0 * + col0 AS col2 FROM tab2 AS cor0
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) + - col1 col2 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 94 col0 FROM tab1 AS cor0
----
94
94
94

query I rowsort
SELECT ( 9 ) * cor0.col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
315
65682
7128

query I rowsort
SELECT + ( - 43 ) FROM tab1 cor0
----
-43
-43
-43

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

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 48 * + col2 FROM tab1
----
2592
2736
4608

query I rowsort
SELECT ALL 70 * + tab2.col0 AS col2 FROM tab2
----
490
5460
5530

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT DISTINCT - col2 * col0 - - col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + 52 + col2 FROM tab0 AS cor0
----
134
53
85

query I rowsort
SELECT 70 + - col0 FROM tab0 AS cor0
----
-19
35
46

query I rowsort
SELECT 3 * + 33 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

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

query I rowsort
SELECT - + col1 * + col1 + 50 FROM tab2 AS cor0
----
-239
-3431
-911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 55 col0 FROM tab0 AS cor0
----
144
79
90

query I rowsort
SELECT ALL col1 * ( - cor0.col2 ) + col0 - cor0.col2 FROM tab1 cor0
----
-1264
-1455
-563

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

skipif mysql # not compatible
query I rowsort label-1804
SELECT ALL - col0 + + CAST ( NULL AS INTEGER ) / col0 + + cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + 68 - 76 AS col0 FROM tab2 AS cor0
----
23
51
9

query I rowsort
SELECT + col0 + 99 FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT + - col1 + - col0 * + cor0.col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT - col1 * 47 + col0 * - col0 + - col0 FROM tab2 AS cor0
----
-1513
-7119
-8935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 27 col1 FROM tab2 AS cor0
----
-51
-52
20

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

query I rowsort
SELECT - cor0.col2 + - 35 FROM tab1 AS cor0
----
-131
-89
-92

query I rowsort
SELECT DISTINCT + col2 * col2 * + col2 + + col2 * 38 AS col1 FROM tab0 AS cor0
----
37191
39
554484

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

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab0 cor0, tab2 cor1
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT DISTINCT 83 + + col2 + col1 * col2 FROM tab0
----
181
2954
7627

query I rowsort
SELECT DISTINCT col0 * col1 + 0 AS col2 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1817
SELECT col2 + col1 DIV + col1 AS col0 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1817
SELECT col2 + col1 / + col1 AS col0 FROM tab1
----
55
58
97

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

query I rowsort
SELECT DISTINCT 8 * - col2 + - col1 + col2 AS col2 FROM tab0
----
-104
-317
-665

query I rowsort
SELECT col1 + col1 + tab1.col2 FROM tab1
----
106
122
77

query I rowsort
SELECT ALL 0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - col0 * ( 99 ) + col1 AS col0 FROM tab2 AS cor0
----
-662
-7663
-7804

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1823
SELECT DISTINCT - col0 + CAST( - 24 AS SIGNED ) col2 FROM tab0 AS cor0
----
-113
-48
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1823
SELECT DISTINCT - col0 + CAST ( - 24 AS INTEGER ) col2 FROM tab0 AS cor0
----
-113
-48
-59

query I rowsort
SELECT - cor0.col0 * col2 + col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - col1 * + ( cor0.col0 ) * + col2 + col1 FROM tab0 AS cor0
----
-3298
-664027
-68026

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

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

query I rowsort
SELECT + - col2 * col1 - + ( - col2 ) FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1829
SELECT DISTINCT + + col2 - + col1 DIV 4 FROM tab1 cor0
----
48
55
93

skipif mysql # not compatible
query I rowsort label-1829
SELECT DISTINCT + + col2 - + col1 / 4 FROM tab1 cor0
----
48
55
93

query I rowsort
SELECT ALL col2 - + col1 * + col1 * tab0.col0 FROM tab0
----
-177471
-329314
-736927

query I rowsort
SELECT - 7 * + col0 FROM tab1 AS cor0
----
-21
-448
-560

query I rowsort
SELECT ALL - 17 * - col1 AS col0 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT ALL - ( - col0 ) * ( col0 ) FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1834
SELECT + 5 + col1 DIV + col0 + + ( col0 ) FROM tab1
----
16
69
85

skipif mysql # not compatible
query I rowsort label-1834
SELECT + 5 + col1 / + col0 + + ( col0 ) FROM tab1
----
16
69
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1835
SELECT - cor0.col1 DIV 64 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1835
SELECT - cor0.col1 / 64 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - 27 + - col2 + + col2 AS col0 FROM tab0 AS cor0
----
-27
-27
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1837
SELECT DISTINCT - + col0 DIV + col0 + - col1 * - 43 + col2 FROM tab1 cor0
----
1171
486
654

skipif mysql # not compatible
query I rowsort label-1837
SELECT DISTINCT - + col0 / + col0 + - col1 * - 43 + col2 FROM tab1 cor0
----
1171
486
654

query I rowsort
SELECT - 44 - col2 FROM tab1 AS cor0
----
-101
-140
-98

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-1840
SELECT - + 42 DIV + col0 + + ( cor0.col1 ) + col0 FROM tab0 AS cor0
----
109
131
180

skipif mysql # not compatible
query I rowsort label-1840
SELECT - + 42 / + col0 + + ( cor0.col1 ) + col0 FROM tab0 AS cor0
----
109
131
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-1841
SELECT DISTINCT - 20 DIV + col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1841
SELECT DISTINCT - 20 / + col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + ( col1 ) + - 25 * + 56 + + cor0.col2 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1536
-5038
-9067

query I rowsort
SELECT DISTINCT + + 84 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
84

query I rowsort
SELECT - col1 * + ( + tab0.col0 ) + + col2 AS col2 FROM tab0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * - cor0.col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 23 + tab0.col2 FROM tab0, tab0 AS cor0
----
105
24
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 35 col2 FROM tab1 cor0
----
-1890
-1995
-3360

query I rowsort
SELECT DISTINCT cor1.col0 * + tab2.col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
49
546
553
6084
6162
6241

query I rowsort
SELECT ALL - col1 + + 23 FROM tab1 cor0
----
-3
10
13

query I rowsort
SELECT ALL 92 AS col1 FROM tab1
----
92
92
92

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

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

query I rowsort
SELECT DISTINCT cor0.col1 + - 87 * 43 FROM tab1, tab0 cor0
----
-3644
-3650
-3655

query I rowsort
SELECT + tab2.col1 * 65 FROM tab2, tab1 cor0
----
9 values hashing to 39013cbc2b01c7afe2a236f2b862e670

query I rowsort
SELECT + 21 * col2 + 4 FROM tab0 AS cor0
----
1726
25
697

query I rowsort
SELECT ALL + 54 + - col0 * col0 FROM tab2 AS cor0
----
-6030
-6187
5

query I rowsort
SELECT ALL 25 * + col2 FROM tab2 cor0
----
650
675
950

query I rowsort
SELECT DISTINCT + 15 FROM tab1 cor0
----
15

query I rowsort
SELECT DISTINCT - 88 + col2 AS col0 FROM tab2 AS cor0
----
-50
-61
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1859
SELECT DISTINCT ( + col2 ) + 11 * + col2 + cor0.col1 DIV col2 AS col0 FROM tab0 cor0
----
109
398
985

skipif mysql # not compatible
query I rowsort label-1859
SELECT DISTINCT ( + col2 ) + 11 * + col2 + cor0.col1 / col2 AS col0 FROM tab0 cor0
----
109
398
985

query I rowsort
SELECT ALL - 71 * col0 + + ( - 18 * + col2 ) FROM tab0 AS cor0
----
-2298
-2503
-7795

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

query I rowsort
SELECT ALL - cor0.col1 + + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT + col1 + + col2 * - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

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

skipif mysql # not compatible
query I rowsort label-1864
SELECT + col2 / ( col1 ) AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - cor0.col2 * col2 + 12 AS col2 FROM tab1 AS cor0
----
2928
3261
9228

query I rowsort
SELECT + + col0 + 74 * 49 AS col0 FROM tab0 cor0
----
3650
3661
3715

query I rowsort
SELECT DISTINCT - + col2 * - col1 * col2 FROM tab0 AS cor0
----
611884
93654
97

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

skipif mysql # not compatible
query I rowsort label-1868
SELECT ALL col2 * + col1 / + col1 AS col1 FROM tab0 AS cor0
----
1
33
82

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

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

query I rowsort
SELECT + 8 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT ( tab0.col0 * tab0.col0 ) + col2 AS col0 FROM tab0
----
1226
609
8003

query I rowsort
SELECT cor0.col0 + ( + col0 ) AS col2 FROM tab2 cor0
----
14
156
158

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

query I rowsort
SELECT 83 AS col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

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

query I rowsort
SELECT 50 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to b834e2084022ca341153dd05ef833c6b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1878
SELECT DISTINCT + + 16 DIV 4 + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
4
7

skipif mysql # not compatible
query I rowsort label-1878
SELECT DISTINCT + + 16 / 4 + col2 / col0 AS col0 FROM tab2 AS cor0
----
4
7

query I rowsort
SELECT ALL + ( col2 ) * + col0 + + 8 AS col1 FROM tab0 AS cor0
----
43
7306
800

query I rowsort
SELECT col1 + 17 * + col2 * - col0 AS col1 FROM tab2
----
-3182
-34417
-51017

query I rowsort
SELECT ALL col2 + 21 AS col0 FROM tab2 AS cor0
----
47
48
59

query I rowsort
SELECT ALL 9 FROM tab0, tab2 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

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

skipif mysql # not compatible
query I rowsort label-1883
SELECT + CAST ( col2 AS INTEGER ) * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + 33 FROM tab1, tab2 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT - + col0 * - col0 - col1 AS col1 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT - + 64 FROM tab1 AS cor0
----
-64
-64
-64

query I rowsort
SELECT + cor0.col2 + cor0.col1 * - ( - col1 * col2 ) AS col1 FROM tab1 AS cor0
----
16320
36558
5757

query I rowsort
SELECT cor0.col0 * + col1 + + ( - col2 ) FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - 79 * - col1 - - ( 13 ) FROM tab2 AS cor0
----
1356
2462
4674

onlyif mysql # use DIV operator for integer division
query I rowsort label-1890
SELECT + 33 DIV 69 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1890
SELECT + 33 / 69 AS col0 FROM tab2
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1891
SELECT ALL ( col1 ) * - col0 + - CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * col1 + 28 AS col2 FROM tab1 AS cor0
----
128
197
704

onlyif mysql # use DIV operator for integer division
query I rowsort label-1893
SELECT DISTINCT - cor0.col0 * + col1 + - col2 DIV col1 FROM tab2 AS cor0
----
-1345
-217
-4602

skipif mysql # not compatible
query I rowsort label-1893
SELECT DISTINCT - cor0.col0 * + col1 + - col2 / col1 FROM tab2 AS cor0
----
-1345
-217
-4602

query I rowsort
SELECT DISTINCT - - col2 * col0 + + 35 AS col2 FROM tab2 AS cor0
----
2063
224
3037

query I rowsort
SELECT 76 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1896
SELECT ALL + col0 + 29 + tab0.col0 * CAST( - col0 AS SIGNED ) DIV col0 col2 FROM tab0
----
29
29
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1896
SELECT ALL + col0 + 29 + tab0.col0 * CAST ( - col0 AS INTEGER ) / col0 col2 FROM tab0
----
29
29
29

query I rowsort
SELECT 41 - tab1.col2 AS col0 FROM tab1
----
-13
-16
-55

query I rowsort
SELECT ALL 99 * col1 * col1 + + 22 * + 89 FROM tab0
----
734162
821777
933449

query I rowsort
SELECT DISTINCT tab2.col2 + 79 - 70 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
35
36
47

query I rowsort
SELECT 62 * + col0 FROM tab0
----
1488
2170
5518

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

query I rowsort
SELECT ALL + col2 * col0 + col0 AS col2 FROM tab0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1903
SELECT ALL + col1 DIV + col1 + + col1 + ( ( col0 ) ) * ( tab1.col1 * tab1.col1 + + ( col2 ) ) FROM tab1
----
10059
21214
2217

skipif mysql # not compatible
query I rowsort label-1903
SELECT ALL + col1 / + col1 + + col1 + ( ( col0 ) ) * ( tab1.col1 * tab1.col1 + + ( col2 ) ) FROM tab1
----
10059
21214
2217

query I rowsort
SELECT - cor0.col1 * col1 * - 71 AS col1 FROM tab1 AS cor0
----
11999
47996
7100

query I rowsort
SELECT DISTINCT - - 93 * - col2 + + col2 FROM tab1 AS cor0
----
-4968
-5244
-8832

query I rowsort
SELECT ALL 12 * col2 FROM tab1 AS cor0
----
1152
648
684

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

query I rowsort
SELECT - - 33 AS col0 FROM tab0 cor0
----
33
33
33

query I rowsort
SELECT ALL - 76 * - col1 - + col1 AS col2 FROM tab1 cor0
----
1950
750
975

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 66 * - col0 col0 FROM tab1 AS cor0
----
198
4224
5280

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

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

query I rowsort
SELECT - - 59 + col2 * - col2 FROM tab1 AS cor0
----
-2857
-3190
-9157

query I rowsort
SELECT - + col1 + col2 * col1 * 92 FROM tab1 cor0
----
114803
129142
52430

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1916
SELECT + col2 * - CAST( NULL AS SIGNED ) - + col2 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-1916
SELECT + col2 * - CAST ( NULL AS INTEGER ) - + col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

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

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

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

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

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

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

query I rowsort
SELECT + cor0.col1 + 33 AS col0 FROM tab0 AS cor0
----
119
124
130

onlyif mysql # use DIV operator for integer division
query I rowsort label-1922
SELECT + col2 DIV col0 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1534
646
840

skipif mysql # not compatible
query I rowsort label-1922
SELECT + col2 / col0 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1534
646
840

query I rowsort
SELECT - col1 - 97 FROM tab2 AS cor0
----
-114
-128
-156

query I rowsort
SELECT DISTINCT + + col1 * col1 + - col2 FROM tab0 AS cor0
----
7363
8199
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-1925
SELECT - col1 DIV col1 + + col0 AS col2 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-1925
SELECT - col1 / col1 + + col0 AS col2 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT + 3 + - col0 AS col0 FROM tab1 AS cor0
----
-61
-77
0

query I rowsort
SELECT ALL + + ( - cor0.col0 ) * col2 + + col2 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-1928
SELECT ALL col1 DIV col0 AS col2 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1928
SELECT ALL col1 / col0 AS col2 FROM tab0 cor0
----
1
2
3

query I rowsort
SELECT - 11 * col1 + cor0.col2 * col0 FROM tab1 AS cor0
----
-124
3538
7537

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

query I rowsort
SELECT 67 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT - ( col1 ) - cor0.col1 AS col1 FROM tab1 AS cor0
----
-20
-26
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-1933
SELECT ALL 77 DIV - col1 + col0 FROM tab2 AS cor0
----
5
75
77

skipif mysql # not compatible
query I rowsort label-1933
SELECT ALL 77 / - col1 + col0 FROM tab2 AS cor0
----
5
75
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1934
SELECT DISTINCT + CAST( col2 AS SIGNED ) + - col1 FROM tab2 AS cor0
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-1934
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + - col1 FROM tab2 AS cor0
----
-33
-4
21

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

skipif mysql # not compatible
query I rowsort label-1935
SELECT DISTINCT col0 / + 62 AS col1 FROM tab2 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - + 21 - col1 * + col0 FROM tab0 AS cor0
----
-2085
-3416
-8120

onlyif mysql # use DIV operator for integer division
query I rowsort label-1937
SELECT + - col1 + col2 DIV - col1 FROM tab2 cor0
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-1937
SELECT + - col1 + col2 / - col1 FROM tab2 cor0
----
-19
-31
-59

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 57 * - ( + cor0.col1 * + col1 ) col2 FROM tab2 AS cor0
----
16473
198417
54777

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

query I rowsort
SELECT ALL + col2 * 49 + col2 AS col1 FROM tab2 AS cor0
----
1300
1350
1900

query I rowsort
SELECT ALL + - 84 + + col0 * - col1 FROM tab2 AS cor0
----
-1427
-301
-4686

query I rowsort
SELECT + col2 * 21 - col2 FROM tab2 AS cor0
----
520
540
760

query I rowsort
SELECT DISTINCT + col0 * 89 + col0 * ( + col2 ) * col2 AS col2 FROM tab1 AS cor0
----
213632
744400
9015

query I rowsort
SELECT DISTINCT col1 - + ( 91 * col1 ) FROM tab1
----
-1170
-2340
-900

onlyif mysql # use DIV operator for integer division
query I rowsort label-1947
SELECT ALL col1 - + col0 DIV + col1 FROM tab1
----
26
4
7

skipif mysql # not compatible
query I rowsort label-1947
SELECT ALL col1 - + col0 / + col1 FROM tab1
----
26
4
7

query I rowsort
SELECT - tab1.col2 + col1 + tab1.col1 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT + col0 * 47 AS col2 FROM tab0
----
1128
1645
4183

query I rowsort
SELECT DISTINCT + col1 - - col0 * col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT col0 + - 35 FROM tab2 AS cor0
----
-28
43
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-1952
SELECT ALL - 74 + col2 DIV - col2 FROM tab1 cor0
----
-75
-75
-75

skipif mysql # not compatible
query I rowsort label-1952
SELECT ALL - 74 + col2 / - col2 FROM tab1 cor0
----
-75
-75
-75

query I rowsort
SELECT DISTINCT + col2 * ( cor0.col2 ) + + cor0.col1 AS col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT - - col1 + + col0 * + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + 63 - - col0 * cor0.col1 FROM tab2 AS cor0
----
1406
280
4665

query I rowsort
SELECT + - cor0.col0 * + 38 + col0 AS col2 FROM tab1 AS cor0
----
-111
-2368
-2960

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

query I rowsort
SELECT ALL - ( + cor0.col0 ) * + col2 + - col1 FROM tab0 AS cor0
----
-132
-7389
-878

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 + col2 * 13 col0 FROM tab0 AS cor0
----
1075
22
438

query I rowsort
SELECT - 48 AS col2 FROM tab2 cor0
----
-48
-48
-48

query I rowsort
SELECT DISTINCT - col1 * + col1 + - col2 + + tab1.col2 * + 39 * + col2 AS col0 FROM tab1
----
112994
126554
359159

query I rowsort
SELECT ALL + ( col1 ) + col0 * 48 * - col2 FROM tab2
----
-144079
-9041
-97285

query I rowsort
SELECT DISTINCT + col2 + + col1 * - 73 AS col2 FROM tab0 AS cor0
----
-6245
-6561
-7080

query I rowsort
SELECT ALL col1 + - col2 + ( col1 ) FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT DISTINCT + 38 AS col1 FROM tab1, tab2 AS cor0
----
38

query I rowsort
SELECT DISTINCT - col1 - - tab2.col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT col1 - 83 AS col1 FROM tab0
----
14
3
8

query I rowsort
SELECT ALL col2 - + tab2.col2 * col0 FROM tab2
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-1970
SELECT - col2 DIV + col0 + + tab1.col1 AS col2 FROM tab1
----
10
12
8

skipif mysql # not compatible
query I rowsort label-1970
SELECT - col2 / + col0 + + tab1.col1 AS col2 FROM tab1
----
10
12
8

query I rowsort
SELECT DISTINCT + col0 - - col0 * ( - col0 ) FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT ALL - col1 * ( - 30 ) FROM tab2
----
1770
510
930

query I rowsort
SELECT 81 + + col2 * - col0 FROM tab2 AS cor0
----
-108
-1947
-2921

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

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

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

query I rowsort
SELECT ALL ( - 18 + col2 ) FROM tab0
----
-17
15
64

query I rowsort
SELECT - ( cor0.col1 ) + + col0 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 1 col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( cor0.col2 ) * + cor0.col0 + + col2 col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + 32 * - col0 AS col0 FROM tab0 AS cor0
----
-1120
-2848
-768

query I rowsort
SELECT ALL 36 * + col2 AS col0 FROM tab1
----
1944
2052
3456

query I rowsort
SELECT - - col1 * col2 AS col0 FROM tab2 cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-1984
SELECT DISTINCT + col2 DIV col1 AS col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1984
SELECT DISTINCT + col2 / col1 AS col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + col2 * col2 + col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT - col2 * - 70 + 83 FROM tab1
----
3863
4073
6803

query I rowsort
SELECT col2 * + ( - col2 + - col2 ) * - col2 FROM tab1
----
1769472
314928
370386

query I rowsort
SELECT - col2 * 37 AS col1 FROM tab0
----
-1221
-3034
-37

query I rowsort
SELECT col2 * - col1 * - tab2.col2 AS col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT 39 * - tab0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 3c9fb06536a5ea37f7497a6a4dc0b1a3

query I rowsort
SELECT - 10 + col2 * cor0.col2 FROM tab2 AS cor0
----
1434
666
719

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

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

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

query I rowsort
SELECT - 98 * 94 + - col2 FROM tab0 AS cor0
----
-9213
-9245
-9294

query I rowsort
SELECT + 60 + + col0 * col2 AS col2 FROM tab1 cor0
----
222
3708
7740

onlyif mysql # use DIV operator for integer division
query I rowsort label-1997
SELECT DISTINCT col2 + - col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-1997
SELECT DISTINCT col2 + - col2 / - col2 AS col0 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1998
SELECT + col1 + - cor0.col2 + + cor0.col2 DIV + cor0.col1 FROM tab2 AS cor0
----
-19
33
4

skipif mysql # not compatible
query I rowsort label-1998
SELECT + col1 + - cor0.col2 + + cor0.col2 / + cor0.col1 FROM tab2 AS cor0
----
-19
33
4

query I rowsort
SELECT - col0 * col2 * - col1 - - col2 FROM tab0 AS cor0
----
3396
664200
68145

query III rowsort
SELECT * FROM tab1 WHERE col2 * - col2 + col1 < col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT cor0.col0 + cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 0a9ba7ddbb78279db2d78308414e03c9

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT ( NULL ) < cor0.col1
----

query I rowsort
SELECT - col2 * col2 - col1 * - tab1.col0 FROM tab1 WHERE NOT NULL IN ( col0 / + col0 + tab1.col2 * + col2 )
----

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

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( + col2 * + col0 )
----

query I rowsort
SELECT DISTINCT + col0 * + col0 + col2 FROM tab1
----
4153
63
6496

query I rowsort
SELECT col0 * col2 * - tab2.col0 AS col0 FROM tab2 WHERE col1 + col0 IN ( + col1 )
----

query I rowsort
SELECT col1 * - col0 + col0 + col0 FROM tab1 cor0
----
-512
-72
-880

query I rowsort
SELECT DISTINCT + col2 * col1 * - col0 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-2010
SELECT - col0 * col2 DIV col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2010
SELECT - col0 * col2 / col0 FROM tab1 AS cor0
----
-54
-57
-96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2012
SELECT - col2 DIV - cor0.col1 + - col0 FROM tab1 AS cor0
----
-1
-59
-73

skipif mysql # not compatible
query I rowsort label-2012
SELECT - col2 / - cor0.col1 + - col0 FROM tab1 AS cor0
----
-1
-59
-73

query I rowsort
SELECT + col2 + - col2 + col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - cor0.col1 * + col1 * col2 + col2 FROM tab1 AS cor0
----
-16128
-36450
-5643

onlyif mysql # use DIV operator for integer division
query I rowsort label-2015
SELECT - col0 DIV - col1 col2 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2015
SELECT - col0 / - col1 col2 FROM tab2
----
0
1
4

query I rowsort
SELECT - - col1 - col0 * + cor0.col1 FROM tab1 cor0
----
-1027
-52
-630

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

query I rowsort
SELECT DISTINCT - - col2 * + col0 AS col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT col1 - 31 AS col1 FROM tab1 AS cor0
----
-18
-21
-5

query I rowsort
SELECT + col2 * col2 * col2 + col1 FROM tab2 AS cor0
----
17635
19714
54889

onlyif mysql # use DIV operator for integer division
query I rowsort label-2021
SELECT DISTINCT - col1 + + 92 DIV - col1 AS col1 FROM tab2 AS cor0
----
-22
-33
-60

skipif mysql # not compatible
query I rowsort label-2021
SELECT DISTINCT - col1 + + 92 / - col1 AS col1 FROM tab2 AS cor0
----
-22
-33
-60

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

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

query I rowsort
SELECT ALL + cor0.col0 * col1 + + 84 AS col2 FROM tab1 AS cor0
----
1124
162
724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2025
SELECT cor0.col0 * + 49 + col0 DIV col1 FROM tab0 AS cor0
----
1176
1715
4361

skipif mysql # not compatible
query I rowsort label-2025
SELECT cor0.col0 * + 49 + col0 / col1 FROM tab0 AS cor0
----
1176
1715
4361

query I rowsort
SELECT DISTINCT - cor0.col2 * - col2 - - cor0.col1 * + col2 * + col2 AS col2 FROM tab0 AS cor0
----
618608
94743
98

query I rowsort
SELECT DISTINCT 0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
0

query I rowsort
SELECT - tab0.col2 - col1 AS col0 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT tab1.col2 + - 58 * col2 FROM tab1
----
-3078
-3249
-5472

query I rowsort
SELECT ALL - col0 * + ( + col1 ) + col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT col1 + 26 + col1 FROM tab1
----
46
52
78

query I rowsort
SELECT col2 * col0 + 14 AS col2 FROM tab0
----
49
7312
806

query I rowsort
SELECT col0 * + col2 + + 73 FROM tab0 AS cor0
----
108
7371
865

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

query I rowsort
SELECT ALL + col2 * col1 + 11 AS col0 FROM tab0
----
108
2849
7473

query I rowsort
SELECT ALL - col2 * - col2 * col1 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT ALL + 38 FROM tab1, tab0, tab0 cor0
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT ALL + cor0.col0 - - col1 * - 79 AS col1 FROM tab2 AS cor0
----
-1264
-2442
-4583

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 14 col1 FROM tab2 AS cor0
----
14

query I rowsort
SELECT DISTINCT + col1 * col1 + col2 * + col2 * col0 FROM tab2 AS cor0
----
114365
56209
6064

onlyif mysql # use DIV operator for integer division
query I rowsort label-2041
SELECT ALL + cor0.col2 * col2 + col0 * cor0.col0 DIV + col0 - col1 AS col0 FROM tab0 AS cor0
----
-61
1027
6722

skipif mysql # not compatible
query I rowsort label-2041
SELECT ALL + cor0.col2 * col2 + col0 * cor0.col0 / + col0 - col1 AS col0 FROM tab0 AS cor0
----
-61
1027
6722

query I rowsort
SELECT ALL 42 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2045
SELECT col1 DIV + col1 col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2045
SELECT col1 / + col1 col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ( - tab2.col2 ) - - col1 FROM tab2
----
-21
33
4

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2048
SELECT ALL 87 DIV cor0.col2 + - tab0.col1 DIV - tab0.col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 42374441ccf6b5fda32e4e4df1c2d793

skipif mysql # not compatible
query I rowsort label-2048
SELECT ALL 87 / cor0.col2 + - tab0.col1 / - tab0.col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 42374441ccf6b5fda32e4e4df1c2d793

onlyif mysql # use DIV operator for integer division
query I rowsort label-2049
SELECT DISTINCT - 30 DIV col0 AS col0 FROM tab0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2049
SELECT DISTINCT - 30 / col0 AS col0 FROM tab0
----
-1
0

query I rowsort
SELECT + + 52 - col0 AS col0 FROM tab2 AS cor0
----
-26
-27
45

query I rowsort
SELECT ALL col0 - col0 AS col0 FROM tab2
----
0
0
0

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

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 AS col0 FROM tab1 cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2054
SELECT ALL + col0 DIV cor0.col0 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-2054
SELECT ALL + col0 / cor0.col0 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

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

query I rowsort
SELECT - - 41 AS col0 FROM tab2 AS cor0
----
41
41
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * col0 col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT 22 + + tab2.col1 FROM tab2
----
39
53
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + tab1.col1 col2 FROM tab1
----
20
26
52

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

skipif mysql # not compatible
query I rowsort label-2060
SELECT DISTINCT + 10 + - col0 / col1 AS col0 FROM tab1 AS cor0
----
10
4

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

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

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

query I rowsort
SELECT + + col2 * 80 - col0 FROM tab1 AS cor0
----
4317
4496
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + 92 col1 FROM tab2 AS cor0
----
109
123
151

query I rowsort
SELECT ALL + ( + 74 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT DISTINCT + col1 * 14 + - col0 FROM tab1 AS cor0
----
102
361
76

query I rowsort
SELECT col0 + ( col2 * - col2 ) AS col1 FROM tab2 AS cor0
----
-1365
-598
-722

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

query I rowsort
SELECT ALL + cor0.col1 * 32 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT - + col1 * + 12 + + col2 AS col0 FROM tab2 AS cor0
----
-166
-345
-682

query I rowsort
SELECT col1 * + col0 - + col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT + + 92 + col2 * + col1 FROM tab1 cor0
----
1340
1496
662

query I rowsort
SELECT DISTINCT + ( col1 ) + cor0.col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT DISTINCT ( 70 ) * - col0 + col0 * col0 AS col2 FROM tab0 cor0
----
-1104
-1225
1691

query I rowsort
SELECT col2 + + col2 * col2 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT - ( 41 ) + col2 FROM tab0 AS cor0
----
-40
-8
41

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

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

query I rowsort
SELECT ALL - + ( col1 ) + - col2 * - col0 * col2 AS col0 FROM tab0 AS cor0
----
-62
26050
598345

query I rowsort
SELECT ALL - ( + cor0.col2 ) + + cor0.col0 * col1 * + col0 + col0 FROM tab1 AS cor0
----
183
40967
83184

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * + col0 - col2 col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT + - 67 * - col0 FROM tab0 AS cor0
----
1608
2345
5963

onlyif mysql # use DIV operator for integer division
query I rowsort label-2082
SELECT + col0 DIV + col0 + col1 col0 FROM tab0 AS cor0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2082
SELECT + col0 / + col0 + col1 col0 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT DISTINCT - col2 + + 46 AS col0 FROM tab2 AS cor0
----
19
20
8

query I rowsort
SELECT ALL 15 * col1 + + col0 FROM tab0 AS cor0
----
1314
1454
1490

query I rowsort
SELECT ALL - col2 * + 90 * + col1 + - 7 FROM tab1 AS cor0
----
-112327
-126367
-51307

query I rowsort
SELECT ALL tab1.col2 * + 13 FROM tab1
----
1248
702
741

query I rowsort
SELECT + 27 * col0 + col0 FROM tab0
----
2492
672
980

query I rowsort
SELECT DISTINCT + - 69 * + col2 AS col0 FROM tab2 AS cor0
----
-1794
-1863
-2622

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 + - col1 ) * col0 * 49 col1 FROM tab2
----
-8232
240002
72618

query I rowsort
SELECT ( tab0.col2 ) - + col2 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2091
SELECT DISTINCT CAST( col0 + col1 AS SIGNED ) * col0 DIV 53 FROM tab0
----
302
49
87

skipif mysql # not compatible
query I rowsort label-2091
SELECT DISTINCT CAST ( col0 + col1 AS INTEGER ) * col0 / 53 FROM tab0
----
302
49
87

query I rowsort
SELECT 69 * - col0 FROM tab2 cor0
----
-483
-5382
-5451

query I rowsort
SELECT DISTINCT + + ( col0 ) * + col1 + - ( ( col1 ) ) * col1 FROM tab0 AS cor0
----
-182
-5332
-6014

onlyif mysql # use DIV operator for integer division
query I rowsort label-2094
SELECT - col2 * col2 + col2 DIV - ( + col2 * - col0 ) FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-2094
SELECT - col2 * col2 + col2 / - ( + col2 * - col0 ) FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2095
SELECT DISTINCT col2 DIV - ( + cor0.col0 + - ( - cor0.col2 ) * - col0 ) FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2095
SELECT DISTINCT col2 / - ( + cor0.col0 + - ( - cor0.col2 ) * - col0 ) FROM tab2 AS cor0
----
0

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0 CROSS JOIN tab1, tab0 cor1
----
972 values hashing to 5342fb4caf4767cb98bd21989bad099f

query I rowsort
SELECT 59 - + col2 FROM tab0 AS cor0
----
-23
26
58

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

skipif mysql # not compatible
query I rowsort label-2098
SELECT + col2 / - 87 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 29 + + col1 * - col0 col2 FROM tab2 cor0
----
-1314
-188
-4573

query I rowsort
SELECT ALL + - col2 + 29 AS col2 FROM tab0 cor0
----
-4
-53
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-2101
SELECT ( + col1 ) DIV + col1 + 26 * - col0 * cor0.col2 AS col1 FROM tab1 cor0
----
-199679
-4211
-94847

skipif mysql # not compatible
query I rowsort label-2101
SELECT ( + col1 ) / + col1 + 26 * - col0 * cor0.col2 AS col1 FROM tab1 cor0
----
-199679
-4211
-94847

query I rowsort
SELECT + + 15 + col0 FROM tab0 AS cor0
----
104
39
50

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

query I rowsort
SELECT - cor0.col0 - - 13 FROM tab0, tab0 AS cor0
----
9 values hashing to 2c761353bdd9a18d81c38d588fbeac11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 * 93 col1 FROM tab2 AS cor0
----
-26877
-323733
-89373

query I rowsort
SELECT DISTINCT - 60 * tab0.col1 * col1 AS col1 FROM tab0
----
-443760
-496860
-564540

query I rowsort
SELECT ALL + 79 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT ALL 55 AS col0 FROM tab1, tab0 cor0, tab2 cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

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

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

query I rowsort
SELECT col0 + col1 * + col1 FROM tab2
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 22 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2112
SELECT ( cor0.col2 ) + col2 DIV - 58 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-2112
SELECT ( cor0.col2 ) + col2 / - 58 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT ALL + col1 * + 88 + col2 AS col0 FROM tab2
----
1534
2755
5218

query I rowsort
SELECT ALL col1 * - col0 + ( col2 ) AS col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT col2 * 63 FROM tab2
----
1638
1701
2394

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

query I rowsort
SELECT ALL - - col1 * 91 + + col2 * ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
1480
2431
3770

onlyif mysql # use DIV operator for integer division
query I rowsort label-2118
SELECT DISTINCT col0 * 79 DIV col1 AS col0 FROM tab0
----
22
28
77

skipif mysql # not compatible
query I rowsort label-2118
SELECT DISTINCT col0 * 79 / col1 AS col0 FROM tab0
----
22
28
77

query I rowsort
SELECT - - 68 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT - 80 * tab2.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 50a87395c2d2ece4bf3018913d183a9c

query I rowsort
SELECT 93 * - col0 - - col0 FROM tab2
----
-644
-7176
-7268

query I rowsort
SELECT DISTINCT ( ( + col0 ) * 15 ) - 29 AS col0 FROM tab0
----
1306
331
496

query I rowsort
SELECT 38 * col1 FROM tab2
----
1178
2242
646

query I rowsort
SELECT col1 * + col1 + + cor0.col1 * - 48 FROM tab0 AS cor0
----
3268
3913
4753

query I rowsort
SELECT + ( col1 ) * + col0 + col1 * + col2 AS col0 FROM tab2 cor0
----
1054
1989
6136

query I rowsort
SELECT - 10 * col1 + - col1 FROM tab1 AS cor0
----
-110
-143
-286

query I rowsort
SELECT + cor0.col1 + 51 AS col2 FROM tab0 AS cor0
----
137
142
148

query I rowsort
SELECT DISTINCT - 70 * col2 FROM tab0
----
-2310
-5740
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2129
SELECT + CAST( NULL AS SIGNED ) FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2129
SELECT + CAST ( NULL AS INTEGER ) FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT 73 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
73

query I rowsort
SELECT ALL ( + col1 ) * cor0.col2 + col0 FROM tab0 cor0
----
132
2862
7551

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

query I rowsort
SELECT ALL - col0 * col1 * - 3 AS col0 FROM tab0
----
10185
24297
6192

query I rowsort
SELECT col1 * 43 FROM tab1 AS cor0
----
1118
430
559

query I rowsort
SELECT - col2 * 73 AS col0 FROM tab1 AS cor0
----
-3942
-4161
-7008

query I rowsort
SELECT DISTINCT - 44 + + col0 * - 39 + - ( col0 ) FROM tab2 AS cor0
----
-3164
-3204
-324

query I rowsort
SELECT + tab1.col1 + col1 * + col0 + + tab1.col2 FROM tab1
----
1149
158
707

query I rowsort
SELECT DISTINCT col0 + col2 + col1 FROM tab1
----
131
189
83

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

query I rowsort
SELECT ALL + 57 * col0 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT ALL - + 98 + - col1 FROM tab1 AS cor0
----
-108
-111
-124

query I rowsort
SELECT ALL + - 61 + + col0 AS col0 FROM tab2 AS cor0
----
-54
17
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2143
SELECT + cor0.col2 DIV - cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-2143
SELECT + cor0.col2 / - cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - col2 * col0 + 96 + + 11 FROM tab1 AS cor0
----
-3541
-55
-7573

query I rowsort
SELECT DISTINCT col2 + + 82 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
139
203
258

skipif mysql # not compatible
query I rowsort
SELECT 98 * - tab2.col1 / - CAST ( + col1 AS REAL ) AS col0 FROM tab2
----
98
98
98

query I rowsort
SELECT ALL 70 * col0 FROM tab0
----
1680
2450
6230

query I rowsort
SELECT DISTINCT col1 - col0 * - 25 AS col0 FROM tab1
----
101
1610
2013

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2149
SELECT DISTINCT - 25 - + col1 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2149
SELECT DISTINCT - 25 - + col1 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

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

skipif mysql # not compatible
query I rowsort label-2150
SELECT ALL - - col1 + + CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT col2 + col0 + 98 * - col1 AS col0 FROM tab0 AS cor0
----
-8371
-8747
-9470

query I rowsort
SELECT - col1 * col1 + col2 - col2 * - 81 AS col1 FROM tab2 AS cor0
----
-1349
1253
2827

query I rowsort
SELECT DISTINCT col2 * col2 - tab0.col2 AS col2 FROM tab0
----
0
1056
6642

query I rowsort
SELECT col0 - col1 * 1 * + 34 AS col0 FROM tab1
----
-276
-362
-881

query I rowsort
SELECT ALL + col0 * col2 + tab1.col2 * - col2 FROM tab1
----
-1536
-2754
399

onlyif mysql # use DIV operator for integer division
query I rowsort label-2156
SELECT ALL col2 * - col0 + col2 DIV - col0 AS col1 FROM tab2
----
-192
-2028
-3002

skipif mysql # not compatible
query I rowsort label-2156
SELECT ALL col2 * - col0 + col2 / - col0 AS col1 FROM tab2
----
-192
-2028
-3002

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) < col2
----

query I rowsort
SELECT - col2 * - col2 + col0 AS col1 FROM tab2
----
1523
736
754

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

query I rowsort
SELECT DISTINCT - col0 * + col1 + + col1 AS col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT tab0.col0 * + col2 - col0 AS col2 FROM tab0
----
0
7209
768

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col2 >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2163
SELECT col1 * col2 + - col0 + col2 DIV tab1.col2 AS col0 FROM tab1
----
1169
1402
507

skipif mysql # not compatible
query I rowsort label-2163
SELECT col1 * col2 + - col0 + col2 / tab1.col2 AS col0 FROM tab1
----
1169
1402
507

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col1 = col0 * + col2
----

query I rowsort
SELECT DISTINCT col0 + - col0 * + col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - col0 + + col1 FROM tab2 WHERE NOT ( col0 ) IN ( + col2 )
----
-19
-62
24

query I rowsort
SELECT - tab0.col2 * tab0.col1 + col0 + col2 AS col1 FROM tab0
----
-2781
-61
-7291

query I rowsort
SELECT + col0 / - tab2.col2 + - col2 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND ( col2 )
----

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

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

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL <> col2
----

query I rowsort
SELECT + col1 AS col0 FROM tab0 WHERE NOT NULL IN ( - tab0.col1 + + col1 )
----

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

query I rowsort
SELECT DISTINCT + 29 * + col1 FROM tab0
----
2494
2639
2813

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

skipif mysql # not compatible
query I rowsort label-2175
SELECT tab0.col2 + col2 / col2 FROM tab0
----
2
34
83

query I rowsort
SELECT ALL ( + 1 ) * col1 * - 80 AS col1 FROM tab2
----
-1360
-2480
-4720

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

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

query I rowsort
SELECT ALL ( - col0 + - col1 ) FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ALL - tab1.col2 * - tab1.col1 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 16ae0e1090cb09b93854a4788f17716b

query I rowsort
SELECT col0 * - 92 FROM tab1
----
-276
-5888
-7360

query I rowsort
SELECT ALL - - col2 * + col0 - + col1 FROM tab1 AS cor0
----
136
3638
7667

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2183
SELECT ALL 44 DIV col1 FROM tab1 AS cor0
----
1
3
4

skipif mysql # not compatible
query I rowsort label-2183
SELECT ALL 44 / col1 FROM tab1 AS cor0
----
1
3
4

query I rowsort
SELECT DISTINCT - col1 * + col0 + col2 * - col0 AS col1 FROM tab2 cor0
----
-406
-4345
-6630

query I rowsort
SELECT DISTINCT + - col0 * + cor0.col0 + ( - col1 ) FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT - + col2 + + col0 * - cor0.col0 * - cor0.col1 + + cor0.col0 FROM tab2 AS cor0
----
106138
1499
359008

query I rowsort
SELECT ALL - ( + col2 ) * col2 + + col1 AS col1 FROM tab2 AS cor0
----
-1427
-617
-698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2188
SELECT DISTINCT col2 + - col0 - + CAST( - col0 + - col0 AS SIGNED ) FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-2188
SELECT DISTINCT col2 + - col0 - + CAST ( - col0 + - col0 AS INTEGER ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + 22 + - col2 AS col2 FROM tab1 AS cor0
----
-32
-35
-74

query I rowsort
SELECT ALL - 25 * + col0 FROM tab2 AS cor0
----
-175
-1950
-1975

query I rowsort
SELECT ALL 25 FROM tab2 cor0
----
25
25
25

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2193
SELECT ALL col0 DIV - 95 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2193
SELECT ALL col0 / - 95 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * + col1 - col0 AS col2 FROM tab1 cor0
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2195
SELECT DISTINCT col0 DIV + ( ( - cor0.col0 ) ) AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2195
SELECT DISTINCT col0 / + ( ( - cor0.col0 ) ) AS col2 FROM tab0 AS cor0
----
-1

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

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

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

query I rowsort
SELECT DISTINCT - col0 + 76 AS col1 FROM tab2 AS cor0
----
-2
-3
69

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

query I rowsort
SELECT ALL cor0.col0 + + 23 AS col1 FROM tab0 AS cor0
----
112
47
58

query I rowsort
SELECT DISTINCT + - col2 * + ( - col2 ) AS col2 FROM tab0 cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

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

skipif mysql # not compatible
query I rowsort label-2203
SELECT ALL CAST ( NULL AS INTEGER ) * cor0.col2 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT ALL - + 8 - - col2 AS col0 FROM tab2 AS cor0
----
18
19
30

query I rowsort
SELECT 26 * - 46 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1199
-1260
-1276

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

query I rowsort
SELECT - - col1 * 45 + col0 AS col1 FROM tab1 AS cor0
----
1173
514
665

query I rowsort
SELECT ALL - col1 + - ( col1 + + col1 ) * 29 AS col1 FROM tab0
----
-5074
-5369
-5723

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

query I rowsort
SELECT + 96 * col2 FROM tab1 AS cor0
----
5184
5472
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + cor0.col2 ) * col1 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - 21 + col1 + ( - tab1.col0 ) * col2 FROM tab1
----
-157
-3659
-7688

query I rowsort
SELECT - tab2.col0 * tab2.col0 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to 0719570c0aa70e641b7702b59c5d598a

query I rowsort
SELECT + col2 * - 75 + col2 AS col1 FROM tab1 AS cor0
----
-3996
-4218
-7104

query I rowsort
SELECT 24 + + col0 + col2 AS col1 FROM tab0
----
195
60
81

query I rowsort
SELECT + col0 * col2 * + 62 AS col2 FROM tab2
----
11718
125736
186124

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

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) * 7 FROM tab2 cor0
----
-49
-546
-553

query I rowsort
SELECT ALL - 5 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

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

query I rowsort
SELECT - col2 * - col0 * ( + col2 ) FROM tab2
----
114076
5103
52728

query I rowsort
SELECT - col1 * + col0 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + col2 * + 88 FROM tab1
----
4752
5016
8448

query I rowsort
SELECT - col1 * + ( 93 + col2 ) FROM tab2 AS cor0
----
-2227
-3720
-7021

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 34 col1 FROM tab1 AS cor0
----
-340
-442
-884

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

skipif mysql # not compatible
query I rowsort label-2228
SELECT + - col0 * - CAST ( col1 AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

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

query I rowsort
SELECT cor0.col0 + + 25 AS col0 FROM tab0 cor0
----
114
49
60

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

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

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

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

query I rowsort
SELECT DISTINCT - + 30 + - col2 * - col0 FROM tab1 AS cor0
----
132
3618
7650

query I rowsort
SELECT DISTINCT col1 * col0 * col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT + col1 * + col2 * + col2 AS col0 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT ( - ( col0 ) ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT 42 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 23 col2 FROM tab2, tab0 cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2240
SELECT - col1 + col1 DIV 17 FROM tab1 AS cor0
----
-10
-13
-25

skipif mysql # not compatible
query I rowsort label-2240
SELECT - col1 + col1 / 17 FROM tab1 AS cor0
----
-10
-13
-25

query I rowsort
SELECT + 83 * - cor0.col1 FROM tab1 AS cor0
----
-1079
-2158
-830

query I rowsort
SELECT col0 * col1 + ( + tab2.col2 + col0 ) FROM tab2
----
1460
251
4706

onlyif mysql # use DIV operator for integer division
query I rowsort label-2243
SELECT + ( col0 ) * col0 DIV - col2 FROM tab1 AS cor0
----
-66
-71
0

skipif mysql # not compatible
query I rowsort label-2243
SELECT + ( col0 ) * col0 / - col2 FROM tab1 AS cor0
----
-66
-71
0

query I rowsort
SELECT ALL - cor0.col1 * col1 + + col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT ALL col2 + - col2 * cor0.col0 AS col0 FROM tab1 cor0
----
-108
-3591
-7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * col2 + ( col1 ) col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - cor0.col1 FROM tab0, tab1 cor0, tab0 cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT ALL - 39 + + col2 * ( + ( + cor0.col0 ) ) - + col0 * - col1 FROM tab0 AS cor0
----
15358
2817
3391

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2252
SELECT DISTINCT col1 DIV - 16 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2252
SELECT DISTINCT col1 / - 16 FROM tab1 AS cor0
----
-1
0

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

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

query I rowsort
SELECT - col0 * 96 + cor0.col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

query I rowsort
SELECT + col0 * col0 + col0 + - col1 AS col2 FROM tab0 AS cor0
----
1163
514
7919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2257
SELECT DISTINCT CAST( NULL AS DECIMAL ) * + 84 * + col1 - + col0 col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2257
SELECT DISTINCT CAST ( NULL AS REAL ) * + 84 * + col1 - + col0 col0 FROM tab0 AS cor0
----
NULL

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

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

skipif mysql # not compatible
query I rowsort label-2259
SELECT + CAST ( NULL AS REAL ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 53 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

query I rowsort
SELECT - + 28 AS col1 FROM tab0 cor0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT - 2 * cor1.col0 FROM tab1, tab2, tab0 AS cor0, tab0 AS cor1
----
-178
-48
-70

query I rowsort
SELECT col2 * 68 + col1 * col0 AS col2 FROM tab1 AS cor0
----
3750
4516
7568

query I rowsort
SELECT DISTINCT - col1 * - col1 * + col1 AS col2 FROM tab2
----
205379
29791
4913

onlyif mysql # use DIV operator for integer division
query I rowsort label-2265
SELECT tab1.col2 * ( col2 ) DIV col0 - ( + 41 ) FROM tab1
----
74
9
931

skipif mysql # not compatible
query I rowsort label-2265
SELECT tab1.col2 * ( col2 ) / col0 - ( + 41 ) FROM tab1
----
74
9
931

query I rowsort
SELECT - col0 * 7 FROM tab2 AS cor0
----
-49
-546
-553

onlyif mysql # use DIV operator for integer division
query I rowsort label-2267
SELECT DISTINCT + ( - col1 ) + - col0 * cor0.col2 DIV - col1 FROM tab0 AS cor0
----
-11
-77
-97

skipif mysql # not compatible
query I rowsort label-2267
SELECT DISTINCT + ( - col1 ) + - col0 * cor0.col2 / - col1 FROM tab0 AS cor0
----
-11
-77
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 92 col1 FROM tab1 AS cor0
----
-92

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-2273
SELECT ALL CAST ( NULL AS INTEGER ) + col1 * + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2274
SELECT ALL + col1 + + col1 DIV col0 FROM tab2 cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-2274
SELECT ALL + col1 + + col1 / col0 FROM tab2 cor0
----
17
35
59

query I rowsort
SELECT + col2 + 71 * + col2 FROM tab1 AS cor0
----
3888
4104
6912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 98 col0 FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT + 49 + - col2 AS col1 FROM tab1 AS cor0
----
-47
-5
-8

query I rowsort
SELECT cor0.col2 * col2 + - 6 AS col2 FROM tab0 AS cor0
----
-5
1083
6718

query I rowsort
SELECT col2 + + col0 * + col0 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2280
SELECT col1 * col2 + + ( - ( col2 ) ) DIV + col1 AS col2 FROM tab2 AS cor0
----
1534
644
837

skipif mysql # not compatible
query I rowsort label-2280
SELECT col1 * col2 + + ( - ( col2 ) ) / + col1 AS col2 FROM tab2 AS cor0
----
1534
644
837

query I rowsort
SELECT - - 76 * + col1 + col2 AS col1 FROM tab1 AS cor0
----
1084
2030
817

query I rowsort
SELECT DISTINCT 29 * - col2 + - col0 * col0 AS col1 FROM tab1
----
-1575
-5749
-9184

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

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

query I rowsort
SELECT ( - col1 ) - - cor0.col0 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT 0 * col0 + ( + 64 ) AS col2 FROM tab0 AS cor0
----
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-2286
SELECT ALL + 83 DIV - col2 + + cor0.col1 FROM tab0 AS cor0
----
14
84
90

skipif mysql # not compatible
query I rowsort label-2286
SELECT ALL + 83 / - col2 + + cor0.col1 FROM tab0 AS cor0
----
14
84
90

query I rowsort
SELECT ALL + - col2 * col2 + - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT - cor0.col0 + - ( + col2 * col2 ) FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ALL col0 + - ( col2 ) * col0 FROM tab0 AS cor0
----
-7209
-768
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2291
SELECT DISTINCT col0 DIV 19 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-2291
SELECT DISTINCT col0 / 19 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT cor0.col1 + - ( col1 ) FROM tab0 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT DISTINCT col0 * - 97 FROM tab0 AS cor0
----
-2328
-3395
-8633

query I rowsort
SELECT - col0 * 95 + ( - col2 ) FROM tab2 AS cor0
----
-692
-7436
-7543

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

query I rowsort
SELECT DISTINCT col1 * ( col0 ) AS col1 FROM tab1 AS cor0
----
1040
640
78

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

query I rowsort
SELECT 79 + col1 FROM tab0
----
165
170
176

query I rowsort
SELECT DISTINCT - col0 * col2 + 68 FROM tab1 AS cor0
----
-3580
-7612
-94

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - cor0.col0 * - CAST ( - col0 AS REAL ) + col2 FROM tab2 AS cor0
----
6110
6279
76

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-2303
SELECT ALL + col1 * col0 + col2 DIV - cor0.col1 + + col1 AS col0 FROM tab1 cor0
----
102
1046
645

skipif mysql # not compatible
query I rowsort label-2303
SELECT ALL + col1 * col0 + col2 / - cor0.col1 + + col1 AS col0 FROM tab1 cor0
----
102
1046
645

onlyif mysql # use DIV operator for integer division
query I rowsort label-2304
SELECT ALL + col0 * 97 DIV + col1 AS col1 FROM tab0
----
27
35
94

skipif mysql # not compatible
query I rowsort label-2304
SELECT ALL + col0 * 97 / + col1 AS col1 FROM tab0
----
27
35
94

query I rowsort
SELECT 16 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2306
SELECT - CAST( - col2 AS SIGNED ) * col1 * - ( col0 * + col1 ) AS col1 FROM tab1 cor0
----
-109512
-1297920
-364800

skipif mysql # not compatible
query I rowsort label-2306
SELECT - CAST ( - col2 AS INTEGER ) * col1 * - ( col0 * + col1 ) AS col1 FROM tab1 cor0
----
-109512
-1297920
-364800

query I rowsort
SELECT ALL 34 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT tab1.col0 * - 29 FROM tab1
----
-1856
-2320
-87

query I rowsort
SELECT ALL tab0.col1 - col2 * + col2 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT ALL - 77 * - col0 + - col0 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT - 73 - col1 AS col1 FROM tab1 AS cor0
----
-83
-86
-99

query I rowsort
SELECT - - 31 + col0 AS col1 FROM tab1 AS cor0
----
111
34
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 + 4 col0 FROM tab2
----
30
31
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 25 ) col1 FROM tab2
----
-25
-25
-25

query I rowsort
SELECT col1 + + col2 * + tab0.col1 AS col0 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL + + col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - - cor0.col2 col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2318
SELECT DISTINCT - col0 * col1 * - CAST( - 93 AS SIGNED ) FROM tab0 AS cor0
----
-191952
-315735
-753207

skipif mysql # not compatible
query I rowsort label-2318
SELECT DISTINCT - col0 * col1 * - CAST ( - 93 AS INTEGER ) FROM tab0 AS cor0
----
-191952
-315735
-753207

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + col0 col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ( + col1 ) - - 95 * col2 FROM tab0 cor0
----
192
3221
7881

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

query I rowsort
SELECT ALL ( tab1.col0 ) + - cor1.col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 9988d482f94d4a436a2fe6e0568c1c30

query I rowsort
SELECT col1 + - cor0.col2 * + 78 FROM tab0 AS cor0
----
-2488
-6305
19

query I rowsort
SELECT ALL - col0 * cor0.col0 * + col2 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT + col0 * col1 + + col2 * col2 AS col0 FROM tab1 AS cor0
----
10256
2994
3889

onlyif mysql # use DIV operator for integer division
query I rowsort label-2326
SELECT DISTINCT cor0.col2 + col0 DIV 43 FROM tab0 AS cor0
----
1
33
84

skipif mysql # not compatible
query I rowsort label-2326
SELECT DISTINCT cor0.col2 + col0 / 43 FROM tab0 AS cor0
----
1
33
84

query I rowsort
SELECT ( 71 ) AS col1 FROM tab0 AS cor0
----
71
71
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2328
SELECT + CAST( NULL AS SIGNED ) * + col0 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-2328
SELECT + CAST ( NULL AS INTEGER ) * + col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * ( col2 * + col1 ) FROM tab2
----
10982
25947
90506

query I rowsort
SELECT DISTINCT cor1.col2 * 23 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
1886
23
759

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

query I rowsort
SELECT + + 42 AS col1 FROM tab0 cor0
----
42
42
42

query I rowsort
SELECT ALL + + 16 + - col0 FROM tab2 cor0
----
-62
-63
9

query I rowsort
SELECT ALL col0 + cor0.col1 - - col2 AS col0 FROM tab2 AS cor0
----
134
163
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2335
SELECT DISTINCT - CAST( 16 AS SIGNED ) FROM tab1 AS cor0
----
-16

skipif mysql # not compatible
query I rowsort label-2335
SELECT DISTINCT - CAST ( 16 AS INTEGER ) FROM tab1 AS cor0
----
-16

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 # use DIV operator for integer division
query I rowsort label-2337
SELECT + tab2.col2 DIV - col0 + col0 FROM tab2
----
4
78
79

skipif mysql # not compatible
query I rowsort label-2337
SELECT + tab2.col2 / - col0 + col0 FROM tab2
----
4
78
79

query I rowsort
SELECT + col0 * col1 + cor0.col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT - + 50 + + col2 + col2 FROM tab0 AS cor0
----
-48
114
16

query I rowsort
SELECT + + 97 * col2 FROM tab1 AS cor0
----
5238
5529
9312

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

skipif mysql # not compatible
query I rowsort label-2341
SELECT DISTINCT + + col1 * + CAST ( col1 * + col2 AS INTEGER ) - col2 FROM tab0 AS cor0
----
244035
678960
9408

query I rowsort
SELECT DISTINCT + - col0 + - 64 FROM tab2 AS cor0
----
-142
-143
-71

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

skipif mysql # not compatible
query I rowsort label-2343
SELECT - col0 * + CAST ( + col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - col2 + 91 * 82 + col2 FROM tab0
----
7462

query I rowsort
SELECT ALL + tab1.col2 * col1 * col0 FROM tab1
----
36480
4212
99840

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2347
SELECT - + col1 DIV col2 + col1 * col0 FROM tab0 cor0
----
2062
3298
8098

skipif mysql # not compatible
query I rowsort label-2347
SELECT - + col1 / col2 + col1 * col0 FROM tab0 cor0
----
2062
3298
8098

onlyif mysql # use DIV operator for integer division
query I rowsort label-2348
SELECT + col2 + ( col2 ) DIV + col0 AS col1 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-2348
SELECT + col2 + ( col2 ) / + col0 AS col1 FROM tab1 AS cor0
----
57
72
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2349
SELECT - + cor0.col2 + - CAST( + col2 AS SIGNED ) DIV - cor0.col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-2349
SELECT - + cor0.col2 + - CAST ( + col2 AS INTEGER ) / - cor0.col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort
SELECT - col1 * + CAST ( - ( + col2 ) AS REAL ) * + 71 FROM tab1 AS cor0
----
40470
88608
99684

query I rowsort
SELECT ALL 61 * - col1 AS col1 FROM tab2 AS cor0
----
-1037
-1891
-3599

query I rowsort
SELECT DISTINCT - ( + 22 ) FROM tab1 AS cor0
----
-22

query I rowsort
SELECT + ( - 95 ) + + col0 * col1 FROM tab2 AS cor0
----
122
1248
4507

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

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

query I rowsort
SELECT - - col2 * col0 * + col0 FROM tab1 cor0
----
233472
486
614400

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

query I rowsort
SELECT + 50 + 50 * col2 FROM tab2 AS cor0
----
1350
1400
1950

query I rowsort
SELECT ALL + 94 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT DISTINCT + + col2 + col2 * - col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + col2 - + col0 * + ( + col2 + + cor0.col1 ) FROM tab1 cor0
----
-186
-4231
-8624

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

query I rowsort
SELECT DISTINCT tab0.col2 * + col0 * + col0 - col0 FROM tab0
----
1190
18984
649433

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - col0 col2 FROM tab1
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-2364
SELECT - - col1 * + col2 - + col0 DIV col0 FROM tab1 AS cor0
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-2364
SELECT - - col1 * + col2 - + col0 / col0 FROM tab1 AS cor0
----
1247
1403
569

query I rowsort
SELECT tab2.col0 + ( - col0 * - col0 ) FROM tab2
----
56
6162
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 + col1 * 8 col0 FROM tab0 AS cor0
----
759
799
847

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col0 ) * col2 col0 FROM tab1
----
-162
-3648
-7680

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

query I rowsort
SELECT + col0 + - 20 AS col0 FROM tab2 AS cor0
----
-13
58
59

query I rowsort
SELECT - col2 * 30 AS col2 FROM tab0 AS cor0
----
-2460
-30
-990

query I rowsort
SELECT 36 AS col0 FROM tab2 cor0
----
36
36
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2372
SELECT ALL + 42 * + col1 DIV - cor0.col1 AS col1 FROM tab0 cor0
----
-42
-42
-42

skipif mysql # not compatible
query I rowsort label-2372
SELECT ALL + 42 * + col1 / - cor0.col1 AS col1 FROM tab0 cor0
----
-42
-42
-42

query I rowsort
SELECT DISTINCT - col0 * + col1 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT 59 + col2 FROM tab1
----
113
116
155

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2375
SELECT ALL CAST( NULL AS DECIMAL ) AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2375
SELECT ALL CAST ( NULL AS REAL ) AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL 15 AS col0 FROM tab2 AS cor0
----
15
15
15

query I rowsort
SELECT + + 81 * col1 + col2 * col2 * + col0 AS col2 FROM tab0 AS cor0
----
33102
605807
7892

query I rowsort
SELECT + - 59 + col2 AS col0 FROM tab2 AS cor0
----
-21
-32
-33

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

query I rowsort
SELECT DISTINCT - col1 * col0 - - 85 AS col2 FROM tab0 AS cor0
----
-1979
-3310
-8014

query I rowsort
SELECT DISTINCT - col2 + col0 * - col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT col1 + - cor0.col0 * + col0 AS col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT tab1.col0 + + col1 * - ( col0 * - 7 ) FROM tab1
----
4544
549
7360

query I rowsort
SELECT DISTINCT tab2.col0 * - col2 - - 7 AS col1 FROM tab2
----
-182
-2021
-2995

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2385
SELECT - tab2.col1 * CAST( col0 AS SIGNED ) col1 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2385
SELECT - tab2.col1 * CAST ( col0 AS INTEGER ) col1 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col0 - col2 * - col0 * col0 col2 FROM tab0
----
1261
19065
649693

query I rowsort
SELECT DISTINCT col1 - - 40 * tab1.col2 AS col2 FROM tab1
----
2186
2290
3853

query I rowsort
SELECT col2 * col0 + col2 AS col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT col2 * col1 - 26 FROM tab1
----
1222
1378
544

query I rowsort
SELECT + col2 * - col2 + col0 + col2 * col0 FROM tab1 AS cor0
----
-1456
-2751
463

onlyif mysql # use DIV operator for integer division
query I rowsort label-2391
SELECT ALL - CAST( + col2 AS SIGNED ) + col0 DIV cor0.col2 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-2391
SELECT ALL - CAST ( + col2 AS INTEGER ) + col0 / cor0.col2 FROM tab1 AS cor0
----
-54
-56
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2392
SELECT DISTINCT + CAST( + 69 AS SIGNED ) + - col0 * cor0.col1 FROM tab0 AS cor0
----
-1995
-3326
-8030

skipif mysql # not compatible
query I rowsort label-2392
SELECT DISTINCT + CAST ( + 69 AS INTEGER ) + - col0 * cor0.col1 FROM tab0 AS cor0
----
-1995
-3326
-8030

onlyif mysql # use DIV operator for integer division
query I rowsort label-2393
SELECT ALL + CAST( col1 AS SIGNED ) * col0 DIV + 8 FROM tab2 cor0
----
167
27
575

skipif mysql # not compatible
query I rowsort label-2393
SELECT ALL + CAST ( col1 AS INTEGER ) * col0 / + 8 FROM tab2 cor0
----
167
27
575

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

query I rowsort
SELECT ALL + - col1 + 96 AS col0 FROM tab0 AS cor0
----
-1
10
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 50 ) col0 FROM tab1 AS cor0
----
50
50
50

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

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

query I rowsort
SELECT col1 * + col1 + - col1 * - col1 FROM tab2 AS cor0
----
1922
578
6962

query I rowsort
SELECT - + cor0.col1 * + cor0.col2 + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - cor0.col2 + col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 75 col1 FROM tab1, tab1 cor0
----
75

query I rowsort
SELECT - + 55 + col1 + - cor0.col0 FROM tab2 AS cor0
----
-117
-31
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-2405
SELECT ALL col2 * ( ( col0 ) ) DIV - CAST( + col0 AS SIGNED ) FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2405
SELECT ALL col2 * ( ( col0 ) ) / - CAST ( + col0 AS INTEGER ) FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL + 81 * + col0 FROM tab2 cor0
----
567
6318
6399

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

query I rowsort
SELECT + - cor0.col0 + 89 * - col1 - col0 FROM tab0 AS cor0
----
-7702
-8277
-8703

query I rowsort
SELECT ALL + ( + col1 ) * - col1 * 78 FROM tab0 AS cor0
----
-576888
-645918
-733902

query I rowsort
SELECT DISTINCT 53 + + col2 * col2 FROM tab2 AS cor0
----
1497
729
782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 2 col2 FROM tab2 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT + 88 FROM tab0, tab0 AS cor0
----
88

query I rowsort
SELECT cor1.col2 * + cor0.col2 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 1a327f2a52a0a35b577f58109ee147a4

query I rowsort
SELECT DISTINCT ( + col2 ) * + col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - - col1 * 50 * col2 + + 37 FROM tab1 cor0
----
28537
62437
70237

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

query I rowsort
SELECT DISTINCT - col0 + + ( - cor0.col1 ) FROM tab2 AS cor0
----
-137
-38
-96

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

query I rowsort
SELECT ALL + + ( ( col1 ) ) + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 col2 FROM tab0 cor0
----
-2064
-3395
-8099

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-2423
SELECT - + cor0.col2 DIV - cor0.col2 + - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-2423
SELECT - + cor0.col2 / - cor0.col2 + - col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT - 25 + col0 FROM tab1 cor0
----
-22
39
55

query I rowsort
SELECT DISTINCT + col2 * + col0 * + col0 FROM tab1 cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 + col1 col1 FROM tab2 AS cor0
----
31
45
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 79 col0 FROM tab1 AS cor0
----
-79
-79
-79

query I rowsort
SELECT col2 * + cor0.col2 + col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - tab1.col0 + - 86 AS col0 FROM tab1
----
-150
-166
-89

query I rowsort
SELECT + 7 * tab2.col0 FROM tab2
----
49
546
553

query I rowsort
SELECT ALL + col2 * cor0.col1 + - 58 FROM tab2 AS cor0
----
1476
588
779

query I rowsort
SELECT ALL - col1 * col1 + col0 * cor0.col1 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT DISTINCT col2 + + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-2434
SELECT DISTINCT + col2 + 9 DIV - col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2434
SELECT DISTINCT + col2 + 9 / - col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col2 col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - col2 * - col2 * ( col2 ) AS col0 FROM tab0 AS cor0
----
1
35937
551368

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * - col1 col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL - ( col2 * - ( 80 ) ) AS col1 FROM tab0
----
2640
6560
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2440
SELECT - col0 * col1 * CAST( - col0 AS SIGNED ) + - col1 col2 FROM tab0
----
118728
49450
720720

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2440
SELECT - col0 * col1 * CAST ( - col0 AS INTEGER ) + - col1 col2 FROM tab0
----
118728
49450
720720

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

query I rowsort
SELECT + ( col0 ) + col0 - + col1 * col2 AS col0 FROM tab1 cor0
----
-1088
-1398
-442

query I rowsort
SELECT 18 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT DISTINCT col2 * + 81 + col1 FROM tab0 AS cor0
----
178
2759
6733

query I rowsort
SELECT - cor0.col0 + 78 + - col0 * + col2 AS col0 FROM tab1 AS cor0
----
-3634
-7682
-87

query I rowsort
SELECT ALL + col0 * 58 + col1 * col2 AS col2 FROM tab0
----
12624
2127
4230

query I rowsort
SELECT 62 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT 35 * + col0 AS col0 FROM tab2 AS cor0
----
245
2730
2765

query I rowsort
SELECT ALL ( + col0 ) * col1 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2450
SELECT ALL + col1 * col0 DIV + 53 AS col1 FROM tab1
----
1
12
19

skipif mysql # not compatible
query I rowsort label-2450
SELECT ALL + col1 * col0 / + 53 AS col1 FROM tab1
----
1
12
19

query I rowsort
SELECT DISTINCT - 33 AS col0 FROM tab0, tab2 cor0
----
-33

query I rowsort
SELECT - + 89 * - col2 + + 91 * cor0.col0 AS col2 FROM tab2 AS cor0
----
10571
3040
9412

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

query I rowsort
SELECT + 86 * col1 + + 69 AS col2 FROM tab1 AS cor0
----
1187
2305
929

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

skipif mysql # not compatible
query I rowsort label-2455
SELECT - + 38 / - col0 AS col2 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT ALL - col2 + + 19 AS col1 FROM tab0
----
-14
-63
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2457
SELECT ALL CAST( - 45 AS SIGNED ) * - col2 + col2 FROM tab0
----
1518
3772
46

skipif mysql # not compatible
query I rowsort label-2457
SELECT ALL CAST ( - 45 AS INTEGER ) * - col2 + col2 FROM tab0
----
1518
3772
46

query I rowsort
SELECT col1 * - col1 + + col2 AS col0 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT + + 39 AS col1 FROM tab2 AS cor0
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2460
SELECT + - 92 DIV - col1 - + ( col1 ) FROM tab0 AS cor0
----
-85
-90
-97

skipif mysql # not compatible
query I rowsort label-2460
SELECT + - 92 / - col1 - + ( col1 ) FROM tab0 AS cor0
----
-85
-90
-97

query I rowsort
SELECT ALL + cor0.col1 * col0 + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT col2 * - col1 + cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2463
SELECT ALL + col0 + col1 DIV col1 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2463
SELECT ALL + col0 + col1 / col1 AS col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT - + col2 + - 65 * - 90 FROM tab1 AS cor0
----
5754
5793
5796

query I rowsort
SELECT ALL - col0 * cor0.col2 - col2 AS col1 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT ALL + col2 * + ( + 8 ) FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT + - col0 * col1 + + 87 FROM tab0 AS cor0
----
-1977
-3308
-8012

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

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

query I rowsort
SELECT DISTINCT col2 + 69 FROM tab1 AS cor0
----
123
126
165

onlyif mysql # use DIV operator for integer division
query I rowsort label-2470
SELECT - 9 DIV col2 - + col2 FROM tab0
----
-10
-33
-82

skipif mysql # not compatible
query I rowsort label-2470
SELECT - 9 / col2 - + col2 FROM tab0
----
-10
-33
-82

query I rowsort
SELECT DISTINCT col0 - - col1 * col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT + ( + col0 * + tab2.col0 + + col0 ) FROM tab2
----
56
6162
6320

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

query I rowsort
SELECT - 92 AS col2 FROM tab2
----
-92
-92
-92

query I rowsort
SELECT DISTINCT + 60 AS col0 FROM tab2
----
60

query I rowsort
SELECT DISTINCT col2 - col1 * col0 AS col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT col1 + + col2 * - 22 + col0 * - col1 AS col2 FROM tab2
----
-2162
-5115
-780

query I rowsort
SELECT DISTINCT - col2 * - tab0.col1 + - col0 * col0 FROM tab0
----
-1128
-459
2262

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

query I rowsort
SELECT cor0.col1 + ( - ( - col1 ) + - col0 ) * - col2 * - col1 FROM tab1 AS cor0
----
-30770
-83603
32318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col2 + + col1 col1 FROM tab0 AS cor0
----
1175
6815
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2482
SELECT - cor0.col0 DIV ( + col1 ) + col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-2482
SELECT - cor0.col0 / ( + col1 ) + col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2483
SELECT - col2 + - CAST( - 19 AS SIGNED ) FROM tab1 AS cor0
----
-35
-38
-77

skipif mysql # not compatible
query I rowsort label-2483
SELECT - col2 + - CAST ( - 19 AS INTEGER ) FROM tab1 AS cor0
----
-35
-38
-77

query I rowsort
SELECT + 1 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

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

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

query I rowsort
SELECT - col0 * + 53 FROM tab0 AS cor0
----
-1272
-1855
-4717

onlyif mysql # use DIV operator for integer division
query I rowsort label-2488
SELECT col0 * col0 DIV + col1 FROM tab2 AS cor0
----
1
103
367

skipif mysql # not compatible
query I rowsort label-2488
SELECT col0 * col0 / + col1 FROM tab2 AS cor0
----
1
103
367

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2489
SELECT + CAST( - col1 AS SIGNED ) FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2489
SELECT + CAST ( - col1 AS INTEGER ) FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT + cor0.col1 * 23 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a27c2fabaf6ba45a4c560bfd0e4eb0d2

query I rowsort
SELECT ALL - col2 + col0 * col1 * - col0 AS col2 FROM tab2 AS cor0
----
-106135
-1546
-358982

query I rowsort
SELECT + cor1.col2 * 20 * + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ed6c2c8c867510ece5ec570b5c17b204

query I rowsort
SELECT + 99 + - col2 FROM tab2 AS cor0
----
61
72
73

query I rowsort
SELECT + 90 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

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

query I rowsort
SELECT - col2 * + col0 - tab1.col0 FROM tab1
----
-165
-3712
-7760

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) < NULL
----

query I rowsort
SELECT + col1 * - col1 FROM tab1 WHERE NULL NOT BETWEEN col1 / + col0 AND NULL
----

query I rowsort
SELECT ALL - tab2.col0 * col0 + + col1 FROM tab2
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 - + col1 * col2 col0 FROM tab0
----
-2752
-7371
0

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

query I rowsort
SELECT DISTINCT col1 + tab2.col2 * tab2.col0 + - tab2.col0 AS col2 FROM tab2
----
2009
213
2940

query I rowsort
SELECT col1 * + col2 * + col0 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-2504
SELECT + col0 * col0 DIV + col2 FROM tab1
----
0
66
71

skipif mysql # not compatible
query I rowsort label-2504
SELECT + col0 * col0 / + col2 FROM tab1
----
0
66
71

query I rowsort
SELECT col0 FROM tab0 WHERE NULL IN ( col1 * + tab0.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 + col1 col1 FROM tab1
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 39 + + col2 col2 FROM tab0 AS cor0
----
-38
-6
43

query I rowsort
SELECT ALL + col0 * tab2.col1 * col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT - col1 AS col0 FROM tab0 WHERE NOT NULL IN ( + tab0.col1 / col0 )
----

query I rowsort
SELECT - col0 * - col0 + - col1 * + col0 AS col2 FROM tab0
----
-1488
-178
-2170

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col1 * col0 + col1 >= NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT - col2 * col2 + + col0 NOT IN ( col0 * + col2 )
----

query I rowsort
SELECT DISTINCT tab2.col0 * col1 - - col0 FROM tab2
----
1422
224
4680

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

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT NULL BETWEEN ( col2 ) AND NULL
----

query I rowsort
SELECT ALL col2 + + cor0.col2 - + col1 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT DISTINCT col2 * col2 + col1 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT tab0.col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 col0 FROM tab0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 * col2 col1 FROM tab1
----
216
3705
7776

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2522
SELECT DISTINCT + tab1.col1 * col1 DIV - col0 FROM tab1
----
-1
-2
-225

skipif mysql # not compatible
query I rowsort label-2522
SELECT DISTINCT + tab1.col1 * col1 / - col0 FROM tab1
----
-1
-2
-225

query I rowsort
SELECT col1 + + col2 * + col1 * - tab2.col0 AS col2 FROM tab2
----
-119593
-51017
-5828

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

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) = ( - col2 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 * + col2 + col0 col2 FROM tab2
----
1638
763
871

onlyif mysql # use DIV operator for integer division
query I rowsort label-2528
SELECT col0 + tab0.col2 * - col0 - + col1 * tab0.col0 DIV col1 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-2528
SELECT col0 + tab0.col2 * - col0 - + col1 * tab0.col0 / col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col0 * col1 + - col0 + + tab1.col0 * - col2 * col2 FROM tab1
----
-207360
-736320
-8673

query I rowsort
SELECT DISTINCT col2 + + col2 + col1 * col2 AS col0 FROM tab0
----
2904
7626
99

query I rowsort
SELECT DISTINCT col2 + col2 + + col2 AS col2 FROM tab1
----
162
171
288

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) NOT IN ( col2 )
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE col2 IN ( - col1 )
----

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT col1 >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2535
SELECT DISTINCT col2 * - col1 + cor0.col2 * col0 DIV + cor0.col1 FROM tab2 AS cor0
----
-1500
-470
-831

skipif mysql # not compatible
query I rowsort label-2535
SELECT DISTINCT col2 * - col1 + cor0.col2 * col0 / + cor0.col1 FROM tab2 AS cor0
----
-1500
-470
-831

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col2 col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 11 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 288f8fb62e079d095c14d7cf3e2d3359

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 1 * 6 col2 FROM tab1 AS cor0
----
-6
-6
-6

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

query I rowsort
SELECT + col2 * + col1 + 99 AS col0 FROM tab2 AS cor0
----
1633
745
936

query I rowsort
SELECT - col2 * + col1 * + ( + ( - col2 ) ) AS col2 FROM tab0 AS cor0
----
611884
93654
97

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 + - col0 col0 FROM tab2 cor0
----
-26
-27
-38

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

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

query I rowsort
SELECT ALL cor0.col1 * ( - col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * + col0 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 93 col1 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT DISTINCT + col2 + ( col1 ) * col2 * + col0 AS col1 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT ALL col0 * ( - ( col2 ) ) + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - col2 * 56 AS col2 FROM tab0 AS cor0
----
-1848
-4592
-56

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

query I rowsort
SELECT + col1 * + col0 + cor0.col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT - cor0.col1 * cor0.col1 FROM tab2, tab1 cor0
----
9 values hashing to 38f503ad6f93db2d1a70a8c95bb8c2c2

query I rowsort
SELECT + col1 + - col1 * col1 + + col0 FROM tab2 cor0
----
-193
-3344
-923

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

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

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

query I rowsort
SELECT 4 * + col0 + 88 FROM tab0 AS cor0
----
184
228
444

query I rowsort
SELECT - col0 * col2 + 6 FROM tab2 AS cor0
----
-183
-2022
-2996

query I rowsort
SELECT + 98 + col1 FROM tab2 AS cor0
----
115
129
157

query I rowsort
SELECT ALL - 69 AS col1 FROM tab0
----
-69
-69
-69

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

query I rowsort
SELECT + col1 * - col1 * col1 AS col0 FROM tab1 cor0
----
-1000
-17576
-2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 * - col0 col0 FROM tab0 cor0
----
-1608
-2345
-5963

query I rowsort
SELECT - col1 * - 71 FROM tab2 AS cor0
----
1207
2201
4189

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

query I rowsort
SELECT + col0 + + cor0.col0 * + 9 * + col2 AS col1 FROM tab1 AS cor0
----
1461
32896
69200

onlyif mysql # use DIV operator for integer division
query I rowsort label-2568
SELECT + col0 - + ( - col0 ) DIV + col2 AS col2 FROM tab1 cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-2568
SELECT + col0 - + ( - col0 ) / + col2 AS col2 FROM tab1 cor0
----
3
65
80

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

query I rowsort
SELECT + cor0.col2 * + 51 FROM tab1 AS cor0
----
2754
2907
4896

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2571
SELECT - - col2 * - CAST( - 56 + col1 AS SIGNED ) * - ( ( col0 ) ) col0 FROM tab1 AS cor0
----
-167808
-330240
-4860

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2571
SELECT - - col2 * - CAST ( - 56 + col1 AS INTEGER ) * - ( ( col0 ) ) col0 FROM tab1 AS cor0
----
-167808
-330240
-4860

query I rowsort
SELECT + - ( 64 ) + + col1 AS col1 FROM tab2 cor0
----
-33
-47
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2573
SELECT - - 76 + 28 DIV col1 FROM tab2 AS cor0
----
76
76
77

skipif mysql # not compatible
query I rowsort label-2573
SELECT - - 76 + 28 / col1 FROM tab2 AS cor0
----
76
76
77

query I rowsort
SELECT col2 * - 95 FROM tab2 AS cor0
----
-2470
-2565
-3610

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

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

query I rowsort
SELECT ALL + col1 + col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - cor0.col2 AS REAL ) - col2 AS col2 FROM tab1 AS cor0
----
-108
-114
-192

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

query I rowsort
SELECT DISTINCT - col1 * 9 + - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1350
-2098
-8740

query I rowsort
SELECT DISTINCT + col0 * ( - col0 ) + - 2 FROM tab1 AS cor0
----
-11
-4098
-6402

query I rowsort
SELECT ALL + col0 * col1 + col0 + - col2 AS col0 FROM tab1 AS cor0
----
1024
27
647

onlyif mysql # use DIV operator for integer division
query I rowsort label-2582
SELECT - 85 + - ( col2 ) DIV + 3 FROM tab0 AS cor0
----
-112
-85
-96

skipif mysql # not compatible
query I rowsort label-2582
SELECT - 85 + - ( col2 ) / + 3 FROM tab0 AS cor0
----
-112
-85
-96

query I rowsort
SELECT - col0 + ( col0 ) * - cor0.col1 - + col0 AS col1 FROM tab0 AS cor0
----
-2112
-3465
-8277

onlyif mysql # use DIV operator for integer division
query I rowsort label-2584
SELECT 19 DIV + 96 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2584
SELECT 19 / + 96 FROM tab2 AS cor0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-2585
SELECT DISTINCT - col2 + + 25 * + col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 * + col0 * col1 AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT ALL col0 + col1 * - col0 + col2 AS col2 FROM tab0 AS cor0
----
-2007
-3359
-7928

query I rowsort
SELECT ALL - col1 * + col0 * - col1 + - col1 FROM tab1 AS cor0
----
13507
2002
6390

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) + - col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + - 97 FROM tab1 AS cor0
----
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 + cor0.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 7e40e63e1d968f57439cc0074c42b75e

query I rowsort
SELECT DISTINCT + col0 - + col0 * 74 FROM tab1 cor0
----
-219
-4672
-5840

query I rowsort
SELECT DISTINCT + - cor1.col0 * - cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-2594
SELECT cor0.col2 DIV + 95 - col2 * ( - col1 ) FROM tab2 cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-2594
SELECT cor0.col2 / + 95 - col2 * ( - col1 ) FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 0 - + ( + col0 ) * + ( + col2 ) col0 FROM tab0
----
-35
-7298
-792

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

query I rowsort
SELECT DISTINCT + + col0 * + col2 * col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT cor0.col0 + 47 AS col2 FROM tab2 AS cor0
----
125
126
54

query I rowsort
SELECT ALL ( - cor0.col0 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

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

query I rowsort
SELECT - 40 - cor0.col0 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 5355802d4c12c50bfaf9a03f01ce456e

query I rowsort
SELECT 99 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * + 56 col0 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT 33 + - cor0.col0 * + 16 * + col2 AS col0 FROM tab1 AS cor0
----
-122847
-2559
-58335

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2605
SELECT - tab1.col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab0 AS cor0, tab0, tab0 cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-2605
SELECT - tab1.col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab0 AS cor0, tab0, tab0 cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT - 50 * col1 AS col1 FROM tab2 AS cor0
----
-1550
-2950
-850

query I rowsort
SELECT + col2 + col0 * 51 FROM tab2 AS cor0
----
384
4004
4067

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 52 + + col0 col1 FROM tab0 AS cor0
----
141
76
87

query I rowsort
SELECT ALL + col2 + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 88 * col2 col2 FROM tab2 AS cor0
----
2288
2376
3344

query I rowsort
SELECT ALL col2 * - col1 * col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ( - col0 ) + + col1 * 30 FROM tab2 AS cor0
----
1692
431
923

query I rowsort
SELECT ALL - 43 * - col2 AS col1 FROM tab2 AS cor0
----
1118
1161
1634

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

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

query I rowsort
SELECT col2 * - 4 - col2 AS col1 FROM tab1 AS cor0
----
-270
-285
-480

query I rowsort
SELECT + col1 * col1 + - col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT - col0 * - col0 + cor0.col2 * col1 + 25 FROM tab2 AS cor0
----
6912
7643
911

query I rowsort
SELECT - col0 * - cor0.col0 + col1 * + col0 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT - col1 + col0 + 97 * col1 FROM tab0
----
8280
8825
9347

onlyif mysql # use DIV operator for integer division
query I rowsort label-2620
SELECT + 52 + + col1 DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
53
53
53

skipif mysql # not compatible
query I rowsort label-2620
SELECT + 52 + + col1 / cor0.col1 AS col0 FROM tab2 AS cor0
----
53
53
53

query I rowsort
SELECT + 80 - - 74 FROM tab1, tab0 cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 57035db81452f9bb57531372dd419dce

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

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

skipif mysql # not compatible
query I rowsort label-2623
SELECT ALL + 0 / col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2624
SELECT ALL - 2 DIV - 96 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2624
SELECT ALL - 2 / - 96 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 92 + + col1 FROM tab0 cor0
----
178
183
189

query I rowsort
SELECT + + 32 AS col1 FROM tab2 AS cor0
----
32
32
32

query I rowsort
SELECT ALL - + 79 * + col0 + + 19 AS col1 FROM tab2 AS cor0
----
-534
-6143
-6222

query I rowsort
SELECT + 89 FROM tab2, tab1, tab2 cor0
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

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

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

query I rowsort
SELECT - 98 + - col1 * 71 AS col1 FROM tab1 AS cor0
----
-1021
-1944
-808

onlyif mysql # use DIV operator for integer division
query I rowsort label-2631
SELECT ALL - - col0 - cor0.col0 DIV 89 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2631
SELECT ALL - - col0 - cor0.col0 / 89 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col0 + col0 * - col0 FROM tab0
----
-1260
-600
-8010

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2634
SELECT ( + col2 + - CAST( + col1 AS SIGNED ) ) AS col2 FROM tab2
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-2634
SELECT ( + col2 + - CAST ( + col1 AS INTEGER ) ) AS col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col2 * - col0 * 53 AS col1 FROM tab2
----
10017
107484
159106

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

query I rowsort
SELECT ALL ( + cor1.col0 ) FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT + col0 * + col1 + 51 AS col2 FROM tab2
----
1394
268
4653

query I rowsort
SELECT DISTINCT col1 * + col1 + col1 * col2 FROM tab1
----
1417
2080
670

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT - col0 * col1 * ( + col1 * + 73 + col2 ) FROM tab1
----
-1086800
-152256
-503680

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

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

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

query I rowsort
SELECT tab0.col0 + ( - col0 * + col0 ) FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT + col1 - ( col0 ) AS col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT col0 + + 10 * col0 AS col1 FROM tab0 AS cor0
----
264
385
979

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

query I rowsort
SELECT DISTINCT - col1 * - ( cor0.col2 ) * cor0.col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL col0 + 57 * 2 + + col1 AS col0 FROM tab2
----
152
210
251

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col2 AS REAL ) + - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - - 35 + + 9 AS col1 FROM tab0 AS cor0
----
44
44
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2652
SELECT ALL + + CAST( - col1 AS SIGNED ) - col0 FROM tab0 AS cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-2652
SELECT ALL + + CAST ( - col1 AS INTEGER ) - col0 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 4 col0 FROM tab0 AS cor0
----
4

query I rowsort
SELECT 31 AS col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT + col0 * col2 + col1 * 75 AS col2 FROM tab2 AS cor0
----
2514
4277
6453

query I rowsort
SELECT + 31 * col2 AS col0 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT DISTINCT col2 * 80 - col1 AS col1 FROM tab0 AS cor0
----
-17
2554
6469

query I rowsort
SELECT col1 + + 76 * col0 FROM tab0 cor0
----
1910
2757
6855

query I rowsort
SELECT DISTINCT - + 28 * - 7 AS col0 FROM tab0 AS cor0
----
196

query I rowsort
SELECT ALL + 89 + 61 * + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-177787
-198100
-562087

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

skipif mysql # not compatible
query I rowsort label-2661
SELECT DISTINCT CAST ( NULL AS REAL ) / ( col0 ) - + col0 * col1 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - 50 + col2 AS col0 FROM tab0 cor0
----
-17
-49
32

query I rowsort
SELECT - col0 - ( + col0 + - col2 * - col1 ) AS col2 FROM tab2 AS cor0
----
-1690
-804
-851

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2665
SELECT ALL + cor0.col2 + - CAST( + col1 AS SIGNED ) - - col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2665
SELECT ALL + cor0.col2 + - CAST ( + col1 AS INTEGER ) - - col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab0, tab2, tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2668
SELECT col0 DIV + col0 - - col2 * tab2.col0 FROM tab2
----
190
2029
3003

skipif mysql # not compatible
query I rowsort label-2668
SELECT col0 / + col0 - - col2 * tab2.col0 FROM tab2
----
190
2029
3003

query I rowsort
SELECT DISTINCT - col1 - col1 * - col2 * col0 AS col1 FROM tab2
----
119593
51017
5828

query I rowsort
SELECT DISTINCT col0 * - 34 - col2 * - tab1.col0 AS col1 FROM tab1
----
1472
4960
60

query I rowsort
SELECT col2 * ( + 52 ) FROM tab1
----
2808
2964
4992

query I rowsort
SELECT col1 * - col1 + - col1 AS col0 FROM tab0 AS cor0
----
-7482
-8372
-9506

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2674
SELECT ALL + CAST( - col1 AS SIGNED ) * col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-2674
SELECT ALL + CAST ( - col1 AS INTEGER ) * col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - col2 * + ( col1 ) FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + 53 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT - - ( + col2 ) + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT ( 43 ) FROM tab0
----
43

query I rowsort
SELECT DISTINCT - tab2.col0 * ( + col0 ) FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT 4 + col1 * - ( 38 ) FROM tab2 cor0
----
-1174
-2238
-642

query I rowsort
SELECT DISTINCT + col2 * col1 * + col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT - 57 AS col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT DISTINCT ( col0 ) * - 95 AS col1 FROM tab1
----
-285
-6080
-7600

query I rowsort
SELECT DISTINCT ( cor0.col1 ) AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT 3 + - col2 AS col0 FROM tab2 AS cor0
----
-23
-24
-35

query I rowsort
SELECT DISTINCT + col2 + - ( col0 ) * col1 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col0 col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + col0 + + 71 FROM tab2 AS cor0
----
149
150
78

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

query I rowsort
SELECT DISTINCT + col0 - - 21 AS col0 FROM tab0 AS cor0
----
110
45
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 * - col1 + + 72 col1 FROM tab1 AS cor0
----
-28
-604
-97

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 3 col1 FROM tab2 AS cor0
----
10
81
82

query I rowsort
SELECT col0 * 50 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT ALL - col2 + + ( ( - col2 ) ) * + 64 * col0 FROM tab2 AS cor0
----
-12123
-129818
-192166

query I rowsort
SELECT DISTINCT + col0 * + 56 AS col2 FROM tab1 AS cor0
----
168
3584
4480

query I rowsort
SELECT ALL col1 + + col2 * col2 AS col1 FROM tab2 cor0
----
1461
735
760

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2699
SELECT DISTINCT + col0 + CAST( 52 AS SIGNED ) * col1 FROM tab1 AS cor0
----
1355
584
756

skipif mysql # not compatible
query I rowsort label-2699
SELECT DISTINCT + col0 + CAST ( 52 AS INTEGER ) * col1 FROM tab1 AS cor0
----
1355
584
756

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * - 9 + + col1 col2 FROM tab2 AS cor0
----
-32
-643
-694

query I rowsort
SELECT - - col0 * - 5 + + col2 AS col0 FROM tab0 cor0
----
-174
-363
-87

query I rowsort
SELECT ALL col2 * 92 FROM tab2 AS cor0
----
2392
2484
3496

query I rowsort
SELECT - + col1 * 81 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-6999
-7453
-7858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2705
SELECT DISTINCT + CAST( + 19 AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0
----
19

skipif mysql # not compatible
query I rowsort label-2705
SELECT DISTINCT + CAST ( + 19 AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0
----
19

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2707
SELECT + col1 DIV 97 + col1 * + 29 FROM tab2 cor0
----
1711
493
899

skipif mysql # not compatible
query I rowsort label-2707
SELECT + col1 / 97 + col1 * + 29 FROM tab2 cor0
----
1711
493
899

query I rowsort
SELECT ALL 59 + col1 FROM tab0 AS cor0
----
145
150
156

query I rowsort
SELECT ALL + col0 * 96 * + col2 AS col1 FROM tab2 AS cor0
----
18144
194688
288192

query I rowsort
SELECT DISTINCT 70 * col0 AS col1 FROM tab2 AS cor0
----
490
5460
5530

query I rowsort
SELECT - + 22 * - 19 * - cor0.col0 + - cor0.col2 FROM tab2 cor0
----
-2953
-32630
-33060

onlyif mysql # use DIV operator for integer division
query I rowsort label-2712
SELECT DISTINCT - col2 + col1 DIV - col2 FROM tab0 cor0
----
-35
-83
-98

skipif mysql # not compatible
query I rowsort label-2712
SELECT DISTINCT - col2 + col1 / - col2 FROM tab0 cor0
----
-35
-83
-98

query I rowsort
SELECT ALL + col1 + + col0 * - 78 AS col1 FROM tab2 AS cor0
----
-515
-6025
-6145

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2715
SELECT col0 DIV col2 - + col0 AS col0 FROM tab0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-2715
SELECT col0 / col2 - + col0 AS col0 FROM tab0
----
-24
-88
0

query I rowsort
SELECT + - 43 + col0 FROM tab0 AS cor0
----
-19
-8
46

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

query I rowsort
SELECT + 46 + ( col1 ) * + col2 AS col2 FROM tab2 AS cor0
----
1580
692
883

query I rowsort
SELECT col1 * ( 63 ) FROM tab1
----
1638
630
819

query I rowsort
SELECT ALL - ( - 65 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT + 64 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
64

query I rowsort
SELECT ( - 35 ) + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f5ce2f6c4600554ede59b436c886260f

query I rowsort
SELECT ALL - - cor0.col2 + - col0 * cor0.col0 AS col0 FROM tab1 cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL + ( - col1 ) * col1 + - col0 * - 18 AS col2 FROM tab0 AS cor0
----
-6679
-6964
-8779

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2725
SELECT ALL - CAST( col0 AS SIGNED ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2725
SELECT ALL - CAST ( col0 AS INTEGER ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2726
SELECT DISTINCT - 8 * + col2 + cor0.col2 DIV + ( + cor0.col0 * col1 ) + - col1 * + col1 DIV - col1 FROM tab2 AS cor0
----
-149
-185
-287

skipif mysql # not compatible
query I rowsort label-2726
SELECT DISTINCT - 8 * + col2 + cor0.col2 / + ( + cor0.col0 * col1 ) + - col1 * + col1 / - col1 FROM tab2 AS cor0
----
-149
-185
-287

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

skipif mysql # not compatible
query I rowsort label-2727
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) / cor0.col1 + cor0.col0 FROM tab2 AS cor0
----
NULL

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

skipif mysql # not compatible
query I rowsort label-2728
SELECT ALL CAST ( col1 AS INTEGER ) * col0 + col0 * col0 AS col1 FROM tab2 AS cor0
----
10686
266
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + col2 col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - - 64 * col2 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT - col2 * - 69 FROM tab2 AS cor0
----
1794
1863
2622

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 1 col2 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 78 * 32 + - cor0.col2 col1 FROM tab2 AS cor0
----
2458
2469
2470

query I rowsort
SELECT DISTINCT - + col2 * col0 + + col2 * ( cor0.col2 ) * col0 AS col0 FROM tab2 AS cor0
----
111074
4914
50700

query I rowsort
SELECT + col1 * + col0 * col1 FROM tab0
----
177504
329315
737009

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2737
SELECT DISTINCT col1 DIV col2 AS col1 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2737
SELECT DISTINCT col1 / col2 AS col1 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT + 59 + col0 * ( col1 ) AS col2 FROM tab1 AS cor0
----
1099
137
699

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

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

skipif mysql # not compatible
query I rowsort label-2740
SELECT col0 * + cor0.col2 / CAST ( NULL AS REAL ) + col1 + - cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT - + 11 * col1 + 75 AS col0 FROM tab0 AS cor0
----
-871
-926
-992

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

query I rowsort
SELECT - 90 + + col0 FROM tab1 AS cor0
----
-10
-26
-87

query I rowsort
SELECT DISTINCT - + 24 * - col0 AS col1 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT + col2 * - col0 + + 71 * 62 FROM tab1 AS cor0
----
-3278
4240
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 85 * + col1 col0 FROM tab1 AS cor0
----
-1105
-2210
-850

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

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

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

query I rowsort
SELECT ALL col2 + - col0 * col1 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT + col2 + ( col0 ) * cor0.col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - cor0.col2 + + 79 FROM tab0 cor0
----
-3
46
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2753
SELECT ALL + cor0.col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-2753
SELECT ALL + cor0.col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

onlyif mysql # use DIV operator for integer division
query I rowsort label-2754
SELECT - + cor0.col0 * col0 + cor0.col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-2754
SELECT - + cor0.col0 * col0 + cor0.col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2755
SELECT DISTINCT - col1 / col0 col1 FROM tab1 AS cor0
----
-8
0

query I rowsort
SELECT - col2 * - 50 FROM tab1
----
2700
2850
4800

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL col0 * + CAST ( col2 AS REAL ) * col1 col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - + col0 + 50 FROM tab0 AS cor0
----
-39
15
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + ( col0 ) col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT - col1 * + 61 + cor0.col2 * col0 AS col1 FROM tab0 AS cor0
----
-4454
-5882
1747

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * 27 + - 43 col2 FROM tab2 cor0
----
-1069
-745
-772

query I rowsort
SELECT col1 * col2 * + col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT 54 * + col0 AS col0 FROM tab1 AS cor0
----
162
3456
4320

query I rowsort
SELECT - cor0.col1 + col0 * col1 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT + + cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

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

query I rowsort
SELECT - col2 + - col2 - col2 FROM tab0 AS cor0
----
-246
-3
-99

query I rowsort
SELECT col1 + col0 * - col1 * col2 AS col1 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT - 39 * + col1 * - col2 + col0 * col2 + col0 FROM tab2 AS cor0
----
28275
32839
61932

query I rowsort
SELECT DISTINCT + col1 + col1 * + 68 + - col2 FROM tab0 AS cor0
----
5901
6197
6692

query I rowsort
SELECT + - 71 + - col0 FROM tab2 cor0
----
-149
-150
-78

query I rowsort
SELECT DISTINCT + - 42 FROM tab1 AS cor0
----
-42

query I rowsort
SELECT col1 * + col2 + + col0 AS col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT col0 + 50 AS col2 FROM tab0
----
139
74
85

query I rowsort
SELECT ALL col2 * - tab0.col1 * col1 + - 1 AS col1 FROM tab0
----
-244069
-679043
-9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-2777
SELECT 45 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2777
SELECT 45 / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - tab2.col1 * - col0 + col2 * - tab2.col2 * col0 AS col2 FROM tab2
----
-112733
-48126
-4886

query I rowsort
SELECT + col2 + - col0 + - 6 AS col0 FROM tab1 AS cor0
----
-13
10
45

query I rowsort
SELECT ALL 98 * - col1 AS col1 FROM tab0
----
-8428
-8918
-9506

query I rowsort
SELECT + ( + col1 ) * col2 + + 85 AS col1 FROM tab0 AS cor0
----
182
2923
7547

query I rowsort
SELECT ALL ( + tab2.col1 ) * + col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT - cor1.col0 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT 48 AS col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
48

query I rowsort
SELECT - 62 * 43 AS col1 FROM tab2 AS cor0
----
-2666
-2666
-2666

onlyif mysql # use DIV operator for integer division
query I rowsort label-2786
SELECT + - 45 DIV 21 FROM tab2 AS cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-2786
SELECT + - 45 / 21 FROM tab2 AS cor0
----
-2
-2
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2787
SELECT CAST( - 24 AS SIGNED ) DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2787
SELECT CAST ( - 24 AS INTEGER ) / col2 FROM tab1 AS cor0
----
0
0
0

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

query I rowsort
SELECT ALL 8 * ( col1 ) AS col0 FROM tab2 AS cor0
----
136
248
472

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

query I rowsort
SELECT ALL + 55 * col0 AS col1 FROM tab2
----
385
4290
4345

query I rowsort
SELECT ALL - 47 + + col1 FROM tab2 AS cor0
----
-16
-30
12

query I rowsort
SELECT ALL + col1 + col2 + + cor0.col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT + ( 86 ) FROM tab2 cor0
----
86
86
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2795
SELECT ALL + tab2.col1 DIV + 5 AS col1 FROM tab2
----
11
3
6

skipif mysql # not compatible
query I rowsort label-2795
SELECT ALL + tab2.col1 / + 5 AS col1 FROM tab2
----
11
3
6

query I rowsort
SELECT DISTINCT + 18 * - col1 FROM tab1
----
-180
-234
-468

query I rowsort
SELECT col2 * - tab2.col0 * + col2 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT + cor1.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2799
SELECT DISTINCT + col2 DIV - 25 FROM tab0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-2799
SELECT DISTINCT + col2 / - 25 FROM tab0
----
-1
-3
0

query I rowsort
SELECT col0 * col1 + 44 AS col1 FROM tab1 AS cor0
----
1084
122
684

onlyif mysql # use DIV operator for integer division
query I rowsort label-2801
SELECT DISTINCT col1 DIV + col2 + col0 AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2801
SELECT DISTINCT col1 / + col2 + col0 AS col0 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2802
SELECT + col2 * + col1 DIV col1 - + col1 * + col1 DIV - tab1.col1 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-2802
SELECT + col2 * + col1 / col1 - + col1 * + col1 / - tab1.col1 FROM tab1
----
109
67
80

query I rowsort
SELECT col2 + col2 * + col0 + + col1 * col0 * tab0.col0 FROM tab0
----
118861
50361
728191

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2806
SELECT ALL col2 + - col0 DIV + col2 FROM tab0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-2806
SELECT ALL col2 + - col0 / + col2 FROM tab0
----
-34
33
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2807
SELECT ALL + cor0.col1 * col0 * col2 + cor0.col0 DIV + cor0.col2 AS col2 FROM tab0 AS cor0
----
3430
664119
68112

skipif mysql # not compatible
query I rowsort label-2807
SELECT ALL + cor0.col1 * col0 * col2 + cor0.col0 / + cor0.col2 AS col2 FROM tab0 AS cor0
----
3430
664119
68112

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2809
SELECT ALL + col2 + - col0 DIV col1 AS col2 FROM tab1 AS cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-2809
SELECT ALL + col2 + - col0 / col1 AS col2 FROM tab1 AS cor0
----
51
54
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * col0 col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col1 * col2 + + col1 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

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

query I rowsort
SELECT ALL - col1 * col2 + col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT cor0.col2 * + col2 - - col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 * - cor0.col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - col1 - + col2 * + col2 * - col1 FROM tab0
----
0
611793
93568

query I rowsort
SELECT + - ( col1 ) * col0 + - col2 * - col2 + + col1 FROM tab2 AS cor0
----
-3867
118
543

query I rowsort
SELECT + 13 + - col1 + + col2 AS col2 FROM tab1 AS cor0
----
41
60
96

query I rowsort
SELECT + + col2 * - col0 + col0 - + col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-15308
-2832
-3395

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

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

query I rowsort
SELECT - 20 * - col0 - - col1 * col2 AS col0 FROM tab0 cor0
----
3318
797
9242

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

query I rowsort
SELECT DISTINCT + - cor0.col2 * col0 - col2 AS col2 FROM tab2 cor0
----
-2054
-216
-3040

query I rowsort
SELECT + cor0.col1 * col1 * col0 + col1 * col0 AS col2 FROM tab0 cor0
----
179568
332710
745108

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

query I rowsort
SELECT - col0 + - col2 * ( cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-196
-2106
-3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * col1 col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + + col1 * col1 + col2 AS col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT col2 + + cor0.col0 + cor0.col0 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT DISTINCT - - 54 * + cor0.col0 - col1 FROM tab0 AS cor0
----
1210
1793
4715

query I rowsort
SELECT DISTINCT - 18 + col0 FROM tab2 AS cor0
----
-11
60
61

query I rowsort
SELECT ALL col1 * cor0.col1 + + col0 + col0 FROM tab1 AS cor0
----
228
329
682

query I rowsort
SELECT ALL - 24 + + col1 AS col2 FROM tab2 AS cor0
----
-7
35
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col1 + 93 * + col2 * col2 col0 FROM tab2 AS cor0
----
135635
67470
68014

query I rowsort
SELECT 1 AS col0 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT - 37 * col2 + - col1 AS col0 FROM tab2
----
-1021
-1030
-1423

query I rowsort
SELECT DISTINCT tab1.col2 + - 1 FROM tab1
----
53
56
95

query I rowsort
SELECT 2 * + col2 + + col0 * tab1.col1 * - col0 AS col0 FROM tab1
----
-126
-40846
-83008

query I rowsort
SELECT DISTINCT + col2 * 11 + - col1 * 5 AS col0 FROM tab2
----
-9
142
333

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab0, tab1, tab1 AS cor0
----
54
57
96

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

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

query I rowsort
SELECT 22 + col2 AS col1 FROM tab0
----
104
23
55

skipif mysql # not compatible
query I rowsort
SELECT ALL + - col0 * col1 + CAST ( + col0 AS REAL ) * col2 FROM tab1 AS cor0
----
3008
6640
84

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

query I rowsort
SELECT + 95 + col0 * - 74 AS col1 FROM tab1 AS cor0
----
-127
-4641
-5825

query I rowsort
SELECT DISTINCT col2 * - col2 * col0 - - col1 FROM tab0
----
-26050
-598345
62

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

query I rowsort
SELECT 42 * + col0 - + col1 * - col2 FROM tab1 AS cor0
----
1530
3258
4608

query I rowsort
SELECT ALL col1 - ( col2 ) AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL col2 * - col0 + col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT ALL + + ( col1 ) * - cor0.col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + 70 + col0 * - tab2.col2 FROM tab2
----
-119
-1958
-2932

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab2, tab0 cor0, tab2 cor1
----
-17
-31
-59

query I rowsort
SELECT DISTINCT 52 * + col1 + - col0 AS col2 FROM tab1
----
1349
456
596

query I rowsort
SELECT ALL - ( col0 ) + - col1 + - ( 4 ) * - tab1.col1 * col1 AS col0 FROM tab1
----
2675
326
583

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

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

query I rowsort
SELECT ALL - ( - col0 ) * cor0.col1 - - col2 * - 80 FROM tab0 AS cor0
----
-576
1539
3315

query I rowsort
SELECT DISTINCT - 4 * cor0.col2 + col1 AS col2 FROM tab2 AS cor0
----
-135
-45
-77

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

query I rowsort
SELECT ALL 97 - + 22 * cor0.col2 FROM tab0 AS cor0
----
-1707
-629
75

query I rowsort
SELECT ALL cor1.col1 * - cor1.col1 * 67 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 018a89dc984e34825b0173a5a131b33e

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ( - col0 ) - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + 79 AS col0 FROM tab0 cor0
----
79

query I rowsort
SELECT ( + 89 ) + - col2 * 21 * - 3 + + col1 AS col2 FROM tab1 cor0
----
3517
3690
6150

query I rowsort
SELECT col1 * + col0 + col0 * + col2 + + 16 FROM tab0 AS cor0
----
15413
2872
3446

query I rowsort
SELECT ALL - 57 + + 82 FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT 52 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1352
-520
-676

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

skipif mysql # not compatible
query I rowsort label-2872
SELECT + 58 * + col1 - col0 * - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT ALL - - 93 * 89 FROM tab1 AS cor0
----
8277
8277
8277

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

query I rowsort
SELECT ALL 8 * - col2 AS col2 FROM tab1 AS cor0
----
-432
-456
-768

query I rowsort
SELECT + - col0 + + col0 + + ( col0 ) * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col0 * col0 * - ( 3 ) - + col0 FROM tab0 cor0
----
-1752
-23852
-3710

query I rowsort
SELECT ALL 46 + cor1.col1 AS col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to b2650cba1f6aad67d3c0578c0cf263d2

query I rowsort
SELECT DISTINCT - + cor0.col2 * - 74 AS col2 FROM tab2 AS cor0
----
1924
1998
2812

query I rowsort
SELECT DISTINCT - col1 * 39 FROM tab2 AS cor0
----
-1209
-2301
-663

query I rowsort
SELECT + - cor0.col0 * 25 FROM tab2 AS cor0
----
-175
-1950
-1975

query I rowsort
SELECT DISTINCT - col1 * 51 FROM tab2 AS cor0
----
-1581
-3009
-867

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

query I rowsort
SELECT 13 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 27 + col2 col2 FROM tab1 cor0
----
165
81
87

query I rowsort
SELECT + ( - col0 ) * col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col0 * - 83 + tab2.col1 AS col0 FROM tab2
----
-550
-6415
-6540

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

query I rowsort
SELECT 97 + tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 02d2892b361fc3d06d5db36957de1116

query I rowsort
SELECT - cor0.col0 * + 59 + - col2 FROM tab1 AS cor0
----
-231
-3833
-4816

query I rowsort
SELECT - + cor0.col2 * 22 + - col0 FROM tab0 AS cor0
----
-1893
-57
-750

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

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

query I rowsort
SELECT + cor0.col1 + - 59 * - col1 AS col0 FROM tab1 AS cor0
----
1560
600
780

query I rowsort
SELECT cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

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

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

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

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 col1 FROM tab1 AS cor0
----
-46
-46
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-2902
SELECT ALL - 40 DIV 35 + cor0.col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-2902
SELECT ALL - 40 / 35 + cor0.col1 FROM tab1 AS cor0
----
12
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2903
SELECT 29 + + col0 DIV col0 AS col0 FROM tab0 AS cor0
----
30
30
30

skipif mysql # not compatible
query I rowsort label-2903
SELECT 29 + + col0 / col0 AS col0 FROM tab0 AS cor0
----
30
30
30

query I rowsort
SELECT 32 + col2 FROM tab2 AS cor0
----
58
59
70

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

skipif mysql # not compatible
query I rowsort label-2905
SELECT - cor0.col0 * col2 + CAST ( NULL AS REAL ) * + 46 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col1 * + col1 + + col1 * - col0 col2 FROM tab0
----
271
5356
6049

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

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

query I rowsort
SELECT - + 87 * - col2 + - col2 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT + 85 + col1 - col1 AS col1 FROM tab0 AS cor0
----
85
85
85

query I rowsort
SELECT DISTINCT + 3 * - col1 AS col2 FROM tab0 AS cor0
----
-258
-273
-291

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

query I rowsort
SELECT 52 + col1 + col0 FROM tab1 AS cor0
----
126
145
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2913
SELECT col2 DIV 60 AS col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2913
SELECT col2 / 60 AS col2 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2914
SELECT ALL col1 DIV col2 + + cor0.col0 FROM tab0 cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-2914
SELECT ALL col1 / col2 + + cor0.col0 FROM tab0 cor0
----
132
26
90

query I rowsort
SELECT DISTINCT col2 * - col1 * + col0 AS col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - cor0.col2 * - 21 + - col0 FROM tab2 cor0
----
468
560
719

query I rowsort
SELECT DISTINCT - cor0.col0 + ( - 63 ) FROM tab0 cor0
----
-152
-87
-98

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

skipif mysql # not compatible
query I rowsort label-2918
SELECT DISTINCT + - col1 + + CAST ( NULL AS INTEGER ) / ( col2 ) AS col0 FROM tab0 AS cor0
----
NULL

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

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

query I rowsort
SELECT ( - cor1.col1 ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - ( col2 ) - + col2 FROM tab1
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2922
SELECT ALL + col2 DIV col1 - ( - col0 + + col0 ) * - CAST( col2 AS SIGNED ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2922
SELECT ALL + col2 / col1 - ( - col0 + + col0 ) * - CAST ( col2 AS INTEGER ) FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 * - col2 + 31 AS col2 FROM tab0 AS cor0
----
66
7329
823

query I rowsort
SELECT + col1 * 33 + col2 * col0 AS col0 FROM tab2
----
1212
3563
3975

query I rowsort
SELECT DISTINCT col1 + - col0 + + col2 AS col2 FROM tab1
----
29
3
77

query I rowsort
SELECT col1 * + ( 88 + col2 ) FROM tab1
----
1450
2392
3692

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2927
SELECT DISTINCT - col0 + CAST( tab2.col2 * col2 AS SIGNED ) FROM tab2
----
1365
598
722

skipif mysql # not compatible
query I rowsort label-2927
SELECT DISTINCT - col0 + CAST ( tab2.col2 * col2 AS INTEGER ) FROM tab2
----
1365
598
722

query I rowsort
SELECT + tab1.col2 + col2 * - col0 * - tab1.col1 FROM tab1
----
36537
4266
99936

query I rowsort
SELECT + col0 * tab2.col0 - col1 FROM tab2
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-2930
SELECT col0 DIV col0 + col2 * - tab0.col1 * 73 FROM tab0
----
-207173
-544725
-7080

skipif mysql # not compatible
query I rowsort label-2930
SELECT col0 / col0 + col2 * - tab0.col1 * 73 FROM tab0
----
-207173
-544725
-7080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + 5 * 16 col1 FROM tab1
----
134
137
176

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

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

query I rowsort
SELECT 85 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT DISTINCT - 27 * + col2 - - col1 * col2 FROM tab2 cor0
----
-380
108
832

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

skipif mysql # not compatible
query I rowsort label-2936
SELECT ALL - + 45 * col1 + - CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT ALL - col2 - + cor0.col1 * cor0.col2 * + 60 FROM tab1 AS cor0
----
-34257
-74976
-84294

query I rowsort
SELECT - 19 + - 87 AS col0 FROM tab2
----
-106
-106
-106

query I rowsort
SELECT ALL + 2 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 2 + - col2 col1 FROM tab2 cor0
----
-24
-25
-36

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

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

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

query I rowsort
SELECT ALL + + 68 + col1 * - col1 AS col2 FROM tab0 AS cor0
----
-7328
-8213
-9341

query I rowsort
SELECT ALL - col2 * cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL - 73 + - col0 AS col2 FROM tab2 AS cor0
----
-151
-152
-80

query I rowsort
SELECT DISTINCT + + 80 * - col1 - 69 * col1 FROM tab2 AS cor0
----
-2533
-4619
-8791

onlyif mysql # use DIV operator for integer division
query I rowsort label-2948
SELECT DISTINCT - ( cor0.col1 ) + 7 + 83 DIV + col0 AS col1 FROM tab1 AS cor0
----
-2
-5
8

skipif mysql # not compatible
query I rowsort label-2948
SELECT DISTINCT - ( cor0.col1 ) + 7 + 83 / + col0 AS col1 FROM tab1 AS cor0
----
-2
-5
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2949
SELECT - col2 DIV - col2 + - ( col0 ) AS col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-2949
SELECT - col2 / - col2 + - ( col0 ) AS col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT ALL - + 58 * col0 AS col2 FROM tab1 AS cor0
----
-174
-3712
-4640

query I rowsort
SELECT + col0 + + col0 * - 38 AS col1 FROM tab2 cor0
----
-259
-2886
-2923

query I rowsort
SELECT DISTINCT + 67 * col2 AS col2 FROM tab2 AS cor0
----
1742
1809
2546

query I rowsort
SELECT ALL + 65 + col1 + col1 FROM tab2 AS cor0
----
127
183
99

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

query I rowsort
SELECT DISTINCT ( - 57 ) + - col2 FROM tab1 AS cor0
----
-111
-114
-153

query I rowsort
SELECT ALL + 10 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to bf75e71325a06683558cf93fd725ad16

query I rowsort
SELECT + cor0.col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 6 + - col0 * col1 AS col0 FROM tab0 AS cor0
----
-2058
-3389
-8093

query I rowsort
SELECT ( 96 ) - col2 AS col1 FROM tab0 AS cor0
----
14
63
95

query I rowsort
SELECT DISTINCT - col2 * 87 + + col2 AS col2 FROM tab1 AS cor0
----
-4644
-4902
-8256

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2961
SELECT + CAST( - col1 AS SIGNED ) * - col2 + - cor0.col2 + + col1 FROM tab1 cor0
----
1165
1376
523

skipif mysql # not compatible
query I rowsort label-2961
SELECT + CAST ( - col1 AS INTEGER ) * - col2 + - cor0.col2 + + col1 FROM tab1 cor0
----
1165
1376
523

query I rowsort
SELECT + 23 + + 23 - col2 AS col2 FROM tab1 cor0
----
-11
-50
-8

query I rowsort
SELECT + - 65 + + cor0.col1 * - 53 FROM tab1 AS cor0
----
-1443
-595
-754

query I rowsort
SELECT DISTINCT + col1 * - ( col1 ) + col2 FROM tab2
----
-251
-3455
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-2965
SELECT + col1 + - col0 DIV - tab2.col1 AS col2 FROM tab2
----
21
31
60

skipif mysql # not compatible
query I rowsort label-2965
SELECT + col1 + - col0 / - tab2.col1 AS col2 FROM tab2
----
21
31
60

query I rowsort
SELECT DISTINCT 56 + - 9 AS col0 FROM tab2
----
47

query I rowsort
SELECT - tab1.col0 * 46 + - col2 + - 11 AS col2 FROM tab1
----
-203
-3012
-3787

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2969
SELECT DISTINCT + col1 * - 63 + col0 DIV + col1 AS col2 FROM tab0 AS cor0
----
-5418
-5733
-6111

skipif mysql # not compatible
query I rowsort label-2969
SELECT DISTINCT + col1 * - 63 + col0 / + col1 AS col2 FROM tab0 AS cor0
----
-5418
-5733
-6111

query I rowsort
SELECT DISTINCT cor0.col2 * + 76 + - col1 FROM tab0 AS cor0
----
-21
2422
6141

query I rowsort
SELECT DISTINCT col0 * - col1 * col2 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-2972
SELECT ALL - + col1 DIV - 22 FROM tab0 AS cor0
----
3
4
4

skipif mysql # not compatible
query I rowsort label-2972
SELECT ALL - + col1 / - 22 FROM tab0 AS cor0
----
3
4
4

query I rowsort
SELECT + col1 * 74 FROM tab2 AS cor0
----
1258
2294
4366

query I rowsort
SELECT DISTINCT + col1 * 40 AS col0 FROM tab0 AS cor0
----
3440
3640
3880

query I rowsort
SELECT + col0 + - 67 FROM tab1 AS cor0
----
-3
-64
13

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + cor0.col0 * + CAST ( col2 AS REAL ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 cor1, tab1 AS cor2, tab1 AS cor3
----
243 values hashing to ee8b23a58dda2d92e14ed437e06ed8d2

query I rowsort
SELECT ALL 6 * - tab1.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 6c831792e43e43dff996e9b406056291

query I rowsort
SELECT - 0 AS col0 FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

onlyif mysql # use DIV operator for integer division
query I rowsort label-2981
SELECT + - col1 + col0 DIV - col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-2981
SELECT + - col1 + col0 / - col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 7 + col0 col2 FROM tab1 AS cor0
----
10
71
87

query I rowsort
SELECT ALL cor1.col1 * cor1.col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to aff311fa1b3948e179779cc03c1fade4

query I rowsort
SELECT + 63 * + col0 FROM tab2
----
441
4914
4977

query I rowsort
SELECT + ( - 25 ) * + col2 AS col2 FROM tab0 AS cor0
----
-2050
-25
-825

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

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

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

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

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

query I rowsort
SELECT ALL col1 * col2 - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

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

skipif mysql # not compatible
query I rowsort label-2991
SELECT + ( + col2 ) + 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 + col1 + + col0 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - col2 + - 60 FROM tab2 AS cor0
----
-86
-87
-98

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
13122 values hashing to 10f0de126ff468281b9ae982670b44ba

query I rowsort
SELECT 23 * 76 FROM tab2
----
1748
1748
1748

query I rowsort
SELECT DISTINCT cor0.col1 + + col1 * + cor0.col2 FROM tab2 cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2997
SELECT - cor0.col2 * - col1 + col0 * - CAST( + col1 AS SIGNED ) col2 FROM tab2 AS cor0
----
-3068
-697
620

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2997
SELECT - cor0.col2 * - col1 + col0 * - CAST ( + col1 AS INTEGER ) col2 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT 13 + col1 * + col2 FROM tab1
----
1261
1417
583

query I rowsort
SELECT DISTINCT + 17 + col0 FROM tab1
----
20
81
97

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

query I rowsort
SELECT + ( col2 * 76 ) FROM tab2
----
1976
2052
2888

query I rowsort
SELECT ALL - ( tab2.col1 ) * tab2.col1 + - col1 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT DISTINCT - 69 + - col0 AS col0 FROM tab0
----
-104
-158
-93

query I rowsort
SELECT ALL 79 * col1 + 50 FROM tab1 AS cor0
----
1077
2104
840

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

query I rowsort
SELECT + col2 + col2 * - col0 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + col0 * ( - col2 ) FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3008
SELECT - col2 + 92 DIV - cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
-34
-83

skipif mysql # not compatible
query I rowsort label-3008
SELECT - col2 + 92 / - cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
-34
-83

query I rowsort
SELECT + + col2 - 49 FROM tab0 AS cor0
----
-16
-48
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 28 + cor0.col1 * col0 col0 FROM tab1 AS cor0
----
106
1068
668

query I rowsort
SELECT col0 * 7 FROM tab2 AS cor0
----
49
546
553

query I rowsort
SELECT DISTINCT - + 72 - + 11 FROM tab1 AS cor0
----
-83

query I rowsort
SELECT DISTINCT + 35 FROM tab1 cor0
----
35

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

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

query I rowsort
SELECT ALL + col1 * - col2 + col0 * 95 * col2 AS col0 FROM tab1 AS cor0
----
13986
345990
728352

query I rowsort
SELECT ALL 16 + + cor0.col0 * col1 FROM tab2 AS cor0
----
1359
233
4618

query I rowsort
SELECT - ( - 75 ) - + col2 * 12 AS col1 FROM tab1 AS cor0
----
-1077
-573
-609

query I rowsort
SELECT DISTINCT - 12 + - col1 + col0 * ( + cor0.col0 ) FROM tab0 AS cor0
----
1116
478
7818

query I rowsort
SELECT + ( 72 ) * - col0 + - col2 AS col2 FROM tab1 AS cor0
----
-270
-4665
-5856

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

query I rowsort
SELECT ALL + - 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-3022
SELECT DISTINCT col1 * + col2 + col1 * CAST( NULL AS SIGNED ) + 3 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3022
SELECT DISTINCT col1 * + col2 + col1 * CAST ( NULL AS INTEGER ) + 3 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT 36 AS col1 FROM tab1, tab1 AS cor0
----
36

query I rowsort
SELECT ALL + 17 AS col0 FROM tab1 AS cor0
----
17
17
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3025
SELECT CAST( col1 AS SIGNED ) * - cor0.col1 + 9 AS col1 FROM tab1 cor0
----
-160
-667
-91

skipif mysql # not compatible
query I rowsort label-3025
SELECT CAST ( col1 AS INTEGER ) * - cor0.col1 + 9 AS col1 FROM tab1 cor0
----
-160
-667
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3026
SELECT - CAST( - 7 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
7
7
7

skipif mysql # not compatible
query I rowsort label-3026
SELECT - CAST ( - 7 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
7
7
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3027
SELECT - col1 DIV 1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-3027
SELECT - col1 / 1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT 54 - - cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 41e86a9764ba29c593f7c73b5760e18f

query I rowsort
SELECT ALL ( - col1 ) * - col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - cor0.col2 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-54
-57
-96

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

query I rowsort
SELECT ALL col2 + 53 - col1 FROM tab0
----
-43
0
44

query I rowsort
SELECT DISTINCT - 63 AS col0 FROM tab0 cor0
----
-63

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

query I rowsort
SELECT + col0 + col0 - col2 AS col1 FROM tab0 AS cor0
----
15
69
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 57 * + col0 col0 FROM tab1 AS cor0
----
171
3648
4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3037
SELECT DISTINCT + col0 * col0 - - col0 DIV + 57 FROM tab2
----
49
6085
6242

skipif mysql # not compatible
query I rowsort label-3037
SELECT DISTINCT + col0 * col0 - - col0 / + 57 FROM tab2
----
49
6085
6242

query I rowsort
SELECT ( col1 ) + + col1 AS col1 FROM tab1
----
20
26
52

query I rowsort
SELECT - col1 * - col0 + col2 + - tab0.col1 AS col0 FROM tab0
----
2011
3299
8090

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 50 + col2 col2 FROM tab0
----
148
169
223

query I rowsort
SELECT DISTINCT - col2 * + 75 - col1 AS col1 FROM tab1
----
-4076
-4285
-7213

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

skipif mysql # not compatible
query I rowsort label-3042
SELECT - CAST ( NULL AS REAL ) * + tab2.col0 + - col2 + col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3043
SELECT ALL + col2 + 69 DIV - col0 col2 FROM tab0 AS cor0
----
0
31
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3043
SELECT ALL + col2 + 69 / - col0 col2 FROM tab0 AS cor0
----
0
31
82

query I rowsort
SELECT ALL + col2 + - 85 AS col0 FROM tab2 AS cor0
----
-47
-58
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3045
SELECT + col0 DIV 89 col2 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3045
SELECT + col0 / 89 col2 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + cor0.col2 col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3047
SELECT ALL col2 * - cor0.col1 + col0 DIV col0 AS col2 FROM tab2 AS cor0
----
-1533
-645
-836

skipif mysql # not compatible
query I rowsort label-3047
SELECT ALL col2 * - cor0.col1 + col0 / col0 AS col2 FROM tab2 AS cor0
----
-1533
-645
-836

query I rowsort
SELECT ALL + 63 + col0 FROM tab2
----
141
142
70

query I rowsort
SELECT ALL + cor0.col1 + - 72 * + cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 8a5dca220a14a56eb2b08031d7f76332

onlyif mysql # use DIV operator for integer division
query I rowsort label-3050
SELECT DISTINCT + col2 DIV + 30 FROM tab1
----
1
3

skipif mysql # not compatible
query I rowsort label-3050
SELECT DISTINCT + col2 / + 30 FROM tab1
----
1
3

query I rowsort
SELECT tab0.col0 - - col0 * + col2 AS col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT - cor0.col0 + + 46 FROM tab0 AS cor0
----
-43
11
22

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3053
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / 79 col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
NULL

query I rowsort
SELECT + col0 * + col2 + col0 * - col0 * - tab2.col1 AS col0 FROM tab2
----
109099
1708
360984

query I rowsort
SELECT ALL + - col1 + col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-104
-1053
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-3056
SELECT DISTINCT cor0.col1 DIV 1 FROM tab0, tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3056
SELECT DISTINCT cor0.col1 / 1 FROM tab0, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + col0 * col1 + + 37 AS col1 FROM tab1 AS cor0
----
1077
115
677

query I rowsort
SELECT DISTINCT + cor0.col1 * - 41 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT DISTINCT col1 * + col0 + - col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL + col0 * - 61 AS col1 FROM tab1 AS cor0
----
-183
-3904
-4880

onlyif mysql # use DIV operator for integer division
query I rowsort label-3061
SELECT + cor0.col2 - 52 DIV - cor0.col1 FROM tab2 cor0
----
26
28
41

skipif mysql # not compatible
query I rowsort label-3061
SELECT + cor0.col2 - 52 / - cor0.col1 FROM tab2 cor0
----
26
28
41

query I rowsort
SELECT ALL - + col2 + ( col0 + col0 ) AS col2 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT ALL col2 + col0 * 81 AS col0 FROM tab2 AS cor0
----
594
6344
6437

query I rowsort
SELECT DISTINCT - + col2 + 93 * + 17 AS col1 FROM tab2 AS cor0
----
1543
1554
1555

query I rowsort
SELECT DISTINCT cor0.col2 * + col2 - 21 AS col2 FROM tab1 AS cor0
----
2895
3228
9195

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3066
SELECT col1 + CAST( + col2 + - col0 AS SIGNED ) * col2 AS col2 FROM tab1 AS cor0
----
-389
1549
2780

skipif mysql # not compatible
query I rowsort label-3066
SELECT col1 + CAST ( + col2 + - col0 AS INTEGER ) * col2 AS col2 FROM tab1 AS cor0
----
-389
1549
2780

query I rowsort
SELECT + col2 * + 66 + cor0.col2 FROM tab1 AS cor0
----
3618
3819
6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-3068
SELECT + 6 DIV - col0 + - col1 * - col2 DIV col2 + + col2 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-3068
SELECT + 6 / - col0 + - col1 * - col2 / col2 + + col2 FROM tab0
----
119
173
98

query I rowsort
SELECT - col2 * col1 * col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT - col2 + col1 * 75 AS col2 FROM tab2 AS cor0
----
1237
2298
4399

query I rowsort
SELECT ALL - col0 + 1 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT col2 * 29 FROM tab1 AS cor0
----
1566
1653
2784

query I rowsort
SELECT 39 + + col0 AS col1 FROM tab1 AS cor0
----
103
119
42

query I rowsort
SELECT ALL - + col2 + - col1 * - col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - + ( 12 ) * + col1 AS col2 FROM tab0 AS cor0
----
-1032
-1092
-1164

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

query I rowsort
SELECT + 97 * - 79 AS col0 FROM tab0 AS cor0
----
-7663
-7663
-7663

query I rowsort
SELECT - 48 + + col2 FROM tab1 AS cor0
----
48
6
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3079
SELECT ALL col2 DIV + 8 AS col1 FROM tab0 cor0
----
0
10
4

skipif mysql # not compatible
query I rowsort label-3079
SELECT ALL col2 / + 8 AS col1 FROM tab0 cor0
----
0
10
4

query I rowsort
SELECT + + col0 * 86 FROM tab2 AS cor0
----
602
6708
6794

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

query I rowsort
SELECT ALL - + ( + 51 ) AS col2 FROM tab0 AS cor0
----
-51
-51
-51

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

query I rowsort
SELECT DISTINCT - - cor0.col0 * + 59 FROM tab0 AS cor0
----
1416
2065
5251

query I rowsort
SELECT 19 * col0 AS col0 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT DISTINCT - 7 * - 13 AS col0 FROM tab1 AS cor0
----
91

query I rowsort
SELECT ALL - ( - col2 ) AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - 67 * + col0 AS col2 FROM tab0 AS cor0
----
-1608
-2345
-5963

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

query I rowsort
SELECT + 35 * 51 * - col0 FROM tab2 AS cor0
----
-12495
-139230
-141015

query I rowsort
SELECT ALL + - 8 * 26 FROM tab0, tab2 AS cor0
----
9 values hashing to 4f7ebccb5c898f16f67ec88b9d9ef7f0

query I rowsort
SELECT + ( 16 ) * - tab0.col1 * - col2 + col2 FROM tab0
----
119474
1553
45441

query I rowsort
SELECT 22 + col2 AS col1 FROM tab0 AS cor0
----
104
23
55

query I rowsort
SELECT - - cor0.col1 + + col0 + ( + ( - col2 ) ) AS col2 FROM tab1 AS cor0
----
-25
-3
17

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

query I rowsort
SELECT ALL + col2 * col0 + - col0 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL + ( 63 + + col1 ) AS col0 FROM tab2
----
122
80
94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3098
SELECT ALL - CAST( 53 AS SIGNED ) AS col1 FROM tab0
----
-53
-53
-53

skipif mysql # not compatible
query I rowsort label-3098
SELECT ALL - CAST ( 53 AS INTEGER ) AS col1 FROM tab0
----
-53
-53
-53

query I rowsort
SELECT ALL 87 FROM tab1, tab1 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT - 15 * col1 FROM tab2 cor0
----
-255
-465
-885

query I rowsort
SELECT tab0.col0 FROM tab0, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT DISTINCT 93 * col0 FROM tab2 AS cor0
----
651
7254
7347

query I rowsort
SELECT ALL 31 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT - + 51 + col2 FROM tab0 AS cor0
----
-18
-50
31

query I rowsort
SELECT ALL - 31 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

query I rowsort
SELECT DISTINCT ( - col2 ) * + col0 AS col1 FROM tab0
----
-35
-7298
-792

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT + ( - 24 ) * col2 * + 33 FROM tab0
----
-26136
-64944
-792

query I rowsort
SELECT - cor0.col1 + - ( 82 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 10d1e45c093a070d9a447bbb30e385fd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 28 + - 98 * + col0 + - ( col2 ) col0 FROM tab1 AS cor0
----
-320
-6301
-7908

query I rowsort
SELECT DISTINCT + ( - 13 ) FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
-13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * col0 col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - 79 + 93 * col2 FROM tab0 AS cor0
----
14
2990
7547

query I rowsort
SELECT - - 50 * cor0.col0 + col0 * col1 FROM tab2 AS cor0
----
5293
567
8502

query I rowsort
SELECT ALL + + 18 + - col1 AS col2 FROM tab2 AS cor0
----
-13
-41
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) * col0 * 84 + + col0 * - col2 col0 FROM tab1 AS cor0
----
-347712
-545280
-918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3118
SELECT DISTINCT CAST( + 88 AS SIGNED ) + - cor0.col2 FROM tab2 AS cor0
----
50
61
62

skipif mysql # not compatible
query I rowsort label-3118
SELECT DISTINCT CAST ( + 88 AS INTEGER ) + - cor0.col2 FROM tab2 AS cor0
----
50
61
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3119
SELECT ALL - col0 * 61 + - col1 DIV col0 AS col1 FROM tab1 cor0
----
-191
-3904
-4880

skipif mysql # not compatible
query I rowsort label-3119
SELECT ALL - col0 * 61 + - col1 / col0 AS col1 FROM tab1 cor0
----
-191
-3904
-4880

query I rowsort
SELECT DISTINCT + - col2 * - ( col0 ) + - cor0.col2 * col2 AS col2 FROM tab1 cor0
----
-1536
-2754
399

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

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

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

query I rowsort
SELECT DISTINCT col1 * - 37 FROM tab1 AS cor0
----
-370
-481
-962

query I rowsort
SELECT col1 + 42 AS col1 FROM tab2 AS cor0
----
101
59
73

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

query I rowsort
SELECT ALL - + col1 * - ( + 10 ) * cor0.col0 + col2 + col0 FROM tab1 cor0
----
10576
6521
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3128
SELECT + col0 DIV + ( + col0 ) + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-3128
SELECT + col0 / + ( + col0 ) + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-16
-30
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3129
SELECT DISTINCT col2 * col1 DIV col0 FROM tab0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-3129
SELECT DISTINCT col2 * col1 / col0 FROM tab0
----
118
2
83

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

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

query I rowsort
SELECT + - col0 - 39 AS col0 FROM tab2 AS cor0
----
-117
-118
-46

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

query I rowsort
SELECT col2 * 99 + cor0.col1 + col1 FROM tab1 AS cor0
----
5398
5663
9530

query I rowsort
SELECT ALL col1 - - ( - col0 ) * + col2 AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - 16 * cor0.col2 * + ( cor0.col2 ) FROM tab0 AS cor0
----
-107584
-16
-17424

query I rowsort
SELECT DISTINCT + 73 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-3942
-4161
-7008

query I rowsort
SELECT ALL - 67 AS col2 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 95c9eba643f6489e03be4d5e83f1ef99

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
24
35
89

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

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

query I rowsort
SELECT + col2 * cor0.col2 * - ( 36 ) FROM tab1 AS cor0
----
-104976
-116964
-331776

query I rowsort
SELECT DISTINCT col1 * col2 - col0 * - col2 FROM tab0 AS cor0
----
132
14760
3630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3144
SELECT ALL col1 + - col1 DIV - col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-3144
SELECT ALL col1 + - col1 / - col1 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 * + col0 col2 FROM tab1 cor0
----
36
768
960

query I rowsort
SELECT DISTINCT + - cor0.col0 - + col2 * col2 FROM tab2 cor0
----
-1523
-736
-754

query I rowsort
SELECT ALL + 38 * - col2 FROM tab0 AS cor0
----
-1254
-3116
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3148
SELECT DISTINCT + - col2 DIV + cor0.col0 + cor0.col2 * - col2 * + col0 FROM tab0 AS cor0
----
-26137
-35
-598436

skipif mysql # not compatible
query I rowsort label-3148
SELECT DISTINCT + - col2 / + cor0.col0 + cor0.col2 * - col2 * + col0 FROM tab0 AS cor0
----
-26137
-35
-598436

query I rowsort
SELECT DISTINCT + col2 * + col1 * col2 AS col2 FROM tab2 cor0
----
22599
24548
39884

query I rowsort
SELECT ALL + col0 + + col0 + - col0 * col0 FROM tab1 AS cor0
----
-3
-3968
-6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-3151
SELECT ALL - tab2.col2 + tab2.col2 * + col0 + + tab2.col2 DIV col1 AS col0 FROM tab2
----
162
2002
2966

skipif mysql # not compatible
query I rowsort label-3151
SELECT ALL - tab2.col2 + tab2.col2 * + col0 + + tab2.col2 / col1 AS col0 FROM tab2
----
162
2002
2966

query I rowsort
SELECT 89 + col2 + cor0.col1 * - col2 FROM tab1 AS cor0
----
-1063
-1261
-424

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

query I rowsort
SELECT ALL ( ( + col1 ) ) + col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL - 6 + 21 AS col0 FROM tab2
----
15
15
15

query I rowsort
SELECT ALL col1 + - 18 FROM tab1
----
-5
-8
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3157
SELECT CAST( 97 AS SIGNED ) + col0 DIV + col2 FROM tab1 AS cor0
----
97
97
98

skipif mysql # not compatible
query I rowsort label-3157
SELECT CAST ( 97 AS INTEGER ) + col0 / + col2 FROM tab1 AS cor0
----
97
97
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 19 ) * - col2 col2 FROM tab0 AS cor0
----
-1558
-19
-627

query I rowsort
SELECT + + ( col0 ) * - col1 + - col1 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL - 10 * + col1 FROM tab2 AS cor0
----
-170
-310
-590

query I rowsort
SELECT ALL + col1 * col0 + col0 - + col1 AS col0 FROM tab1 AS cor0
----
1107
55
694

query I rowsort
SELECT - 56 * - col2 + col1 * - col0 * col1 AS col0 FROM tab1 cor0
----
-3208
-8144
996

query I rowsort
SELECT col1 + 25 * col2 FROM tab2 AS cor0
----
706
709
967

query I rowsort
SELECT ALL + + col0 + 69 * col0 AS col0 FROM tab1 AS cor0
----
210
4480
5600

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

query I rowsort
SELECT ALL - col2 * col1 * - col2 FROM tab1 cor0
----
119808
32490
75816

query I rowsort
SELECT col1 + + col1 * col2 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT 89 + col2 FROM tab1 AS cor0
----
143
146
185

query I rowsort
SELECT - col1 + col2 * col2 AS col0 FROM tab0 cor0
----
-96
1003
6633

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-3171
SELECT ALL + col0 + - col1 * - col1 DIV col1 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-3171
SELECT ALL + col0 + - col1 * - col1 / col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL col0 + - col1 * + cor0.col0 FROM tab2 AS cor0
----
-1264
-210
-4524

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

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

query I rowsort
SELECT + 43 * + col0 AS col1 FROM tab0 AS cor0
----
1032
1505
3827

query I rowsort
SELECT - col1 + 31 * + col2 AS col2 FROM tab2
----
1161
747
806

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

query I rowsort
SELECT DISTINCT 84 + col0 AS col2 FROM tab2 AS cor0
----
162
163
91

query I rowsort
SELECT + col0 - col1 * tab0.col1 FROM tab0
----
-7372
-8192
-9374

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

query I rowsort
SELECT DISTINCT - col2 * - 14 + + col1 AS col0 FROM tab1
----
1357
782
808

query I rowsort
SELECT 5 + - 15 AS col1 FROM tab1 AS cor0
----
-10
-10
-10

query I rowsort
SELECT ( + 15 ) * - col1 FROM tab1 AS cor0
----
-150
-195
-390

onlyif mysql # use DIV operator for integer division
query I rowsort label-3184
SELECT cor1.col1 DIV - ( - 93 ) FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-3184
SELECT cor1.col1 / - ( - 93 ) FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT - 77 FROM tab2, tab2 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

query I rowsort
SELECT col1 + - 55 FROM tab1
----
-29
-42
-45

query I rowsort
SELECT ALL + ( 2 ) FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 6d1be3904d6870ba21bc766b979d1110

onlyif mysql # use DIV operator for integer division
query I rowsort label-3188
SELECT DISTINCT - ( tab2.col1 ) DIV col0 FROM tab2
----
-4
0

skipif mysql # not compatible
query I rowsort label-3188
SELECT DISTINCT - ( tab2.col1 ) / col0 FROM tab2
----
-4
0

query I rowsort
SELECT DISTINCT + col1 * + 54 AS col1 FROM tab2
----
1674
3186
918

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

query I rowsort
SELECT DISTINCT + ( - 3 ) * + col2 AS col2 FROM tab0 AS cor0
----
-246
-3
-99

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

query I rowsort
SELECT ( col0 * 65 ) + col2 * - col1 AS col0 FROM tab0
----
-1278
-1677
2178

query I rowsort
SELECT - tab2.col0 + + col0 * - col0 * + 75 AS col1 FROM tab2
----
-3682
-456378
-468154

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

query I rowsort
SELECT col1 + col1 + - col1 * col1 FROM tab0
----
-7224
-8099
-9215

query I rowsort
SELECT + col0 * + cor0.col0 + col2 * - cor0.col0 FROM tab1 AS cor0
----
-1280
-153
448

query I rowsort
SELECT - col1 * col0 + 96 AS col1 FROM tab2 AS cor0
----
-121
-1247
-4506

query I rowsort
SELECT DISTINCT - + 98 FROM tab0 AS cor0
----
-98

query I rowsort
SELECT 17 * col2 AS col1 FROM tab1
----
1632
918
969

query I rowsort
SELECT DISTINCT + 33 + + tab1.col2 AS col2 FROM tab1
----
129
87
90

query I rowsort
SELECT col0 * + col2 + ( - col0 ) AS col0 FROM tab1
----
159
3584
7600

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 + cor0.col2 col0 FROM tab0 cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 33 col1 FROM tab0 AS cor0
----
1155
2937
792

query I rowsort
SELECT cor0.col0 + + col1 + col0 FROM tab0 AS cor0
----
134
167
269

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

skipif mysql # not compatible
query I rowsort label-3207
SELECT ALL col0 + - CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * ( - col1 + + col1 ) FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - col1 + - cor0.col2 + col2 * + col1 FROM tab0 AS cor0
----
193
2891
7471

onlyif mysql # use DIV operator for integer division
query I rowsort label-3210
SELECT + col1 DIV 2 + + col2 * cor0.col1 * + col0 + + col1 * - cor0.col0 FROM tab1 AS cor0
----
35845
4147
98806

skipif mysql # not compatible
query I rowsort label-3210
SELECT + col1 / 2 + + col2 * cor0.col1 * + col0 + + col1 * - cor0.col0 FROM tab1 AS cor0
----
35845
4147
98806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col1 col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT 91 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT col1 * + ( + col0 ) + - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT + 75 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT + col0 + + 57 AS col0 FROM tab1 AS cor0
----
121
137
60

query I rowsort
SELECT - + col1 + - col0 * - 5 AS col1 FROM tab1 AS cor0
----
-11
310
387

query I rowsort
SELECT - ( 47 ) * + col1 FROM tab0 AS cor0
----
-4042
-4277
-4559

query I rowsort
SELECT - col0 * col2 + col1 * cor0.col0 * 11 FROM tab0 AS cor0
----
21912
37310
81791

query I rowsort
SELECT - col2 + - 33 AS col0 FROM tab2 AS cor0
----
-59
-60
-71

query I rowsort
SELECT + + ( col2 ) + col0 * col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT ALL tab1.col1 * - col0 + - col1 FROM tab1
----
-104
-1053
-650

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

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

query I rowsort
SELECT + + 22 * + col0 + col0 FROM tab1 cor0
----
1472
1840
69

query I rowsort
SELECT DISTINCT + + col1 * + 47 FROM tab2 AS cor0
----
1457
2773
799

query I rowsort
SELECT DISTINCT + col0 + - 27 FROM tab2 cor0
----
-20
51
52

query I rowsort
SELECT + cor0.col2 * - col2 - col1 * col2 AS col0 FROM tab1 AS cor0
----
-10464
-3819
-4320

query I rowsort
SELECT ( col2 ) + 20 + - 75 * + col1 FROM tab2 AS cor0
----
-1217
-2278
-4379

query I rowsort
SELECT col2 * + col1 * ( + col1 ) FROM tab2
----
10982
25947
90506

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

query I rowsort
SELECT DISTINCT + + col2 + col0 * + 23 * col1 FROM tab2 AS cor0
----
105872
30927
5018

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

query I rowsort
SELECT ALL + col0 * - col0 * - col0 FROM tab1
----
262144
27
512000

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

query I rowsort
SELECT - + cor0.col2 * 57 - + col0 FROM tab0 AS cor0
----
-1905
-4763
-92

query I rowsort
SELECT + - 84 * col1 FROM tab2 AS cor0
----
-1428
-2604
-4956

query I rowsort
SELECT + - 85 + col2 AS col2 FROM tab0 cor0
----
-3
-52
-84

query I rowsort
SELECT + 17 + - col2 AS col1 FROM tab1 AS cor0
----
-37
-40
-79

query I rowsort
SELECT - col2 * - col1 * 25 FROM tab1 AS cor0
----
14250
31200
35100

query I rowsort
SELECT - col0 * col0 * 64 AS col0 FROM tab0 AS cor0
----
-36864
-506944
-78400

query I rowsort
SELECT DISTINCT - 1 * - cor0.col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3241
SELECT ALL - col2 DIV cor0.col2 col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3241
SELECT ALL - col2 / cor0.col2 col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + ( col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 76 col1 FROM tab0 cor0
----
76

query I rowsort
SELECT - col2 * 78 FROM tab1 AS cor0
----
-4212
-4446
-7488

onlyif mysql # use DIV operator for integer division
query I rowsort label-3246
SELECT - col1 DIV + ( + col1 * col0 ) - col0 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3246
SELECT - col1 / + ( + col1 * col0 ) - col0 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + col2 + 28 * 3 AS col1 FROM tab1 AS cor0
----
138
141
180

query I rowsort
SELECT col2 * - col0 + + 86 FROM tab1
----
-3562
-7594
-76

query I rowsort
SELECT ALL - 39 * - col1 AS col0 FROM tab2
----
1209
2301
663

query I rowsort
SELECT ALL - 55 + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-104
-6139
-6296

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

query I rowsort
SELECT DISTINCT cor0.col2 * 9 FROM tab0, tab1 AS cor0
----
486
513
864

query I rowsort
SELECT ( col0 * col2 ) AS col2 FROM tab0
----
35
7298
792

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

query I rowsort
SELECT + + 94 AS col0 FROM tab1 AS cor0
----
94
94
94

query I rowsort
SELECT ( tab0.col0 ) + col0 AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT - ( - tab2.col0 ) - col2 AS col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT 57 + col0 AS col0 FROM tab1
----
121
137
60

query I rowsort
SELECT ALL col0 * 97 + col2 AS col2 FROM tab1
----
345
6265
7856

query I rowsort
SELECT - - cor1.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col0 ) + col0 col0 FROM tab2 cor0
----
14
156
158

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

query I rowsort
SELECT - ( + col2 ) * col1 + 54 FROM tab1
----
-1194
-1350
-516

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

skipif mysql # not compatible
query I rowsort label-3264
SELECT + CAST ( NULL AS INTEGER ) + + col0 * col2 / - 7 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab1, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + + cor0.col1 + - col1 * + col2 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT + 71 + col1 AS col0 FROM tab0 cor0
----
157
162
168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - 1 * col2 col0 FROM tab0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - cor0.col2 * - col2 * + col2 col2 FROM tab0 AS cor0
----
0
35904
551286

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

skipif mysql # not compatible
query I rowsort label-3270
SELECT DISTINCT + - col1 * CAST ( - col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

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

skipif mysql # not compatible
query I rowsort label-3271
SELECT - col0 / CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col2 * cor1.col1 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
9 values hashing to 3aa3dc9c06ac75ec040ed5bc20953cf9

query I rowsort
SELECT DISTINCT - + ( col2 ) * col2 * col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT + + col0 + - 97 FROM tab2 AS cor0
----
-18
-19
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3275
SELECT DISTINCT + 3 * col1 * + col0 + - CAST( cor0.col2 AS SIGNED ) FROM tab1 AS cor0
----
180
1863
3024

skipif mysql # not compatible
query I rowsort label-3275
SELECT DISTINCT + 3 * col1 * + col0 + - CAST ( cor0.col2 AS INTEGER ) FROM tab1 AS cor0
----
180
1863
3024

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

query I rowsort
SELECT - - 28 + col0 AS col0 FROM tab0 AS cor0
----
117
52
63

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

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

query I rowsort
SELECT ALL 81 AS col2 FROM tab2 AS cor0
----
81
81
81

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + 86 col0 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT 57 + col2 FROM tab2 cor0
----
83
84
95

query I rowsort
SELECT + + 73 FROM tab1 cor0
----
73
73
73

query I rowsort
SELECT DISTINCT - - col2 - - 90 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT DISTINCT 85 + - col2 + col1 FROM tab2 cor0
----
118
64
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 46 * - col2 col1 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT ALL + col0 + - 28 + + col1 AS col0 FROM tab0 AS cor0
----
104
152
82

query I rowsort
SELECT DISTINCT + col0 * col1 + + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT DISTINCT ( + 93 ) + + col0 * - col2 * col0 AS col2 FROM tab2 AS cor0
----
-1230
-158091
-237065

query I rowsort
SELECT + + cor0.col1 * + col2 + col1 * + col2 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT ALL - ( 31 ) FROM tab2 AS cor0
----
-31
-31
-31

query I rowsort
SELECT + + col2 * col0 * + cor0.col1 + - col1 * col2 AS col2 FROM tab2 AS cor0
----
118118
5022
50388

query I rowsort
SELECT col2 + - 72 FROM tab0 AS cor0
----
-39
-71
10

query I rowsort
SELECT DISTINCT - 96 * 29 + + col1 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-1380
-1536
-2214

query I rowsort
SELECT 34 + col0 FROM tab2 AS cor0
----
112
113
41

query I rowsort
SELECT ALL + col1 * col1 + col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + cor0.col1 * col1 + + col2 * - col2 * - col2 FROM tab1 AS cor0
----
158140
185293
884905

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col0 * col1 col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - col1 * col1 + col0 * - col0 AS col0 FROM tab1
----
-4196
-6569
-685

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE ( col0 + col0 ) = ( + col1 )
----

query I rowsort
SELECT col2 + col2 FROM tab0 cor0 WHERE NOT ( - col0 * + col0 + col0 ) NOT BETWEEN NULL AND ( - col2 )
----

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL > col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3305
SELECT ALL col0 DIV col2 + col1 * col2 FROM tab0
----
132
2838
7463

skipif mysql # not compatible
query I rowsort label-3305
SELECT ALL col0 / col2 + col1 * col2 FROM tab0
----
132
2838
7463

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

query I rowsort
SELECT tab0.col1 FROM tab0 WHERE + col1 * col1 BETWEEN + col1 AND + col2
----

query I rowsort
SELECT ALL + col0 * + col0 * col2 + col0 AS col0 FROM tab2
----
1330
158262
237237

query I rowsort
SELECT + tab1.col1 * col1 * + tab1.col1 AS col0 FROM tab1 WHERE NOT + col2 * + col2 NOT IN ( + col1 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 * tab1.col2 col2 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + tab1.col0 col0 FROM tab1
----
29
74
93

query I rowsort
SELECT col2 FROM tab0 WHERE ( + col0 ) = + col1
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL <> col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3315
SELECT DISTINCT tab0.col1 DIV - col1 + + col2 * col2 AS col2 FROM tab0
----
0
1088
6723

skipif mysql # not compatible
query I rowsort label-3315
SELECT DISTINCT tab0.col1 / - col1 + + col2 * col2 AS col2 FROM tab0
----
0
1088
6723

onlyif mysql # use DIV operator for integer division
query I rowsort label-3316
SELECT DISTINCT col1 DIV tab0.col1 - col0 * col0 DIV - tab0.col2 AS col2 FROM tab0
----
1226
18
97

skipif mysql # not compatible
query I rowsort label-3316
SELECT DISTINCT col1 / tab0.col1 - col0 * col0 / - tab0.col2 AS col2 FROM tab0
----
1226
18
97

query I rowsort
SELECT DISTINCT + col0 * - col2 + + col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-357
124
1947

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-3320
SELECT DISTINCT - + col2 + col1 DIV - col0 AS col1 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-3320
SELECT DISTINCT - + col2 + col1 / - col0 AS col1 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT + + col1 + - col1 * col1 AS col2 FROM tab2 AS cor0
----
-272
-3422
-930

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

skipif mysql # not compatible
query I rowsort label-3322
SELECT col0 / + tab0.col0 FROM tab0
----
1
1
1

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

query I rowsort
SELECT - col0 - col1 * tab0.col1 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT + col0 + - col1 + + col2 AS col2 FROM tab2
----
100
3
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3326
SELECT DISTINCT col1 * - col0 + tab0.col2 DIV + col0 - + col0 FROM tab0
----
-2087
-3430
-8188

skipif mysql # not compatible
query I rowsort label-3326
SELECT DISTINCT col1 * - col0 + tab0.col2 / + col0 - + col0 FROM tab0
----
-2087
-3430
-8188

query I rowsort
SELECT ALL - tab0.col2 - - col2 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 + - col1 + col0 * + col0 AS col0 FROM tab2
----
25
6103
6303

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) NOT BETWEEN ( + col2 * col0 ) AND ( NULL )
----

query I rowsort
SELECT DISTINCT + col1 * col0 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - cor0.col1 + + col1 * + col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT + col0 + col1 * + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT + col1 DIV col0 - + col0 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-3333
SELECT + col1 / col0 - + col0 FROM tab0 AS cor0
----
-21
-33
-88

query I rowsort
SELECT + col2 * col1 + + col1 * + col1 AS col1 FROM tab0 AS cor0
----
10234
15743
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3335
SELECT - + col0 * + col1 DIV + col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3335
SELECT - + col0 * + col1 / + col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + tab1.col2 + cor0.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 08980ba33c72425c650f4b0533f5a9d7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3337
SELECT + col1 DIV + tab0.col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3337
SELECT + col1 / + tab0.col2 FROM tab0
----
1
2
97

query I rowsort
SELECT - col0 * + 64 * - 14 - col2 AS col1 FROM tab2 AS cor0
----
6245
69862
70746

query I rowsort
SELECT 16 * tab0.col0 FROM tab0
----
1424
384
560

query I rowsort
SELECT ALL - 31 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + + col1 * - col2 col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - col0 * + col1 * 75 + col2 AS col0 FROM tab0 cor0
----
-154767
-254624
-607343

onlyif mysql # use DIV operator for integer division
query I rowsort label-3343
SELECT - cor0.col1 + + cor0.col0 DIV - col2 FROM tab0 AS cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-3343
SELECT - cor0.col1 + + cor0.col0 / - col2 FROM tab0 AS cor0
----
-132
-86
-92

query I rowsort
SELECT col1 * 28 - 95 FROM tab2 AS cor0
----
1557
381
773

query I rowsort
SELECT + + col0 * col1 * + col0 + - cor0.col0 + col1 AS col1 FROM tab1 cor0
----
257
40906
83133

query I rowsort
SELECT ALL - col1 * - col0 - tab0.col2 * col1 AS col1 FROM tab0 WHERE NULL > + col0
----

query I rowsort
SELECT col1 + - col1 * tab0.col2 * col1 FROM tab0
----
-243982
-678951
-9312

query I rowsort
SELECT DISTINCT col2 - - col2 * - col1 * col1 AS col2 FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT col2 + col2 + + col1 FROM tab2
----
111
85
93

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col0 * + col2 * col2 >= NULL
----

query I rowsort
SELECT DISTINCT tab1.col0 FROM tab1 WHERE - col2 IN ( tab1.col2 * - col2 * tab1.col1 )
----

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

query I rowsort
SELECT DISTINCT col0 + - col1 * tab1.col2 AS col2 FROM tab1
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3354
SELECT + col1 DIV col1 + + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-3354
SELECT + col1 / col1 + + col2 FROM tab1
----
55
58
97

query I rowsort
SELECT ALL - tab0.col1 + - 98 AS col0 FROM tab0
----
-184
-189
-195

onlyif mysql # use DIV operator for integer division
query I rowsort label-3356
SELECT - col0 * col0 - col2 * + col1 DIV + ( + col1 ) FROM tab1
----
-4153
-63
-6496

skipif mysql # not compatible
query I rowsort label-3356
SELECT - col0 * col0 - col2 * + col1 / + ( + col1 ) FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT cor0.col2 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + ( col2 ) + - tab1.col1 col1 FROM tab1
----
2890
3239
9203

query I rowsort
SELECT DISTINCT col1 + + ( - col0 + col2 ) * 85 FROM tab2
----
-3468
-4361
1731

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3360
SELECT ALL col1 * CAST( + col1 AS SIGNED ) * + col1 + col0 AS col1 FROM tab0
----
636080
753660
912708

skipif mysql # not compatible
query I rowsort label-3360
SELECT ALL col1 * CAST ( + col1 AS INTEGER ) * + col1 + col0 AS col1 FROM tab0
----
636080
753660
912708

query I rowsort
SELECT - col0 + 78 * - 34 FROM tab1
----
-2655
-2716
-2732

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3362
SELECT DISTINCT CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3362
SELECT DISTINCT CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - + ( ( - col0 ) ) * + 72 + + col0 AS col1 FROM tab1 cor0
----
219
4672
5840

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3365
SELECT CAST( + col1 + - col2 AS SIGNED ) FROM tab1
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-3365
SELECT CAST ( + col1 + - col2 AS INTEGER ) FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + ( 37 ) FROM tab0
----
37

query I rowsort
SELECT DISTINCT - - col2 * - col1 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-3370
SELECT ALL + - ( col2 ) + + col2 DIV col2 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-3370
SELECT ALL + - ( col2 ) + + col2 / col2 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT ALL - col1 + cor0.col2 * col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

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

query I rowsort
SELECT DISTINCT + col0 * - cor0.col0 + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL + 33 * + col0 AS col1 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT DISTINCT - col1 + + col1 * col1 AS col1 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3376
SELECT ALL - + col1 DIV cor0.col1 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3376
SELECT ALL - + col1 / cor0.col1 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT + 14 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-1204
-1274
-1358

query I rowsort
SELECT - 3 * - col0 * + col0 AS col1 FROM tab0 AS cor0
----
1728
23763
3675

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( 7 AS REAL ) FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT - col2 - - col1 * col2 AS col0 FROM tab2 AS cor0
----
1508
608
810

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-3382
SELECT ALL ( col2 ) DIV 79 - col0 FROM tab1 AS cor0
----
-3
-64
-79

skipif mysql # not compatible
query I rowsort label-3382
SELECT ALL ( col2 ) / 79 - col0 FROM tab1 AS cor0
----
-3
-64
-79

query I rowsort
SELECT - + col0 * - col0 + 35 AS col1 FROM tab1 AS cor0
----
4131
44
6435

query I rowsort
SELECT 97 * col0 * - col1 + + col2 FROM tab0 AS cor0
----
-200175
-329314
-785521

query I rowsort
SELECT DISTINCT - + 71 * + col2 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT + col0 * - col1 + 58 + col0 FROM tab0 AS cor0
----
-1982
-3302
-7952

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

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

query I rowsort
SELECT DISTINCT + col2 - + 73 FROM tab0 AS cor0
----
-40
-72
9

query I rowsort
SELECT + - col2 + cor0.col2 + - col0 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT col2 * - ( + col2 ) AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + - col2 + 23 FROM tab0 AS cor0
----
-10
-59
22

query I rowsort
SELECT 47 AS col1 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT + cor0.col0 + 2 - + col1 AS col2 FROM tab1 AS cor0
----
-21
56
69

query I rowsort
SELECT DISTINCT - col1 + 78 * col1 FROM tab0 AS cor0
----
6622
7007
7469

query I rowsort
SELECT ALL + col1 + 91 FROM tab1 cor0
----
101
104
117

onlyif mysql # use DIV operator for integer division
query I rowsort label-3396
SELECT - col1 DIV CAST( cor0.col0 + + col2 * col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3396
SELECT - col1 / CAST ( cor0.col0 + + col2 * col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
0
0
0

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

query I rowsort
SELECT - + col1 * col0 + col2 + - col1 FROM tab1 AS cor0
----
-50
-593
-957

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

query I rowsort
SELECT DISTINCT - col2 + 80 FROM tab1 cor0
----
-16
23
26

query I rowsort
SELECT col0 + cor0.col0 - col1 FROM tab2 AS cor0
----
-17
141
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL - col2 * col1 + - col1 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-3404
SELECT ALL - cor0.col0 + + cor0.col1 * 33 DIV - col0 - + ( 19 ) DIV col0 FROM tab2 cor0
----
-102
-155
-86

skipif mysql # not compatible
query I rowsort label-3404
SELECT ALL - cor0.col0 + + cor0.col1 * 33 / - col0 - + ( 19 ) / col0 FROM tab2 cor0
----
-102
-155
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3405
SELECT + - col2 * CAST( - col2 AS SIGNED ) - + col2 col1 FROM tab2 AS cor0
----
1406
650
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3405
SELECT + - col2 * CAST ( - col2 AS INTEGER ) - + col2 col1 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT + col1 + ( - col1 ) * - col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + 83 * - col2 AS col1 FROM tab2 AS cor0
----
-2158
-2241
-3154

query IIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0 WHERE NOT NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT col0 + col0 * ( col2 ) * ( + ( - col0 ) * - 76 ) AS col0 FROM tab1
----
17743936
36939
46694480

onlyif mysql # use DIV operator for integer division
query I rowsort label-3410
SELECT DISTINCT - ( col0 ) DIV + col1 + - col1 * col1 * 76 AS col0 FROM tab0 AS cor0
----
-562096
-629356
-715084

skipif mysql # not compatible
query I rowsort label-3410
SELECT DISTINCT - ( col0 ) / + col1 + - col1 * col1 * 76 AS col0 FROM tab0 AS cor0
----
-562096
-629356
-715084

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

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

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

query I rowsort
SELECT DISTINCT ( cor0.col0 ) * - col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT 26 * + col0 * + col1 FROM tab0 AS cor0
----
210574
53664
88270

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

query I rowsort
SELECT ALL + cor1.col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 - tab2.col2 * col0 * 77 col1 FROM tab2
----
-14544
-156147
-231145

onlyif mysql # use DIV operator for integer division
query I rowsort label-3418
SELECT - ( + col2 ) DIV - col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-3418
SELECT - ( + col2 ) / - col1 FROM tab2
----
0
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3419
SELECT col0 * - col1 + CAST( - 60 AS SIGNED ) + col2 * 61 AS col0 FROM tab1
----
2777
3156
4756

skipif mysql # not compatible
query I rowsort label-3419
SELECT col0 * - col1 + CAST ( - 60 AS INTEGER ) + col2 * 61 AS col0 FROM tab1
----
2777
3156
4756

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

query I rowsort
SELECT DISTINCT 92 + cor0.col2 AS col1 FROM tab0, tab0 AS cor0
----
125
174
93

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab2, tab1 AS cor0
----
-76

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

query I rowsort
SELECT + 13 * - 73 + - col2 * 39 FROM tab0 AS cor0
----
-2236
-4147
-988

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

query I rowsort
SELECT ALL + col2 * 28 + col1 AS col2 FROM tab0 AS cor0
----
1010
125
2387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * 86 + + col2 col2 FROM tab0 AS cor0
----
7429
7908
8343

query I rowsort
SELECT DISTINCT + - col0 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT 38 + col0 * col2 FROM tab1 AS cor0
----
200
3686
7718

query I rowsort
SELECT ALL + col2 * 10 AS col2 FROM tab0 AS cor0
----
10
330
820

query I rowsort
SELECT + + col0 * - col0 + 56 * col2 FROM tab1 AS cor0
----
-1024
-904
3015

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

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

query I rowsort
SELECT DISTINCT - ( + 45 ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
-45

query I rowsort
SELECT 26 * - tab0.col0 AS col2 FROM tab0
----
-2314
-624
-910

query I rowsort
SELECT ALL - + 17 + + col1 FROM tab0 AS cor0
----
69
74
80

query I rowsort
SELECT 59 + + col1 AS col1 FROM tab2 AS cor0
----
118
76
90

query I rowsort
SELECT + 99 * 13 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 56bf6cd72d4b51d3db398f9b9df5d15d

query I rowsort
SELECT DISTINCT + col1 * 56 FROM tab1 AS cor0
----
1456
560
728

query I rowsort
SELECT + col2 + col1 * - tab2.col0 * col1 FROM tab2
----
-22793
-271492
-6700

query I rowsort
SELECT ALL col1 * ( tab0.col1 * + col1 ) AS col1 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT - 15 * + col2 AS col0 FROM tab2 cor0
----
-390
-405
-570

query I rowsort
SELECT - + col0 * + col2 - + cor0.col0 AS col1 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT - col0 + + 79 FROM tab0 AS cor0
----
-10
44
55

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

skipif mysql # not compatible
query I rowsort label-3444
SELECT col2 - cor0.col2 / - col0 FROM tab0 AS cor0
----
1
34
82

query I rowsort
SELECT - 4 * tab1.col0 * cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 090c3c101fdbf7b89797f6d0822aca57

query I rowsort
SELECT 46 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3447
SELECT DISTINCT + 42 DIV - 13 FROM tab0, tab2 AS cor0
----
-3

skipif mysql # not compatible
query I rowsort label-3447
SELECT DISTINCT + 42 / - 13 FROM tab0, tab2 AS cor0
----
-3

query I rowsort
SELECT DISTINCT - + ( 8 ) * col2 AS col1 FROM tab2 AS cor0
----
-208
-216
-304

query I rowsort
SELECT - col0 * tab0.col1 * - col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL + 99 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT 6 * + col1 * + col0 AS col1 FROM tab2
----
1302
27612
8058

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

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

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

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

query I rowsort
SELECT ALL + ( 91 * col0 + - 19 ) FROM tab2
----
618
7079
7170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 64 col0 FROM tab2, tab0 cor0
----
64

query I rowsort
SELECT - + ( - 56 ) * + col1 FROM tab2 cor0
----
1736
3304
952

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

query I rowsort
SELECT DISTINCT + 26 AS col2 FROM tab0
----
26

query I rowsort
SELECT cor0.col0 + + col2 + col1 AS col0 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT - col1 * - col0 + + 86 FROM tab0 AS cor0
----
2150
3481
8185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 38 * cor0.col0 col2 FROM tab1 AS cor0
----
-114
-2432
-3040

query I rowsort
SELECT DISTINCT + - col0 * col1 + cor0.col2 + col2 * col0 FROM tab2 AS cor0
----
-1
-2548
1697

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + - col0 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + + col1 * + col0 * col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT - ( - col1 ) + col1 * + cor0.col1 * col2 FROM tab0 AS cor0
----
244154
679133
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * col0 col2 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + 35 AS col0 FROM tab2 AS cor0
----
-14
-6049
-6206

query I rowsort
SELECT DISTINCT - ( col1 ) * - col0 - - col2 * + 56 FROM tab2
----
1729
3471
6058

query I rowsort
SELECT DISTINCT + tab1.col1 + col1 AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT + 84 - - col1 FROM tab2
----
101
115
143

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 col2 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 21 col0 FROM tab1 AS cor0
----
-21

query I rowsort
SELECT ALL + + col2 + - col1 * + col1 FROM tab1 cor0
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col1 * + cor0.col1 + 53 * + 36 col0 FROM tab2 AS cor0
----
2197
2869
5389

query I rowsort
SELECT ALL - + 31 AS col0 FROM tab0 AS cor0
----
-31
-31
-31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * col1 * + 43 + - cor0.col0 col0 FROM tab1 AS cor0
----
27456
3351
44640

query I rowsort
SELECT - col2 + cor0.col2 + col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - cor0.col0 * - col1 * - 94 AS col0 FROM tab1 AS cor0
----
-60160
-7332
-97760

query I rowsort
SELECT + 17 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT + col0 + - ( + col1 ) * ( - col1 ) FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT 67 + + 56 FROM tab2
----
123

query I rowsort
SELECT + ( - 13 ) * + col1 FROM tab0
----
-1118
-1183
-1261

query I rowsort
SELECT ALL + col2 * - 45 + col2 AS col2 FROM tab0 AS cor0
----
-1452
-3608
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 56 * - 88 + col0 col2 FROM tab0 AS cor0
----
4952
4963
5017

query I rowsort
SELECT + col1 * - 19 - col0 AS col2 FROM tab0 AS cor0
----
-1658
-1818
-1878

query I rowsort
SELECT ALL - + 98 + col0 * - cor0.col1 * + 64 AS col0 FROM tab2 AS cor0
----
-13986
-294626
-86050

query I rowsort
SELECT col1 + + col1 - + col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT 44 + cor0.col0 * col0 * - col2 FROM tab1 AS cor0
----
-233428
-442
-614356

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0, tab2 cor2
----
3645 values hashing to 972d282d6d92f451c90dc8ca51a18f3e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 39 * cor0.col0 col0 FROM tab2, tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT DISTINCT + - cor0.col2 + - 93 AS col1 FROM tab0 AS cor0
----
-126
-175
-94

query I rowsort
SELECT ALL col1 * 83 + - tab0.col2 FROM tab0
----
7105
7471
8050

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + cor0.col1 * col1 col2 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT ALL - col1 * col0 + cor0.col2 * - col0 - col1 AS col2 FROM tab2 AS cor0
----
-4362
-437
-6689

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col0 ) * col2 * cor0.col0 col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + cor0.col0 + 27 * col0 FROM tab0 AS cor0
----
2492
672
980

query I rowsort
SELECT DISTINCT - - cor0.col0 * col1 AS col2 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3499
SELECT DISTINCT - col2 DIV + 23 - + col2 FROM tab0 AS cor0
----
-1
-34
-85

skipif mysql # not compatible
query I rowsort label-3499
SELECT DISTINCT - col2 / + 23 - + col2 FROM tab0 AS cor0
----
-1
-34
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 42 col2 FROM tab1 AS cor0
----
-42
-42
-42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3501
SELECT ALL + CAST( NULL AS SIGNED ) * - col0 - cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3501
SELECT ALL + CAST ( NULL AS INTEGER ) * - col0 - cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col0 ) * col1 col0 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col2 ) + + col2 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 + - 86 FROM tab1 AS cor0
----
-140
-143
-182

query I rowsort
SELECT cor0.col1 - col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - 43 + - col0 AS col1 FROM tab2 cor0
----
-121
-122
-50

query I rowsort
SELECT DISTINCT + col2 - - col1 * + ( + col1 ) AS col2 FROM tab2 AS cor0
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-3508
SELECT DISTINCT 41 DIV cor0.col2 - - col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3508
SELECT DISTINCT 41 / cor0.col2 - - col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + + ( + cor0.col0 ) * col0 + - col2 + - col2 * + 31 * - col2 AS col2 FROM tab0 AS cor0
----
1255
216283
34302

query I rowsort
SELECT - - 51 * + col1 + - col2 * - ( col2 ) AS col2 FROM tab0 AS cor0
----
11365
4948
5475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3511
SELECT DISTINCT CAST( NULL AS SIGNED ) - col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3511
SELECT DISTINCT CAST ( NULL AS INTEGER ) - col1 FROM tab1
----
NULL

query I rowsort
SELECT - + col1 + col1 * + cor0.col1 FROM tab0 AS cor0
----
7310
8190
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + col2 * + col0 col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - ( col0 ) + - col1 + - col1 * 89 AS col0 FROM tab2
----
-1609
-2797
-5388

query I rowsort
SELECT DISTINCT tab1.col2 - - col0 * col0 FROM tab1
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + - col1 col2 FROM tab2 cor0
----
-118
-34
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3517
SELECT ALL + col1 * CAST( NULL AS SIGNED ) + - cor0.col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3517
SELECT ALL + col1 * CAST ( NULL AS INTEGER ) + - cor0.col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3518
SELECT col1 DIV 92 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3518
SELECT col1 / 92 FROM tab0 cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3519
SELECT col1 DIV cor0.col2 col1 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3519
SELECT col1 / cor0.col2 col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - col1 * + col1 * col2 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT - 59 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 22ab9bd3b5f4877e4ba3d3f7269d563e

onlyif mysql # use DIV operator for integer division
query I rowsort label-3522
SELECT - col1 DIV + col0 - + col0 * + col0 FROM tab1
----
-17
-4096
-6400

skipif mysql # not compatible
query I rowsort label-3522
SELECT - col1 / + col0 - + col0 * + col0 FROM tab1
----
-17
-4096
-6400

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 - 91 * + col1 AS col0 FROM tab2 AS cor0
----
-1547
-2821
-5369

query I rowsort
SELECT DISTINCT 86 * col1 AS col1 FROM tab1 cor0
----
1118
2236
860

query I rowsort
SELECT - - 55 * col2 * col2 AS col1 FROM tab0 cor0
----
369820
55
59895

query I rowsort
SELECT + col1 - - col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT ( + 73 ) FROM tab2, tab1 AS cor0
----
73

query I rowsort
SELECT - + col1 + 4 - col0 AS col2 FROM tab1 AS cor0
----
-25
-70
-89

query I rowsort
SELECT ALL - cor1.col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT - - col2 + 85 AS col0 FROM tab2 AS cor0
----
111
112
123

query I rowsort
SELECT DISTINCT - 66 * + col2 AS col2 FROM tab2
----
-1716
-1782
-2508

query I rowsort
SELECT ALL col0 * 25 AS col1 FROM tab0
----
2225
600
875

query I rowsort
SELECT ALL 10 AS col2 FROM tab2
----
10
10
10

query I rowsort
SELECT ALL + - col0 * col1 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 92 + col1 AS col0 FROM tab2 AS cor0
----
-33
-61
-75

query I rowsort
SELECT ALL + - col1 * - col1 * + col1 AS col2 FROM tab2 cor0
----
205379
29791
4913

query I rowsort
SELECT ALL 46 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-13
15
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3539
SELECT DISTINCT col1 + ( col2 ) * + CAST( - col0 * + col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-119593
-51017
-5828

skipif mysql # not compatible
query I rowsort label-3539
SELECT DISTINCT col1 + ( col2 ) * + CAST ( - col0 * + col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT DISTINCT + + ( + col1 ) + col1 * col1 * - col2 FROM tab0 AS cor0
----
-243982
-678951
-9312

query I rowsort
SELECT + 26 * col2 AS col2 FROM tab1 AS cor0
----
1404
1482
2496

query I rowsort
SELECT DISTINCT - + 2 + + col1 FROM tab1 AS cor0
----
11
24
8

query I rowsort
SELECT DISTINCT col2 + + col2 + col2 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT + 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 ALL + 47 - + cor0.col1 col2 FROM tab0 AS cor0
----
-39
-44
-50

query I rowsort
SELECT DISTINCT - - 29 * + cor0.col1 FROM tab0 AS cor0
----
2494
2639
2813

query I rowsort
SELECT ALL - + 40 AS col2 FROM tab1 cor0
----
-40
-40
-40

query I rowsort
SELECT tab0.col2 + + col1 * col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT + col2 * col0 + - 59 FROM tab2 AS cor0
----
130
1969
2943

query I rowsort
SELECT - 13 * - col1 FROM tab2 AS cor0
----
221
403
767

query I rowsort
SELECT 40 + + col2 * - col1 * col2 AS col2 FROM tab1 AS cor0
----
-119768
-32450
-75776

query I rowsort
SELECT ALL + col2 * col0 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT cor0.col2 + col0 * col1 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3554
SELECT cor0.col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3554
SELECT cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT - 69 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3557
SELECT col1 DIV 21 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3557
SELECT col1 / 21 AS col1 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3558
SELECT - CAST( NULL AS SIGNED ) + + col1 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-3558
SELECT - CAST ( NULL AS INTEGER ) + + col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3559
SELECT - 41 / col1 + - col0 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3559
SELECT - 41 / col1 + - col0 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT + col1 + + CAST ( + 35 AS REAL ) * col2 + + col1 AS col0 FROM tab1
----
1942
2015
3386

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col0 * col0 col1 FROM tab2
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-3562
SELECT ALL col1 DIV ( tab0.col2 ) AS col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3562
SELECT ALL col1 / ( tab0.col2 ) AS col2 FROM tab0
----
1
2
97

query I rowsort
SELECT + col2 * + col1 + col0 * 9 AS col0 FROM tab1 AS cor0
----
1146
1431
1968

onlyif mysql # use DIV operator for integer division
query I rowsort label-3564
SELECT col2 DIV 51 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3564
SELECT col2 / 51 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT - 11 * + col1 FROM tab1
----
-110
-143
-286

query I rowsort
SELECT - cor0.col0 * 50 + - col1 AS col2 FROM tab0 AS cor0
----
-1286
-1847
-4541

query I rowsort
SELECT + col1 * 20 AS col0 FROM tab2 AS cor0
----
1180
340
620

query I rowsort
SELECT - tab0.col1 + + tab0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to c22e7a33a1d8d55a5f7224b3cf03e3bc

query I rowsort
SELECT + tab2.col2 * - col1 AS col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT + ( - 79 ) * col2 + + ( col1 ) FROM tab0 AS cor0
----
-2521
-6387
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 + cor0.col2 col1 FROM tab1 AS cor0
----
106
122
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col1 col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT ( 52 ) + - col2 + col1 FROM tab1
----
-31
24
5

query I rowsort
SELECT DISTINCT + col2 + 22 FROM tab0
----
104
23
55

query I rowsort
SELECT DISTINCT - ( col2 ) - col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT col0 + 18 FROM tab0 AS cor0
----
107
42
53

query I rowsort
SELECT DISTINCT - 0 * 82 + col0 AS col1 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3578
SELECT DISTINCT CAST( col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3578
SELECT DISTINCT CAST ( col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT cor0.col0 * col0 + col2 + col1 AS col2 FROM tab0 AS cor0
----
1323
695
8094

query I rowsort
SELECT - 20 * + col1 + + col1 FROM tab0 AS cor0
----
-1634
-1729
-1843

query I rowsort
SELECT ALL col1 + - cor0.col0 * + 70 AS col2 FROM tab1 AS cor0
----
-184
-4470
-5587

onlyif mysql # use DIV operator for integer division
query I rowsort label-3582
SELECT ALL - ( + ( col1 ) ) + tab0.col0 DIV tab0.col2 - + col2 FROM tab0
----
-119
-172
-63

skipif mysql # not compatible
query I rowsort label-3582
SELECT ALL - ( + ( col1 ) ) + tab0.col0 / tab0.col2 - + col2 FROM tab0
----
-119
-172
-63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3583
SELECT - CAST( col2 AS SIGNED ) - col1 FROM tab2
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-3583
SELECT - CAST ( col2 AS INTEGER ) - col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT DISTINCT + + col1 - + col2 * 78 * - 7 FROM tab2 AS cor0
----
14255
14773
20765

query I rowsort
SELECT DISTINCT + col0 + + col1 * 33 AS col0 FROM tab0 AS cor0
----
2862
3092
3236

query I rowsort
SELECT + col2 * + cor0.col1 - + col0 * 2 AS col0 FROM tab1 AS cor0
----
1088
1398
442

query I rowsort
SELECT ALL col0 * col1 + + col2 + - 83 FROM tab0 cor0
----
2014
3313
8098

onlyif mysql # use DIV operator for integer division
query I rowsort label-3588
SELECT ALL + col0 DIV + col2 + col1 col0 FROM tab1
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3588
SELECT ALL + col0 / + col2 + col1 col0 FROM tab1
----
11
13
26

query I rowsort
SELECT DISTINCT + tab2.col1 + col1 * col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT DISTINCT 76 AS col1 FROM tab2, tab0 AS cor0
----
76

query I rowsort
SELECT DISTINCT 1 - + tab2.col0 FROM tab2
----
-6
-77
-78

query I rowsort
SELECT - col0 + - 84 AS col1 FROM tab0
----
-108
-119
-173

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 - col1 * col1 col2 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT - + col1 * ( + col2 + - cor0.col2 ) FROM tab1 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3595
SELECT DISTINCT - cor0.col1 * + CAST( + col2 * col1 + + col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-11628
-26784
-92040

skipif mysql # not compatible
query I rowsort label-3595
SELECT DISTINCT - cor0.col1 * + CAST ( + col2 * col1 + + col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-11628
-26784
-92040

query I rowsort
SELECT col1 + + col2 * cor0.col1 AS col0 FROM tab2 cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-3597
SELECT DISTINCT col2 DIV col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3597
SELECT DISTINCT col2 / col1 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3598
SELECT DISTINCT - cor0.col2 DIV + 26 AS col2 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3598
SELECT DISTINCT - cor0.col2 / + 26 AS col2 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT ALL - col2 + + ( col2 ) AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * + 73 * cor0.col2 col2 FROM tab0 AS cor0
----
-2555
-532754
-57816

query I rowsort
SELECT DISTINCT - 54 * tab1.col2 + col0 + col0 FROM tab1
----
-2910
-2950
-5024

query I rowsort
SELECT DISTINCT 59 + + col1 FROM tab1
----
69
72
85

query I rowsort
SELECT 89 * col1 - + 53 FROM tab1
----
1104
2261
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3604
SELECT col2 DIV 2 + 97 FROM tab2
----
110
110
116

skipif mysql # not compatible
query I rowsort label-3604
SELECT col2 / 2 + 97 FROM tab2
----
110
110
116

query I rowsort
SELECT ALL 47 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 cor2, tab0 AS cor3
----
243 values hashing to 79962577c0add9c47b55da7472585e96

query I rowsort
SELECT - col1 + 35 * col1 FROM tab0 AS cor0
----
2924
3094
3298

query I rowsort
SELECT ALL + + col0 + 43 * col2 FROM tab2 AS cor0
----
1168
1196
1713

query I rowsort
SELECT + cor1.col0 AS col0 FROM tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ALL - 49 FROM tab1, tab2 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab1, tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT 37 * ( + col1 ) AS col2 FROM tab0 AS cor0
----
3182
3367
3589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ALL 29 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 15 col2 FROM tab2
----
255
465
885

query I rowsort
SELECT DISTINCT ( 45 ) AS col1 FROM tab1
----
45

query I rowsort
SELECT ALL 62 * col1 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT DISTINCT + - col1 * + 59 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT DISTINCT col1 + + col1 AS col2 FROM tab0 cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-3619
SELECT 57 DIV ( cor0.col1 ) FROM tab2 cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-3619
SELECT 57 / ( cor0.col1 ) FROM tab2 cor0
----
0
1
3

query I rowsort
SELECT ALL + col2 * + 97 FROM tab1 AS cor0
----
5238
5529
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3621
SELECT DISTINCT - 96 * - col1 DIV col1 AS col0 FROM tab1 cor0
----
96

skipif mysql # not compatible
query I rowsort label-3621
SELECT DISTINCT - 96 * - col1 / col1 AS col0 FROM tab1 cor0
----
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3622
SELECT - - ( + ( cor0.col1 ) ) * CAST( NULL AS SIGNED ) + - 85 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3622
SELECT - - ( + ( cor0.col1 ) ) * CAST ( NULL AS INTEGER ) + - 85 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( + col0 ) * - col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + - col2 + 53 FROM tab2 cor0
----
15
26
27

query I rowsort
SELECT ALL + col1 * + col0 + - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT + ( cor0.col1 ) + col2 * - ( col1 ) AS col0 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT - 2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
31
80

query I rowsort
SELECT ALL - cor0.col1 + - cor0.col1 + - col2 FROM tab0 AS cor0
----
-195
-205
-264

onlyif mysql # use DIV operator for integer division
query I rowsort label-3629
SELECT 46 * + col1 + + col1 DIV + col0 AS col1 FROM tab1 AS cor0
----
1204
460
598

skipif mysql # not compatible
query I rowsort label-3629
SELECT 46 * + col1 + + col1 / + col0 AS col1 FROM tab1 AS cor0
----
1204
460
598

query I rowsort
SELECT ALL + 97 * + col0 AS col2 FROM tab0 AS cor0
----
2328
3395
8633

query I rowsort
SELECT DISTINCT 88 + + col0 * 75 FROM tab0 AS cor0
----
1888
2713
6763

query I rowsort
SELECT - 73 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-38
-49
16

query I rowsort
SELECT DISTINCT col1 + + col0 * 51 AS col1 FROM tab1 AS cor0
----
179
3274
4093

onlyif mysql # use DIV operator for integer division
query I rowsort label-3634
SELECT DISTINCT + col0 DIV - cor0.col2 + - col1 + - col1 AS col0 FROM tab1 AS cor0
----
-21
-26
-52

skipif mysql # not compatible
query I rowsort label-3634
SELECT DISTINCT + col0 / - cor0.col2 + - col1 + - col1 AS col0 FROM tab1 AS cor0
----
-21
-26
-52

query I rowsort
SELECT ALL - cor0.col1 - col0 AS col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT + 84 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 92 + cor0.col1 col0 FROM tab1 AS cor0
----
-66
-79
-82

query I rowsort
SELECT DISTINCT - + col1 + + col1 + ( 91 ) AS col2 FROM tab0 AS cor0
----
91

query I rowsort
SELECT + col0 * col1 + - col1 * col2 FROM tab1 AS cor0
----
-1326
-208
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3640
SELECT DISTINCT - - col0 * + CAST( NULL AS DECIMAL ) - col0 AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3640
SELECT DISTINCT - - col0 * + CAST ( NULL AS REAL ) - col0 AS col1 FROM tab2 cor0
----
NULL

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1, tab0 cor2
----
3645 values hashing to b225d3765f33551c12574f545c8c91eb

query I rowsort
SELECT DISTINCT - - col2 * - col1 + 88 AS col2 FROM tab1 cor0
----
-1160
-1316
-482

query I rowsort
SELECT - col0 * 95 + col1 AS col0 FROM tab0 AS cor0
----
-2194
-3228
-8364

onlyif mysql # use DIV operator for integer division
query I rowsort label-3644
SELECT ALL - col2 + + col1 DIV col2 FROM tab0 AS cor0
----
-31
-81
96

skipif mysql # not compatible
query I rowsort label-3644
SELECT ALL - col2 + + col1 / col2 FROM tab0 AS cor0
----
-31
-81
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + col0 * + col0 col0 FROM tab0 AS cor0
----
13824
42875
704969

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT NULL <= NULL OR ( - col1 ) = - col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + cor0.col0 col0 FROM tab2 AS cor0
----
0
0
0

query III rowsort
SELECT * FROM tab0 WHERE NULL < NULL AND - col0 * col1 > NULL
----

query I rowsort
SELECT DISTINCT - tab1.col2 * - col2 AS col0 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3650
SELECT col1 DIV + col1 col1 FROM tab2 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3650
SELECT col1 / + col1 col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL - col1 * col1 - col1 AS col1 FROM tab0 WHERE NOT NULL IN ( + col2 )
----

query I rowsort
SELECT DISTINCT col1 FROM tab1 AS cor0 WHERE NULL >= ( NULL )
----

query I rowsort
SELECT ALL - col2 * tab1.col2 + col2 AS col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT + tab1.col2 * tab1.col0 AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT tab2.col0 + - cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to bd9d093c1474b55627062c05809f59d2

query I rowsort
SELECT ALL tab2.col0 * col1 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT col1 * + col2 + + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL col1 * + col2 - col0 AS col2 FROM tab1
----
1168
1401
506

query I rowsort
SELECT + tab2.col0 * col0 + tab2.col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT - - 85 + + col0 FROM tab1 AS cor0
----
149
165
88

query I rowsort
SELECT DISTINCT col2 + + col1 FROM tab1 WHERE NOT NULL <= ( NULL )
----

query I rowsort
SELECT ALL + col0 * col2 + col0 FROM tab1 WHERE NOT col2 + + col1 * col1 <> col0 * + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3663
SELECT DISTINCT col1 * col1 + + col0 DIV - col1 + + col2 AS col1 FROM tab2
----
323
3506
988

skipif mysql # not compatible
query I rowsort label-3663
SELECT DISTINCT col1 * col1 + + col0 / - col1 + + col2 AS col1 FROM tab2
----
323
3506
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-3664
SELECT tab0.col2 + - col1 * - col2 + col0 DIV col1 AS col1 FROM tab0
----
2871
7544
98

skipif mysql # not compatible
query I rowsort label-3664
SELECT tab0.col2 + - col1 * - col2 + col0 / col1 AS col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT - col1 * col1 * - col1 FROM tab2
----
205379
29791
4913

query I rowsort
SELECT - col0 * - col0 + - col1 * col0 FROM tab0
----
-1488
-178
-2170

query I rowsort
SELECT ALL + col2 * + col0 * - col2 FROM tab0
----
-26136
-35
-598436

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT BETWEEN ( NULL ) AND ( - col2 + - col2 / col1 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT col0 * + col0 + col1 IN ( + col2 * col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col2 + - col0 * col2 + + col0 * - col1 FROM tab0
----
-15315
-2823
-3429

query I rowsort
SELECT + col1 * col1 + - 64 FROM tab2 AS cor0
----
225
3417
897

query I rowsort
SELECT + - 7 * col1 FROM tab1 cor0
----
-182
-70
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-3673
SELECT ALL col1 + col0 + col1 * col1 DIV + col0 AS col0 FROM tab2
----
175
181
99

skipif mysql # not compatible
query I rowsort label-3673
SELECT ALL col1 + col0 + col1 * col1 / + col0 AS col0 FROM tab2
----
175
181
99

query I rowsort
SELECT - 38 * col0 + + 40 AS col2 FROM tab2 AS cor0
----
-226
-2924
-2962

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + + col2 col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 18 * cor0.col0 AS col2 FROM tab1 AS cor0
----
1152
1440
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-3677
SELECT + col1 DIV col0 + + col2 AS col1 FROM tab0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-3677
SELECT + col1 / col0 + + col2 AS col1 FROM tab0
----
3
36
83

query I rowsort
SELECT col2 * col0 + - col2 AS col1 FROM tab2
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-3679
SELECT ALL col2 DIV col0 + col2 * col2 FROM tab0
----
1
1090
6724

skipif mysql # not compatible
query I rowsort label-3679
SELECT ALL col2 / col0 + col2 * col2 FROM tab0
----
1
1090
6724

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col0 FROM tab0, tab0 cor0
----
9 values hashing to d2e5241c58e367013a1a203910e000c0

query I rowsort
SELECT ALL col1 - + col0 * col0 * cor0.col0 AS col1 FROM tab2 AS cor0 WHERE NOT NULL > col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3682
SELECT ALL tab1.col2 DIV col2 + - tab1.col2 * + tab1.col1 FROM tab1
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-3682
SELECT ALL tab1.col2 / col2 + - tab1.col2 * + tab1.col1 FROM tab1
----
-1247
-1403
-569

query I rowsort
SELECT DISTINCT + col2 * col1 * - col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT col1 * + col0 FROM tab2 WHERE NOT ( NULL ) <> ( NULL )
----

query I rowsort
SELECT DISTINCT col1 + - col2 + + col0 AS col2 FROM tab2
----
11
111
58

query I rowsort
SELECT DISTINCT + col2 AS col0 FROM tab2 WHERE col2 + - col0 > NULL
----

query I rowsort
SELECT tab0.col0 * - col0 FROM tab0 WHERE + col0 * col2 + - col2 * col1 >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3688
SELECT tab0.col2 DIV col2 + - col2 * col0 - - col0 FROM tab0
----
-7208
-767
1

skipif mysql # not compatible
query I rowsort label-3688
SELECT tab0.col2 / col2 + - col2 * col0 - - col0 FROM tab0
----
-7208
-767
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3689
SELECT + col1 DIV - tab2.col1 + col2 * col2 FROM tab2
----
1443
675
728

skipif mysql # not compatible
query I rowsort label-3689
SELECT + col1 / - tab2.col1 + col2 * col2 FROM tab2
----
1443
675
728

query I rowsort
SELECT col2 * col0 + - col0 AS col0 FROM tab1
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 col0 FROM tab2 WHERE + col0 BETWEEN ( NULL ) AND ( NULL )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col0 = NULL
----

query I rowsort
SELECT col2 * + col1 - - col2 AS col0 FROM tab2
----
1560
684
864

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) BETWEEN ( col0 + - col2 / col1 ) AND ( NULL )
----

query I rowsort
SELECT ALL col1 * col1 * col1 AS col0 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT DISTINCT + col1 AS col2 FROM tab1 WHERE NULL NOT BETWEEN ( NULL ) AND - tab1.col0 / - col2
----

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col2 ) <> + col2 - col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT col1 + - tab0.col2 AS col2 FROM tab0 WHERE ( NULL ) NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT DISTINCT - tab1.col1 AS col1 FROM tab1, tab2, tab2 cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 col1 FROM tab0
----
38
38
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 96 * - cor0.col2 col0 FROM tab0 AS cor0
----
3168
7872
96

query I rowsort
SELECT ALL - col1 + cor0.col2 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT col0 * + col1 + cor0.col1 * col1 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT - cor0.col1 * 3 FROM tab0 AS cor0
----
-258
-273
-291

skipif mysql # not compatible
query I rowsort
SELECT ALL - cor0.col2 * - CAST ( - col0 AS REAL ) * col2 + + col0 - + col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3707
SELECT ALL col1 * 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-3707
SELECT ALL col1 * CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 * CAST ( + col1 AS REAL ) + + col0 * - col2 AS col2 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT DISTINCT + col1 * 28 AS col0 FROM tab2 AS cor0
----
1652
476
868

query I rowsort
SELECT DISTINCT - col0 * - 65 * 81 + - col1 * + 53 + col2 FROM tab0 AS cor0
----
121835
179135
463844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col2 col1 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3712
SELECT ALL + col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3712
SELECT ALL + col1 * + 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-3713
SELECT + col0 - + col2 DIV - 8 AS col1 FROM tab1 AS cor0
----
71
9
92

skipif mysql # not compatible
query I rowsort label-3713
SELECT + col0 - + col2 / - 8 AS col1 FROM tab1 AS cor0
----
71
9
92

query I rowsort
SELECT ALL + - col1 * - 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-3715
SELECT DISTINCT col0 + + CAST( 56 AS SIGNED ) col2 FROM tab1 AS cor0
----
120
136
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3715
SELECT DISTINCT col0 + + CAST ( 56 AS INTEGER ) col2 FROM tab1 AS cor0
----
120
136
59

query I rowsort
SELECT ALL + col0 - + ( col2 ) FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3717
SELECT col1 + - col0 DIV - tab0.col0 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3717
SELECT col1 + - col0 / - tab0.col0 FROM tab0
----
87
92
98

query I rowsort
SELECT + - cor0.col0 + 26 * col2 * - col1 FROM tab0 AS cor0
----
-194101
-2557
-73812

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col1 col0 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3720
SELECT ALL - CAST( NULL AS SIGNED ) / + 67 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3720
SELECT ALL - CAST ( NULL AS INTEGER ) / + 67 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 * - ( cor0.col1 ) AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT + + col2 + 18 FROM tab2 cor0
----
44
45
56

query I rowsort
SELECT + - 43 * 1 FROM tab2 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - col2 * - 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-3725
SELECT DISTINCT + - CAST( col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3725
SELECT DISTINCT + - CAST ( col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col0 + col2 col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT - + ( + col1 ) * cor0.col0 + ( + 71 + - cor0.col0 ) FROM tab1 AS cor0
----
-10
-1049
-633

query I rowsort
SELECT col0 + cor0.col1 * col0 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3729
SELECT ( 8 ) DIV + col2 + + CAST( - 13 AS SIGNED ) FROM tab0 AS cor0
----
-13
-13
-5

skipif mysql # not compatible
query I rowsort label-3729
SELECT ( 8 ) / + col2 + + CAST ( - 13 AS INTEGER ) FROM tab0 AS cor0
----
-13
-13
-5

query I rowsort
SELECT ALL + + cor0.col1 + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col2 * + col0 * col2 AS col1 FROM tab0 AS cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-3732
SELECT ALL - + cor0.col0 DIV col0 - cor0.col0 FROM tab2 cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-3732
SELECT ALL - + cor0.col0 / col0 - cor0.col0 FROM tab2 cor0
----
-79
-8
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col2 * - 31 col0 FROM tab1 AS cor0
----
-1648
-1757
-2963

query I rowsort
SELECT - - 71 * - col2 * + col0 AS col1 FROM tab0 AS cor0
----
-2485
-518158
-56232

query I rowsort
SELECT DISTINCT + col2 + cor0.col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + - col0 * + col1 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 AS cor2
----
3645 values hashing to dd5ce24448edb4b3ab62c251475d6548

query I rowsort
SELECT ( + col1 ) + tab0.col1 * ( - ( + col1 ) ) FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT col2 + - col0 * - col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT ALL tab2.col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL + tab2.col1 + - col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL - 83 + col1 FROM tab0 cor0
----
14
3
8

query I rowsort
SELECT ALL - + 28 * + col1 * + 97 FROM tab1 AS cor0
----
-27160
-35308
-70616

query I rowsort
SELECT ALL - + col1 * + col0 * + 80 FROM tab2 AS cor0
----
-107440
-17360
-368160

query I rowsort
SELECT ALL + + 95 AS col0 FROM tab2 AS cor0
----
95
95
95

query I rowsort
SELECT cor0.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 33 + col0 col0 FROM tab2
----
111
112
40

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 63 AS REAL ) AS col2 FROM tab2
----
-63
-63
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-3749
SELECT DISTINCT tab0.col0 DIV 79 + col2 * + 98 + - tab0.col0 FROM tab0
----
3210
63
7948

skipif mysql # not compatible
query I rowsort label-3749
SELECT DISTINCT tab0.col0 / 79 + col2 * + 98 + - tab0.col0 FROM tab0
----
3210
63
7948

query I rowsort
SELECT - + col2 * + col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - col1 * col0 * ( cor0.col0 * col2 + 90 ) FROM tab1 AS cor0
----
-19656
-2392320
-8080800

query I rowsort
SELECT ALL + 13 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3753
SELECT CAST( + col1 AS SIGNED ) - col0 AS col1 FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-3753
SELECT CAST ( + col1 AS INTEGER ) - col0 AS col1 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT DISTINCT + 9 * + ( - col0 ) + - col1 DIV - col1 col1 FROM tab1 AS cor0
----
-26
-575
-719

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3754
SELECT DISTINCT + 9 * + ( - col0 ) + - col1 / - col1 col1 FROM tab1 AS cor0
----
-26
-575
-719

query I rowsort
SELECT DISTINCT - col1 - col0 * + col0 AS col2 FROM tab2
----
-6143
-6258
-80

query I rowsort
SELECT + col2 + 2 FROM tab0
----
3
35
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col1 + + ( + col2 ) col0 FROM tab1
----
28
47
83

query I rowsort
SELECT + col1 - col1 * col0 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT col2 + 19 FROM tab1
----
115
73
76

query I rowsort
SELECT 1 * - col2 AS col2 FROM tab2
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3761
SELECT ALL - CAST( + col0 AS SIGNED ) + - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-3761
SELECT ALL - CAST ( + col0 AS INTEGER ) + - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3762
SELECT ALL - - 58 + + col0 DIV col1 AS col2 FROM tab1 AS cor0
----
58
64
64

skipif mysql # not compatible
query I rowsort label-3762
SELECT ALL - - 58 + + col0 / col1 AS col2 FROM tab1 AS cor0
----
58
64
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-3763
SELECT ALL 37 + col1 DIV + tab1.col0 FROM tab1
----
37
37
45

skipif mysql # not compatible
query I rowsort label-3763
SELECT ALL 37 + col1 / + tab1.col0 FROM tab1
----
37
37
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3764
SELECT ( col1 ) * col0 DIV - col0 + - col0 AS col1 FROM tab2
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-3764
SELECT ( col1 ) * col0 / - col0 + - col0 AS col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT DISTINCT 31 * + 6 + col2 FROM tab0 AS cor0
----
187
219
268

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col1 ) * - cor0.col0 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - + 1 + + 62 * col2 * + col2 FROM tab0 AS cor0
----
416887
61
67517

query I rowsort
SELECT - 96 + + 97 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT ( + 2 ) FROM tab0, tab1 cor0, tab2 AS cor1, tab1 AS cor2
----
2

query I rowsort
SELECT + 5 + cor0.col2 AS col0 FROM tab1 AS cor0
----
101
59
62

query I rowsort
SELECT ALL - 33 + + col1 AS col0 FROM tab1 cor0
----
-20
-23
-7

query I rowsort
SELECT DISTINCT + col1 * 21 * - 71 FROM tab0 cor0
----
-128226
-135681
-144627

query I rowsort
SELECT ALL - col0 + - col1 * col2 AS col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT + col2 * + 1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - cor0.col2 * col1 + + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + col1 * col1 + - col1 AS col1 FROM tab1 cor0
----
156
650
90

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - col1 AS REAL ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + - cor0.col1 + 8 FROM tab1 cor0
----
-18
-2
-5

query I rowsort
SELECT + + 95 + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-545
-945
17

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 15ae1b54cae2dcf5c6eef7f1d15689eb

query I rowsort
SELECT + col0 + col2 - cor0.col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col1 + - col2 + cor0.col2 * - cor0.col0 * col2 FROM tab2 AS cor0
----
-114097
-5099
-52695

query I rowsort
SELECT + - col0 * + cor0.col1 - cor0.col2 FROM tab2 AS cor0
----
-1381
-244
-4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-3784
SELECT + - col2 * + col2 + 93 DIV col0 AS col2 FROM tab2 AS cor0
----
-1443
-675
-716

skipif mysql # not compatible
query I rowsort label-3784
SELECT + - col2 * + col2 + 93 / col0 AS col2 FROM tab2 AS cor0
----
-1443
-675
-716

query I rowsort
SELECT + 44 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT - 75 * - col1 - + 37 AS col1 FROM tab2 AS cor0
----
1238
2288
4388

query I rowsort
SELECT DISTINCT 16 - col2 FROM tab1
----
-38
-41
-80

query I rowsort
SELECT 33 + + col1 FROM tab0
----
119
124
130

query I rowsort
SELECT DISTINCT ( + col1 + tab1.col1 ) FROM tab1
----
20
26
52

query I rowsort
SELECT col2 + col2 * - col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT + col0 * - col2 * 97 AS col0 FROM tab0
----
-3395
-707906
-76824

query I rowsort
SELECT ALL + - col1 * + 39 FROM tab1 AS cor0
----
-1014
-390
-507

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3793
SELECT ALL + col2 + CAST( + col2 AS SIGNED ) + - col1 AS col2 FROM tab2 AS cor0
----
-7
23
59

skipif mysql # not compatible
query I rowsort label-3793
SELECT ALL + col2 + CAST ( + col2 AS INTEGER ) + - col1 AS col2 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT ALL 92 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + - col1 * 6 col1 FROM tab2 AS cor0
----
-119
-217
-413

query I rowsort
SELECT - col2 * - 95 * col2 + - col0 FROM tab1 AS cor0
----
277017
308591
875440

query I rowsort
SELECT ALL - col1 + + ( - col2 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT cor0.col0 * 50 FROM tab1, tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT ALL + 79 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT ALL - ( cor0.col0 ) AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT col1 + col1 - col2 AS col2 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT - col1 * + col2 + ( col0 ) * col1 AS col1 FROM tab2 cor0
----
-620
3068
697

query I rowsort
SELECT col1 * col0 * + col2 + col0 * + col1 + cor0.col0 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
108560
40768
4452

query I rowsort
SELECT DISTINCT - col1 + 54 FROM tab0
----
-32
-37
-43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3805
SELECT + CAST( 1 AS SIGNED ) FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3805
SELECT + CAST ( 1 AS INTEGER ) FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT - 45 FROM tab0, tab0 cor0
----
-45

query I rowsort
SELECT 39 AS col0 FROM tab1 AS cor0
----
39
39
39

query I rowsort
SELECT col2 * - col2 + + ( 12 ) AS col0 FROM tab2 AS cor0
----
-1432
-664
-717

query I rowsort
SELECT DISTINCT - - 11 + + col0 * - 92 + col1 AS col1 FROM tab0 AS cor0
----
-2111
-3112
-8086

query I rowsort
SELECT - 89 + - col2 AS col2 FROM tab0 AS cor0
----
-122
-171
-90

query I rowsort
SELECT ALL + ( cor0.col1 ) AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL - 41 * - 77 AS col2 FROM tab1 AS cor0
----
3157
3157
3157

query I rowsort
SELECT + 50 * - col0 AS col1 FROM tab0 AS cor0
----
-1200
-1750
-4450

query I rowsort
SELECT ALL - col0 + + col1 + + tab2.col1 AS col1 FROM tab2
----
-45
40
55

query I rowsort
SELECT + 73 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 9f0f371d979e70a792c8597c6559f0e2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3816
SELECT ALL ( 11 ) DIV col2 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3816
SELECT ALL ( 11 ) / col2 AS col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 57 col2 FROM tab0
----
57
57
57

query I rowsort
SELECT DISTINCT col0 * 32 AS col2 FROM tab0
----
1120
2848
768

query I rowsort
SELECT col2 + + col1 * col2 AS col1 FROM tab1 cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-3820
SELECT ALL - - 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-3820
SELECT ALL - - col2 / - col2 col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + 44 FROM tab0 cor0
----
44

query I rowsort
SELECT + - 43 FROM tab1 cor0
----
-43
-43
-43

query I rowsort
SELECT ALL - 69 * - col0 FROM tab0 AS cor0
----
1656
2415
6141

query I rowsort
SELECT + col1 + col1 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + col1 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT 58 + - col1 FROM tab0 AS cor0
----
-28
-33
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-3827
SELECT col1 * + col2 - - ( - tab1.col2 + col0 ) DIV + col1 FROM tab1
----
1247
1403
570

skipif mysql # not compatible
query I rowsort label-3827
SELECT col1 * + col2 - - ( - tab1.col2 + col0 ) / + col1 FROM tab1
----
1247
1403
570

query I rowsort
SELECT ALL + 15 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT DISTINCT - 39 + col0 FROM tab1
----
-36
25
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-3830
SELECT tab2.col2 + + col1 DIV col0 FROM tab2
----
26
31
38

skipif mysql # not compatible
query I rowsort label-3830
SELECT tab2.col2 + + col1 / col0 FROM tab2
----
26
31
38

query I rowsort
SELECT DISTINCT - tab0.col1 + col2 * col1 FROM tab0
----
0
2752
7371

query I rowsort
SELECT ALL + col2 - + col2 * col2 AS col2 FROM tab2
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-3833
SELECT ALL 35 - tab0.col1 DIV tab0.col1 AS col1 FROM tab0
----
34
34
34

skipif mysql # not compatible
query I rowsort label-3833
SELECT ALL 35 - tab0.col1 / tab0.col1 AS col1 FROM tab0
----
34
34
34

query I rowsort
SELECT + + col0 + - col0 * 59 AS col0 FROM tab2 AS cor0
----
-406
-4524
-4582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 12 col2 FROM tab1 cor0
----
12
12
12

query I rowsort
SELECT col0 * + tab2.col0 * col0 + - col1 AS col1 FROM tab2
----
312
474493
493022

query I rowsort
SELECT - cor0.col2 * - 86 + cor0.col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
2511
4264
6270

query I rowsort
SELECT DISTINCT col1 * 36 * 65 AS col2 FROM tab1 AS cor0
----
23400
30420
60840

query I rowsort
SELECT DISTINCT - col1 * + col1 * col1 + col1 + + col2 * 37 FROM tab0 AS cor0
----
-634749
-750446
-912539

query I rowsort
SELECT DISTINCT col0 * - col2 * + col2 + col2 FROM tab0 AS cor0
----
-26103
-34
-598354

query I rowsort
SELECT ALL - - col1 + col1 * + col2 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - + cor0.col0 * ( 27 ) FROM tab2 AS cor0
----
-189
-2106
-2133

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3843
SELECT + col1 * + CAST( NULL AS SIGNED ) + + 7 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3843
SELECT + col1 * + CAST ( NULL AS INTEGER ) + + 7 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 + - 23 AS col0 FROM tab1 cor0
----
-33
-36
-49

query I rowsort
SELECT - - cor0.col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 * cor0.col1 + 53 AS col2 FROM tab2 AS cor0
----
1396
270
4655

query I rowsort
SELECT DISTINCT - - cor0.col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT col2 + - 18 * col2 * col0 AS col2 FROM tab2 AS cor0
----
-3375
-36478
-53998

query I rowsort
SELECT - col0 * 95 FROM tab0 cor0
----
-2280
-3325
-8455

query I rowsort
SELECT ALL - - col1 * - col0 + cor0.col2 * col0 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT DISTINCT + + col0 - - 59 FROM tab1 AS cor0
----
123
139
62

query I rowsort
SELECT + - col1 + - 40 FROM tab2 AS cor0
----
-57
-71
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + col2 col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3854
SELECT + col2 + 2 DIV - col0 col2 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3854
SELECT + col2 + 2 / - col0 col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT - col2 * 76 AS col1 FROM tab2
----
-1976
-2052
-2888

query I rowsort
SELECT + col2 + ( + 78 * col1 ) FROM tab0 AS cor0
----
6741
7180
7567

onlyif mysql # use DIV operator for integer division
query I rowsort label-3857
SELECT ALL - - col0 + + col0 DIV + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3857
SELECT ALL - - col0 + + col0 / + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT + col2 * col1 + + 45 FROM tab0 AS cor0
----
142
2883
7507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 35 + col2 col2 FROM tab2 AS cor0
----
61
62
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-3860
SELECT DISTINCT col2 * col1 * tab1.col0 + col2 DIV 50 FROM tab1
----
36481
4213
99841

skipif mysql # not compatible
query I rowsort label-3860
SELECT DISTINCT col2 * col1 * tab1.col0 + col2 / 50 FROM tab1
----
36481
4213
99841

onlyif mysql # use DIV operator for integer division
query I rowsort label-3861
SELECT + col1 * col2 + col2 DIV - col0 AS col0 FROM tab1
----
1247
1386
570

skipif mysql # not compatible
query I rowsort label-3861
SELECT + col1 * col2 + col2 / - col0 AS col0 FROM tab1
----
1247
1386
570

query I rowsort
SELECT DISTINCT tab2.col1 + - 74 FROM tab2
----
-15
-43
-57

query I rowsort
SELECT ALL + col2 * 27 + - col1 AS col0 FROM tab0
----
-70
2123
805

query I rowsort
SELECT DISTINCT col1 + + 54 FROM tab2
----
113
71
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3865
SELECT col2 + + 70 + tab1.col1 DIV tab1.col2 FROM tab1
----
124
127
166

skipif mysql # not compatible
query I rowsort label-3865
SELECT col2 + + 70 + tab1.col1 / tab1.col2 FROM tab1
----
124
127
166

query I rowsort
SELECT + col0 * - ( ( - col0 ) ) * - ( col1 ) FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT + + ( - 34 ) FROM tab1 AS cor0
----
-34
-34
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3868
SELECT - 7 + - col2 DIV cor0.col0 FROM tab1 cor0
----
-25
-7
-8

skipif mysql # not compatible
query I rowsort label-3868
SELECT - 7 + - col2 / cor0.col0 FROM tab1 cor0
----
-25
-7
-8

query I rowsort
SELECT + col2 * + 65 + + col0 FROM tab1
----
3513
3769
6320

query I rowsort
SELECT - ( - cor0.col2 ) * col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + + 67 AS col2 FROM tab0 cor0
----
67
67
67

query I rowsort
SELECT ALL + cor0.col1 + col1 * + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT col2 + col0 * col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * - col0 col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col1 * + 94 FROM tab2
----
1598
2914
5546

query I rowsort
SELECT ALL tab2.col1 * + tab2.col1 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 66d12b13327233058113a26801f3f4bd

query I rowsort
SELECT DISTINCT + 95 AS col0 FROM tab0
----
95

query I rowsort
SELECT ALL 43 * col0 * - 92 FROM tab2 AS cor0
----
-27692
-308568
-312524

onlyif mysql # use DIV operator for integer division
query I rowsort label-3879
SELECT + col2 DIV col1 AS col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3879
SELECT + col2 / col1 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - ( + 53 ) * col0 + 70 AS col2 FROM tab0
----
-1202
-1785
-4647

query I rowsort
SELECT ALL - col2 * col1 + - tab0.col0 * + col0 FROM tab0
----
-1322
-15383
-3414

query I rowsort
SELECT + cor0.col1 * col1 - - col0 FROM tab1 cor0
----
164
249
679

query I rowsort
SELECT ALL - - cor0.col0 - col2 * 82 FROM tab1 AS cor0
----
-4425
-4610
-7792

query I rowsort
SELECT DISTINCT + 5 AS col0 FROM tab2 AS cor0
----
5

query I rowsort
SELECT ALL - col0 * col1 * + col0 + + 64 FROM tab1 AS cor0
----
-170
-40896
-83136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 96 col0 FROM tab1
----
96
96
96

query I rowsort
SELECT ALL col2 * col1 + - 84 * col1 FROM tab1
----
-270
-780
156

onlyif mysql # use DIV operator for integer division
query I rowsort label-3888
SELECT - 53 DIV - col1 FROM tab2
----
0
1
3

skipif mysql # not compatible
query I rowsort label-3888
SELECT - 53 / - col1 FROM tab2
----
0
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 50 col0 FROM tab1
----
-50

query I rowsort
SELECT - 57 * col1 * + 18 FROM tab0 AS cor0
----
-88236
-93366
-99522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 + - col1 * - 31 col1 FROM tab2 AS cor0
----
1731
429
863

query I rowsort
SELECT - col2 * col1 * + col2 + - col0 + 87 * - col0 * - 11 FROM tab0
----
-526800
-70710
33363

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3893
SELECT DISTINCT + CAST( col0 AS SIGNED ) AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3893
SELECT DISTINCT + CAST ( col0 AS INTEGER ) AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + col1 + + col1 + col0 AS col2 FROM tab2
----
113
196
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-3895
SELECT - ( - col0 ) DIV col0 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3895
SELECT - ( - col0 ) / col0 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - 21 * - cor0.col2 * cor0.col1 + col1 AS col2 FROM tab0 cor0
----
156793
2134
59684

query I rowsort
SELECT col0 * - col1 - ( 69 ) AS col1 FROM tab1 AS cor0
----
-1109
-147
-709

query I rowsort
SELECT ALL - col1 + col2 + + 14 FROM tab1 AS cor0
----
42
61
97

query I rowsort
SELECT DISTINCT - col1 + ( ( - col2 ) ) FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - + col0 * 68 FROM tab2 AS cor0
----
-476
-5304
-5372

onlyif mysql # use DIV operator for integer division
query I rowsort label-3901
SELECT ALL + - col0 + 53 + 50 DIV col2 FROM tab1 AS cor0
----
-11
-27
50

skipif mysql # not compatible
query I rowsort label-3901
SELECT ALL + - col0 + 53 + 50 / col2 FROM tab1 AS cor0
----
-11
-27
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3902
SELECT - col0 * - CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-3902
SELECT - col0 * - CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - ( col1 ) * col1 - col2 FROM tab1 cor0
----
-157
-265
-730

query I rowsort
SELECT - cor1.col0 + cor1.col0 AS col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT 55 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + 39 * + 33 AS col0 FROM tab0 AS cor0
----
1287
1287
1287

query I rowsort
SELECT DISTINCT + 56 * col0 AS col2 FROM tab1 AS cor0
----
168
3584
4480

query I rowsort
SELECT ALL col2 + - col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 - 59 * + col2 AS col2 FROM tab0 AS cor0
----
-156
-2033
-4929

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 25 + + col0 * col0 - 69 col0 FROM tab1 AS cor0
----
-35
4052
6356

query I rowsort
SELECT DISTINCT + col0 * + col2 + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT col0 * 72 AS col1 FROM tab2 AS cor0
----
504
5616
5688

query I rowsort
SELECT + col0 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ( ( + cor0.col1 ) ) * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + 0 * + 10 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3916
SELECT - + 10 * col0 + - ( + col0 ) DIV - col1 FROM tab1 AS cor0
----
-30
-634
-794

skipif mysql # not compatible
query I rowsort label-3916
SELECT - + 10 * col0 + - ( + col0 ) / - col1 FROM tab1 AS cor0
----
-30
-634
-794

query I rowsort
SELECT ALL - + col2 + - col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3918
SELECT DISTINCT + col2 DIV col0 + ( col0 ) * - col0 FROM tab0 AS cor0
----
-1225
-575
-7921

skipif mysql # not compatible
query I rowsort label-3918
SELECT DISTINCT + col2 / col0 + ( col0 ) * - col0 FROM tab0 AS cor0
----
-1225
-575
-7921

query I rowsort
SELECT DISTINCT - + col0 + - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3920
SELECT DISTINCT - ( col1 ) + col2 * + ( + cor0.col2 ) - col2 * 30 DIV col0 AS col2 FROM tab0 AS cor0
----
-96
6606
962

skipif mysql # not compatible
query I rowsort label-3920
SELECT DISTINCT - ( col1 ) + col2 * + ( + cor0.col2 ) - col2 * 30 / col0 AS col2 FROM tab0 AS cor0
----
-96
6606
962

query I rowsort
SELECT 50 * col1 + + cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
1739
3852
4978

query I rowsort
SELECT - col1 * - ( - cor0.col1 * - col0 ) AS col0 FROM tab2 cor0
----
22831
271518
6727

query I rowsort
SELECT 40 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT DISTINCT col0 * 74 FROM tab1 AS cor0
----
222
4736
5920

query I rowsort
SELECT + - col0 * col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ( + tab0.col2 ) AS col0 FROM tab0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3927
SELECT ALL - cor0.col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3927
SELECT ALL - cor0.col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + - col0 * - col1 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + col1 * + 26 FROM tab0 cor0
----
2236
2366
2522

query I rowsort
SELECT ALL + + tab2.col2 + 44 AS col0 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to 8c9fe5c1fa5b9b6e8f3a55f5b8a9c1b4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 55 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT DISTINCT - col0 * ( 85 ) FROM tab0
----
-2040
-2975
-7565

query I rowsort
SELECT ALL tab2.col1 + + tab2.col2 AS col1 FROM tab2
----
55
58
85

query I rowsort
SELECT tab1.col1 + ( ( col0 ) ) * - col0 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT col1 * col0 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - - cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT col0 * + col0 + col1 * + 51 * + col1 FROM tab0 AS cor0
----
377772
430252
481084

query I rowsort
SELECT ALL + cor0.col1 * + cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3939
SELECT DISTINCT + ( - col1 ) + - col1 DIV cor0.col1 col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3939
SELECT DISTINCT + ( - col1 ) + - col1 / cor0.col1 col0 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT - + col1 + + col1 * col2 - - col2 AS col2 FROM tab2 AS cor0
----
1501
667
833

query I rowsort
SELECT DISTINCT + ( + col0 ) * col2 + 62 AS col1 FROM tab0 AS cor0
----
7360
854
97

query I rowsort
SELECT 66 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT ( + col2 ) * col0 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT 49 + col2 AS col1 FROM tab2
----
75
76
87

query I rowsort
SELECT + + col0 + 92 FROM tab0 AS cor0
----
116
127
181

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT - + col0 * col0 + 54 AS col1 FROM tab1 AS cor0
----
-4042
-6346
45

query I rowsort
SELECT DISTINCT - 60 * + col1 FROM tab1 AS cor0
----
-1560
-600
-780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT col0 * + col1 + tab1.col0 AS col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT DISTINCT ( - col2 ) + col1 * ( + col2 ) AS col1 FROM tab0
----
2805
7380
96

query I rowsort
SELECT + cor0.col0 * - 17 FROM tab0 AS cor0
----
-1513
-408
-595

query I rowsort
SELECT DISTINCT 3 * 25 AS col1 FROM tab1 AS cor0
----
75

query I rowsort
SELECT ALL - - col2 * + col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT + 98 * col0 * + col1 FROM tab2 AS cor0
----
131614
21266
450996

query I rowsort
SELECT ( col0 ) * - col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 + - cor0.col0 * - col2 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col0 + col0 * col0 AS col1 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL 98 * + col2 + col0 FROM tab0 AS cor0
----
133
3258
8125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col2 col2 FROM tab0, tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3961
SELECT col2 DIV tab1.col1 + col0 AS col0 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-3961
SELECT col2 / tab1.col1 + col0 AS col0 FROM tab1
----
5
69
87

query I rowsort
SELECT col0 + + col0 * - col2 AS col1 FROM tab0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT ALL ( - col2 ) + - col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT + cor0.col1 * - col0 + - col1 - col2 FROM tab2 AS cor0
----
-1398
-275
-4687

query I rowsort
SELECT ALL col0 * col1 * col0 FROM tab0 cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + 29 * cor0.col0 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
210
2340
2370

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3968
SELECT CAST( NULL AS SIGNED ) * col0 + + col2 - + 75 * 98 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3968
SELECT CAST ( NULL AS INTEGER ) * col0 + + col2 - + 75 * 98 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - cor0.col0 + 29 * - cor0.col0 FROM tab2 AS cor0
----
-196
-2184
-2212

query I rowsort
SELECT ALL 19 AS col0 FROM tab0 AS cor0
----
19
19
19

query I rowsort
SELECT - cor0.col2 + + col2 - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT 82 - col0 FROM tab0 cor0
----
-7
47
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3973
SELECT DISTINCT CAST( 86 AS SIGNED ) * col1 FROM tab2 AS cor0
----
1462
2666
5074

skipif mysql # not compatible
query I rowsort label-3973
SELECT DISTINCT CAST ( 86 AS INTEGER ) * col1 FROM tab2 AS cor0
----
1462
2666
5074

query I rowsort
SELECT + + cor0.col2 + + cor0.col0 - col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 22 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT + ( col1 + col2 ) FROM tab1
----
109
67
80

query I rowsort
SELECT ALL - ( + col1 * - col2 ) + + col0 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT + col0 * col2 + - col1 FROM tab2
----
158
1969
2985

query I rowsort
SELECT DISTINCT 61 * 54 + col1 AS col0 FROM tab2
----
3311
3325
3353

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3980
SELECT ALL CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3980
SELECT ALL CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL 99 * col1 AS col0 FROM tab1 AS cor0
----
1287
2574
990

query I rowsort
SELECT + 5 - + cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to a5bfaad1c2746f2d0b4b9537128f385f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + ( col1 ) ) col2 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL 31 * - col1 + col2 FROM tab2 cor0
----
-1803
-489
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-3985
SELECT ALL col0 DIV + cor0.col2 + - col2 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-3985
SELECT ALL col0 / + cor0.col2 + - col2 FROM tab1 AS cor0
----
-54
-56
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3986
SELECT DISTINCT + + cor0.col1 DIV col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3986
SELECT DISTINCT + + cor0.col1 / col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT - - col0 + col2 * col2 * col1 AS col1 FROM tab1 AS cor0
----
119888
32554
75819

query I rowsort
SELECT DISTINCT + col1 * + col1 - - col0 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT - col1 + - col1 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT 36 + col2 * col1 FROM tab2 AS cor0
----
1570
682
873

query I rowsort
SELECT col1 + - col1 * - col0 - + col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-2998
-58
-6627

query I rowsort
SELECT ALL + col0 - + 23 * + col2 FROM tab2
----
-520
-614
-795

query I rowsort
SELECT ALL - - cor0.col0 * col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col0 * + 96 FROM tab1 AS cor0
----
-288
-6144
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3995
SELECT ALL col1 + CAST( - col0 AS SIGNED ) AS col0 FROM tab0 cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-3995
SELECT ALL col1 + CAST ( - col0 AS INTEGER ) AS col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT DISTINCT + col1 * ( 46 ) FROM tab0 AS cor0
----
3956
4186
4462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 42 * 75 * col2 col1 FROM tab1 AS cor0
----
170103
179614
302480

query I rowsort
SELECT col2 + + ( 95 ) * col2 AS col2 FROM tab1
----
5184
5472
9216

query I rowsort
SELECT ALL cor0.col0 + - cor0.col2 + col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - col0 * cor0.col2 + col1 * col1 AS col0 FROM tab0 AS cor0
----
6604
9374
983

query I rowsort
SELECT ALL col1 * - 77 + - col2 AS col1 FROM tab2 AS cor0
----
-1347
-2414
-4569

query I rowsort
SELECT DISTINCT - + col2 - - ( 87 ) AS col1 FROM tab1 AS cor0
----
-9
30
33

query I rowsort
SELECT DISTINCT + col0 - - 24 AS col1 FROM tab0 AS cor0
----
113
48
59

query I rowsort
SELECT ALL - + col0 * 74 FROM tab0 cor0
----
-1776
-2590
-6586

query I rowsort
SELECT ALL + + col2 * ( + ( col0 ) ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col1 * ( col2 * col1 + col0 ) AS col2 FROM tab2 AS cor0
----
12325
26164
95108

onlyif mysql # use DIV operator for integer division
query I rowsort label-4007
SELECT - col2 + - col2 DIV 52 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-4007
SELECT - col2 + - col2 / 52 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT - ( + ( col0 ) ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + + cor0.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 70 + 30 col1 FROM tab1 AS cor0
----
100

query I rowsort
SELECT DISTINCT col1 + col1 + cor0.col0 FROM tab2 AS cor0
----
113
196
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * col1 col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - col1 + + 46 FROM tab2 AS cor0
----
-13
15
29

query I rowsort
SELECT - + col0 * + ( - cor0.col2 ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col2 * + 21 AS col1 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT - col1 * ( + col2 ) * + col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 * - col2 col0 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT + - 45 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 63e2b488a204f83ec8c063dafdfd4371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4019
SELECT + col0 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4019
SELECT + col0 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 * 6 * + 24 FROM tab0 AS cor0
----
11808
144
4752

query I rowsort
SELECT ALL + + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT DISTINCT - col0 - col2 * 19 FROM tab2
----
-520
-572
-801

query I rowsort
SELECT + col2 * col2 * col2 AS col0 FROM tab0
----
1
35937
551368

query I rowsort
SELECT - 30 FROM tab0, tab1 AS cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

query I rowsort
SELECT ALL - col1 + + cor0.col2 * + cor0.col2 * - 89 FROM tab1 AS cor0
----
-259550
-289171
-820237

query I rowsort
SELECT col2 * 41 + cor0.col0 AS col2 FROM tab2 AS cor0
----
1114
1144
1637

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to 163d7732097d78f1cda7f65c2cea5a08

query I rowsort
SELECT + 33 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

query I rowsort
SELECT col0 * + ( + col0 ) * ( ( col0 ) + + tab0.col0 ) FROM tab0
----
1409938
27648
85750

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 + + col1 * + col0 AS col2 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT + ( - col0 + ( - 96 ) ) FROM tab0
----
-120
-131
-185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 33 * col0 col2 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT ALL + tab2.col0 * col1 + + col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT + col1 * - col0 + - ( col0 + tab1.col2 ) FROM tab1
----
-1216
-135
-761

query I rowsort
SELECT 51 * 45 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a132eb45147c1da362e6fa0f21aac479

onlyif mysql # use DIV operator for integer division
query I rowsort label-4037
SELECT - col0 * + col2 + 20 DIV col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-4037
SELECT - col0 * + col2 + 20 / col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + - col1 * ( - col2 ) AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col1 + - cor0.col0 * col2 * col0 AS col2 FROM tab1 AS cor0
----
-233482
-512
-614413

query I rowsort
SELECT + 23 + - 17 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT DISTINCT + - cor0.col1 + 37 AS col0 FROM tab2 AS cor0
----
-22
20
6

query I rowsort
SELECT DISTINCT col2 + - ( col1 ) FROM tab1 AS cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4043
SELECT ALL - cor0.col1 DIV - 59 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4043
SELECT ALL - cor0.col1 / - 59 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 41 + + col0 - cor0.col2 FROM tab1 cor0
----
-10
25
48

query I rowsort
SELECT col2 * - col2 + col0 * col0 FROM tab2 AS cor0
----
-680
4797
5408

query I rowsort
SELECT DISTINCT + 14 FROM tab1, tab2, tab1 AS cor0
----
14

query I rowsort
SELECT DISTINCT - 33 * col0 - + col2 FROM tab0 AS cor0
----
-1156
-3019
-825

query I rowsort
SELECT col0 + + col0 + - cor0.col1 FROM tab1 cor0
----
-20
118
147

query I rowsort
SELECT DISTINCT - - cor0.col1 + col0 AS col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + - col1 * - col2 * 39 + - 49 FROM tab1 AS cor0
----
22181
48623
54707

onlyif mysql # use DIV operator for integer division
query I rowsort label-4051
SELECT ALL - col2 + col2 DIV + cor0.col2 AS col1 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-4051
SELECT ALL - col2 + col2 / + cor0.col2 AS col1 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT DISTINCT - 92 + + cor0.col2 FROM tab1 AS cor0
----
-35
-38
4

query I rowsort
SELECT DISTINCT - ( col1 ) * col0 * + col0 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-106114
-1550
-359015

query I rowsort
SELECT ALL + + cor0.col2 * cor0.col1 + - cor0.col1 AS col2 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT - + 49 * col1 FROM tab0 AS cor0
----
-4214
-4459
-4753

onlyif mysql # use DIV operator for integer division
query I rowsort label-4056
SELECT ALL + col1 * + cor0.col2 + col0 - 3 DIV + cor0.col0 AS col2 FROM tab1 AS cor0
----
1328
1406
634

skipif mysql # not compatible
query I rowsort label-4056
SELECT ALL + col1 * + cor0.col2 + col0 - 3 / + cor0.col0 AS col2 FROM tab1 AS cor0
----
1328
1406
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-4057
SELECT DISTINCT - - col0 DIV - col2 AS col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4057
SELECT DISTINCT - - col0 / - col2 AS col2 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL col2 + + col1 * 60 FROM tab1 AS cor0
----
1614
657
876

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4059
SELECT CAST( NULL AS SIGNED ) - tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4059
SELECT CAST ( NULL AS INTEGER ) - tab0.col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 * - col1 ) AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col1 + col0 * + col0 FROM tab1
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col1 * + col1 col2 FROM tab2
----
-251
-3455
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-4063
SELECT DISTINCT - 52 + - cor0.col2 * - col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
-19
-51
30

skipif mysql # not compatible
query I rowsort label-4063
SELECT DISTINCT - 52 + - cor0.col2 * - col2 / + col2 AS col2 FROM tab0 AS cor0
----
-19
-51
30

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 * col1 FROM tab2 cor0
----
1475
629
806

query I rowsort
SELECT cor0.col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4066
SELECT DISTINCT + ( + col1 ) + + col0 DIV 27 FROM tab1 AS cor0
----
12
15
26

skipif mysql # not compatible
query I rowsort label-4066
SELECT DISTINCT + ( + col1 ) + + col0 / 27 FROM tab1 AS cor0
----
12
15
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4067
SELECT ALL - col2 + - col2 DIV + cor0.col0 - - col1 AS col2 FROM tab1 AS cor0
----
-46
-47
-84

skipif mysql # not compatible
query I rowsort label-4067
SELECT ALL - col2 + - col2 / + cor0.col0 - - col1 AS col2 FROM tab1 AS cor0
----
-46
-47
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * cor0.col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + + col2 * ( col1 ) + + cor0.col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + col1 + col1 - - col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ALL - col1 + + 99 * col1 AS col1 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT ( - col2 ) * - cor0.col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - cor0.col0 * ( col2 ) - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 + + col2 col0 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT + ( - col0 ) + + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL + + ( + cor0.col2 ) * + cor0.col1 * + col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - - col0 + - col2 * + ( 82 ) FROM tab0 AS cor0
----
-2682
-47
-6635

query I rowsort
SELECT ( col0 ) * - col1 + col1 FROM tab2
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4079
SELECT DISTINCT ( - col2 ) * + col2 + + CAST( + col1 AS SIGNED ) AS col0 FROM tab0
----
-1003
-6633
96

skipif mysql # not compatible
query I rowsort label-4079
SELECT DISTINCT ( - col2 ) * + col2 + + CAST ( + col1 AS INTEGER ) AS col0 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT + - 36 AS col1 FROM tab0, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to aea3eb70e9270b660d4c81f39b11409b

query I rowsort
SELECT + 30 AS col0 FROM tab0, tab0 cor0 CROSS JOIN tab2
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4082
SELECT 94 - col1 DIV + col0 AS col1 FROM tab0 AS cor0
----
91
92
93

skipif mysql # not compatible
query I rowsort label-4082
SELECT 94 - col1 / + col0 AS col1 FROM tab0 AS cor0
----
91
92
93

query I rowsort
SELECT DISTINCT col2 * 50 + col2 FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT DISTINCT - col1 * + ( 8 + - col0 ) FROM tab1 AS cor0
----
-130
560
936

query I rowsort
SELECT DISTINCT + 79 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab2, tab1 AS cor2
----
79

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 AS col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col2 * + col0 - ( - col2 * ( - col2 ) ) FROM tab1 AS cor0
----
-16896
-3078
-6897

query I rowsort
SELECT ALL + col2 * col0 + + 53 FROM tab2 AS cor0
----
2081
242
3055

query I rowsort
SELECT DISTINCT - 71 FROM tab1, tab2 AS cor0
----
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * - col1 * 99 col0 FROM tab0
----
-280962
-738738
-9603

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4091
SELECT ALL col0 * CAST( cor0.col2 AS SIGNED ) * col0 col0 FROM tab1 cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4091
SELECT ALL col0 * CAST ( cor0.col2 AS INTEGER ) * col0 col0 FROM tab1 cor0
----
233472
486
614400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4092
SELECT ALL - + cor0.col1 + - CAST( 26 AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
-1593
-459
-837

skipif mysql # not compatible
query I rowsort label-4092
SELECT ALL - + cor0.col1 + - CAST ( 26 AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
-1593
-459
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 + 73 col1 FROM tab2
----
14
42
56

query I rowsort
SELECT DISTINCT + col1 + col2 * col2 AS col2 FROM tab2 cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col0 + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT + 91 * - col1 + col0 FROM tab1 AS cor0
----
-1103
-2363
-846

query I rowsort
SELECT + + ( col0 ) + col0 * col0 FROM tab1 AS cor0
----
12
4160
6480

skipif mysql # not compatible
query I rowsort
SELECT - ( ( - cor0.col2 ) ) * + CAST ( col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col0 * col2 + + col2 * - col1 FROM tab0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4100
SELECT ALL cor1.col2 DIV + 74 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-4100
SELECT ALL cor1.col2 / + 74 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT DISTINCT 8 AS col2 FROM tab0
----
8

query I rowsort
SELECT DISTINCT - 69 AS col1 FROM tab2, tab2 cor0
----
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-4103
SELECT - col1 DIV - col0 AS col1 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4103
SELECT - col1 / - col0 AS col1 FROM tab2 cor0
----
0
0
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4104
SELECT ALL + CAST( + 37 AS SIGNED ) FROM tab1 AS cor0
----
37
37
37

skipif mysql # not compatible
query I rowsort label-4104
SELECT ALL + CAST ( + 37 AS INTEGER ) FROM tab1 AS cor0
----
37
37
37

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 9af67d6f98010464af5d560bf949d487

query I rowsort
SELECT + 70 FROM tab1
----
70
70
70

query I rowsort
SELECT DISTINCT - col2 + + col0 * col0 AS col2 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT 81 * + col0 * + tab0.col1 + + col1 AS col1 FROM tab0
----
167270
275092
656110

query I rowsort
SELECT - col1 * col1 + - col2 FROM tab0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT tab1.col0 * - col1 + + col1 * + 75 AS col1 FROM tab1
----
-65
110
1872

onlyif mysql # use DIV operator for integer division
query I rowsort label-4111
SELECT + 31 + - col2 DIV + tab0.col1 + col0 FROM tab0
----
120
55
66

skipif mysql # not compatible
query I rowsort label-4111
SELECT + 31 + - col2 / + tab0.col1 + col0 FROM tab0
----
120
55
66

query I rowsort
SELECT - 98 * + col1 AS col2 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT + ( col0 ) * col0 * + col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT ALL - + ( - cor0.col2 ) FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4115
SELECT ALL + col2 + + col2 DIV - col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4115
SELECT ALL + col2 + + col2 / - col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

query I rowsort
SELECT - col1 * - col2 * col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - col0 * ( + ( cor0.col2 ) ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col0 + - cor0.col2 * - 54 * col2 AS col1 FROM tab0 AS cor0
----
19
363007
58782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 76 * col1 col2 FROM tab1
----
48640
5928
79040

query I rowsort
SELECT - cor0.col2 + + 54 * - 33 AS col0 FROM tab1 cor0
----
-1836
-1839
-1878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4122
SELECT + - col1 + + CAST( 52 AS SIGNED ) FROM tab2 AS cor0
----
-7
21
35

skipif mysql # not compatible
query I rowsort label-4122
SELECT + - col1 + + CAST ( 52 AS INTEGER ) FROM tab2 AS cor0
----
-7
21
35

query I rowsort
SELECT - col2 * + col1 + 32 * col2 FROM tab0 AS cor0
----
-1782
-4838
-65

query I rowsort
SELECT col2 * - ( col0 ) * col0 AS col1 FROM tab0 cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT col0 + + 23 AS col1 FROM tab1 AS cor0
----
103
26
87

query I rowsort
SELECT - cor0.col2 + ( ( col1 ) ) AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - col1 * col2 + - col2 * col0 * + col0 FROM tab1
----
-1890
-234042
-615648

query I rowsort
SELECT col1 * + col2 - 6 FROM tab2
----
1528
640
831

onlyif mysql # use DIV operator for integer division
query I rowsort label-4129
SELECT - col1 + col2 DIV + col1 AS col2 FROM tab1
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-4129
SELECT - col1 + col2 / + col1 AS col2 FROM tab1
----
-24
-5
-6

query I rowsort
SELECT - - 46 * + col0 AS col0 FROM tab2 AS cor0
----
322
3588
3634

query I rowsort
SELECT ALL - cor0.col1 + 96 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to ce7473a7b4b46f8daa10587db9b0f9ce

query I rowsort
SELECT ALL + + cor0.col0 + col0 + - col1 FROM tab1 AS cor0
----
-20
118
147

query I rowsort
SELECT ALL - + cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 * + ( 56 ) AS col2 FROM tab1 AS cor0
----
3024
3192
5376

query I rowsort
SELECT ALL + col0 + ( col0 ) FROM tab1 cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 + - col1 ) col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + ( col2 ) AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT 78 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT + col0 * + ( col1 ) * - col2 AS col1 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - col2 * col0 + col2 * - ( col1 ) + + col2 AS col0 FROM tab1 AS cor0
----
-1512
-4161
-8832

query I rowsort
SELECT + 22 + - 47 * + col1 * col1 FROM tab2 AS cor0
----
-13561
-163585
-45145

query I rowsort
SELECT + + ( col0 ) + - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4143
SELECT col0 DIV + tab2.col0 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4143
SELECT col0 / + tab2.col0 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT - 25 FROM tab0, tab2 cor0
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

query I rowsort
SELECT col0 * col2 * col0 + cor0.col2 AS col2 FROM tab2 AS cor0
----
1350
158210
237196

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4146
SELECT DISTINCT col0 + CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4146
SELECT DISTINCT col0 + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 + 88 col1 FROM tab2
----
121
67
92

query I rowsort
SELECT ALL + 2 AS col2 FROM tab1, tab1 cor0 CROSS JOIN tab2
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-4149
SELECT + - 34 + col2 DIV col1 AS col0 FROM tab1 AS cor0
----
-27
-29
-32

skipif mysql # not compatible
query I rowsort label-4149
SELECT + - 34 + col2 / col1 AS col0 FROM tab1 AS cor0
----
-27
-29
-32

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 877a8dbac0e29b86e845fb64ed9d2242

query I rowsort
SELECT DISTINCT + col1 + - col2 * col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT col1 * col1 + 94 AS col1 FROM tab1 AS cor0
----
194
263
770

query I rowsort
SELECT - - col0 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + col1 * - col2 + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4155
SELECT cor0.col2 DIV cor0.col0 + - col1 AS col1 FROM tab0 cor0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-4155
SELECT cor0.col2 / cor0.col0 + - col1 AS col1 FROM tab0 cor0
----
-85
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 col0 FROM tab0
----
46
46
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-4157
SELECT DISTINCT - col1 + - col2 DIV col1 + col1 FROM tab2
----
-2
0

skipif mysql # not compatible
query I rowsort label-4157
SELECT DISTINCT - col1 + - col2 / col1 + col1 FROM tab2
----
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 ) + col2 * + ( + col1 * - col1 ) col0 FROM tab0
----
-244044
-678953
-9374

query I rowsort
SELECT ALL + ( + col1 ) * + col2 FROM tab0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4160
SELECT ALL CAST( NULL AS SIGNED ) * col1 - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4160
SELECT ALL CAST ( NULL AS INTEGER ) * col1 - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + + 79 - + col1 * - 65 AS col0 FROM tab1
----
1020
1823
786

query I rowsort
SELECT ALL 12 + col1 + col0 FROM tab2
----
108
149
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 29 col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT DISTINCT - - 44 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
44

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) * 80 + - 54 * + col1 AS col1 FROM tab1 AS cor0
----
-1340
-1742
-3484

query I rowsort
SELECT ALL - + 45 + - col1 AS col2 FROM tab0 AS cor0
----
-131
-136
-142

query I rowsort
SELECT ALL + + 23 * - col2 FROM tab2 AS cor0
----
-598
-621
-874

query I rowsort
SELECT DISTINCT 35 * col0 AS col2 FROM tab0 cor0
----
1225
3115
840

query I rowsort
SELECT ALL + 22 * - col2 FROM tab0 AS cor0
----
-1804
-22
-726

query I rowsort
SELECT + 94 + - col2 AS col1 FROM tab1 AS cor0
----
-2
37
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4171
SELECT - col0 * + col2 * CAST( - cor0.col0 AS SIGNED ) + col2 AS col0 FROM tab2 AS cor0
----
1350
158210
237196

skipif mysql # not compatible
query I rowsort label-4171
SELECT - col0 * + col2 * CAST ( - cor0.col0 AS INTEGER ) + col2 AS col0 FROM tab2 AS cor0
----
1350
158210
237196

query I rowsort
SELECT tab0.col2 + cor0.col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to c4b3f256aed754fcefbf420423e5b6e1

query I rowsort
SELECT DISTINCT 76 AS col1 FROM tab0, tab2 AS cor0
----
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4174
SELECT + col0 DIV 77 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4174
SELECT + col0 / 77 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT - + col0 + - col0 * + ( - cor0.col1 ) FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + cor0.col1 * - 21 FROM tab2, tab0 AS cor0
----
9 values hashing to 94672f86f13288ebf1957fd941c067dd

query I rowsort
SELECT DISTINCT - col0 + - cor0.col0 + col1 FROM tab1 AS cor0
----
-118
-147
20

query I rowsort
SELECT col0 * col0 * col1 + 64 + col0 FROM tab1
----
301
41088
83344

query I rowsort
SELECT + 60 + + col1 FROM tab1 AS cor0
----
70
73
86

query I rowsort
SELECT DISTINCT - 19 + col1 + + col1 FROM tab0 AS cor0
----
153
163
175

query I rowsort
SELECT ALL 52 * - col0 - col1 AS col1 FROM tab2 AS cor0
----
-395
-4115
-4125

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4182
SELECT DISTINCT + - CAST( NULL AS SIGNED ) / - cor0.col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4182
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) / - cor0.col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col1 + - 56 FROM tab2 AS cor0
----
-115
-73
-87

query I rowsort
SELECT - cor0.col1 - - 8 FROM tab1 AS cor0
----
-18
-2
-5

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 + col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT 35 AS col1 FROM tab1, tab1 AS cor0
----
35

query I rowsort
SELECT + 36 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT + ( col1 ) * + 46 * col0 FROM tab2 AS cor0
----
211692
61778
9982

query I rowsort
SELECT DISTINCT col2 * col0 + 3 FROM tab0 AS cor0
----
38
7301
795

query I rowsort
SELECT DISTINCT - ( col0 ) * + col0 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-4191
SELECT ALL 30 DIV - col0 FROM tab1 AS cor0
----
-10
0
0

skipif mysql # not compatible
query I rowsort label-4191
SELECT ALL 30 / - col0 FROM tab1 AS cor0
----
-10
0
0

query I rowsort
SELECT DISTINCT + - 70 AS col2 FROM tab0 cor0
----
-70

query I rowsort
SELECT col2 + + tab0.col0 * col2 AS col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT - + col1 * + col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + col1 * col2 * col0 AS col1 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col2 + ( col0 ) AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + col0 + - ( - col0 ) + - cor0.col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4198
SELECT ALL - col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4198
SELECT ALL - col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * - 35 AS col2 FROM tab0 AS cor0
----
1155
2870
35

query I rowsort
SELECT ALL - 6 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 8be8910507908e6353d02a545b748252

query I rowsort
SELECT - ( 32 ) * - col0 AS col1 FROM tab0 AS cor0
----
1120
2848
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4202
SELECT - CAST( 63 AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
-37
-50
-53

skipif mysql # not compatible
query I rowsort label-4202
SELECT - CAST ( 63 AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
-37
-50
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 53 + col2 * col0 col2 FROM tab0
----
-18
7245
739

query I rowsort
SELECT ALL - col0 * tab1.col0 + - col1 AS col2 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT DISTINCT col2 * - col0 + col1 AS col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - col2 + col2 * cor0.col2 FROM tab1 cor0
----
2862
3192
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-4207
SELECT ALL ( col1 ) * col1 DIV col0 + - col1 - - col2 AS col1 FROM tab1 AS cor0
----
253
48
85

skipif mysql # not compatible
query I rowsort label-4207
SELECT ALL ( col1 ) * col1 / col0 + - col1 - - col2 AS col1 FROM tab1 AS cor0
----
253
48
85

query I rowsort
SELECT + col1 + col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4209
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * - col2 - col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4209
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * - col2 - col2 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor2.col1 * 34 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
-2924
-3094
-3298

query I rowsort
SELECT DISTINCT 72 * col0 FROM tab2 AS cor0
----
504
5616
5688

query I rowsort
SELECT DISTINCT col0 * - cor0.col2 - ( - col0 * + col2 ) AS col0 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 * - col0 col0 FROM tab1 cor0
----
-204
-4352
-5440

query I rowsort
SELECT col1 + + cor0.col1 AS col2 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT DISTINCT cor0.col1 * + cor0.col1 + col0 AS col2 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT - 76 * col1 FROM tab1 AS cor0
----
-1976
-760
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-4217
SELECT DISTINCT - - 76 DIV - cor0.col0 FROM tab2 cor0
----
-10
0

skipif mysql # not compatible
query I rowsort label-4217
SELECT DISTINCT - - 76 / - cor0.col0 FROM tab2 cor0
----
-10
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col1 + + 22 col2 FROM tab1 AS cor0
----
-1018
-56
-618

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 62 + + col0 col0 FROM tab0 AS cor0
----
151
86
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4220
SELECT DISTINCT - - col0 * + col2 + col1 * + ( - col1 + CAST( NULL AS SIGNED ) ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4220
SELECT DISTINCT - - col0 * + col2 + col1 * + ( - col1 + CAST ( NULL AS INTEGER ) ) FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4221
SELECT + cor0.col0 DIV 90 AS col1 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-4221
SELECT + cor0.col0 / 90 AS col1 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT + col0 * 98 FROM tab1
----
294
6272
7840

query I rowsort
SELECT tab2.col0 + - col2 * - col2 FROM tab2
----
1523
736
754

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 AS REAL ) * col0 + col1 * tab1.col2 AS col0 FROM tab1
----
1413
4666
7648

query I rowsort
SELECT - col1 * col2 * + col2 + + col0 AS col1 FROM tab2
----
-22592
-24469
-39806

query I rowsort
SELECT col1 + + ( col2 ) FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT - col2 + 79 * col2 * 38 AS col0 FROM tab2
----
114038
78026
81027

query I rowsort
SELECT - - col0 * col0 + + cor0.col1 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - - col2 + - col0 * col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + 28 * + col2 + 81 FROM tab1 AS cor0
----
1593
1677
2769

query I rowsort
SELECT + col1 + + 34 FROM tab2 AS cor0
----
51
65
93

query I rowsort
SELECT + 90 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT DISTINCT - ( col0 + + ( col1 ) ) FROM tab0
----
-110
-132
-180

query I rowsort
SELECT - ( + col1 ) * col1 AS col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL ( col2 ) * + 63 FROM tab0
----
2079
5166
63

query I rowsort
SELECT - cor0.col0 * + tab0.col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 3f7ab940a743ed4256c99c2a07a2b971

query I rowsort
SELECT - tab2.col0 + cor0.col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to fe77e742ee356950e73e6d48a37f2637

query I rowsort
SELECT + col2 * - 77 * + col0 + - 47 - + 70 FROM tab1 AS cor0
----
-12591
-281013
-591477

query I rowsort
SELECT 41 + cor0.col1 * + col0 AS col2 FROM tab2 AS cor0
----
1384
258
4643

query I rowsort
SELECT + 90 + ( - col2 ) AS col0 FROM tab0 AS cor0
----
57
8
89

query I rowsort
SELECT DISTINCT + + 31 + + ( - col0 ) FROM tab1 AS cor0
----
-33
-49
28

query I rowsort
SELECT DISTINCT ( + 30 ) * col1 FROM tab1 AS cor0
----
300
390
780

query I rowsort
SELECT - col1 * + 36 + + col2 FROM tab2
----
-1089
-2098
-574

query I rowsort
SELECT - col1 + 66 FROM tab0
----
-20
-25
-31

query I rowsort
SELECT + 17 + 79 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT col0 + 71 FROM tab2
----
149
150
78

query I rowsort
SELECT - col0 * + 52 + col2 + tab0.col1 AS col0 FROM tab0
----
-1129
-1722
-4455

query I rowsort
SELECT ALL - col1 + col0 + + col0 AS col1 FROM tab0
----
-27
-38
87

query I rowsort
SELECT DISTINCT - col1 * 73 FROM tab0
----
-6278
-6643
-7081

query I rowsort
SELECT + + 28 + col0 * + col2 FROM tab0 cor0
----
63
7326
820

query I rowsort
SELECT DISTINCT col0 * + col0 + + col2 * cor0.col0 - + cor0.col2 AS col1 FROM tab0 AS cor0
----
1259
1335
15137

query I rowsort
SELECT DISTINCT - cor0.col2 + - 49 * - col0 FROM tab1 AS cor0
----
3079
3824
93

query I rowsort
SELECT - ( - col2 ) * col0 + ( + col2 ) AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT 47 AS col0 FROM tab0 cor0
----
47

query I rowsort
SELECT ALL + col1 + 27 AS col0 FROM tab1 AS cor0
----
37
40
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-4256
SELECT - 40 - cor0.col2 DIV col2 AS col0 FROM tab1 cor0
----
-41
-41
-41

skipif mysql # not compatible
query I rowsort label-4256
SELECT - 40 - cor0.col2 / col2 AS col0 FROM tab1 cor0
----
-41
-41
-41

query I rowsort
SELECT ALL - ( - col2 ) * col0 + + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col2 * col0 + + col0 * - col0 FROM tab1 AS cor0
----
-448
1280
153

query I rowsort
SELECT - col2 * + col0 * + 35 AS col1 FROM tab2
----
-105070
-6615
-70980

query I rowsort
SELECT ALL col1 * ( tab2.col1 ) FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL - ( + 86 * - tab1.col2 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 9346b2fda1338626f0f4ffd24c1b1c6a

onlyif mysql # use DIV operator for integer division
query I rowsort label-4262
SELECT - col1 DIV 82 + 66 + col2 FROM tab2 AS cor0
----
104
92
93

skipif mysql # not compatible
query I rowsort label-4262
SELECT - col1 / 82 + 66 + col2 FROM tab2 AS cor0
----
104
92
93

query I rowsort
SELECT - col2 + 84 * col0 AS col1 FROM tab2
----
561
6526
6598

query I rowsort
SELECT - - ( - col2 ) * col1 + + ( - 85 * col1 + + cor0.col1 * cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-2752
-6916
1067

onlyif mysql # use DIV operator for integer division
query I rowsort label-4265
SELECT + ( col1 ) * col2 DIV 64 col0 FROM tab0 AS cor0
----
1
116
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4265
SELECT + ( col1 ) * col2 / 64 col0 FROM tab0 AS cor0
----
1
116
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-4266
SELECT + cor0.col0 + col0 DIV col1 + + col0 * + col2 FROM tab2 AS cor0
----
196
2107
3085

skipif mysql # not compatible
query I rowsort label-4266
SELECT + cor0.col0 + col0 / col1 + + col0 * + col2 FROM tab2 AS cor0
----
196
2107
3085

query I rowsort
SELECT DISTINCT + + 86 FROM tab0 AS cor0
----
86

query I rowsort
SELECT ALL cor0.col1 * col0 + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * + 41 col1 FROM tab2
----
11849
142721
39401

query I rowsort
SELECT DISTINCT + 21 AS col1 FROM tab1, tab0 AS cor0
----
21

query I rowsort
SELECT - - 1 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT + ( 50 ) AS col2 FROM tab2 AS cor0
----
50
50
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col2 * + col1 col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL - ( - cor0.col1 ) + - col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - col0 - - col2 AS col1 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT col0 - + cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + - col2 * - ( col1 ) FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT + - cor0.col0 + col1 * + col0 AS col2 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + col1 * col2 - 94 FROM tab2 cor0
----
1440
552
743

query I rowsort
SELECT + ( col0 ) * col1 * col2 + + col1 * + 41 AS col1 FROM tab1 AS cor0
----
100373
36890
5278

query I rowsort
SELECT + 75 - col0 AS col2 FROM tab0 cor0
----
-14
40
51

query I rowsort
SELECT + + col1 + col2 + - col1 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col2 * col1 * - 64 - col2 FROM tab2 AS cor0
----
41306
53541
98150

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col1 col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT - col0 * + 4 * + col0 - col0 FROM tab0 AS cor0
----
-2328
-31773
-4935

query I rowsort
SELECT - col0 + ( - col0 ) FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT - 91 AS col0 FROM tab2
----
-91

query I rowsort
SELECT - + col1 * + col2 - + 24 * - col2 FROM tab0 AS cor0
----
-2046
-5494
-73

query I rowsort
SELECT - + col1 * + ( col1 ) - + col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + col0 + - col2 + - col2 AS col1 FROM tab0 AS cor0
----
-42
-75
33

query I rowsort
SELECT ALL - col0 * 56 AS col2 FROM tab1 cor0
----
-168
-3584
-4480

query I rowsort
SELECT ALL col0 * + col1 * 60 FROM tab0 cor0
----
123840
203700
485940

query I rowsort
SELECT DISTINCT + col1 * tab0.col1 AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT col0 * col2 - - 72 AS col1 FROM tab1 AS cor0
----
234
3720
7752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + - col2 + col1 col2 FROM tab1 AS cor0
----
-111
-163
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-4297
SELECT DISTINCT 56 DIV tab2.col1 FROM tab2
----
0
1
3

skipif mysql # not compatible
query I rowsort label-4297
SELECT DISTINCT 56 / tab2.col1 FROM tab2
----
0
1
3

query I rowsort
SELECT + col2 - + col1 AS col2 FROM tab1
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + cor0.col2 col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 00f153c5d80e692faff5018d8701b92d

query I rowsort
SELECT ALL - 1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4301
SELECT + cor0.col0 + col0 DIV + col1 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-4301
SELECT + cor0.col0 + col0 / + col1 FROM tab2 AS cor0
----
7
79
83

query I rowsort
SELECT - + col1 + cor0.col2 AS col0 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + tab2.col1 + - 50 * + tab2.col1 FROM tab2
----
-1519
-2891
-833

query I rowsort
SELECT ALL - 21 AS col0 FROM tab0 AS cor0
----
-21
-21
-21

query I rowsort
SELECT ALL + 50 * + col2 AS col1 FROM tab1
----
2700
2850
4800

query I rowsort
SELECT + col2 * + col1 + + col0 AS col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL - col2 * + tab0.col0 AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4308
SELECT + ( col2 ) * - CAST( NULL AS DECIMAL ) * - ( col2 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4308
SELECT + ( col2 ) * - CAST ( NULL AS REAL ) * - ( col2 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4309
SELECT col0 + col0 * col1 DIV 10 FROM tab0 AS cor0
----
230
374
898

skipif mysql # not compatible
query I rowsort label-4309
SELECT col0 + col0 * col1 / 10 FROM tab0 AS cor0
----
230
374
898

query I rowsort
SELECT + ( col1 ) * - ( col1 * + col2 ) AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL - + cor0.col1 - - col2 * + col0 * col2 FROM tab2 AS cor0
----
114059
5072
52669

query I rowsort
SELECT - 34 * + col0 * col2 FROM tab2 cor0
----
-102068
-6426
-68952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + 36 * col0 col1 FROM tab2 AS cor0
----
221
2749
2827

query I rowsort
SELECT DISTINCT + + 67 + 85 AS col0 FROM tab2 AS cor0
----
152

query I rowsort
SELECT + - 80 * + col1 AS col1 FROM tab1 AS cor0
----
-1040
-2080
-800

query I rowsort
SELECT DISTINCT + col2 * - col2 - + col0 AS col2 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT DISTINCT + col0 * + col0 + col0 + col1 AS col0 FROM tab2 AS cor0
----
6221
6337
87

query I rowsort
SELECT DISTINCT - cor0.col1 + + 18 + cor0.col0 FROM tab1 cor0
----
-5
72
85

query I rowsort
SELECT + tab1.col1 * col2 + col2 AS col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT col1 * col0 + - 14 + + col0 AS col2 FROM tab0
----
2074
3416
8174

onlyif mysql # use DIV operator for integer division
query I rowsort label-4321
SELECT - col0 + + cor0.col0 DIV col0 FROM tab0 cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4321
SELECT - col0 + + cor0.col0 / col0 FROM tab0 cor0
----
-23
-34
-88

query I rowsort
SELECT + + col2 + - col0 * cor0.col2 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT - col0 * + ( - tab1.col0 * col2 ) - - 45 * tab1.col0 AS col0 FROM tab1
----
236352
618000
621

query I rowsort
SELECT ALL col0 * col0 + col0 + col2 FROM tab0
----
1261
633
8092

onlyif mysql # use DIV operator for integer division
query I rowsort label-4325
SELECT DISTINCT + col0 DIV - col1 + 60 AS col1 FROM tab1
----
54
60

skipif mysql # not compatible
query I rowsort label-4325
SELECT DISTINCT + col0 / - col1 + 60 AS col1 FROM tab1
----
54
60

query I rowsort
SELECT DISTINCT ( col1 ) * + col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT + 99 + col0 * col1 FROM tab2
----
1442
316
4701

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 88 col1 FROM tab2 AS cor0
----
-616
-6864
-6952

query I rowsort
SELECT + 97 * col2 AS col2 FROM tab2 cor0
----
2522
2619
3686

query I rowsort
SELECT DISTINCT + ( 30 ) FROM tab0 cor0
----
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 48 col0 FROM tab2 AS cor0
----
48
48
48

query I rowsort
SELECT DISTINCT - 45 + + col1 * - col1 AS col2 FROM tab0
----
-7441
-8326
-9454

query I rowsort
SELECT - + col2 * col0 - col2 * col1 FROM tab1 cor0
----
-1566
-4218
-8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4334
SELECT ALL - - CAST( NULL AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4334
SELECT ALL - - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL 99 * col2 * 71 + + ( tab0.col0 ) * col1 FROM tab0
----
10424
234021
584477

query I rowsort
SELECT ALL + col0 + + col0 * col0 AS col0 FROM tab1
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4337
SELECT ALL + col2 DIV - col2 + + 82 AS col2 FROM tab1 AS cor0
----
81
81
81

skipif mysql # not compatible
query I rowsort label-4337
SELECT ALL + col2 / - col2 + + 82 AS col2 FROM tab1 AS cor0
----
81
81
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4338
SELECT + tab0.col2 + col2 * + CAST( NULL AS SIGNED ) col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4338
SELECT + tab0.col2 + col2 * + CAST ( NULL AS INTEGER ) col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab2.col0 + col1 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT col0 + + tab2.col2 * 60 * col2 AS col0 FROM tab2
----
40638
43747
86719

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4341
SELECT col1 * CAST( - col2 AS SIGNED ) FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-4341
SELECT col1 * CAST ( - col2 AS INTEGER ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT tab0.col0 + 47 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 385c0443a3e5bd054d740b843e1d60b8

query I rowsort
SELECT ALL cor2.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4344
SELECT col0 * + CAST( - col2 AS SIGNED ) + + col2 * + col2 AS col2 FROM tab2
----
-1352
-1558
540

skipif mysql # not compatible
query I rowsort label-4344
SELECT col0 * + CAST ( - col2 AS INTEGER ) + + col2 * + col2 AS col2 FROM tab2
----
-1352
-1558
540

query I rowsort
SELECT - col0 * 21 + col0 AS col2 FROM tab0 AS cor0
----
-1780
-480
-700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4346
SELECT DISTINCT col0 + 0 DIV 1 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4346
SELECT DISTINCT col0 + 0 / 1 AS col1 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4347
SELECT DISTINCT - col1 DIV col2 AS col1 FROM tab0 cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4347
SELECT DISTINCT - col1 / col2 AS col1 FROM tab0 cor0
----
-1
-2
-97

query I rowsort
SELECT + - col2 * - col2 - - 19 FROM tab0 AS cor0
----
1108
20
6743

onlyif mysql # use DIV operator for integer division
query I rowsort label-4349
SELECT cor0.col0 DIV cor0.col0 + + col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4349
SELECT cor0.col0 / cor0.col0 + + col2 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4350
SELECT ALL - - col1 DIV - ( + col2 * col2 ) 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-4350
SELECT ALL - - col1 / - ( + col2 * col2 ) col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 * + 68 * col0 - + col0 AS col1 FROM tab0 AS cor0
----
2345
496175
53832

query I rowsort
SELECT DISTINCT + col2 * 68 + col1 FROM tab2 AS cor0
----
1827
1867
2601

query I rowsort
SELECT ALL - col0 - + 91 FROM tab0 AS cor0
----
-115
-126
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4354
SELECT - cor0.col2 * 32 + col0 DIV + col1 AS col1 FROM tab1 cor0
----
-1728
-1818
-3066

skipif mysql # not compatible
query I rowsort label-4354
SELECT - cor0.col2 * 32 + col0 / + col1 AS col1 FROM tab1 cor0
----
-1728
-1818
-3066

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + cor0.col2 + + col1 col1 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT + + col2 * 70 AS col2 FROM tab0 cor0
----
2310
5740
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4357
SELECT col0 * col1 + + col2 DIV + col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-4357
SELECT col0 * col1 + + col2 / + col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col0 * - col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT + 60 + col1 * + col0 AS col2 FROM tab1 AS cor0
----
1100
138
700

query I rowsort
SELECT DISTINCT + col2 * + 85 + - col0 * - col1 AS col0 FROM tab2
----
2512
4573
6812

query I rowsort
SELECT cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT + cor0.col0 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
3
64
80

query I rowsort
SELECT + 45 * col1 + col0 FROM tab0 AS cor0
----
3894
4184
4400

query I rowsort
SELECT DISTINCT + + col1 * col1 + 3 AS col1 FROM tab0 AS cor0
----
7399
8284
9412

query I rowsort
SELECT - + ( + col2 ) * cor0.col0 AS col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - - 79 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT + 58 * cor0.col1 AS col2 FROM tab0 AS cor0
----
4988
5278
5626

query I rowsort
SELECT col0 - 11 AS col1 FROM tab0 AS cor0
----
13
24
78

query I rowsort
SELECT - cor0.col1 * col0 + + col1 - + col0 AS col2 FROM tab1 AS cor0
----
-1107
-55
-694

query I rowsort
SELECT + col2 * ( + col1 ) + col0 FROM tab0 AS cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 36 col0 FROM tab1
----
36
36
36

query I rowsort
SELECT col2 + col2 * col2 * col2 FROM tab2
----
17602
19710
54910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * col2 col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-4374
SELECT ALL col2 + col1 DIV col0 col0 FROM tab1 AS cor0
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4374
SELECT ALL col2 + col1 / col0 col0 FROM tab1 AS cor0
----
57
62
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4375
SELECT + cor0.col0 * col1 + col0 DIV col1 - col2 FROM tab0 AS cor0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-4375
SELECT + cor0.col0 * col1 + col0 / col1 - col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL 77 - + col2 AS col0 FROM tab1 AS cor0
----
-19
20
23

query I rowsort
SELECT ALL - col0 * + col2 * - col1 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col1 col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - ( col2 ) + col0 * col1 * col2 FROM tab2
----
119626
50996
5832

query I rowsort
SELECT - col0 + - col1 - - col2 AS col1 FROM tab2
----
-11
-111
-58

query I rowsort
SELECT col0 + tab2.col2 * col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL + 85 AS col0 FROM tab1
----
85
85
85

query I rowsort
SELECT ALL ( col2 * - col2 ) FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL ( - tab0.col0 ) + + 47 AS col1 FROM tab0
----
-42
12
23

query I rowsort
SELECT - - 58 AS col0 FROM tab2 AS cor0
----
58
58
58

query I rowsort
SELECT 49 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

onlyif mysql # use DIV operator for integer division
query I rowsort label-4388
SELECT DISTINCT - col0 DIV + 48 AS col2 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-4388
SELECT DISTINCT - col0 / + 48 AS col2 FROM tab2
----
-1
0

query I rowsort
SELECT col2 - - col2 * col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT tab0.col1 - - col0 * + col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL + - 27 * - ( - cor0.col1 ) + col1 AS col1 FROM tab2 AS cor0
----
-1534
-442
-806

query I rowsort
SELECT ALL 29 * 18 FROM tab1 AS cor0
----
522
522
522

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4393
SELECT + - CAST( NULL AS SIGNED ) + + col1 / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4393
SELECT + - CAST ( NULL AS INTEGER ) + + col1 / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 39 - - 66 FROM tab0
----
105
105
105

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4395
SELECT ALL CAST( NULL AS DECIMAL ) + col2 * - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4395
SELECT ALL CAST ( NULL AS REAL ) + col2 * - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * ( cor0.col2 ) + + 73 * 43 AS col1 FROM tab0 cor0
----
-4159
2347
3104

query I rowsort
SELECT ALL + col0 * col0 + col2 * col1 FROM tab2 AS cor0
----
6887
7618
886

query I rowsort
SELECT - + ( + 41 ) + cor0.col0 * col1 AS col1 FROM tab0 AS cor0
----
2023
3354
8058

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + col2 * col1 * - col0 col2 FROM tab2 AS cor0
----
-119730
-51113
-5866

query I rowsort
SELECT ALL ( col0 ) + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - - ( col1 ) * - col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + 47 * - col0 + col2 FROM tab0 AS cor0
----
-1095
-1644
-4101

onlyif mysql # use DIV operator for integer division
query I rowsort label-4403
SELECT 96 DIV col0 AS col0 FROM tab0 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4403
SELECT 96 / col0 AS col0 FROM tab0 AS cor0
----
1
2
4

query I rowsort
SELECT ALL cor0.col2 + - col2 * 66 FROM tab1 AS cor0
----
-3510
-3705
-6240

query I rowsort
SELECT ALL + col0 * col2 + - col1 * - 84 FROM tab1 AS cor0
----
2346
4488
8772

query I rowsort
SELECT DISTINCT + + 47 * col0 FROM tab1 AS cor0
----
141
3008
3760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4407
SELECT + col0 * - col2 + + col1 DIV col1 col1 FROM tab1 AS cor0
----
-161
-3647
-7679

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4407
SELECT + col0 * - col2 + + col1 / col1 col1 FROM tab1 AS cor0
----
-161
-3647
-7679

query I rowsort
SELECT DISTINCT + 90 + + col2 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT ALL + 52 + - col1 + + ( - 88 ) * cor0.col0 * - 69 FROM tab1 AS cor0
----
18242
388650
485799

query I rowsort
SELECT col1 - - 31 * col1 * - 52 AS col2 FROM tab1
----
-16110
-20943
-41886

query I rowsort
SELECT ALL - col0 + col0 * + 56 FROM tab0 AS cor0
----
1320
1925
4895

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - cor0.col0 + 58 col0 FROM tab2 AS cor0
----
-6026
-6183
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4413
SELECT DISTINCT + + col0 * col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4413
SELECT DISTINCT + + col0 * col2 / - col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + - ( 2 ) col1 FROM tab0 AS cor0
----
-88
-93
-99

query I rowsort
SELECT + col1 * ( - col1 * + col1 ) FROM tab2 AS cor0
----
-205379
-29791
-4913

onlyif mysql # use DIV operator for integer division
query I rowsort label-4416
SELECT DISTINCT + + cor0.col2 * - 21 + + col0 - - col1 DIV + col1 FROM tab1 cor0
----
-1130
-1132
-1935

skipif mysql # not compatible
query I rowsort label-4416
SELECT DISTINCT + + cor0.col2 * - 21 + + col0 - - col1 / + col1 FROM tab1 cor0
----
-1130
-1132
-1935

query I rowsort
SELECT DISTINCT - col2 + 48 FROM tab2 AS cor0
----
10
21
22

query I rowsort
SELECT + cor0.col0 + + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - + cor0.col1 * - 82 FROM tab2 AS cor0
----
1394
2542
4838

query I rowsort
SELECT ALL 1 * - tab2.col0 AS col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT + col0 * col0 * col2 + col1 * + ( - 96 ) FROM tab2 cor0
----
-1653
152520
235526

query I rowsort
SELECT ALL + + col1 + cor0.col1 AS col0 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT ALL + + col1 + + col2 * + col2 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4424
SELECT ALL cor0.col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4424
SELECT ALL cor0.col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4425
SELECT DISTINCT - cor0.col1 * - col0 DIV col0 col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4425
SELECT DISTINCT - cor0.col1 * - col0 / col0 col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - - col1 * - col0 * col0 + + 11 * + col2 AS col0 FROM tab0 AS cor0
----
-118814
-49173
-719909

query I rowsort
SELECT ALL col2 * 41 + col0 + - col2 AS col2 FROM tab0
----
1344
3369
75

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 162169e743caf7b1ab855c7985eb36ff

query I rowsort
SELECT col0 * col1 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-101
-512
3926

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4430
SELECT - + col2 - - CAST( - cor0.col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-4430
SELECT - + col2 - - CAST ( - cor0.col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT - + col0 + + col2 + col1 AS col0 FROM tab2 AS cor0
----
-24
51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4432
SELECT DISTINCT col1 - col2 DIV + cor0.col1 AS col2 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-4432
SELECT DISTINCT col1 - col2 / + cor0.col1 AS col2 FROM tab2 AS cor0
----
15
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + ( col0 ) * col1 col1 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT - + col1 + - 9 * 21 - + cor0.col0 AS col0 FROM tab0 AS cor0
----
-299
-321
-369

query I rowsort
SELECT + - col2 + - col1 AS col1 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - + col0 + 41 FROM tab1 AS cor0
----
-23
-39
38

query I rowsort
SELECT ALL + col0 * - 28 + col0 AS col2 FROM tab2 AS cor0
----
-189
-2106
-2133

query I rowsort
SELECT DISTINCT - col0 * 51 - 72 FROM tab0 AS cor0
----
-1296
-1857
-4611

query I rowsort
SELECT - col2 + ( 55 ) FROM tab0 AS cor0
----
-27
22
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-4440
SELECT + col1 * + ( + ( + col1 ) ) - - 88 * ( col1 ) DIV col0 FROM tab1 AS cor0
----
113
1438
183

skipif mysql # not compatible
query I rowsort label-4440
SELECT + col1 * + ( + ( + col1 ) ) - - 88 * ( col1 ) / col0 FROM tab1 AS cor0
----
113
1438
183

query I rowsort
SELECT - + 48 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col0 - col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + col0 * - col0 + cor0.col1 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT - + col2 + col0 AS col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT col0 + - 97 AS col1 FROM tab2 AS cor0
----
-18
-19
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4446
SELECT ALL + + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-4446
SELECT ALL + + col2 / col0 AS col1 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL + tab0.col0 + col0 * ( - col2 * col0 ) AS col1 FROM tab0
----
-1190
-18984
-649433

query I rowsort
SELECT ALL - cor0.col1 + cor1.col1 AS col2 FROM tab2, tab0 cor0, tab0 cor1
----
27 values hashing to 41e878c2362fac0b2147703952a28b8e

query I rowsort
SELECT DISTINCT - 34 AS col0 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 + - 62 col0 FROM tab2
----
1382
614
667

query I rowsort
SELECT 64 * cor0.col1 * tab2.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 36be653de85089feeacff89609f20081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4452
SELECT ALL + col2 * + col1 DIV col1 col2 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4452
SELECT ALL + col2 * + col1 / col1 col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col0 + - cor0.col1 + - col2 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT + + cor0.col2 * cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4455
SELECT ALL col1 * col1 * + CAST( cor0.col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1000
17576
2197

skipif mysql # not compatible
query I rowsort label-4455
SELECT ALL col1 * col1 * + CAST ( cor0.col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1000
17576
2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 * - col0 col2 FROM tab1 WHERE NOT ( NULL ) NOT IN ( + col2 + tab1.col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4457
SELECT tab2.col0 + - col0 + col1 DIV - col0 AS col1 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4457
SELECT tab2.col0 + - col0 + col1 / - col0 AS col1 FROM tab2
----
-4
0
0

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN + tab0.col2 + col0 AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4459
SELECT ALL - col2 + - col1 + - col0 DIV col0 FROM tab2 WHERE NOT - col0 * col2 >= ( col2 * - col0 + + col2 )
----
-56
-59
-86

skipif mysql # not compatible
query I rowsort label-4459
SELECT ALL - col2 + - col1 + - col0 / col0 FROM tab2 WHERE NOT - col0 * col2 >= ( col2 * - col0 + + col2 )
----
-56
-59
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4460
SELECT - col0 DIV + col0 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4460
SELECT - col0 / + col0 AS col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL + 68 + col2 AS col0 FROM tab0
----
101
150
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-4462
SELECT - 59 DIV + tab2.col0 AS col2 FROM tab2
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4462
SELECT - 59 / + tab2.col0 AS col2 FROM tab2
----
-8
0
0

query I rowsort
SELECT DISTINCT col2 * - col0 + 87 * - col0 FROM tab0
----
-15041
-2880
-3080

query I rowsort
SELECT ALL 1 * - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT 86 + 30 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2908a9c57f1b83a3ddc339331572c6fa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 19 + col1 + - col1 * col2 col2 FROM tab1 AS cor0
----
-1216
-1359
-541

query I rowsort
SELECT DISTINCT - col0 * col2 + ( col1 ) * col2 AS col0 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT DISTINCT + 82 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
82

query I rowsort
SELECT + col0 + - col2 * col1 FROM tab2 cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-4470
SELECT DISTINCT 33 DIV - col0 col0 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4470
SELECT DISTINCT 33 / - col0 col0 FROM tab0
----
-1
0

query I rowsort
SELECT ALL col1 + + col0 * + ( col1 * col2 ) FROM tab2 AS cor0
----
119711
51051
5890

onlyif mysql # use DIV operator for integer division
query I rowsort label-4472
SELECT col0 * col1 DIV - 58 AS col2 FROM tab1
----
-1
-11
-17

skipif mysql # not compatible
query I rowsort label-4472
SELECT col0 * col1 / - 58 AS col2 FROM tab1
----
-1
-11
-17

query I rowsort
SELECT + col2 * 37 + ( + col2 ) FROM tab2 AS cor0
----
1026
1444
988

query I rowsort
SELECT + cor0.col2 * col2 + 78 AS col0 FROM tab1 AS cor0
----
2994
3327
9294

onlyif mysql # use DIV operator for integer division
query I rowsort label-4475
SELECT + col2 * 32 - - 54 DIV + col1 FROM tab2 AS cor0
----
1219
832
865

skipif mysql # not compatible
query I rowsort label-4475
SELECT + col2 * 32 - - 54 / + col1 FROM tab2 AS cor0
----
1219
832
865

onlyif mysql # use DIV operator for integer division
query I rowsort label-4476
SELECT + cor0.col2 * + ( col0 ) + - col2 + + col2 DIV - col1 FROM tab0 AS cor0
----
34
7216
759

skipif mysql # not compatible
query I rowsort label-4476
SELECT + cor0.col2 * + ( col0 ) + - col2 + + col2 / - col1 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-4477
SELECT + col2 DIV cor0.col2 + col1 AS col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4477
SELECT + col2 / cor0.col2 + col1 AS col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + col1 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 10 - + col2 col2 FROM tab2 AS cor0
----
-36
-37
-48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4480
SELECT DISTINCT + CAST( - col1 AS SIGNED ) * - cor0.col1 * + 69 - cor0.col2 AS col1 FROM tab0 AS cor0
----
510291
571307
649220

skipif mysql # not compatible
query I rowsort label-4480
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) * - cor0.col1 * + 69 - cor0.col2 AS col1 FROM tab0 AS cor0
----
510291
571307
649220

onlyif mysql # use DIV operator for integer division
query I rowsort label-4481
SELECT ALL + 66 DIV + col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4481
SELECT ALL + 66 / + col0 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT ALL tab1.col2 AS col2 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT 14 * col1 AS col0 FROM tab2
----
238
434
826

query I rowsort
SELECT ALL + ( + col2 ) - col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT 13 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to b092e3fa17e78608cf120e97d1bfff67

query I rowsort
SELECT 57 * cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 1d6306f216c759692cd9a50966ae3340

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4487
SELECT ALL CAST( NULL AS SIGNED ) * 6 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4487
SELECT ALL CAST ( NULL AS INTEGER ) * 6 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 22 * col0 * + ( - col0 ) AS col2 FROM tab0 AS cor0
----
-12672
-174262
-26950

query I rowsort
SELECT DISTINCT col2 + col2 * - ( - ( - col0 ) ) AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + 81 AS col0 FROM tab0 AS cor0
----
81
81
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4491
SELECT col2 * col0 DIV 21 AS col0 FROM tab1 AS cor0
----
173
365
7

skipif mysql # not compatible
query I rowsort label-4491
SELECT col2 * col0 / 21 AS col0 FROM tab1 AS cor0
----
173
365
7

query I rowsort
SELECT DISTINCT + - cor0.col1 * + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 53 + 84 col1 FROM tab1
----
137
137
137

onlyif mysql # use DIV operator for integer division
query I rowsort label-4494
SELECT ALL col0 DIV tab2.col0 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4494
SELECT ALL col0 / tab2.col0 AS col0 FROM tab2
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + cor0.col2 * col2 col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + col0 + - col2 * + col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * cor0.col1 col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - col0 * - col2 - col0 AS col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + - col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + + col2 - + col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL 45 AS col2 FROM tab0
----
45
45
45

query I rowsort
SELECT - col1 * cor0.col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - 52 * - col0 + - col0 * - col1 + + cor0.col0 FROM tab2 cor0
----
-140
-2686
624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 70 * col2 col1 FROM tab1 AS cor0
----
-3780
-3990
-6720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 19 col1 FROM tab0
----
-19
-19
-19

query I rowsort
SELECT - 17 * + 9 AS col0 FROM tab1
----
-153
-153
-153

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4507
SELECT ALL - CAST( NULL AS SIGNED ) / col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4507
SELECT ALL - CAST ( NULL AS INTEGER ) / col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 38 * - col2 FROM tab2
----
1026
1444
988

query I rowsort
SELECT ALL 38 * cor0.col2 FROM tab2, tab1 cor0
----
9 values hashing to cb940a3e1552a9bda46d0d76a4dc0bc8

query I rowsort
SELECT ALL - 90 * + tab0.col0 FROM tab0
----
-2160
-3150
-8010

query I rowsort
SELECT + 49 * + col0 + col0 AS col1 FROM tab2 AS cor0
----
350
3900
3950

onlyif mysql # use DIV operator for integer division
query I rowsort label-4512
SELECT 42 DIV + cor0.col0 FROM tab1 AS cor0
----
0
0
14

skipif mysql # not compatible
query I rowsort label-4512
SELECT 42 / + cor0.col0 FROM tab1 AS cor0
----
0
0
14

query I rowsort
SELECT DISTINCT + col2 * + tab0.col1 + - col1 FROM tab0 WHERE col0 + col0 IN ( tab0.col2 )
----

query I rowsort
SELECT DISTINCT col2 * tab1.col1 * col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT + col0 * col2 + - tab1.col2 AS col2 FROM tab1
----
108
3591
7584

query I rowsort
SELECT ALL - col0 * col2 * + col2 AS col1 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT + col0 * - col0 + col0 AS col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT col1 + col0 * - tab0.col1 * col2 - col0 AS col2 FROM tab0
----
-3333
-664116
-68050

query III rowsort
SELECT * FROM tab2 WHERE col0 >= - col0 * - col0
----

query I rowsort
SELECT ALL - col0 + - col1 * col1 AS col2 FROM tab1
----
-164
-249
-679

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT IN ( - col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) IN ( tab0.col2 )
----

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) NOT IN ( col2 * col2 )
----

query I rowsort
SELECT ALL col1 + - col0 * + tab0.col2 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT + col2 + - col1 * + col0 * tab1.col1 AS col0 FROM tab1
----
-13424
-1974
-6343

query I rowsort
SELECT - - col1 + + col1 * - col2 * col2 FROM tab2 AS cor0
----
-22568
-24531
-39825

query I rowsort
SELECT ALL + col0 + col2 * - col2 + col1 FROM tab0 AS cor0
----
-6544
-979
131

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 - - cor0.col1 * col1 col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT ALL + col1 + - col1 * + cor0.col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col1 + cor0.col1 * + cor0.col1 FROM tab2 AS cor0
----
-1054
-1121
744

query I rowsort
SELECT col1 * - col0 * - col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + col1 - col2 * - col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL col1 AS col2 FROM tab0 WHERE NOT ( - col0 ) IN ( - col0 * col1 )
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4534
SELECT tab0.col0 DIV - col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4534
SELECT tab0.col0 / - col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT 86 * col2 AS col2 FROM tab2
----
2236
2322
3268

query I rowsort
SELECT DISTINCT - 72 + col2 AS col0 FROM tab0
----
-39
-71
10

query I rowsort
SELECT col1 * + 89 + col0 AS col2 FROM tab0
----
7678
8188
8668

query I rowsort
SELECT ALL + + 7 FROM tab2 cor0
----
7
7
7

query I rowsort
SELECT DISTINCT + 2 + ( + cor0.col1 * - cor0.col0 ) FROM tab0 AS cor0
----
-2062
-3393
-8097

query I rowsort
SELECT - ( col2 ) * col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + ( - 86 * col1 + 79 ) FROM tab2
----
-1383
-2587
-4995

query I rowsort
SELECT + col0 * - col2 + + col1 * col2 AS col2 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT ALL - col1 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4544
SELECT DISTINCT + col0 * - col1 + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4544
SELECT DISTINCT + col0 * - col1 + CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + + col0 * + col0 + col0 - col2 FROM tab2 cor0
----
29
6136
6282

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4546
SELECT ALL + col0 * col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4546
SELECT ALL + col0 * col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * + col0 + + col0 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4548
SELECT col1 DIV - col1 + + 19 AS col2 FROM tab2 AS cor0
----
18
18
18

skipif mysql # not compatible
query I rowsort label-4548
SELECT col1 / - col1 + + 19 AS col2 FROM tab2 AS cor0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4549
SELECT - - cor0.col1 DIV + col0 + + col2 - col2 * col1 AS col0 FROM tab2 AS cor0
----
-1508
-608
-806

skipif mysql # not compatible
query I rowsort label-4549
SELECT - - cor0.col1 / + col0 + + col2 - col2 * col1 AS col0 FROM tab2 AS cor0
----
-1508
-608
-806

query I rowsort
SELECT 59 * + col1 + - col2 - + col1 AS col2 FROM tab1 AS cor0
----
1454
523
658

query I rowsort
SELECT DISTINCT col0 * + 15 AS col2 FROM tab2 AS cor0
----
105
1170
1185

query I rowsort
SELECT - + col0 + + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-4553
SELECT DISTINCT col1 DIV - ( col2 ) + - col2 col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4553
SELECT DISTINCT col1 / - ( col2 ) + - col2 col0 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4554
SELECT + col1 * - CAST( col1 AS SIGNED ) + tab2.col1 AS col0 FROM tab2
----
-272
-3422
-930

skipif mysql # not compatible
query I rowsort label-4554
SELECT + col1 * - CAST ( col1 AS INTEGER ) + tab2.col1 AS col0 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT - cor0.col0 * + 1 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4556
SELECT ALL - - col1 + - CAST( NULL AS SIGNED ) * + cor0.col0 * cor0.col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4556
SELECT ALL - - col1 + - CAST ( NULL AS INTEGER ) * + cor0.col0 * cor0.col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * ( - cor0.col2 ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * - 37 + col0 col0 FROM tab0 AS cor0
----
1330
3382
912

query I rowsort
SELECT DISTINCT - col0 * col0 + + col0 AS col1 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + cor0.col1 + ( - col1 ) FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4561
SELECT DISTINCT - col0 DIV + ( - col0 ) + - col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4561
SELECT DISTINCT - col0 / + ( - col0 ) + - col0 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT DISTINCT + cor1.col0 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
7
78
79

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - 34 AS REAL ) * - col2 * col2 AS col1 FROM tab1 AS cor0
----
110466
313344
99144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 99 * ( col0 * ( col0 ) ) col1 FROM tab0 AS cor0
----
121275
57024
784179

query I rowsort
SELECT cor2.col2 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT - 7 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
-4
57
73

query I rowsort
SELECT + ( 71 ) AS col2 FROM tab0 AS cor0
----
71
71
71

query I rowsort
SELECT ALL + col1 * + 11 FROM tab2
----
187
341
649

query I rowsort
SELECT ALL col1 * - 8 FROM tab1
----
-104
-208
-80

query I rowsort
SELECT - 17 + 62 AS col0 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT - col0 * - col2 + cor0.col2 + col2 FROM tab0 AS cor0
----
37
7462
858

query I rowsort
SELECT - col2 * 60 AS col1 FROM tab2 cor0
----
-1560
-1620
-2280

query I rowsort
SELECT ALL + ( col1 ) + col0 * col0 FROM tab2
----
6143
6258
80

query I rowsort
SELECT - tab0.col0 * + 80 FROM tab0
----
-1920
-2800
-7120

query I rowsort
SELECT + col2 + 41 * 8 AS col1 FROM tab0 AS cor0
----
329
361
410

query I rowsort
SELECT - cor0.col1 + ( - col0 ) AS col1 FROM tab2 cor0
----
-137
-38
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4577
SELECT cor0.col0 * - CAST( NULL AS SIGNED ) + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4577
SELECT cor0.col0 * - CAST ( NULL AS INTEGER ) + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4578
SELECT ALL + + cor0.col0 DIV + 63 AS col2 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4578
SELECT ALL + + cor0.col0 / + 63 AS col2 FROM tab2 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4579
SELECT ALL + col1 * - CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-4579
SELECT ALL + col1 * - CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - + cor0.col1 * col1 * col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT - col2 * ( col1 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - 2 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

onlyif mysql # use DIV operator for integer division
query I rowsort label-4583
SELECT ALL col2 * 84 DIV col2 AS col2 FROM tab1 AS cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort label-4583
SELECT ALL col2 * 84 / col2 AS col2 FROM tab1 AS cor0
----
84
84
84

query I rowsort
SELECT DISTINCT + cor0.col0 * - 99 AS col1 FROM tab2 AS cor0
----
-693
-7722
-7821

onlyif mysql # use DIV operator for integer division
query I rowsort label-4585
SELECT 31 + + col0 DIV + col2 FROM tab1 AS cor0
----
31
31
32

skipif mysql # not compatible
query I rowsort label-4585
SELECT 31 + + col0 / + col2 FROM tab1 AS cor0
----
31
31
32

query I rowsort
SELECT - 57 + + col1 AS col1 FROM tab0 AS cor0
----
29
34
40

query I rowsort
SELECT - 8 + cor0.col0 FROM tab1 AS cor0
----
-5
56
72

query I rowsort
SELECT DISTINCT col0 + + ( col0 ) FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT col1 * - col0 + - col2 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT + ( - tab1.col0 + tab1.col0 ) * + col2 AS col1 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4591
SELECT - CAST( NULL AS DECIMAL ) + + 25 * col0 * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4591
SELECT - CAST ( NULL AS REAL ) + + 25 * col0 * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4592
SELECT - col2 * 74 DIV col2 - col2 * + col0 FROM tab0 AS cor0
----
-109
-7372
-866

skipif mysql # not compatible
query I rowsort label-4592
SELECT - col2 * 74 / col2 - col2 * + col0 FROM tab0 AS cor0
----
-109
-7372
-866

query I rowsort
SELECT DISTINCT 34 * - col0 AS col2 FROM tab0 cor0
----
-1190
-3026
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4594
SELECT DISTINCT cor0.col0 DIV col1 + ( - col2 * cor0.col0 + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-136
-3632
-7661

skipif mysql # not compatible
query I rowsort label-4594
SELECT DISTINCT cor0.col0 / col1 + ( - col2 * cor0.col0 + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-136
-3632
-7661

query I rowsort
SELECT col2 + - col0 + + 24 FROM tab2 AS cor0
----
-17
-28
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 67 col1 FROM tab1 AS cor0
----
67
67
67

query I rowsort
SELECT + 79 + col2 FROM tab1 AS cor0
----
133
136
175

query I rowsort
SELECT DISTINCT ( - tab0.col2 + col1 * col2 ) FROM tab0
----
2805
7380
96

query I rowsort
SELECT DISTINCT - 63 + cor0.col1 - col0 AS col0 FROM tab1 AS cor0
----
-117
-130
-40

onlyif mysql # use DIV operator for integer division
query I rowsort label-4600
SELECT - ( + col0 ) DIV col0 - 43 FROM tab2
----
-44
-44
-44

skipif mysql # not compatible
query I rowsort label-4600
SELECT - ( + col0 ) / col0 - 43 FROM tab2
----
-44
-44
-44

query I rowsort
SELECT 55 FROM tab2, tab1 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT col2 * cor0.col2 + - ( - col1 + col1 ) FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - + col2 * col1 + 70 * + 50 AS col0 FROM tab1 cor0
----
2096
2252
2930

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 - 9 FROM tab2 AS cor0
----
147
149
5

query I rowsort
SELECT ALL - - 65 FROM tab1, tab1 AS cor0, tab2 cor1, tab0, tab0 AS cor2
----
243 values hashing to 0d5e8d2477ad92b57b3f68ac299ad7b9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4606
SELECT DISTINCT + col1 DIV col1 col1 FROM tab0 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4606
SELECT DISTINCT + col1 / col1 col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT - 29 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-16
-19
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - - 43 * cor0.col1 + col1 + col0 FROM tab1 AS cor0
----
1147
504
652

onlyif mysql # use DIV operator for integer division
query I rowsort label-4611
SELECT DISTINCT - 24 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4611
SELECT DISTINCT - 24 / col1 AS col2 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT ALL + - col0 + + col2 * + ( + col2 ) AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + - 90 * col2 + col2 FROM tab1 AS cor0
----
-4806
-5073
-8544

query I rowsort
SELECT DISTINCT 56 FROM tab0, tab1, tab2 AS cor0
----
56

query I rowsort
SELECT 32 - + col0 * - ( col0 + col2 ) FROM tab0
----
1292
1400
15251

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4616
SELECT + cor0.col2 + + 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-4616
SELECT + cor0.col2 + + 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-4617
SELECT - ( col0 ) - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4617
SELECT - ( col0 ) - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col0 ) + - ( col0 * col0 ) FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT ALL 44 * - col2 FROM tab2 AS cor0
----
-1144
-1188
-1672

query I rowsort
SELECT DISTINCT col0 * col0 + - tab2.col1 AS col1 FROM tab2
----
18
6025
6224

query I rowsort
SELECT col1 + + 5 AS col0 FROM tab2
----
22
36
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4622
SELECT col0 * ( col0 ) * - col1 + + ( + tab0.col1 ) DIV - tab0.col2 FROM tab0
----
-118922
-49538
-720812

skipif mysql # not compatible
query I rowsort label-4622
SELECT col0 * ( col0 ) * - col1 + + ( + tab0.col1 ) / - tab0.col2 FROM tab0
----
-118922
-49538
-720812

query I rowsort
SELECT DISTINCT - col2 + col2 * + col0 FROM tab2 cor0
----
162
2002
2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4624
SELECT - CAST( NULL AS SIGNED ) / + col1 - + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4624
SELECT - CAST ( NULL AS INTEGER ) / + col1 - + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 - ( col2 ) AS col0 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4626
SELECT - + col1 DIV + col0 + - col0 AS col1 FROM tab2 AS cor0
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-4626
SELECT - + col1 / + col0 + - col0 AS col1 FROM tab2 AS cor0
----
-11
-78
-79

query I rowsort
SELECT col1 * + 57 - col1 * col2 FROM tab2
----
1829
323
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL + col2 * tab2.col2 + col0 AS col1 FROM tab2
----
1523
736
754

query I rowsort
SELECT + - 60 AS col0 FROM tab1, tab0 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to 17ea60db8bdc9b534fe91b7fd55df3f9

query I rowsort
SELECT + ( col1 ) * - col0 + + col2 - col1 * - col1 AS col1 FROM tab2 AS cor0
----
-1016
-1095
771

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4632
SELECT - CAST( NULL AS SIGNED ) * col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4632
SELECT - CAST ( NULL AS INTEGER ) * col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 41 + cor0.col0 FROM tab2 cor0
----
119
120
48

query I rowsort
SELECT + - col0 - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4635
SELECT - CAST( NULL AS SIGNED ) + - cor0.col0 + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4635
SELECT - CAST ( NULL AS INTEGER ) + - cor0.col0 + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * 23 AS col1 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT - col2 + ( col2 ) * col2 AS col1 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT + col2 + col1 * + col2 * + col2 FROM tab1 AS cor0
----
119904
32547
75870

query I rowsort
SELECT col1 * + col1 + + ( 50 ) AS col0 FROM tab1
----
150
219
726

query I rowsort
SELECT ALL + 79 * + col2 FROM tab1
----
4266
4503
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-4641
SELECT + col0 DIV - col1 col2 FROM tab1 AS cor0
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4641
SELECT + col0 / - col1 col2 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT - cor0.col0 * ( 43 ) AS col0 FROM tab2 AS cor0
----
-301
-3354
-3397

query I rowsort
SELECT + col0 + - col1 * 26 FROM tab1 AS cor0
----
-196
-258
-673

query I rowsort
SELECT + - col0 * col2 * - col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL tab2.col1 * - tab2.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 79ea663c5f468cc57a869fc826cf04a5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 + col1 col1 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT - + cor0.col2 + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + ( + col0 ) + col2 * + col2 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL 36 * 13 FROM tab0 AS cor0
----
468
468
468

onlyif mysql # use DIV operator for integer division
query I rowsort label-4650
SELECT DISTINCT + - col0 * + col0 + + col2 DIV 74 FROM tab1 AS cor0
----
-4096
-6399
-9

skipif mysql # not compatible
query I rowsort label-4650
SELECT DISTINCT + - col0 * + col0 + + col2 / 74 FROM tab1 AS cor0
----
-4096
-6399
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4651
SELECT DISTINCT + col2 * col1 - - col2 DIV col1 FROM tab1 AS cor0
----
1255
1406
575

skipif mysql # not compatible
query I rowsort label-4651
SELECT DISTINCT + col2 * col1 - - col2 / col1 FROM tab1 AS cor0
----
1255
1406
575

query I rowsort
SELECT cor0.col0 * col0 + + col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT - col0 + 68 + col2 AS col2 FROM tab0 AS cor0
----
34
61
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4654
SELECT ALL - CAST( NULL AS SIGNED ) + cor0.col1 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4654
SELECT ALL - CAST ( NULL AS INTEGER ) + cor0.col1 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * 88 + + col1 * - 57 * + 76 FROM tab2 AS cor0
----
-134908
-262452
-80596

query I rowsort
SELECT ALL + col0 * + 18 AS col0 FROM tab2 cor0
----
126
1404
1422

query I rowsort
SELECT + - 5 FROM tab1 AS cor0
----
-5
-5
-5

query I rowsort
SELECT ALL - + 93 * + cor0.col0 + col2 AS col0 FROM tab0 AS cor0
----
-2199
-3254
-8195

onlyif mysql # use DIV operator for integer division
query I rowsort label-4659
SELECT ALL - col1 DIV - col0 + cor0.col1 + + 53 AS col0 FROM tab1 AS cor0
----
63
66
87

skipif mysql # not compatible
query I rowsort label-4659
SELECT ALL - col1 / - col0 + cor0.col1 + + 53 AS col0 FROM tab1 AS cor0
----
63
66
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4660
SELECT ALL - col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4660
SELECT ALL - col2 / - col2 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 16 AS col2 FROM tab1 AS cor0
----
16

query I rowsort
SELECT DISTINCT - + 1 * col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - + ( col2 ) + + ( - col1 ) FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4664
SELECT DISTINCT + 94 DIV + col1 AS col0 FROM tab1 AS cor0
----
3
7
9

skipif mysql # not compatible
query I rowsort label-4664
SELECT DISTINCT + 94 / + col1 AS col0 FROM tab1 AS cor0
----
3
7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4665
SELECT 96 DIV col1 FROM tab2 AS cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-4665
SELECT 96 / col1 FROM tab2 AS cor0
----
1
3
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) + 91 col2 FROM tab0 AS cor0
----
58
9
90

query I rowsort
SELECT ALL 87 * col2 + + col1 AS col2 FROM tab0
----
184
2957
7225

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 39 + col0 * - 41 col2 FROM tab1 AS cor0
----
-2585
-3241
-84

query I rowsort
SELECT col1 * - col1 * 96 FROM tab0 AS cor0
----
-710016
-794976
-903264

query I rowsort
SELECT ALL 0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + + col0 * cor0.col2 col2 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-4672
SELECT DISTINCT 53 DIV col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4672
SELECT DISTINCT 53 / col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort
SELECT - 35 * + col2 * - CAST ( + 11 AS REAL ) + col1 FROM tab2 AS cor0
----
10069
10426
14647

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4674
SELECT col0 / - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4674
SELECT col0 / - 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-4675
SELECT - - col2 DIV + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4675
SELECT - - col2 / + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4676
SELECT DISTINCT - cor0.col2 * col1 DIV + 91 + col1 FROM tab2 AS cor0
----
10
22
43

skipif mysql # not compatible
query I rowsort label-4676
SELECT DISTINCT - cor0.col2 * col1 / + 91 + col1 FROM tab2 AS cor0
----
10
22
43

query I rowsort
SELECT - 88 * + cor0.col0 - - col0 AS col1 FROM tab0 AS cor0
----
-2088
-3045
-7743

query I rowsort
SELECT ( + 8 ) + - col2 FROM tab1 AS cor0
----
-46
-49
-88

query I rowsort
SELECT + 21 * - 26 AS col1 FROM tab2, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 46bd4db8742f582538e509d9bcbd4f3a

query I rowsort
SELECT ( + 51 ) * col1 + col1 AS col1 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT ( - 53 ) * - col2 FROM tab2
----
1378
1431
2014

query I rowsort
SELECT - 29 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4683
SELECT - + col1 * col2 DIV ( - col2 ) + - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4683
SELECT - + col1 * col2 / ( - col2 ) + - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + col2 * + col0 * - 34 AS col2 FROM tab1
----
-123975
-261024
-5454

query I rowsort
SELECT ALL 15 * - 68 * col0 FROM tab2
----
-7140
-79560
-80580

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col2 AS REAL ) AS col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + col0 * + 67 FROM tab1
----
201
4288
5360

query I rowsort
SELECT ALL + col2 * + 4 FROM tab1 AS cor0
----
216
228
384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col1 + + col2 col2 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT - col1 * - col0 * col0 AS col1 FROM tab0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4691
SELECT ALL CAST( 3 AS SIGNED ) FROM tab2
----
3
3
3

skipif mysql # not compatible
query I rowsort label-4691
SELECT ALL CAST ( 3 AS INTEGER ) FROM tab2
----
3
3
3

query I rowsort
SELECT cor0.col0 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT 88 AS col2 FROM tab1
----
88

query I rowsort
SELECT + 64 - col1 FROM tab1
----
38
51
54

query I rowsort
SELECT 27 + + col1 AS col2 FROM tab2
----
44
58
86

query I rowsort
SELECT + cor1.col0 * + 4 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 5c8a4a6a354c51cbd345cc55323c1b1e

query I rowsort
SELECT ALL + - 27 + col2 AS col1 FROM tab2 AS cor0
----
-1
0
11

query I rowsort
SELECT ALL - ( 33 ) AS col1 FROM tab2 cor0
----
-33
-33
-33

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 * col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT - 13 * + cor0.col0 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT ALL 95 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9896fbc7c98abe84cb585e6f5f25b58a

query I rowsort
SELECT ALL - ( tab1.col1 ) - col1 * - 92 FROM tab1
----
1183
2366
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-4703
SELECT ALL + 54 DIV - col0 AS col1 FROM tab1
----
-18
0
0

skipif mysql # not compatible
query I rowsort label-4703
SELECT ALL + 54 / - col0 AS col1 FROM tab1
----
-18
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4704
SELECT + col0 + col0 DIV col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-4704
SELECT + col0 + col0 / col0 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4705
SELECT - col0 / CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4705
SELECT - col0 / CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4707
SELECT cor0.col0 DIV col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4707
SELECT cor0.col0 / col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4708
SELECT ALL col2 * + CAST( NULL AS DECIMAL ) + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4708
SELECT ALL col2 * + CAST ( NULL AS REAL ) + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4709
SELECT col1 DIV + col2 + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4709
SELECT col1 / + col2 + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + col0 * - 84 * - col2 AS col0 FROM tab0 AS cor0
----
2940
613032
66528

query I rowsort
SELECT + col2 * col0 + + col2 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-4712
SELECT + col1 DIV + col1 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4712
SELECT + col1 / + col1 AS col1 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4713
SELECT - tab0.col2 DIV - col0 AS col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4713
SELECT - tab0.col2 / - col0 AS col0 FROM tab0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4714
SELECT DISTINCT - cor0.col0 * - CAST( NULL AS SIGNED ) * col2 + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4714
SELECT DISTINCT - cor0.col0 * - CAST ( NULL AS INTEGER ) * col2 + col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 * - 17 - - 40 FROM tab1 AS cor0
----
-1048
-11
-1320

query I rowsort
SELECT DISTINCT - col0 + 66 * col2 FROM tab2 AS cor0
----
1638
1775
2429

query I rowsort
SELECT cor0.col1 + - col1 AS col1 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + cor0.col1 col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col2 * col2 + - col0 FROM tab2 AS cor0
----
1365
598
722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + + col2 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * ( tab0.col0 ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL + tab0.col1 + ( - ( col1 ) ) AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT - col2 * 88 + - tab1.col0 + tab1.col0 * - tab1.col1 AS col0 FROM tab1
----
-4833
-5720
-9568

query I rowsort
SELECT ALL + col1 * - col1 * - col2 + col0 FROM tab0
----
244092
679131
9444

query I rowsort
SELECT + col2 + + 64 * col2 AS col2 FROM tab2 AS cor0
----
1690
1755
2470

query I rowsort
SELECT DISTINCT - col2 * col1 * - cor0.col0 AS col1 FROM tab0 cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + 50 col0 FROM tab0 AS cor0
----
-36
-41
-47

query I rowsort
SELECT ALL - col1 + - 63 FROM tab0 AS cor0
----
-149
-154
-160

query I rowsort
SELECT DISTINCT + ( - col1 ) * col2 + + col0 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT + cor0.col2 * - cor0.col0 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL col1 * + col0 - col2 * col2 FROM tab0
----
1375
3394
975

query I rowsort
SELECT DISTINCT + + 52 AS col2 FROM tab0 AS cor0
----
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4733
SELECT CAST( NULL AS SIGNED ) + 62 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4733
SELECT CAST ( NULL AS INTEGER ) + 62 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4734
SELECT ALL - ( 81 ) DIV col0 FROM tab2 AS cor0
----
-1
-1
-11

skipif mysql # not compatible
query I rowsort label-4734
SELECT ALL - ( 81 ) / col0 FROM tab2 AS cor0
----
-1
-1
-11

query I rowsort
SELECT DISTINCT - - col2 + + col0 AS col0 FROM tab1 cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 66 + col1 * + cor0.col2 col2 FROM tab0 AS cor0
----
163
2904
7528

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4737
SELECT + - col0 * + cor0.col2 + col1 * + CAST( + col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

skipif mysql # not compatible
query I rowsort label-4737
SELECT + - col0 * + cor0.col2 + col1 * + CAST ( + col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT DISTINCT tab1.col2 + ( tab1.col0 ) * + col1 FROM tab1
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-4739
SELECT tab2.col2 DIV - 30 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4739
SELECT tab2.col2 / - 30 FROM tab2
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4740
SELECT ALL col1 * CAST( NULL AS SIGNED ) - + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4740
SELECT ALL col1 * CAST ( NULL AS INTEGER ) - + col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4741
SELECT DISTINCT tab2.col0 + CAST( col2 + - col0 AS SIGNED ) * - col0 AS col2 FROM tab2
----
-133
3318
4134

skipif mysql # not compatible
query I rowsort label-4741
SELECT DISTINCT tab2.col0 + CAST ( col2 + - col0 AS INTEGER ) * - col0 AS col2 FROM tab2
----
-133
3318
4134

query I rowsort
SELECT - 74 * - col2 FROM tab2 AS cor0
----
1924
1998
2812

query I rowsort
SELECT ALL - - col1 * col0 - cor0.col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - col1 + + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL - col2 * col1 + + col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - - col0 - col1 AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL + - 78 FROM tab0 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4749
SELECT DISTINCT - col1 + - cor0.col2 DIV + ( col1 + 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-4749
SELECT DISTINCT - col1 + - cor0.col2 / + ( col1 + col1 ) col2 FROM tab0 cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4750
SELECT DISTINCT + - col0 + col2 - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4750
SELECT DISTINCT + - col0 + col2 - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4751
SELECT CAST( col0 * col2 + col2 AS SIGNED ) FROM tab2
----
2054
216
3040

skipif mysql # not compatible
query I rowsort label-4751
SELECT CAST ( col0 * col2 + col2 AS INTEGER ) FROM tab2
----
2054
216
3040

query I rowsort
SELECT - 28 FROM tab0, tab0 AS cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4753
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - ( col0 ) * 43 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4753
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - ( col0 ) * 43 AS col0 FROM tab0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4754
SELECT DISTINCT CAST( NULL AS SIGNED ) col0 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4754
SELECT DISTINCT CAST ( NULL AS INTEGER ) col0 FROM tab1
----
NULL

query I rowsort
SELECT + 86 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT + 47 * col1 AS col0 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT - col2 + - col1 * 70 FROM tab2 cor0
----
-1228
-2197
-4156

query I rowsort
SELECT - 75 * col0 + - 80 FROM tab1 AS cor0
----
-305
-4880
-6080

query I rowsort
SELECT DISTINCT - - col1 * - col2 + ( - col2 ) AS col0 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT - - 86 + col2 * col0 FROM tab1 AS cor0
----
248
3734
7766

query I rowsort
SELECT ALL + 44 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT - - cor0.col0 * + col1 * col1 FROM tab2 AS cor0
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col2 - ( col2 ) * col0 col2 FROM tab1 cor0
----
-1566
-4218
-8928

query I rowsort
SELECT ALL - 93 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ea79c61f7a02d25805171f5e85229fba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - + col2 col1 FROM tab2
----
-52
-54
-76

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT IN ( - col2 + col1 )
----

query I rowsort
SELECT - 37 + col1 FROM tab2
----
-20
-6
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-4768
SELECT col2 DIV + ( - cor0.col0 + col1 * 28 ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4768
SELECT col2 / + ( - cor0.col0 + col1 * 28 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * 34 AS col2 FROM tab2 AS cor0
----
1292
884
918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4770
SELECT + CAST( NULL AS SIGNED ) FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4770
SELECT + CAST ( NULL AS INTEGER ) FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col1 + - tab1.col2 / + tab1.col2 FROM tab1 WHERE NOT NULL IN ( col2 + col0 + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4772
SELECT DISTINCT col2 DIV + col1 col0 FROM tab2
----
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4772
SELECT DISTINCT col2 / + col1 col0 FROM tab2
----
0
2

query I rowsort
SELECT ALL tab1.col0 * + col1 + - col2 + - tab1.col0 * - col1 FROM tab1
----
102
1223
1984

query I rowsort
SELECT tab0.col2 * col2 AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL col1 + + col1 * + tab1.col1 + col1 * - col0 FROM tab1
----
-530
-858
624

query I rowsort
SELECT + col1 + + col0 + col0 AS col1 FROM tab1
----
138
173
32

query I rowsort
SELECT tab2.col2 * + col1 FROM tab2 WHERE NOT ( - col0 + + col2 + - col1 ) IN ( col1 - tab2.col2 )
----
1534
646
837

query I rowsort
SELECT DISTINCT col0 AS col1 FROM tab1 WHERE NULL IN ( col2 )
----

query I rowsort
SELECT DISTINCT - col1 + col0 * tab2.col2 FROM tab2
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-4780
SELECT - col2 DIV tab1.col1 + col0 AS col2 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-4780
SELECT - col2 / tab1.col1 + col0 AS col2 FROM tab1
----
1
59
73

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col2 + + col2 * - col2 IN ( - col1 + tab2.col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4782
SELECT DISTINCT col0 * col2 + tab0.col0 * + col0 DIV - col0 + + col0 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-4782
SELECT DISTINCT col0 * col2 + tab0.col0 * + col0 / - col0 + + col0 FROM tab0
----
35
7298
792

query III rowsort
SELECT ALL * FROM tab1 WHERE col0 + tab1.col1 * + col2 NOT IN ( - col1 - + col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col0 > NULL
----

query I rowsort
SELECT + tab0.col2 * + col0 + col2 * + col1 FROM tab0
----
132
14760
3630

query I rowsort
SELECT col1 * col2 + col2 AS col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT tab1.col1 + col1 * col2 * col1 FROM tab1
----
16237
36530
5710

query I rowsort
SELECT col0 * + col1 * + tab2.col2 + - col1 FROM tab2
----
119593
51017
5828

query I rowsort
SELECT col1 * col2 * tab1.col0 + tab1.col2 AS col2 FROM tab1
----
36537
4266
99936

onlyif mysql # use DIV operator for integer division
query I rowsort label-4790
SELECT - + 76 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4790
SELECT - + 76 / col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4791
SELECT - col2 + cor0.col0 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4791
SELECT - col2 + cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 29 + + col2 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT DISTINCT 43 * col2 + - col1 * col1 FROM tab0 cor0
----
-4755
-5977
-9366

query I rowsort
SELECT DISTINCT + ( + col1 ) * - col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT tab2.col0 - - 88 FROM tab2
----
166
167
95

query I rowsort
SELECT ALL - 5 * + col1 FROM tab1
----
-130
-50
-65

query I rowsort
SELECT + ( + 60 ) AS col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

onlyif mysql # use DIV operator for integer division
query I rowsort label-4798
SELECT ( col1 ) DIV - col0 + - 83 AS col1 FROM tab0 AS cor0
----
-84
-85
-86

skipif mysql # not compatible
query I rowsort label-4798
SELECT ( col1 ) / - col0 + - 83 AS col1 FROM tab0 AS cor0
----
-84
-85
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4799
SELECT col2 + - col0 DIV col1 AS col2 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4799
SELECT col2 + - col0 / col1 AS col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT col1 * - cor0.col0 + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL 24 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT DISTINCT - col0 + 75 * + col0 AS col0 FROM tab2 AS cor0
----
518
5772
5846

onlyif mysql # use DIV operator for integer division
query I rowsort label-4803
SELECT - col2 * - ( cor0.col1 ) DIV + cor0.col1 AS col1 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4803
SELECT - col2 * - ( cor0.col1 ) / + cor0.col1 AS col1 FROM tab1 cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4804
SELECT col0 + + CAST( - col1 AS SIGNED ) FROM tab1 cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-4804
SELECT col0 + + CAST ( - col1 AS INTEGER ) FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT - col2 + + 24 AS col0 FROM tab1 AS cor0
----
-30
-33
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-4806
SELECT CAST( + col1 AS SIGNED ) DIV + col0 col1 FROM tab0 cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4806
SELECT CAST ( + col1 AS INTEGER ) / + col0 col1 FROM tab0 cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4807
SELECT DISTINCT - - col0 DIV col1 + + col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-4807
SELECT DISTINCT - - col0 / col1 + + col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT - + cor0.col1 - - cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 * col1 * + col2 - - col0 FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT + 96 * col0 + - col0 * col1 FROM tab0 AS cor0
----
-35
240
445

query I rowsort
SELECT - - col2 - + col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - 11 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
110
143
286

query I rowsort
SELECT - + col2 + + col0 + + cor0.col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - - col1 * - col2 * + col2 + col1 AS col0 FROM tab1 cor0
----
-119795
-32480
-75790

onlyif mysql # use DIV operator for integer division
query I rowsort label-4815
SELECT - 79 DIV col1 col1 FROM tab2
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4815
SELECT - 79 / col1 col1 FROM tab2
----
-1
-2
-4

query I rowsort
SELECT DISTINCT - ( ( - tab0.col2 ) + - col0 ) AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL 27 * - col0 AS col2 FROM tab1
----
-1728
-2160
-81

query I rowsort
SELECT DISTINCT - ( + col1 ) * col0 FROM tab0 cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 5 col2 FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT ALL col1 * col0 - + cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT - 28 + col0 * col2 FROM tab1 AS cor0
----
134
3620
7652

query I rowsort
SELECT ALL - cor0.col1 * col1 * col0 + col2 FROM tab1 AS cor0
----
-13424
-1974
-6343

query I rowsort
SELECT ALL + col0 * + cor0.col0 - - col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4824
SELECT DISTINCT + + cor0.col1 DIV - col0 AS col0 FROM tab2 cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-4824
SELECT DISTINCT + + cor0.col1 / - col0 AS col0 FROM tab2 cor0
----
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4825
SELECT - 92 - - col0 DIV col1 AS col0 FROM tab1
----
-86
-86
-92

skipif mysql # not compatible
query I rowsort label-4825
SELECT - 92 - - col0 / col1 AS col0 FROM tab1
----
-86
-86
-92

query I rowsort
SELECT DISTINCT col1 + - col0 * + col0 AS col0 FROM tab0
----
-1128
-490
-7830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 33 * - col2 * col0 + col0 col0 FROM tab0
----
-1120
-240745
-26112

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL 79 + cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
2107
268
3081

query I rowsort
SELECT cor1.col1 AS col2 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 87 + + col0 AS col0 FROM tab2 AS cor0
----
165
166
94

query I rowsort
SELECT + 14 + + col2 AS col1 FROM tab0 AS cor0
----
15
47
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4833
SELECT CAST( 27 AS SIGNED ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

skipif mysql # not compatible
query I rowsort label-4833
SELECT CAST ( 27 AS INTEGER ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT 6 + - tab0.col0 AS col0 FROM tab0
----
-18
-29
-83

query I rowsort
SELECT ALL - col0 * - 58 FROM tab0
----
1392
2030
5162

query I rowsort
SELECT col2 * - col2 + - tab0.col1 - - col1 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL col1 * - 70 - + col1 * col0 FROM tab0
----
-10185
-14469
-8084

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 - - col1 col2 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4839
SELECT + 20 DIV ( col2 * col1 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4839
SELECT + 20 / ( col2 * col1 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT + + cor0.col2 * col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 22 * col2 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT + ( 27 ) FROM tab0 AS cor0
----
27
27
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - 15 col0 FROM tab1 cor0
----
-1200
-45
-960

query I rowsort
SELECT + col0 + + col1 * + tab1.col1 AS col2 FROM tab1
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col1 col0 FROM tab2 AS cor0 CROSS JOIN tab1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 CROSS JOIN tab1 WHERE NULL <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT ALL - - cor0.col0 DIV - col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4847
SELECT ALL - - cor0.col0 / - col1 FROM tab2 AS cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col1 * - col1 * + col0 + col0 col2 FROM tab2 AS cor0
----
-22752
-271440
-6720

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL IN ( tab0.col1 + tab0.col2 )
----

query I rowsort
SELECT col0 + tab2.col2 * - col0 AS col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - cor0.col1 + + cor0.col1 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + col1 * - cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT col2 * col0 + tab1.col1 AS col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL col1 * col2 + - cor0.col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT - col2 + - col1 * col0 AS col0 FROM tab1 AS cor0 WHERE NULL BETWEEN ( col2 - + col2 ) AND NULL
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( col0 * col1 - - col2 * col2 * col0 )
----

query I rowsort
SELECT col2 * + tab0.col1 * col2 FROM tab0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4858
SELECT DISTINCT col2 * tab1.col0 DIV col0 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4858
SELECT DISTINCT col2 * tab1.col0 / col0 AS col0 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4859
SELECT + + cor0.col0 * + col2 + + col0 + col2 * col2 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
70
7462
861

skipif mysql # not compatible
query I rowsort label-4859
SELECT + + cor0.col0 * + col2 + + col0 + col2 * col2 / cor0.col0 AS col2 FROM tab0 AS cor0
----
70
7462
861

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 + + col2 + + col1 FROM tab2 cor0
----
1619
701
895

query I rowsort
SELECT - col2 + col1 * col0 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT col0 * tab2.col2 + - col1 AS col2 FROM tab2
----
158
1969
2985

query I rowsort
SELECT - col1 + col1 * col1 FROM tab1
----
156
650
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 col0 FROM tab2
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-4865
SELECT DISTINCT col0 DIV - col0 - + col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-2

skipif mysql # not compatible
query I rowsort label-4865
SELECT DISTINCT col0 / - col0 - + col0 / + col0 AS col1 FROM tab1 AS cor0
----
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4866
SELECT ALL + col0 DIV col2 + + col1 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-4866
SELECT ALL + col0 / col2 + + col1 FROM tab0 AS cor0
----
132
86
92

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + - col1 AS col0 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT ALL - - col1 + col2 + col0 AS col2 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # use DIV operator for integer division
query I rowsort label-4869
SELECT + - col0 * col1 DIV col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4869
SELECT + - col0 * col1 / col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - col2 col1 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-4871
SELECT - tab1.col0 DIV + col2 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4871
SELECT - tab1.col0 / + col2 FROM tab1
----
-1
0
0

query I rowsort
SELECT - col2 * col1 * tab2.col2 AS col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT - + col1 * - 28 + col0 AS col0 FROM tab2 AS cor0
----
1730
555
875

query I rowsort
SELECT DISTINCT + col0 * + 29 FROM tab1 AS cor0
----
1856
2320
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 * - col2 col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT col1 * - ( col2 ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - - col0 - - col2 * + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + + col1 + col0 * + 65 AS col2 FROM tab1 AS cor0
----
221
4170
5213

query I rowsort
SELECT col2 * + 54 + - col2 * col0 FROM tab0 AS cor0
----
-2870
19
990

query I rowsort
SELECT ALL + col0 + ( 38 + col2 ) AS col1 FROM tab2 AS cor0
----
142
155
72

query I rowsort
SELECT ALL cor0.col2 * + col2 + + cor0.col0 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT col0 + - col1 * col0 FROM tab1 cor0
----
-576
-75
-960

query I rowsort
SELECT - col0 + + ( - col1 ) + col1 * - 62 FROM tab1 AS cor0
----
-1641
-694
-899

onlyif mysql # use DIV operator for integer division
query I rowsort label-4884
SELECT DISTINCT col0 + + col2 DIV - col0 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-4884
SELECT DISTINCT col0 + + col2 / - col0 FROM tab0 AS cor0
----
23
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4885
SELECT col1 DIV col0 + col2 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-4885
SELECT col1 / col0 + col2 FROM tab2 AS cor0
----
26
31
38

query I rowsort
SELECT + 12 * + col1 + col1 * - col2 * + col0 + + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-100724
-37000
-3978

query I rowsort
SELECT - tab2.col1 + - 27 * + col1 + + col0 FROM tab2
----
-1574
-397
-861

query I rowsort
SELECT col0 * + tab1.col0 * col2 AS col1 FROM tab1
----
233472
486
614400

query I rowsort
SELECT - ( + 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-4890
SELECT col1 + + CAST( NULL AS SIGNED ) * - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4890
SELECT col1 + + CAST ( NULL AS INTEGER ) * - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + cor0.col1 + + col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL - col2 - col2 AS col0 FROM tab0 AS cor0
----
-164
-2
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 16 col0 FROM tab1 AS cor0
----
-16
-16
-16

query I rowsort
SELECT ALL + col0 * col0 + - col0 AS col1 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT ALL - col2 * + col2 - - 92 FROM tab0 AS cor0
----
-6632
-997
91

query I rowsort
SELECT DISTINCT - col1 * - col1 + + 89 FROM tab0 cor0
----
7485
8370
9498

query I rowsort
SELECT ALL - - 28 * + cor0.col2 FROM tab0 cor0
----
2296
28
924

onlyif mysql # use DIV operator for integer division
query I rowsort label-4898
SELECT DISTINCT - - col0 DIV + cor0.col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-4898
SELECT DISTINCT - - col0 / + cor0.col1 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL - ( col0 ) * - col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 27 + ( col0 ) * - 96 FROM tab1
----
-315
-6171
-7707

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 33 col2 FROM tab2
----
33
33
33

query I rowsort
SELECT 12 * + col1 AS col2 FROM tab0 AS cor0
----
1032
1092
1164

onlyif mysql # use DIV operator for integer division
query I rowsort label-4903
SELECT ALL - 83 + - col1 DIV + col0 FROM tab0
----
-84
-85
-86

skipif mysql # not compatible
query I rowsort label-4903
SELECT ALL - 83 + - col1 / + col0 FROM tab0
----
-84
-85
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4904
SELECT - + cor0.col0 + CAST( NULL AS SIGNED ) * - 2 * col0 - ( 70 ) / col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4904
SELECT - + cor0.col0 + CAST ( NULL AS INTEGER ) * - 2 * col0 - ( 70 ) / col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - tab2.col0 + col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT - + col1 - - 21 AS col0 FROM tab0 AS cor0
----
-65
-70
-76

query I rowsort
SELECT ALL ( 48 + + cor0.col0 ) FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to dd09a8ab32bca2bd7aa8c8a339df4e50

query I rowsort
SELECT DISTINCT ( + tab0.col0 ) AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT 1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT + cor0.col1 - + 8 AS col0 FROM tab1 AS cor0
----
18
2
5

query I rowsort
SELECT cor0.col1 - + 88 AS col0 FROM tab0 AS cor0
----
-2
3
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4912
SELECT + col0 * CAST( 14 * - col0 AS SIGNED ) - - cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
-117
-53248
-83200

skipif mysql # not compatible
query I rowsort label-4912
SELECT + col0 * CAST ( 14 * - col0 AS INTEGER ) - - cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
-117
-53248
-83200

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

query I rowsort
SELECT - col1 * + tab1.col2 * 70 FROM tab1
----
-39900
-87360
-98280

query I rowsort
SELECT ALL ( cor0.col1 * cor0.col0 ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to bc669a3cc969c7619ebcffb5400ba0ba

query I rowsort
SELECT DISTINCT 18 * - col2 FROM tab1
----
-1026
-1728
-972

query I rowsort
SELECT 9 * - 56 FROM tab2
----
-504
-504
-504

onlyif mysql # use DIV operator for integer division
query I rowsort label-4918
SELECT DISTINCT - col1 * col1 DIV - col1 AS col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4918
SELECT DISTINCT - col1 * col1 / - col1 AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT 73 + 27 AS col1 FROM tab2 AS cor0
----
100
100
100

query I rowsort
SELECT DISTINCT + - cor0.col0 + col0 * - col1 + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + - col0 + - col0 AS col2 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT ALL - - cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT 26 * - tab2.col2 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 6ec0914f901ace364368d38c0138725b

query I rowsort
SELECT + 85 * + col0 AS col0 FROM tab2 AS cor0
----
595
6630
6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-4925
SELECT - 15 * + col0 DIV col0 FROM tab2 AS cor0
----
-15
-15
-15

skipif mysql # not compatible
query I rowsort label-4925
SELECT - 15 * + col0 / col0 FROM tab2 AS cor0
----
-15
-15
-15

query I rowsort
SELECT + cor0.col2 + col0 * col0 FROM tab2 cor0
----
6110
6279
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4927
SELECT DISTINCT CAST( 72 AS SIGNED ) FROM tab0
----
72

skipif mysql # not compatible
query I rowsort label-4927
SELECT DISTINCT CAST ( 72 AS INTEGER ) FROM tab0
----
72

query I rowsort
SELECT ALL 95 * - col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

query I rowsort
SELECT DISTINCT col0 + - ( col0 ) + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col2 + + ( col0 ) * 19 AS col1 FROM tab1 AS cor0
----
111
1273
1616

onlyif mysql # use DIV operator for integer division
query I rowsort label-4931
SELECT DISTINCT - 23 DIV - 74 + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4931
SELECT DISTINCT - 23 / - 74 + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL 45 - 76 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT ALL - cor0.col0 * 35 + - col0 + + col2 AS col2 FROM tab1 AS cor0
----
-2247
-2784
-54

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) * + col1 + col0 + - cor0.col1 FROM tab1 AS cor0
----
-1181
-1427
-516

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-4936
SELECT DISTINCT - + col2 * ( col2 ) * + CAST( col1 AS SIGNED ) + + cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
-110592
-29241
-72900

skipif mysql # not compatible
query I rowsort label-4936
SELECT DISTINCT - + col2 * ( col2 ) * + CAST ( col1 AS INTEGER ) + + cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
-110592
-29241
-72900

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-4938
SELECT DISTINCT + + 87 DIV col0 AS col0 FROM tab2 AS cor0
----
1
12

skipif mysql # not compatible
query I rowsort label-4938
SELECT DISTINCT + + 87 / col0 AS col0 FROM tab2 AS cor0
----
1
12

query I rowsort
SELECT ALL - - col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + cor0.col1 + col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL + 97 + col1 FROM tab1 AS cor0
----
107
110
123

query I rowsort
SELECT ALL col2 + - col0 * col0 FROM tab2 cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4943
SELECT - col2 + - col0 DIV + col1 AS col1 FROM tab2
----
-27
-27
-42

skipif mysql # not compatible
query I rowsort label-4943
SELECT - col2 + - col0 / + col1 AS col1 FROM tab2
----
-27
-27
-42

query I rowsort
SELECT ALL - cor0.col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT + tab1.col2 * 45 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to a801c73949a0597dbea339853af56ef3

query I rowsort
SELECT 98 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL - + col0 * col1 + - col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT + tab1.col0 + 36 FROM tab1
----
100
116
39

query I rowsort
SELECT col0 + + col2 * - 19 * col2 FROM tab0
----
-127667
-20667
16

query I rowsort
SELECT DISTINCT - 23 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-23

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab0, tab0 cor1, tab1, tab1 AS cor2
----
3645 values hashing to bce5cbf48f4a41569415c085ae91ae7c

query I rowsort
SELECT + + cor0.col0 * col2 AS col0 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 DISTINCT - col1 + 96 FROM tab0 cor0
----
-1
10
5

query I rowsort
SELECT 18 AS col1 FROM tab2 cor0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4956
SELECT ALL - col1 + + ( + col1 ) DIV - col2 + 81 * + col1 FROM tab0
----
6878
7279
7663

skipif mysql # not compatible
query I rowsort label-4956
SELECT ALL - col1 + + ( + col1 ) / - col2 + 81 * + col1 FROM tab0
----
6878
7279
7663

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1, tab2 cor2, tab0 AS cor3
----
3645 values hashing to 40e4acd618698dd2305f1f7b8b547f7a

query I rowsort
SELECT ALL + 20 FROM tab1, tab0 cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT ALL 77 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 34 * col2 col0 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT - - 85 * 3 FROM tab0 AS cor0
----
255
255
255

query I rowsort
SELECT ALL + 49 * 2 AS col1 FROM tab0
----
98
98
98

query I rowsort
SELECT + col2 + - col0 + ( + col2 + - col0 ) * + col0 * 54 FROM tab2
----
-174947
-219076
7580

query I rowsort
SELECT DISTINCT col1 + col0 + + 53 * - tab2.col0 AS col1 FROM tab2
----
-333
-3997
-4091

query I rowsort
SELECT ALL - col0 - + col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT + col1 * cor0.col0 + - col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4967
SELECT DISTINCT col0 * + col0 + + 26 DIV - cor0.col2 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-4967
SELECT DISTINCT col0 * + col0 + + 26 / - cor0.col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + 93 + col0 * col1 FROM tab2 AS cor0
----
1436
310
4695

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 85 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT + + col0 * col1 + + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT col1 + - col0 * 89 + tab2.col0 AS col1 FROM tab2
----
-585
-6805
-6935

query I rowsort
SELECT ALL + tab2.col0 * 59 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 87bed571573f5e33a11f2e1f74c6ca21

onlyif mysql # use DIV operator for integer division
query I rowsort label-4973
SELECT ( - col0 ) DIV 23 + + tab2.col2 FROM tab2
----
23
27
35

skipif mysql # not compatible
query I rowsort label-4973
SELECT ( - col0 ) / 23 + + tab2.col2 FROM tab2
----
23
27
35

query I rowsort
SELECT + + col0 * + 51 FROM tab0 AS cor0
----
1224
1785
4539

query I rowsort
SELECT - col1 + + ( + col2 * + col2 ) AS col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - col0 + + col2 * - col0 * - cor0.col2 FROM tab2 AS cor0
----
113997
5096
52650

query I rowsort
SELECT DISTINCT + cor0.col1 * 38 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT - col1 * + 55 FROM tab0 AS cor0
----
-4730
-5005
-5335

query I rowsort
SELECT DISTINCT col1 * - 90 FROM tab2 AS cor0
----
-1530
-2790
-5310

query I rowsort
SELECT DISTINCT + - col0 + ( col1 ) AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col0 * col2 * 1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4982
SELECT DISTINCT + + col2 * - CAST( col0 AS SIGNED ) FROM tab2 cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-4982
SELECT DISTINCT + + col2 * - CAST ( col0 AS INTEGER ) FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + col1 + - 16 * 95 AS col2 FROM tab2 AS cor0
----
-1537
-1551
-1579

query I rowsort
SELECT ALL + 70 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 col2 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + - col0 * - 91 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT col1 * + ( 43 + - col2 ) * - col2 AS col2 FROM tab0 AS cor0
----
-28380
-4074
291018

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4988
SELECT col1 + - CAST( 45 AS SIGNED ) FROM tab2 AS cor0
----
-14
-28
14

skipif mysql # not compatible
query I rowsort label-4988
SELECT col1 + - CAST ( 45 AS INTEGER ) FROM tab2 AS cor0
----
-14
-28
14

query I rowsort
SELECT ALL - + col0 * col0 * cor0.col0 FROM tab0 cor0
----
-13824
-42875
-704969

query I rowsort
SELECT 3 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT + col2 + 28 AS col1 FROM tab0
----
110
29
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4992
SELECT col1 * col0 DIV 30 + col2 FROM tab1 AS cor0
----
130
56
78

skipif mysql # not compatible
query I rowsort label-4992
SELECT col1 * col0 / 30 + col2 FROM tab1 AS cor0
----
130
56
78

query I rowsort
SELECT - 29 - cor0.col0 * 50 AS col1 FROM tab0 AS cor0
----
-1229
-1779
-4479

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 65 col1 FROM tab2
----
-65
-65
-65

query I rowsort
SELECT ALL + 37 * col2 AS col0 FROM tab1
----
1998
2109
3552

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - 15 * cor0.col1 - col1 FROM tab0 AS cor0
----
-1376
-1456
-1552

query I rowsort
SELECT cor0.col1 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4999
SELECT - + col2 + col1 DIV cor0.col1 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-4999
SELECT - + col2 + col1 / cor0.col1 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT 23 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT + col2 + ( 56 ) AS col2 FROM tab0 AS cor0
----
138
57
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5002
SELECT DISTINCT + + col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5002
SELECT DISTINCT + + col0 / + col1 AS col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL + + col0 * + col0 + - col2 FROM tab0 AS cor0
----
1224
543
7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * + 59 col0 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT ALL col0 * - cor0.col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + ( - ( - col2 ) ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - 7 + + col1 FROM tab0 AS cor0
----
79
84
90

query I rowsort
SELECT ALL - col2 * col2 * cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
-611795
-62
-93630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( col1 ) col0 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5010
SELECT + - 90 * col2 DIV cor0.col0 FROM tab0 AS cor0
----
-123
-2
-82

skipif mysql # not compatible
query I rowsort label-5010
SELECT + - 90 * col2 / cor0.col0 FROM tab0 AS cor0
----
-123
-2
-82

query I rowsort
SELECT DISTINCT - col0 * ( - 0 ) AS col0 FROM tab2
----
0

query I rowsort
SELECT col1 + - 27 * ( - tab1.col2 ) FROM tab1
----
1484
1549
2605

query I rowsort
SELECT 70 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-490
-5460
-5530

onlyif mysql # use DIV operator for integer division
query I rowsort label-5014
SELECT + col2 + - 58 DIV cor0.col0 FROM tab0 AS cor0
----
0
31
82

skipif mysql # not compatible
query I rowsort label-5014
SELECT + col2 + - 58 / cor0.col0 FROM tab0 AS cor0
----
0
31
82

query I rowsort
SELECT + 64 FROM tab0, tab2 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT - + cor0.col0 * + cor0.col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - 30 FROM tab1, tab0, tab0 AS cor0
----
-30

query I rowsort
SELECT - 48 * - 19 + - col0 * - col2 FROM tab2
----
1101
2940
3914

query I rowsort
SELECT + 23 AS col0 FROM tab0
----
23
23
23

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 82e15d5967b272804e574774895a0222

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5021
SELECT DISTINCT - + ( - ( - col0 ) ) * CAST( - col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-5021
SELECT DISTINCT - + ( - ( - col0 ) ) * CAST ( - col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 76 * cor0.col1 * + 16 AS col2 FROM tab0, tab2 AS cor0
----
20672
37696
71744

onlyif mysql # use DIV operator for integer division
query I rowsort label-5023
SELECT ALL + + 9 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5023
SELECT ALL + + 9 / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + 88 AS col2 FROM tab0 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 * col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL ( - col0 ) * col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 * + col2 + 23 AS col1 FROM tab0 AS cor0
----
120
2861
7485

onlyif mysql # use DIV operator for integer division
query I rowsort label-5028
SELECT DISTINCT col0 DIV + 22 FROM tab1
----
0
2
3

skipif mysql # not compatible
query I rowsort label-5028
SELECT DISTINCT col0 / + 22 FROM tab1
----
0
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - ( col1 ) ) col0 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT cor0.col0 + - col1 * col2 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif mysql # not compatible
query I rowsort
SELECT - - col0 + CAST ( 91 AS REAL ) AS col0 FROM tab2 AS cor0
----
169
170
98

query I rowsort
SELECT DISTINCT tab2.col1 * - 68 + - 85 AS col0 FROM tab2, tab0 AS cor0
----
-1241
-2193
-4097

query I rowsort
SELECT 46 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT DISTINCT 49 * col1 FROM tab2
----
1519
2891
833

query I rowsort
SELECT ALL - ( + 10 ) * col1 + - col1 FROM tab0 AS cor0
----
-1001
-1067
-946

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( 70 ) + cor0.col0 col1 FROM tab1 cor0
----
-6
-67
10

query I rowsort
SELECT DISTINCT + + cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
3
64
80

query I rowsort
SELECT - tab1.col0 * + col0 * - tab1.col2 AS col1 FROM tab1
----
233472
486
614400

query I rowsort
SELECT - - col2 + + col1 * - col1 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + col2 * - ( + col2 ) + col2 * - 20 FROM tab1 AS cor0
----
-11136
-3996
-4389

query I rowsort
SELECT cor0.col2 FROM tab0, tab1, tab0 AS cor0, tab2 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 2 col1 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-5043
SELECT + col0 DIV col1 + + ( - col0 * col0 ) + - 65 FROM tab0 AS cor0
----
-1290
-641
-7986

skipif mysql # not compatible
query I rowsort label-5043
SELECT + col0 / col1 + + ( - col0 * col0 ) + - 65 FROM tab0 AS cor0
----
-1290
-641
-7986

onlyif mysql # use DIV operator for integer division
query I rowsort label-5044
SELECT col0 + col2 DIV - ( col1 ) AS col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5044
SELECT col0 + col2 / - ( col1 ) AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT + col2 * col2 - + col0 * col1 AS col2 FROM tab1
----
2609
2838
8176

query I rowsort
SELECT DISTINCT 25 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
25

query I rowsort
SELECT - 3 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 65b7e16aaa7821ace3a45a9846ffa166

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5048
SELECT ALL + col2 - + CAST( - col2 * + col0 AS SIGNED ) FROM tab2 AS cor0
----
2054
216
3040

skipif mysql # not compatible
query I rowsort label-5048
SELECT ALL + col2 - + CAST ( - col2 * + col0 AS INTEGER ) FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + col0 * col0 + 36 * - col0 * 42 AS col0 FROM tab0 AS cor0
----
-126647
-35712
-51695

query I rowsort
SELECT ALL + col1 + ( ( col1 ) ) FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT cor0.col0 * 81 FROM tab1 AS cor0
----
243
5184
6480

query I rowsort
SELECT ALL - col2 - - col1 * + cor0.col0 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5053
SELECT DISTINCT + cor0.col0 DIV 85 AS col1 FROM tab0 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5053
SELECT DISTINCT + cor0.col0 / 85 AS col1 FROM tab0 cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5054
SELECT - cor0.col1 * ( + ( - col0 ) ) * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5054
SELECT - cor0.col1 * ( + ( - col0 ) ) * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * - col1 + cor0.col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT col1 + + 40 FROM tab1 cor0
----
50
53
66

query I rowsort
SELECT 86 FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to e219687f6f4ab6f7ee442792edcebca9

query I rowsort
SELECT DISTINCT - + 34 * cor0.col1 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1081
-2032
-616

query I rowsort
SELECT + + 25 AS col0 FROM tab0 AS cor0
----
25
25
25

query I rowsort
SELECT - 43 + col2 FROM tab2 AS cor0
----
-16
-17
-5

query I rowsort
SELECT DISTINCT ( col1 ) + - col0 * col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - 3 + + 51 FROM tab2 cor0
----
48
48
48

query I rowsort
SELECT ALL - col2 + + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL + + col1 + - ( col1 ) * + 2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - col1 + 63 FROM tab2 AS cor0
----
32
4
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-5066
SELECT - col0 + cor0.col2 DIV - cor0.col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-81

skipif mysql # not compatible
query I rowsort label-5066
SELECT - col0 + cor0.col2 / - cor0.col1 AS col1 FROM tab2 AS cor0
----
-7
-78
-81

query I rowsort
SELECT ( col2 ) * + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ( col0 ) - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + + col1 * - col2 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - 48 * - cor0.col0 FROM tab2 cor0
----
336
3744
3792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5071
SELECT ALL + col2 * col1 + ( cor0.col0 ) * - col2 + ( - col1 ) DIV + col2 FROM tab0 AS cor0
----
-35
163
2044

skipif mysql # not compatible
query I rowsort label-5071
SELECT ALL + col2 * col1 + ( cor0.col0 ) * - col2 + ( - col1 ) / + col2 FROM tab0 AS cor0
----
-35
163
2044

onlyif mysql # use DIV operator for integer division
query I rowsort label-5072
SELECT ALL - + cor0.col0 DIV + col0 + 2 * col2 FROM tab1 AS cor0
----
107
113
191

skipif mysql # not compatible
query I rowsort label-5072
SELECT ALL - + cor0.col0 / + col0 + 2 * col2 FROM tab1 AS cor0
----
107
113
191

query I rowsort
SELECT + col1 * col1 * - tab0.col2 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT DISTINCT - + cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - - col0 * col2 * - col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT col0 * col2 + ( - col2 ) AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + 62 + + col1 + - ( 76 * cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-439
-5807
-5925

onlyif mysql # use DIV operator for integer division
query I rowsort label-5078
SELECT - 23 * col1 + col0 DIV + 24 FROM tab2 AS cor0
----
-1354
-388
-713

skipif mysql # not compatible
query I rowsort label-5078
SELECT - 23 * col1 + col0 / + 24 FROM tab2 AS cor0
----
-1354
-388
-713

query I rowsort
SELECT DISTINCT col1 * - col2 * + col1 + col1 FROM tab2 AS cor0
----
-10965
-25916
-90447

query I rowsort
SELECT + + col2 + col1 * - col1 * col2 AS col2 FROM tab2 AS cor0
----
-10944
-25920
-90480

query I rowsort
SELECT DISTINCT + ( col0 + + col2 * 70 ) FROM tab2
----
1897
1898
2739

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 col0 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT ALL - + 50 * col0 - - ( ( col1 ) ) FROM tab1 AS cor0
----
-124
-3190
-3987

query I rowsort
SELECT + + col2 * + col2 + 68 FROM tab2 AS cor0
----
1512
744
797

query I rowsort
SELECT ALL - col1 + + col0 * ( 85 + + col2 ) * + col1 FROM tab0 AS cor0
----
1352442
243466
291873

query I rowsort
SELECT DISTINCT + + 96 + - col1 AS col2 FROM tab0 cor0
----
-1
10
5

query I rowsort
SELECT DISTINCT - - col2 * - col0 * col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL 95 + - col2 AS col1 FROM tab2 cor0
----
57
68
69

query I rowsort
SELECT - 99 * col2 + + 20 * + col0 * col2 AS col2 FROM tab1 AS cor0
----
-2106
144096
67317

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5090
SELECT DISTINCT 81 * ( + tab0.col1 + CAST( NULL AS DECIMAL ) ) / + cor0.col1 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5090
SELECT DISTINCT 81 * ( + tab0.col1 + CAST ( NULL AS REAL ) ) / + cor0.col1 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
NULL

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab2 AS cor1, tab2, tab0 cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col1 + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT cor0.col0 + - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT cor1.col0 AS col0 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - col1 * + col1 - - col1 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT col1 * + 27 AS col2 FROM tab0
----
2322
2457
2619

query I rowsort
SELECT - col0 * + col2 + col0 AS col1 FROM tab2
----
-182
-1950
-2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5098
SELECT CAST( col1 AS SIGNED ) + col2 + 89 FROM tab2
----
144
147
174

skipif mysql # not compatible
query I rowsort label-5098
SELECT CAST ( col1 AS INTEGER ) + col2 + 89 FROM tab2
----
144
147
174

query I rowsort
SELECT ALL + ( 67 ) * - col0 + col0 AS col0 FROM tab2
----
-462
-5148
-5214

onlyif mysql # use DIV operator for integer division
query I rowsort label-5100
SELECT ALL 34 DIV col0 FROM tab1 cor0
----
0
0
11

skipif mysql # not compatible
query I rowsort label-5100
SELECT ALL 34 / col0 FROM tab1 cor0
----
0
0
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-5101
SELECT DISTINCT col2 DIV + 94 - - col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-5101
SELECT DISTINCT col2 / + 94 - - col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5102
SELECT + CAST( NULL AS SIGNED ) + + col0 * - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5102
SELECT + CAST ( NULL AS INTEGER ) + + col0 * - col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( 62 ) + col2 FROM tab0
----
144
63
95

query I rowsort
SELECT DISTINCT col1 * - col0 + tab1.col2 AS col2 FROM tab1
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5105
SELECT + ( 67 ) DIV col0 AS col0 FROM tab2
----
0
0
9

skipif mysql # not compatible
query I rowsort label-5105
SELECT + ( 67 ) / col0 AS col0 FROM tab2
----
0
0
9

query I rowsort
SELECT ( col2 ) * col1 * 66 AS col1 FROM tab1
----
37620
82368
92664

query I rowsort
SELECT DISTINCT - 20 * + ( col1 + 68 ) AS col2 FROM tab2 AS cor0
----
-1700
-1980
-2540

query I rowsort
SELECT col2 * + col2 + - 20 * 31 FROM tab0
----
-619
469
6104

onlyif mysql # use DIV operator for integer division
query I rowsort label-5109
SELECT DISTINCT - 93 DIV 39 + + tab1.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
1
62
78

skipif mysql # not compatible
query I rowsort label-5109
SELECT DISTINCT - 93 / 39 + + tab1.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
1
62
78

query I rowsort
SELECT DISTINCT 98 * col0 + - col0 AS col2 FROM tab0
----
2328
3395
8633

query I rowsort
SELECT - ( col2 ) * - col2 * - col2 + col2 * tab2.col2 FROM tab2
----
-16900
-18954
-53428

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col0 * col1 * ( - col2 + ( col0 ) * - col0 ) col2 FROM tab2 AS cor0
----
-16465
-28118194
-8432659

query I rowsort
SELECT DISTINCT 70 + + 88 AS col2 FROM tab1
----
158

query I rowsort
SELECT + 54 + ( - col0 ) * + col2 AS col2 FROM tab2
----
-135
-1974
-2948

query I rowsort
SELECT + ( + 78 ) AS col0 FROM tab2
----
78
78
78

query I rowsort
SELECT - ( - 0 ) + cor0.col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5117
SELECT ALL + ( + 39 ) DIV - cor0.col1 + + 99 FROM tab0 AS cor0
----
99
99
99

skipif mysql # not compatible
query I rowsort label-5117
SELECT ALL + ( + 39 ) / - cor0.col1 + + 99 FROM tab0 AS cor0
----
99
99
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5118
SELECT + CAST( NULL AS SIGNED ) / 97 + col1 + 37 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5118
SELECT + CAST ( NULL AS INTEGER ) / 97 + col1 + 37 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 10 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT ALL + 7 AS col0 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT ALL + + cor0.col0 + col1 + col0 AS col2 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT 56 * - col1 + + 79 FROM tab0 AS cor0
----
-4737
-5017
-5353

query I rowsort
SELECT - - 58 + - col1 FROM tab1 AS cor0
----
32
45
48

query I rowsort
SELECT DISTINCT tab0.col2 + col2 + col0 AS col2 FROM tab0
----
253
37
90

query I rowsort
SELECT + col2 * cor0.col2 + ( + col1 ) AS col0 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT + - col2 + cor0.col2 * + col0 AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - ( cor0.col2 ) AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 * + tab2.col2 col2 FROM tab2
----
1066
1107
1558

query I rowsort
SELECT - - col1 * + col2 + + ( col0 ) * + col2 AS col0 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT - - col0 * - col0 * col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT + col2 * - 6 FROM tab2 AS cor0
----
-156
-162
-228

query I rowsort
SELECT col0 * col1 + - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT - + col0 + - 68 * col2 FROM tab0 AS cor0
----
-103
-2268
-5665

query I rowsort
SELECT - col0 + - 37 * col2 FROM tab2 AS cor0
----
-1006
-1040
-1485

query I rowsort
SELECT 89 * - col1 FROM tab2
----
-1513
-2759
-5251

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5136
SELECT DISTINCT + - col0 * + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5136
SELECT DISTINCT + - col0 * + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 + 71 * 2 + + col0 AS col2 FROM tab0 AS cor0
----
140
80
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + 10 col1 FROM tab2 cor0
----
-170
-310
-590

onlyif mysql # use DIV operator for integer division
query I rowsort label-5139
SELECT + cor0.col2 DIV 26 AS col0 FROM tab1 cor0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-5139
SELECT + cor0.col2 / 26 AS col0 FROM tab1 cor0
----
2
2
3

query I rowsort
SELECT + + col0 + + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - 10 * - col1 AS col0 FROM tab1
----
100
130
260

query I rowsort
SELECT + col0 * col0 + - col1 * - 53 * + col2 AS col2 FROM tab0 AS cor0
----
150990
403407
6366

onlyif mysql # use DIV operator for integer division
query I rowsort label-5143
SELECT + 60 - col0 DIV - col2 FROM tab1 AS cor0
----
60
60
61

skipif mysql # not compatible
query I rowsort label-5143
SELECT + 60 - col0 / - col2 FROM tab1 AS cor0
----
60
60
61

query I rowsort
SELECT - ( + col2 ) + + cor0.col2 AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + ( cor0.col1 ) - - col1 AS col2 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5146
SELECT - CAST( NULL AS SIGNED ) * 81 - + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5146
SELECT - CAST ( NULL AS INTEGER ) * 81 - + cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5147
SELECT DISTINCT + + col2 + col2 * col1 DIV + ( + col1 ) AS col2 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-5147
SELECT DISTINCT + + col2 + col2 * col1 / + ( + col1 ) AS col2 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5148
SELECT - - 92 + col2 * + CAST( col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
2120
281
3094

skipif mysql # not compatible
query I rowsort label-5148
SELECT - - 92 + col2 * + CAST ( col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
2120
281
3094

query I rowsort
SELECT ALL - ( - col2 ) * - col0 + + col0 AS col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + + col2 * ( + col1 ) - ( 66 + cor0.col2 ) * col0 * + 23 FROM tab0 cor0
----
-295494
-51810
-53838

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5151
SELECT col2 * + CAST( NULL AS SIGNED ) col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5151
SELECT col2 * + CAST ( NULL AS INTEGER ) col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( 48 ) * cor0.col0 FROM tab2 AS cor0
----
-336
-3744
-3792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5153
SELECT DISTINCT - - 82 * ( + col1 ) DIV 85 AS col0 FROM tab0 AS cor0
----
82
87
93

skipif mysql # not compatible
query I rowsort label-5153
SELECT DISTINCT - - 82 * ( + col1 ) / 85 AS col0 FROM tab0 AS cor0
----
82
87
93

query I rowsort
SELECT 97 + + col1 * col0 AS col1 FROM tab1 AS cor0
----
1137
175
737

query I rowsort
SELECT + + 42 + col0 * - col2 FROM tab1 AS cor0
----
-120
-3606
-7638

query I rowsort
SELECT ALL + + 10 * ( + col2 ) FROM tab1 cor0
----
540
570
960

query I rowsort
SELECT ALL + + 92 * ( - col1 ) + + cor0.col0 FROM tab1 AS cor0
----
-1116
-2389
-856

onlyif mysql # use DIV operator for integer division
query I rowsort label-5158
SELECT ALL + col1 DIV col0 + col1 AS col2 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-5158
SELECT ALL + col1 / col0 + col1 AS col2 FROM tab1
----
10
13
34

query I rowsort
SELECT - col0 * 73 FROM tab2
----
-511
-5694
-5767

query I rowsort
SELECT ALL cor0.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5161
SELECT ALL + tab0.col1 DIV col0 + + col2 col0 FROM tab0
----
3
36
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5161
SELECT ALL + tab0.col1 / col0 + + col2 col0 FROM tab0
----
3
36
83

query I rowsort
SELECT 65 * tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a6255f826acaf2d31e3f32491824e83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col0 col1 FROM tab0, tab2 AS cor0, tab2, tab1 cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT DISTINCT - - col1 + - col0 * - col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ( cor0.col2 ) * col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
35937
551368

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5166
SELECT ALL + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5166
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 25 FROM tab2 cor0
----
-25
-25
-25

query I rowsort
SELECT ALL 2 FROM tab1, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 77 + col0 col0 FROM tab2 AS cor0
----
155
156
84

query I rowsort
SELECT ALL 53 - col0 FROM tab0 AS cor0
----
-36
18
29

query I rowsort
SELECT - - 68 + + col2 * col0 FROM tab1 AS cor0
----
230
3716
7748

onlyif mysql # use DIV operator for integer division
query I rowsort label-5172
SELECT DISTINCT + col0 + col1 DIV - cor0.col0 AS col2 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-5172
SELECT DISTINCT + col0 + col1 / - cor0.col0 AS col2 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT - - 19 AS col1 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT tab0.col0 + col2 * - col2 AS col0 FROM tab0
----
-1065
-6635
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 * - ( 12 ) col2 FROM tab2 AS cor0
----
-2268
-24336
-36024

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 64 * col0 col2 FROM tab0 AS cor0
----
1536
2240
5696

query I rowsort
SELECT ALL - + col1 * - col1 * col0 FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT ALL col2 * ( col2 * + col1 ) + + 47 * + tab1.col0 + col0 AS col2 FROM tab1
----
123648
35562
75960

query I rowsort
SELECT col0 + col2 - - cor0.col1 AS col1 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # use DIV operator for integer division
query I rowsort label-5180
SELECT col1 DIV col1 + 47 FROM tab0 cor0
----
48
48
48

skipif mysql # not compatible
query I rowsort label-5180
SELECT col1 / col1 + 47 FROM tab0 cor0
----
48
48
48

query I rowsort
SELECT DISTINCT - col1 + col0 * - col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * cor0.col2 * cor0.col0 col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - col1 * - col0 * col2 + - col0 FROM tab2 AS cor0
----
119574
50955
5852

query I rowsort
SELECT ALL + col1 * + 55 FROM tab2 cor0
----
1705
3245
935

query I rowsort
SELECT - col2 + - 65 FROM tab2 AS cor0
----
-103
-91
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5186
SELECT DISTINCT + cor0.col2 + - 97 DIV - col0 col1 FROM tab0 AS cor0
----
3
37
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5186
SELECT DISTINCT + cor0.col2 + - 97 / - col0 col1 FROM tab0 AS cor0
----
3
37
83

query I rowsort
SELECT - col2 + + 57 - 21 * - cor0.col0 FROM tab2 AS cor0
----
1669
1678
177

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + ( + cor0.col1 ) col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT col2 * + col2 - - col1 * + col0 AS col2 FROM tab2 AS cor0
----
2787
5278
946

query I rowsort
SELECT + col2 * col1 - + col1 AS col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL + + ( col1 ) AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL - - col0 * - col0 + - col1 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT ( col1 ) * - cor0.col0 * col0 - + col0 AS col0 FROM tab1 AS cor0
----
-237
-41024
-83280

query I rowsort
SELECT ALL ( - col1 ) * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 * - 79 FROM tab1 cor0
----
-237
-5056
-6320

query I rowsort
SELECT - + ( col0 ) + cor0.col1 * + cor0.col1 FROM tab2 AS cor0
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-5197
SELECT - col1 * - col1 DIV col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5197
SELECT - col1 * - col1 / col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - + 57 FROM tab0 cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT + + 42 * - cor0.col0 FROM tab2 AS cor0
----
-294
-3276
-3318

query I rowsort
SELECT ALL col1 * - col2 + + col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 + col2 col2 FROM tab2 AS cor0
----
103
91
92

query I rowsort
SELECT ALL col0 + col1 * - col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + + col2 * col1 + col0 + + col0 AS col1 FROM tab2 AS cor0
----
1690
804
851

query I rowsort
SELECT DISTINCT + ( - col1 ) + ( col0 * col2 ) FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-5205
SELECT DISTINCT - ( - col0 ) DIV - col1 AS col2 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-5205
SELECT DISTINCT - ( - col0 ) / - col1 AS col2 FROM tab0
----
0

query I rowsort
SELECT ALL - col1 + + ( - col0 ) * col0 * col1 FROM tab0 AS cor0
----
-118922
-49622
-720902

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT - col1 * + col0 * col0 AS col2 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT + + 85 + col1 * cor0.col2 + col1 AS col1 FROM tab0 cor0
----
279
3009
7638

query I rowsort
SELECT cor0.col1 + col2 * 47 AS col2 FROM tab1 AS cor0
----
2564
2689
4525

query I rowsort
SELECT - + 94 + + col1 FROM tab0 AS cor0
----
-3
-8
3

query I rowsort
SELECT - 75 + - cor0.col0 * 41 AS col2 FROM tab0 AS cor0
----
-1059
-1510
-3724

query I rowsort
SELECT + - 57 + col1 * 10 * col1 FROM tab1 AS cor0
----
1633
6703
943

query I rowsort
SELECT DISTINCT - 87 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-87

query I rowsort
SELECT 75 - + cor0.col1 * col0 FROM tab2 AS cor0
----
-1268
-142
-4527

query I rowsort
SELECT ALL - 63 FROM tab1, tab2 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 0a6489496517f27fb746473909f2b76b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5217
SELECT col0 DIV ( col0 + col0 ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5217
SELECT col0 / ( col0 + col0 ) FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + 25 FROM tab2, tab1 AS cor0
----
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-5219
SELECT DISTINCT ( + col0 ) DIV + col0 AS col0 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-5219
SELECT DISTINCT ( + col0 ) / + col0 AS col0 FROM tab2
----
1

query I rowsort
SELECT 15 * - tab1.col2 FROM tab1
----
-1440
-810
-855

query I rowsort
SELECT - cor0.col1 + col1 * + cor0.col0 AS col0 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT 12 + cor0.col2 FROM tab0 AS cor0
----
13
45
94

query I rowsort
SELECT DISTINCT tab2.col2 + + col0 AS col1 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5224
SELECT cor0.col2 * + cor0.col1 + cor0.col2 DIV 10 AS col2 FROM tab2 AS cor0
----
1536
649
839

skipif mysql # not compatible
query I rowsort label-5224
SELECT cor0.col2 * + cor0.col1 + cor0.col2 / 10 AS col2 FROM tab2 AS cor0
----
1536
649
839

query I rowsort
SELECT 87 * + col0 FROM tab2
----
609
6786
6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-5226
SELECT - 78 DIV - col1 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5226
SELECT - 78 / - col1 FROM tab2
----
1
2
4

query I rowsort
SELECT DISTINCT tab2.col0 FROM tab2, tab0, tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL - - ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + + ( + col2 ) * - 14 AS col1 FROM tab2 AS cor0
----
-364
-378
-532

query I rowsort
SELECT + col1 - - col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + + col0 - cor0.col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT col0 - + col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT ALL + + 46 FROM tab2 AS cor0
----
46
46
46

query I rowsort
SELECT ALL + tab2.col1 * 19 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1c462c407a25bf027d875f1c1501febd

query I rowsort
SELECT ALL 53 + tab2.col2 * 29 FROM tab2
----
1155
807
836

query I rowsort
SELECT - 96 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to a7b3e5dd01c8929180b7ffda67f79798

onlyif mysql # use DIV operator for integer division
query I rowsort label-5237
SELECT ALL ( col0 ) DIV - ( tab1.col2 * + col1 ) + 69 * col2 AS col2 FROM tab1
----
3726
3933
6624

skipif mysql # not compatible
query I rowsort label-5237
SELECT ALL ( col0 ) / - ( tab1.col2 * + col1 ) + 69 * col2 AS col2 FROM tab1
----
3726
3933
6624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 62 - cor0.col2 col2 FROM tab1 AS cor0
----
-34
5
8

query IIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 WHERE NULL BETWEEN ( NULL ) AND NULL
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5240
SELECT ALL - col2 * - tab2.col1 + - ( - ( + col0 ) * CAST( NULL AS SIGNED ) ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5240
SELECT ALL - col2 * - tab2.col1 + - ( - ( + col0 ) * CAST ( NULL AS INTEGER ) ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + - col2 AS col1 FROM tab0
----
-9
34
7

query I rowsort
SELECT - 32 FROM tab1, tab2 cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5243
SELECT ALL + col2 DIV - col1 col1 FROM tab1
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5243
SELECT ALL + col2 / - col1 col1 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT DISTINCT + 70 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
70

query I rowsort
SELECT + col2 * col1 - cor0.col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT ALL tab2.col0 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-5247
SELECT DISTINCT + col1 DIV + col0 - col0 * ( col1 ) * col0 AS col1 FROM tab0
----
-118823
-49533
-720810

skipif mysql # not compatible
query I rowsort label-5247
SELECT DISTINCT + col1 / + col0 - col0 * ( col1 ) * col0 AS col1 FROM tab0
----
-118823
-49533
-720810

query I rowsort
SELECT - col0 * + 99 AS col0 FROM tab0 AS cor0
----
-2376
-3465
-8811

query I rowsort
SELECT - col2 * - col0 * col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT 38 * - 61 FROM tab2 cor0
----
-2318
-2318
-2318

query I rowsort
SELECT ALL - + 62 AS col2 FROM tab1 AS cor0
----
-62
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5252
SELECT ALL + - col1 DIV col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5252
SELECT ALL + - col1 / col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col1 * + 28 AS col1 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT - col2 * + 68 * col1 AS col2 FROM tab0 cor0
----
-192984
-507416
-6596

query I rowsort
SELECT - - col1 + - col0 * + col2 AS col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL col2 * - ( col0 ) + col1 * + 57 AS col2 FROM tab0 AS cor0
----
-2111
4110
5494

query I rowsort
SELECT ALL cor0.col1 * ( 5 ) + + col1 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT + col1 * - tab2.col1 AS col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ALL + 84 FROM tab0, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT + col2 * 54 + + ( + col1 * + col0 ) AS col2 FROM tab0
----
12527
3449
3846

query I rowsort
SELECT ALL col2 + 3 FROM tab1
----
57
60
99

query I rowsort
SELECT ALL + col2 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT + col0 * + 64 + 2 AS col2 FROM tab0 AS cor0
----
1538
2242
5698

onlyif mysql # use DIV operator for integer division
query I rowsort label-5264
SELECT ALL + col2 + 1 DIV col0 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5264
SELECT ALL + col2 + 1 / col0 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col0 + ( col1 ) AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 * col2 * + col0 AS col2 FROM tab1 cor0
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-5267
SELECT DISTINCT - col2 + - 29 DIV col0 col1 FROM tab0 AS cor0
----
-1
-34
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5267
SELECT DISTINCT - col2 + - 29 / col0 col1 FROM tab0 AS cor0
----
-1
-34
-82

query I rowsort
SELECT - col1 + ( + col1 ) - cor0.col0 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5269
SELECT ALL + CAST( NULL AS SIGNED ) * + col2 + cor0.col1 * CAST( + col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5269
SELECT ALL + CAST ( NULL AS INTEGER ) * + col2 + cor0.col1 * CAST ( + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + + 10 * col1 AS col1 FROM tab2 AS cor0
----
187
341
649

query I rowsort
SELECT ALL - col2 + - col1 * - col0 AS col0 FROM tab1
----
24
583
944

query I rowsort
SELECT ALL + 62 * + col1 AS col2 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT DISTINCT 71 + col1 FROM tab0 AS cor0
----
157
162
168

query I rowsort
SELECT DISTINCT 21 * + col2 AS col1 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT DISTINCT 22 + cor0.col1 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
100
1062
662

onlyif mysql # use DIV operator for integer division
query I rowsort label-5276
SELECT DISTINCT + + col1 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5276
SELECT DISTINCT + + col1 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - - 88 + - col0 * - col0 AS col2 FROM tab0 cor0
----
1313
664
8009

query I rowsort
SELECT - col0 + - 44 FROM tab2 cor0
----
-122
-123
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + 36 * + col0 col1 FROM tab1
----
2247
2784
54

query I rowsort
SELECT 31 FROM tab0, tab1 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + tab0.col0 + + col1 + - tab0.col1 * col2 col1 FROM tab0
----
-15470
-3395
-4816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 49 col2 FROM tab2 AS cor0
----
-49
-49
-49

query I rowsort
SELECT + col1 * - col0 * - col0 FROM tab1 cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT col0 * + cor0.col2 + col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL + 74 * - col0 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-525
-5850
-5925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - - col2 col0 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT + + 39 * col2 FROM tab2 AS cor0
----
1014
1053
1482

query I rowsort
SELECT ALL - + 57 + col1 AS col0 FROM tab0 AS cor0
----
29
34
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-5289
SELECT DISTINCT + col0 * - col0 + + col1 * col0 DIV - col2 AS col1 FROM tab1 AS cor0
----
-10
-4107
-6410

skipif mysql # not compatible
query I rowsort label-5289
SELECT DISTINCT + col0 * - col0 + + col1 * col0 / - col2 AS col1 FROM tab1 AS cor0
----
-10
-4107
-6410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5290
SELECT + ( col1 ) - - CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5290
SELECT + ( col1 ) - - CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 42 + - col1 FROM tab0
----
-44
-49
-55

query I rowsort
SELECT - 22 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT + col2 * ( + col2 ) * col1 AS col1 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL ( + col0 ) AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + 41 AS col1 FROM tab1, tab2 AS cor0
----
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-5297
SELECT ALL + col0 * + col1 + - ( - col2 ) DIV ( - col1 ) FROM tab2 AS cor0
----
1341
217
4602

skipif mysql # not compatible
query I rowsort label-5297
SELECT ALL + col0 * + col1 + - ( - col2 ) / ( - col1 ) FROM tab2 AS cor0
----
1341
217
4602

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col2 - CAST ( + col0 AS REAL ) * col0 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT ALL + + col0 * + 60 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT ALL - cor0.col1 + 28 * + col1 AS col1 FROM tab2 AS cor0
----
1593
459
837

query I rowsort
SELECT DISTINCT + - col0 - - ( col2 ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL - cor0.col1 + + 31 * + 7 * col1 FROM tab1 cor0
----
2160
2808
5616

query I rowsort
SELECT ALL + tab2.col2 * col1 * col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT 25 + tab1.col2 AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to ec1c6036b4ecd9b4b8599119dc7e2b51

query I rowsort
SELECT ALL + + 19 + - col0 FROM tab1 AS cor0
----
-45
-61
16

query I rowsort
SELECT DISTINCT 90 + 87 AS col1 FROM tab1 cor0
----
177

query I rowsort
SELECT + col1 + - col0 + col1 AS col2 FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT - 75 + - 83 FROM tab1 AS cor0
----
-158
-158
-158

query I rowsort
SELECT col0 + + 78 * col1 AS col2 FROM tab2 cor0
----
1405
2425
4680

query I rowsort
SELECT ALL + - ( ( + cor0.col1 ) ) * - col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5311
SELECT - 85 DIV 49 col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5311
SELECT - 85 / 49 col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col0 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + - cor0.col1 * - col2 + - col0 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT col0 * 85 FROM tab2
----
595
6630
6715

query I rowsort
SELECT 34 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT ALL - cor0.col1 * + col0 * - col1 FROM tab1 cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-5318
SELECT col1 DIV + 16 + col2 AS col2 FROM tab0 AS cor0
----
38
7
87

skipif mysql # not compatible
query I rowsort label-5318
SELECT col1 / + 16 + col2 AS col2 FROM tab0 AS cor0
----
38
7
87

query I rowsort
SELECT + col1 + ( + col0 ) * col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 + - ( col1 ) col0 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL - col2 * 83 FROM tab1
----
-4482
-4731
-7968

query I rowsort
SELECT DISTINCT - col1 * + 9 FROM tab2
----
-153
-279
-531

query I rowsort
SELECT DISTINCT - 76 + 88 FROM tab2, tab1 cor0
----
12

query I rowsort
SELECT + col0 + + ( + col2 ) - + col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5325
SELECT + cor0.col2 * - ( - cor0.col1 * cor0.col0 ) + - col2 DIV 31 AS col1 FROM tab1 AS cor0
----
36479
4211
99837

skipif mysql # not compatible
query I rowsort label-5325
SELECT + cor0.col2 * - ( - cor0.col1 * cor0.col0 ) + - col2 / 31 AS col1 FROM tab1 AS cor0
----
36479
4211
99837

query I rowsort
SELECT ALL + + cor0.col1 FROM tab0, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT col0 * + 68 AS col0 FROM tab2
----
476
5304
5372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5328
SELECT CAST( NULL AS SIGNED ) + col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5328
SELECT CAST ( NULL AS INTEGER ) + col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + cor0.col2 col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5330
SELECT - col2 DIV + col2 + cor0.col2 AS col1 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-5330
SELECT - col2 / + col2 + cor0.col2 AS col1 FROM tab1 AS cor0
----
53
56
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 * col1 col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT + - ( col2 ) * + col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - + 11 + - col1 AS col0 FROM tab2 AS cor0
----
-28
-42
-70

query I rowsort
SELECT 66 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT - + col1 - ( col2 + col1 * - 86 ) AS col0 FROM tab2 AS cor0
----
1407
2608
4989

query I rowsort
SELECT + col0 * + ( col0 ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - tab0.col0 + col2 + + col1 FROM tab0
----
63
84
95

query I rowsort
SELECT DISTINCT + cor0.col1 + + tab2.col0 * + tab2.col2 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to e8a0dd81527a983c243ce69a54122a04

query I rowsort
SELECT + - 24 + cor0.col2 AS col1 FROM tab1, tab2, tab2 cor0
----
27 values hashing to 73413a79ac04d089677684e55369ab33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 + col0 + + col1 col1 FROM tab0
----
133
143
262

query I rowsort
SELECT + col0 * + 59 FROM tab2 AS cor0
----
413
4602
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * tab0.col2 * col2 col1 FROM tab0
----
611884
93654
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + ( + col2 ) * + col2 col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT DISTINCT col1 * + col1 + col2 + - col1 AS col2 FROM tab1 AS cor0
----
147
252
704

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col0 + col1 col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + cor0.col1 * col1 - col2 * col0 AS col1 FROM tab2 AS cor0
----
-2713
1453
772

query I rowsort
SELECT ALL 28 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT ALL + + col1 * ( - col0 ) * col2 + 72 AS col1 FROM tab0 AS cor0
----
-3323
-664046
-68040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + ( - cor0.col2 ) col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - cor0.col1 + - ( - col2 ) * 26 * col1 FROM tab2 AS cor0
----
16779
21731
39825

query I rowsort
SELECT ALL col1 * tab2.col2 - col0 FROM tab2
----
1456
567
830

query I rowsort
SELECT + 1 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT ALL + 77 AS col1 FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT col2 * + col1 + + col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT 63 FROM tab2, tab1, tab0 AS cor0
----
63

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 AS REAL ) * col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - 69 + cor0.col1 * + col2 AS col2 FROM tab1 AS cor0
----
1179
1335
501

query I rowsort
SELECT + + col2 * + col0 * - col2 + + col2 * col0 FROM tab1 AS cor0
----
-204288
-729600
-8586

query I rowsort
SELECT DISTINCT + 22 AS col0 FROM tab2, tab1 AS cor0
----
22

query I rowsort
SELECT ALL - 63 AS col0 FROM tab1
----
-63
-63
-63

query I rowsort
SELECT 61 + col2 * 86 FROM tab1 AS cor0
----
4705
4963
8317

query I rowsort
SELECT - - 8 AS col2 FROM tab0 cor0
----
8
8
8

query I rowsort
SELECT ALL - 1 * + 27 * col0 AS col0 FROM tab2
----
-189
-2106
-2133

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5364
SELECT + col1 + col2 * - cor0.col1 / CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5364
SELECT + col1 + col2 * - cor0.col1 / CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 39 * + col2 FROM tab0 AS cor0
----
1287
3198
39

query I rowsort
SELECT - 24 + cor0.col0 FROM tab0 AS cor0
----
0
11
65

query I rowsort
SELECT ALL + 42 AS col0 FROM tab0 AS cor0
----
42
42
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-5368
SELECT DISTINCT + col0 DIV col0 col1 FROM tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5368
SELECT DISTINCT + col0 / col0 col1 FROM tab2 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5369
SELECT DISTINCT 8 DIV col2 FROM tab0 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-5369
SELECT DISTINCT 8 / col2 FROM tab0 AS cor0
----
0
8

query I rowsort
SELECT - + 72 + + col2 + - col1 * 15 FROM tab1 AS cor0
----
-165
-171
-408

query I rowsort
SELECT ALL + col2 * - col1 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - col2 - - cor0.col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 82 AS col2 FROM tab1 cor0
----
82

query I rowsort
SELECT ALL + 55 * col0 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT - ( col0 ) * 91 + 53 - col2 AS col2 FROM tab0 AS cor0
----
-2164
-3133
-8128

onlyif mysql # use DIV operator for integer division
query I rowsort label-5376
SELECT DISTINCT - - ( + col1 ) DIV col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5376
SELECT DISTINCT - - ( + col1 ) / col0 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT - 58 * col2 + - 92 - - col0 AS col2 FROM tab1 AS cor0
----
-3221
-3334
-5580

query I rowsort
SELECT - col2 * col1 - 8 FROM tab2 cor0
----
-1542
-654
-845

query I rowsort
SELECT ALL - 82 FROM tab0 cor0
----
-82
-82
-82

query I rowsort
SELECT + - col1 + - col2 + ( col0 ) FROM tab0 AS cor0
----
-63
-84
-95

query I rowsort
SELECT DISTINCT - ( col1 ) * col0 FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5382
SELECT CAST( - col0 AS SIGNED ) - - col2 AS col0 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-5382
SELECT CAST ( - col0 AS INTEGER ) - - col2 AS col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL col1 + col0 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + col2 + - col0 - col1 * col0 FROM tab1 AS cor0
----
-1024
-27
-647

query I rowsort
SELECT DISTINCT - + 81 + + col1 * col2 AS col1 FROM tab1 cor0
----
1167
1323
489

query I rowsort
SELECT DISTINCT ( col2 ) * 5 AS col1 FROM tab0 AS cor0
----
165
410
5

query I rowsort
SELECT - - col2 + col1 + 64 AS col0 FROM tab0 AS cor0
----
162
183
237

skipif mysql # not compatible
query I rowsort
SELECT + - col1 * - CAST ( col2 AS REAL ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + - col1 * + ( + ( - col1 ) ) + - col0 + - col1 * col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - + col2 * - 80 * 6 + - col2 * - col1 + - col0 * col1 FROM tab2 AS cor0
----
13580
17543
9412

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + 34 col2 FROM tab2 AS cor0
----
112
113
41

query I rowsort
SELECT DISTINCT + cor0.col0 * + col0 + - 2 FROM tab2 AS cor0
----
47
6082
6239

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5393
SELECT ALL - col2 + CAST( 73 AS SIGNED ) * - cor0.col1 FROM tab0 AS cor0
----
-6311
-6725
-7082

skipif mysql # not compatible
query I rowsort label-5393
SELECT ALL - col2 + CAST ( 73 AS INTEGER ) * - cor0.col1 FROM tab0 AS cor0
----
-6311
-6725
-7082

query I rowsort
SELECT ALL - - cor0.col2 * - 83 + + 81 AS col1 FROM tab2 AS cor0
----
-2077
-2160
-3073

query I rowsort
SELECT DISTINCT + ( col1 ) + cor0.col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - - col1 * 38 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
3235
3376
3685

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab1 cor1, tab0 AS cor2
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT ( col2 ) * + col2 FROM tab2 cor0
----
1444
676
729

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab2, tab1 cor1, tab2 AS cor2
----
972 values hashing to bcf430f79386b43bc4077271fcd15cf0

query I rowsort
SELECT - + 85 AS col1 FROM tab1 AS cor0
----
-85
-85
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col2 col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + + 47 + + col1 * + col2 FROM tab1 AS cor0
----
1295
1451
617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col1 ) * - col2 col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col1 + + ( + 54 ) AS col1 FROM tab2
----
113
71
85

query I rowsort
SELECT DISTINCT col0 * 66 AS col0 FROM tab0
----
1584
2310
5874

query I rowsort
SELECT - - ( + col0 ) * - col1 + + 57 AS col0 FROM tab2 AS cor0
----
-1286
-160
-4545

query I rowsort
SELECT DISTINCT + col2 + 99 FROM tab0
----
100
132
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-5408
SELECT ALL col0 + + 1 DIV 37 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5408
SELECT ALL col0 + + 1 / 37 FROM tab1
----
3
64
80

query I rowsort
SELECT - cor0.col2 + cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5fc5fcec216468c99d1c0eaf371b3149

query I rowsort
SELECT DISTINCT 75 AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
75

query I rowsort
SELECT DISTINCT + - 10 + - col0 AS col1 FROM tab2 AS cor0
----
-17
-88
-89

query I rowsort
SELECT ALL + - 13 * - cor0.col1 - - col1 FROM tab1 cor0
----
140
182
364

query I rowsort
SELECT DISTINCT - col1 * - ( col0 ) FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT + 11 + col2 * + col0 FROM tab1
----
173
3659
7691

query I rowsort
SELECT ALL - - 98 * 86 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 21cba1eefce6b634d4251b50fd41ab7f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 + tab0.col2 col0 FROM tab0
----
171
36
57

query I rowsort
SELECT + col2 + - 47 FROM tab0 AS cor0
----
-14
-46
35

query I rowsort
SELECT ALL - + col0 + 37 AS col1 FROM tab2 AS cor0
----
-41
-42
30

query I rowsort
SELECT ALL + cor0.col1 * + 49 FROM tab0 AS cor0
----
4214
4459
4753

query I rowsort
SELECT ALL + cor0.col1 * - ( col1 ) AS col1 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5421
SELECT DISTINCT cor0.col2 DIV - 94 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5421
SELECT DISTINCT cor0.col2 / - 94 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL col1 * - col1 * col2 FROM tab1 cor0
----
-16224
-36504
-5700

query I rowsort
SELECT + col2 + + 91 * - col0 FROM tab0 AS cor0
----
-2151
-3184
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 col0 FROM tab0, tab0 cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL - cor0.col1 * cor0.col2 + ( col1 ) FROM tab0 cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 - - col1 * 48 col1 FROM tab2 cor0
----
1578
2922
906

query I rowsort
SELECT + + 64 * col2 AS col2 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT + 94 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT DISTINCT - 22 AS col0 FROM tab0
----
-22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 81 - col1 * col1 col0 FROM tab0 AS cor0
----
-7477
-8362
-9490

query I rowsort
SELECT - - col0 - col1 * col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT + - col0 * + col2 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL col0 * 35 FROM tab2
----
245
2730
2765

query I rowsort
SELECT col2 * - col2 * col2 AS col0 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT DISTINCT 61 * cor0.col0 AS col0 FROM tab2, tab1 cor0
----
183
3904
4880

onlyif mysql # use DIV operator for integer division
query I rowsort label-5436
SELECT + 25 + + cor0.col2 DIV col1 AS col1 FROM tab1 cor0
----
27
30
32

skipif mysql # not compatible
query I rowsort label-5436
SELECT + 25 + + cor0.col2 / col1 AS col1 FROM tab1 cor0
----
27
30
32

query I rowsort
SELECT + 58 FROM tab2, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT 22 AS col0 FROM tab0, tab0 cor0
----
22

query I rowsort
SELECT cor0.col2 + col1 + col0 AS col1 FROM tab0 AS cor0
----
133
143
262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 88 col1 FROM tab2 cor0
----
10
81
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5441
SELECT CAST( + cor0.col2 AS SIGNED ) * - col1 FROM tab1 cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-5441
SELECT CAST ( + cor0.col2 AS INTEGER ) * - col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + col1 + + ( + col2 ) FROM tab0 AS cor0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5443
SELECT + - CAST( NULL AS SIGNED ) * col0 + - col0 + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5443
SELECT + - CAST ( NULL AS INTEGER ) * col0 + - col0 + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5444
SELECT DISTINCT + - ( col2 ) DIV + col2 AS col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5444
SELECT DISTINCT + - ( col2 ) / + col2 AS col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT + - 33 + col0 FROM tab2 AS cor0
----
-26
45
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-5446
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-5446
SELECT + col1 / col0 col1 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT 63 * - col1 AS col0 FROM tab0 AS cor0
----
-5418
-5733
-6111

query I rowsort
SELECT DISTINCT + col1 * col0 + - cor0.col1 AS col1 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) + col0 * col2 * col0 FROM tab1 cor0
----
233529
540
614496

query I rowsort
SELECT ALL 40 AS col0 FROM tab0 AS cor0
----
40
40
40

query I rowsort
SELECT col0 + 26 FROM tab0 AS cor0
----
115
50
61

query I rowsort
SELECT - - col0 + - col1 * col2 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT - cor0.col0 + - cor0.col1 * + 66 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to d3ad8ff750276b6f36e897fbf070ee71

query I rowsort
SELECT col1 * ( tab1.col1 + - tab1.col0 ) AS col2 FROM tab1
----
-540
-871
598

query I rowsort
SELECT DISTINCT - + cor0.col0 * - 56 FROM tab1 AS cor0
----
168
3584
4480

query I rowsort
SELECT ALL - 12 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT + - col2 * ( + col1 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + col0 * col0 - + col1 FROM tab1 AS cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col2 + cor0.col1 * + col2 col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT col2 * + col1 + col2 * + col2 AS col2 FROM tab1 AS cor0
----
10464
3819
4320

query I rowsort
SELECT ALL ( + 10 ) + + col0 AS col1 FROM tab2 AS cor0
----
17
88
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5462
SELECT - - col1 * + col1 DIV cor0.col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5462
SELECT - - col1 * + col1 / cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - + cor0.col0 * + col2 + + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL col2 + + cor0.col2 + col2 AS col0 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT + col2 + col2 * + col2 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT - 41 AS col0 FROM tab1 AS cor0
----
-41

query I rowsort
SELECT 75 FROM tab0, tab1 cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT + 48 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT ALL - col2 * + col0 * + col2 + + col2 + col1 AS col2 FROM tab0 AS cor0
----
-26017
-598263
63

query I rowsort
SELECT - + ( ( - cor1.col2 ) ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL - col1 * + ( col2 + col0 ) * + 10 AS col1 FROM tab0
----
-155610
-34920
-49020

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 * 77 + + cor0.col1 * - col0 * ( 18 ) col2 FROM tab2 AS cor0
----
-27100
-5985
-84838

query I rowsort
SELECT - - col2 + 39 * col2 AS col0 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT ALL cor0.col1 * + ( + col0 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT 57 FROM tab0, tab2 AS cor0
----
57

query I rowsort
SELECT - + col2 * + ( cor0.col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + col2 + 3 * - col1 AS col2 FROM tab2
----
-13
-151
-66

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2, tab0 AS cor0, tab0 cor1
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

query I rowsort
SELECT ALL + col1 + col0 * + tab2.col2 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL col2 * col0 + - col0 AS col1 FROM tab2
----
182
1950
2923

query I rowsort
SELECT ALL 85 + ( + col2 ) + ( - col1 ) FROM tab0
----
-11
32
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 * ( - 20 ) col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
-1180
-340
-620

query I rowsort
SELECT ALL - col0 * + 59 FROM tab2 AS cor0
----
-413
-4602
-4661

query I rowsort
SELECT + + 94 + col0 * col1 FROM tab1 AS cor0
----
1134
172
734

query I rowsort
SELECT DISTINCT + col1 * - 0 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - ( + 14 ) * + col0 + ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-1335
-360
-525

query I rowsort
SELECT ALL - - cor0.col0 + col2 * col2 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT + ( 16 ) FROM tab1
----
16
16
16

query I rowsort
SELECT + + 40 + col0 AS col1 FROM tab2 AS cor0
----
118
119
47

query I rowsort
SELECT ALL - 91 * col1 AS col1 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT DISTINCT + + 78 * col0 AS col1 FROM tab2 AS cor0
----
546
6084
6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * cor0.col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT col2 * col2 + + 35 * col2 FROM tab2 AS cor0
----
1586
1674
2774

query I rowsort
SELECT 35 + col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
1479
711
764

query I rowsort
SELECT ALL col1 * col1 - + ( - 87 ) FROM tab1 AS cor0
----
187
256
763

onlyif mysql # use DIV operator for integer division
query I rowsort label-5496
SELECT - cor0.col1 DIV col0 + - col0 FROM tab0 AS cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-5496
SELECT - cor0.col1 / col0 + - col0 FROM tab0 AS cor0
----
-27
-37
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5497
SELECT + ( cor0.col0 ) DIV + 83 + + 33 FROM tab2 AS cor0
----
33
33
33

skipif mysql # not compatible
query I rowsort label-5497
SELECT + ( cor0.col0 ) / + 83 + + 33 FROM tab2 AS cor0
----
33
33
33

query I rowsort
SELECT 64 * col2 FROM tab2 cor0
----
1664
1728
2432

query I rowsort
SELECT DISTINCT - + col2 * col0 + + col1 * col1 AS col2 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT DISTINCT - col2 * - col1 * 43 FROM tab1 cor0
----
24510
53664
60372

query I rowsort
SELECT - col0 * col1 + cor0.col0 * col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * col1 + 86 FROM tab0 AS cor0
----
-11
-2752
-7376

query I rowsort
SELECT DISTINCT 67 + cor0.col1 AS col2 FROM tab2, tab0, tab0 cor0
----
153
158
164

query I rowsort
SELECT ALL + - cor0.col2 * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col1 * col1 * + 93 FROM tab0
----
687828
770133
875037

query I rowsort
SELECT + + col1 * + col1 - col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT + + 14 * col2 + col1 * 43 FROM tab0 AS cor0
----
4160
4185
5061

query I rowsort
SELECT - col1 * + col2 * + col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT col0 * - 85 AS col0 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT - col1 * + 96 FROM tab1 AS cor0
----
-1248
-2496
-960

query I rowsort
SELECT ALL + 34 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT + col0 * col1 + + tab2.col0 AS col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT col2 * - col2 + - col1 + - col0 FROM tab1
----
-2945
-3323
-9309

onlyif mysql # use DIV operator for integer division
query I rowsort label-5514
SELECT DISTINCT + col0 DIV 50 + col1 * col1 FROM tab1 AS cor0
----
101
170
676

skipif mysql # not compatible
query I rowsort label-5514
SELECT DISTINCT + col0 / 50 + col1 * col1 FROM tab1 AS cor0
----
101
170
676

query I rowsort
SELECT DISTINCT - - 15 * col1 FROM tab1 AS cor0
----
150
195
390

query I rowsort
SELECT ALL + 0 * cor0.col1 + col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5517
SELECT - CAST( NULL AS SIGNED ) / + cor0.col1 + col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5517
SELECT - CAST ( NULL AS INTEGER ) / + cor0.col1 + col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 * + col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT + + 80 + col2 FROM tab1 cor0
----
134
137
176

onlyif mysql # use DIV operator for integer division
query I rowsort label-5520
SELECT col1 DIV + 22 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5520
SELECT col1 / + 22 AS col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - 96 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to c89b545346f99713888a7934e4caa539

query I rowsort
SELECT ALL ( 7 ) FROM tab0
----
7
7
7

query I rowsort
SELECT DISTINCT - + ( col1 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + tab1.col1 AS col0 FROM tab1 WHERE ( NULL ) > NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) NOT IN ( col1 / + col1 + col2 / - col1 )
----

query I rowsort
SELECT ALL tab2.col2 + + col1 * - col0 FROM tab2 WHERE NOT NULL IN ( col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col0 + - col0 col1 FROM tab2
----
182
1950
2923

query I rowsort
SELECT DISTINCT - col2 + - col0 AS col0 FROM tab0 WHERE NOT ( NULL ) <> NULL
----

query III rowsort
SELECT * FROM tab1 WHERE col0 BETWEEN ( col0 ) AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( col1 ) NOT IN ( - col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab1 WHERE NOT ( + col1 ) IN ( + col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT + tab2.col2 * col1 + tab2.col0 AS col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - col1 * tab0.col0 - + col0 FROM tab0
----
-2088
-3430
-8188

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) > col0 + col2 / col2 + col2 * col0
----

query I rowsort
SELECT - tab0.col1 + - col1 * - col1 FROM tab0
----
7310
8190
9312

query III rowsort
SELECT * FROM tab1 WHERE + col1 <> NULL
----

query I rowsort
SELECT DISTINCT + - ( col1 ) * 22 + 4 + + col0 FROM tab0 AS cor0
----
-1864
-1909
-2095

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT - tab2.col2 NOT IN ( col1 * - col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col2 IN ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5540
SELECT col0 + + col0 * tab1.col0 DIV col0 FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort label-5540
SELECT col0 + + col0 * tab1.col0 / col0 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT col1 * - col1 AS col2 FROM tab1 AS cor0 WHERE ( + col2 + col0 ) IN ( col0 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL NOT BETWEEN col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5543
SELECT ALL col1 DIV col0 + - col0 * - col2 AS col2 FROM tab1
----
170
3648
7680

skipif mysql # not compatible
query I rowsort label-5543
SELECT ALL col1 / col0 + - col0 * - col2 AS col2 FROM tab1
----
170
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - tab2.col1 col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT + col1 / + col1 + col0 * - col2 + - col1 FROM tab2 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL + col2 * col0 + tab2.col2 * col0 * col0 FROM tab2
----
1512
160212
240160

onlyif mysql # use DIV operator for integer division
query I rowsort label-5547
SELECT - tab0.col1 * - col2 + col0 DIV col0 AS col1 FROM tab0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-5547
SELECT - tab0.col1 * - col2 + col0 / col0 AS col1 FROM tab0
----
2839
7463
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col2 col0 FROM tab0 WHERE NULL <= NULL
----

query I rowsort
SELECT col2 * + col0 * + col0 + cor0.col0 FROM tab0 AS cor0
----
1260
19032
649611

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT - col0 >= col2 / - col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 cor1, tab1, tab2 AS cor2
----
3645 values hashing to 4805bcb9c04e49d1f6f82defa880d751

query I rowsort
SELECT DISTINCT 54 * - col2 FROM tab1 AS cor0
----
-2916
-3078
-5184

query I rowsort
SELECT DISTINCT col0 * 24 AS col1 FROM tab2 AS cor0
----
168
1872
1896

query I rowsort
SELECT + 22 FROM tab1, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5555
SELECT - col1 * CAST( + 7 AS SIGNED ) AS col1 FROM tab1
----
-182
-70
-91

skipif mysql # not compatible
query I rowsort label-5555
SELECT - col1 * CAST ( + 7 AS INTEGER ) AS col1 FROM tab1
----
-182
-70
-91

query I rowsort
SELECT + col2 * + ( cor0.col0 ) + 86 * col0 FROM tab2 AS cor0
----
791
8736
9796

query I rowsort
SELECT + 12 * tab2.col0 + - col2 * col2 FROM tab2
----
-496
-645
260

query I rowsort
SELECT col1 * + col2 - + col2 AS col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT ALL ( + col0 ) * col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) * + col0 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - - 67 * + col1 * col0 FROM tab2 AS cor0
----
14539
308334
89981

query I rowsort
SELECT DISTINCT - col2 + - col2 AS col2 FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT ALL + col1 * - col0 * ( + tab1.col1 * - col2 ) + col2 * tab1.col1 - - col0 FROM tab1
----
110919
1299248
365434

query I rowsort
SELECT ALL 29 - - col0 AS col1 FROM tab1
----
109
32
93

query I rowsort
SELECT DISTINCT + 32 * - col0 AS col2 FROM tab0
----
-1120
-2848
-768

query I rowsort
SELECT + col1 * col0 * ( col0 ) AS col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT col0 + col2 + col2 AS col1 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT - col2 * - col1 + ( col0 ) * + col2 FROM tab2 AS cor0
----
1026
3562
3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-5569
SELECT 81 DIV + col1 + col1 * 25 FROM tab2 AS cor0
----
1476
429
777

skipif mysql # not compatible
query I rowsort label-5569
SELECT 81 / + col1 + col1 * 25 FROM tab2 AS cor0
----
1476
429
777

query I rowsort
SELECT - 3 + - col1 * + col0 * col1 AS col2 FROM tab2 AS cor0
----
-22834
-271521
-6730

query I rowsort
SELECT ALL col0 - + ( - col0 ) FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL - col0 + - 85 AS col2 FROM tab1 AS cor0
----
-149
-165
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-5573
SELECT DISTINCT + - col0 DIV col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5573
SELECT DISTINCT + - col0 / col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT - col0 + - 98 AS col1 FROM tab1 AS cor0
----
-101
-162
-178

query I rowsort
SELECT - col0 * - cor0.col2 + - col2 * col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ( col0 ) * - 72 AS col1 FROM tab2
----
-504
-5616
-5688

query I rowsort
SELECT col2 * - 34 FROM tab1 AS cor0
----
-1836
-1938
-3264

query I rowsort
SELECT DISTINCT + col1 + + 48 FROM tab1 AS cor0
----
58
61
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-5579
SELECT cor0.col0 DIV col0 - - col0 AS col2 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-5579
SELECT cor0.col0 / col0 - - col0 AS col2 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT DISTINCT + - col1 + - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - cor0.col0 * cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 75a608bf2ba236d24f146ac4aff9ec52

query I rowsort
SELECT ALL col0 - cor0.col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col1 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5584
SELECT ALL + - CAST( - col2 AS SIGNED ) FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5584
SELECT ALL + - CAST ( - col2 AS INTEGER ) FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - 68 - 54 FROM tab0 cor0
----
-122

query I rowsort
SELECT ( cor0.col0 ) + + col0 * + col0 * col2 FROM tab0 AS cor0
----
1260
19032
649611

query I rowsort
SELECT DISTINCT + col2 + col2 + + col0 FROM tab2 AS cor0
----
130
155
61

query I rowsort
SELECT ALL 58 + - ( col0 ) FROM tab0 AS cor0
----
-31
23
34

query I rowsort
SELECT - col0 + tab0.col0 * - 52 FROM tab0
----
-1272
-1855
-4717

query I rowsort
SELECT ALL col1 + 87 * + cor0.col0 FROM tab2 AS cor0
----
640
6845
6890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5591
SELECT DISTINCT CAST( col0 AS SIGNED ) * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-5591
SELECT DISTINCT CAST ( col0 AS INTEGER ) * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + ( + 37 ) + col0 * - col2 FROM tab1
----
-125
-3611
-7643

onlyif mysql # use DIV operator for integer division
query I rowsort label-5593
SELECT 75 + - 49 DIV + col1 AS col2 FROM tab2
----
73
74
75

skipif mysql # not compatible
query I rowsort label-5593
SELECT 75 + - 49 / + col1 AS col2 FROM tab2
----
73
74
75

query I rowsort
SELECT col2 + - 1 AS col1 FROM tab1
----
53
56
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5595
SELECT + CAST( NULL AS SIGNED ) + tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5595
SELECT + CAST ( NULL AS INTEGER ) + tab2.col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( ( col1 ) * - col1 ) + + col2 AS col1 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT DISTINCT + 99 AS col0 FROM tab1
----
99

query I rowsort
SELECT DISTINCT col0 * + col1 + - cor0.col1 * col2 + col2 * + col2 AS col2 FROM tab0 cor0
----
315
3299
7361

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 65 col0 FROM tab0 AS cor0
----
147
66
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5600
SELECT DISTINCT col2 * + col1 DIV col1 AS col2 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5600
SELECT DISTINCT col2 * + col1 / col1 AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT - col2 * + 2 AS col0 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT DISTINCT - tab2.col1 - col2 AS col0 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - tab2.col2 - col0 AS col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT - col0 * 35 + + 62 AS col1 FROM tab2 AS cor0
----
-183
-2668
-2703

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5605
SELECT ALL - col1 + CAST( NULL AS SIGNED ) * - 89 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5605
SELECT ALL - col1 + CAST ( NULL AS INTEGER ) * - 89 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5606
SELECT - col2 * - col1 * ( col1 ) + col0 DIV + col0 AS col1 FROM tab2 AS cor0
----
10983
25948
90507

skipif mysql # not compatible
query I rowsort label-5606
SELECT - col2 * - col1 * ( col1 ) + col0 / + col0 AS col1 FROM tab2 AS cor0
----
10983
25948
90507

query I rowsort
SELECT tab0.col1 * + col2 + - col1 + tab0.col2 FROM tab0
----
1
2785
7453

query I rowsort
SELECT DISTINCT + 6 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
6

query I rowsort
SELECT + col0 * tab1.col0 AS col2 FROM tab1
----
4096
6400
9

query I rowsort
SELECT DISTINCT + cor0.col1 * + 24 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT DISTINCT + col0 * ( + 58 ) * - col2 AS col2 FROM tab2 AS cor0
----
-10962
-117624
-174116

query I rowsort
SELECT - col0 - col0 * col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT + + cor0.col1 * 45 - 29 FROM tab2 AS cor0
----
1366
2626
736

query I rowsort
SELECT col1 * + ( col0 ) - col1 * - col0 FROM tab2 AS cor0
----
2686
434
9204

query I rowsort
SELECT DISTINCT col1 + 46 + col1 FROM tab2 AS cor0
----
108
164
80

query I rowsort
SELECT col0 + + ( - 75 ) FROM tab2 AS cor0
----
-68
3
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5617
SELECT ALL cor0.col0 * CAST( NULL AS SIGNED ) + col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5617
SELECT ALL cor0.col0 * CAST ( NULL AS INTEGER ) + col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 + - ( col2 ) FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL + col0 - ( + col0 ) * col1 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - col1 * - col1 + col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT + tab0.col1 * col1 * + col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT tab0.col0 + tab0.col0 + - col1 AS col2 FROM tab0
----
-27
-38
87

query I rowsort
SELECT DISTINCT + col2 * col2 + + col1 AS col0 FROM tab0
----
1175
6815
98

query I rowsort
SELECT ALL + col1 * col0 + col0 AS col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL - col0 + + tab2.col2 AS col2 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5626
SELECT ALL - - col1 DIV + cor0.col2 AS col1 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5626
SELECT ALL - - col1 / + cor0.col2 AS col1 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT ALL + + col1 * col1 + - col1 AS col0 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT col0 + - col2 + col2 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + + col0 * col1 + col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT - + col1 * col0 + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query III rowsort
SELECT * FROM tab1 WHERE NOT + col2 * col0 + + col0 <> NULL
----

query I rowsort
SELECT + cor0.col1 * - col0 * col2 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-119678
-51072
-5886

query I rowsort
SELECT ALL col1 + + col1 * col1 + - col0 * col2 * + tab0.col0 AS col0 FROM tab0
----
-11526
-641150
8281

onlyif mysql # use DIV operator for integer division
query I rowsort label-5634
SELECT - col0 + col0 DIV + cor0.col0 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-5634
SELECT - col0 + col0 / + cor0.col0 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT ALL col2 + col2 * col1 FROM tab0 cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5636
SELECT DISTINCT 59 + - col0 DIV col0 AS col2 FROM tab0 AS cor0
----
58

skipif mysql # not compatible
query I rowsort label-5636
SELECT DISTINCT 59 + - col0 / col0 AS col2 FROM tab0 AS cor0
----
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5637
SELECT ALL - cor0.col1 DIV col0 + cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
1248
1396
570

skipif mysql # not compatible
query I rowsort label-5637
SELECT ALL - cor0.col1 / col0 + cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
1248
1396
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5638
SELECT DISTINCT 38 DIV cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5638
SELECT DISTINCT 38 / cor0.col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + + col2 * col2 + - col2 + + col0 FROM tab0 AS cor0
----
1080
35
6731

query I rowsort
SELECT ALL - 23 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT DISTINCT + 23 + col0 * col1 FROM tab1 cor0
----
101
1063
663

query I rowsort
SELECT 76 * col2 + + col0 FROM tab1 AS cor0
----
4107
4396
7376

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col0 col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ( col2 ) + - col2 * col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL cor0.col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 * col2 * col2 col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ALL + col0 + col2 + + col2 * col1 FROM tab0
----
133
2895
7633

query I rowsort
SELECT + ( + col1 ) * col0 + col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT ( col0 ) * + 50 * 57 + col1 * ( ( - col0 ) ) FROM tab2 AS cor0
----
19733
217698
223807

onlyif mysql # use DIV operator for integer division
query I rowsort label-5650
SELECT + + ( col0 ) DIV - col1 + + 2 * col1 AS col0 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-5650
SELECT + + ( col0 ) / - col1 + + 2 * col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + - col0 * + 49 * + col1 FROM tab1 AS cor0
----
-31360
-3822
-50960

query I rowsort
SELECT + col2 * - col0 + col2 * - cor0.col1 AS col2 FROM tab1 cor0
----
-1566
-4218
-8928

query I rowsort
SELECT ALL - - col0 * - 91 + - col0 FROM tab1 AS cor0
----
-276
-5888
-7360

query I rowsort
SELECT DISTINCT + - col1 - 37 AS col1 FROM tab2 AS cor0
----
-54
-68
-96

query I rowsort
SELECT DISTINCT col1 + + cor0.col1 + + cor0.col2 FROM tab0 AS cor0
----
195
205
264

query I rowsort
SELECT ALL + col2 * - 12 * col0 FROM tab2 AS cor0
----
-2268
-24336
-36024

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 40 col2 FROM tab1 AS cor0
----
136
94
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5658
SELECT DISTINCT col1 + + col1 + col2 DIV - cor0.col1 AS col2 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-5658
SELECT DISTINCT col1 + + col1 + col2 / - cor0.col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL - col1 + - cor0.col0 * col1 * col0 FROM tab1 AS cor0
----
-260
-40970
-83213

query I rowsort
SELECT + ( - 27 ) * + col0 + - col0 * col0 * col0 FROM tab2 AS cor0
----
-476658
-495172
-532

query I rowsort
SELECT + ( col1 ) * col2 - col2 * + cor0.col0 * - col1 FROM tab1 AS cor0
----
101088
37050
5616

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * ( - col0 ) col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - + col2 * col0 + + col0 * 43 - col1 FROM tab2 AS cor0
----
1267
378
81

query I rowsort
SELECT - cor0.col1 + - col0 * - col0 * - 10 AS col1 FROM tab1 AS cor0
----
-116
-40970
-64013

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5665
SELECT - CAST( NULL AS SIGNED ) + cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5665
SELECT - CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 * col0 col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5667
SELECT + 94 + 58 * col0 - - CAST( 94 AS SIGNED ) * col2 FROM tab1 AS cor0
----
13758
5344
9164

skipif mysql # not compatible
query I rowsort label-5667
SELECT + 94 + 58 * col0 - - CAST ( 94 AS INTEGER ) * col2 FROM tab1 AS cor0
----
13758
5344
9164

query I rowsort
SELECT + + cor0.col1 + col0 * col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + col2 + col2 * col1 * col0 AS col0 FROM tab0 cor0
----
3396
664200
68145

query I rowsort
SELECT - 9 + col1 AS col0 FROM tab2 AS cor0
----
22
50
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5671
SELECT ALL col1 DIV + col0 col2 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5671
SELECT ALL col1 / + col0 col2 FROM tab2 AS cor0
----
0
0
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5672
SELECT ALL CAST( + col1 * + col1 + 30 AS SIGNED ) AS col0 FROM tab0
----
7426
8311
9439

skipif mysql # not compatible
query I rowsort label-5672
SELECT ALL CAST ( + col1 * + col1 + 30 AS INTEGER ) AS col0 FROM tab0
----
7426
8311
9439

onlyif mysql # use DIV operator for integer division
query I rowsort label-5673
SELECT ALL + col0 * - col2 + 25 * + col2 DIV col2 FROM tab1 AS cor0
----
-137
-3623
-7655

skipif mysql # not compatible
query I rowsort label-5673
SELECT ALL + col0 * - col2 + 25 * + col2 / col2 FROM tab1 AS cor0
----
-137
-3623
-7655

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 - col1 * - col0 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT ALL + col1 + col2 * + 21 FROM tab0 AS cor0
----
118
1813
779

query I rowsort
SELECT ALL col2 + col1 * - col2 * - col2 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT DISTINCT + col2 * col1 * col1 + col0 FROM tab1 AS cor0
----
16304
36507
5764

onlyif mysql # use DIV operator for integer division
query I rowsort label-5679
SELECT ALL - cor0.col2 + + col2 DIV + col0 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-5679
SELECT ALL - cor0.col2 + + col2 / + col0 FROM tab1 AS cor0
----
-36
-57
-95

query I rowsort
SELECT + cor0.col0 + + col2 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT 16 + + col2 * col1 FROM tab2 AS cor0
----
1550
662
853

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5682
SELECT ALL - col2 + - col0 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-5682
SELECT ALL - col2 + - col0 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-5683
SELECT - 69 DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5683
SELECT - 69 / - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT + ( + col0 ) + + col2 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT - + 80 - - col1 FROM tab1 AS cor0
----
-54
-67
-70

query I rowsort
SELECT col0 * col0 * + 88 - + 23 * + col0 FROM tab1 cor0
----
358976
561360
723

query I rowsort
SELECT DISTINCT + col1 + - col0 * + col0 * + col1 FROM tab1 AS cor0
----
-208
-40950
-83187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5688
SELECT DISTINCT ( col0 ) + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5688
SELECT DISTINCT ( col0 ) + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + + col0 * col0 col1 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT + col2 + + col1 * col2 - 76 FROM tab0 AS cor0
----
22
2795
7468

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 92 + col2 col1 FROM tab2
----
118
119
130

query I rowsort
SELECT cor0.col0 * - ( + ( - col0 ) ) AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5693
SELECT ALL 46 DIV + cor0.col1 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5693
SELECT ALL 46 / + cor0.col1 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + + col1 + ( - col2 ) * + col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5695
SELECT + col1 - col0 DIV col0 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-5695
SELECT + col1 - col0 / col0 FROM tab2
----
16
30
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT + col1 * + tab1.col1 * 52 AS col0 FROM tab1
----
35152
5200
8788

query I rowsort
SELECT ALL - col2 * 6 + col0 - - col1 FROM tab2 AS cor0
----
-124
-132
-19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5699
SELECT DISTINCT - CAST( NULL AS SIGNED ) / - col2 + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5699
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / - col2 + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + 71 * col1 + - col0 FROM tab0 AS cor0
----
6082
6372
6852

query I rowsort
SELECT ALL 97 - col0 AS col1 FROM tab2 cor0
----
18
19
90

query I rowsort
SELECT ALL + 11 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 288f8fb62e079d095c14d7cf3e2d3359

query I rowsort
SELECT DISTINCT - 55 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-55

query I rowsort
SELECT DISTINCT - col0 * 52 - col0 FROM tab0
----
-1272
-1855
-4717

query I rowsort
SELECT col0 + col2 * - tab0.col2 AS col1 FROM tab0
----
-1065
-6635
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5706
SELECT CAST( NULL AS DECIMAL ) * col1 - - col0 / col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5706
SELECT CAST ( NULL AS REAL ) * col1 - - col0 / col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col2 ) * - tab2.col2 - + tab2.col2 AS col0 FROM tab2
----
-1482
-702
-756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5708
SELECT DISTINCT CAST( - col1 AS SIGNED ) * col0 + - CAST( NULL AS SIGNED ) * + col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5708
SELECT DISTINCT CAST ( - col1 AS INTEGER ) * col0 + - CAST ( NULL AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 48 + col0 FROM tab2 AS cor0
----
126
127
55

query I rowsort
SELECT ALL 14 * col1 * - col1 AS col2 FROM tab1
----
-1400
-2366
-9464

query I rowsort
SELECT + - ( - col0 ) + col1 * + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - tab1.col1 + col2 * + col0 AS col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + col2 * + col2 * 87 AS col0 FROM tab2
----
125628
58812
63423

query I rowsort
SELECT + ( + 1 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT ALL + + col0 * + ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col1 * col0 + - col0 * - col2 * col1 FROM tab2 AS cor0
----
115050
49691
5642

query I rowsort
SELECT ALL + col1 + 20 + col1 AS col2 FROM tab1 AS cor0
----
40
46
72

query I rowsort
SELECT DISTINCT - col0 * col1 * - col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT col2 * 56 + col0 FROM tab2 AS cor0
----
1519
1534
2207

query I rowsort
SELECT - + col1 * cor0.col2 + col1 FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - cor0.col2 + 38 * col1 FROM tab0 AS cor0
----
3235
3376
3685

query I rowsort
SELECT - col2 * 0 + cor0.col0 AS col2 FROM tab0 cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5724
SELECT ALL - CAST( - 78 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
78
78
78

skipif mysql # not compatible
query I rowsort label-5724
SELECT ALL - CAST ( - 78 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT DISTINCT 75 + 28 FROM tab0 AS cor0
----
103

onlyif mysql # use DIV operator for integer division
query I rowsort label-5726
SELECT + + col1 DIV col1 + + col0 AS col2 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5726
SELECT + + col1 / col1 + + col0 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT col2 + + 54 * col0 AS col0 FROM tab1
----
216
3513
4416

onlyif mysql # use DIV operator for integer division
query I rowsort label-5728
SELECT 93 DIV col1 FROM tab2 AS cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-5728
SELECT 93 / col1 FROM tab2 AS cor0
----
1
3
5

query I rowsort
SELECT DISTINCT + + 58 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
58

query I rowsort
SELECT ALL - col2 + - col0 * 36 FROM tab1 AS cor0
----
-162
-2361
-2976

query I rowsort
SELECT ALL + ( + col0 ) + 81 FROM tab2 AS cor0
----
159
160
88

query I rowsort
SELECT DISTINCT col0 * - 83 FROM tab2
----
-581
-6474
-6557

query I rowsort
SELECT DISTINCT + 30 + col0 * + col0 AS col2 FROM tab2 AS cor0
----
6114
6271
79

query I rowsort
SELECT ALL 62 AS col2 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT DISTINCT - col1 * + col0 * - col2 AS col0 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5736
SELECT DISTINCT col1 DIV - tab0.col0 AS col2 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-5736
SELECT DISTINCT col1 / - tab0.col0 AS col2 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT 26 - col2 AS col0 FROM tab0
----
-56
-7
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5738
SELECT DISTINCT + + col1 * ( + 38 * + col1 + CAST( 27 AS SIGNED ) ) FROM tab2 AS cor0
----
11441
133871
37355

skipif mysql # not compatible
query I rowsort label-5738
SELECT DISTINCT + + col1 * ( + 38 * + col1 + CAST ( 27 AS INTEGER ) ) FROM tab2 AS cor0
----
11441
133871
37355

onlyif mysql # use DIV operator for integer division
query I rowsort label-5739
SELECT col2 DIV + 39 FROM tab1 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-5739
SELECT col2 / + 39 FROM tab1 AS cor0
----
1
1
2

query I rowsort
SELECT ALL 17 * - col0 AS col2 FROM tab1
----
-1088
-1360
-51

query I rowsort
SELECT DISTINCT 59 + + cor0.col1 FROM tab1, tab2, tab1 AS cor0
----
69
72
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 38 ) col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT + ( 42 ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT col1 * + 48 AS col2 FROM tab1 AS cor0
----
1248
480
624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5746
SELECT ALL - CAST( NULL AS SIGNED ) * 94 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5746
SELECT ALL - CAST ( NULL AS INTEGER ) * 94 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + tab1.col2 + col0 + col2 FROM tab1
----
111
178
272

query I rowsort
SELECT col1 * + ( 96 * col2 + 44 * col2 ) AS col1 FROM tab1 AS cor0
----
174720
196560
79800

query I rowsort
SELECT ALL + + col2 * 50 FROM tab2 cor0
----
1300
1350
1900

query I rowsort
SELECT + col0 * 32 FROM tab2 AS cor0
----
224
2496
2528

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5751
SELECT DISTINCT + col2 * - CAST( ( - col0 ) AS SIGNED ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-5751
SELECT DISTINCT + col2 * - CAST ( ( - col0 ) AS INTEGER ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5752
SELECT DISTINCT - col1 * 62 DIV - col0 AS col0 FROM tab0
----
171
222
63

skipif mysql # not compatible
query I rowsort label-5752
SELECT DISTINCT - col1 * 62 / - col0 AS col0 FROM tab0
----
171
222
63

query I rowsort
SELECT 91 + + col2 * - col1 FROM tab0
----
-2747
-6
-7371

query I rowsort
SELECT 4 * + col0 + + col1 AS col1 FROM tab2
----
333
371
59

query I rowsort
SELECT ( + col1 ) * col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - col2 * col2 + - tab2.col1 * - 1 * + 83 FROM tab2
----
-33
1844
4221

query I rowsort
SELECT ( + tab1.col1 ) + + col1 * + 51 * + col0 FROM tab1
----
32650
4004
53053

query I rowsort
SELECT col0 * col2 + col2 + ( col1 ) * + col2 * + tab0.col2 FROM tab0
----
133
619264
94479

query I rowsort
SELECT ( 73 ) + + col1 FROM tab1
----
83
86
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 98 ) col0 FROM tab1
----
98

query I rowsort
SELECT DISTINCT ( 10 ) FROM tab1
----
10

query I rowsort
SELECT DISTINCT + + col0 * col0 - - col1 * col2 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT 75 * - col1 FROM tab0 AS cor0
----
-6450
-6825
-7275

query I rowsort
SELECT ALL + cor0.col0 * col1 FROM tab1 cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * cor0.col1 col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL ( + col0 ) + - col1 * + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - - 15 * col2 FROM tab2 AS cor0
----
390
405
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * - cor0.col2 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5769
SELECT + tab1.col0 * ( col1 ) DIV - tab1.col1 AS col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5769
SELECT + tab1.col0 * ( col1 ) / - tab1.col1 AS col2 FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 61 col1 FROM tab2, tab1 cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col2 + col1 * + col0 * col0 FROM tab2 cor0
----
106135
1546
358982

query I rowsort
SELECT + 40 * cor0.col2 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT DISTINCT - col1 - 30 AS col1 FROM tab1 AS cor0
----
-40
-43
-56

query I rowsort
SELECT ALL - + 16 AS col0 FROM tab0 AS cor0
----
-16
-16
-16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5776
SELECT - CAST( NULL AS SIGNED ) * + 29 * + cor0.col1 + col1 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5776
SELECT - CAST ( NULL AS INTEGER ) * + 29 * + cor0.col1 + col1 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab1, tab1 AS cor1
----
3645 values hashing to ca91d1f523a87017f672304548e91a77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5778
SELECT - - CAST( NULL AS SIGNED ) + cor0.col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5778
SELECT - - CAST ( NULL AS INTEGER ) + cor0.col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5779
SELECT CAST( NULL AS SIGNED ) + + 81 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5779
SELECT CAST ( NULL AS INTEGER ) + + 81 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab1.col2 + 25 FROM tab1, tab2 cor0
----
9 values hashing to b7162c6ab679d43703aa6aaf202a162b

query I rowsort
SELECT - + col0 * - col1 * + col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5782
SELECT - 46 DIV + cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5782
SELECT - 46 / + cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 48 * col2 AS col1 FROM tab0 AS cor0
----
1584
3936
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 * - col1 col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5785
SELECT - col1 + - CAST( NULL AS SIGNED ) + col1 * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5785
SELECT - col1 + - CAST ( NULL AS INTEGER ) + col1 * col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * col1 + - ( col0 ) + col1 AS col0 FROM tab2 AS cor0
----
1515
584
861

query I rowsort
SELECT col0 + col1 * - ( - col0 + - col0 ) AS col2 FROM tab2
----
2765
441
9282

query I rowsort
SELECT DISTINCT ( + 24 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5789
SELECT + col1 * - CAST( - 12 AS SIGNED ) - col0 AS col0 FROM tab2 AS cor0
----
125
365
630

skipif mysql # not compatible
query I rowsort label-5789
SELECT + col1 * - CAST ( - 12 AS INTEGER ) - col0 AS col0 FROM tab2 AS cor0
----
125
365
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-5790
SELECT - + col0 DIV col2 + col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2064
3360
8098

skipif mysql # not compatible
query I rowsort label-5790
SELECT - + col0 / col2 + col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
2064
3360
8098

query I rowsort
SELECT DISTINCT + 40 AS col0 FROM tab1, tab2 cor0, tab2 cor1
----
40

query I rowsort
SELECT ALL - col2 + 21 * + col2 AS col2 FROM tab1 AS cor0
----
1080
1140
1920

query I rowsort
SELECT + col1 * 60 AS col1 FROM tab1 AS cor0
----
1560
600
780

query I rowsort
SELECT ALL + col2 * - 74 + col2 AS col2 FROM tab0 AS cor0
----
-2409
-5986
-73

query I rowsort
SELECT DISTINCT + + col0 + + 40 FROM tab2 AS cor0
----
118
119
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5796
SELECT - col0 + CAST( 78 AS SIGNED ) * + cor0.col2 col2 FROM tab0 AS cor0
----
2550
43
6307

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5796
SELECT - col0 + CAST ( 78 AS INTEGER ) * + cor0.col2 col2 FROM tab0 AS cor0
----
2550
43
6307

query I rowsort
SELECT ALL col0 + - ( col1 ) FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5798
SELECT - - col1 * CAST( - col2 AS SIGNED ) FROM tab1 cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-5798
SELECT - - col1 * CAST ( - col2 AS INTEGER ) FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - col2 + + col2 + - col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5800
SELECT DISTINCT - cor0.col1 * col1 + + col1 DIV col2 FROM tab0 AS cor0
----
-7394
-8280
-9312

skipif mysql # not compatible
query I rowsort label-5800
SELECT DISTINCT - cor0.col1 * col1 + + col1 / col2 FROM tab0 AS cor0
----
-7394
-8280
-9312

query I rowsort
SELECT ALL + 65 + + col2 FROM tab1 AS cor0
----
119
122
161

query I rowsort
SELECT ALL - col1 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5803
SELECT DISTINCT 93 DIV - ( + col1 ) AS col1 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5803
SELECT DISTINCT 93 / - ( + col1 ) AS col1 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT ( - 62 ) + col1 - + 43 FROM tab1 AS cor0
----
-79
-92
-95

query I rowsort
SELECT - + col1 + cor0.col0 - col0 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5806
SELECT DISTINCT - 25 DIV + col0 FROM tab1 AS cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-5806
SELECT DISTINCT - 25 / + col0 FROM tab1 AS cor0
----
-8
0

query I rowsort
SELECT - + cor0.col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - tab2.col1 FROM tab0, tab2 cor0 CROSS JOIN tab2
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ( + 30 ) AS col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT ( col2 * + col0 ) AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT - 54 + - col1 FROM tab0
----
-140
-145
-151

query I rowsort
SELECT DISTINCT - tab2.col2 * + col2 AS col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT + 73 * + col0 - col1 FROM tab0
----
1666
2458
6406

onlyif mysql # use DIV operator for integer division
query I rowsort label-5814
SELECT col1 DIV col1 + col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5814
SELECT col1 / col1 + col0 FROM tab1
----
4
65
81

query I rowsort
SELECT DISTINCT 6 * col0 FROM tab0
----
144
210
534

query I rowsort
SELECT ALL - col0 * - col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - + 98 * ( cor0.col1 ) FROM tab2 AS cor0
----
-1666
-3038
-5782

query I rowsort
SELECT ALL + 16 AS col2 FROM tab2 cor0
----
16
16
16

query I rowsort
SELECT + col1 + col2 + + col0 AS col2 FROM tab2 AS cor0
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) col0 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col0 col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + col2 * col2 + - ( + 96 ) * + col1 FROM tab1 AS cor0
----
2289
420
7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-5823
SELECT - col0 DIV + ( - col1 ) + col0 * 23 FROM tab1 AS cor0
----
1478
1846
69

skipif mysql # not compatible
query I rowsort label-5823
SELECT - col0 / + ( - col1 ) + col0 * 23 FROM tab1 AS cor0
----
1478
1846
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-5824
SELECT tab2.col1 DIV 89 - col1 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5824
SELECT tab2.col1 / 89 - col1 FROM tab2
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5825
SELECT + col0 DIV + col0 + + 22 FROM tab2
----
23
23
23

skipif mysql # not compatible
query I rowsort label-5825
SELECT + col0 / + col0 + + 22 FROM tab2
----
23
23
23

query I rowsort
SELECT + col2 + - col1 * - 64 AS col0 FROM tab1
----
1718
697
928

query I rowsort
SELECT ALL 3 * cor0.col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9df9b70f0ce9b74a1172dc2d08f634c0

query I rowsort
SELECT DISTINCT - col1 * + col1 + - 27 * + col0 + + 66 FROM tab1 AS cor0
----
-1762
-2263
-691

query I rowsort
SELECT DISTINCT - - cor0.col0 * - 15 FROM tab1 AS cor0
----
-1200
-45
-960

query I rowsort
SELECT ALL + + 73 * col1 * - col0 FROM tab2 cor0
----
-15841
-335946
-98039

query I rowsort
SELECT ALL + + 34 * 93 FROM tab0 AS cor0
----
3162
3162
3162

query I rowsort
SELECT ALL - ( - col2 ) AS col0 FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5833
SELECT DISTINCT + - 61 + cor0.col0 DIV col1 FROM tab2 AS cor0
----
-57
-60
-61

skipif mysql # not compatible
query I rowsort label-5833
SELECT DISTINCT + - 61 + cor0.col0 / col1 FROM tab2 AS cor0
----
-57
-60
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5834
SELECT DISTINCT - CAST( - col0 AS SIGNED ) * col0 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-5834
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) * col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - 78 * 89 FROM tab2 AS cor0
----
-6942
-6942
-6942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 74 * + col0 col0 FROM tab1 AS cor0
----
222
4736
5920

query I rowsort
SELECT ALL col1 * 34 + + col1 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT + col2 * ( cor0.col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT col2 * tab0.col1 * - 33 FROM tab0
----
-246246
-3201
-93654

onlyif mysql # use DIV operator for integer division
query I rowsort label-5840
SELECT - col2 + - col2 DIV col0 FROM tab1
----
-57
-72
-97

skipif mysql # not compatible
query I rowsort label-5840
SELECT - col2 + - col2 / col0 FROM tab1
----
-57
-72
-97

query I rowsort
SELECT - - 82 * 36 FROM tab1 AS cor0
----
2952
2952
2952

query I rowsort
SELECT ALL + ( col0 ) + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5843
SELECT ALL col2 DIV - 59 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5843
SELECT ALL col2 / - 59 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - + col1 * col0 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - cor0.col2 + - col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT 88 * - cor0.col1 FROM tab1 cor0
----
-1144
-2288
-880

query I rowsort
SELECT - - ( col2 ) * 36 * cor0.col2 FROM tab2 AS cor0
----
24336
26244
51984

query I rowsort
SELECT + 27 * - col2 AS col1 FROM tab1 AS cor0
----
-1458
-1539
-2592

query I rowsort
SELECT + cor0.col0 * - col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - ( - 91 * tab2.col0 ) AS col1 FROM tab2
----
637
7098
7189

query I rowsort
SELECT DISTINCT + 9 FROM tab1, tab2 cor0
----
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5852
SELECT ALL - tab1.col0 DIV - 65 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5852
SELECT ALL - tab1.col0 / - 65 FROM tab1
----
0
0
1

query I rowsort
SELECT DISTINCT 67 * 72 FROM tab1
----
4824

query I rowsort
SELECT + - 66 * + tab1.col1 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to d199a2fe48d3d3201fdb7b9a8aa98454

query I rowsort
SELECT + col0 + - ( + col1 ) AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + col0 + 40 FROM tab2 AS cor0
----
118
119
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 col2 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT + col2 * - col2 + 45 FROM tab2
----
-1399
-631
-684

query I rowsort
SELECT DISTINCT ( col1 ) + + ( + col1 ) FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5860
SELECT ALL cor0.col2 * + 32 + - col0 DIV - col1 FROM tab0 AS cor0
----
1056
2624
32

skipif mysql # not compatible
query I rowsort label-5860
SELECT ALL cor0.col2 * + 32 + - col0 / - col1 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT ALL col0 * - ( - 71 ) AS col1 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT ALL cor0.col0 + - 95 FROM tab1 AS cor0
----
-15
-31
-92

query I rowsort
SELECT DISTINCT - col1 * + ( + col2 ) + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT cor0.col1 - col2 * col0 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + - col2 * + col0 + cor0.col1 * col1 * cor0.col2 + col0 FROM tab0 AS cor0
----
243300
671833
9409

query I rowsort
SELECT DISTINCT - col1 * - col1 * cor0.col0 - col2 * + ( col0 ) * col1 FROM tab0 AS cor0
----
109392
325920
72891

query I rowsort
SELECT col1 * + ( col1 ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + + col1 * + ( col1 ) + col2 AS col0 FROM tab1 AS cor0
----
157
265
730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL + col2 + ( col2 ) + col2 AS col0 FROM tab1 AS cor0
----
162
171
288

onlyif mysql # use DIV operator for integer division
query I rowsort label-5871
SELECT DISTINCT col0 * col2 DIV - col0 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5871
SELECT DISTINCT col0 * col2 / - col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - col2 * col1 * col1 + + col0 AS col2 FROM tab2 AS cor0
----
-10903
-25940
-90428

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col2 col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL col0 * col2 + col1 - - col1 AS col1 FROM tab2 AS cor0
----
2146
251
3036

onlyif mysql # use DIV operator for integer division
query I rowsort label-5875
SELECT + col0 DIV col0 + col2 * col0 * - tab0.col0 FROM tab0
----
-1224
-19007
-649521

skipif mysql # not compatible
query I rowsort label-5875
SELECT + col0 / col0 + col2 * col0 * - tab0.col0 FROM tab0
----
-1224
-19007
-649521

onlyif mysql # use DIV operator for integer division
query I rowsort label-5876
SELECT + tab2.col2 DIV col0 + + col2 AS col2 FROM tab2
----
26
30
38

skipif mysql # not compatible
query I rowsort label-5876
SELECT + tab2.col2 / col0 + + col2 AS col2 FROM tab2
----
26
30
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5877
SELECT DISTINCT col2 * col1 DIV - tab0.col0 FROM tab0
----
-118
-2
-83

skipif mysql # not compatible
query I rowsort label-5877
SELECT DISTINCT col2 * col1 / - tab0.col0 FROM tab0
----
-118
-2
-83

query I rowsort
SELECT + col0 * + col1 * col2 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5879
SELECT col2 * - col1 DIV col1 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5879
SELECT col2 * - col1 / col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - col1 * col1 + col2 + - col2 * - col1 AS col1 FROM tab0
----
-4525
-737
-9311

onlyif mysql # use DIV operator for integer division
query I rowsort label-5881
SELECT - col0 * col1 DIV col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5881
SELECT - col0 * col1 / col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT col1 * + tab2.col1 - col1 AS col2 FROM tab2
----
272
3422
930

query I rowsort
SELECT DISTINCT - tab2.col0 * col0 + + col2 * - col1 FROM tab2
----
-6887
-7618
-886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col0 + - col1 * col1 col1 FROM tab0
----
-7458
-8283
-9471

query I rowsort
SELECT DISTINCT col1 + + col1 + - col1 * col0 FROM tab0
----
-1892
-3201
-7917

query I rowsort
SELECT ALL - cor0.col1 + - col0 AS col2 FROM tab1 cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5887
SELECT DISTINCT - col1 * col1 * - col2 - + col2 DIV + col2 FROM tab1 AS cor0
----
16223
36503
5699

skipif mysql # not compatible
query I rowsort label-5887
SELECT DISTINCT - col1 * col1 * - col2 - + col2 / + col2 FROM tab1 AS cor0
----
16223
36503
5699

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + - col2 * cor0.col0 col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + col0 + col2 * cor0.col0 * col0 FROM tab0 AS cor0
----
1260
19032
649611

query I rowsort
SELECT DISTINCT + tab1.col0 AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
3
64
80

query III rowsort
SELECT * FROM tab2 WHERE NOT + col0 NOT BETWEEN NULL AND + col2 + - col0
----

query I rowsort
SELECT - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 24 * + col0 col0 FROM tab1
----
-1536
-1920
-72

query I rowsort
SELECT ALL + col0 - 66 FROM tab0 AS cor0
----
-31
-42
23

query I rowsort
SELECT - tab0.col0 + + col1 * + ( 75 ) FROM tab0
----
6426
6736
7240

query I rowsort
SELECT ALL + col1 + + 52 FROM tab1 AS cor0
----
62
65
78

query I rowsort
SELECT DISTINCT + cor0.col2 - 14 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1248
-702
-741

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5898
SELECT DISTINCT - col2 * 34 + - cor0.col2 * - col2 - - CAST( + ( col2 ) AS SIGNED ) FROM tab0 AS cor0
----
-32
0
4018

skipif mysql # not compatible
query I rowsort label-5898
SELECT DISTINCT - col2 * 34 + - cor0.col2 * - col2 - - CAST ( + ( col2 ) AS INTEGER ) FROM tab0 AS cor0
----
-32
0
4018

query I rowsort
SELECT 84 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col0 + - col2 * + col2 FROM tab1 AS cor0
----
-2967
-3242
-9232

query I rowsort
SELECT ALL - + col2 + - col0 * col1 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT - + col0 + col2 * cor0.col0 + col0 * 92 FROM tab2 AS cor0
----
10191
826
9126

query I rowsort
SELECT DISTINCT - col1 + + 2 AS col2 FROM tab1 AS cor0
----
-11
-24
-8

query I rowsort
SELECT cor0.col0 * ( col2 ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + + col1 + - col2 * - col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + col2 + ( ( col1 ) ) AS col2 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5907
SELECT + col0 DIV col1 - col0 * + col1 FROM tab2
----
-1339
-217
-4601

skipif mysql # not compatible
query I rowsort label-5907
SELECT + col0 / col1 - col0 * + col1 FROM tab2
----
-1339
-217
-4601

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN ( col0 - - col2 ) AND - col1 * col2 + col2
----

query I rowsort
SELECT ALL + col1 * + tab0.col1 * col1 AS col1 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT DISTINCT - col2 * - col2 * + col2 AS col0 FROM tab0
----
1
35937
551368

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE - col1 * + col0 NOT IN ( - col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT col0 + - col0 * col1 * col2 FROM tab0
----
-3360
-664029
-68088

query I rowsort
SELECT tab1.col2 + col0 * + col2 * col0 FROM tab1
----
233529
540
614496

onlyif mysql # use DIV operator for integer division
query I rowsort label-5914
SELECT + col2 * - col2 - + col1 DIV col0 FROM tab1
----
-2924
-3249
-9216

skipif mysql # not compatible
query I rowsort label-5914
SELECT + col2 * - col2 - + col1 / col0 FROM tab1
----
-2924
-3249
-9216

query I rowsort
SELECT DISTINCT + tab1.col2 * + col0 AS col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5916
SELECT ALL col2 DIV + col1 + col0 AS col2 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-5916
SELECT ALL col2 / + col1 + col0 AS col2 FROM tab1
----
5
69
87

query I rowsort
SELECT col1 * col1 + - col2 * col1 AS col0 FROM tab0
----
4558
819
9312

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL BETWEEN ( + col0 - - col0 ) AND NULL
----

query I rowsort
SELECT ALL - col2 * - col2 * tab1.col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT ALL 33 + - col2 * + col2 FROM tab2 AS cor0
----
-1411
-643
-696

query I rowsort
SELECT 63 AS col2 FROM tab0 cor0
----
63
63
63

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) >= ( NULL )
----

query I rowsort
SELECT ALL - 61 * - col1 AS col1 FROM tab0 cor0
----
5246
5551
5917

onlyif mysql # use DIV operator for integer division
query I rowsort label-5924
SELECT + - 13 DIV col2 FROM tab0 AS cor0
----
-13
0
0

skipif mysql # not compatible
query I rowsort label-5924
SELECT + - 13 / col2 FROM tab0 AS cor0
----
-13
0
0

query I rowsort
SELECT DISTINCT - col0 AS col0 FROM tab0 WHERE ( - col2 ) IN ( col0 * col1 )
----

query I rowsort
SELECT - tab2.col2 + + tab2.col2 * + col1 AS col0 FROM tab2
----
1508
608
810

query I rowsort
SELECT - col1 * + col2 + - tab2.col2 AS col1 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT - + col1 * col1 * col1 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT + col0 * 28 AS col0 FROM tab1 AS cor0
----
1792
2240
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5930
SELECT DISTINCT + col2 * CAST( - col0 AS SIGNED ) + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

skipif mysql # not compatible
query I rowsort label-5930
SELECT DISTINCT + col2 * CAST ( - col0 AS INTEGER ) + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-5931
SELECT ALL col1 DIV 95 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5931
SELECT ALL col1 / 95 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col2 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5933
SELECT + col1 * 28 + + ( col0 ) DIV col0 AS col1 FROM tab2 AS cor0
----
1653
477
869

skipif mysql # not compatible
query I rowsort label-5933
SELECT + col1 * 28 + + ( col0 ) / col0 AS col1 FROM tab2 AS cor0
----
1653
477
869

query I rowsort
SELECT DISTINCT - col2 + + col2 * - 82 FROM tab2
----
-2158
-2241
-3154

query I rowsort
SELECT ALL - 19 + + col1 AS col0 FROM tab1
----
-6
-9
7

query I rowsort
SELECT - + 0 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5937
SELECT - col0 * - CAST( + col2 AS SIGNED ) FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-5937
SELECT - col0 * - CAST ( + col2 AS INTEGER ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - cor0.col1 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL + + col1 * col2 * + cor0.col1 FROM tab2 AS cor0
----
10982
25947
90506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5940
SELECT DISTINCT cor0.col0 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5940
SELECT DISTINCT cor0.col0 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 27 col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

query I rowsort
SELECT + - 35 FROM tab1, tab2 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT DISTINCT + 44 + - col0 + + col2 * - 74 AS col0 FROM tab0 AS cor0
----
-2422
-6113
-65

query I rowsort
SELECT DISTINCT ( col0 ) + - col2 * col0 FROM tab2
----
-182
-1950
-2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5945
SELECT col0 + - tab2.col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5945
SELECT col0 + - tab2.col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 85 * col2 + - 81 FROM tab0 AS cor0
----
2724
4
6889

query I rowsort
SELECT DISTINCT + + ( - col1 ) + col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT col1 * tab0.col1 * col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT ALL 57 + + col0 + - 2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-23
-7
54

query I rowsort
SELECT - - cor0.col2 * + col0 + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL col1 + - col2 * col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT - 87 * col0 + - cor0.col2 - + 31 FROM tab1 AS cor0
----
-346
-5656
-7087

onlyif mysql # use DIV operator for integer division
query I rowsort label-5953
SELECT - - col1 + - col2 DIV + 39 col2 FROM tab0 AS cor0
----
86
89
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5953
SELECT - - col1 + - col2 / + 39 col2 FROM tab0 AS cor0
----
86
89
97

query I rowsort
SELECT 70 * + cor0.col1 + + col1 FROM tab1 AS cor0
----
1846
710
923

query I rowsort
SELECT ALL col0 * - cor0.col2 + + col1 - col0 FROM tab0 AS cor0
----
-7296
-730
27

query I rowsort
SELECT ALL + 71 * - col0 * col1 AS col1 FROM tab0
----
-146544
-241045
-575029

query I rowsort
SELECT - col2 + col1 * col1 * col1 AS col0 FROM tab2 AS cor0
----
205353
29764
4875

query I rowsort
SELECT tab1.col2 * col1 + + col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL + - col2 * - ( + col2 ) AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - 49 * + ( cor0.col0 ) FROM tab0 cor0
----
-1176
-1715
-4361

query I rowsort
SELECT DISTINCT 34 + + col2 AS col1 FROM tab0 AS cor0
----
116
35
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-5962
SELECT + 36 * col0 DIV + col1 FROM tab2 cor0
----
167
47
8

skipif mysql # not compatible
query I rowsort label-5962
SELECT + 36 * col0 / + col1 FROM tab2 cor0
----
167
47
8

query I rowsort
SELECT ( 28 ) * + col0 * tab0.col2 AS col2 FROM tab0
----
204344
22176
980

query I rowsort
SELECT DISTINCT - 44 * col0 * col1 FROM tab2
----
-202488
-59092
-9548

query I rowsort
SELECT + - 13 * + col1 * + col0 AS col0 FROM tab0 AS cor0
----
-105287
-26832
-44135

query I rowsort
SELECT cor0.col0 + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 10977325261681ddca962e0a5d2b348b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5967
SELECT + CAST( NULL AS SIGNED ) + col0 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5967
SELECT + CAST ( NULL AS INTEGER ) + col0 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0 WHERE NOT ( NULL ) >= NULL
----

query I rowsort
SELECT + + ( - 9 ) AS col2 FROM tab2 cor0
----
-9
-9
-9

query I rowsort
SELECT 40 + col1 AS col1 FROM tab2 AS cor0
----
57
71
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col2 + + tab2.col1 * - col0 + col2 col2 FROM tab2
----
-3042
-659
647

query I rowsort
SELECT + - col2 + - cor0.col2 * col0 - col0 AS col2 FROM tab0 AS cor0
----
-71
-7469
-849

query I rowsort
SELECT - - col2 + + col2 - + col0 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT + col0 * col1 * col0 + col1 AS col2 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT col2 + col0 - col0 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + ( + col0 ) + - col1 FROM tab0
----
-2
-62

query I rowsort
SELECT - 16 FROM tab2
----
-16
-16
-16

query I rowsort
SELECT ALL - 11 * - tab0.col1 + + col0 FROM tab0
----
1090
1102
970

query I rowsort
SELECT DISTINCT col0 + col2 + col0 * col0 AS col1 FROM tab1
----
4217
6576
66

query I rowsort
SELECT ALL col2 + + col0 * - col0 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT + 26 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5982
SELECT - ( - col1 ) + tab0.col1 * CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5982
SELECT - ( - col1 ) + tab0.col1 * CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5983
SELECT 91 * col0 DIV cor0.col2 FROM tab1 AS cor0
----
102
5
75

skipif mysql # not compatible
query I rowsort label-5983
SELECT 91 * col0 / cor0.col2 FROM tab1 AS cor0
----
102
5
75

query I rowsort
SELECT DISTINCT + 99 * col2 AS col0 FROM tab2
----
2574
2673
3762

query I rowsort
SELECT ALL + - cor0.col1 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * + ( col1 ) + - 76 col0 FROM tab0
----
21
2762
7386

query I rowsort
SELECT ALL ( ( col2 ) ) AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - col1 + col1 * + 19 FROM tab2 AS cor0
----
1062
306
558

onlyif mysql # use DIV operator for integer division
query I rowsort label-5989
SELECT DISTINCT + 44 + col2 DIV + col0 FROM tab0 AS cor0
----
44
45

skipif mysql # not compatible
query I rowsort label-5989
SELECT DISTINCT + 44 + col2 / + col0 FROM tab0 AS cor0
----
44
45

query I rowsort
SELECT ALL - - 28 * col2 FROM tab0 AS cor0
----
2296
28
924

onlyif mysql # use DIV operator for integer division
query I rowsort label-5991
SELECT - + ( cor0.col0 ) DIV ( col0 ) FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5991
SELECT - + ( cor0.col0 ) / ( col0 ) FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT 14 AS col1 FROM tab2 AS cor0
----
14

query I rowsort
SELECT col2 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + 66 * tab2.col2 FROM tab2
----
1716
1782
2508

query I rowsort
SELECT DISTINCT - 15 * + col2 FROM tab0
----
-1230
-15
-495

query I rowsort
SELECT ALL - 89 * col1 + - col1 FROM tab0 AS cor0
----
-7740
-8190
-8730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 48 col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT col2 * - ( 61 ) + col1 FROM tab2 cor0
----
-1527
-1616
-2301

query I rowsort
SELECT ALL + col0 + - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col1 * - 37 * col1 FROM tab2 cor0
----
10693
128797
35557

query I rowsort
SELECT - ( cor0.col0 ) + + col2 * + 29 AS col0 FROM tab1 cor0
----
1563
1589
2704

query I rowsort
SELECT ALL - col1 + col2 + tab1.col0 AS col1 FROM tab1
----
111
163
31

query I rowsort
SELECT - col0 * + 98 + + col2 + - col1 AS col1 FROM tab1 AS cor0
----
-266
-6225
-7757

query I rowsort
SELECT col1 * ( col0 ) * - col0 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT ALL ( col2 ) * - cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col2 * cor0.col0 + col1 * - col2 - col2 AS col1 FROM tab2 AS cor0
----
-1053
-3588
-3686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 - 50 col2 FROM tab1 AS cor0
----
-114
-130
-53

query I rowsort
SELECT + - ( - col2 ) + + col0 FROM tab0 cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6009
SELECT DISTINCT + CAST( - 58 AS SIGNED ) AS col0 FROM tab1 cor0
----
-58

skipif mysql # not compatible
query I rowsort label-6009
SELECT DISTINCT + CAST ( - 58 AS INTEGER ) AS col0 FROM tab1 cor0
----
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6010
SELECT ALL 98 + + col0 DIV - col2 col0 FROM tab1 AS cor0
----
97
98
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6010
SELECT ALL 98 + + col0 / - col2 col0 FROM tab1 AS cor0
----
97
98
98

query I rowsort
SELECT DISTINCT - ( + 11 ) + col1 + col0 * col0 * col0 FROM tab1 AS cor0
----
262143
42
512002

query I rowsort
SELECT ALL + 84 * col2 AS col1 FROM tab1 AS cor0
----
4536
4788
8064

query I rowsort
SELECT DISTINCT + + col0 - - col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - ( - cor0.col1 ) * - col2 * + col1 + - col2 FROM tab1 cor0
----
-16320
-36558
-5757

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( ( col0 ) ) col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - - col0 + ( - col2 ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - 30 * col0 + col1 FROM tab0 cor0
----
-2579
-634
-953

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6018
SELECT DISTINCT col1 + col1 * + col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6018
SELECT DISTINCT col1 + col1 * + col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 + - ( ( col2 ) ) * + col2 * 62 AS col1 FROM tab2
----
-41971
-45229
-89545

query I rowsort
SELECT ALL col2 + 6 FROM tab0
----
39
7
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col2 * col2 * - col1 col2 FROM tab1
----
119712
32433
75762

query I rowsort
SELECT - 92 + col2 AS col1 FROM tab1 AS cor0
----
-35
-38
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6023
SELECT DISTINCT - ( cor0.col1 ) DIV col0 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6023
SELECT DISTINCT - ( cor0.col1 ) / col0 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT - + 57 + col1 FROM tab1 AS cor0
----
-31
-44
-47

query I rowsort
SELECT ALL - 78 + col0 FROM tab1 AS cor0
----
-14
-75
2

query I rowsort
SELECT ALL - 80 + - 22 FROM tab2 AS cor0
----
-102
-102
-102

query I rowsort
SELECT DISTINCT - + 15 * col2 * col0 FROM tab0 AS cor0
----
-109470
-11880
-525

query I rowsort
SELECT ALL + col2 + 84 FROM tab0 AS cor0
----
117
166
85

query I rowsort
SELECT DISTINCT + - cor0.col2 + - col0 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL 30 + - 38 * col2 + col0 AS col0 FROM tab2 AS cor0
----
-1335
-880
-989

query I rowsort
SELECT + - 87 * + col2 AS col2 FROM tab0 AS cor0
----
-2871
-7134
-87

query I rowsort
SELECT ALL col0 * col2 - - col2 * col1 AS col1 FROM tab1
----
1566
4218
8928

query I rowsort
SELECT ALL - col0 * ( col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col0 col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 + + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - col2 - + 94 FROM tab1 AS cor0
----
-148
-151
-190

query I rowsort
SELECT DISTINCT col2 + ( col1 ) * col2 AS col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + - col2 * + ( + ( - col0 ) ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + col0 * ( - ( - col1 ) ) - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL cor0.col1 + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - col2 * col2 - - col1 AS col1 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT + cor0.col2 * - 32 FROM tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT ALL - col2 + cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + col2 + 95 AS col2 FROM tab0 AS cor0
----
128
177
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6045
SELECT ALL + col0 * + ( + ( + col0 ) ) + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6045
SELECT ALL + col0 * + ( + ( + col0 ) ) + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

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 + ( - col2 ) * - ( - 78 ) FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT ALL + + col2 + col2 * + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT + col0 * - col2 + - col1 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT cor1.col1 * + cor0.col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
9 values hashing to e5422173e1caaeeb02bbae09b3f4e2fd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6051
SELECT col2 * + col1 * CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

skipif mysql # not compatible
query I rowsort label-6051
SELECT col2 * + col1 * CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - - col0 * + col0 + - ( - col2 + - col0 ) AS col1 FROM tab2 AS cor0
----
6188
6358
83

query I rowsort
SELECT + cor0.col2 * - cor0.col2 - - col0 AS col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT + 35 + col0 * ( + col2 ) FROM tab2 AS cor0
----
2063
224
3037

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6055
SELECT ALL + CAST( NULL AS SIGNED ) + + 50 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6055
SELECT ALL + CAST ( NULL AS INTEGER ) + + 50 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 35 * + tab2.col2 - - col2 * ( col1 ) FROM tab2
----
1782
1976
2444

query I rowsort
SELECT + + 82 + + col0 AS col1 FROM tab1 AS cor0
----
146
162
85

query I rowsort
SELECT DISTINCT + 15 * + col1 * col2 + + col1 + - col1 AS col1 FROM tab2 AS cor0
----
12555
23010
9690

query I rowsort
SELECT DISTINCT + col0 * cor0.col2 + 66 FROM tab2 AS cor0
----
2094
255
3068

query I rowsort
SELECT - ( + col0 ) + ( + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + 34 + + col2 AS col0 FROM tab0 AS cor0
----
116
35
67

query I rowsort
SELECT + 29 + col2 * 19 AS col0 FROM tab2 cor0
----
523
542
751

query I rowsort
SELECT ALL cor0.col0 * col1 * + cor0.col1 AS col1 FROM tab1 cor0
----
13520
2028
6400

query I rowsort
SELECT + - 10 + col1 * ( col0 + cor0.col1 ) AS col1 FROM tab2 AS cor0
----
1168
1622
8073

query I rowsort
SELECT + col2 + - cor0.col2 * - 13 * col1 FROM tab0 AS cor0
----
1262
36927
97088

query I rowsort
SELECT ALL + cor1.col0 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT 28 * + col1 AS col0 FROM tab1
----
280
364
728

query I rowsort
SELECT ALL col0 * - tab1.col2 * - col2 AS col1 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT - col0 - ( + col2 ) FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + ( 18 ) - - col0 FROM tab1 AS cor0
----
21
82
98

query I rowsort
SELECT ALL 80 + - col2 * cor0.col1 FROM tab2 AS cor0
----
-1454
-566
-757

query I rowsort
SELECT - + ( - 82 ) * col2 - + col1 FROM tab2 AS cor0
----
2073
2183
3099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * - cor0.col1 + col1 col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + ( col1 ) + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - - 36 + col2 FROM tab0 cor0
----
118
37
69

query I rowsort
SELECT ALL - 88 + 13 AS col2 FROM tab2 AS cor0
----
-75
-75
-75

query I rowsort
SELECT cor1.col2 * - 75 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d22eef88c4274259be3cbd8bf5490d8c

query I rowsort
SELECT ALL 48 * - col0 + cor0.col2 * - ( col2 ) AS col0 FROM tab1 AS cor0
----
-13056
-3060
-6321

query I rowsort
SELECT ALL - - 52 * - cor1.col2 + 92 * - 64 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 278d2935e239c05e8cc30b402e220163

query I rowsort
SELECT DISTINCT col1 * col1 + + col2 * - col2 FROM tab0
----
1557
6307
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 69 + + col0 col1 FROM tab0
----
104
158
93

query I rowsort
SELECT ( col0 * + col0 ) FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6083
SELECT ALL col1 DIV col0 + - col0 AS col1 FROM tab1
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-6083
SELECT ALL col1 / col0 + - col0 AS col1 FROM tab1
----
-64
-80
5

query I rowsort
SELECT col0 - 80 FROM tab0 AS cor0
----
-45
-56
9

query I rowsort
SELECT DISTINCT + 79 + col2 AS col2 FROM tab1 AS cor0
----
133
136
175

query I rowsort
SELECT - col0 - - col1 * + col1 FROM tab0 cor0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT - - col0 + + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT 46 + col2 AS col0 FROM tab2
----
72
73
84

query I rowsort
SELECT ( col0 ) + - col0 + + ( - ( - col0 ) ) FROM tab2
----
7
78
79

query I rowsort
SELECT ALL + col0 + - col2 AS col1 FROM tab2
----
-20
41
52

query I rowsort
SELECT 74 * - tab2.col2 FROM tab2
----
-1924
-1998
-2812

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0 CROSS JOIN tab1, tab0 cor1
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL 45 FROM tab1, tab0 cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ALL + 82 AS col1 FROM tab0
----
82
82
82

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to 01eead0dd25d3467de7ffefe027bc35f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6096
SELECT DISTINCT CAST( NULL AS SIGNED ) + + 94 AS col2 FROM tab2, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6096
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + 94 AS col2 FROM tab2, tab2 cor0
----
NULL

query I rowsort
SELECT col0 - - col0 AS col2 FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * + col2 - + ( cor0.col0 ) col1 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT - col0 + col0 * + ( cor0.col1 ) * - col0 AS col1 FROM tab0 AS cor0
----
-118860
-49560
-720900

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 51 + ( - tab0.col1 ) col1 FROM tab0, tab1 AS cor0
----
-35
-40
-46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6101
SELECT DISTINCT + col1 + CAST( + 62 AS SIGNED ) FROM tab0 AS cor0
----
148
153
159

skipif mysql # not compatible
query I rowsort label-6101
SELECT DISTINCT + col1 + CAST ( + 62 AS INTEGER ) FROM tab0 AS cor0
----
148
153
159

query I rowsort
SELECT - ( + 88 ) * cor0.col2 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 94da3a66e1ae99e21bf45b5e82ec6036

query I rowsort
SELECT ALL - 65 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

query I rowsort
SELECT + col0 * 9 * - col1 AS col1 FROM tab2 AS cor0
----
-12087
-1953
-41418

query I rowsort
SELECT + + 22 * col1 AS col1 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT + 92 * col1 FROM tab0 AS cor0
----
7912
8372
8924

onlyif mysql # use DIV operator for integer division
query I rowsort label-6107
SELECT DISTINCT ( 20 ) DIV + col1 + + cor0.col2 * + col2 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-6107
SELECT DISTINCT ( 20 ) / + col1 + + cor0.col2 * + col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6108
SELECT ALL + CAST( - cor0.col0 AS SIGNED ) - + cor0.col1 AS col0 FROM tab1 cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-6108
SELECT ALL + CAST ( - cor0.col0 AS INTEGER ) - + cor0.col1 AS col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT 26 * + ( + col1 ) FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT - + 26 * - col0 FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT + 48 + cor0.col1 FROM tab2 AS cor0
----
107
65
79

query I rowsort
SELECT + 98 * - col1 FROM tab0 cor0
----
-8428
-8918
-9506

query I rowsort
SELECT DISTINCT + col0 * tab2.col0 + 16 FROM tab2
----
6100
6257
65

query I rowsort
SELECT ALL col1 * + col1 * tab2.col1 + col2 * col0 AS col0 FROM tab2
----
207407
29980
7915

query I rowsort
SELECT - col1 * - col1 * - col1 AS col0 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT col0 + - col2 * 73 * + col2 AS col2 FROM tab2
----
-105333
-49270
-53210

query I rowsort
SELECT DISTINCT - col2 * 40 AS col2 FROM tab1 AS cor0
----
-2160
-2280
-3840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6118
SELECT DISTINCT + cor0.col2 + + cor0.col0 + 57 * - col2 DIV col2 FROM tab0 cor0
----
-21
0
114

skipif mysql # not compatible
query I rowsort label-6118
SELECT DISTINCT + cor0.col2 + + cor0.col0 + 57 * - col2 / col2 FROM tab0 cor0
----
-21
0
114

query I rowsort
SELECT DISTINCT col1 * 71 * cor0.col1 FROM tab1 AS cor0
----
11999
47996
7100

onlyif mysql # use DIV operator for integer division
query I rowsort label-6120
SELECT DISTINCT - col2 * 16 DIV - col0 col2 FROM tab2 AS cor0
----
5
61
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6120
SELECT DISTINCT - col2 * 16 / - col0 col2 FROM tab2 AS cor0
----
5
61
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - 3 col1 FROM tab1 AS cor0
----
-57
-60
-99

query I rowsort
SELECT ALL + col1 * - col1 - col0 * col1 FROM tab1
----
-1209
-740
-754

query I rowsort
SELECT + 27 + col0 * + col2 AS col0 FROM tab2
----
2055
216
3029

query I rowsort
SELECT 87 + - col1 * + tab0.col2 FROM tab0
----
-10
-2751
-7375

query I rowsort
SELECT + 18 - col1 FROM tab0 AS cor0
----
-68
-73
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * + col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - cor1.col2 AS col2 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL - + ( col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - 47 * col0 FROM tab2 AS cor0
----
-329
-3666
-3713

query I rowsort
SELECT ALL - 47 * + col0 FROM tab2 AS cor0
----
-329
-3666
-3713

query I rowsort
SELECT - 63 + col2 AS col0 FROM tab1 AS cor0
----
-6
-9
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-6132
SELECT + + 93 * col2 * col0 + - col1 DIV cor0.col0 FROM tab1 AS cor0
----
15058
339264
714240

skipif mysql # not compatible
query I rowsort label-6132
SELECT + + 93 * col2 * col0 + - col1 / cor0.col0 FROM tab1 AS cor0
----
15058
339264
714240

query I rowsort
SELECT - - col1 * cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + 82 + - col2 * - col2 FROM tab0 AS cor0
----
1171
6806
83

query I rowsort
SELECT DISTINCT 79 AS col0 FROM tab2
----
79

query I rowsort
SELECT ALL + 83 * - col1 * - 48 FROM tab1 AS cor0
----
103584
39840
51792

query I rowsort
SELECT DISTINCT + 13 * + col2 AS col2 FROM tab2 AS cor0
----
338
351
494

query I rowsort
SELECT - + col1 * - col0 * ( - cor0.col2 * col2 ) + 6 FROM tab1 AS cor0
----
-2079354
-227442
-9584634

query I rowsort
SELECT - col0 + - col0 + cor0.col1 FROM tab0 AS cor0
----
-87
27
38

query I rowsort
SELECT DISTINCT - 10 * - col0 FROM tab0 cor0
----
240
350
890

onlyif mysql # use DIV operator for integer division
query I rowsort label-6141
SELECT ALL col2 + col2 * + ( col1 ) DIV col1 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6141
SELECT ALL col2 + col2 * + ( col1 ) / col1 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6142
SELECT ALL - - 7 * + col0 + cor0.col1 DIV - cor0.col0 FROM tab1 AS cor0
----
13
448
560

skipif mysql # not compatible
query I rowsort label-6142
SELECT ALL - - 7 * + col0 + cor0.col1 / - cor0.col0 FROM tab1 AS cor0
----
13
448
560

query I rowsort
SELECT ALL + - col2 * col0 * col0 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - - col0 * col2 * 54 FROM tab1 AS cor0
----
196992
414720
8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6145
SELECT - cor0.col1 + + CAST( cor0.col0 AS SIGNED ) * + col2 AS col1 FROM tab0 AS cor0
----
-62
706
7207

skipif mysql # not compatible
query I rowsort label-6145
SELECT - cor0.col1 + + CAST ( cor0.col0 AS INTEGER ) * + col2 AS col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT col2 + - ( - col1 ) AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col1 + col2 * col1 AS col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL + - cor0.col0 * ( 28 ) - + cor0.col1 FROM tab1 AS cor0
----
-110
-1802
-2253

query I rowsort
SELECT DISTINCT - - col2 * 63 FROM tab0 AS cor0
----
2079
5166
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6150
SELECT + + col1 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6150
SELECT + + col1 * + CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - col0 + col0 * col1 FROM tab0 cor0
----
1272
3360
801

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col2 col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + col1 + col1 * - col2 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT + 43 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT - - 37 AS col2 FROM tab2 AS cor0
----
37
37
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6156
SELECT CAST( + 35 AS SIGNED ) FROM tab0 AS cor0
----
35
35
35

skipif mysql # not compatible
query I rowsort label-6156
SELECT CAST ( + 35 AS INTEGER ) FROM tab0 AS cor0
----
35
35
35

query I rowsort
SELECT ALL - 87 * col0 AS col2 FROM tab2 AS cor0
----
-609
-6786
-6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-6158
SELECT DISTINCT CAST( + col2 AS SIGNED ) + - col1 DIV - col1 + col1 * - col2 FROM tab2 AS cor0
----
-1507
-607
-809

skipif mysql # not compatible
query I rowsort label-6158
SELECT DISTINCT CAST ( + col2 AS INTEGER ) + - col1 / - col1 + col1 * - col2 FROM tab2 AS cor0
----
-1507
-607
-809

onlyif mysql # use DIV operator for integer division
query I rowsort label-6159
SELECT DISTINCT + CAST( ( + col0 ) AS SIGNED ) * col2 DIV + col1 AS col2 FROM tab0 AS cor0
----
0
80
9

skipif mysql # not compatible
query I rowsort label-6159
SELECT DISTINCT + CAST ( ( + col0 ) AS INTEGER ) * col2 / + col1 AS col2 FROM tab0 AS cor0
----
0
80
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 33 * - cor0.col0 col0 FROM tab0 cor0
----
112035
267267
68112

query I rowsort
SELECT DISTINCT - col0 * col0 + + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT ALL + cor0.col1 * 20 FROM tab0 AS cor0
----
1720
1820
1940

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6163
SELECT ALL CAST( - col2 AS SIGNED ) * - col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-6163
SELECT ALL CAST ( - col2 AS INTEGER ) * - col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 61 col1 FROM tab1 AS cor0
----
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6165
SELECT DISTINCT - CAST( + col2 AS SIGNED ) * col0 + ( col1 ) AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif mysql # not compatible
query I rowsort label-6165
SELECT DISTINCT - CAST ( + col2 AS INTEGER ) * col0 + ( col1 ) AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-6166
SELECT ALL col1 DIV 85 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6166
SELECT ALL col1 / 85 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col0 - col2 * tab1.col0 * col2 FROM tab1
----
-207872
-737200
-8745

onlyif mysql # use DIV operator for integer division
query I rowsort label-6168
SELECT ALL col1 DIV ( + col0 ) FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-6168
SELECT ALL col1 / ( + col0 ) FROM tab2
----
0
0
4

query I rowsort
SELECT DISTINCT + 5 * + 58 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1127
1824
936

query I rowsort
SELECT DISTINCT + - tab2.col2 * tab2.col0 + - 38 FROM tab2, tab0, tab1 AS cor0
----
-2066
-227
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 - - col0 col1 FROM tab0
----
178
48
70

query I rowsort
SELECT - col2 * - col1 * + col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT ALL + - 93 * col2 AS col2 FROM tab2 AS cor0
----
-2418
-2511
-3534

query I rowsort
SELECT + 95 * cor0.col1 AS col1 FROM tab2 cor0
----
1615
2945
5605

query I rowsort
SELECT - tab1.col1 + - ( + tab1.col0 ) + col2 FROM tab1
----
-17
25
3

query I rowsort
SELECT DISTINCT col2 * - tab0.col0 + + col1 * + col0 * col1 AS col0 FROM tab0
----
176712
329280
729711

query I rowsort
SELECT ALL + col0 + + ( + col2 * - tab0.col0 + + tab0.col1 ) AS col2 FROM tab0
----
-682
-7118
97

query I rowsort
SELECT DISTINCT tab0.col0 * - 9 AS col0 FROM tab0
----
-216
-315
-801

query I rowsort
SELECT ALL col1 + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6180
SELECT + col0 DIV ( - ( col0 ) ) FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6180
SELECT + col0 / ( - ( col0 ) ) FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * 5 * ( + col1 ) col0 FROM tab1
----
2850
6240
7020

onlyif mysql # use DIV operator for integer division
query I rowsort label-6182
SELECT DISTINCT - + col0 * cor0.col1 + + col2 DIV + 58 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-6182
SELECT DISTINCT - + col0 * cor0.col1 + + col2 / + 58 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6183
SELECT - - CAST( col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6183
SELECT - - CAST ( col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - col1 - + cor0.col0 * col2 * + col1 AS col2 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT col2 * + 2 AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL + - cor0.col0 + 70 * col1 FROM tab1 AS cor0
----
1817
636
830

query I rowsort
SELECT + cor0.col1 * - ( col0 ) - + ( 13 * col0 ) AS col2 FROM tab0 AS cor0
----
-2376
-3850
-9256

query I rowsort
SELECT ( col0 ) + col1 * + ( col1 ) FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT cor0.col0 * 17 - col2 * + col1 FROM tab0 AS cor0
----
-2430
-5949
498

onlyif mysql # use DIV operator for integer division
query I rowsort label-6190
SELECT col2 * col1 + cor0.col0 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-6190
SELECT col2 * col1 + cor0.col0 / cor0.col0 AS col2 FROM tab2 AS cor0
----
1535
647
838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 95 - col1 col0 FROM tab1 AS cor0
----
-105
-108
-121

query I rowsort
SELECT - col0 + col1 * cor0.col1 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
248
3429
981

query I rowsort
SELECT - col2 * col0 * - col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL - - 17 + - col1 * - cor0.col0 FROM tab1 AS cor0
----
1057
657
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-6196
SELECT col2 DIV col1 + col1 + + ( cor0.col0 * - ( + cor0.col1 ) ) FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-6196
SELECT col2 / col1 + col1 + + ( cor0.col0 * - ( + cor0.col1 ) ) FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - 27 + cor0.col1 * - 89 FROM tab1 AS cor0
----
-1184
-2341
-917

query I rowsort
SELECT col1 * col1 * + 6 FROM tab0 AS cor0
----
44376
49686
56454

onlyif mysql # use DIV operator for integer division
query I rowsort label-6199
SELECT DISTINCT - ( - col2 ) + col2 DIV col0 AS col1 FROM tab0 cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-6199
SELECT DISTINCT - ( - col2 ) + col2 / col0 AS col1 FROM tab0 cor0
----
1
34
82

query I rowsort
SELECT DISTINCT - col0 + ( + 16 + - col2 ) * 16 AS col2 FROM tab2 AS cor0
----
-183
-238
-431

query I rowsort
SELECT col1 + col1 AS col1 FROM tab0 cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 65 col1 FROM tab0
----
-65
-65
-65

query I rowsort
SELECT col1 * - ( 60 ) FROM tab0 AS cor0
----
-5160
-5460
-5820

onlyif mysql # use DIV operator for integer division
query I rowsort label-6204
SELECT + ( - 57 ) DIV col1 - ( - 86 ) FROM tab1 AS cor0
----
81
82
84

skipif mysql # not compatible
query I rowsort label-6204
SELECT + ( - 57 ) / col1 - ( - 86 ) FROM tab1 AS cor0
----
81
82
84

query I rowsort
SELECT - - cor0.col0 * 49 FROM tab0 AS cor0
----
1176
1715
4361

query I rowsort
SELECT + col1 * - ( + cor0.col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + 85 * col0 AS col1 FROM tab2 cor0
----
595
6630
6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-6208
SELECT + 44 DIV col2 FROM tab0 AS cor0
----
0
1
44

skipif mysql # not compatible
query I rowsort label-6208
SELECT + 44 / col2 FROM tab0 AS cor0
----
0
1
44

query I rowsort
SELECT ALL - 23 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT - 47 AS col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT ALL - ( + col0 ) AS col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL 31 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

onlyif mysql # use DIV operator for integer division
query I rowsort label-6213
SELECT col2 DIV - col1 + - col1 * + cor0.col2 AS col1 FROM tab2 cor0
----
-1534
-648
-837

skipif mysql # not compatible
query I rowsort label-6213
SELECT col2 / - col1 + - col1 * + cor0.col2 AS col1 FROM tab2 cor0
----
-1534
-648
-837

query I rowsort
SELECT DISTINCT - col0 - col1 AS col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - + ( + col0 ) + + cor0.col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6216
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + 22 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6216
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + 22 FROM tab1 cor0
----
NULL

query I rowsort
SELECT 65 - 48 FROM tab1 AS cor0
----
17
17
17

query I rowsort
SELECT DISTINCT - 87 - + col2 FROM tab2 AS cor0
----
-113
-114
-125

query I rowsort
SELECT DISTINCT + col2 * - col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL col2 + + 63 AS col0 FROM tab0 AS cor0
----
145
64
96

query I rowsort
SELECT ALL + col2 * - ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - 44 + + ( col0 + ( + col1 ) * - col0 ) AS col1 FROM tab2
----
-1308
-254
-4568

query I rowsort
SELECT + tab2.col1 AS col0 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ( + 42 + col2 ) * 93 AS col2 FROM tab2
----
6324
6417
7440

query I rowsort
SELECT tab0.col1 * + cor0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 116454f2268e21c1351daf3f5803c987

query I rowsort
SELECT - col2 + - col0 * cor0.col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT - col1 * col1 + col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL tab2.col2 + + col0 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL 53 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT - col1 + + col1 * + col1 AS col1 FROM tab2
----
272
3422
930

query I rowsort
SELECT + col1 + - col0 * col0 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT col0 - cor0.col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + col1 * + col2 * + cor0.col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL + col1 * - ( 78 ) + - col1 AS col2 FROM tab2 AS cor0
----
-1343
-2449
-4661

query I rowsort
SELECT + col2 * 33 + col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT DISTINCT + col1 * + ( col0 ) + col0 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col1 col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col1 + + 39 * - 55 AS col0 FROM tab1
----
-2119
-2132
-2135

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6239
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 89 col1 FROM tab2, tab1, tab2 AS cor0, tab2 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6239
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 89 col1 FROM tab2, tab1, tab2 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT 86 FROM tab0, tab1 AS cor0
----
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * 0 col2 FROM tab2
----
0

query I rowsort
SELECT - tab0.col0 * col1 + + col1 AS col0 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - - col0 * ( col1 ) + col0 * + col2 AS col1 FROM tab1 AS cor0
----
240
4288
8720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6244
SELECT DISTINCT col2 / ( + ( - col2 ) ) + CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6244
SELECT DISTINCT col2 / ( + ( - col2 ) ) + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * + ( - 46 ) col0 FROM tab2 AS cor0
----
-1196
-1242
-1748

query I rowsort
SELECT - col2 * 39 FROM tab1 AS cor0
----
-2106
-2223
-3744

query I rowsort
SELECT ALL + - 67 AS col1 FROM tab0 AS cor0
----
-67
-67
-67

query I rowsort
SELECT - 32 + + 16 AS col1 FROM tab2 AS cor0
----
-16
-16
-16

query I rowsort
SELECT ALL + ( col2 ) + - col2 * 20 FROM tab1 AS cor0
----
-1026
-1083
-1824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * cor0.col2 * col1 col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT - ( cor0.col2 ) - col2 AS col2 FROM tab2 cor0
----
-52
-54
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6252
SELECT DISTINCT + - ( - col1 ) * col2 - CAST( col1 AS SIGNED ) FROM tab1 cor0
----
1235
1378
560

skipif mysql # not compatible
query I rowsort label-6252
SELECT DISTINCT + - ( - col1 ) * col2 - CAST ( col1 AS INTEGER ) FROM tab1 cor0
----
1235
1378
560

query I rowsort
SELECT ALL + 49 - col0 AS col0 FROM tab0 AS cor0
----
-40
14
25

query I rowsort
SELECT + col0 + + 1 FROM tab2 cor0
----
79
8
80

query I rowsort
SELECT DISTINCT ( col1 ) + col0 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT col0 * + 24 + - 24 AS col2 FROM tab1
----
1512
1896
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-6257
SELECT ( cor0.col1 ) DIV cor0.col0 - + CAST( + col0 AS SIGNED ) * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-4096
-6400

skipif mysql # not compatible
query I rowsort label-6257
SELECT ( cor0.col1 ) / cor0.col0 - + CAST ( + col0 AS INTEGER ) * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-4096
-6400

query I rowsort
SELECT ALL - 43 + + 1 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
43
48
54

query I rowsort
SELECT DISTINCT + - col1 * col0 + + cor0.col0 * 50 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-30864
-404149
-64645

query I rowsort
SELECT ALL - + col0 + col1 * ( - col0 ) FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT - cor0.col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 74 AS col0 FROM tab1 cor0
----
-74
-74
-74

query I rowsort
SELECT DISTINCT + + 88 * - col1 FROM tab0 AS cor0
----
-7568
-8008
-8536

query I rowsort
SELECT ( + cor0.col1 ) + 19 AS col1 FROM tab1 AS cor0
----
29
32
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6265
SELECT DISTINCT - col1 + col1 * - col2 + - col0 * - col1 DIV - col1 FROM tab0 AS cor0
----
-229
-2948
-7642

skipif mysql # not compatible
query I rowsort label-6265
SELECT DISTINCT - col1 + col1 * - col2 + - col0 * - col1 / - col1 FROM tab0 AS cor0
----
-229
-2948
-7642

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6266
SELECT DISTINCT col2 * + col0 * + CAST( col0 AS SIGNED ) + - col2 FROM tab2 AS cor0
----
1296
158158
237120

skipif mysql # not compatible
query I rowsort label-6266
SELECT DISTINCT col2 * + col0 * + CAST ( col0 AS INTEGER ) + - col2 FROM tab2 AS cor0
----
1296
158158
237120

query I rowsort
SELECT DISTINCT + - col2 + cor0.col1 + 36 FROM tab2 AS cor0
----
15
40
69

query I rowsort
SELECT 86 AS col0 FROM tab0 cor0
----
86
86
86

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT col0 + - 11 * - col1 FROM tab0 AS cor0
----
1090
1102
970

query I rowsort
SELECT DISTINCT 65 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
65

query I rowsort
SELECT + cor2.col2 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 39c7e653e7a493eb9c9e3dad9ba3b8c2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6273
SELECT + 23 DIV - col0 + - col1 AS col1 FROM tab1
----
-10
-13
-33

skipif mysql # not compatible
query I rowsort label-6273
SELECT + 23 / - col0 + - col1 AS col1 FROM tab1
----
-10
-13
-33

query I rowsort
SELECT + 53 AS col2 FROM tab1 AS cor0
----
53
53
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 9 col2 FROM tab1, tab1 AS cor0
----
9

query I rowsort
SELECT - col0 * col2 + tab0.col0 * + ( - 2 ) * col1 AS col0 FROM tab0
----
-23496
-4920
-6825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 41 col1 FROM tab1, tab2 cor0
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

query I rowsort
SELECT ALL col1 * col2 * col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT + col2 * + tab0.col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT + 43 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 199105619049271147956de52e7f5ed4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6281
SELECT DISTINCT + col0 + col0 DIV col1 FROM tab1
----
3
70
86

skipif mysql # not compatible
query I rowsort label-6281
SELECT DISTINCT + col0 + col0 / col1 FROM tab1
----
3
70
86

query I rowsort
SELECT + 7 + col2 FROM tab0 AS cor0
----
40
8
89

query I rowsort
SELECT DISTINCT - - ( - col0 ) + + col0 AS col2 FROM tab2 AS cor0
----
0

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 # use DIV operator for integer division
query I rowsort label-6285
SELECT DISTINCT + 50 DIV - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6285
SELECT DISTINCT + 50 / - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT + col0 * + 39 * + col1 - - col2 FROM tab2
----
179504
52415
8490

query I rowsort
SELECT col1 * + 64 FROM tab2 cor0
----
1088
1984
3776

query I rowsort
SELECT + + col0 + - 16 * col0 FROM tab0 AS cor0
----
-1335
-360
-525

query I rowsort
SELECT ALL + col0 - col0 * col2 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6290
SELECT DISTINCT - col0 DIV CAST( col0 AS SIGNED ) + col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6290
SELECT DISTINCT - col0 / CAST ( col0 AS INTEGER ) + col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT col2 * + 35 * - col2 FROM tab1 AS cor0
----
-102060
-113715
-322560

query I rowsort
SELECT + col1 + 19 FROM tab1 AS cor0
----
29
32
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6293
SELECT DISTINCT + - col0 * - ( 25 ) + - col0 DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
1601
2000
75

skipif mysql # not compatible
query I rowsort label-6293
SELECT DISTINCT + - col0 * - ( 25 ) + - col0 / - cor0.col2 AS col0 FROM tab1 AS cor0
----
1601
2000
75

query I rowsort
SELECT + 72 FROM tab2, tab1 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT - - 6 + + col1 * - col2 AS col1 FROM tab1 AS cor0
----
-1242
-1398
-564

query I rowsort
SELECT 13 FROM tab1, tab0 cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to b092e3fa17e78608cf120e97d1bfff67

query I rowsort
SELECT ALL - - 68 AS col1 FROM tab2 AS cor0
----
68
68
68

query I rowsort
SELECT ALL - 60 * col2 FROM tab1 AS cor0
----
-3240
-3420
-5760

query I rowsort
SELECT ALL + ( - 97 ) FROM tab2
----
-97
-97
-97

query I rowsort
SELECT DISTINCT + 48 AS col0 FROM tab0, tab1, tab0 AS cor0
----
48

query I rowsort
SELECT DISTINCT + 53 * col2 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT + 14 * col0 FROM tab2 AS cor0
----
1092
1106
98

query I rowsort
SELECT + 30 + + col1 FROM tab1 AS cor0
----
40
43
56

query I rowsort
SELECT col1 * - 96 FROM tab0
----
-8256
-8736
-9312

query I rowsort
SELECT DISTINCT - 48 * - 99 FROM tab1
----
4752

query I rowsort
SELECT - - cor0.col1 * ( + col2 ) + - 63 AS col0 FROM tab0 cor0
----
2775
34
7399

query I rowsort
SELECT - 6 * 79 + - cor0.col2 * + col0 FROM tab0 cor0
----
-1266
-509
-7772

query I rowsort
SELECT 47 * col2 + - cor0.col0 FROM tab2 AS cor0
----
1144
1262
1707

onlyif mysql # use DIV operator for integer division
query I rowsort label-6309
SELECT + + 16 + col1 DIV col1 FROM tab0 AS cor0
----
17
17
17

skipif mysql # not compatible
query I rowsort label-6309
SELECT + + 16 + col1 / col1 FROM tab0 AS cor0
----
17
17
17

query I rowsort
SELECT + col2 + - ( - col0 ) * col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6311
SELECT - col2 * 3 DIV col0 col2 FROM tab0 AS cor0
----
-2
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6311
SELECT - col2 * 3 / col0 col2 FROM tab0 AS cor0
----
-2
-4
0

query I rowsort
SELECT DISTINCT - - 58 * cor0.col1 AS col2 FROM tab1, tab2 AS cor0
----
1798
3422
986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col0 + - cor0.col0 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ae22909705672dcb483690ac21345259

query I rowsort
SELECT cor0.col2 + ( - cor0.col1 ) AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to ae0eeb942db3f01544a81804e95e971a

query I rowsort
SELECT DISTINCT + + 75 + col1 * ( col1 ) AS col2 FROM tab1 AS cor0
----
175
244
751

query I rowsort
SELECT + col0 + + col0 * + col0 - col2 FROM tab0 AS cor0
----
1259
567
7928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 - + col0 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 23 * - col0 + - col0 AS col1 FROM tab1
----
1408
1760
66

query I rowsort
SELECT DISTINCT col0 * col2 * - 70 FROM tab0
----
-2450
-510860
-55440

query I rowsort
SELECT - col1 * col1 * tab0.col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT + 24 * + 16 + col1 + ( - col0 ) FROM tab2 AS cor0
----
322
365
408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 83 col1 FROM tab0 AS cor0
----
2739
6806
83

query I rowsort
SELECT col0 * 6 FROM tab1
----
18
384
480

query I rowsort
SELECT + - col0 * col2 * - 43 FROM tab1 cor0
----
156864
330240
6966

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6325
SELECT cor0.col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6325
SELECT cor0.col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT tab2.col0 * - tab2.col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + col1 * - ( - 48 ) FROM tab1 AS cor0
----
1248
480
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-6329
SELECT ALL col1 DIV + ( cor0.col0 ) FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-6329
SELECT ALL col1 / + ( cor0.col0 ) FROM tab1 AS cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6330
SELECT - col1 + col1 DIV - col2 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6330
SELECT - col1 + col1 / - col2 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6331
SELECT DISTINCT - col2 * 66 + col1 DIV col0 FROM tab2 AS cor0
----
-1716
-1778
-2508

skipif mysql # not compatible
query I rowsort label-6331
SELECT DISTINCT - col2 * 66 + col1 / col0 FROM tab2 AS cor0
----
-1716
-1778
-2508

query I rowsort
SELECT DISTINCT col0 * ( + 76 ) FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT DISTINCT col2 + col1 * + ( + col1 ) AS col0 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL - + cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + col1 * ( col1 ) AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + + cor0.col1 + + ( + 32 ) FROM tab1 AS cor0
----
42
45
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col0 + ( - col1 ) * col1 FROM tab2 cor0
----
-210
-3403
-954

query I rowsort
SELECT - + cor0.col0 * - 5 * - col2 AS col1 FROM tab1 AS cor0
----
-18240
-38400
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 33 * - cor0.col0 + col0 - + col0 * + col2 * - col2 col1 FROM tab1 AS cor0
----
210112
740000
8850

query I rowsort
SELECT ALL + - col0 * 0 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6342
SELECT ALL - ( + col2 ) DIV - cor0.col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6342
SELECT ALL - ( + col2 ) / - cor0.col0 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 col1 FROM tab2, tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - + 77 FROM tab1 AS cor0
----
-77
-77
-77

query I rowsort
SELECT - ( 88 ) * col1 + col2 FROM tab2 AS cor0
----
-1458
-2701
-5166

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - - cor0.col0 * col0 col2 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT + + 35 * + col0 * + col1 - + col1 FROM tab1 AS cor0
----
22390
2704
36387

query I rowsort
SELECT ALL cor1.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-6349
SELECT DISTINCT - col0 - col1 * 62 DIV col2 FROM tab0
----
-157
-185
-6049

skipif mysql # not compatible
query I rowsort label-6349
SELECT DISTINCT - col0 - col1 * 62 / col2 FROM tab0
----
-157
-185
-6049

query I rowsort
SELECT - ( + col1 ) + + col2 * - 81 FROM tab2 AS cor0
----
-2165
-2218
-3095

query I rowsort
SELECT DISTINCT + + ( + col0 ) * col0 * col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL + col1 + col1 * 77 FROM tab0 cor0
----
6708
7098
7566

query I rowsort
SELECT + cor1.col2 * ( + 57 ) * - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 07c8ebb7eb198310c4a04b30dc93bf20

query I rowsort
SELECT - 50 AS col0 FROM tab2, tab0, tab0 cor0
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

query I rowsort
SELECT ALL + cor0.col1 + - 79 * + col0 FROM tab1 cor0
----
-211
-5046
-6307

query I rowsort
SELECT - + 9 * col1 AS col1 FROM tab1 AS cor0
----
-117
-234
-90

query I rowsort
SELECT + + col1 * + col2 * - col2 FROM tab0 cor0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab1
----
13

query I rowsort
SELECT - 55 - col0 AS col1 FROM tab0
----
-144
-79
-90

query I rowsort
SELECT col2 * col2 * - col0 + col1 FROM tab1
----
-207926
-737267
-8722

query I rowsort
SELECT ALL col2 * ( col1 ) FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 96 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c89b545346f99713888a7934e4caa539

query I rowsort
SELECT col2 * - tab1.col2 + col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT - tab1.col2 + + tab1.col0 AS col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT col2 + 91 AS col2 FROM tab0
----
124
173
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6366
SELECT - col0 + - 2 DIV col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6366
SELECT - col0 + - 2 / col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col1 * 54 AS col0 FROM tab0 AS cor0
----
4644
4914
5238

query I rowsort
SELECT DISTINCT col0 * ( - col1 + + col2 ) * ( col0 ) FROM tab2 AS cor0
----
-196
-200772
131061

query I rowsort
SELECT ALL - ( - col2 ) + tab2.col1 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL 64 + col2 AS col1 FROM tab2
----
102
90
91

query I rowsort
SELECT DISTINCT col0 * + col0 + col1 * - col0 FROM tab0
----
-1488
-178
-2170

query I rowsort
SELECT ALL + col2 + + 97 AS col2 FROM tab2
----
123
124
135

query I rowsort
SELECT ALL 66 + col2 AS col2 FROM tab0
----
148
67
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT + CAST( NULL AS DECIMAL ) + 7 * col2 + + 9 * - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6374
SELECT + CAST ( NULL AS REAL ) + 7 * col2 + + 9 * - col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * col1 + col0 + col1 FROM tab1 AS cor0
----
-26
-647
-76

query I rowsort
SELECT ALL 69 AS col1 FROM tab2 AS cor0
----
69
69
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 99 + col1 col1 FROM tab2 AS cor0
----
116
130
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6378
SELECT + + col1 + 34 * col1 * - CAST( col1 AS SIGNED ) - col2 * - col2 AS col2 FROM tab2 AS cor0
----
-117619
-31914
-8365

skipif mysql # not compatible
query I rowsort label-6378
SELECT + + col1 + 34 * col1 * - CAST ( col1 AS INTEGER ) - col2 * - col2 AS col2 FROM tab2 AS cor0
----
-117619
-31914
-8365

query I rowsort
SELECT DISTINCT + + 2 * - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-1280
-156
-2080

query I rowsort
SELECT DISTINCT + 2 - col2 * - col2 FROM tab0 cor0
----
1091
3
6726

query I rowsort
SELECT + + 80 * cor0.col1 - col1 AS col1 FROM tab2 cor0
----
1343
2449
4661

query I rowsort
SELECT ALL col0 * 27 + - col2 FROM tab1 AS cor0
----
1671
2064
27

query I rowsort
SELECT + ( ( - tab2.col0 ) ) + col1 AS col2 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL + 29 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6385
SELECT DISTINCT + - col2 * col0 + + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6385
SELECT DISTINCT + - col2 * col0 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col2 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL + ( - col0 ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT 0 + - col1 * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - 1 * - col0 + col0 AS col2 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 - col0 col0 FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT DISTINCT - - 60 AS col2 FROM tab2 AS cor0
----
60

query I rowsort
SELECT DISTINCT - 83 + - col2 + - col2 FROM tab0 AS cor0
----
-149
-247
-85

query I rowsort
SELECT - - ( + col0 ) * cor0.col2 + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT ALL cor0.col1 + + col2 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - + col2 + col0 * 8 FROM tab2 AS cor0
----
29
594
598

query I rowsort
SELECT - cor0.col2 * - col0 * + ( - cor0.col2 ) + col1 AS col0 FROM tab1 AS cor0
----
-207926
-737267
-8722

query I rowsort
SELECT 76 + col2 AS col0 FROM tab0 AS cor0
----
109
158
77

query I rowsort
SELECT ALL - - cor0.col0 * + col1 AS col2 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * + col1 + col2 * - 90 col2 FROM tab0 cor0
----
4426
901
9319

onlyif mysql # use DIV operator for integer division
query I rowsort label-6400
SELECT ALL + 56 - - col2 DIV + 40 FROM tab2 cor0
----
56
56
56

skipif mysql # not compatible
query I rowsort label-6400
SELECT ALL + 56 - - col2 / + 40 FROM tab2 cor0
----
56
56
56

query I rowsort
SELECT DISTINCT + + 35 + col1 * + col1 * col2 FROM tab2 AS cor0
----
11017
25982
90541

query I rowsort
SELECT ALL + col2 + + col1 * - col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT - 13 + + col1 - - col1 * + 72 FROM tab0 AS cor0
----
6265
6630
7068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 19 + + col0 col1 FROM tab1 AS cor0
----
-16
45
61

query I rowsort
SELECT ALL cor0.col0 + 50 FROM tab1, tab0 AS cor0
----
9 values hashing to f295a2607c134d3fa8a7b9b3519a6b22

query I rowsort
SELECT - cor0.col2 * + 39 FROM tab2, tab1 AS cor0
----
9 values hashing to 09be94d84b2323d591dd0d594e34f33f

query I rowsort
SELECT - - ( + cor0.col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + - 48 + + 86 * + col2 AS col1 FROM tab0 AS cor0
----
2790
38
7004

query I rowsort
SELECT - ( + 41 ) AS col1 FROM tab2
----
-41
-41
-41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6410
SELECT ALL CAST( col2 AS SIGNED ) * col2 AS col1 FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-6410
SELECT ALL CAST ( col2 AS INTEGER ) * col2 AS col1 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6411
SELECT ALL + 27 DIV - col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6411
SELECT ALL + 27 / - col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + + col2 * + col1 - + col0 FROM tab0 AS cor0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-6413
SELECT - - col2 DIV + col1 + col0 col2 FROM tab1 AS cor0
----
5
69
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6413
SELECT - - col2 / + col1 + col0 col2 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT - col1 * col2 + - 69 + + col1 FROM tab0 AS cor0
----
-2821
-69
-7440

query I rowsort
SELECT col0 * 50 AS col0 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT - col2 * - 75 + + 17 + cor0.col1 AS col2 FROM tab1 AS cor0
----
4093
4302
7230

query I rowsort
SELECT DISTINCT - col0 * col0 * col1 + - col2 * col0 AS col0 FROM tab0
----
-118860
-50328
-728109

query I rowsort
SELECT col0 + + col0 * - 97 + - ( - tab0.col2 ) * - tab0.col1 * col2 FROM tab0
----
-3457
-620428
-95958

query I rowsort
SELECT ALL col2 * col1 + - col0 AS col0 FROM tab1
----
1168
1401
506

query I rowsort
SELECT col1 * + col1 * - col1 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT col1 + 82 AS col2 FROM tab1 AS cor0
----
108
92
95

query I rowsort
SELECT col1 + 39 AS col1 FROM tab1 AS cor0
----
49
52
65

query I rowsort
SELECT DISTINCT + cor0.col1 + + 5 FROM tab2 cor0
----
22
36
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6424
SELECT DISTINCT - col2 + + CAST( NULL AS SIGNED ) / + col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6424
SELECT DISTINCT - col2 + + CAST ( NULL AS INTEGER ) / + col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 + - col1 * - 60 + col2 FROM tab2 cor0
----
1075
1918
3625

query I rowsort
SELECT ALL 89 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT + 88 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6428
SELECT - CAST( NULL AS DECIMAL ) + + col1 + - col0 * col2 * + col0 col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6428
SELECT - CAST ( NULL AS REAL ) + + col1 + - col0 * col2 * + col0 col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * cor0.col2 + + col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT 84 AS col0 FROM tab1 AS cor0
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 * + col2 * col2 + + col2 col1 FROM tab2 AS cor0
----
-17550
-19656
-54834

query I rowsort
SELECT ALL - 41 + col1 * cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
636015
753530
912632

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6433
SELECT col2 * CAST( NULL AS SIGNED ) * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6433
SELECT col2 * CAST ( NULL AS INTEGER ) * col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * ( 18 ) * col0 AS col0 FROM tab2
----
109512
112338
882

query I rowsort
SELECT ALL 71 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT col2 + tab0.col1 + col1 * col2 * - 78 AS col0 FROM tab0
----
-221245
-581863
-7468

query I rowsort
SELECT col0 + 73 FROM tab0 AS cor0
----
108
162
97

query I rowsort
SELECT DISTINCT 14 + - cor0.col2 * + col1 + 65 AS col2 FROM tab0 cor0
----
-18
-2759
-7383

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6439
SELECT + CAST( col1 AS SIGNED ) + col0 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-6439
SELECT + CAST ( col1 AS INTEGER ) + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6440
SELECT + + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6440
SELECT + + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6441
SELECT + CAST( cor0.col1 AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif mysql # not compatible
query I rowsort label-6441
SELECT + CAST ( cor0.col1 AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL 48 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6443
SELECT + - 26 * col2 DIV + col1 FROM tab2 AS cor0
----
-11
-22
-58

skipif mysql # not compatible
query I rowsort label-6443
SELECT + - 26 * col2 / + col1 FROM tab2 AS cor0
----
-11
-22
-58

query I rowsort
SELECT - col2 * 93 + col1 * - col0 FROM tab0 AS cor0
----
-15725
-3488
-5133

query I rowsort
SELECT + cor0.col2 + col2 * col0 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + col2 * 17 FROM tab2 cor0
----
442
459
646

query I rowsort
SELECT ALL - - col0 * - col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6448
SELECT - + col1 * + col2 - - col1 DIV col1 AS col2 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-6448
SELECT - + col1 * + col2 - - col1 / col1 AS col2 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 49 - - col2 col1 FROM tab2 AS cor0
----
-316
-3796
-3833

query I rowsort
SELECT 86 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT col2 + ( - col1 * col2 ) AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + cor0.col0 * + col1 - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT + 36 - 79 AS col2 FROM tab1
----
-43
-43
-43

query I rowsort
SELECT - - 51 + - 3 FROM tab2 AS cor0
----
48
48
48

query I rowsort
SELECT ALL - - 9 * cor0.col1 - + col0 FROM tab1 AS cor0
----
231
26
37

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 + ( + cor0.col1 ) + + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL + col1 + + col1 * col0 AS col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-6459
SELECT ALL + col1 DIV + cor0.col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6459
SELECT ALL + col1 / + cor0.col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT + + col0 + cor0.col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - 24 AS col1 FROM tab0 cor0
----
-24

query I rowsort
SELECT col1 * 80 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
1398
2507
4746

query I rowsort
SELECT ALL col1 * + 87 + ( tab0.col0 ) FROM tab0
----
7506
8006
8474

query I rowsort
SELECT DISTINCT - col1 * ( - ( - col1 ) ) AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - col1 + + col1 * - ( - col0 ) FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL col0 * ( col0 ) FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT 2 + - cor0.col0 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 38170f35921a3370d8c055311d385979

query I rowsort
SELECT DISTINCT + + col1 * + col1 AS col2 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT ALL + - cor0.col0 + col2 * ( cor0.col0 ) FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT ALL - col2 * 77 FROM tab1 cor0
----
-4158
-4389
-7392

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6471
SELECT DISTINCT - - CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6471
SELECT DISTINCT - - CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - ( - ( + col0 ) ) + + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + - col2 + + 72 * col2 FROM tab2 AS cor0
----
1846
1917
2698

onlyif mysql # use DIV operator for integer division
query I rowsort label-6474
SELECT DISTINCT col1 DIV col2 AS col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6474
SELECT DISTINCT col1 / col2 AS col2 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT ALL + col0 * + 54 * col0 FROM tab0
----
31104
427734
66150

query I rowsort
SELECT ALL - - col0 * - 34 + col0 FROM tab0 AS cor0
----
-1155
-2937
-792

query I rowsort
SELECT DISTINCT - + col0 + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 0 + cor0.col1 col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + - col1 + + cor0.col0 * col0 + + col0 * + ( col1 ) FROM tab1 AS cor0
----
4726
61
7427

onlyif mysql # use DIV operator for integer division
query I rowsort label-6480
SELECT ALL - col1 * col1 DIV cor0.col0 FROM tab1 AS cor0
----
-1
-2
-225

skipif mysql # not compatible
query I rowsort label-6480
SELECT ALL - col1 * col1 / cor0.col0 FROM tab1 AS cor0
----
-1
-2
-225

query I rowsort
SELECT ALL + + cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL col0 + - col1 * - tab1.col2 FROM tab1
----
1328
1407
634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6483
SELECT ALL - col1 * CAST( 34 AS SIGNED ) * col2 FROM tab1
----
-19380
-42432
-47736

skipif mysql # not compatible
query I rowsort label-6483
SELECT ALL - col1 * CAST ( 34 AS INTEGER ) * col2 FROM tab1
----
-19380
-42432
-47736

query I rowsort
SELECT ( + col2 ) * col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6485
SELECT ALL - + ( + ( col0 ) ) DIV col0 + col2 AS col2 FROM tab0 cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-6485
SELECT ALL - + ( + ( col0 ) ) / col0 + col2 AS col2 FROM tab0 cor0
----
0
32
81

query I rowsort
SELECT DISTINCT cor0.col1 * - cor0.col0 + + cor0.col1 FROM tab0, tab0 AS cor0
----
-1978
-3298
-8008

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 ALL + col2 * - 81 AS col2 FROM tab0 AS cor0
----
-2673
-6642
-81

query I rowsort
SELECT DISTINCT - col0 + col1 * col0 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + cor1.col1 * ( - 28 ) + - cor1.col2 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-337
-460
-782

query I rowsort
SELECT col1 * col1 + col2 AS col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT + ( - tab0.col2 ) * col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - ( ( + col0 ) ) AS col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - col0 * col1 * col2 - + ( col0 + + 3 ) FROM tab1
----
-36547
-4218
-99923

query I rowsort
SELECT - tab0.col1 + col1 + col0 * 12 FROM tab0
----
1068
288
420

query I rowsort
SELECT cor0.col2 + 37 AS col0 FROM tab2 AS cor0
----
63
64
75

query I rowsort
SELECT + col1 * + col2 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col1 + + col2 * - col2 col0 FROM tab2 AS cor0
----
-2787
-5278
-946

query I rowsort
SELECT ALL + col2 * col0 + - col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT - col2 + + 90 FROM tab2 AS cor0
----
52
63
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - tab2.col1 col2 FROM tab2, tab1, tab0 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col2 * - col1 + tab0.col2 col1 FROM tab0
----
2904
7626
99

query I rowsort
SELECT + ( + col0 * col1 ) + + col1 + col0 FROM tab2
----
1439
255
4739

onlyif mysql # use DIV operator for integer division
query I rowsort label-6504
SELECT DISTINCT - col0 DIV col2 - ( + ( - col2 ) ) FROM tab1
----
54
56
96

skipif mysql # not compatible
query I rowsort label-6504
SELECT DISTINCT - col0 / col2 - ( + ( - col2 ) ) FROM tab1
----
54
56
96

query I rowsort
SELECT + tab2.col1 + ( + col0 ) + + col2 AS col0 FROM tab2
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - col1 col2 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT - col0 * ( + col2 ) + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT cor0.col0 + ( col0 * col0 + + col1 ) AS col2 FROM tab0 AS cor0
----
1357
686
8101

query I rowsort
SELECT + + col1 + ( + 91 ) FROM tab2 AS cor0
----
108
122
150

query I rowsort
SELECT DISTINCT - - cor0.col2 + col1 * col2 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * ( 20 ) col2 FROM tab2 AS cor0
----
-1180
-340
-620

query I rowsort
SELECT DISTINCT - cor0.col2 - + 19 * - 61 AS col0 FROM tab2 AS cor0
----
1121
1132
1133

query I rowsort
SELECT ALL cor0.col1 * 88 FROM tab0 AS cor0
----
7568
8008
8536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6514
SELECT DISTINCT col1 * CAST( 79 AS SIGNED ) + cor0.col1 AS col0 FROM tab2 AS cor0
----
1360
2480
4720

skipif mysql # not compatible
query I rowsort label-6514
SELECT DISTINCT col1 * CAST ( 79 AS INTEGER ) + cor0.col1 AS col0 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT ALL + col0 * - ( + col2 ) + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL + + cor0.col1 * cor0.col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + cor0.col1 + col1 - col0 FROM tab0 AS cor0
----
148
159
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6518
SELECT + col1 + CAST( NULL AS SIGNED ) / - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6518
SELECT + col1 + CAST ( NULL AS INTEGER ) / - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 * + 81 AS col0 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT col2 + col1 * + col1 AS col0 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT - ( col1 ) * tab1.col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - 28 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to eac00a95d734c7071360ed392c3f39bc

query I rowsort
SELECT + col0 * ( - col1 ) * col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - col2 * col0 * - 39 FROM tab2 AS cor0
----
117078
7371
79092

query I rowsort
SELECT 23 * col1 AS col2 FROM tab1
----
230
299
598

query I rowsort
SELECT cor0.col0 - + col0 * col2 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT + 28 + + col0 * - cor0.col0 FROM tab0 cor0
----
-1197
-548
-7893

onlyif mysql # use DIV operator for integer division
query I rowsort label-6528
SELECT - 9 DIV col1 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6528
SELECT - 9 / col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( 13 ) * - col0 AS col0 FROM tab1 AS cor0
----
1040
39
832

query I rowsort
SELECT + col2 + 42 + col1 FROM tab2 cor0
----
100
127
97

query I rowsort
SELECT + ( - 1 ) * col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + - col1 * col1 * - col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT - col0 * + ( + col2 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

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 ALL - col1 + + col0 * col0 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT ALL - col1 * + 34 AS col2 FROM tab2 AS cor0
----
-1054
-2006
-578

query I rowsort
SELECT - col0 * - col0 + - col1 - + col2 * col2 * col1 AS col1 FROM tab2 AS cor0
----
-18324
-22581
-33859

query I rowsort
SELECT + tab0.col0 + - col2 AS col2 FROM tab0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col1 * - col0 col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT col0 + - col0 * col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT - col2 + 1 FROM tab2
----
-25
-26
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 71 ) * - col2 col0 FROM tab1
----
3834
4047
6816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6543
SELECT CAST( NULL AS SIGNED ) + + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6543
SELECT CAST ( NULL AS INTEGER ) + + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 3 + - col1 * col2 + cor0.col1 * col1 AS col2 FROM tab0 cor0
----
4561
822
9315

onlyif mysql # use DIV operator for integer division
query I rowsort label-6545
SELECT + - cor0.col2 DIV - col1 + + ( - cor0.col0 ) col1 FROM tab1 cor0
----
-1
-59
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6545
SELECT + - cor0.col2 / - col1 + + ( - cor0.col0 ) col1 FROM tab1 cor0
----
-1
-59
-73

query I rowsort
SELECT + - col1 + col1 * 92 - - col1 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT DISTINCT - 92 * + col2 + - col0 FROM tab1 AS cor0
----
-4971
-5308
-8912

query I rowsort
SELECT ALL - 78 FROM tab2, tab2 AS cor0
----
9 values hashing to b6e4cc21599216686f0cf45b85668b2c

query I rowsort
SELECT + 98 * + 49 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2db2bfb9a46db4da81061e8988c53f51

query I rowsort
SELECT ALL + cor1.col0 + - 82 * + cor0.col0 * cor1.col2 - + 85 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 22429d9c7aa42b703cf8a395b71ee33a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6551
SELECT - CAST( - cor0.col0 AS SIGNED ) FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif mysql # not compatible
query I rowsort label-6551
SELECT - CAST ( - cor0.col0 AS INTEGER ) FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-6552
SELECT + col0 - + cor0.col1 DIV + 27 FROM tab0 AS cor0
----
21
32
86

skipif mysql # not compatible
query I rowsort label-6552
SELECT + col0 - + cor0.col1 / + 27 FROM tab0 AS cor0
----
21
32
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 + col0 col0 FROM tab1 AS cor0
----
159
175
98

query I rowsort
SELECT + - 11 + + col1 FROM tab0 AS cor0
----
75
80
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-6555
SELECT ALL + 85 DIV + 90 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-6555
SELECT ALL + 85 / + 90 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT col2 * + col2 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT 24 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
24

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to e3f81e329d34d83e4528a9ef7b933946

query I rowsort
SELECT 12 AS col2 FROM tab0 AS cor0
----
12
12
12

query I rowsort
SELECT ALL col2 * + 12 + cor0.col0 * - col1 AS col1 FROM tab2 AS cor0
----
-4290
-887
107

query I rowsort
SELECT col1 * 31 FROM tab1 AS cor0
----
310
403
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6562
SELECT + ( cor0.col0 ) * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6562
SELECT + ( cor0.col0 ) * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
3
64
80

query I rowsort
SELECT cor0.col0 AS col0 FROM tab1, tab1 AS cor0, tab2 cor1, tab1 AS cor2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT - - col0 * + 43 FROM tab0 AS cor0
----
1032
1505
3827

query I rowsort
SELECT ALL + col2 + ( + col0 ) * + col0 AS col2 FROM tab0 cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-6567
SELECT ALL + col2 * - 25 + - col0 * col1 DIV - col2 + + col0 * + col1 FROM tab1 AS cor0
----
-1271
-1350
-774

skipif mysql # not compatible
query I rowsort label-6567
SELECT ALL + col2 * - 25 + - col0 * col1 / - col2 + + col0 * + col1 FROM tab1 AS cor0
----
-1271
-1350
-774

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6568
SELECT ALL + CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6568
SELECT ALL + CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col2 * - col2 + 80 + col1 AS col0 FROM tab1 AS cor0
----
-2810
-3159
-9123

query I rowsort
SELECT DISTINCT - col2 * + 99 FROM tab1 AS cor0
----
-5346
-5643
-9504

query I rowsort
SELECT - - cor0.col0 + - ( + col0 * + col1 ) + 50 * + col2 AS col2 FROM tab1 AS cor0
----
2274
2625
3840

query I rowsort
SELECT col1 - col0 * + col0 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT ALL col0 + tab0.col2 * - 56 AS col1 FROM tab0
----
-1824
-21
-4503

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6574
SELECT DISTINCT col1 + - col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6574
SELECT DISTINCT col1 + - col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6575
SELECT col0 * + CAST( NULL AS SIGNED ) + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6575
SELECT col0 * + CAST ( NULL AS INTEGER ) + col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab0.col1 * + col0 * - col1 AS col0 FROM tab0
----
-177504
-329315
-737009

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 61c64d7c972af4105004f57e1913df08

query I rowsort
SELECT col1 * 19 + cor0.col0 FROM tab2 AS cor0
----
1199
402
596

query I rowsort
SELECT DISTINCT col1 + - 44 + 44 * + col2 * + ( - 52 * col2 ) AS col2 FROM tab1 cor0
----
-21086239
-6671826
-7433746

query I rowsort
SELECT DISTINCT + col0 * col2 * col1 + col2 AS col2 FROM tab1 cor0
----
36537
4266
99936

query I rowsort
SELECT DISTINCT - col2 * + 9 + + cor0.col2 + - col0 * + 54 AS col1 FROM tab0 AS cor0
----
-1560
-1898
-5462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * cor0.col2 + col1 col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL + ( col0 ) - col0 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col0 - - col1 * + col2 * - 50 FROM tab0
----
-141924
-373189
-4885

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab0, tab0 cor1
----
972 values hashing to b2fa3f9d060540fe1eb4ad1c0754e163

query I rowsort
SELECT - 66 + - cor0.col1 FROM tab2 AS cor0
----
-125
-83
-97

query I rowsort
SELECT - cor0.col2 - + 87 * - col1 AS col2 FROM tab2 AS cor0
----
1441
2670
5107

query I rowsort
SELECT - - 90 + col1 FROM tab0 AS cor0
----
176
181
187

query I rowsort
SELECT + ( + col0 ) * - col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT ( - col2 ) - col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL col0 + - col2 * - col1 AS col1 FROM tab1 AS cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * col0 - - col1 col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + 75 + - col2 AS col0 FROM tab0
----
-7
42
74

query I rowsort
SELECT 81 * + col2 + col1 FROM tab0 AS cor0
----
178
2759
6733

query I rowsort
SELECT ALL + 74 * col2 - + col1 AS col2 FROM tab0 AS cor0
----
-23
2356
5977

onlyif mysql # use DIV operator for integer division
query I rowsort label-6596
SELECT + + col2 - - col0 DIV col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6596
SELECT + + col2 - - col0 / col1 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - col1 + col2 * 70 AS col2 FROM tab1 AS cor0
----
3754
3980
6707

query I rowsort
SELECT DISTINCT + col1 - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL cor0.col0 FROM tab0, tab0 AS cor0 WHERE NULL <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6600
SELECT DISTINCT + - 1 DIV cor0.col0 + + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6600
SELECT DISTINCT + - 1 / cor0.col0 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) FROM tab0, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - + col1 * - col1 - + 60 AS col2 FROM tab1 AS cor0
----
109
40
616

query I rowsort
SELECT cor0.col0 * cor0.col0 * 3 - + col0 AS col2 FROM tab1 AS cor0
----
12224
19120
24

query I rowsort
SELECT col0 + - cor0.col2 * col2 + cor0.col0 * col0 FROM tab2 AS cor0
----
-673
4876
5486

query I rowsort
SELECT DISTINCT cor0.col1 * col1 + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + - col1 * + col1 + 59 AS col2 FROM tab0 AS cor0
----
-7337
-8222
-9350

query I rowsort
SELECT DISTINCT - - col1 + 17 FROM tab0 AS cor0
----
103
108
114

query I rowsort
SELECT DISTINCT + + col1 + + col1 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 78 col2 FROM tab2 AS cor0
----
19
47
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-6610
SELECT DISTINCT - col2 DIV + col2 + - col0 + + col1 AS col0 FROM tab1 AS cor0
----
-55
-68
22

skipif mysql # not compatible
query I rowsort label-6610
SELECT DISTINCT - col2 / + col2 + - col0 + + col1 AS col0 FROM tab1 AS cor0
----
-55
-68
22

query I rowsort
SELECT - col1 + + col2 * + col2 - - col1 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-6612
SELECT DISTINCT col0 DIV ( + col0 ) FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6612
SELECT DISTINCT col0 / ( + col0 ) FROM tab0 AS cor0
----
1

query I rowsort
SELECT col0 + cor0.col0 AS col2 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL col1 + col2 * + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL 57 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT - col1 + - ( col1 ) * ( - col0 ) * col0 AS col0 FROM tab2 AS cor0
----
106080
1488
358897

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab0 cor1, tab2, tab1 AS cor2
----
3645 values hashing to ae08f1949fd59e00b049f28175217e60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 * - col1 col0 FROM tab1 AS cor0
----
-1664
-640
-832

query I rowsort
SELECT + + col1 * 80 AS col1 FROM tab1 cor0
----
1040
2080
800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 22 * col0 + - col1 col1 FROM tab2 AS cor0
----
-1755
-1775
-185

query I rowsort
SELECT ALL ( - col0 ) + - col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col2 * - ( col1 ) AS col0 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6625
SELECT - ( col2 ) + col0 DIV + col1 AS col1 FROM tab1
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-6625
SELECT - ( col2 ) + col0 / + col1 AS col1 FROM tab1
----
-51
-54
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 + + col2 col2 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 col1 FROM tab1
----
3
3
3

query I rowsort
SELECT DISTINCT col2 * - ( + col1 ) AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT 19 + tab2.col2 FROM tab2
----
45
46
57

query I rowsort
SELECT DISTINCT 93 * + col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
5025
5365
9008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * col1 + + 60 col0 FROM tab1 AS cor0
----
1308
1464
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-6632
SELECT ALL col0 DIV + tab2.col1 AS col2 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6632
SELECT ALL col0 / + tab2.col1 AS col2 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + tab2.col1 * + col0 col1 FROM tab2
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-6634
SELECT col2 DIV + 27 FROM tab1 AS cor0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-6634
SELECT col2 / + 27 FROM tab1 AS cor0
----
2
2
3

query I rowsort
SELECT ALL cor0.col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL + + 33 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6637
SELECT DISTINCT - col1 DIV 58 AS col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-6637
SELECT DISTINCT - col1 / 58 AS col0 FROM tab0
----
-1

query I rowsort
SELECT + ( + 28 ) FROM tab2
----
28
28
28

query I rowsort
SELECT cor0.col2 + col2 * + col1 FROM tab1 AS cor0
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - tab0.col2 ) col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - + cor0.col1 * - col1 - - col0 * col0 * col0 AS col2 FROM tab0 AS cor0
----
21220
52284
713250

onlyif mysql # use DIV operator for integer division
query I rowsort label-6642
SELECT col1 DIV + cor0.col0 + - col0 * + 22 AS col0 FROM tab1 AS cor0
----
-1408
-1760
-58

skipif mysql # not compatible
query I rowsort label-6642
SELECT col1 / + cor0.col0 + - col0 * + 22 AS col0 FROM tab1 AS cor0
----
-1408
-1760
-58

query I rowsort
SELECT DISTINCT 22 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
22

query I rowsort
SELECT 67 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT DISTINCT - tab1.col0 * + col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT 75 + + col2 FROM tab2
----
101
102
113

query I rowsort
SELECT col2 * - col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT - col0 - - 35 * + ( col0 ) * - col2 FROM tab2
----
-105149
-6622
-71058

query I rowsort
SELECT ALL + ( ( - cor0.col2 ) ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT tab1.col0 * - col2 + + col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT + + col2 + 98 * ( col0 ) FROM tab0 cor0
----
2385
3431
8804

query I rowsort
SELECT + + col1 * col2 * cor0.col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT ALL + col0 + cor0.col1 - - col2 FROM tab2 AS cor0
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - ( + col2 ) + 33 * col0 * - col0 col2 FROM tab0 AS cor0
----
-16170
-253931
-40328

query I rowsort
SELECT DISTINCT - 9 + + cor0.col1 FROM tab0 AS cor0
----
77
82
88

query I rowsort
SELECT DISTINCT + col1 - + cor0.col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6657
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 44 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6657
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 44 FROM tab2 cor0
----
NULL

query I rowsort
SELECT - 12 - col1 AS col0 FROM tab2 AS cor0
----
-29
-43
-71

query I rowsort
SELECT ALL col1 + - col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col2 * + col0 + - col2 FROM tab2 cor0
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6661
SELECT DISTINCT + col1 + ( + col0 ) * + CAST( + 24 + col2 AS SIGNED ) FROM tab0 cor0
----
1454
9525
972

skipif mysql # not compatible
query I rowsort label-6661
SELECT DISTINCT + col1 + ( + col0 ) * + CAST ( + 24 + col2 AS INTEGER ) FROM tab0 cor0
----
1454
9525
972

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + col2 AS col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT + 3 * + col0 AS col2 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT ALL + ( cor0.col0 ) - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL col2 * - col1 + col2 * col0 * + col2 FROM tab2 AS cor0
----
113430
4266
51194

query I rowsort
SELECT - tab1.col2 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6667
SELECT - col1 * - col0 + + CAST( + col0 + + col1 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
165
5376
8480

skipif mysql # not compatible
query I rowsort label-6667
SELECT - col1 * - col0 + + CAST ( + col0 + + col1 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
165
5376
8480

query I rowsort
SELECT - + col0 + - col1 * ( col1 + - col2 ) AS col1 FROM tab1 AS cor0
----
406
725
999

query I rowsort
SELECT col2 + col0 + - col1 AS col1 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT - - ( col2 ) * col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + ( col0 * + col2 ) FROM tab1
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6672
SELECT DISTINCT CAST( 31 AS SIGNED ) AS col0 FROM tab2
----
31

skipif mysql # not compatible
query I rowsort label-6672
SELECT DISTINCT CAST ( 31 AS INTEGER ) AS col0 FROM tab2
----
31

query I rowsort
SELECT ALL 25 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

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 + 84 * - tab2.col2 FROM tab2, tab2 AS cor0
----
-2184
-2268
-3192

query I rowsort
SELECT + 60 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-18
-19
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-6677
SELECT DISTINCT - col1 DIV + col0 AS col2 FROM tab1 AS cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-6677
SELECT DISTINCT - col1 / + col0 AS col2 FROM tab1 AS cor0
----
-8
0

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT ALL 11 * - col1 * + ( col1 + + tab2.col1 ) AS col2 FROM tab2
----
-21142
-6358
-76582

query I rowsort
SELECT DISTINCT - + col0 + 85 * col2 * + col1 AS col0 FROM tab2 AS cor0
----
130312
54831
71138

query I rowsort
SELECT col0 * 51 AS col0 FROM tab1 cor0
----
153
3264
4080

query I rowsort
SELECT - 65 + - col2 FROM tab2
----
-103
-91
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6683
SELECT ALL + + cor0.col1 DIV + col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6683
SELECT ALL + + cor0.col1 / + col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col0 * col2 + + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + col2 * + col2 AS col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT col2 - tab0.col2 FROM tab0
----
0

query I rowsort
SELECT ALL - cor0.col0 * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6688
SELECT - col0 DIV col2 + col1 DIV + col1 AS col0 FROM tab0 AS cor0
----
-34
0
1

skipif mysql # not compatible
query I rowsort label-6688
SELECT - col0 / col2 + col1 / + col1 AS col0 FROM tab0 AS cor0
----
-34
0
1

query I rowsort
SELECT DISTINCT + col2 + + col0 AS col1 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6690
SELECT ALL col0 + col1 DIV col0 AS col1 FROM tab0 cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-6690
SELECT ALL col0 + col1 / col0 AS col1 FROM tab0 cor0
----
27
37
90

query I rowsort
SELECT DISTINCT col2 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col2 * col1 * - col1 AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT + col2 NOT BETWEEN + col2 AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 * col0 col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL - col0 + + col2 + tab1.col2 AS col1 FROM tab1
----
105
112
50

query I rowsort
SELECT ALL col0 FROM tab0 WHERE NULL <= NULL
----

query I rowsort
SELECT DISTINCT col0 * tab1.col2 FROM tab1 WHERE NOT NULL NOT BETWEEN ( col1 ) AND NULL
----

query I rowsort
SELECT + col1 * + col0 * col0 + col0 FROM tab2 AS cor0
----
106176
1526
359034

query I rowsort
SELECT col0 + - tab1.col2 * + col1 AS col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT tab0.col1 + - tab0.col1 + col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT col1 + + col2 * + col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT col2 * - col2 + col2 + col0 AS col1 FROM tab2
----
-1327
-572
-695

query I rowsort
SELECT ( - col2 + - col1 ) AS col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT ALL + - cor0.col2 * + col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL 49 FROM tab0
----
49
49
49

query I rowsort
SELECT 10 - + col0 * - col0 FROM tab0
----
1235
586
7931

query I rowsort
SELECT ALL tab0.col2 * tab0.col1 - col0 AS col0 FROM tab0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col2 * col1 + col1 * - col1 * - col0 - - col2 col1 FROM tab1
----
-2130
-30023
-86224

query I rowsort
SELECT + col0 + col2 * tab0.col0 AS col1 FROM tab0
----
70
7387
816

query I rowsort
SELECT + col2 * - col1 + + tab1.col1 * col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT tab2.col0 - - col2 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT col1 - - col1 * - col1 * col1 FROM tab1
----
-17550
-2184
-990

onlyif mysql # use DIV operator for integer division
query I rowsort label-6713
SELECT col0 DIV col0 + col1 + + col2 FROM tab0
----
120
174
99

skipif mysql # not compatible
query I rowsort label-6713
SELECT col0 / col0 + col1 + + col2 FROM tab0
----
120
174
99

query I rowsort
SELECT ALL col2 - col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + tab2.col2 * + col0 - col1 * col1 AS col1 FROM tab2
----
-1375
-765
2792

query I rowsort
SELECT + tab2.col0 + - tab2.col0 - + col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-6718
SELECT ALL + col2 DIV col1 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6718
SELECT ALL + col2 / col1 + col1 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6719
SELECT col0 DIV col1 FROM tab2 WHERE col1 BETWEEN + col1 * - col0 AND ( col0 )
----
1
4

skipif mysql # not compatible
query I rowsort label-6719
SELECT col0 / col1 FROM tab2 WHERE col1 BETWEEN + col1 * - col0 AND ( col0 )
----
1
4

query I rowsort
SELECT col0 AS col2 FROM tab2 WHERE NOT col2 >= ( NULL )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL IN ( + col0 * col2 + - col0 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6722
SELECT + col0 + col0 DIV col1 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-6722
SELECT + col0 + col0 / col1 FROM tab2
----
7
79
83

query I rowsort
SELECT ALL col2 * col0 + + col0 * - col2 AS col0 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT + tab0.col0 + - col2 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT + col2 * - col0 - - col2 AS col1 FROM tab0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6726
SELECT ALL cor0.col0 DIV cor0.col0 + ( col0 ) FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-6726
SELECT ALL cor0.col0 / cor0.col0 + ( col0 ) FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col1 AS col1 FROM tab0, tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col2 * col1 + - col0 * + 60 AS col1 FROM tab0 AS cor0
----
-2003
1398
2122

query I rowsort
SELECT ALL + col0 * + col1 AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT + - col2 - col0 * col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT - - 48 + + col1 * ( col1 ) FROM tab2 cor0
----
1009
337
3529

query I rowsort
SELECT DISTINCT + - col2 - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6733
SELECT DISTINCT + cor0.col1 DIV col2 + + ( 59 * col0 ) FROM tab0 AS cor0
----
1418
2162
5252

skipif mysql # not compatible
query I rowsort label-6733
SELECT DISTINCT + cor0.col1 / col2 + + ( 59 * col0 ) FROM tab0 AS cor0
----
1418
2162
5252

query I rowsort
SELECT col1 AS col2 FROM tab2 WHERE NOT col2 * + col0 * + col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL + cor0.col2 * - col0 * col2 + - col1 FROM tab2 AS cor0 WHERE col0 NOT IN ( + col0 )
----

query I rowsort
SELECT ALL + tab1.col1 + col2 AS col1 FROM tab1 WHERE NOT NULL IN ( col0 - col0 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) = - col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col2 * - tab0.col0 col2 FROM tab0
----
132
7389
878

query I rowsort
SELECT col1 * col2 * col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6740
SELECT ALL + col1 * + cor0.col0 - col2 DIV col0 FROM tab2 AS cor0
----
1343
214
4602

skipif mysql # not compatible
query I rowsort label-6740
SELECT ALL + col1 * + cor0.col0 - col2 / col0 FROM tab2 AS cor0
----
1343
214
4602

query I rowsort
SELECT col0 + + col2 * - cor0.col1 * + col1 FROM tab1 cor0
----
-16144
-36501
-5636

query I rowsort
SELECT tab2.col0 + col0 * + col1 + col0 FROM tab2
----
1501
231
4758

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 * col0 col0 FROM tab0
----
34
7216
759

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 BETWEEN + col1 AND NULL
----

query I rowsort
SELECT DISTINCT + col2 * col0 AS col0 FROM tab2 WHERE ( NULL ) NOT IN ( col1 * col0 + + col1 )
----

query I rowsort
SELECT + col2 AS col2 FROM tab2 WHERE NOT NULL IN ( + col2 + tab2.col1 + + tab2.col1 )
----

query I rowsort
SELECT col1 + col1 - col2 * + col0 AS col2 FROM tab1
----
-110
-3628
-7654

query I rowsort
SELECT col2 + - col1 * col2 AS col0 FROM tab0 WHERE NULL NOT IN ( tab0.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 * + col2 + + col2 * col2 col1 FROM tab0
----
2
37026
558092

query I rowsort
SELECT + col2 + col2 - col0 * col0 AS col2 FROM tab2
----
-6032
-6165
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6751
SELECT + - 14 DIV + col0 col1 FROM tab1 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6751
SELECT + - 14 / + col0 col1 FROM tab1 AS cor0
----
-4
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6752
SELECT + 29 DIV col0 AS col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6752
SELECT + 29 / col0 AS col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + 16 * 92 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e6ac755483c68c1e47bf33c2df8b85d8

query I rowsort
SELECT DISTINCT 88 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
88

query I rowsort
SELECT DISTINCT - + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col2 * - col2 col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT 7 * col0 AS col2 FROM tab0
----
168
245
623

query I rowsort
SELECT ALL - 17 + col2 AS col1 FROM tab1
----
37
40
79

query I rowsort
SELECT ALL - tab1.col2 + + col1 * + col0 AS col2 FROM tab1
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6760
SELECT ALL - col1 DIV - col2 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6760
SELECT ALL - col1 / - col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - col2 + col1 * col0 AS col2 FROM tab0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-6762
SELECT col0 + col0 DIV col0 AS col1 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6762
SELECT col0 + col0 / col0 AS col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT + col2 * - cor0.col2 + + col0 AS col1 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT col0 + 37 * col2 FROM tab0
----
1245
3123
72

query I rowsort
SELECT col1 + col2 * 14 FROM tab0 AS cor0
----
111
1239
548

query I rowsort
SELECT col2 + - col0 * + 58 * + col1 AS col2 FROM tab0
----
-119679
-196909
-469660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6767
SELECT col0 * + CAST( NULL AS SIGNED ) col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6767
SELECT col0 * + CAST ( NULL AS INTEGER ) col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + 40 * - col0 FROM tab1
----
-117
-2496
-3120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 * col1 col0 FROM tab0 AS cor0
----
-8342
-8827
-9409

query I rowsort
SELECT ALL 65 * 0 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + col2 * col1 + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT 3 AS col2 FROM tab0 AS cor0
----
3

query I rowsort
SELECT ALL - col1 + 6 AS col0 FROM tab0 AS cor0
----
-80
-85
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6774
SELECT + + CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6774
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 DISTINCT col0 * + col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL 98 + + col1 FROM tab1
----
108
111
124

query I rowsort
SELECT 43 + cor0.col2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f5b9c651a64695b6d95098cca3706947

query I rowsort
SELECT + tab1.col0 AS col2 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + 65 * - col2 FROM tab2 AS cor0
----
-1690
-1755
-2470

onlyif mysql # use DIV operator for integer division
query I rowsort label-6780
SELECT ( col2 ) + cor0.col1 DIV col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-6780
SELECT ( col2 ) + cor0.col1 / col2 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT col2 * + 42 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT ALL - 29 + col0 AS col0 FROM tab0
----
-5
6
60

query I rowsort
SELECT ALL + cor0.col0 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL + 17 * col0 + col1 AS col1 FROM tab0 AS cor0
----
1604
494
692

query I rowsort
SELECT DISTINCT + 51 * + cor0.col1 FROM tab0 AS cor0
----
4386
4641
4947

query I rowsort
SELECT DISTINCT + - 2 AS col0 FROM tab0 AS cor0
----
-2

query I rowsort
SELECT 2 * + col1 + cor0.col0 FROM tab2 AS cor0
----
113
196
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col1 + - col2 col1 FROM tab2 cor0
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 2 col1 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT + - col0 + col0 + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col2 + - col0 * col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL - col0 * col1 - col2 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + cor0.col0 * 23 + + col0 AS col2 FROM tab2 AS cor0
----
168
1872
1896

query I rowsort
SELECT - + col2 * col0 + col0 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6795
SELECT - col2 + CAST( NULL AS SIGNED ) * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6795
SELECT - col2 + CAST ( NULL AS INTEGER ) * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 54 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT col1 * - col0 - - col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - col2 + - ( col1 * + col2 ) - + cor0.col2 FROM tab2 AS cor0
----
-1586
-722
-891

query I rowsort
SELECT + - cor0.col0 + - 53 - col0 FROM tab2 AS cor0
----
-209
-211
-67

query I rowsort
SELECT - + 54 + + col1 * col1 FROM tab0 AS cor0
----
7342
8227
9355

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col2 AS REAL ) + + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL - col2 * - ( col1 ) AS col0 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT col2 - + col1 * col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT - cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 7f0405f8197238fbd342972ef0bcee12

query I rowsort
SELECT DISTINCT - + col0 * - ( - col0 ) AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6807
SELECT ALL + + col2 DIV - cor0.col2 AS col1 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6807
SELECT ALL + + col2 / - cor0.col2 AS col1 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 59 AS col0 FROM tab1 AS cor0
----
-59

query I rowsort
SELECT ALL ( col1 ) * + col0 + - ( ( - col1 ) ) + - 70 * - col0 AS col0 FROM tab0 AS cor0
----
14420
3830
5942

onlyif mysql # use DIV operator for integer division
query I rowsort label-6810
SELECT ALL + 15 DIV - col1 AS col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6810
SELECT ALL + 15 / - col1 AS col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT - col2 * + col1 - cor0.col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL - - col2 + 89 FROM tab1 cor0
----
143
146
185

query I rowsort
SELECT DISTINCT - col2 * - 64 + col0 FROM tab1 cor0
----
3459
3712
6224

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL - 54 * col2 - - col1 FROM tab1 AS cor0
----
-2890
-3068
-5171

query I rowsort
SELECT - + 76 + col1 + col0 AS col0 FROM tab2 AS cor0
----
-38
20
61

query I rowsort
SELECT ALL + - 46 * ( col2 ) * + 87 AS col1 FROM tab1 AS cor0
----
-216108
-228114
-384192

query I rowsort
SELECT ALL + + col2 + + col0 * - col1 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + col1 + col0 * col2 AS col2 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT - + col1 * - col2 + - col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT - col1 * - 50 - - ( col1 ) AS col1 FROM tab2
----
1581
3009
867

query I rowsort
SELECT ALL + col1 * + ( col0 ) * + col1 - ( col0 ) AS col1 FROM tab0
----
177480
329280
736920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6823
SELECT + col1 DIV - ( + tab1.col2 ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6823
SELECT + col1 / - ( + tab1.col2 ) FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + + col2 + - col0 * col2 AS col1 FROM tab1 cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 30 AS REAL ) + col0 AS col0 FROM tab1 AS cor0
----
-27
34
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6826
SELECT ALL + col0 * - col0 * col2 + - col2 DIV col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

skipif mysql # not compatible
query I rowsort label-6826
SELECT ALL + col0 * - col0 * col2 + - col2 / col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-6827
SELECT + + col1 * + cor0.col1 + + col0 DIV - cor0.col1 col2 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6827
SELECT + + col1 * + cor0.col1 + + col0 / - cor0.col1 col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - + 16 AS col0 FROM tab1 cor0
----
-16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6829
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab1, tab0 cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6829
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab1, tab0 cor0, tab0 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6830
SELECT ALL col0 DIV + col1 AS col1 FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-6830
SELECT ALL col0 / + col1 AS col1 FROM tab1 cor0
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 45 col0 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT - + 47 + - col2 AS col1 FROM tab2 AS cor0
----
-73
-74
-85

query I rowsort
SELECT - - col1 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6834
SELECT ALL - CAST( + col2 AS SIGNED ) FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6834
SELECT ALL - CAST ( + col2 AS INTEGER ) FROM tab2
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6835
SELECT DISTINCT + 48 + - col1 DIV 97 AS col0 FROM tab2 cor0
----
48

skipif mysql # not compatible
query I rowsort label-6835
SELECT DISTINCT + 48 + - col1 / 97 AS col0 FROM tab2 cor0
----
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6836
SELECT ALL - - col1 + col0 * CAST( cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
1322
662
8012

skipif mysql # not compatible
query I rowsort label-6836
SELECT ALL - - col1 + col0 * CAST ( cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6837
SELECT 27 * col1 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6837
SELECT 27 * col1 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + cor0.col0 * + ( col1 ) FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT ALL + + col2 + ( 97 ) + col1 AS col0 FROM tab0 AS cor0
----
195
216
270

onlyif mysql # use DIV operator for integer division
query I rowsort label-6840
SELECT col0 DIV tab2.col0 - + ( - 84 ) FROM tab2
----
85
85
85

skipif mysql # not compatible
query I rowsort label-6840
SELECT col0 / tab2.col0 - + ( - 84 ) FROM tab2
----
85
85
85

query I rowsort
SELECT ALL - + cor1.col2 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
243 values hashing to b98cc07e6d63e3c0583ed19f9e9ad2be

onlyif mysql # use DIV operator for integer division
query I rowsort label-6842
SELECT ALL - col1 * + ( + col2 ) + col1 DIV - CAST( col0 * - col0 AS SIGNED ) AS col2 FROM tab2 cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-6842
SELECT ALL - col1 * + ( + col2 ) + col1 / - CAST ( col0 * - col0 AS INTEGER ) AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT 92 AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL tab1.col0 * + 99 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 4fa436db38e67fdfeb6031ee264392cb

query I rowsort
SELECT ALL + col2 * + col2 * col2 FROM tab0
----
1
35937
551368

query I rowsort
SELECT DISTINCT col0 * col0 * + 79 FROM tab2
----
3871
480636
493039

query I rowsort
SELECT col0 + + ( + col1 ) AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT col2 * - ( col2 ) FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + col2 + + ( 98 ) AS col1 FROM tab2 AS cor0
----
124
125
136

onlyif mysql # use DIV operator for integer division
query I rowsort label-6850
SELECT - col0 + col2 + + col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-6
17
52

skipif mysql # not compatible
query I rowsort label-6850
SELECT - col0 + col2 + + col0 / col0 AS col2 FROM tab1 AS cor0
----
-6
17
52

query I rowsort
SELECT - col0 * - 90 + - col2 * cor0.col1 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-234
5460
6426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + cor0.col0 * 84 col0 FROM tab2 AS cor0
----
561
6526
6598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col0 * + col2 col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL col2 + + col1 * - col0 + + col2 AS col1 FROM tab1 cor0
----
-526
-848
30

query I rowsort
SELECT DISTINCT + cor0.col1 * - col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL 6 + 79 FROM tab1
----
85
85
85

query I rowsort
SELECT + ( + ( col1 ) ) AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + ( - col0 * col2 ) + + col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT + 39 * + ( col2 ) + ( col0 ) AS col1 FROM tab0
----
1311
3287
74

query I rowsort
SELECT col1 + + col0 * + col1 AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT - 47 + - col2 AS col0 FROM tab2
----
-73
-74
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6862
SELECT DISTINCT 25 - tab2.col2 * - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6862
SELECT DISTINCT 25 - tab2.col2 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6863
SELECT DISTINCT cor0.col0 DIV 10 AS col1 FROM tab0, tab1 AS cor0
----
0
6
8

skipif mysql # not compatible
query I rowsort label-6863
SELECT DISTINCT cor0.col0 / 10 AS col1 FROM tab0, tab1 AS cor0
----
0
6
8

query I rowsort
SELECT 78 * col2 + - ( - col2 + + col0 * 51 ) AS col2 FROM tab1
----
1239
3504
4113

query I rowsort
SELECT col0 * - col2 * 50 FROM tab2
----
-101400
-150100
-9450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * col0 col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6867
SELECT DISTINCT + ( col2 ) * 81 + ( + cor0.col2 ) DIV col2 + 76 * + col2 * CAST( + col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
16687
281866
591457

skipif mysql # not compatible
query I rowsort label-6867
SELECT DISTINCT + ( col2 ) * 81 + ( + cor0.col2 ) / col2 + 76 * + col2 * CAST ( + col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
16687
281866
591457

query I rowsort
SELECT 95 * - col2 + 60 FROM tab2 AS cor0
----
-2410
-2505
-3550

onlyif mysql # use DIV operator for integer division
query I rowsort label-6869
SELECT DISTINCT col0 * - col2 + ( - col0 ) DIV col0 AS col1 FROM tab2 AS cor0
----
-190
-2029
-3003

skipif mysql # not compatible
query I rowsort label-6869
SELECT DISTINCT col0 * - col2 + ( - col0 ) / col0 AS col1 FROM tab2 AS cor0
----
-190
-2029
-3003

query I rowsort
SELECT cor0.col1 * - col2 + 2 FROM tab1 AS cor0
----
-1246
-1402
-568

query I rowsort
SELECT 37 + col0 * col0 AS col1 FROM tab1 AS cor0
----
4133
46
6437

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6872
SELECT - col2 + + 34 * - col0 * + CAST( - col1 * col0 AS SIGNED ) FROM tab0 AS cor0
----
1684191
24507492
4040049

skipif mysql # not compatible
query I rowsort label-6872
SELECT - col2 + + 34 * - col0 * + CAST ( - col1 * col0 AS INTEGER ) FROM tab0 AS cor0
----
1684191
24507492
4040049

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6873
SELECT + CAST( col2 AS SIGNED ) FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6873
SELECT + CAST ( col2 AS INTEGER ) FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - 94 * col1 FROM tab1 AS cor0
----
-1222
-2444
-940

query I rowsort
SELECT - 89 + + col1 * cor0.col0 FROM tab0 cor0
----
1975
3306
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col2 * - 8 col2 FROM tab2
----
-208
-216
-304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 col1 FROM tab1 AS cor0
----
36
36
36

query I rowsort
SELECT + col1 + ( - col2 ) AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT col0 * 43 AS col1 FROM tab0 AS cor0
----
1032
1505
3827

onlyif mysql # use DIV operator for integer division
query I rowsort label-6880
SELECT + col2 * 75 + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
172
2477
6151

skipif mysql # not compatible
query I rowsort label-6880
SELECT + col2 * 75 + col1 / col2 AS col0 FROM tab0 AS cor0
----
172
2477
6151

query I rowsort
SELECT DISTINCT 82 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
82

query I rowsort
SELECT ALL col0 * - 32 FROM tab1
----
-2048
-2560
-96

query I rowsort
SELECT col0 + - 73 AS col0 FROM tab2 AS cor0
----
-66
5
6

query I rowsort
SELECT ALL 46 + + col1 AS col2 FROM tab2 cor0
----
105
63
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-6885
SELECT 59 DIV + 28 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif mysql # not compatible
query I rowsort label-6885
SELECT 59 / + 28 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT DISTINCT - 29 AS col0 FROM tab2, tab2 cor0
----
-29

query I rowsort
SELECT + tab0.col0 * tab0.col2 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 * - 83 FROM tab2
----
-2158
-2241
-3154

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6889
SELECT + + CAST( + col0 AS SIGNED ) * + col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6889
SELECT + + CAST ( + col0 AS INTEGER ) * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col1 * 24 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT ALL - ( + col1 ) * col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col2 - ( col2 ) * + ( 78 ) AS col1 FROM tab0 AS cor0
----
-2607
-6478
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6893
SELECT DISTINCT 28 + + col0 DIV col1 FROM tab2 AS cor0
----
28
29
32

skipif mysql # not compatible
query I rowsort label-6893
SELECT DISTINCT 28 + + col0 / col1 FROM tab2 AS cor0
----
28
29
32

query I rowsort
SELECT - col2 + + cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT col2 - + tab0.col2 AS col0 FROM tab0
----
0

query I rowsort
SELECT col0 * col1 * + col0 AS col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT - 99 AS col2 FROM tab2, tab1 AS cor0
----
-99

query I rowsort
SELECT ALL - ( tab2.col0 ) * - col0 + - col0 FROM tab2
----
42
6006
6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-6899
SELECT DISTINCT col0 DIV + col1 + col0 AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6899
SELECT DISTINCT col0 / + col1 + col0 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - col1 * + col2 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6901
SELECT ALL tab0.col2 * col2 DIV + 20 FROM tab0
----
0
336
54

skipif mysql # not compatible
query I rowsort label-6901
SELECT ALL tab0.col2 * col2 / + 20 FROM tab0
----
0
336
54

query I rowsort
SELECT - col2 * col1 + col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT - col1 + + col2 * ( + col2 ) FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - ( col0 * - col2 ) AS col1 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 93 col1 FROM tab0
----
93
93
93

query I rowsort
SELECT - cor0.col1 - + 63 AS col2 FROM tab1 AS cor0
----
-73
-76
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6907
SELECT col0 + col0 DIV - col2 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-6907
SELECT col0 + col0 / - col2 col1 FROM tab1 AS cor0
----
3
63
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6908
SELECT DISTINCT + col0 - - col0 DIV col2 AS col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-6908
SELECT DISTINCT + col0 - - col0 / col2 AS col2 FROM tab0
----
24
70
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - cor0.col1 col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + cor0.col0 + - col1 - + cor0.col2 AS col1 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT ALL - col0 + ( col1 + col2 * col2 ) FROM tab2 AS cor0
----
1382
657
753

query I rowsort
SELECT + col1 + + cor0.col2 * cor0.col2 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-6913
SELECT + - col2 * CAST( - col0 AS SIGNED ) + col0 DIV col1 FROM tab2 AS cor0
----
189
2029
3006

skipif mysql # not compatible
query I rowsort label-6913
SELECT + - col2 * CAST ( - col0 AS INTEGER ) + col0 / col1 FROM tab2 AS cor0
----
189
2029
3006

query I rowsort
SELECT DISTINCT - - 99 + + col1 FROM tab0 AS cor0
----
185
190
196

onlyif mysql # use DIV operator for integer division
query I rowsort label-6915
SELECT DISTINCT - col1 DIV 65 AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6915
SELECT DISTINCT - col1 / 65 AS col2 FROM tab2
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6916
SELECT CAST( NULL AS DECIMAL ) * ( + col1 ) + - 68 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6916
SELECT CAST ( NULL AS REAL ) * ( + col1 ) + - 68 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( 85 + col0 ) AS col0 FROM tab0
----
109
120
174

query I rowsort
SELECT ( + col0 ) * - col0 + + 3 AS col2 FROM tab1
----
-4093
-6
-6397

query I rowsort
SELECT DISTINCT ( 51 ) AS col1 FROM tab0
----
51

query I rowsort
SELECT 89 + col2 * - col0 FROM tab0 cor0
----
-703
-7209
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-6921
SELECT ALL col0 * col1 + - 36 DIV + col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6921
SELECT ALL col0 * col1 + - 36 / + col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 - 93 AS col2 FROM tab2 AS cor0
----
-1436
-310
-4695

query I rowsort
SELECT ALL 28 + - col1 + cor0.col1 * - col1 FROM tab0 AS cor0
----
-7454
-8344
-9478

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col2 + + col1 col0 FROM tab1 AS cor0
----
-111
-163
-31

query I rowsort
SELECT DISTINCT - - 84 AS col0 FROM tab1 AS cor0
----
84

query I rowsort
SELECT DISTINCT - - cor0.col1 - col1 * 24 FROM tab2 AS cor0
----
-1357
-391
-713

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6927
SELECT DISTINCT - col1 * col0 * + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6927
SELECT DISTINCT - col1 * col0 * + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL + 39 + + col0 + - col2 AS col0 FROM tab1 AS cor0
----
-12
23
46

query I rowsort
SELECT - + 28 AS col0 FROM tab1 AS cor0
----
-28
-28
-28

query I rowsort
SELECT ALL tab0.col2 * 4 + col2 FROM tab0
----
165
410
5

query I rowsort
SELECT + col1 + + 91 + col0 FROM tab0
----
201
223
271

query I rowsort
SELECT + 34 * - cor0.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 084eb7f6d2e434c1a92d97f46838c084

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 + col1 * - col1 col2 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT - col2 * ( col0 + col2 ) AS col2 FROM tab0 AS cor0
----
-14022
-1881
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-6935
SELECT ALL + col2 + col1 * - cor0.col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-6935
SELECT ALL + col2 + col1 * - cor0.col0 / + col0 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + col2 + + col2 - col2 AS col2 FROM tab0 cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6937
SELECT - - cor0.col2 - - col1 DIV col0 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-6937
SELECT - - cor0.col2 - - col1 / col0 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT DISTINCT + col1 * 55 + - col2 AS col0 FROM tab0 AS cor0
----
4697
4923
5334

query I rowsort
SELECT 87 * 59 AS col0 FROM tab2 AS cor0
----
5133
5133
5133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 8 col1 FROM tab0 AS cor0
----
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6941
SELECT - - CAST( 52 AS SIGNED ) + + col0 * - col0 FROM tab0 AS cor0
----
-1173
-524
-7869

skipif mysql # not compatible
query I rowsort label-6941
SELECT - - CAST ( 52 AS INTEGER ) + + col0 * - col0 FROM tab0 AS cor0
----
-1173
-524
-7869

query I rowsort
SELECT DISTINCT ( col2 ) * col0 AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col0 + - col1 * col2 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT ( cor0.col1 ) + + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f65167375aa80cc8b3f3f8987d2662a3

query I rowsort
SELECT ALL 27 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 092918b9163061e291041d594b1a402a

query I rowsort
SELECT DISTINCT ( - 58 ) FROM tab0 AS cor0
----
-58

query I rowsort
SELECT 47 * - 38 FROM tab1 cor0
----
-1786
-1786
-1786

query I rowsort
SELECT ALL + 51 AS col0 FROM tab1 AS cor0
----
51
51
51

query I rowsort
SELECT + 71 * col1 + col2 AS col2 FROM tab1 AS cor0
----
1019
1900
767

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6950
SELECT ALL - col2 + - ( col2 ) * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6950
SELECT ALL - col2 + - ( col2 ) * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 16 AS col0 FROM tab2 cor0
----
-16
-16
-16

query I rowsort
SELECT ALL + col0 * - col0 * + col1 AS col1 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT + + col2 + + col2 * + col0 * - col0 AS col2 FROM tab2 cor0
----
-1296
-158158
-237120

query I rowsort
SELECT ALL col0 * - col2 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-6955
SELECT 44 DIV - col0 FROM tab2 AS cor0
----
-6
0
0

skipif mysql # not compatible
query I rowsort label-6955
SELECT 44 / - col0 FROM tab2 AS cor0
----
-6
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6956
SELECT - - col1 * col1 + col1 DIV - ( - col2 ) AS col2 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-6956
SELECT - - col1 * col1 + col1 / - ( - col2 ) AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - cor0.col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - cor0.col2 + 51 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3e4ae1ce69be15417fb93e656366d8a8

query I rowsort
SELECT + - col2 + col0 * - col1 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT - col2 + col2 * col2 - col0 FROM tab1 AS cor0
----
2859
3128
9040

query I rowsort
SELECT ALL + - col2 * 9 FROM tab0 cor0
----
-297
-738
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6962
SELECT - col1 + CAST( NULL AS SIGNED ) - - 10 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6962
SELECT - col1 + CAST ( NULL AS INTEGER ) - - 10 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 46 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col1 + 78 col0 FROM tab2
----
-1265
-139
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-6965
SELECT + col0 DIV col2 + - col0 * + col1 * + col2 + col1 * + col2 AS col1 FROM tab1
----
-2808
-35909
-98592

skipif mysql # not compatible
query I rowsort label-6965
SELECT + col0 / col2 + - col0 * + col1 * + col2 + col1 * + col2 AS col1 FROM tab1
----
-2808
-35909
-98592

query I rowsort
SELECT ALL + col2 * - col0 + - 6 * - col2 AS col1 FROM tab1
----
-3306
-7104
162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 - - 80 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT + col1 - 6 FROM tab2
----
11
25
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6969
SELECT ALL + col1 * CAST( 62 AS SIGNED ) FROM tab0 AS cor0
----
5332
5642
6014

skipif mysql # not compatible
query I rowsort label-6969
SELECT ALL + col1 * CAST ( 62 AS INTEGER ) FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT ALL + - cor0.col0 AS col0 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + + col1 + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6972
SELECT + cor0.col1 DIV ( col2 ) - col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6972
SELECT + cor0.col1 / ( col2 ) - col0 / + col0 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6973
SELECT DISTINCT + col0 + - 70 + - 47 DIV cor0.col1 AS col0 FROM tab1 AS cor0
----
-10
-68
7

skipif mysql # not compatible
query I rowsort label-6973
SELECT DISTINCT + col0 + - 70 + - 47 / cor0.col1 AS col0 FROM tab1 AS cor0
----
-10
-68
7

query I rowsort
SELECT ALL col2 + 27 + - col1 * + col2 AS col2 FROM tab1
----
-1125
-1323
-486

query I rowsort
SELECT ALL 2 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-6976
SELECT + col2 * col0 DIV - 79 FROM tab1
----
-2
-46
-97

skipif mysql # not compatible
query I rowsort label-6976
SELECT + col2 * col0 / - 79 FROM tab1
----
-2
-46
-97

query I rowsort
SELECT - + 23 * - ( cor1.col2 ) FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 61be457c277f5442f15b67d858888ea6

query I rowsort
SELECT - cor0.col1 + cor0.col0 * - 57 AS col2 FROM tab0 cor0
----
-1454
-2092
-5164

query I rowsort
SELECT - 54 AS col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

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-6981
SELECT + - col0 * + ( + col0 ) * col1 + 70 * - col1 + - col2 DIV - cor0.col1 AS col1 FROM tab1 AS cor0
----
-2052
-41655
-84103

skipif mysql # not compatible
query I rowsort label-6981
SELECT + - col0 * + ( + col0 ) * col1 + 70 * - col1 + - col2 / - cor0.col1 AS col1 FROM tab1 AS cor0
----
-2052
-41655
-84103

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 89 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT cor0.col2 + - 33 AS col1 FROM tab1 AS cor0
----
21
24
63

query I rowsort
SELECT - + 30 * - cor0.col0 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT DISTINCT + 1 * col2 + col2 * - col1 * ( - col1 + - col1 ) FROM tab1 AS cor0
----
11457
32544
73062

query I rowsort
SELECT ALL + ( + tab1.col1 + tab1.col1 ) * + col2 FROM tab1
----
1140
2496
2808

query I rowsort
SELECT 57 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT 13 * - 65 AS col0 FROM tab0
----
-845
-845
-845

query I rowsort
SELECT + - 55 AS col0 FROM tab1 AS cor0
----
-55
-55
-55

query I rowsort
SELECT + ( col2 ) * col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + + col1 * - cor0.col1 + 19 * col0 * - col2 AS col2 FROM tab0 cor0
----
-10074
-146943
-22444

query I rowsort
SELECT - 23 - col1 AS col1 FROM tab0 AS cor0
----
-109
-114
-120

query I rowsort
SELECT ALL + 94 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 2 + col2 col0 FROM tab0
----
-1
31
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6995
SELECT - ( - cor0.col1 ) DIV - 76 + col1 * col1 + col0 FROM tab2 AS cor0
----
3559
368
968

skipif mysql # not compatible
query I rowsort label-6995
SELECT - ( - cor0.col1 ) / - 76 + col1 * col1 + col0 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6996
SELECT - col1 * - col0 / + cor0.col0 + - ( + col2 ) * CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6996
SELECT - col1 * - col0 / + cor0.col0 + - ( + col2 ) * CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6997
SELECT ALL - 43 + - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6997
SELECT ALL - 43 + - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * - tab1.col0 * + 49 AS col1 FROM tab1
----
200704
313600
441

onlyif mysql # use DIV operator for integer division
query I rowsort label-6999
SELECT ALL col2 * 19 + col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
1044
1083
1825

skipif mysql # not compatible
query I rowsort label-6999
SELECT ALL col2 * 19 + col2 / + col0 AS col1 FROM tab1 AS cor0
----
1044
1083
1825

query I rowsort
SELECT ALL + + col1 * + 21 + + col0 * col0 FROM tab1 AS cor0
----
4306
555
6673

query I rowsort
SELECT - cor0.col2 * - cor0.col1 + + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - col1 - - col1 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL + + col2 * - col1 + col0 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT col0 - - tab1.col2 AS col0 FROM tab1
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7005
SELECT + 4 + col1 + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7005
SELECT + 4 + col1 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 18 - col1 AS col0 FROM tab1
----
-8
5
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 20 - col1 * 55 * - 3 col2 FROM tab1
----
1670
2165
4310

query I rowsort
SELECT DISTINCT - + 72 FROM tab0 cor0
----
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-7009
SELECT col0 + - col0 DIV col2 AS col0 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-7009
SELECT col0 + - col0 / col2 AS col0 FROM tab1 AS cor0
----
3
63
80

query I rowsort
SELECT ALL 12 + + col0 AS col2 FROM tab2 AS cor0
----
19
90
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7011
SELECT ALL + 0 * - col1 + - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7011
SELECT ALL + 0 * - col1 + - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col2 ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT 51 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
51

query I rowsort
SELECT - 58 * col1 * + col0 + - 34 FROM tab0
----
-119746
-196944
-469776

query I rowsort
SELECT + - 21 + 28 AS col0 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT + 81 * col0 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT ALL - - col2 * col0 - + col2 AS col0 FROM tab1 AS cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * cor0.col0 col2 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col1 col2 FROM tab2, tab1 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT col0 * col0 + - col0 * + col2 FROM tab0
----
-216
1190
623

query I rowsort
SELECT col2 * - col2 + + col2 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT - tab2.col0 * + col1 + col0 * - tab2.col1 + col2 FROM tab2
----
-2648
-407
-9178

query I rowsort
SELECT 57 * 72 FROM tab1
----
4104
4104
4104

query I rowsort
SELECT DISTINCT - col1 + + col0 - - col2 FROM tab0
----
-29
-61
80

query I rowsort
SELECT DISTINCT 65 - + 89 AS col1 FROM tab1
----
-24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7026
SELECT + 85 DIV tab2.col0 - - col2 AS col2 FROM tab2
----
27
39
39

skipif mysql # not compatible
query I rowsort label-7026
SELECT + 85 / tab2.col0 - - col2 AS col2 FROM tab2
----
27
39
39

query I rowsort
SELECT DISTINCT + 6 - - col0 FROM tab0
----
30
41
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-7028
SELECT ALL + + col2 DIV - col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-7028
SELECT ALL + + col2 / - col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7029
SELECT DISTINCT - + cor0.col1 DIV + col0 + col2 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-7029
SELECT DISTINCT - + cor0.col1 / + col0 + col2 FROM tab2 AS cor0
----
23
26
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + cor0.col2 col0 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7031
SELECT ( + col1 ) DIV - tab0.col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-7031
SELECT ( + col1 ) / - tab0.col2 FROM tab0
----
-1
-2
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7032
SELECT + col1 + + 69 DIV col0 FROM tab0
----
88
91
98

skipif mysql # not compatible
query I rowsort label-7032
SELECT + col1 + + 69 / col0 FROM tab0
----
88
91
98

query I rowsort
SELECT DISTINCT - 59 + + 22 * + col2 - tab1.col0 FROM tab1
----
1126
1131
1973

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7034
SELECT + CAST( + col0 * col0 AS SIGNED ) + - col1 FROM tab2
----
18
6025
6224

skipif mysql # not compatible
query I rowsort label-7034
SELECT + CAST ( + col0 * col0 AS INTEGER ) + - col1 FROM tab2
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-7035
SELECT 91 DIV + ( + col2 ) AS col1 FROM tab0
----
1
2
91

skipif mysql # not compatible
query I rowsort label-7035
SELECT 91 / + ( + col2 ) AS col1 FROM tab0
----
1
2
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7036
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col1 * - col1 - - col1 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7036
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col1 * - col1 - - col1 AS col0 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7037
SELECT ALL col0 * col2 + - tab0.col0 + col0 DIV - col2 FROM tab0
----
-35
7208
768

skipif mysql # not compatible
query I rowsort label-7037
SELECT ALL col0 * col2 + - tab0.col0 + col0 / - col2 FROM tab0
----
-35
7208
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col1 + - col2 * + col0 col1 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT - 72 + col0 AS col1 FROM tab1
----
-69
-8
8

query I rowsort
SELECT ALL + + 98 + cor0.col0 * - col0 * - col0 FROM tab2 AS cor0
----
441
474650
493137

onlyif mysql # use DIV operator for integer division
query I rowsort label-7041
SELECT 30 DIV col1 AS col2 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7041
SELECT 30 / col1 AS col2 FROM tab2 cor0
----
0
0
1

query I rowsort
SELECT ALL - 33 AS col0 FROM tab2 AS cor0
----
-33
-33
-33

query I rowsort
SELECT - + 98 + col1 FROM tab0 AS cor0
----
-1
-12
-7

query I rowsort
SELECT DISTINCT - 49 * col2 AS col0 FROM tab2 AS cor0
----
-1274
-1323
-1862

query I rowsort
SELECT DISTINCT 35 * col2 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT + - 72 * - col2 + col0 * col1 FROM tab0 AS cor0
----
14003
3467
4440

query I rowsort
SELECT DISTINCT + 42 + col1 AS col0 FROM tab2 AS cor0
----
101
59
73

query I rowsort
SELECT + col0 * + col2 + - col0 * + col0 * tab2.col1 FROM tab2
----
-103095
-1330
-356928

query I rowsort
SELECT col2 * - col1 * - tab0.col1 FROM tab0
----
244068
679042
9409

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL <= ( - col0 * - col1 + + col1 )
----

query I rowsort
SELECT ALL - col1 AS col2 FROM tab1 WHERE col0 * col0 + + col0 BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT ALL - col1 + col0 * - col2 FROM tab0
----
-132
-7389
-878

query III rowsort
SELECT * FROM tab0 WHERE NULL <= ( col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col0 NOT IN ( - col2 )
----

query I rowsort
SELECT DISTINCT - col2 + col1 * - col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT ALL col2 / col2 - - col0 * col1 AS col1 FROM tab2 WHERE NOT NULL IN ( + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7057
SELECT - col0 DIV col1 + - col0 AS col1 FROM tab1
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-7057
SELECT - col0 / col1 + - col0 AS col1 FROM tab1
----
-3
-70
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT DISTINCT + col0 DIV - col0 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7058
SELECT DISTINCT + col0 / - col0 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT ALL - col0 + - col1 * - col2 AS col0 FROM tab0 cor0
----
2814
62
7373

query III rowsort
SELECT ALL * FROM tab2 WHERE - col0 NOT IN ( col1 * col0 * + col1 + + tab2.col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 + + col1 col0 FROM tab0
----
1322
662
8012

query I rowsort
SELECT DISTINCT col0 * - col2 + col0 AS col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT + col2 / col0 AS col2 FROM tab0 WHERE NOT ( + col0 ) < col0 / - col2 + col1 * + col1 * col1
----

query I rowsort
SELECT col1 * + tab2.col1 + col2 FROM tab2 WHERE ( - col0 * + col2 - col2 ) NOT BETWEEN col0 + col2 AND NULL
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 * - col1 col2 FROM tab0
----
611884
93654
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * tab2.col0 col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL tab1.col1 * + col1 - - col0 AS col2 FROM tab1
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col1 * col1 * tab0.col1 col1 FROM tab0
----
636023
753489
912672

query I rowsort
SELECT DISTINCT + col0 AS col2 FROM tab1 WHERE NOT ( col2 ) IN ( + col0 )
----
3
64
80

query I rowsort
SELECT col0 * col1 + col0 + col2 * col0 * col2 FROM tab0
----
28224
3465
606624

query I rowsort
SELECT ALL col0 * - col1 * + tab2.col2 FROM tab2
----
-119652
-51034
-5859

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT IN ( + col2 )
----

query I rowsort
SELECT ALL col2 * tab1.col0 * col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT - col0 * col2 + - col2 + + tab0.col1 FROM tab0
----
-7289
-739
61

query I rowsort
SELECT DISTINCT col0 + + col1 + col2 AS col1 FROM tab2
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-7076
SELECT + col0 * col0 DIV col1 FROM tab2
----
1
103
367

skipif mysql # not compatible
query I rowsort label-7076
SELECT + col0 * col0 / col1 FROM tab2
----
1
103
367

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 ALL col2 * col0 * - col0 AS col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT ALL + col0 * col0 + col2 AS col2 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7080
SELECT DISTINCT - col1 DIV - col0 + - col2 * col0 + + col0 AS col1 FROM tab0 AS cor0
----
-7208
-765
2

skipif mysql # not compatible
query I rowsort label-7080
SELECT DISTINCT - col1 / - col0 + - col2 * col0 + + col0 AS col1 FROM tab0 AS cor0
----
-7208
-765
2

query I rowsort
SELECT + col1 + + tab1.col0 * + col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT col1 + + col1 AS col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL + col2 * - col2 + col1 * col2 * + col2 AS col2 FROM tab1 cor0
----
110592
29241
72900

onlyif mysql # use DIV operator for integer division
query I rowsort label-7084
SELECT DISTINCT col2 DIV col0 - col0 FROM tab1 AS cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-7084
SELECT DISTINCT col2 / col0 - col0 FROM tab1 AS cor0
----
-64
-79
15

query I rowsort
SELECT DISTINCT cor0.col0 + + col1 * col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + cor0.col2 * - col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + col1 + col0 - + col1 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL col0 * - col1 + + cor0.col2 * col2 FROM tab0 cor0
----
-1375
-3394
-975

query I rowsort
SELECT + col2 + + 1 * + col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + - 65 FROM tab2 AS cor0
----
-65
-65
-65

query I rowsort
SELECT + - ( - col2 ) + cor0.col0 - ( 49 ) FROM tab0 AS cor0
----
-13
122
8

query I rowsort
SELECT DISTINCT + 30 * - cor0.col2 FROM tab2 AS cor0
----
-1140
-780
-810

query I rowsort
SELECT - + 83 + col1 FROM tab2 cor0
----
-24
-52
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-7094
SELECT - - col2 * - col0 * col2 + - col1 - col2 DIV col1 FROM tab1 cor0
----
-207951
-737300
-8776

skipif mysql # not compatible
query I rowsort label-7094
SELECT - - col2 * - col0 * col2 + - col1 - col2 / col1 FROM tab1 cor0
----
-207951
-737300
-8776

onlyif mysql # use DIV operator for integer division
query I rowsort label-7095
SELECT + col0 DIV col0 + col0 * col1 FROM tab0 AS cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-7095
SELECT + col0 / col0 + col0 * col1 FROM tab0 AS cor0
----
2065
3396
8100

query I rowsort
SELECT - 70 + 83 FROM tab0 AS cor0
----
13
13
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-7097
SELECT - cor0.col1 DIV cor0.col0 - col0 FROM tab0 AS cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-7097
SELECT - cor0.col1 / cor0.col0 - col0 FROM tab0 AS cor0
----
-27
-37
-90

query I rowsort
SELECT ALL - col1 * - ( 74 ) AS col2 FROM tab1
----
1924
740
962

query I rowsort
SELECT DISTINCT + tab1.col2 * + 82 * - col2 + tab1.col1 + + tab1.col2 * tab1.col2 AS col2 FROM tab1
----
-236170
-263159
-746483

query I rowsort
SELECT - - 9 + col0 AS col2 FROM tab0 AS cor0
----
33
44
98

query I rowsort
SELECT + cor0.col1 + col2 * + col0 - + col2 FROM tab1 cor0
----
134
3601
7597

query I rowsort
SELECT col0 + 23 + - col2 FROM tab0 AS cor0
----
14
30
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7103
SELECT ( 96 ) DIV col2 FROM tab0 AS cor0
----
1
2
96

skipif mysql # not compatible
query I rowsort label-7103
SELECT ( 96 ) / col2 FROM tab0 AS cor0
----
1
2
96

query I rowsort
SELECT ALL ( col2 * + tab1.col1 ) + 72 * - col2 - col0 * + col1 * col0 AS col2 FROM tab1
----
-2718
-44494
-88864

query I rowsort
SELECT cor0.col1 * + cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col2 * + col1 * - col0 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7107
SELECT CAST( NULL AS SIGNED ) * 69 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7107
SELECT CAST ( NULL AS INTEGER ) * 69 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - + col0 * + ( col0 + + col0 ) AS col1 FROM tab0 AS cor0
----
-1152
-15842
-2450

query I rowsort
SELECT - col1 * + 93 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT col0 + 58 * 24 AS col2 FROM tab2 AS cor0
----
1399
1470
1471

query I rowsort
SELECT + col0 * + 22 FROM tab1 AS cor0
----
1408
1760
66

query I rowsort
SELECT ALL col1 + + ( col0 ) * + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT + col0 * ( 62 ) - col1 FROM tab1 AS cor0
----
160
3958
4947

query I rowsort
SELECT col1 + + cor0.col0 * 30 * col2 FROM tab1 cor0
----
109450
230413
4886

query I rowsort
SELECT - col1 * 11 AS col1 FROM tab1 AS cor0
----
-110
-143
-286

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7116
SELECT DISTINCT CAST( NULL AS SIGNED ) * col2 * col0 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7116
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col2 * col0 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col1 * ( - col2 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + 99 * - col0 FROM tab2 AS cor0
----
-693
-7722
-7821

query I rowsort
SELECT ALL + + col0 * + 63 FROM tab1 cor0
----
189
4032
5040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 61 ) col0 FROM tab0
----
-61
-61
-61

query I rowsort
SELECT cor0.col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT 65 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT - col1 * - 87 - - col0 FROM tab2 AS cor0
----
1558
2704
5211

query I rowsort
SELECT ALL - 14 * 53 * - col0 + col2 AS col0 FROM tab2 AS cor0
----
5221
57902
58656

query I rowsort
SELECT DISTINCT - cor1.col2 AS col0 FROM tab1, tab0 cor0, tab1 AS cor1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 * + col1 col1 FROM tab2 AS cor0
----
1326
2418
4602

query I rowsort
SELECT - col1 * - col2 * col2 + + col2 FROM tab1 AS cor0
----
119904
32547
75870

onlyif mysql # use DIV operator for integer division
query I rowsort label-7128
SELECT + col1 * col1 + - 89 DIV - col2 FROM tab0
----
7398
8282
9498

skipif mysql # not compatible
query I rowsort label-7128
SELECT + col1 * col1 + - 89 / - col2 FROM tab0
----
7398
8282
9498

query I rowsort
SELECT ALL 23 + col1 FROM tab1
----
33
36
49

query I rowsort
SELECT DISTINCT - ( - col1 ) * - col1 * + ( col2 ) + col2 FROM tab2
----
-10944
-25920
-90480

query I rowsort
SELECT ALL tab0.col2 * - ( 2 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 3ecf22ea98914f3029f17bd37e7e2ec3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col1 * col0 + col0 + col2 * + col0 col1 FROM tab1
----
3072
6720
87

query I rowsort
SELECT DISTINCT + 73 + + col1 FROM tab1 AS cor0
----
83
86
99

query I rowsort
SELECT + + col2 * col2 * + col1 AS col0 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - + ( - col2 ) + - cor0.col1 * + 80 FROM tab0 cor0
----
-6847
-7198
-7759

query I rowsort
SELECT col1 + + col1 * - 85 AS col2 FROM tab0 AS cor0
----
-7224
-7644
-8148

query I rowsort
SELECT - + ( col1 ) + 64 AS col2 FROM tab1 AS cor0
----
38
51
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-7138
SELECT ALL + col1 * col0 + col1 DIV col2 + col1 FROM tab0 AS cor0
----
2152
3589
8191

skipif mysql # not compatible
query I rowsort label-7138
SELECT ALL + col1 * col0 + col1 / col2 + col1 FROM tab0 AS cor0
----
2152
3589
8191

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col2 * + col1 col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - cor0.col1 * ( col0 ) + - col0 AS col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL + - col1 * + 77 AS col0 FROM tab1 AS cor0
----
-1001
-2002
-770

query I rowsort
SELECT ALL - cor0.col1 + col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col1 + col1 ) * - col1 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + - col2 * - ( col1 ) + col0 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + col2 * 32 FROM tab1 cor0
----
1728
1824
3072

query I rowsort
SELECT ALL - + col1 * col0 * + col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7147
SELECT + ( - col1 ) * CAST( NULL AS DECIMAL ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7147
SELECT + ( - col1 ) * CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 + + col1 * col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7149
SELECT + col1 * col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7149
SELECT + col1 * col0 + 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-7150
SELECT DISTINCT - cor1.col1 DIV cor0.col2 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-1
-17
-31
-59
0

skipif mysql # not compatible
query I rowsort label-7150
SELECT DISTINCT - cor1.col1 / cor0.col2 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-1
-17
-31
-59
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7151
SELECT DISTINCT - col1 DIV col0 + col0 DIV col0 AS col0 FROM tab2 AS cor0
----
-3
1

skipif mysql # not compatible
query I rowsort label-7151
SELECT DISTINCT - col1 / col0 + col0 / col0 AS col0 FROM tab2 AS cor0
----
-3
1

query I rowsort
SELECT DISTINCT + + ( cor0.col1 ) - - 78 AS col0 FROM tab0 AS cor0
----
164
169
175

query I rowsort
SELECT ALL 26 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

onlyif mysql # use DIV operator for integer division
query I rowsort label-7154
SELECT DISTINCT cor0.col2 DIV + col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-7154
SELECT DISTINCT cor0.col2 / + col2 FROM tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT + cor0.col1 + + col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + col2 * + col0 - - ( - col1 ) AS col1 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7157
SELECT ALL + ( - col0 ) + + CAST( NULL AS SIGNED ) - 15 * + col0 * col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7157
SELECT ALL + ( - col0 ) + + CAST ( NULL AS INTEGER ) - 15 * + col0 * col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7158
SELECT + col2 DIV - col0 - + col0 * 13 AS col1 FROM tab2 AS cor0
----
-1014
-1027
-94

skipif mysql # not compatible
query I rowsort label-7158
SELECT + col2 / - col0 - + col0 * 13 AS col1 FROM tab2 AS cor0
----
-1014
-1027
-94

query I rowsort
SELECT DISTINCT 39 * - col1 AS col2 FROM tab1 AS cor0
----
-1014
-390
-507

query I rowsort
SELECT col0 * col2 + col1 * col2 FROM tab1 AS cor0
----
1566
4218
8928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 76 + - col0 col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

query I rowsort
SELECT col1 + 56 FROM tab1 AS cor0
----
66
69
82

query I rowsort
SELECT DISTINCT - col2 * ( col1 ) FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + col2 + col1 * + col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - col0 * ( 46 ) + col1 AS col2 FROM tab1 AS cor0
----
-112
-2934
-3667

query I rowsort
SELECT ALL + col2 + 56 AS col1 FROM tab0 AS cor0
----
138
57
89

query I rowsort
SELECT DISTINCT col0 + ( - col2 ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - col0 + - 19 FROM tab0 AS cor0
----
-108
-43
-54

query I rowsort
SELECT DISTINCT col1 + col0 + + col0 * - col2 FROM tab0
----
-682
-7118
97

query I rowsort
SELECT ALL 66 AS col1 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT 1 * + 83 AS col1 FROM tab0 cor0
----
83
83
83

query I rowsort
SELECT 27 AS col2 FROM tab2 AS cor0
----
27
27
27

query I rowsort
SELECT DISTINCT - 62 * col2 * col2 FROM tab0 AS cor0
----
-416888
-62
-67518

query I rowsort
SELECT DISTINCT - col2 + + 53 FROM tab0 cor0
----
-29
20
52

query I rowsort
SELECT ALL - + ( - 54 ) FROM tab2 AS cor0
----
54
54
54

query I rowsort
SELECT DISTINCT + - col0 * - 46 FROM tab2 AS cor0
----
322
3588
3634

query I rowsort
SELECT ALL + + col2 * - 57 + col2 AS col1 FROM tab2 AS cor0
----
-1456
-1512
-2128

onlyif mysql # use DIV operator for integer division
query I rowsort label-7178
SELECT - 64 DIV col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-7178
SELECT - 64 / col0 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL + 79 * + col0 AS col1 FROM tab2 AS cor0
----
553
6162
6241

query I rowsort
SELECT col1 * - col0 * col0 AS col2 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL - + ( + col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + col0 * - col1 - col2 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT - ( col1 ) + - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + tab0.col0 - + col2 * col1 AS col0 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL 19 - col1 FROM tab1
----
-7
6
9

query I rowsort
SELECT DISTINCT col1 * 77 FROM tab0 AS cor0
----
6622
7007
7469

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7187
SELECT DISTINCT + + CAST( - col1 AS SIGNED ) * col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7187
SELECT DISTINCT + + CAST ( - col1 AS INTEGER ) * col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + ( 61 ) * + col2 FROM tab0
----
2013
5002
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) * - col1 col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + - 94 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

query I rowsort
SELECT - 31 + col2 AS col1 FROM tab1 AS cor0
----
23
26
65

query I rowsort
SELECT 1 + col1 AS col1 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-7193
SELECT ALL col2 + cor0.col2 * 21 DIV ( col2 * - col0 ) col0 FROM tab1 cor0
----
47
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7193
SELECT ALL col2 + cor0.col2 * 21 / ( col2 * - col0 ) col0 FROM tab1 cor0
----
47
57
96

query I rowsort
SELECT ALL 94 * cor0.col2 + + col0 * 97 AS col0 FROM tab2 AS cor0
----
10010
11235
3217

query I rowsort
SELECT - - col2 - + col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 - - 46 AS col2 FROM tab1 cor0
----
110
126
49

query I rowsort
SELECT DISTINCT - - col0 * - col0 + + col2 - col0 AS col0 FROM tab0 cor0
----
-1259
-567
-7928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7198
SELECT ALL - col0 + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7198
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 + + ( - col1 ) AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT cor0.col1 * + col1 + col0 * col2 AS col0 FROM tab0 AS cor0
----
15579
8188
9444

query I rowsort
SELECT DISTINCT - 99 AS col1 FROM tab2 AS cor0
----
-99

query I rowsort
SELECT + col1 * + cor0.col0 * col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-7203
SELECT + - col2 DIV + ( - cor0.col0 ) FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-7203
SELECT + - col2 / + ( - cor0.col0 ) FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT - - col1 * - 64 AS col0 FROM tab1 AS cor0
----
-1664
-640
-832

query I rowsort
SELECT ALL cor0.col2 * ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7206
SELECT DISTINCT - ( col1 ) * - ( - col2 + col1 * CAST( NULL AS SIGNED ) ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-7206
SELECT DISTINCT - ( col1 ) * - ( - col2 + col1 * CAST ( NULL AS INTEGER ) ) AS col2 FROM tab2
----
NULL

query I rowsort
SELECT - col0 + - col1 * 56 AS col2 FROM tab0 AS cor0
----
-4840
-5185
-5467

query I rowsort
SELECT + cor0.col0 * + col1 * + ( + cor0.col1 ) FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7209
SELECT ALL - - CAST( NULL AS SIGNED ) - + col2 * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7209
SELECT ALL - - CAST ( NULL AS INTEGER ) - + col2 * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 18 AS col0 FROM tab2 AS cor0
----
18

query I rowsort
SELECT ALL + - 32 FROM tab1 AS cor0
----
-32
-32
-32

query I rowsort
SELECT ALL + 3 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to c7bd37716aa9c76e684a54f53d1ee343

query I rowsort
SELECT + - col2 * - ( col0 ) - ( - col2 ) FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - + 74 * col1 FROM tab1 AS cor0
----
-1924
-740
-962

query I rowsort
SELECT + - 19 * - col0 AS col1 FROM tab0 AS cor0
----
1691
456
665

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 * col1 + + col2 col0 FROM tab2
----
106135
1546
358982

query I rowsort
SELECT DISTINCT - col1 - col0 AS col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT col0 * col1 + tab1.col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT - tab0.col0 + col2 FROM tab0 WHERE NOT + col1 * - col2 < NULL
----

query I rowsort
SELECT DISTINCT 79 FROM tab2, tab0, tab0 cor0
----
79

query I rowsort
SELECT - + 6 AS col0 FROM tab2 cor0
----
-6
-6
-6

query I rowsort
SELECT ALL - 17 * + col2 FROM tab2
----
-442
-459
-646

query I rowsort
SELECT DISTINCT - tab1.col0 AS col2 FROM tab1, tab0, tab0 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col1 + 76 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT DISTINCT - cor2.col0 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab0 cor2
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + 93 FROM tab1, tab0 cor0, tab0 AS cor1
----
93

query I rowsort
SELECT DISTINCT + ( + col1 ) * - col2 + - col1 AS col2 FROM tab1
----
-1261
-1430
-580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7228
SELECT + tab1.col2 * CAST( + 80 AS SIGNED ) FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 86a24a6be178bfe879ad8acd45ce4b7c

skipif mysql # not compatible
query I rowsort label-7228
SELECT + tab1.col2 * CAST ( + 80 AS INTEGER ) FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 86a24a6be178bfe879ad8acd45ce4b7c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7229
SELECT DISTINCT col2 / CAST( NULL AS DECIMAL ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7229
SELECT DISTINCT col2 / CAST ( NULL AS REAL ) AS col0 FROM tab1
----
NULL

query I rowsort
SELECT + 22 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT + tab2.col1 + + col1 * + ( col0 ) AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT DISTINCT + cor0.col0 * col2 + + cor0.col2 * + col0 FROM tab2 AS cor0
----
378
4056
6004

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7233
SELECT + col0 / + CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7233
SELECT + col0 / + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col0 col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT col0 + + col0 + - col0 AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT + 47 - + 36 FROM tab0
----
11

query I rowsort
SELECT DISTINCT ( col2 ) - + col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT + 50 * + col1 AS col2 FROM tab2
----
1550
2950
850

query I rowsort
SELECT - col0 * 25 + + col2 FROM tab1 AS cor0
----
-1543
-1904
-21

query I rowsort
SELECT col2 * - col2 + + col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - + ( - col0 ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - cor0.col2 * col2 + 2 * + col0 FROM tab2 AS cor0
----
-1286
-520
-715

query I rowsort
SELECT DISTINCT col2 + + col1 * 14 FROM tab1 AS cor0
----
197
278
418

query I rowsort
SELECT ALL + - col0 + col0 + col1 * - col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col2 * + col2 + + 13 FROM tab1 AS cor0
----
-2903
-3236
-9203

query I rowsort
SELECT - + cor0.col2 AS col0 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 2df272448a67587d4635afedff278dcc

query I rowsort
SELECT ALL + ( + 86 + col1 ) FROM tab2
----
103
117
145

onlyif mysql # use DIV operator for integer division
query I rowsort label-7248
SELECT 79 DIV + col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7248
SELECT 79 / + col1 AS col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col1 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - col2 * col1 - + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-1612
-725
-844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 + + ( col1 + cor0.col1 ) col0 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT - - 76 - col1 FROM tab0 AS cor0
----
-10
-15
-21

query I rowsort
SELECT DISTINCT - col2 * col0 + 24 FROM tab0 AS cor0
----
-11
-7274
-768

onlyif mysql # use DIV operator for integer division
query I rowsort label-7254
SELECT ALL col2 DIV col0 + col1 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-7254
SELECT ALL col2 / col0 + col1 FROM tab1 AS cor0
----
10
14
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7255
SELECT DISTINCT col2 + + CAST( col0 AS SIGNED ) + - col2 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7255
SELECT DISTINCT col2 + + CAST ( col0 AS INTEGER ) + - col2 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - 4 * - col2 AS col1 FROM tab0 AS cor0
----
132
328
4

query I rowsort
SELECT - - 57 + 46 AS col2 FROM tab0 AS cor0
----
103
103
103

query I rowsort
SELECT - ( 55 ) AS col2 FROM tab0
----
-55
-55
-55

query I rowsort
SELECT DISTINCT + col2 * ( col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7260
SELECT + col0 + 29 * col2 - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7260
SELECT + col0 + 29 * col2 - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * col1 + - cor0.col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT + 3 + - col0 AS col2 FROM tab1
----
-61
-77
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7263
SELECT col1 DIV - col0 + - col2 DIV 96 AS col0 FROM tab1
----
-1
-8
0

skipif mysql # not compatible
query I rowsort label-7263
SELECT col1 / - col0 + - col2 / 96 AS col0 FROM tab1
----
-1
-8
0

query I rowsort
SELECT DISTINCT + 66 * - col1 + + ( + col0 ) * + col2 FROM tab0 AS cor0
----
-4884
-6367
1292

query I rowsort
SELECT ALL - + col2 * + cor0.col2 * - col2 AS col0 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT ALL 51 + col1 * 97 FROM tab2 AS cor0
----
1700
3058
5774

query I rowsort
SELECT DISTINCT + + ( cor0.col0 ) * - col1 * + col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT + 23 AS col2 FROM tab1 cor0
----
23
23
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-7269
SELECT - col2 DIV 10 FROM tab2 cor0
----
-2
-2
-3

skipif mysql # not compatible
query I rowsort label-7269
SELECT - col2 / 10 FROM tab2 cor0
----
-2
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7270
SELECT DISTINCT - col2 DIV ( + col1 ) + + col1 AS col2 FROM tab1 cor0
----
24
5
6

skipif mysql # not compatible
query I rowsort label-7270
SELECT DISTINCT - col2 / ( + col1 ) + + col1 AS col2 FROM tab1 cor0
----
24
5
6

query I rowsort
SELECT DISTINCT + col2 + - col2 + 49 * + col0 * + col0 AS col2 FROM tab0 AS cor0
----
28224
388129
60025

query I rowsort
SELECT DISTINCT - - col1 + col2 + col1 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT DISTINCT col0 + ( - col2 ) AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL - col2 * + 7 - col2 AS col1 FROM tab2 cor0
----
-208
-216
-304

query I rowsort
SELECT + col1 * - 49 FROM tab2 AS cor0
----
-1519
-2891
-833

query I rowsort
SELECT DISTINCT cor0.col2 * - 19 * col2 + - col1 FROM tab1 AS cor0
----
-175117
-55430
-61741

query I rowsort
SELECT + col2 * - col1 + col1 * + col1 FROM tab2 AS cor0
----
-357
124
1947

query I rowsort
SELECT DISTINCT + + col0 + ( + 32 ) AS col1 FROM tab1 AS cor0
----
112
35
96

query I rowsort
SELECT col1 * col0 * - 42 FROM tab1 cor0
----
-26880
-3276
-43680

query I rowsort
SELECT - - col2 * ( + col1 ) FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + 29 * + col1 AS col2 FROM tab2 AS cor0
----
1711
493
899

query I rowsort
SELECT 79 + col1 FROM tab0 AS cor0
----
165
170
176

onlyif mysql # use DIV operator for integer division
query I rowsort label-7283
SELECT - col2 DIV col2 + - cor0.col1 AS col2 FROM tab0 cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-7283
SELECT - col2 / col2 + - cor0.col1 AS col2 FROM tab0 cor0
----
-87
-92
-98

query I rowsort
SELECT - col2 + col1 * col1 FROM tab1 AS cor0
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-7285
SELECT ALL - col0 + - col1 DIV col1 col0 FROM tab0
----
-25
-36
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7285
SELECT ALL - col0 + - col1 / col1 col0 FROM tab0
----
-25
-36
-90

query I rowsort
SELECT ALL + col0 + + col1 + + tab2.col2 AS col1 FROM tab2
----
134
163
65

query I rowsort
SELECT DISTINCT ( tab1.col0 ) + col2 * col2 AS col0 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT ALL - col2 + - col2 * + col2 FROM tab2
----
-1482
-702
-756

query I rowsort
SELECT ALL ( 79 ) + + col1 AS col1 FROM tab0
----
165
170
176

onlyif mysql # use DIV operator for integer division
query I rowsort label-7290
SELECT ALL col0 DIV + col1 + tab0.col1 + + ( 76 + col2 ) FROM tab0
----
174
195
249

skipif mysql # not compatible
query I rowsort label-7290
SELECT ALL col0 / + col1 + tab0.col1 + + ( 76 + col2 ) FROM tab0
----
174
195
249

query I rowsort
SELECT ALL + 61 * - col2 * - 86 AS col2 FROM tab0
----
173118
430172
5246

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7292
SELECT - - cor0.col2 + + cor0.col2 * - CAST( NULL AS SIGNED ) * col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7292
SELECT - - cor0.col2 + + cor0.col2 * - CAST ( NULL AS INTEGER ) * col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + col0 ) AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 89 * + col0 AS col2 FROM tab1 AS cor0
----
267
5696
7120

query I rowsort
SELECT + - col0 * + cor0.col0 + + col1 AS col0 FROM tab1 cor0
----
-4086
-6387
17

query I rowsort
SELECT + 5 + col2 * col1 AS col0 FROM tab0 AS cor0
----
102
2843
7467

query I rowsort
SELECT ALL col1 + - ( col0 ) + - 91 AS col0 FROM tab0
----
-29
-29
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7298
SELECT - ( 89 ) + - col1 * - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7298
SELECT - ( 89 ) + - col1 * - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( - col0 ) * col0 + - ( - col0 ) AS col2 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT - 88 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7301
SELECT - + col0 DIV col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7301
SELECT - + col0 / col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col1 col1 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT col0 + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT + + ( + col0 ) * - cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - - 16 + - col1 FROM tab0 AS cor0
----
-70
-75
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7306
SELECT DISTINCT - 99 DIV col0 AS col1 FROM tab2 AS cor0
----
-1
-14

skipif mysql # not compatible
query I rowsort label-7306
SELECT DISTINCT - 99 / col0 AS col1 FROM tab2 AS cor0
----
-1
-14

query I rowsort
SELECT - - cor0.col1 + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - col1 * - ( col0 ) + - col2 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT 23 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT - col0 - ( col2 ) AS col1 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7311
SELECT + col0 * cor0.col1 + col0 DIV + col2 AS col2 FROM tab1 AS cor0
----
1040
641
78

skipif mysql # not compatible
query I rowsort label-7311
SELECT + col0 * cor0.col1 + col0 / + col2 AS col2 FROM tab1 AS cor0
----
1040
641
78

query I rowsort
SELECT + col2 - 41 FROM tab2 AS cor0
----
-14
-15
-3

query I rowsort
SELECT + - col0 + - ( - col2 ) AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT col0 - 20 FROM tab1 AS cor0
----
-17
44
60

query I rowsort
SELECT DISTINCT - ( col0 ) + - col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + 86 * col2 AS col0 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT ALL + col0 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT 38 AS col2 FROM tab0 AS cor0
----
38

query I rowsort
SELECT - 20 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT DISTINCT - cor0.col0 * - col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + + ( col0 ) * cor0.col1 + + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - - 17 FROM tab0 cor0
----
17
17
17

query I rowsort
SELECT + cor0.col0 * - 29 + cor0.col1 FROM tab2 AS cor0
----
-172
-2203
-2274

query I rowsort
SELECT DISTINCT - 32 + 80 FROM tab1 AS cor0
----
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-7325
SELECT ALL + - ( col0 ) * col1 - - ( col0 ) DIV col0 FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-7325
SELECT ALL + - ( col0 ) * col1 - - ( col0 ) / col0 FROM tab1 AS cor0
----
-1039
-639
-77

query I rowsort
SELECT - 18 * 4 + col0 AS col1 FROM tab0 AS cor0
----
-37
-48
17

query I rowsort
SELECT DISTINCT + 79 * 22 - + col2 * - col1 FROM tab2 AS cor0
----
2384
2575
3272

query I rowsort
SELECT ALL + - ( - 18 ) * col2 FROM tab0 AS cor0
----
1476
18
594

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 56 col0 FROM tab1 AS cor0
----
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + 89 AS col0 FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT ALL 25 * cor0.col0 + - cor0.col2 FROM tab2 cor0
----
148
1924
1937

query I rowsort
SELECT cor1.col1 * cor0.col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 220064493ff9775ff1f87429d726f896

query I rowsort
SELECT col1 * + 90 AS col0 FROM tab1
----
1170
2340
900

query I rowsort
SELECT col1 * + 94 AS col1 FROM tab1
----
1222
2444
940

query I rowsort
SELECT ALL 58 + 35 - col0 AS col1 FROM tab1 AS cor0
----
13
29
90

query I rowsort
SELECT DISTINCT - - 90 * 17 FROM tab1 AS cor0
----
1530

query I rowsort
SELECT ALL - 29 FROM tab2 AS cor0
----
-29
-29
-29

query I rowsort
SELECT ALL - - col2 + col0 * col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
262201
512096
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7340
SELECT - CAST( - col2 AS SIGNED ) * - col1 col2 FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7340
SELECT - CAST ( - col2 AS INTEGER ) * - col1 col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7341
SELECT cor0.col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7341
SELECT cor0.col0 / - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 * col1 + - ( col2 ) * 67 FROM tab0 AS cor0
----
1968
30
627

query I rowsort
SELECT ALL + + col1 * + col1 + col0 + col2 AS col1 FROM tab1 cor0
----
221
345
733

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7345
SELECT col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7345
SELECT col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + 61 FROM tab0
----
147
152
158

query I rowsort
SELECT + tab1.col1 + - col0 AS col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT col1 - 10 FROM tab1
----
0
16
3

query I rowsort
SELECT DISTINCT + + col2 * - cor0.col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + col0 + - 53 * - 5 + - tab0.col1 FROM tab0
----
203
203
263

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7351
SELECT - col2 * + CAST( - 90 AS SIGNED ) + + cor0.col2 AS col0 FROM tab1 cor0
----
4914
5187
8736

skipif mysql # not compatible
query I rowsort label-7351
SELECT - col2 * + CAST ( - 90 AS INTEGER ) + + cor0.col2 AS col0 FROM tab1 cor0
----
4914
5187
8736

query I rowsort
SELECT - + col2 + + cor0.col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT col1 - col1 * - col1 FROM tab1
----
110
182
702

query I rowsort
SELECT DISTINCT col2 + col0 * - ( 92 ) AS col2 FROM tab0 AS cor0
----
-2175
-3219
-8106

onlyif mysql # use DIV operator for integer division
query I rowsort label-7355
SELECT 17 DIV col0 AS col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7355
SELECT 17 / col0 AS col1 FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 21 col2 FROM tab2 AS cor0
----
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-7357
SELECT DISTINCT - col1 * 19 DIV col2 AS col2 FROM tab1
----
-2
-3
-9

skipif mysql # not compatible
query I rowsort label-7357
SELECT DISTINCT - col1 * 19 / col2 AS col2 FROM tab1
----
-2
-3
-9

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 AS cor2
----
3645 values hashing to f3ede863c793df0de5c26c654290b3b7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7359
SELECT + 52 + - col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7359
SELECT + 52 + - col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - - tab0.col0 AS col1 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL - col1 * col2 * col1 AS col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT 52 * tab0.col1 AS col0 FROM tab0, tab1, tab2 AS cor0
----
4472
4732
5044

query I rowsort
SELECT 63 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT cor0.col2 * + 22 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to e3295b171871080f98abf951fa3e401a

query I rowsort
SELECT DISTINCT 17 * col2 AS col1 FROM tab0 AS cor0
----
1394
17
561

onlyif mysql # use DIV operator for integer division
query I rowsort label-7366
SELECT ALL + ( + col0 ) DIV + col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7366
SELECT ALL + ( + col0 ) / + col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab0, tab1, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + col2 + - col0 * + col0 + - col2 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT ALL - col2 + 15 * tab0.col0 FROM tab0
----
1253
327
524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col2 + - 19 col0 FROM tab1
----
143
3629
7661

onlyif mysql # use DIV operator for integer division
query I rowsort label-7371
SELECT DISTINCT col0 DIV + col2 + tab1.col2 FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-7371
SELECT DISTINCT col0 / + col2 + tab1.col2 FROM tab1
----
54
58
96

query I rowsort
SELECT col2 - + 24 FROM tab2
----
14
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7373
SELECT col2 + ( + col0 ) DIV col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-7373
SELECT col2 + ( + col0 ) / col2 FROM tab0
----
33
36
83

query I rowsort
SELECT DISTINCT + - col0 + col0 + - col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL col1 - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL col1 * + col0 * 87 + col1 FROM tab2 cor0
----
116858
18910
400433

query I rowsort
SELECT ALL + tab1.col2 + - 35 AS col1 FROM tab1
----
19
22
61

query I rowsort
SELECT - col2 * - col0 AS col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + cor0.col1 col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to aff311fa1b3948e179779cc03c1fade4

query I rowsort
SELECT ALL col1 * + col1 + - col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT ALL - col1 + ( - col1 ) * col2 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT + cor0.col2 + + ( col0 ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + ( 45 ) FROM tab1 cor0
----
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7384
SELECT + ( - col1 ) + col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7384
SELECT + ( - col1 ) + col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( 16 ) AS col1 FROM tab2 AS cor0
----
16
16
16

query I rowsort
SELECT - - 41 * col0 * col0 FROM tab2 cor0
----
2009
249444
255881

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( col0 ) + col2 - + col1 col1 FROM tab1 AS cor0
----
111
163
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + col1 ) * - col0 + 38 col2 FROM tab0 AS cor0
----
2102
3433
8137

query I rowsort
SELECT DISTINCT col0 * + col0 + cor0.col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + ( + col2 ) * col2 + ( 10 ) * col1 AS col0 FROM tab2 AS cor0
----
1039
1266
1614

query I rowsort
SELECT + - ( 14 ) + col1 AS col1 FROM tab0 AS cor0
----
72
77
83

query I rowsort
SELECT DISTINCT + tab0.col0 + + 75 FROM tab0
----
110
164
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7393
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * 53 + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7393
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * 53 + col0 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7394
SELECT + + 54 + - col2 DIV + col1 FROM tab2 cor0
----
52
54
54

skipif mysql # not compatible
query I rowsort label-7394
SELECT + + 54 + - col2 / + col1 FROM tab2 cor0
----
52
54
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT DISTINCT col0 DIV cor0.col0 + - col1 col2 FROM tab2 AS cor0
----
-16
-30
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7395
SELECT DISTINCT col0 / cor0.col0 + - col1 col2 FROM tab2 AS cor0
----
-16
-30
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7396
SELECT - col1 + cor0.col1 DIV + col0 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-7396
SELECT - col1 + cor0.col1 / + col0 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT ( col1 ) + + col1 * + col2 * col1 AS col2 FROM tab2 cor0
----
10999
25978
90565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7398
SELECT + CAST( tab1.col1 AS SIGNED ) * - col2 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-7398
SELECT + CAST ( tab1.col1 AS INTEGER ) * - col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT col2 * - 50 AS col1 FROM tab0
----
-1650
-4100
-50

query I rowsort
SELECT ALL ( + 25 ) FROM tab1
----
25
25
25

query I rowsort
SELECT 36 * - col1 FROM tab2
----
-1116
-2124
-612

query I rowsort
SELECT - 43 * col1 FROM tab2
----
-1333
-2537
-731

query I rowsort
SELECT ALL - col0 - - 32 FROM tab1 AS cor0
----
-32
-48
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7404
SELECT DISTINCT CAST( NULL AS DECIMAL ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7404
SELECT DISTINCT CAST ( NULL AS REAL ) AS col1 FROM tab0
----
NULL

query I rowsort
SELECT 19 * - col1 * - col1 + col0 FROM tab1 cor0
----
12847
1964
3291

query I rowsort
SELECT + 30 * + 50 + cor0.col1 FROM tab1 cor0
----
1510
1513
1526

query I rowsort
SELECT ALL + + 82 * cor0.col0 + col1 * ( - col0 ) FROM tab1 AS cor0
----
168
4608
5520

query I rowsort
SELECT DISTINCT ( 32 ) * cor0.col0 FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT + 86 FROM tab0, tab2 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT + + 34 + col2 AS col0 FROM tab1 AS cor0
----
130
88
91

query I rowsort
SELECT col1 * - col1 + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - ( col2 ) * col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + 50 FROM tab0
----
50
50
50

query I rowsort
SELECT ALL ( 55 ) FROM tab2
----
55
55
55

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col2 AS REAL ) FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 + + ( - cor0.col1 ) * + col2 + + col2 * + col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col0 + + 17 FROM tab0 AS cor0
----
106
41
52

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col0 AS col0 FROM tab0 cor0
----
1224
543
7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-7419
SELECT + col2 + - ( col0 ) DIV col2 AS col2 FROM tab1 cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-7419
SELECT + col2 + - ( col0 ) / col2 AS col2 FROM tab1 cor0
----
54
56
96

query I rowsort
SELECT + - col1 + - ( + col1 ) + col2 AS col1 FROM tab0 AS cor0
----
-100
-139
-193

onlyif mysql # use DIV operator for integer division
query I rowsort label-7421
SELECT + col0 + 31 DIV col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-7421
SELECT + col0 + 31 / col0 FROM tab2 AS cor0
----
11
78
79

query I rowsort
SELECT ALL - col1 * + col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT col1 + ( - 79 * - col0 ) AS col0 FROM tab0
----
1982
2862
7122

query I rowsort
SELECT DISTINCT - 39 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-39

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1, tab1 AS cor2, tab2 AS cor3
----
13122 values hashing to 2d5a9f2490ef990f3b4dd2d7eb7a6887

query I rowsort
SELECT DISTINCT + col0 * col1 * col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT col2 * 19 * - tab0.col2 FROM tab0
----
-127756
-19
-20691

query I rowsort
SELECT DISTINCT + - col0 * col2 * col0 AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + + cor0.col0 * ( + col2 ) + col0 FROM tab1 AS cor0
----
165
3712
7760

skipif mysql # not compatible
query I rowsort
SELECT ALL + + cor0.col1 + - CAST ( col1 AS REAL ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * + ( - cor0.col0 ) + - col0 AS col0 FROM tab0 cor0
----
-70
-7387
-816

query I rowsort
SELECT + col2 * col0 - 85 FROM tab2
----
104
1943
2917

query I rowsort
SELECT - + 76 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

query I rowsort
SELECT + ( + col1 + col1 ) * tab2.col0 FROM tab2
----
2686
434
9204

query I rowsort
SELECT DISTINCT col1 * col2 + 44 + - col2 FROM tab1
----
1196
1394
557

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7436
SELECT + col2 * CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7436
SELECT + col2 * CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7437
SELECT - - col2 DIV + col1 + + col2 + col2 * col0 FROM tab0 AS cor0
----
36
7380
825

skipif mysql # not compatible
query I rowsort label-7437
SELECT - - col2 / + col1 + + col2 + col2 * col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL - - col0 + + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT col2 + - ( 47 ) * col1 FROM tab0 AS cor0
----
-4009
-4195
-4558

onlyif mysql # use DIV operator for integer division
query I rowsort label-7440
SELECT + col0 * col1 DIV - col2 + + col0 * cor0.col2 * col0 + + col2 FROM tab1 cor0
----
233518
539
614486

skipif mysql # not compatible
query I rowsort label-7440
SELECT + col0 * col1 / - col2 + + col0 * cor0.col2 * col0 + + col2 FROM tab1 cor0
----
233518
539
614486

query I rowsort
SELECT + col0 * + 9 + 30 + col0 FROM tab0 AS cor0
----
270
380
920

query I rowsort
SELECT - - 44 + - col0 FROM tab1 AS cor0
----
-20
-36
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-7443
SELECT - ( - col0 ) * 85 + - ( + col0 + - col2 ) DIV + 66 col0 FROM tab0 cor0
----
2040
2975
7565

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7443
SELECT - ( - col0 ) * 85 + - ( + col0 + - col2 ) / + 66 col0 FROM tab0 cor0
----
2040
2975
7565

query I rowsort
SELECT + 9 + - col2 * col1 FROM tab2 AS cor0
----
-1525
-637
-828

query I rowsort
SELECT - ( - cor0.col0 ) - 86 FROM tab1 AS cor0
----
-22
-6
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 54 col2 FROM tab1 cor0
----
54
54
54

query I rowsort
SELECT DISTINCT + cor0.col0 * + col1 * + col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - + col2 + - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT + col2 + - col2 * 93 AS col2 FROM tab1 cor0
----
-4968
-5244
-8832

query I rowsort
SELECT 48 * - col1 FROM tab2 AS cor0
----
-1488
-2832
-816

query I rowsort
SELECT ALL + col0 * col1 * 4 AS col2 FROM tab1 AS cor0
----
2560
312
4160

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-7453
SELECT DISTINCT cor0.col2 - col1 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-7453
SELECT DISTINCT cor0.col2 - col1 / cor0.col0 AS col1 FROM tab2 AS cor0
----
23
26
38

query I rowsort
SELECT DISTINCT - + cor0.col0 * + col0 - col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT col0 * - col2 + + 67 * 41 AS col2 FROM tab2 AS cor0
----
-255
2558
719

query I rowsort
SELECT ALL + + 98 * col1 * 77 FROM tab2 AS cor0
----
128282
233926
445214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 34 * col0 + 72 col2 FROM tab0 cor0
----
1262
3098
888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7458
SELECT ALL - + col2 * + CAST( - col1 AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

skipif mysql # not compatible
query I rowsort label-7458
SELECT ALL - + col2 * + CAST ( - col1 AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + + col1 - 14 AS col0 FROM tab1 AS cor0
----
-1
-4
12

query I rowsort
SELECT DISTINCT + col1 - - cor0.col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + - col0 * ( + col0 ) - col0 AS col2 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT ALL col1 - - tab1.col1 AS col0 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL + ( tab1.col2 * col1 ) - col0 AS col2 FROM tab1
----
1168
1401
506

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + + col2 * - 72 * - col1 AS col2 FROM tab1 AS cor0
----
101088
41040
89856

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 76 col1 FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT DISTINCT + ( - 11 ) + + col1 * col0 AS col1 FROM tab0 cor0
----
2053
3384
8088

query I rowsort
SELECT ( - ( + col2 ) ) + + ( + col2 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 55 AS col1 FROM tab1 AS cor0
----
55

query I rowsort
SELECT ALL - col2 * - col1 + col1 AS col0 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT 33 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT ALL - - ( - cor0.col0 ) * - col1 * + col0 FROM tab1 AS cor0
----
234
40960
83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7473
SELECT - CAST( NULL AS SIGNED ) + + col1 * - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7473
SELECT - CAST ( NULL AS INTEGER ) + + col1 * - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 29 AS col0 FROM tab0, tab2 AS cor0
----
29

query I rowsort
SELECT ALL 34 * - col0 AS col0 FROM tab0
----
-1190
-3026
-816

query I rowsort
SELECT - - cor0.col2 * col1 * + ( + col0 ) AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL ( 38 ) * col0 AS col0 FROM tab0
----
1330
3382
912

query I rowsort
SELECT ( - col1 ) + tab1.col2 AS col0 FROM tab1
----
28
47
83

query I rowsort
SELECT + ( - ( col0 ) ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT col2 * 16 FROM tab0
----
1312
16
528

query I rowsort
SELECT col0 - + 63 * col0 FROM tab0
----
-1488
-2170
-5518

query I rowsort
SELECT col0 * - col1 * col0 + + col0 * + col1 FROM tab2
----
-104754
-1302
-354354

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7483
SELECT ALL + CAST( NULL AS SIGNED ) * - 20 + + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7483
SELECT ALL + CAST ( NULL AS INTEGER ) * - 20 + + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 15 * + col2 AS col2 FROM tab1 cor0
----
1440
810
855

query I rowsort
SELECT DISTINCT + + 37 + + col0 * - col1 FROM tab0 AS cor0
----
-2027
-3358
-8062

query I rowsort
SELECT DISTINCT col2 * - col1 + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + ( + 13 ) AS col1 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT + + col0 * - ( - col2 ) AS col1 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7489
SELECT - - CAST( NULL AS SIGNED ) + + 22 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7489
SELECT - - CAST ( NULL AS INTEGER ) + + 22 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7490
SELECT - col1 DIV - 70 + + col1 DIV 79 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7490
SELECT - col1 / - 70 + + col1 / 79 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7491
SELECT ALL + 62 * + col0 - col2 * - col0 DIV col0 FROM tab0 AS cor0
----
1521
2171
5600

skipif mysql # not compatible
query I rowsort label-7491
SELECT ALL + 62 * + col0 - col2 * - col0 / col0 FROM tab0 AS cor0
----
1521
2171
5600

query I rowsort
SELECT + 95 + col0 FROM tab2 AS cor0
----
102
173
174

query I rowsort
SELECT DISTINCT 16 AS col1 FROM tab1 AS cor0
----
16

query I rowsort
SELECT 5 + - 85 * + col0 FROM tab2 AS cor0
----
-590
-6625
-6710

query I rowsort
SELECT + 46 + col0 * col0 AS col1 FROM tab1 AS cor0
----
4142
55
6446

query I rowsort
SELECT 28 * col0 AS col0 FROM tab1 AS cor0
----
1792
2240
84

query I rowsort
SELECT ALL + + col1 * - col2 + col1 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT - - col1 * 68 + + 34 FROM tab2 cor0
----
1190
2142
4046

query I rowsort
SELECT DISTINCT - + col2 * 25 FROM tab2 AS cor0
----
-650
-675
-950

onlyif mysql # use DIV operator for integer division
query I rowsort label-7500
SELECT ALL + col0 * 83 DIV + 45 FROM tab1 AS cor0
----
118
147
5

skipif mysql # not compatible
query I rowsort label-7500
SELECT ALL + col0 * 83 / + 45 FROM tab1 AS cor0
----
118
147
5

query I rowsort
SELECT DISTINCT tab1.col1 - col1 FROM tab1
----
0

query I rowsort
SELECT - col2 * 23 FROM tab0 cor0
----
-1886
-23
-759

query I rowsort
SELECT DISTINCT tab0.col1 * cor0.col1 FROM tab0, tab2 cor0, tab0 cor1
----
9 values hashing to 73681df8216070e2d6c1ade2e7109825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7504
SELECT CAST( NULL AS DECIMAL ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7504
SELECT CAST ( NULL AS REAL ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col2 + col1 + - ( col2 ) FROM tab0
----
86
91
97

query I rowsort
SELECT 91 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

query I rowsort
SELECT + 72 FROM tab2, tab1 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT + col0 * + 57 FROM tab2
----
399
4446
4503

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7509
SELECT DISTINCT CAST( NULL AS DECIMAL ) AS col2 FROM tab0, tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7509
SELECT DISTINCT CAST ( NULL AS REAL ) AS col2 FROM tab0, tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( ( col0 ) ) col0 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + 57 col2 FROM tab2 AS cor0
----
-2
26
40

query I rowsort
SELECT cor0.col0 * - 17 + col1 FROM tab1 cor0
----
-1078
-1347
-25

query I rowsort
SELECT + col0 * + col0 + col0 - + cor0.col2 FROM tab1 AS cor0
----
-42
4103
6384

query I rowsort
SELECT DISTINCT + cor1.col0 AS col0 FROM tab2, tab2 AS cor0, tab0 cor1
----
24
35
89

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab2, tab0 cor0, tab2 cor1
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - 15 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
-15

query I rowsort
SELECT - - 17 AS col2 FROM tab1, tab0, tab2 cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7518
SELECT ALL - col0 DIV - col1 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-7518
SELECT ALL - col0 / - col1 FROM tab1
----
0
6
6

query I rowsort
SELECT 42 * tab2.col1 AS col0 FROM tab2
----
1302
2478
714

query I rowsort
SELECT ( col2 + col1 ) * col0 FROM tab1
----
240
4288
8720

query I rowsort
SELECT - ( + 16 ) FROM tab2
----
-16
-16
-16

query I rowsort
SELECT + 42 + - col2 - - col2 AS col1 FROM tab1 cor0
----
42
42
42

query I rowsort
SELECT - ( cor0.col2 ) + col1 * + col1 AS col1 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT col1 * + 20 + + col0 AS col0 FROM tab1 cor0
----
264
340
523

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7525
SELECT - CAST( NULL AS SIGNED ) * + cor0.col0 + + col0 * col1 * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7525
SELECT - CAST ( NULL AS INTEGER ) * + cor0.col0 + + col0 * col1 * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7526
SELECT DISTINCT + 92 * + cor0.col0 + CAST( NULL AS DECIMAL ) col0 FROM tab1, tab2, tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7526
SELECT DISTINCT + 92 * + cor0.col0 + CAST ( NULL AS REAL ) col0 FROM tab1, tab2, tab0 AS cor0
----
NULL

query I rowsort
SELECT tab2.col0 AS col0 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT - ( col0 * - ( - 39 ) ) FROM tab0
----
-1365
-3471
-936

query I rowsort
SELECT - col2 * + ( ( + col0 ) ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + col1 + - 37 * - 91 FROM tab1 AS cor0
----
3377
3380
3393

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7531
SELECT + col2 + CAST( col2 AS SIGNED ) * + cor0.col2 AS col1 FROM tab0 cor0
----
1122
2
6806

skipif mysql # not compatible
query I rowsort label-7531
SELECT + col2 + CAST ( col2 AS INTEGER ) * + cor0.col2 AS col1 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT ALL col2 * - col2 - - 81 * ( col2 ) AS col0 FROM tab2 cor0
----
1430
1458
1634

query I rowsort
SELECT ALL - cor0.col1 * col0 + ( + col2 ) FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col2 FROM tab0 AS cor0
----
87
87
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7535
SELECT DISTINCT - col1 * col0 + CAST( 47 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-1296
-170
-4555

skipif mysql # not compatible
query I rowsort label-7535
SELECT DISTINCT - col1 * col0 + CAST ( 47 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1296
-170
-4555

query III rowsort
SELECT * FROM tab0 WHERE ( + col1 ) IN ( col0 * col0 + tab0.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7537
SELECT col1 + - col0 DIV + col1 AS col2 FROM tab1
----
26
4
7

skipif mysql # not compatible
query I rowsort label-7537
SELECT col1 + - col0 / + col1 AS col2 FROM tab1
----
26
4
7

query I rowsort
SELECT ALL + tab0.col2 - - col2 * + col1 * col0 FROM tab0
----
3396
664200
68145

onlyif mysql # use DIV operator for integer division
query I rowsort label-7539
SELECT DISTINCT + + cor0.col2 - + col2 DIV + ( col0 ) FROM tab1 AS cor0
----
36
57
95

skipif mysql # not compatible
query I rowsort label-7539
SELECT DISTINCT + + cor0.col2 - + col2 / + ( col0 ) FROM tab1 AS cor0
----
36
57
95

query I rowsort
SELECT DISTINCT col1 * - col2 + 81 FROM tab0 AS cor0
----
-16
-2757
-7381

query I rowsort
SELECT - 70 * col1 AS col1 FROM tab2
----
-1190
-2170
-4130

query I rowsort
SELECT DISTINCT cor0.col2 + + ( 83 ) FROM tab2 cor0
----
109
110
121

query I rowsort
SELECT ALL - + cor0.col2 + 84 - + 97 AS col2 FROM tab1 AS cor0
----
-109
-67
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col1 * 78 col1 FROM tab2 AS cor0
----
-1288
-2391
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 - + col1 col1 FROM tab1
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7546
SELECT DISTINCT - col2 - col2 * CAST( + ( col0 ) AS SIGNED ) AS col1 FROM tab1
----
-216
-3705
-7776

skipif mysql # not compatible
query I rowsort label-7546
SELECT DISTINCT - col2 - col2 * CAST ( + ( col0 ) AS INTEGER ) AS col1 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT col2 + - col2 + 11 * col1 AS col2 FROM tab0
----
1001
1067
946

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7548
SELECT ALL 62 - + col1 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7548
SELECT ALL 62 - + col1 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab2.col0 - + col0 FROM tab2
----
0

query I rowsort
SELECT + 67 - - tab0.col1 AS col2 FROM tab0
----
153
158
164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 + col1 - ( tab0.col2 ) col0 FROM tab0
----
-73
20
95

query I rowsort
SELECT ALL + col2 * col0 + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT DISTINCT - tab0.col0 + col0 + + col2 * col1 FROM tab0 WHERE ( NULL ) NOT BETWEEN col0 - + col0 * - col2 AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( col2 ) IN ( col2 * - col0 + col0 )
----

query I rowsort
SELECT col2 + - col2 * + col2 FROM tab2
----
-1406
-650
-702

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL <> - col2 * + tab1.col0
----

query I rowsort
SELECT col0 + - col0 FROM tab2 WHERE NOT col1 <> ( + col1 * + col2 + col1 )
----

query I rowsort
SELECT DISTINCT col1 + + col1 * - col0 AS col1 FROM tab1
----
-1027
-52
-630

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col0 * - col1 >= ( NULL )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( + col2 * - col2 ) = col1 + col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col0 - + col2 * - col2 AS col0 FROM tab2
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-7562
SELECT + tab2.col2 DIV - col0 col2 FROM tab2
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7562
SELECT + tab2.col2 / - col0 col2 FROM tab2
----
-3
0
0

query I rowsort
SELECT col0 + col2 + tab0.col2 AS col0 FROM tab0
----
253
37
90

query I rowsort
SELECT col0 - col2 AS col1 FROM tab1
----
-16
-51
7

query III rowsort
SELECT * FROM tab0 WHERE ( col0 ) <> ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL BETWEEN NULL AND col2
----

query I rowsort
SELECT - col0 / col0 FROM tab1 WHERE + col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT - tab2.col0 + col1 AS col2 FROM tab2
----
-19
-62
24

query I rowsort
SELECT tab0.col1 * + col0 AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - col2 + col2 + + col2 * col1 * + tab1.col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT col2 * - col0 + - col2 FROM tab2 WHERE NOT + col0 * col1 = NULL
----

query I rowsort
SELECT ALL + ( + col1 ) + ( col2 * + cor0.col2 ) FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL - 54 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

query I rowsort
SELECT ALL + ( + 40 ) * - col2 AS col0 FROM tab1 cor0
----
-2160
-2280
-3840

skipif mysql # not compatible
query I rowsort
SELECT ALL + - 15 + cor0.col2 * cor0.col1 * CAST ( - col2 AS REAL ) FROM tab0 AS cor0
----
-112
-611899
-93669

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 * - 69 col0 FROM tab1 AS cor0
----
-181
-4406
-5507

query I rowsort
SELECT col1 * cor0.col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - - 37 FROM tab2 AS cor0
----
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-7579
SELECT - cor0.col2 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-7579
SELECT - cor0.col2 / - col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( + cor0.col2 ) AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL - ( + col2 ) + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT 52 AS col0 FROM tab1 AS cor0
----
52

query I rowsort
SELECT + ( - cor0.col0 ) + - 29 AS col0 FROM tab0 AS cor0
----
-118
-53
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col2 * - 49 col2 FROM tab0 AS cor0
----
-1715
-357602
-38808

query I rowsort
SELECT DISTINCT + col1 * + 25 + - 32 FROM tab1
----
218
293
618

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 * + ( - col1 ) col0 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-7587
SELECT DISTINCT + col0 DIV col0 + + col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-7587
SELECT DISTINCT + col0 / col0 + + col2 AS col1 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7588
SELECT DISTINCT - col0 DIV + 90 + + col0 + cor0.col0 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-7588
SELECT DISTINCT - col0 / + 90 + + col0 + cor0.col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT col0 + - col0 * - col2 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT ALL + cor0.col0 - col2 * col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + + col1 + ( + 15 * + cor0.col0 ) AS col1 FROM tab2 AS cor0
----
1202
1229
136

onlyif mysql # use DIV operator for integer division
query I rowsort label-7592
SELECT DISTINCT - - col1 + + col1 DIV + 96 AS col0 FROM tab2 cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-7592
SELECT DISTINCT - - col1 + + col1 / + 96 AS col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + + col0 * 61 AS col0 FROM tab1 AS cor0
----
183
3904
4880

onlyif mysql # use DIV operator for integer division
query I rowsort label-7594
SELECT + cor0.col0 * + 2 + col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
-2
128
160

skipif mysql # not compatible
query I rowsort label-7594
SELECT + cor0.col0 * + 2 + col1 / - col0 AS col2 FROM tab1 AS cor0
----
-2
128
160

query I rowsort
SELECT ALL - col1 * 29 FROM tab0 AS cor0
----
-2494
-2639
-2813

query I rowsort
SELECT DISTINCT + col1 * - col1 * col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT + ( - 80 ) AS col0 FROM tab0 AS cor0
----
-80

query I rowsort
SELECT ALL 18 + col2 FROM tab0 AS cor0
----
100
19
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7599
SELECT DISTINCT + + 81 + + col0 DIV col0 AS col0 FROM tab0 AS cor0
----
82

skipif mysql # not compatible
query I rowsort label-7599
SELECT DISTINCT + + 81 + + col0 / col0 AS col0 FROM tab0 AS cor0
----
82

query I rowsort
SELECT DISTINCT + + col0 + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - 72 * - col0 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT - + 42 AS col0 FROM tab1 AS cor0
----
-42
-42
-42

query I rowsort
SELECT ALL - cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT 7 * tab1.col0 + 63 FROM tab1
----
511
623
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7605
SELECT DISTINCT + cor0.col0 * + CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7605
SELECT DISTINCT + cor0.col0 * + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col0 + col2 * 2 col2 FROM tab0 AS cor0
----
2130
3397
8263

query I rowsort
SELECT DISTINCT + ( + col2 ) + - col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT + col2 + + cor0.col0 * + 7 * col1 + col0 AS col1 FROM tab1 AS cor0
----
4601
603
7456

query I rowsort
SELECT ALL - cor0.col0 - col2 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + 78 + - cor0.col1 AS col1 FROM tab1 cor0
----
52
65
68

query I rowsort
SELECT DISTINCT - col0 * - col2 + 25 AS col0 FROM tab1 AS cor0
----
187
3673
7705

query I rowsort
SELECT ALL - + cor0.col0 * - col0 + + 43 * + 42 * + cor0.col1 FROM tab0 AS cor0
----
155892
172267
176407

query I rowsort
SELECT ALL 52 * - col1 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT ALL - col0 * col0 + + col2 + col0 AS col0 FROM tab2 AS cor0
----
-15
-5980
-6124

query I rowsort
SELECT + - 21 + col2 FROM tab2 AS cor0
----
17
5
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7616
SELECT ALL - + col0 DIV cor0.col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7616
SELECT ALL - + col0 / cor0.col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + - col1 * + col0 - + col0 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT - + cor0.col1 * col0 + 1 FROM tab2 AS cor0
----
-1342
-216
-4601

query I rowsort
SELECT ALL cor0.col0 + col2 AS col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - col2 + ( - 6 * col1 + + col1 ) AS col0 FROM tab0 cor0
----
-463
-486
-537

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7621
SELECT ALL - - col1 / + CAST( NULL AS SIGNED ) + - col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7621
SELECT ALL - - col1 / + CAST ( NULL AS INTEGER ) + - col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + 22 * + col2 AS col1 FROM tab0 cor0
----
1722
21
693

query I rowsort
SELECT DISTINCT + - cor0.col2 * 48 - + col1 * col2 AS col1 FROM tab2 AS cor0
----
-2133
-2470
-2782

onlyif mysql # use DIV operator for integer division
query I rowsort label-7624
SELECT ALL col2 DIV - col1 + - col2 + col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7624
SELECT ALL col2 / - col1 + - col2 + col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7625
SELECT + CAST( 12 AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d4f5a8e032294c3b9342821617800972

skipif mysql # not compatible
query I rowsort label-7625
SELECT + CAST ( 12 AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT - col2 * - col0 + 33 FROM tab1
----
195
3681
7713

query I rowsort
SELECT - + 29 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( - cor0.col2 ) col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7629
SELECT ALL + - cor0.col2 * 33 + + cor0.col1 * CAST( 79 * col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
10183
51622
6019

skipif mysql # not compatible
query I rowsort label-7629
SELECT ALL + - cor0.col2 * 33 + + cor0.col1 * CAST ( 79 * col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
10183
51622
6019

query I rowsort
SELECT ALL - col1 * + col0 + col1 AS col2 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - - 3 AS col1 FROM tab2 AS cor0
----
3

query I rowsort
SELECT + 37 FROM tab1 cor0
----
37
37
37

query I rowsort
SELECT ALL + col0 * + 85 * - col1 + 48 AS col2 FROM tab1 AS cor0
----
-54352
-6582
-88352

query I rowsort
SELECT cor0.col1 * 75 AS col0 FROM tab2 AS cor0
----
1275
2325
4425

query I rowsort
SELECT DISTINCT + col2 + 90 FROM tab1 AS cor0
----
144
147
186

query I rowsort
SELECT - + col1 * - col1 - col2 AS col0 FROM tab1 AS cor0
----
43
622
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7637
SELECT + CAST( + tab2.col2 AS SIGNED ) + + col1 + 79 AS col0 FROM tab2
----
134
137
164

skipif mysql # not compatible
query I rowsort label-7637
SELECT + CAST ( + tab2.col2 AS INTEGER ) + + col1 + 79 AS col0 FROM tab2
----
134
137
164

query I rowsort
SELECT - 99 * - col0 + + col0 AS col1 FROM tab2
----
700
7800
7900

query I rowsort
SELECT + + 40 * - col0 FROM tab2 AS cor0
----
-280
-3120
-3160

query I rowsort
SELECT ( - 7 ) FROM tab1
----
-7
-7
-7

query I rowsort
SELECT - - 49 + - col2 * - 24 FROM tab0 AS cor0
----
2017
73
841

query I rowsort
SELECT - 73 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

onlyif mysql # use DIV operator for integer division
query I rowsort label-7643
SELECT ALL tab2.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-7643
SELECT ALL tab2.col2 / + col0 col2 FROM tab2
----
0
0
3

query I rowsort
SELECT DISTINCT + cor0.col1 + + 75 * col2 AS col0 FROM tab0 AS cor0
----
172
2561
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7645
SELECT - cor0.col2 * + CAST( NULL AS SIGNED ) + - col0 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7645
SELECT - cor0.col2 * + CAST ( NULL AS INTEGER ) + - col0 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 + - 3 FROM tab2 AS cor0
----
14
28
56

query I rowsort
SELECT ALL 45 * + col1 AS col1 FROM tab1
----
1170
450
585

query I rowsort
SELECT tab1.col1 - col2 AS col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ( cor0.col1 ) * + 10 FROM tab2 AS cor0
----
170
310
590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 + col2 * + col1 col2 FROM tab2
----
1566
2090
2210

query I rowsort
SELECT DISTINCT - tab2.col0 * + ( tab2.col1 ) AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + tab2.col1 * + 56 FROM tab2
----
1736
3304
952

query I rowsort
SELECT ALL - col1 + col0 + + 26 * + col0 AS col0 FROM tab2 AS cor0
----
158
2047
2116

query I rowsort
SELECT col1 * + ( 33 + col1 ) * + 95 FROM tab2
----
188480
515660
80750

query I rowsort
SELECT DISTINCT - 9 * col2 AS col1 FROM tab1 AS cor0
----
-486
-513
-864

query I rowsort
SELECT - col0 * 62 FROM tab0 AS cor0
----
-1488
-2170
-5518

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7657
SELECT + + CAST( + cor0.col0 AS SIGNED ) * + cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-7657
SELECT + + CAST ( + cor0.col0 AS INTEGER ) * + cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT 65 * 9 FROM tab2 AS cor0
----
585
585
585

query I rowsort
SELECT + - cor0.col0 * 67 AS col1 FROM tab1 AS cor0
----
-201
-4288
-5360

query I rowsort
SELECT - 95 * ( col0 ) * + col2 AS col1 FROM tab2 AS cor0
----
-17955
-192660
-285190

query I rowsort
SELECT col2 + tab2.col0 * col2 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL + + col1 * cor0.col1 + + col0 * col0 AS col0 FROM tab2 AS cor0
----
1010
6530
9565

query I rowsort
SELECT ALL + col0 + col0 + - 44 AS col1 FROM tab0 AS cor0
----
134
26
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col2 + + col2 * + 36 - + col1 col2 FROM tab2 AS cor0
----
1778
1997
2411

query I rowsort
SELECT - - 94 * + col2 + + col0 * + col0 FROM tab0 AS cor0
----
1319
15629
3678

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7666
SELECT CAST( - col1 AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-7666
SELECT CAST ( - col1 AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT 22 * + 84 FROM tab2 AS cor0
----
1848

onlyif mysql # use DIV operator for integer division
query I rowsort label-7668
SELECT + col2 + + col2 DIV col0 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-7668
SELECT + col2 + + col2 / col0 FROM tab1 AS cor0
----
57
72
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7669
SELECT DISTINCT + ( col2 ) + + cor0.col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7669
SELECT DISTINCT + ( col2 ) + + cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 67 * 16 FROM tab2 AS cor0
----
1072
1072
1072

query I rowsort
SELECT + - 49 - - 83 AS col1 FROM tab1 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7672
SELECT DISTINCT col2 DIV - ( col1 ) + - 55 * col1 FROM tab2 AS cor0
----
-1705
-3245
-937

skipif mysql # not compatible
query I rowsort label-7672
SELECT DISTINCT col2 / - ( col1 ) + - 55 * col1 FROM tab2 AS cor0
----
-1705
-3245
-937

query I rowsort
SELECT + 61 - + col2 FROM tab1 AS cor0
----
-35
4
7

query I rowsort
SELECT DISTINCT - - col1 * col2 - cor0.col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT + - 21 * ( col0 ) + - ( + col2 ) FROM tab2 AS cor0
----
-1664
-1697
-174

query I rowsort
SELECT DISTINCT + col0 * + 54 FROM tab1 AS cor0
----
162
3456
4320

query I rowsort
SELECT + 97 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT col2 * + col1 * ( col0 ) + col1 FROM tab1 cor0
----
36490
4238
99853

onlyif mysql # use DIV operator for integer division
query I rowsort label-7679
SELECT + col0 + - col1 * 2 DIV + 60 AS col2 FROM tab0 AS cor0
----
22
32
86

skipif mysql # not compatible
query I rowsort label-7679
SELECT + col0 + - col1 * 2 / + 60 AS col2 FROM tab0 AS cor0
----
22
32
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7680
SELECT - 67 DIV col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-7680
SELECT - 67 / col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 * 24 col0 FROM tab2 AS cor0
----
4536
48672
72048

query I rowsort
SELECT + col0 + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT cor0.col2 * - col0 + col1 AS col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT col2 * + col1 + 96 * + col0 AS col1 FROM tab2 AS cor0
----
1509
8230
9022

query I rowsort
SELECT DISTINCT + 32 + col2 FROM tab1 AS cor0
----
128
86
89

query I rowsort
SELECT ALL - col1 * + ( col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + + cor0.col2 + - col2 * - col2 FROM tab2 cor0
----
1482
702
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 12 ) * cor1.col0 col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8e5ea344e010f81883d3febf1b417e51

query I rowsort
SELECT - 50 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT - - 49 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT col0 * - cor0.col0 * 83 + col2 * col2 AS col2 FROM tab1 AS cor0
----
-336719
-521984
2169

query I rowsort
SELECT - + col1 * - col1 + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + ( tab2.col2 ) + + col0 AS col2 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7694
SELECT DISTINCT - col2 * + ( + col1 ) + col2 DIV - 34 FROM tab2 AS cor0
----
-1534
-647
-837

skipif mysql # not compatible
query I rowsort label-7694
SELECT DISTINCT - col2 * + ( + col1 ) + col2 / - 34 FROM tab2 AS cor0
----
-1534
-647
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7695
SELECT - col2 DIV 20 FROM tab1 AS cor0
----
-2
-2
-4

skipif mysql # not compatible
query I rowsort label-7695
SELECT - col2 / 20 FROM tab1 AS cor0
----
-2
-2
-4

query I rowsort
SELECT + col0 * - col0 + col1 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - - col2 * - col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT + - col0 + 79 * cor0.col0 FROM tab1 AS cor0
----
234
4992
6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-7699
SELECT ALL + + col0 DIV 57 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7699
SELECT ALL + + col0 / 57 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT - cor0.col0 + - cor0.col0 FROM tab0 cor0
----
-178
-48
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7701
SELECT ALL - col0 + CAST( 86 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-3
51
62

skipif mysql # not compatible
query I rowsort label-7701
SELECT ALL - col0 + CAST ( 86 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-3
51
62

query I rowsort
SELECT ALL + col1 * 33 FROM tab1 cor0
----
330
429
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-7703
SELECT + + cor0.col2 * col2 + 25 DIV - col2 + - col0 FROM tab0 cor0
----
-59
1065
6635

skipif mysql # not compatible
query I rowsort label-7703
SELECT + + cor0.col2 * col2 + 25 / - col2 + - col0 FROM tab0 cor0
----
-59
1065
6635

query I rowsort
SELECT ALL col2 * + tab1.col1 + 84 FROM tab1
----
1332
1488
654

query I rowsort
SELECT ALL - col1 + - col2 * + col1 AS col1 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - ( col1 ) + ( 26 ) AS col2 FROM tab0
----
-60
-65
-71

query I rowsort
SELECT DISTINCT + 42 AS col0 FROM tab2, tab2 cor0
----
42

query I rowsort
SELECT DISTINCT col1 * + 96 FROM tab2
----
1632
2976
5664

query I rowsort
SELECT ALL - col0 * + 57 * cor0.col1 FROM tab1 AS cor0
----
-36480
-4446
-59280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7710
SELECT ALL + col1 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7710
SELECT ALL + col1 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * ( - 78 ) FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT ALL - col2 * ( + 38 + col0 ) * col0 AS col0 FROM tab2
----
-235248
-351234
-8505

query I rowsort
SELECT + + cor0.col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + ( - col2 ) col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-7715
SELECT DISTINCT - col1 DIV 53 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7715
SELECT DISTINCT - col1 / 53 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + ( - tab0.col0 * tab0.col0 ) FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + - cor1.col1 + - ( - cor0.col1 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to d7e632a100c1d4cc2dc87e3e95c20f13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7718
SELECT + col2 * col1 + cor0.col0 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7718
SELECT + col2 * col1 + cor0.col0 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 52 AS col2 FROM tab0 cor0
----
-52
-52
-52

query I rowsort
SELECT 36 + cor0.col1 AS col0 FROM tab0, tab2 cor0 CROSS JOIN tab2, tab1 AS cor1
----
81 values hashing to e06270df36cef74e7d248fa7059690a1

query I rowsort
SELECT DISTINCT col1 * - col2 * + col1 + - col1 - col2 * tab1.col2 FROM tab1
----
-25453
-39446
-8959

query I rowsort
SELECT col2 * cor0.col1 + - 26 AS col2 FROM tab1 AS cor0
----
1222
1378
544

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7723
SELECT ALL + tab1.col2 + - col2 + CAST( + col1 AS SIGNED ) AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7723
SELECT ALL + tab1.col2 + - col2 + CAST ( + col1 AS INTEGER ) AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT col1 + - col2 * + col0 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL + + col1 + + cor0.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 + - cor0.col1 * + 81 * - col0 col2 FROM tab1 AS cor0
----
51897
6372
84336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 92 col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col1 col2 FROM tab1 cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7729
SELECT + - col0 DIV - col2 + col1 AS col0 FROM tab1 cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-7729
SELECT + - col0 / - col2 + col1 AS col0 FROM tab1 cor0
----
11
13
26

query I rowsort
SELECT - col2 * 45 FROM tab2 AS cor0
----
-1170
-1215
-1710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7731
SELECT CAST( col1 AS SIGNED ) + col2 * - cor0.col0 AS col1 FROM tab2 cor0
----
-158
-1969
-2985

skipif mysql # not compatible
query I rowsort label-7731
SELECT CAST ( col1 AS INTEGER ) + col2 * - cor0.col0 AS col1 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT - 55 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7733
SELECT - col2 * + col2 DIV + ( + tab1.col2 ) + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7733
SELECT - col2 * + col2 / + ( + tab1.col2 ) + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - 0 * + col0 * + col1 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * cor0.col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 * - tab0.col0 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + ( + 6 ) AS col0 FROM tab2 cor0
----
6
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7739
SELECT - - col2 * col0 DIV col1 - - col2 FROM tab1 AS cor0
----
421
60
686

skipif mysql # not compatible
query I rowsort label-7739
SELECT - - col2 * col0 / col1 - - col2 FROM tab1 AS cor0
----
421
60
686

query I rowsort
SELECT ( col1 + + col1 ) * - col0 AS col1 FROM tab2
----
-2686
-434
-9204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + + col1 * col1 col2 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT - col1 - - col0 * + col2 AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT + col0 * 38 * cor0.col0 AS col2 FROM tab2 AS cor0
----
1862
231192
237158

query I rowsort
SELECT ALL + cor0.col2 + - col1 * + col1 + + col1 FROM tab2 AS cor0
----
-234
-3396
-903

query I rowsort
SELECT DISTINCT + cor0.col1 + + col0 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - 73 * col0 FROM tab0 AS cor0
----
-1752
-2555
-6497

query I rowsort
SELECT ALL 76 * - col2 AS col0 FROM tab1 cor0
----
-4104
-4332
-7296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7748
SELECT - col0 + - col2 * - CAST( NULL AS SIGNED ) / col2 + - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7748
SELECT - col0 + - col2 * - CAST ( NULL AS INTEGER ) / col2 + - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7749
SELECT col1 * CAST( + col1 AS SIGNED ) * + col2 AS col1 FROM tab0 cor0
----
244068
679042
9409

skipif mysql # not compatible
query I rowsort label-7749
SELECT col1 * CAST ( + col1 AS INTEGER ) * + col2 AS col1 FROM tab0 cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - col0 * 4 AS col1 FROM tab2 AS cor0
----
-28
-312
-316

query I rowsort
SELECT DISTINCT - col2 * + 70 * tab1.col0 FROM tab1
----
-11340
-255360
-537600

onlyif mysql # use DIV operator for integer division
query I rowsort label-7752
SELECT + col2 + 7 DIV col2 FROM tab0 AS cor0
----
33
8
82

skipif mysql # not compatible
query I rowsort label-7752
SELECT + col2 + 7 / col2 FROM tab0 AS cor0
----
33
8
82

query I rowsort
SELECT + + col0 * cor0.col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT ( - col1 ) * - col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col0 + + cor0.col2 * 67 FROM tab0 AS cor0
----
102
2235
5583

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 + + 23 col2 FROM tab2
----
1557
669
860

query I rowsort
SELECT col2 * + 23 + col0 AS col0 FROM tab1 cor0
----
1245
1375
2288

query I rowsort
SELECT 12 * 67 + tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 851fefc594bd9393d4b7f27197b18f58

query I rowsort
SELECT - - col1 * - col0 + + col0 * - col2 AS col0 FROM tab2 AS cor0
----
-406
-4345
-6630

query I rowsort
SELECT - cor0.col1 * col2 + - col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT - + 6 * cor0.col0 FROM tab0 cor0
----
-144
-210
-534

query I rowsort
SELECT - 99 * cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to e1952255fc5bfefcf4cfde66cf399d57

query I rowsort
SELECT - + col2 + 82 AS col2 FROM tab1 AS cor0
----
-14
25
28

query I rowsort
SELECT - col0 * 53 FROM tab0 AS cor0
----
-1272
-1855
-4717

query I rowsort
SELECT DISTINCT + + 20 * col0 AS col0 FROM tab2 AS cor0
----
140
1560
1580

query I rowsort
SELECT 82 + + col0 FROM tab2 AS cor0
----
160
161
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7767
SELECT - cor0.col2 + + cor0.col1 + + CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
100
139
193

skipif mysql # not compatible
query I rowsort label-7767
SELECT - cor0.col2 + + cor0.col1 + + CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT DISTINCT + - 93 * col2 + - col1 AS col0 FROM tab0 AS cor0
----
-190
-3155
-7717

query I rowsort
SELECT col2 + col1 * col2 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 36 - - col0 col0 FROM tab0 AS cor0
----
125
60
71

query I rowsort
SELECT ALL col2 * - col2 * col0 AS col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + cor0.col2 + cor0.col2 * - 9 AS col2 FROM tab2 AS cor0
----
-208
-216
-304

query I rowsort
SELECT 93 AS col2 FROM tab1
----
93
93
93

query I rowsort
SELECT tab1.col0 * + col0 * col0 AS col1 FROM tab1
----
262144
27
512000

onlyif mysql # use DIV operator for integer division
query I rowsort label-7775
SELECT DISTINCT col2 + - 53 DIV - col0 + + col2 col0 FROM tab0
----
164
3
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7775
SELECT DISTINCT col2 + - 53 / - col0 + + col2 col0 FROM tab0
----
164
3
68

query I rowsort
SELECT + col0 + + col1 * tab1.col1 + - tab1.col1 AS col0 FROM tab1
----
154
236
653

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 + 76 + + col2 col1 FROM tab2
----
110
180
193

query I rowsort
SELECT 28 + + col0 AS col2 FROM tab2
----
106
107
35

query I rowsort
SELECT + 94 + col2 FROM tab1 AS cor0
----
148
151
190

query I rowsort
SELECT DISTINCT + col1 - - col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ( - col1 ) * + 0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - ( col1 ) * - ( - col1 ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT tab0.col0 * 85 * - ( - col2 ) FROM tab0
----
2975
620330
67320

query I rowsort
SELECT DISTINCT + col0 - - col1 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT col0 * + 1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT 60 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
60

query I rowsort
SELECT DISTINCT - col2 - 61 AS col1 FROM tab0
----
-143
-62
-94

query I rowsort
SELECT col0 + - 2 AS col0 FROM tab2 cor0
----
5
76
77

query I rowsort
SELECT cor0.col1 - col2 FROM tab2 cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7791
SELECT + + cor0.col1 DIV + 38 - col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7791
SELECT + + cor0.col1 / + 38 - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT col0 * col1 + col2 * col1 * - col0 FROM tab2 AS cor0
----
-115050
-49691
-5642

query I rowsort
SELECT - - ( + col0 ) + col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7794
SELECT DISTINCT + - col1 DIV 38 + - col1 * - col2 AS col1 FROM tab2 AS cor0
----
1533
646
837

skipif mysql # not compatible
query I rowsort label-7794
SELECT DISTINCT + - col1 / 38 + - col1 * - col2 AS col1 FROM tab2 AS cor0
----
1533
646
837

query I rowsort
SELECT DISTINCT - - ( col1 ) * + cor0.col0 + + col2 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col1 + cor0.col0 * col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - 7 * - 56 AS col0 FROM tab0 cor0
----
392
392
392

query I rowsort
SELECT + col2 * - 58 AS col0 FROM tab2 AS cor0
----
-1508
-1566
-2204

query I rowsort
SELECT + 34 + 89 * + col0 AS col2 FROM tab0 AS cor0
----
2170
3149
7955

query I rowsort
SELECT + col2 * + ( + col0 * + col0 ) FROM tab0
----
1225
19008
649522

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7801
SELECT - col0 * CAST( 46 AS SIGNED ) FROM tab2
----
-322
-3588
-3634

skipif mysql # not compatible
query I rowsort label-7801
SELECT - col0 * CAST ( 46 AS INTEGER ) FROM tab2
----
-322
-3588
-3634

query I rowsort
SELECT ALL - 60 + cor0.col1 FROM tab2 AS cor0
----
-1
-29
-43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7803
SELECT CAST( 16 AS SIGNED ) + col0 * - col1 FROM tab1 AS cor0
----
-1024
-62
-624

skipif mysql # not compatible
query I rowsort label-7803
SELECT CAST ( 16 AS INTEGER ) + col0 * - col1 FROM tab1 AS cor0
----
-1024
-62
-624

query I rowsort
SELECT - col0 * + col2 + - cor0.col2 + - col1 * 2 AS col0 FROM tab2 AS cor0
----
-2172
-278
-3074

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7805
SELECT ALL - - CAST( NULL AS SIGNED ) + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7805
SELECT ALL - - CAST ( NULL AS INTEGER ) + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 - - col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - + col1 * + col1 - - col2 * + 62 AS col2 FROM tab0 AS cor0
----
-3197
-5350
-9347

query I rowsort
SELECT + 11 * + col0 + col2 FROM tab1 AS cor0
----
761
87
976

query I rowsort
SELECT ALL 45 + - col0 AS col1 FROM tab1
----
-19
-35
42

query I rowsort
SELECT + + col2 * col2 + col2 FROM tab0 cor0
----
1122
2
6806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7811
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * - 65 + col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7811
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * - 65 + col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + 44 - col0 FROM tab2 AS cor0
----
-34
-35
37

query I rowsort
SELECT - 35 * - 33 - col1 * 42 * - 37 AS col0 FROM tab0 AS cor0
----
134799
142569
151893

query I rowsort
SELECT - 96 * - cor0.col2 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b3f8e48e8e10e4595171d14efb9bf7cc

query I rowsort
SELECT DISTINCT 42 + + 98 AS col1 FROM tab1 AS cor0
----
140

query I rowsort
SELECT + 27 - 40 FROM tab1 AS cor0
----
-13
-13
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-7817
SELECT ALL + cor0.col2 + - 17 + - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
-16
16
65

skipif mysql # not compatible
query I rowsort label-7817
SELECT ALL + cor0.col2 + - 17 + - col2 / col1 AS col0 FROM tab0 AS cor0
----
-16
16
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7818
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - 55 / col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7818
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - 55 / col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT 47 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-39
-44
-50

query I rowsort
SELECT ( col0 ) * + ( + col1 ) + - col2 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT - - col0 * - col0 + col2 * 2 * col1 AS col0 FROM tab1 AS cor0
----
-2956
-3904
2799

query I rowsort
SELECT ALL 36 + + col2 * - col2 FROM tab1 AS cor0
----
-2880
-3213
-9180

query I rowsort
SELECT ALL + cor0.col1 * cor0.col1 + - col1 * - col0 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT DISTINCT + + col2 * - col0 + - col0 * + col2 AS col0 FROM tab0 AS cor0
----
-14596
-1584
-70

query I rowsort
SELECT - col1 * col1 + col0 * col1 AS col0 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT ALL cor0.col0 + - col1 * + 48 FROM tab1 AS cor0
----
-1245
-416
-544

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7827
SELECT ALL - CAST( NULL AS SIGNED ) * col2 + col1 * - ( col0 * 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-7827
SELECT ALL - CAST ( NULL AS INTEGER ) * col2 + col1 * - ( col0 * tab0.col1 ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 2 + 40 FROM tab0
----
38
38
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7829
SELECT ALL tab2.col2 + + col1 * col1 + 43 DIV 23 FROM tab2
----
328
3508
989

skipif mysql # not compatible
query I rowsort label-7829
SELECT ALL tab2.col2 + + col1 * col1 + 43 / 23 FROM tab2
----
328
3508
989

query I rowsort
SELECT DISTINCT - tab2.col1 + tab2.col1 * col0 * - col2 FROM tab2
----
-119711
-51051
-5890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 + - col1 col0 FROM tab2
----
1326
186
4543

query I rowsort
SELECT DISTINCT col0 + - ( 47 ) FROM tab0 cor0
----
-12
-23
42

query I rowsort
SELECT col2 * - 6 AS col0 FROM tab0 AS cor0
----
-198
-492
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + col0 * col2 col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT + col0 * + 79 AS col2 FROM tab0 cor0
----
1896
2765
7031

query I rowsort
SELECT + col1 + - 80 * - col0 AS col0 FROM tab2 cor0
----
591
6299
6337

query I rowsort
SELECT - - col1 * 38 AS col2 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT DISTINCT - + cor0.col0 AS col1 FROM tab2, tab0, tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 83 + col1 FROM tab2
----
100
114
142

query I rowsort
SELECT 38 - - col0 FROM tab1
----
102
118
41

query I rowsort
SELECT ALL col2 * col2 + 7 AS col0 FROM tab1 AS cor0
----
2923
3256
9223

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 + - 60 * cor0.col2 col2 FROM tab1 AS cor0
----
-1836
-2850
-4512

query I rowsort
SELECT DISTINCT + + col1 - + cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT ALL - 27 * - 5 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 17b10acf07e16d67b01bcec56d331023

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * cor0.col0 col2 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT ALL - - cor0.col2 * 20 FROM tab2 AS cor0
----
520
540
760

query I rowsort
SELECT + cor0.col1 * - 93 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT ALL col0 - 80 AS col1 FROM tab0 AS cor0
----
-45
-56
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7849
SELECT DISTINCT col1 + + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-7849
SELECT DISTINCT col1 + + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - col1 * + col1 * 8 AS col1 FROM tab0
----
-59168
-66248
-75272

query I rowsort
SELECT + col0 * - ( tab0.col0 * col0 + + 53 * col1 ) FROM tab0
----
-1134216
-123216
-222810

query I rowsort
SELECT + col0 + col2 * col2 * + col1 AS col1 FROM tab0 AS cor0
----
132
611973
93678

query I rowsort
SELECT + - col2 + - col2 * cor0.col2 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-17602
-19710
-54910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 col0 FROM tab1 AS cor0
----
-89
-89
-89

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7856
SELECT CAST( col1 AS SIGNED ) + + col2 FROM tab2
----
55
58
85

skipif mysql # not compatible
query I rowsort label-7856
SELECT CAST ( col1 AS INTEGER ) + + col2 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL ( + col2 ) * - tab2.col1 * col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT - 44 * - col2 FROM tab0 cor0
----
1452
3608
44

query I rowsort
SELECT ALL tab0.col0 * 92 * - col2 FROM tab0
----
-3220
-671416
-72864

query I rowsort
SELECT ALL 72 * col0 * tab0.col2 AS col1 FROM tab0
----
2520
525456
57024

onlyif mysql # use DIV operator for integer division
query I rowsort label-7861
SELECT - ( col2 ) DIV - col0 + + col0 FROM tab2
----
10
78
79

skipif mysql # not compatible
query I rowsort label-7861
SELECT - ( col2 ) / - col0 + + col0 FROM tab2
----
10
78
79

query I rowsort
SELECT ALL - col0 * - cor0.col2 + col0 * col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT ALL 32 + col0 AS col2 FROM tab2 AS cor0
----
110
111
39

query I rowsort
SELECT DISTINCT col2 * ( col2 ) + - col1 * col1 FROM tab0
----
-1557
-6307
-9408

query I rowsort
SELECT + col0 * 33 + - col0 FROM tab1
----
2048
2560
96

query I rowsort
SELECT col0 + col0 + - cor0.col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7867
SELECT DISTINCT + + 7 + + cor1.col0 DIV cor0.col1 col2 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
10
11
7
8
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7867
SELECT DISTINCT + + 7 + + cor1.col0 / cor0.col1 col2 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
10
11
7
8
9

query I rowsort
SELECT - 67 AS col1 FROM tab2
----
-67
-67
-67

query I rowsort
SELECT + 76 * - 30 FROM tab1
----
-2280
-2280
-2280

query I rowsort
SELECT DISTINCT + col1 * + tab0.col2 AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + col0 + 34 AS col2 FROM tab2
----
112
113
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7872
SELECT - CAST( + col1 AS SIGNED ) * col1 * col2 FROM tab1
----
-16224
-36504
-5700

skipif mysql # not compatible
query I rowsort label-7872
SELECT - CAST ( + col1 AS INTEGER ) * col1 * col2 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT + col0 * col1 + - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT 73 AS col1 FROM tab1, tab1 AS cor0
----
73

query I rowsort
SELECT DISTINCT - col0 * col2 + + cor0.col0 - + col1 FROM tab2 cor0
----
-2009
-213
-2940

query I rowsort
SELECT + - ( + 79 ) * + cor0.col0 + col1 FROM tab1 AS cor0
----
-211
-5046
-6307

query I rowsort
SELECT ALL - + 68 FROM tab2 AS cor0
----
-68
-68
-68

query I rowsort
SELECT ALL col2 * ( col0 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - - col1 * col0 + col0 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-3008
-6640
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-7880
SELECT ALL col1 * - col0 DIV col0 AS col2 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7880
SELECT ALL col1 * - col0 / col0 AS col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT col2 * col1 * col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT col1 * + col1 + + tab0.col2 + col2 * - col0 * col0 FROM tab0
----
-11579
-641159
8185

query I rowsort
SELECT col2 - + tab2.col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col1 FROM tab0 cor0 WHERE NOT NULL NOT IN ( col0 )
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE - col2 IN ( col1 )
----

query I rowsort
SELECT col2 * col1 * + col1 AS col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT tab0.col0 * + tab0.col0 AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - + col1 * - col1 + col2 FROM tab2 AS cor0
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 - col0 * - col2 col0 FROM tab2 cor0
----
-1453
-772
2713

query I rowsort
SELECT + - col1 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ALL - col0 + col0 * col1 * col2 AS col1 FROM tab1
----
36416
4209
99760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7892
SELECT ALL col1 * + col1 + - tab2.col0 DIV col1 AS col2 FROM tab2
----
285
3480
961

skipif mysql # not compatible
query I rowsort label-7892
SELECT ALL col1 * + col1 + - tab2.col0 / col1 AS col2 FROM tab2
----
285
3480
961

query I rowsort
SELECT DISTINCT + col2 + col2 * + col2 AS col1 FROM tab1 cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-7894
SELECT DISTINCT - + col1 DIV - 89 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7894
SELECT DISTINCT - + col1 / - 89 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + col2 * col0 + - col0 - col0 AS col2 FROM tab1 AS cor0
----
156
3520
7520

query I rowsort
SELECT DISTINCT - col1 * 52 + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1530
-2449
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * col0 * cor0.col2 col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + 55 * tab1.col2 FROM tab1
----
2970
3135
5280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7900
SELECT - col2 * - CAST( NULL AS DECIMAL ) + 39 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7900
SELECT - col2 * - CAST ( NULL AS REAL ) + 39 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col2 * 96 FROM tab2
----
2496
2592
3648

query I rowsort
SELECT col0 * 18 + + col1 FROM tab2
----
1439
1463
157

onlyif mysql # use DIV operator for integer division
query I rowsort label-7903
SELECT DISTINCT col2 + tab0.col2 DIV col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-7903
SELECT DISTINCT col2 + tab0.col2 / col2 FROM tab0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7904
SELECT - cor0.col2 * ( + ( col2 ) ) + col1 DIV + 33 AS col0 FROM tab2 AS cor0
----
-1444
-675
-729

skipif mysql # not compatible
query I rowsort label-7904
SELECT - cor0.col2 * ( + ( col2 ) ) + col1 / + 33 AS col0 FROM tab2 AS cor0
----
-1444
-675
-729

query I rowsort
SELECT ALL - col2 * + col2 * 4 + - tab0.col1 * col2 FROM tab0
----
-101
-34358
-7194

query I rowsort
SELECT 71 * cor0.col0 + - 17 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f54a806db88eebf2d738f8a959c1ce5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 + - col0 ) col2 FROM tab0
----
0
0
0

query I rowsort
SELECT + + ( 30 ) FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT + - cor0.col0 + col0 - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - 68 AS col2 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to 3a5c3d9872a8a4148ab98ed0ab0a6c62

query I rowsort
SELECT + ( col1 * col1 ) AS col0 FROM tab1
----
100
169
676

query I rowsort
SELECT col0 - 96 AS col0 FROM tab0
----
-61
-7
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-7913
SELECT ALL col2 DIV + ( - col1 * ( tab2.col0 ) ) col1 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7913
SELECT ALL col2 / + ( - col1 * ( tab2.col0 ) ) col1 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7914
SELECT - + 81 DIV col2 col2 FROM tab1 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7914
SELECT - + 81 / col2 col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT + col2 + - cor0.col0 * - ( - 21 ) - cor0.col2 FROM tab1 AS cor0
----
-1344
-1680
-63

query I rowsort
SELECT ALL ( cor0.col1 ) * col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7917
SELECT DISTINCT + col2 + + col2 DIV 21 FROM tab0 AS cor0
----
1
34
85

skipif mysql # not compatible
query I rowsort label-7917
SELECT DISTINCT + col2 + + col2 / 21 FROM tab0 AS cor0
----
1
34
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7918
SELECT + col0 * - col2 + CAST( cor0.col2 AS SIGNED ) * col1 - + col1 AS col2 FROM tab1 AS cor0
----
-3088
-6445
1216

skipif mysql # not compatible
query I rowsort label-7918
SELECT + col0 * - col2 + CAST ( cor0.col2 AS INTEGER ) * col1 - + col1 AS col2 FROM tab1 AS cor0
----
-3088
-6445
1216

query I rowsort
SELECT - col2 * - col1 * - col0 + col1 * - col0 FROM tab0 cor0
----
-672217
-6790
-70176

onlyif mysql # use DIV operator for integer division
query I rowsort label-7920
SELECT + col2 DIV - col2 + cor0.col0 AS col2 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-7920
SELECT + col2 / - col2 + cor0.col0 AS col2 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL - 91 * - col1 * 21 AS col0 FROM tab1 AS cor0
----
19110
24843
49686

onlyif mysql # use DIV operator for integer division
query I rowsort label-7922
SELECT - col1 * - col1 * 25 + - col2 + - tab1.col2 DIV col1 AS col2 FROM tab1
----
16844
2438
4122

skipif mysql # not compatible
query I rowsort label-7922
SELECT - col1 * - col1 * 25 + - col2 + - tab1.col2 / col1 AS col2 FROM tab1
----
16844
2438
4122

query I rowsort
SELECT col1 + col0 + 93 AS col2 FROM tab0
----
203
225
273

query I rowsort
SELECT + 68 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT ALL col2 * + col2 - + ( 2 ) AS col1 FROM tab2
----
1442
674
727

query I rowsort
SELECT DISTINCT col0 - col2 * + ( col2 ) * + col2 AS col2 FROM tab2
----
-17498
-19676
-54793

query I rowsort
SELECT DISTINCT + + 55 AS col1 FROM tab0 AS cor0
----
55

query I rowsort
SELECT ALL ( + col2 ) * - col2 + - col0 FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7929
SELECT DISTINCT + col0 * CAST( + cor0.col0 AS SIGNED ) + col1 * cor0.col2 FROM tab1 AS cor0
----
1413
4666
7648

skipif mysql # not compatible
query I rowsort label-7929
SELECT DISTINCT + col0 * CAST ( + cor0.col0 AS INTEGER ) + col1 * cor0.col2 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT DISTINCT + cor0.col2 * ( + cor0.col0 ) * - col0 FROM tab1 cor0
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT + col2 * + ( - ( col0 ) ) * + col2 + + cor0.col1 FROM tab1 AS cor0
----
-207926
-737267
-8722

query I rowsort
SELECT + + col0 - + ( - col2 ) AS col1 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7933
SELECT - col2 DIV col0 + 47 AS col2 FROM tab2 cor0
----
44
47
47

skipif mysql # not compatible
query I rowsort label-7933
SELECT - col2 / col0 + 47 AS col2 FROM tab2 cor0
----
44
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 + + cor0.col2 col1 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-7935
SELECT - cor0.col0 - - CAST( ( col0 ) AS SIGNED ) DIV + col1 AS col1 FROM tab1 AS cor0
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-7935
SELECT - cor0.col0 - - CAST ( ( col0 ) AS INTEGER ) / + col1 AS col1 FROM tab1 AS cor0
----
-3
-58
-74

query I rowsort
SELECT DISTINCT + - col1 * col0 + 67 FROM tab0 AS cor0
----
-1997
-3328
-8032

query I rowsort
SELECT ALL - col0 * + col2 * col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7938
SELECT ALL col0 / + CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7938
SELECT ALL col0 / + CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + 5 AS col1 FROM tab1 AS cor0
----
101
59
62

query I rowsort
SELECT 89 + + tab0.col0 - - col1 AS col0 FROM tab0
----
199
221
269

query I rowsort
SELECT - col0 + 31 FROM tab0 AS cor0
----
-4
-58
7

query I rowsort
SELECT DISTINCT + cor0.col2 * 18 AS col2 FROM tab2 AS cor0
----
468
486
684

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7943
SELECT + col2 - - CAST( col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-7943
SELECT + col2 - - CAST ( col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT 35 * - col0 FROM tab1 cor0
----
-105
-2240
-2800

query I rowsort
SELECT DISTINCT - 45 * col0 * - col0 AS col0 FROM tab1 AS cor0
----
184320
288000
405

query I rowsort
SELECT ALL ( 69 ) AS col0 FROM tab2 AS cor0
----
69
69
69

query I rowsort
SELECT - + 21 * col1 FROM tab0 AS cor0
----
-1806
-1911
-2037

query I rowsort
SELECT DISTINCT - 71 * ( col1 ) FROM tab2 AS cor0
----
-1207
-2201
-4189

query I rowsort
SELECT DISTINCT - - ( - col1 ) * + col0 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL + ( + 89 ) FROM tab0 cor0
----
89
89
89

query I rowsort
SELECT + col0 * 37 FROM tab2 AS cor0
----
259
2886
2923

query I rowsort
SELECT + ( + 50 ) AS col2 FROM tab2 cor0
----
50
50
50

query I rowsort
SELECT DISTINCT + - 3 * col2 + col0 AS col0 FROM tab2 AS cor0
----
-35
-74
0

query I rowsort
SELECT + - cor0.col0 + 75 AS col2 FROM tab0 cor0
----
-14
40
51

query I rowsort
SELECT ALL - - cor0.col1 * - 81 * col0 + + 24 FROM tab2 AS cor0
----
-108759
-17553
-372738

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7956
SELECT ALL + - CAST( 56 AS SIGNED ) * - col0 - col0 FROM tab0 AS cor0
----
1320
1925
4895

skipif mysql # not compatible
query I rowsort label-7956
SELECT ALL + - CAST ( 56 AS INTEGER ) * - col0 - col0 FROM tab0 AS cor0
----
1320
1925
4895

query I rowsort
SELECT DISTINCT + + 36 - col2 AS col1 FROM tab2 cor0
----
-2
10
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7958
SELECT + CAST( NULL AS SIGNED ) * col0 + - col1 * - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7958
SELECT + CAST ( NULL AS INTEGER ) * col0 + - col1 * - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 16 + col1 col1 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT ALL + ( + 33 ) FROM tab2 cor0
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 + col1 col1 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7962
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + ( - cor0.col1 + col1 ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7962
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + ( - cor0.col1 + col1 ) FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7963
SELECT DISTINCT col0 + - col2 * col0 + - CAST( NULL AS SIGNED ) * cor0.col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7963
SELECT DISTINCT col0 + - col2 * col0 + - CAST ( NULL AS INTEGER ) * cor0.col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 - - col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + - col1 * col2 * - ( ( + col1 ) ) + + col2 AS col2 FROM tab0 AS cor0
----
244101
679124
9410

query I rowsort
SELECT ALL 37 + col0 * - col1 - col1 * - col0 AS col1 FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT + col1 * - col0 + + col0 * col1 + - cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + 5 AS col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
5

query I rowsort
SELECT - ( tab2.col2 ) - col1 * 1 * col0 FROM tab2
----
-1381
-244
-4628

query I rowsort
SELECT ( 58 ) + + col1 * - col0 FROM tab2
----
-1285
-159
-4544

query I rowsort
SELECT col1 * 21 FROM tab1
----
210
273
546

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7972
SELECT CAST( col1 AS SIGNED ) * + col1 AS col2 FROM tab2
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-7972
SELECT CAST ( col1 AS INTEGER ) * + col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT - 84 AS col1 FROM tab0
----
-84

query I rowsort
SELECT 69 * col0 + + col1 * - ( - col0 ) + col0 AS col1 FROM tab0 AS cor0
----
14329
3744
5845

onlyif mysql # use DIV operator for integer division
query I rowsort label-7975
SELECT - - cor0.col1 DIV - col1 + col0 FROM tab1 cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-7975
SELECT - - cor0.col1 / - col1 + col0 FROM tab1 cor0
----
2
63
79

query I rowsort
SELECT DISTINCT - 84 + ( col0 ) FROM tab2 cor0
----
-5
-6
-77

query I rowsort
SELECT - + cor0.col0 * - 77 + + col2 + - 15 FROM tab1 AS cor0
----
270
4970
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 86 * + col2 col0 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT col1 + col2 * 99 * + col0 AS col2 FROM tab2 AS cor0
----
18742
200831
297215

onlyif mysql # use DIV operator for integer division
query I rowsort label-7980
SELECT + - col2 DIV + col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-7980
SELECT + - col2 / + col0 FROM tab2 AS cor0
----
-3
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7981
SELECT ALL 36 DIV - col2 FROM tab0
----
-1
-36
0

skipif mysql # not compatible
query I rowsort label-7981
SELECT ALL 36 / - col2 FROM tab0
----
-1
-36
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 + col0 col0 FROM tab2 AS cor0
----
102
173
174

onlyif mysql # use DIV operator for integer division
query I rowsort label-7983
SELECT - + col2 + col2 DIV - col2 + col0 FROM tab0 AS cor0
----
-10
33
6

skipif mysql # not compatible
query I rowsort label-7983
SELECT - + col2 + col2 / - col2 + col0 FROM tab0 AS cor0
----
-10
33
6

query I rowsort
SELECT col2 - 68 FROM tab1 AS cor0
----
-11
-14
28

query I rowsort
SELECT DISTINCT col1 * 9 FROM tab0 AS cor0
----
774
819
873

query I rowsort
SELECT - cor0.col2 + + col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + col1 + + ( cor0.col0 ) * col0 + 88 FROM tab0 AS cor0
----
1410
750
8100

onlyif mysql # use DIV operator for integer division
query I rowsort label-7988
SELECT DISTINCT col1 DIV ( + col2 ) AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7988
SELECT DISTINCT col1 / ( + col2 ) AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + col2 * - cor0.col1 + 5 FROM tab0 cor0
----
-2833
-7457
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7990
SELECT DISTINCT - col1 * + 69 - - col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
-1794
-690
-897

skipif mysql # not compatible
query I rowsort label-7990
SELECT DISTINCT - col1 * + 69 - - col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
-1794
-690
-897

query I rowsort
SELECT + col1 * - ( ( col0 ) ) + col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

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-7993
SELECT - + col2 + + 36 DIV + ( + col1 ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7993
SELECT - + col2 + + 36 / + ( + col1 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + + cor0.col1 - col1 * + 2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + col0 + + 42 * + 54 FROM tab1
----
2271
2332
2348

query I rowsort
SELECT + col0 * - ( - col0 ) + - col1 FROM tab1 AS cor0
----
-17
4086
6387

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7997
SELECT - col2 * CAST( NULL AS DECIMAL ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7997
SELECT - col2 * CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( cor1.col0 ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + col1 * + 3 FROM tab1
----
30
39
78

query I rowsort
SELECT - tab1.col1 * + ( + ( + col2 ) ) * col1 AS col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT - - cor0.col1 * + 37 + col2 FROM tab1 AS cor0
----
1016
427
577

query I rowsort
SELECT DISTINCT col0 * ( + col1 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col1 - - 22 * col0 AS col1 FROM tab0 AS cor0
----
1867
442
673

query I rowsort
SELECT ALL + 31 * col2 * + col2 FROM tab2 AS cor0
----
20956
22599
44764

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8005
SELECT DISTINCT + - CAST( col1 AS SIGNED ) AS col2 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8005
SELECT DISTINCT + - CAST ( col1 AS INTEGER ) AS col2 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ( - col2 ) * + col0 - 39 FROM tab2 AS cor0
----
-2067
-228
-3041

query I rowsort
SELECT - ( - cor0.col2 ) + - col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 * 78 col1 FROM tab2 cor0
----
5070
5070
5070

query I rowsort
SELECT + + 74 + - col1 FROM tab1 cor0
----
48
61
64

query I rowsort
SELECT ALL - 51 + 3 * cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 733e83023bce4bc8e786682e5ed53247

query I rowsort
SELECT ALL + tab0.col2 * col1 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + - 68 * - col0 + + col1 + + col0 FROM tab0 AS cor0
----
1742
2512
6232

query I rowsort
SELECT DISTINCT + - ( + col0 ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - 83 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT - - ( - col0 ) + - col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8016
SELECT - CAST( 18 AS SIGNED ) * col1 + cor0.col2 FROM tab0 AS cor0
----
-1515
-1556
-1745

skipif mysql # not compatible
query I rowsort label-8016
SELECT - CAST ( 18 AS INTEGER ) * col1 + cor0.col2 FROM tab0 AS cor0
----
-1515
-1556
-1745

onlyif mysql # use DIV operator for integer division
query I rowsort label-8017
SELECT ALL col0 DIV tab1.col1 + + col1 * + col0 * 94 AS col1 FROM tab1
----
60166
7332
97766

skipif mysql # not compatible
query I rowsort label-8017
SELECT ALL col0 / tab1.col1 + + col1 * + col0 * 94 AS col1 FROM tab1
----
60166
7332
97766

query I rowsort
SELECT ALL - col0 * 87 AS col2 FROM tab0
----
-2088
-3045
-7743

query I rowsort
SELECT DISTINCT + + col0 * col2 * + col0 + - col1 FROM tab1 AS cor0
----
233462
460
614387

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL col1 * + col0 + - CAST ( - cor0.col1 AS REAL ) col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - + 17 - + col0 AS col0 FROM tab0 cor0
----
-106
-41
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8022
SELECT ALL - cor0.col0 DIV col0 AS col2 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8022
SELECT ALL - cor0.col0 / col0 AS col2 FROM tab2 cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8023
SELECT DISTINCT + 6 * col0 + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8023
SELECT DISTINCT + 6 * col0 + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 * cor0.col1 + 25 AS col0 FROM tab1 AS cor0
----
125
194
701

onlyif mysql # use DIV operator for integer division
query I rowsort label-8025
SELECT ALL + 22 DIV - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8025
SELECT ALL + 22 / - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * col2 + col0 * 18 AS col0 FROM tab1 AS cor0
----
1458
1722
2688

query I rowsort
SELECT col0 + - 46 AS col0 FROM tab1 AS cor0
----
-43
18
34

query I rowsort
SELECT ALL - - col0 + - 55 FROM tab2 AS cor0
----
-48
23
24

query I rowsort
SELECT DISTINCT - col2 * - ( + col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + col2 + 23 FROM tab1 AS cor0
----
119
77
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col1 - col2 col0 FROM tab2
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8032
SELECT ALL col1 * CAST( - 89 AS SIGNED ) FROM tab2 cor0
----
-1513
-2759
-5251

skipif mysql # not compatible
query I rowsort label-8032
SELECT ALL col1 * CAST ( - 89 AS INTEGER ) FROM tab2 cor0
----
-1513
-2759
-5251

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 19 col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + col2 * - 31 - - col0 col2 FROM tab2
----
21034
22606
44843

query I rowsort
SELECT ALL - - 26 + - col0 FROM tab0 AS cor0
----
-63
-9
2

query I rowsort
SELECT ALL + 64 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL col1 * + ( + col2 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - cor0.col1 + - col1 * col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT ( + 51 ) + col2 * + cor0.col0 FROM tab0 AS cor0
----
7349
843
86

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab0 cor2
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL 66 * col1 AS col0 FROM tab0 AS cor0
----
5676
6006
6402

query I rowsort
SELECT ALL 8 * - cor2.col0 AS col2 FROM tab1, tab2 AS cor0, tab1 cor1, tab2 AS cor2
----
81 values hashing to 40601f7b9842f1240c6146ccce75a117

query I rowsort
SELECT ALL + 4 AS col0 FROM tab1
----
4
4
4

query I rowsort
SELECT ALL ( - col1 ) + + col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( + 7 * - tab2.col2 ) AS col1 FROM tab2
----
182
189
266

query I rowsort
SELECT - - 65 AS col1 FROM tab1 cor0
----
65
65
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) - - col0 col2 FROM tab1
----
128
160
6

query I rowsort
SELECT + 66 AS col2 FROM tab1 cor0
----
66
66
66

query I rowsort
SELECT DISTINCT 42 FROM tab2, tab2 AS cor0, tab1 cor1
----
42

query I rowsort
SELECT + tab1.col1 + + tab1.col2 * ( 31 ) FROM tab1
----
1700
1777
2989

query I rowsort
SELECT + 59 AS col1 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT - 83 * + col2 + 35 * + 69 FROM tab0
----
-324
-4391
2332

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 31 * col0 + + tab1.col0 col0 FROM tab1
----
-1920
-2400
-90

query I rowsort
SELECT 72 AS col1 FROM tab1 AS cor0
----
72
72
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col0 col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT DISTINCT 65 AS col0 FROM tab2 AS cor0
----
65

query I rowsort
SELECT ALL col1 + + col1 * + ( col0 * col2 ) AS col1 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT ALL col1 * 44 + col0 * + col0 FROM tab0
----
11925
4360
5493

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8059
SELECT ALL tab2.col1 + CAST( col1 + col2 AS SIGNED ) * - 34 FROM tab2
----
-1853
-1941
-2831

skipif mysql # not compatible
query I rowsort label-8059
SELECT ALL tab2.col1 + CAST ( col1 + col2 AS INTEGER ) * - 34 FROM tab2
----
-1853
-1941
-2831

query I rowsort
SELECT DISTINCT - col2 * 38 + + 16 AS col1 FROM tab2
----
-1010
-1428
-972

query I rowsort
SELECT - col1 * ( + col2 ) + col1 + col0 AS col2 FROM tab1 AS cor0
----
-1155
-1375
-496

query I rowsort
SELECT ALL + col0 + 62 FROM tab0
----
151
86
97

query I rowsort
SELECT ALL + col1 * 36 + cor0.col0 FROM tab0 AS cor0
----
3120
3365
3527

query I rowsort
SELECT DISTINCT 62 * cor0.col1 FROM tab1 AS cor0
----
1612
620
806

query I rowsort
SELECT DISTINCT + ( ( - col1 ) ) + - col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - - ( + 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 - 47 * - cor0.col1 col1 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT ALL + + cor0.col1 + - col1 * col1 AS col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - 26 + col1 + col0 AS col0 FROM tab2 cor0
----
111
12
70

query I rowsort
SELECT col1 * col2 + - col1 * cor0.col1 + - ( col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1271
1801
605

query I rowsort
SELECT DISTINCT + 6 + col0 * col2 * cor0.col1 FROM tab0 cor0
----
3401
664124
68118

onlyif mysql # use DIV operator for integer division
query I rowsort label-8072
SELECT DISTINCT 38 DIV - 35 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8072
SELECT DISTINCT 38 / - 35 AS col0 FROM tab1 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8073
SELECT CAST( NULL AS DECIMAL ) * 58 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8073
SELECT CAST ( NULL AS REAL ) * 58 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8074
SELECT + CAST( NULL AS SIGNED ) * col0 * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8074
SELECT + CAST ( NULL AS INTEGER ) * col0 * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 13 * - col1 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT DISTINCT 32 + - 62 FROM tab0 AS cor0
----
-30

query I rowsort
SELECT DISTINCT 58 * - col0 AS col2 FROM tab2 AS cor0
----
-406
-4524
-4582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 9 col1 FROM tab2 AS cor0
----
-9
-9
-9

query I rowsort
SELECT - col0 + - 73 * - col0 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT col2 + 57 * col0 + col2 AS col0 FROM tab0 AS cor0
----
1434
1997
5237

query I rowsort
SELECT 22 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT DISTINCT - tab1.col0 + col2 AS col0 FROM tab1
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + 70 * col0 col0 FROM tab2 cor0
----
497
5538
5609

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + tab0.col2 * - ( col2 ) col1 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT ALL 87 + + col0 AS col2 FROM tab0 AS cor0
----
111
122
176

query I rowsort
SELECT - - col0 * - col0 + ( + col2 * col0 ) FROM tab1 AS cor0
----
-448
1280
153

query I rowsort
SELECT + 79 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT - + col1 + - cor0.col1 * + col0 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT + col0 * - ( + 88 ) AS col2 FROM tab2 AS cor0
----
-616
-6864
-6952

query I rowsort
SELECT col0 + ( col2 ) * col2 FROM tab1 cor0
----
2919
3313
9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8091
SELECT + col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8091
SELECT + col1 * 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-8092
SELECT - col0 DIV - col0 + 15 AS col0 FROM tab2 cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-8092
SELECT - col0 / - col0 + 15 AS col0 FROM tab2 cor0
----
16
16
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-8093
SELECT DISTINCT col0 * col2 + - col2 DIV col0 col1 FROM tab0 AS cor0
----
35
7298
791

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8093
SELECT DISTINCT col0 * col2 + - col2 / col0 col1 FROM tab0 AS cor0
----
35
7298
791

query I rowsort
SELECT cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL - + ( + col0 ) AS col2 FROM tab0 cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8096
SELECT ALL + CAST( NULL AS SIGNED ) + - col0 - - col0 / + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8096
SELECT ALL + CAST ( NULL AS INTEGER ) + - col0 - - col0 / + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 0 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 + 54 AS col0 FROM tab2 AS cor0
----
-24
-25
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * 81 col1 FROM tab0 AS cor0
----
-6966
-7371
-7857

query I rowsort
SELECT - cor0.col2 * + cor0.col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL col0 * 5 + + col0 FROM tab0 AS cor0
----
144
210
534

query I rowsort
SELECT ALL + col2 * + cor0.col0 + + col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8103
SELECT DISTINCT + + col2 + - 78 * + col1 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8103
SELECT DISTINCT + + col2 + - 78 * + col1 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - + cor0.col2 * + 84 FROM tab2 AS cor0
----
-2184
-2268
-3192

query I rowsort
SELECT + cor0.col2 * col2 - - col0 FROM tab1 cor0
----
2919
3313
9296

query I rowsort
SELECT + col0 + col2 * + col1 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-8107
SELECT - col1 + + cor0.col2 * col0 DIV 51 - col1 AS col1 FROM tab0 cor0
----
-157
-194
-39

skipif mysql # not compatible
query I rowsort label-8107
SELECT - col1 + + cor0.col2 * col0 / 51 - col1 AS col1 FROM tab0 cor0
----
-157
-194
-39

query I rowsort
SELECT col0 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - - col0 + + cor0.col0 * - col0 FROM tab1 cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + + col1 * col0 * col0 + cor0.col2 AS col2 FROM tab2 cor0
----
106135
1546
358982

query I rowsort
SELECT DISTINCT col2 - - col0 * col0 AS col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT + col0 * 1 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - col0 * + col1 * 74 FROM tab1 cor0
----
-47360
-5772
-76960

query I rowsort
SELECT + col0 - + cor0.col2 * 45 FROM tab0 AS cor0
----
-10
-1461
-3601

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 91 col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

onlyif mysql # use DIV operator for integer division
query I rowsort label-8116
SELECT DISTINCT col2 + - ( col0 ) DIV + CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8116
SELECT DISTINCT col2 + - ( col0 ) / + CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL 37 * cor0.col1 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 94de0e41710bf3fdbda3e5ce4b23e12d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 47 col2 FROM tab2
----
1222
1269
1786

query I rowsort
SELECT DISTINCT - ( col2 ) * + col0 FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( tab2.col1 * - tab2.col2 ) col0 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + tab2.col1 ) + col2 col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + 39 + col1 AS col1 FROM tab0
----
125
130
136

query I rowsort
SELECT DISTINCT - col2 + 11 FROM tab2 AS cor0
----
-15
-16
-27

query I rowsort
SELECT - + col1 + + 66 AS col1 FROM tab1 AS cor0
----
40
53
56

query I rowsort
SELECT col0 + ( col2 ) AS col2 FROM tab0 cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8126
SELECT DISTINCT - col2 * col1 + 92 DIV col1 FROM tab1 cor0
----
-1241
-1401
-561

skipif mysql # not compatible
query I rowsort label-8126
SELECT DISTINCT - col2 * col1 + 92 / col1 FROM tab1 cor0
----
-1241
-1401
-561

query I rowsort
SELECT col1 * - 14 * col2 FROM tab1 AS cor0
----
-17472
-19656
-7980

query I rowsort
SELECT ALL - 98 * + 97 * - cor0.col0 + + 51 + - col1 FROM tab1 AS cor0
----
28543
608425
760518

query I rowsort
SELECT cor1.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col0 col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8131
SELECT DISTINCT + col0 DIV - 6 + + col1 FROM tab1 AS cor0
----
0
26

skipif mysql # not compatible
query I rowsort label-8131
SELECT DISTINCT + col0 / - 6 + + col1 FROM tab1 AS cor0
----
0
26

query I rowsort
SELECT ALL 47 + col1 FROM tab0 cor0
----
133
138
144

query I rowsort
SELECT + col1 * col1 + col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL + 49 + col2 AS col1 FROM tab1
----
103
106
145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - - col2 + - col2 + col1 AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + - col0 + - col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT 74 * col1 + 54 * col1 FROM tab0 cor0
----
11008
11648
12416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8139
SELECT ALL - + col0 * CAST( col2 AS SIGNED ) + + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif mysql # not compatible
query I rowsort label-8139
SELECT ALL - + col0 * CAST ( col2 AS INTEGER ) + + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-8140
SELECT DISTINCT + col2 * + col1 DIV cor0.col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8140
SELECT DISTINCT + col2 * + col1 / cor0.col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + col0 * 36 + - 98 * - col1 FROM tab2 cor0
----
3290
4510
8590

onlyif mysql # use DIV operator for integer division
query I rowsort label-8142
SELECT DISTINCT col0 * 66 DIV cor0.col1 col0 FROM tab0 AS cor0
----
18
23
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8142
SELECT DISTINCT col0 * 66 / cor0.col1 col0 FROM tab0 AS cor0
----
18
23
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-8143
SELECT ALL col1 + CAST( col2 + + col0 AS SIGNED ) DIV - 43 FROM tab1 cor0
----
25
8
9

skipif mysql # not compatible
query I rowsort label-8143
SELECT ALL col1 + CAST ( col2 + + col0 AS INTEGER ) / - 43 FROM tab1 cor0
----
25
8
9

query I rowsort
SELECT - + col2 * - 94 FROM tab1 AS cor0
----
5076
5358
9024

query I rowsort
SELECT ALL col2 * - col0 + 85 * tab1.col1 FROM tab1
----
-2798
-6575
2048

query I rowsort
SELECT - 64 + col1 FROM tab2
----
-33
-47
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + col2 * - ( + col0 + + ( - col2 ) ) col0 FROM tab0 AS cor0
----
-663
-69
273

query I rowsort
SELECT DISTINCT + col1 * ( - col0 * col1 ) FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 - + col1 FROM tab1 AS cor0
----
-104
-1053
-650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * - col2 col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT + + cor0.col0 + 74 * + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd960e594b0d4c878eedb476f1f2cd2a

query I rowsort
SELECT col0 - col2 * + col2 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT + col2 * + col0 * - 45 AS col1 FROM tab2 AS cor0
----
-135090
-8505
-91260

query I rowsort
SELECT DISTINCT - tab2.col0 * - 55 FROM tab2, tab1, tab0 AS cor0
----
385
4290
4345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 80 col2 FROM tab1 AS cor0
----
-80
-80
-80

query I rowsort
SELECT col0 * col2 + + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-8157
SELECT DISTINCT col1 DIV 50 - col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-8157
SELECT DISTINCT col1 / 50 - col0 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT - col0 + ( - col0 ) AS col1 FROM tab1
----
-128
-160
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8159
SELECT tab2.col1 * - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8159
SELECT tab2.col1 * - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 67 + col0 - col0 AS col1 FROM tab0
----
67
67
67

query I rowsort
SELECT DISTINCT 68 - - 7 AS col2 FROM tab1
----
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8162
SELECT + + col1 * + col1 + CAST( NULL AS SIGNED ) - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8162
SELECT + + col1 * + col1 + CAST ( NULL AS INTEGER ) - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 51 * col1 FROM tab2 AS cor0
----
1581
3009
867

query I rowsort
SELECT DISTINCT - + 91 FROM tab2 AS cor0
----
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 + - col0 col2 FROM tab1
----
3
64
80

query I rowsort
SELECT + col2 * 50 AS col0 FROM tab0
----
1650
4100
50

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( 62 AS REAL ) + - col1 * col2 AS col0 FROM tab1
----
-1186
-1342
-508

onlyif mysql # use DIV operator for integer division
query I rowsort label-8168
SELECT ALL 51 DIV 77 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-8168
SELECT ALL 51 / 77 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8169
SELECT CAST( NULL AS DECIMAL ) + + tab2.col2 + col1 * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8169
SELECT CAST ( NULL AS REAL ) + + tab2.col2 + col1 * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - col2 col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT + 20 * tab0.col2 + + tab0.col2 + ( col0 + + tab0.col0 ) AS col0 FROM tab0
----
1900
741
91

query I rowsort
SELECT - cor0.col1 * + cor0.col1 - - col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - ( - col1 ) + cor0.col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - col2 + col0 * - col1 FROM tab2 cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT + 67 FROM tab0 cor0
----
67

query I rowsort
SELECT 71 + + col0 * + ( col0 ) AS col1 FROM tab0 AS cor0
----
1296
647
7992

query I rowsort
SELECT + 11 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2827
-7451
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + col1 * - col2 * + col2 col1 FROM tab1 AS cor0
----
-119795
-32480
-75790

query I rowsort
SELECT ALL ( cor0.col2 ) * + 36 - - ( col0 ) AS col1 FROM tab2 AS cor0
----
1014
1447
979

query I rowsort
SELECT - + 43 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-132
-67
-78

query I rowsort
SELECT ALL - + col2 * col2 + - col2 * col1 * col1 AS col1 FROM tab0 AS cor0
----
-245157
-685766
-9410

query I rowsort
SELECT col1 + col1 * ( ( cor0.col0 ) ) FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + + ( 48 ) AS col2 FROM tab0 AS cor0
----
48
48
48

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1, tab1, tab0 AS cor2
----
3645 values hashing to 64312dc66df177d8c745c63c0bdd4dc7

query I rowsort
SELECT ALL 26 FROM tab1, tab0 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

onlyif mysql # use DIV operator for integer division
query I rowsort label-8186
SELECT ALL - - cor0.col2 * col0 + + col1 DIV + col1 AS col1 FROM tab1 AS cor0
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-8186
SELECT ALL - - cor0.col2 * col0 + + col1 / + col1 AS col1 FROM tab1 AS cor0
----
163
3649
7681

query I rowsort
SELECT + 92 + + col2 + col2 FROM tab2
----
144
146
168

query I rowsort
SELECT ( + 52 ) - col2 FROM tab0
----
-30
19
51

query I rowsort
SELECT col1 + - 66 FROM tab1 AS cor0
----
-40
-53
-56

query I rowsort
SELECT - 95 AS col2 FROM tab1 cor0
----
-95
-95
-95

query I rowsort
SELECT ALL - col0 * + tab0.col0 AS col1 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - col1 * col2 * - col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT - col1 * + ( - 91 ) FROM tab1 AS cor0
----
1183
2366
910

query I rowsort
SELECT 85 AS col1 FROM tab1
----
85
85
85

query I rowsort
SELECT tab1.col0 * col1 * - ( col1 ) FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - 11 * + col2 * - col2 AS col2 FROM tab1
----
101376
32076
35739

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8197
SELECT - col1 + - CAST( - col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-8197
SELECT - col1 + - CAST ( - col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col1 + col0 * - 77 FROM tab0 AS cor0
----
-1762
-2598
-6762

query I rowsort
SELECT DISTINCT tab2.col2 + col0 * - col0 * + tab2.col1 FROM tab2
----
-106059
-1492
-358930

query I rowsort
SELECT DISTINCT - col0 + col1 + col1 * col1 FROM tab1
----
102
46
699

query I rowsort
SELECT DISTINCT tab1.col0 * - col0 AS col2 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT - - col2 + + col1 * - col0 + - col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col1 FROM tab2 AS cor0 WHERE NULL < NULL OR ( NULL ) NOT IN ( col0 )
----

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab2
----
86
91
97

query I rowsort
SELECT + col1 * - col2 * - col2 AS col0 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT - col0 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col2 * - col1 * col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL - cor0.col2 * - col0 AS col1 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 + col2 col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col2 + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-8212
SELECT + - col0 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8212
SELECT + - col0 / + col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 * col1 col1 FROM tab2 AS cor0
----
289
3481
961

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-8215
SELECT 2 * col0 + + col1 DIV + col0 FROM tab2 AS cor0
----
156
158
18

skipif mysql # not compatible
query I rowsort label-8215
SELECT 2 * col0 + + col1 / + col0 FROM tab2 AS cor0
----
156
158
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 2 + cor0.col2 * + col2 col2 FROM tab0 AS cor0
----
-1
1087
6722

query I rowsort
SELECT 91 + + col1 FROM tab1 AS cor0
----
101
104
117

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col1 FROM tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col2 + col0 * cor0.col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT - cor0.col2 + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL - 23 + - col1 AS col2 FROM tab1 AS cor0
----
-33
-36
-49

query I rowsort
SELECT - + 73 + + cor0.col0 FROM tab2 AS cor0
----
-66
5
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8223
SELECT + + col1 + col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-8223
SELECT + + col1 + col1 / - col1 AS col0 FROM tab1 AS cor0
----
12
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8224
SELECT - col1 + col2 DIV + col1 + + col0 DIV - cor0.col1 FROM tab1 AS cor0
----
-11
-12
-24

skipif mysql # not compatible
query I rowsort label-8224
SELECT - col1 + col2 / + col1 + + col0 / - cor0.col1 FROM tab1 AS cor0
----
-11
-12
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 - cor0.col1 col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col1 * cor0.col2 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - ( - col0 ) * + cor0.col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 col2 FROM tab1 AS cor0
----
-14
-14
-14

query I rowsort
SELECT + + col1 + + col0 * col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - + 75 * col0 + - col0 FROM tab1 AS cor0
----
-228
-4864
-6080

query I rowsort
SELECT ALL - col1 * + col2 + ( - 19 ) * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-116
-3465
-9020

query I rowsort
SELECT ALL col1 + - col1 * col2 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT - 99 - col2 AS col2 FROM tab1 AS cor0
----
-153
-156
-195

query I rowsort
SELECT ALL + + col1 * col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL - - col0 * col2 + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 39 + + col1 col1 FROM tab1
----
49
52
65

query I rowsort
SELECT col0 * - 72 * col0 - col0 FROM tab2
----
-3535
-438126
-449431

query I rowsort
SELECT col2 * + 81 * - col0 - + col0 AS col1 FROM tab1
----
-13125
-295552
-622160

query I rowsort
SELECT ALL - cor0.col1 * 30 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d2fa662621390dc8ae73966cd7d7f7f2

query I rowsort
SELECT DISTINCT - col2 + + ( tab0.col2 ) * col2 FROM tab0
----
0
1056
6642

query I rowsort
SELECT - col1 + 22 FROM tab0
----
-64
-69
-75

query I rowsort
SELECT ALL - 64 + col2 + + col1 * - ( tab1.col1 * + col1 ) AS col2 FROM tab1
----
-1007
-17586
-2165

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 + - col1 col2 FROM tab2
----
-19
-47
-5

query I rowsort
SELECT ALL + - cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT + 86 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab2
----
13

query I rowsort
SELECT DISTINCT + ( - col1 ) * 10 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-157
-226
-314

query I rowsort
SELECT ALL + 15 * col2 + col0 * - col1 + col1 FROM tab0 AS cor0
----
-1483
-3283
-6778

query I rowsort
SELECT ALL + 94 + - col0 * ( col0 + - col1 ) AS col0 FROM tab1 AS cor0
----
-3362
-5266
163

query I rowsort
SELECT ALL - + col0 + - col1 + col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - - 57 + + cor0.col1 FROM tab1 AS cor0
----
67
70
83

query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) * - ( - 61 ) FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT - cor0.col1 FROM tab1, tab2 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT ALL + + 83 + 15 * - col2 AS col0 FROM tab1 AS cor0
----
-1357
-727
-772

query I rowsort
SELECT - + cor0.col0 - col0 FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8256
SELECT - - col0 + + CAST( + col0 * - col1 AS SIGNED ) - + col1 AS col2 FROM tab0 AS cor0
----
-2126
-3457
-8101

skipif mysql # not compatible
query I rowsort label-8256
SELECT - - col0 + + CAST ( + col0 * - col1 AS INTEGER ) - + col1 AS col2 FROM tab0 AS cor0
----
-2126
-3457
-8101

query I rowsort
SELECT ALL - + cor0.col1 + + col2 * + cor0.col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + col2 + 63 * col2 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT ALL - ( - col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL 59 * + col2 FROM tab0
----
1947
4838
59

query I rowsort
SELECT col0 + + 91 FROM tab2
----
169
170
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 25 * col0 col0 FROM tab2 cor0
----
175
1950
1975

query I rowsort
SELECT ALL - 73 * col0 - col0 FROM tab0 AS cor0
----
-1776
-2590
-6586

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + cor0.col2 * col2 col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT + + col1 * + col1 - + col0 * col2 FROM tab0 AS cor0
----
6604
9374
983

query I rowsort
SELECT DISTINCT + - ( 2 ) FROM tab0 cor0
----
-2

query I rowsort
SELECT - - ( - col0 ) * col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ( 44 ) * col0 AS col2 FROM tab0 AS cor0
----
1056
1540
3916

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ( + col0 ) * col2 * 86 + col0 * col0 AS col2 FROM tab2 AS cor0
----
16303
180492
264413

query I rowsort
SELECT - 59 + - col2 * + col0 AS col2 FROM tab1 cor0
----
-221
-3707
-7739

query I rowsort
SELECT DISTINCT 40 * - col1 FROM tab0 cor0
----
-3440
-3640
-3880

onlyif mysql # use DIV operator for integer division
query I rowsort label-8273
SELECT ALL - + 32 DIV - cor0.col2 AS col0 FROM tab2, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 418098edfa3a8e72d5bfcd464856be68

skipif mysql # not compatible
query I rowsort label-8273
SELECT ALL - + 32 / - cor0.col2 AS col0 FROM tab2, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 418098edfa3a8e72d5bfcd464856be68

onlyif mysql # use DIV operator for integer division
query I rowsort label-8274
SELECT - col2 DIV 78 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8274
SELECT - col2 / 78 FROM tab0
----
-1
0
0

query I rowsort
SELECT - ( + col1 + col1 ) * - col0 * col2 AS col2 FROM tab1
----
199680
72960
8424

query I rowsort
SELECT - 81 + - col2 FROM tab0 AS cor0
----
-114
-163
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 + col2 col2 FROM tab0 AS cor0
----
100
149
68

query I rowsort
SELECT ALL ( - 86 ) FROM tab2 AS cor0
----
-86
-86
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-8279
SELECT col0 + 3 DIV col0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8279
SELECT col0 + 3 / col0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - 85 AS REAL ) * - cor0.col2 FROM tab1 AS cor0
----
4590
4845
8160

query I rowsort
SELECT DISTINCT + + col0 * col2 * col1 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + 15 + col2 AS col1 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT + col0 + + col0 * + 51 * col0 AS col0 FROM tab1 AS cor0
----
208960
326480
462

query I rowsort
SELECT DISTINCT + - col2 * col2 + col1 AS col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT - - col0 * - 24 FROM tab1 AS cor0
----
-1536
-1920
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 69 * + col1 + col0 col2 FROM tab2 cor0
----
105924
44653
57760

query I rowsort
SELECT + + col2 + - 17 FROM tab2 AS cor0
----
10
21
9

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col1 + - 13 FROM tab1 AS cor0
----
156
663
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 79 ) + - col0 col0 FROM tab1 cor0
----
-1
15
76

query I rowsort
SELECT - col0 + + ( col2 ) + col0 FROM tab2
----
26
27
38

query I rowsort
SELECT + 22 - + col1 FROM tab2 AS cor0
----
-37
-9
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8292
SELECT - ( col0 ) + col1 DIV - col0 FROM tab2 AS cor0
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-8292
SELECT - ( col0 ) + col1 / - col0 FROM tab2 AS cor0
----
-11
-78
-79

query I rowsort
SELECT + ( - 41 ) * - col2 + col0 * - col0 FROM tab2 AS cor0
----
-4683
-5018
1058

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 82 col0 FROM tab2 AS cor0
----
-82
-82
-82

query I rowsort
SELECT + col0 * 63 * + col2 + col0 FROM tab1
----
10209
229888
483920

query I rowsort
SELECT DISTINCT col1 + col0 * 62 * col2 FROM tab0
----
2267
452567
49190

query I rowsort
SELECT + col1 + - tab1.col2 + 46 FROM tab1
----
-1
-37
18

query I rowsort
SELECT - col0 + col1 * - col1 AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL + col0 * + 99 * ( col0 + - col1 ) FROM tab1 AS cor0
----
-6831
342144
530640

query I rowsort
SELECT - col2 * - col2 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL - cor0.col2 * - 96 + col0 + + 65 AS col1 FROM tab0 cor0
----
196
3257
8026

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 51 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT col0 + + col0 * + col1 FROM tab1
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8304
SELECT + cor0.col1 DIV col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8304
SELECT + cor0.col1 / col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + 63 * col0 * - col1 FROM tab1 AS cor0
----
-40320
-4914
-65520

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8306
SELECT DISTINCT + ( col2 * - tab2.col2 ) + CAST( NULL AS SIGNED ) + 32 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-8306
SELECT DISTINCT + ( col2 * - tab2.col2 ) + CAST ( NULL AS INTEGER ) + 32 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 col0 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - - cor0.col0 * col1 + - ( ( + col2 ) * 86 + col2 * + col1 ) FROM tab1 AS cor0
----
-4832
-5970
-8464

query I rowsort
SELECT DISTINCT - - col2 * - col0 * - col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8310
SELECT - - col0 + - col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8310
SELECT - - col0 + - col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 47 * - col0 + 76 AS col0 FROM tab1 AS cor0
----
-2932
-3684
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-8312
SELECT DISTINCT - - col2 + + col0 DIV col2 AS col0 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-8312
SELECT DISTINCT - - col2 + + col0 / col2 AS col0 FROM tab0 AS cor0
----
33
36
83

query I rowsort
SELECT + 87 * col2 + 1 AS col1 FROM tab0 AS cor0
----
2872
7135
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-8314
SELECT ALL - col2 DIV col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8314
SELECT ALL - col2 / col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 + + cor0.col2 AS col0 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8316
SELECT DISTINCT 55 * col1 + - col1 - col2 DIV col1 FROM tab1
----
1402
535
695

skipif mysql # not compatible
query I rowsort label-8316
SELECT DISTINCT 55 * col1 + - col1 - col2 / col1 FROM tab1
----
1402
535
695

query I rowsort
SELECT - 80 + - col1 - - col1 FROM tab0
----
-80
-80
-80

query I rowsort
SELECT col1 + col0 * + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT col1 + ( + cor0.col1 ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT col0 + + ( + col0 + + col2 ) * + col2 FROM tab2 AS cor0
----
2782
4525
925

query I rowsort
SELECT + - col2 * 39 AS col2 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT ( col2 ) * col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + tab1.col2 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
54
57
96

query I rowsort
SELECT 37 * + col0 + + col1 FROM tab2 AS cor0
----
290
2940
2945

query I rowsort
SELECT 89 * col0 * - col2 FROM tab1 AS cor0
----
-14418
-324672
-683520

query I rowsort
SELECT + + 90 * 41 FROM tab2 cor0
----
3690
3690
3690

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8327
SELECT - cor0.col2 * - col0 / CAST( NULL AS SIGNED ) + + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8327
SELECT - cor0.col2 * - col0 / CAST ( NULL AS INTEGER ) + + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8328
SELECT - cor0.col0 * col0 DIV + CAST( col2 AS SIGNED ) + col2 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1224
1072
6628

skipif mysql # not compatible
query I rowsort label-8328
SELECT - cor0.col0 * col0 / + CAST ( col2 AS INTEGER ) + col2 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1224
1072
6628

query I rowsort
SELECT + 65 + + col0 AS col1 FROM tab2 AS cor0
----
143
144
72

query I rowsort
SELECT - 2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT 28 - col2 FROM tab1 AS cor0
----
-26
-29
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + tab0.col0 * col0 col2 FROM tab0
----
1226
609
8003

query I rowsort
SELECT col2 * col1 * - col0 + tab2.col2 + tab2.col0 FROM tab2
----
-119548
-50917
-5825

onlyif mysql # use DIV operator for integer division
query I rowsort label-8334
SELECT ALL col1 DIV - col1 AS col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8334
SELECT ALL col1 / - col1 AS col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col2 * col1 + - col1 + + tab1.col2 FROM tab1
----
1331
1432
617

query I rowsort
SELECT - col1 * - col1 - col2 FROM tab2
----
251
3455
934

query I rowsort
SELECT ALL tab2.col1 * - tab2.col1 + col0 * + tab2.col1 * + tab2.col0 FROM tab2
----
105808
355475
558

query I rowsort
SELECT DISTINCT - col0 FROM tab2 WHERE NULL BETWEEN - col2 / + col0 AND ( - col1 + col2 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE col1 >= ( NULL )
----

query I rowsort
SELECT tab2.col1 + - col0 + + tab2.col0 * col0 FROM tab2
----
6065
6179
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-8341
SELECT - col1 + + col0 DIV - col1 FROM tab2
----
-21
-31
-60

skipif mysql # not compatible
query I rowsort label-8341
SELECT - col1 + + col0 / - col1 FROM tab2
----
-21
-31
-60

query I rowsort
SELECT ALL + col2 * tab0.col1 - + col0 FROM tab0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-8343
SELECT DISTINCT + - 48 + col1 DIV - ( + cor0.col0 ) AS col2 FROM tab2 cor0
----
-48
-52

skipif mysql # not compatible
query I rowsort label-8343
SELECT DISTINCT + - 48 + col1 / - ( + cor0.col0 ) AS col2 FROM tab2 cor0
----
-48
-52

query I rowsort
SELECT + col0 * - col1 + - col0 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT - col0 AS col2 FROM tab0 WHERE ( NULL ) BETWEEN ( - tab0.col2 ) AND NULL
----

query I rowsort
SELECT col0 * - col0 AS col0 FROM tab2 WHERE NULL < ( col1 )
----

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 IN ( col0 - + tab2.col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - tab0.col0 + col0 * col0 FROM tab0
----
1190
552
7832

query I rowsort
SELECT + col0 * col2 * + col1 + + col1 FROM tab2
----
119711
51051
5890

query I rowsort
SELECT col2 * - col2 - col1 * col0 AS col0 FROM tab1 WHERE ( col2 + + col1 ) IN ( col2 + - tab1.col0 )
----

query I rowsort
SELECT ALL col1 + - col0 * col0 FROM tab1 WHERE ( col2 ) NOT IN ( - col1 + + col0 )
----
-4086
-6387
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col1 + + col0 col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT col0 - col1 * tab1.col2 * col2 FROM tab1
----
-119728
-32426
-75813

query I rowsort
SELECT - tab0.col1 * - tab0.col1 + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT col0 + + tab1.col2 + tab1.col0 AS col2 FROM tab1
----
185
256
60

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( col2 + col2 ) NOT BETWEEN - col2 AND NULL
----

query I rowsort
SELECT col2 + + col1 - - col0 FROM tab2
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col2 col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL + col2 + - tab2.col1 + - col0 * - col1 FROM tab2
----
1364
213
4569

onlyif mysql # use DIV operator for integer division
query I rowsort label-8360
SELECT + col2 DIV col0 + + col1 FROM tab1
----
10
14
44

skipif mysql # not compatible
query I rowsort label-8360
SELECT + col2 / col0 + + col1 FROM tab1
----
10
14
44

query I rowsort
SELECT col1 AS col1 FROM tab1 WHERE NOT + col2 * col0 - - col1 = + col2 + - col1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8362
SELECT DISTINCT - col2 DIV col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-8362
SELECT DISTINCT - col2 / col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT ALL tab1.col2 + col2 * - col2 + + tab1.col1 FROM tab1
----
-2836
-3182
-9107

onlyif mysql # use DIV operator for integer division
query I rowsort label-8364
SELECT + col1 DIV - col1 + - col2 AS col1 FROM tab2
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-8364
SELECT + col1 / - col1 + - col2 AS col1 FROM tab2
----
-27
-28
-39

query I rowsort
SELECT ALL - col2 AS col1 FROM tab1 WHERE + col0 - tab1.col2 NOT BETWEEN col2 * col0 AND NULL
----
-54
-57
-96

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NOT ( NULL ) IN ( col2 * - cor0.col1 - col1 * + col2 )
----

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 WHERE cor0.col1 > ( tab1.col2 * tab1.col2 )
----

query I rowsort
SELECT col0 + col1 AS col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + col1 * + col0 + - col0 * - col0 AS col2 FROM tab2
----
10686
266
7584

query I rowsort
SELECT col1 * + col2 * - col2 + + col2 * - col2 AS col0 FROM tab0
----
-618608
-94743
-98

query I rowsort
SELECT col2 - + col0 * - col0 AS col1 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - col0 * + col1 + + col0 * + col2 AS col2 FROM tab2 AS cor0
----
-2574
-28
1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-8373
SELECT ALL - col1 * + col0 + col2 DIV col1 FROM tab1 AS cor0
----
-1033
-635
-76

skipif mysql # not compatible
query I rowsort label-8373
SELECT ALL - col1 * + col0 + col2 / col1 FROM tab1 AS cor0
----
-1033
-635
-76

query I rowsort
SELECT DISTINCT - col1 * - 15 AS col0 FROM tab0 cor0
----
1290
1365
1455

query I rowsort
SELECT - ( - 42 ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # use DIV operator for integer division
query I rowsort label-8376
SELECT - ( 2 ) DIV col2 + 34 * - col1 - + col1 FROM tab0 AS cor0
----
-3010
-3185
-3397

skipif mysql # not compatible
query I rowsort label-8376
SELECT - ( 2 ) / col2 + 34 * - col1 - + col1 FROM tab0 AS cor0
----
-3010
-3185
-3397

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 93 * ( + col1 * col0 ) col2 FROM tab0 AS cor0
----
191952
315735
753207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8378
SELECT - CAST( col2 AS SIGNED ) + col2 * - 45 + - ( - col2 * - 55 ) AS col2 FROM tab1 AS cor0
----
-5454
-5757
-9696

skipif mysql # not compatible
query I rowsort label-8378
SELECT - CAST ( col2 AS INTEGER ) + col2 * - 45 + - ( - col2 * - 55 ) AS col2 FROM tab1 AS cor0
----
-5454
-5757
-9696

onlyif mysql # use DIV operator for integer division
query I rowsort label-8379
SELECT - ( + col0 ) + + col1 DIV col0 - 0 AS col1 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-8379
SELECT - ( + col0 ) + + col1 / col0 - 0 AS col1 FROM tab0 AS cor0
----
-21
-33
-88

query I rowsort
SELECT ALL - 16 * - col0 AS col2 FROM tab1 cor0
----
1024
1280
48

query I rowsort
SELECT DISTINCT col1 * col0 + col1 * - cor0.col2 + + 89 AS col0 FROM tab2 AS cor0
----
-531
3157
786

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) * - cor0.col0 + ( - col2 ) + - col2 col2 FROM tab0 AS cor0
----
-2130
-3397
-8263

query I rowsort
SELECT + col2 * 90 - + col2 FROM tab0 AS cor0
----
2937
7298
89

query I rowsort
SELECT ALL - cor1.col0 AS col1 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT 23 + tab2.col1 AS col2 FROM tab2
----
40
54
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8386
SELECT - col2 + - col2 DIV + col0 AS col1 FROM tab1
----
-57
-72
-97

skipif mysql # not compatible
query I rowsort label-8386
SELECT - col2 + - col2 / + col0 AS col1 FROM tab1
----
-57
-72
-97

query I rowsort
SELECT 66 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT 88 * - col0 + col2 FROM tab2
----
-589
-6838
-6914

query I rowsort
SELECT 86 * + tab1.col1 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 4f21fc32bb8f8c72c1140bd6292aac09

query I rowsort
SELECT ALL - 95 AS col2 FROM tab0
----
-95
-95
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8391
SELECT ( - col2 ) DIV + ( + col2 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8391
SELECT ( - col2 ) / + ( + col2 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col0 + col0 * col0 AS col2 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-8393
SELECT ALL - + col1 DIV col1 AS col0 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8393
SELECT ALL - + col1 / col1 AS col0 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - 1 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8395
SELECT ALL - - cor0.col2 + - ( col0 ) DIV + col2 AS col2 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-8395
SELECT ALL - - cor0.col2 + - ( col0 ) / + col2 AS col2 FROM tab0 AS cor0
----
-34
33
81

query I rowsort
SELECT DISTINCT col0 + 57 * 19 FROM tab2 AS cor0
----
1090
1161
1162

query I rowsort
SELECT col1 + - col0 * - col0 FROM tab0 AS cor0
----
1322
662
8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * + col0 col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8399
SELECT - col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8399
SELECT - col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + - col1 * - 14 AS col2 FROM tab2 cor0
----
200
407
800

query I rowsort
SELECT DISTINCT + - 66 AS col1 FROM tab2, tab0, tab0 cor0
----
-66

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab2 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8403
SELECT + + CAST( NULL AS SIGNED ) * 74 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8403
SELECT + + CAST ( NULL AS INTEGER ) * 74 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + + col1 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT col2 * - col2 * col2 + + tab2.col0 FROM tab2
----
-17498
-19676
-54793

query I rowsort
SELECT 96 + col0 AS col1 FROM tab0 AS cor0
----
120
131
185

query I rowsort
SELECT - 49 * col1 AS col2 FROM tab1 AS cor0
----
-1274
-490
-637

onlyif mysql # use DIV operator for integer division
query I rowsort label-8408
SELECT 29 DIV 29 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-8408
SELECT 29 / 29 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8409
SELECT + col1 DIV - 14 AS col0 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-8409
SELECT + col1 / - 14 AS col0 FROM tab2
----
-1
-2
-4

query I rowsort
SELECT + + cor0.col0 + - col2 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8411
SELECT cor0.col1 - - CAST( NULL AS SIGNED ) * 70 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8411
SELECT cor0.col1 - - CAST ( NULL AS INTEGER ) * 70 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8412
SELECT + + CAST( NULL AS SIGNED ) / + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8412
SELECT + + CAST ( NULL AS INTEGER ) / + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 16 + + col2 AS col2 FROM tab2 AS cor0
----
10
11
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-8414
SELECT + CAST( 51 AS SIGNED ) DIV + col0 AS col2 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8414
SELECT + CAST ( 51 AS INTEGER ) / + col0 AS col2 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT + ( 9 ) * - col1 + col2 AS col1 FROM tab2 AS cor0
----
-115
-252
-505

onlyif mysql # use DIV operator for integer division
query I rowsort label-8416
SELECT + cor0.col0 + + 38 DIV - cor0.col0 FROM tab2 AS cor0
----
2
78
79

skipif mysql # not compatible
query I rowsort label-8416
SELECT + cor0.col0 + + 38 / - cor0.col0 FROM tab2 AS cor0
----
2
78
79

query I rowsort
SELECT ALL + ( - col1 ) + cor0.col2 * col2 FROM tab0 AS cor0
----
-96
1003
6633

onlyif mysql # use DIV operator for integer division
query I rowsort label-8418
SELECT + col1 DIV + ( + tab0.col1 ) FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8418
SELECT + col1 / + ( + tab0.col1 ) FROM tab0
----
1
1
1

query I rowsort
SELECT 26 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT + + 73 * col0 - col2 FROM tab2 AS cor0
----
484
5668
5729

query I rowsort
SELECT DISTINCT - - col2 * - 10 - - col1 FROM tab2 AS cor0
----
-201
-239
-363

query I rowsort
SELECT + 58 * - col2 + + col2 * col1 FROM tab0 AS cor0
----
2706
39
924

query I rowsort
SELECT DISTINCT col1 * + cor0.col0 + col2 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-8424
SELECT DISTINCT col1 DIV col1 + + col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8424
SELECT DISTINCT col1 / col1 + + col1 / - col1 AS col0 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8425
SELECT CAST( col2 + + col1 AS SIGNED ) * + col1 * + col1 FROM tab2
----
15895
295885
55738

skipif mysql # not compatible
query I rowsort label-8425
SELECT CAST ( col2 + + col1 AS INTEGER ) * + col1 * + col1 FROM tab2
----
15895
295885
55738

query I rowsort
SELECT ( - 34 + - col1 ) * + col1 AS col0 FROM tab0
----
-10320
-11375
-12707

query I rowsort
SELECT col0 * col1 - - cor0.col1 AS col2 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT ALL 40 FROM tab1, tab1 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT - + col1 + 28 AS col0 FROM tab2 cor0
----
-3
-31
11

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT ALL - 35 - 42 FROM tab0 AS cor0
----
-77
-77
-77

query I rowsort
SELECT DISTINCT - - 31 - - ( - col2 ) FROM tab2 AS cor0
----
-7
4
5

query I rowsort
SELECT ALL 28 + col2 + col0 FROM tab2 cor0
----
132
145
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8434
SELECT ALL - CAST( + 78 + col0 * 11 AS SIGNED ) col1 FROM tab2
----
-155
-936
-947

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8434
SELECT ALL - CAST ( + 78 + col0 * 11 AS INTEGER ) col1 FROM tab2
----
-155
-936
-947

query I rowsort
SELECT - 90 * - col1 AS col0 FROM tab0
----
7740
8190
8730

query I rowsort
SELECT 10 * + col1 * - col2 AS col0 FROM tab2
----
-15340
-6460
-8370

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8437
SELECT ALL - ( + col1 ) * - col2 * + CAST( NULL AS SIGNED ) - 21 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8437
SELECT ALL - ( + col1 ) * - col2 * + CAST ( NULL AS INTEGER ) - 21 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 8 FROM tab2 cor0
----
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8439
SELECT + 32 * + cor0.col2 + + CAST( col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1295
871
910

skipif mysql # not compatible
query I rowsort label-8439
SELECT + 32 * + cor0.col2 + + CAST ( col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1295
871
910

query I rowsort
SELECT ALL col0 * col2 + + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col2 * - ( - col1 + + col2 ) col0 FROM tab0 AS cor0
----
-1663
-647
1

query I rowsort
SELECT DISTINCT - col1 * col1 + 29 AS col1 FROM tab2 AS cor0
----
-260
-3452
-932

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col1 * - col1 + tab0.col0 col0 FROM tab0
----
7506
8461
9541

query I rowsort
SELECT col2 * 21 + col1 FROM tab2
----
598
605
815

query I rowsort
SELECT DISTINCT - col2 + + col2 * col2 FROM tab2
----
1406
650
702

query I rowsort
SELECT ALL cor0.col1 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 25 * col0 - + col2 * - 25 FROM tab0
----
1425
4275
900

query I rowsort
SELECT DISTINCT + ( + 40 ) * + tab1.col0 - + col0 FROM tab1
----
117
2496
3120

query I rowsort
SELECT ALL + cor0.col2 + 14 AS col1 FROM tab2 AS cor0
----
40
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8450
SELECT DISTINCT col1 - - 48 DIV + col2 FROM tab0 AS cor0
----
145
87
91

skipif mysql # not compatible
query I rowsort label-8450
SELECT DISTINCT col1 - - 48 / + col2 FROM tab0 AS cor0
----
145
87
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-8451
SELECT ALL - col0 + - col0 DIV - ( + col0 * + col0 ) FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8451
SELECT ALL - col0 + - col0 / - ( + col0 * + col0 ) FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + cor0.col2 * - ( col1 + col2 ) AS col2 FROM tab1 AS cor0
----
-10464
-3819
-4320

query I rowsort
SELECT DISTINCT + cor0.col1 + - ( - ( cor0.col0 ) ) FROM tab2 cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8454
SELECT DISTINCT + - col2 * ( - col2 ) DIV + col0 + + CAST( - 27 AS SIGNED ) * + col1 - col0 col1 FROM tab0 cor0
----
-2301
-2471
-2654

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8454
SELECT DISTINCT + - col2 * ( - col2 ) / + col0 + + CAST ( - 27 AS INTEGER ) * + col1 - col0 col1 FROM tab0 cor0
----
-2301
-2471
-2654

query I rowsort
SELECT DISTINCT col2 * - ( + col2 * col0 ) + 71 FROM tab1 AS cor0
----
-207865
-737209
-8677

onlyif mysql # use DIV operator for integer division
query I rowsort label-8456
SELECT DISTINCT tab2.col0 DIV + col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8456
SELECT DISTINCT tab2.col0 / + col1 FROM tab2
----
0
1
4

query I rowsort
SELECT + col2 - col1 AS col2 FROM tab2
----
-33
-4
21

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to b9fc7433316cc7891b52d2a23a135419

onlyif mysql # use DIV operator for integer division
query I rowsort label-8459
SELECT + col1 * col2 DIV tab2.col0 - col0 * col0 AS col2 FROM tab2
----
-6065
-6233
70

skipif mysql # not compatible
query I rowsort label-8459
SELECT + col1 * col2 / tab2.col0 - col0 * col0 AS col2 FROM tab2
----
-6065
-6233
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-8460
SELECT + col0 DIV col1 col1 FROM tab1
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8460
SELECT + col0 / col1 col1 FROM tab1
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 col0 FROM tab1, tab0, tab0 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8462
SELECT - 34 + + col1 DIV - tab0.col0 col1 FROM tab0
----
-35
-36
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8462
SELECT - 34 + + col1 / - tab0.col0 col1 FROM tab0
----
-35
-36
-37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8463
SELECT ALL - col1 * + tab0.col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8463
SELECT ALL - col1 * + tab0.col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + tab1.col1 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT ( col2 * col2 ) + + col1 AS col1 FROM tab2
----
1461
735
760

query I rowsort
SELECT - col2 * col0 - col2 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT - col1 + tab2.col1 + + tab2.col1 * 9 FROM tab2
----
153
279
531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8469
SELECT tab1.col2 * col2 DIV - CAST( 79 AS SIGNED ) AS col1 FROM tab1
----
-116
-36
-41

skipif mysql # not compatible
query I rowsort label-8469
SELECT tab1.col2 * col2 / - CAST ( 79 AS INTEGER ) AS col1 FROM tab1
----
-116
-36
-41

query I rowsort
SELECT ALL + + cor0.col0 + cor0.col0 + - col2 AS col0 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT DISTINCT + cor0.col2 + cor0.col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL col2 * - 78 FROM tab1 AS cor0
----
-4212
-4446
-7488

query I rowsort
SELECT DISTINCT + col2 * 35 FROM tab1 AS cor0
----
1890
1995
3360

query I rowsort
SELECT ALL + cor0.col1 * - 67 FROM tab0 AS cor0
----
-5762
-6097
-6499

query I rowsort
SELECT + col0 + - ( ( col0 ) ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * cor0.col0 + cor0.col2 - + cor0.col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - col2 + - ( + col1 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT - - col1 - - col0 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL col1 * ( + 89 ) FROM tab1 cor0
----
1157
2314
890

query I rowsort
SELECT + + col2 * - col0 + - col0 AS col1 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT - col0 * col1 + + col2 * col0 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT DISTINCT - cor0.col0 + + ( + ( + col1 ) ) AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + tab0.col1 - col2 FROM tab0
----
53
9
96

query I rowsort
SELECT + + col1 + - col1 * col0 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + col0 + ( 21 ) FROM tab1 AS cor0
----
101
24
85

query I rowsort
SELECT ALL ( + col0 ) + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + col0 * + col1 + cor0.col2 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT col0 * - ( col1 ) AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + ( - col1 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 48 * col1 + col2 FROM tab1
----
1302
537
720

query I rowsort
SELECT ALL - col1 + ( + col2 ) FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT ( col1 ) + cor0.col1 * col1 FROM tab0 cor0
----
7482
8372
9506

query I rowsort
SELECT ALL - - col1 * - col1 - col2 AS col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT + - cor0.col1 * 59 FROM tab2 cor0
----
-1003
-1829
-3481

query I rowsort
SELECT - col0 + col2 * + cor0.col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT + col2 + ( + col2 ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL ( col1 ) * cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + 9 + col1 FROM tab2 AS cor0
----
26
40
68

query I rowsort
SELECT ALL - ( + 74 ) FROM tab2 AS cor0
----
-74
-74
-74

query I rowsort
SELECT DISTINCT col0 * - col1 + + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - 54 * col2 - col2 FROM tab0 cor0
----
-1815
-4510
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8502
SELECT DISTINCT CAST( NULL AS SIGNED ) * col1 * col0 + 26 * col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8502
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col1 * col0 + 26 * col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - - 19 * - col1 AS col2 FROM tab1 AS cor0
----
-190
-247
-494

query I rowsort
SELECT ALL - + col2 + + col0 AS col1 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8505
SELECT ALL + col2 * + col1 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8505
SELECT ALL + col2 * + col1 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + col2 col0 FROM tab1 cor0
----
0

query I rowsort
SELECT col2 + col0 * col2 AS col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT 23 + - tab0.col0 AS col0 FROM tab0
----
-1
-12
-66

query I rowsort
SELECT - 12 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-19
-90
-91

query I rowsort
SELECT ( 9 ) AS col2 FROM tab2
----
9
9
9

query I rowsort
SELECT ALL 34 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 49 col2 FROM tab1
----
49
49
49

query I rowsort
SELECT - ( - 64 ) AS col2 FROM tab2
----
64
64
64

query I rowsort
SELECT - 38 AS col1 FROM tab2 cor0
----
-38
-38
-38

query I rowsort
SELECT + 33 AS col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + 11 * - col1 col2 FROM tab1
----
13728
15444
6270

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 + - col0 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT + 73 AS col0 FROM tab1 cor0
----
73
73
73

query I rowsort
SELECT ALL 64 AS col0 FROM tab0
----
64
64
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-8520
SELECT DISTINCT col1 DIV - 11 + col2 * col1 FROM tab2
----
1529
645
835

skipif mysql # not compatible
query I rowsort label-8520
SELECT DISTINCT col1 / - 11 + col2 * col1 FROM tab2
----
1529
645
835

query I rowsort
SELECT - + 26 * ( col2 ) FROM tab2 AS cor0
----
-676
-702
-988

query I rowsort
SELECT 29 * col1 + + col1 * + ( 90 * - col2 ) FROM tab1 AS cor0
----
-111943
-125606
-51010

query I rowsort
SELECT col2 + - col1 + + col2 * + tab1.col2 FROM tab1
----
2944
3296
9299

query I rowsort
SELECT + - col2 + - col2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - col0 * 29 * col1 AS col2 FROM tab1 cor0
----
-18560
-2262
-30160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8526
SELECT - 18 * - 74 + col1 DIV - col1 FROM tab1 AS cor0
----
1331
1331
1331

skipif mysql # not compatible
query I rowsort label-8526
SELECT - 18 * - 74 + col1 / - col1 FROM tab1 AS cor0
----
1331
1331
1331

query I rowsort
SELECT - + cor0.col2 * cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + 40 AS col2 FROM tab2 AS cor0
----
40

query I rowsort
SELECT ALL + col0 * + 40 AS col2 FROM tab2 AS cor0
----
280
3120
3160

query I rowsort
SELECT ALL + col1 * 38 AS col1 FROM tab1 AS cor0
----
380
494
988

query I rowsort
SELECT DISTINCT 12 AS col1 FROM tab1, tab2 AS cor0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 43 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT 22 + - col1 FROM tab1
----
-4
12
9

query I rowsort
SELECT + col0 + ( - 6 ) * - col1 FROM tab2 AS cor0
----
181
193
432

onlyif mysql # use DIV operator for integer division
query I rowsort label-8535
SELECT ALL cor0.col1 DIV tab1.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to ace061bdecf89a0beb1084aa4c19ba8a

skipif mysql # not compatible
query I rowsort label-8535
SELECT ALL cor0.col1 / tab1.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to ace061bdecf89a0beb1084aa4c19ba8a

onlyif mysql # use DIV operator for integer division
query I rowsort label-8536
SELECT - - col0 DIV + ( - col0 ) + col2 FROM tab1 cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-8536
SELECT - - col0 / + ( - col0 ) + col2 FROM tab1 cor0
----
53
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8537
SELECT + + col2 - - col0 DIV col2 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-8537
SELECT + + col2 - - col0 / col2 FROM tab0 AS cor0
----
33
36
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8538
SELECT col2 + 90 DIV 88 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-8538
SELECT col2 + 90 / 88 FROM tab2 AS cor0
----
27
28
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-8539
SELECT + + col1 * - col2 + 91 DIV col2 FROM tab0 AS cor0
----
-2836
-6
-7461

skipif mysql # not compatible
query I rowsort label-8539
SELECT + + col1 * - col2 + 91 / col2 FROM tab0 AS cor0
----
-2836
-6
-7461

query I rowsort
SELECT ALL + 56 * col1 FROM tab0
----
4816
5096
5432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 col2 FROM tab0
----
80

query I rowsort
SELECT DISTINCT 51 * 6 * tab1.col2 FROM tab1
----
16524
17442
29376

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8543
SELECT ALL CAST( - col2 AS SIGNED ) col2 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8543
SELECT ALL CAST ( - col2 AS INTEGER ) col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + ( - col1 ) * + 9 AS col1 FROM tab0 AS cor0
----
-774
-819
-873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) + - cor0.col2 col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT col1 * - col2 + + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 80 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT + 68 + col0 AS col1 FROM tab0 AS cor0
----
103
157
92

query I rowsort
SELECT - 90 * 14 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to b5a2c72cc143eeb52c837e99327eaf38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 * - col0 col2 FROM tab1 AS cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8551
SELECT col1 * - tab2.col2 * 52 + + ( col0 + - 22 ) DIV col0 AS col0 FROM tab2
----
-33592
-43526
-79768

skipif mysql # not compatible
query I rowsort label-8551
SELECT col1 * - tab2.col2 * 52 + + ( col0 + - 22 ) / col0 AS col0 FROM tab2
----
-33592
-43526
-79768

onlyif mysql # use DIV operator for integer division
query I rowsort label-8552
SELECT ALL + ( col2 ) DIV + col0 col0 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8552
SELECT ALL + ( col2 ) / + col0 col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + col1 * - 83 FROM tab2 AS cor0
----
-1411
-2573
-4897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - 58 col1 FROM tab1 AS cor0
----
-55
22
6

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL - col0 + - cor0.col1 + col2 FROM tab1 cor0
----
-17
25
3

query I rowsort
SELECT ALL - col1 * col1 AS col2 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - col0 + ( cor0.col2 ) * col2 FROM tab2 AS cor0
----
1365
598
722

onlyif mysql # use DIV operator for integer division
query I rowsort label-8559
SELECT + - col1 + CAST( 93 AS SIGNED ) DIV col2 - + 81 FROM tab0 AS cor0
----
-165
-171
-85

skipif mysql # not compatible
query I rowsort label-8559
SELECT + - col1 + CAST ( 93 AS INTEGER ) / col2 - + 81 FROM tab0 AS cor0
----
-165
-171
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8560
SELECT + col0 + - CAST( + 52 AS SIGNED ) FROM tab1 AS cor0
----
-49
12
28

skipif mysql # not compatible
query I rowsort label-8560
SELECT + col0 + - CAST ( + 52 AS INTEGER ) FROM tab1 AS cor0
----
-49
12
28

query I rowsort
SELECT DISTINCT - - col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col0 * tab0.col1 * col2 FROM tab0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-8563
SELECT ALL + tab2.col2 DIV - col1 col2 FROM tab2
----
-2
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8563
SELECT ALL + tab2.col2 / - col1 col2 FROM tab2
----
-2
0
0

query I rowsort
SELECT ALL - 23 * + col2 FROM tab0
----
-1886
-23
-759

query I rowsort
SELECT + + col2 - 8 FROM tab0 cor0
----
-7
25
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8566
SELECT ALL + col1 * + CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-8566
SELECT ALL + col1 * + CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL cor0.col2 + - 1 AS col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 + - col2 AS col1 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT + + col1 * ( cor0.col0 ) * - 46 + - 3 * col1 AS col0 FROM tab2 AS cor0
----
-10075
-211869
-61829

query I rowsort
SELECT 86 + - 45 AS col2 FROM tab1 cor0
----
41
41
41

query I rowsort
SELECT - - col2 * ( - col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col1 * 68 * - col1 + col0 * - col1 + col0 * col1 * + 0 AS col1 FROM tab2 AS cor0
----
-20995
-241310
-65565

query I rowsort
SELECT DISTINCT + 32 * 18 AS col0 FROM tab0 AS cor0
----
576

query I rowsort
SELECT DISTINCT + cor0.col2 + + col2 + - 77 FROM tab2 AS cor0
----
-1
-23
-25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + col2 * 64 col1 FROM tab1 AS cor0
----
3402
3591
6048

query I rowsort
SELECT + + 82 + col1 AS col1 FROM tab2 AS cor0
----
113
141
99

query I rowsort
SELECT 51 - col0 * - tab2.col0 FROM tab2
----
100
6135
6292

query I rowsort
SELECT + 81 - + col1 FROM tab2
----
22
50
64

query I rowsort
SELECT ALL col2 * - 38 FROM tab0
----
-1254
-3116
-38

query I rowsort
SELECT ALL 82 - cor0.col1 AS col0 FROM tab1 AS cor0
----
56
69
72

query I rowsort
SELECT - col1 + - 37 AS col1 FROM tab0 AS cor0
----
-123
-128
-134

query I rowsort
SELECT DISTINCT col0 * + 89 FROM tab1
----
267
5696
7120

query I rowsort
SELECT ALL - col2 + - 29 FROM tab1 AS cor0
----
-125
-83
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-8584
SELECT ALL col0 DIV col1 col0 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8584
SELECT ALL col0 / col1 col0 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 50 col0 FROM tab1 AS cor0
----
50

query I rowsort
SELECT ALL + 20 AS col0 FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT ALL ( col1 ) * - col2 + tab0.col2 * 13 AS col1 FROM tab0
----
-2409
-6396
-84

query I rowsort
SELECT - 1 * - col1 AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8589
SELECT ALL + col0 * col2 + + cor0.col0 DIV - col2 FROM tab1 AS cor0
----
162
3647
7680

skipif mysql # not compatible
query I rowsort label-8589
SELECT ALL + col0 * col2 + + cor0.col0 / - col2 FROM tab1 AS cor0
----
162
3647
7680

query I rowsort
SELECT ALL + - 40 + - col2 AS col1 FROM tab1 AS cor0
----
-136
-94
-97

query I rowsort
SELECT DISTINCT col2 * cor0.col0 - col1 AS col1 FROM tab2 cor0
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-8592
SELECT DISTINCT + col2 DIV - col2 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8592
SELECT DISTINCT + col2 / - col2 FROM tab1 cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 * col1 col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - 5 * - col1 AS col1 FROM tab1 cor0
----
130
50
65

query I rowsort
SELECT ALL ( + 31 ) * + col0 AS col1 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT + 34 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

onlyif mysql # use DIV operator for integer division
query I rowsort label-8597
SELECT col2 * col2 DIV col0 + + col0 col1 FROM tab2
----
111
86
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8597
SELECT col2 * col2 / col0 + + col0 col1 FROM tab2
----
111
86
97

query I rowsort
SELECT ALL + ( cor0.col1 ) + col2 * + ( cor0.col0 ) AS col1 FROM tab0 cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-8599
SELECT col2 + + col2 + + 45 * 14 DIV col1 AS col0 FROM tab2 AS cor0
----
113
62
74

skipif mysql # not compatible
query I rowsort label-8599
SELECT col2 + + col2 + + 45 * 14 / col1 AS col0 FROM tab2 AS cor0
----
113
62
74

query I rowsort
SELECT DISTINCT 27 * cor0.col1 FROM tab0 AS cor0
----
2322
2457
2619

query I rowsort
SELECT - ( - col1 ) AS col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL col2 + col2 * - ( + col2 * - col1 ) AS col1 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT DISTINCT - - cor0.col1 + col0 * 0 * 14 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + 66 * col0 AS col1 FROM tab0 AS cor0
----
1584
2310
5874

query I rowsort
SELECT + cor0.col1 * - cor0.col0 + - cor0.col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL 63 * col1 + - col2 FROM tab0 AS cor0
----
5385
5651
6110

query I rowsort
SELECT DISTINCT - - cor0.col0 * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + - col1 * 94 AS col0 FROM tab1 AS cor0
----
-1222
-2444
-940

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab2 cor1, tab2, tab1 cor2
----
3645 values hashing to 9b60cb1db2fb2fa5700b0e572b4b6546

query I rowsort
SELECT col0 * + ( col2 ) FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + col0 + 81 FROM tab1 cor0
----
145
161
84

query I rowsort
SELECT ALL col2 + 46 * + col0 FROM tab2 AS cor0
----
349
3614
3672

query I rowsort
SELECT ALL - col0 + - 21 AS col2 FROM tab1 AS cor0
----
-101
-24
-85

query I rowsort
SELECT DISTINCT - col2 * + 96 + - col0 AS col2 FROM tab2 AS cor0
----
-2574
-2599
-3727

query I rowsort
SELECT - cor0.col1 + col0 * ( + col0 ) + + 67 * col0 FROM tab0 AS cor0
----
13793
2098
3473

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + + 62 col0 FROM tab2 AS cor0
----
100
88
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + 30 * col0 col1 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT DISTINCT + - col0 * + 91 + col1 AS col2 FROM tab1 AS cor0
----
-247
-5814
-7267

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8619
SELECT col2 + - CAST( 99 * + col2 AS SIGNED ) col1 FROM tab0 cor0
----
-3234
-8036
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8619
SELECT col2 + - CAST ( 99 * + col2 AS INTEGER ) col1 FROM tab0 cor0
----
-3234
-8036
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8620
SELECT + + CAST( 33 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
33
33
33

skipif mysql # not compatible
query I rowsort label-8620
SELECT + + CAST ( 33 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
33
33
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-8621
SELECT + + CAST( col1 AS SIGNED ) + + col0 DIV CAST( cor0.col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-8621
SELECT + + CAST ( col1 AS INTEGER ) + + col0 / CAST ( cor0.col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
11
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8622
SELECT 89 DIV ( + col1 ) FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-8622
SELECT 89 / ( + col1 ) FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT DISTINCT + 14 * + 19 AS col2 FROM tab0, tab0 AS cor0
----
266

query I rowsort
SELECT DISTINCT - + col1 - - col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + col1 * - col0 - ( col2 ) FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT - + col0 * cor0.col1 + col1 * ( col2 ) FROM tab2 AS cor0
----
-3068
-697
620

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 89 ) col0 FROM tab2, tab1 cor0
----
-89

query I rowsort
SELECT ALL + - 4 - + col1 * col1 * + 58 FROM tab2 cor0
----
-16766
-201902
-55742

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8629
SELECT ALL col1 + - col1 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8629
SELECT ALL col1 + - col1 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 4 - cor0.col0 * + col1 col2 FROM tab2 cor0
----
-1347
-221
-4606

onlyif mysql # use DIV operator for integer division
query I rowsort label-8631
SELECT + + col2 DIV col0 - + 88 AS col1 FROM tab2 AS cor0
----
-85
-88
-88

skipif mysql # not compatible
query I rowsort label-8631
SELECT + + col2 / col0 - + 88 AS col1 FROM tab2 AS cor0
----
-85
-88
-88

query I rowsort
SELECT - 86 * col2 - col1 AS col2 FROM tab1 AS cor0
----
-4670
-4912
-8269

query I rowsort
SELECT ALL 26 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT ALL - col1 * col1 + - 50 AS col0 FROM tab2
----
-1011
-339
-3531

query I rowsort
SELECT ALL + tab0.col0 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-8636
SELECT + 65 + col2 DIV col2 AS col1 FROM tab1
----
66
66
66

skipif mysql # not compatible
query I rowsort label-8636
SELECT + 65 + col2 / col2 AS col1 FROM tab1
----
66
66
66

query I rowsort
SELECT col2 + - col1 + - 6 FROM tab2
----
-10
-39
15

query I rowsort
SELECT ALL + 24 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT DISTINCT col1 * - col1 + + 33 FROM tab1
----
-136
-643
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * - col0 + ( - 44 ) + cor0.col2 col2 FROM tab2 AS cor0
----
-1349
-234
-4620

query I rowsort
SELECT col1 + - col0 * + 19 AS col0 FROM tab1 AS cor0
----
-1206
-1507
-31

query I rowsort
SELECT DISTINCT 38 * col0 + col1 AS col2 FROM tab1 AS cor0
----
140
2442
3053

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 * col1 FROM tab0 AS cor0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-8644
SELECT - ( - cor0.col2 ) DIV 83 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8644
SELECT - ( - cor0.col2 ) / 83 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 51 FROM tab2 AS cor0
----
-51
-51
-51

query I rowsort
SELECT DISTINCT - 33 + + col2 AS col1 FROM tab2 AS cor0
----
-6
-7
5

query I rowsort
SELECT ALL + col1 + col2 + + 89 FROM tab0 cor0
----
187
208
262

query I rowsort
SELECT ALL - - col2 + - col0 * 40 FROM tab2 AS cor0
----
-253
-3094
-3122

query I rowsort
SELECT col2 * 48 - - col0 FROM tab0 AS cor0
----
1608
4025
83

query I rowsort
SELECT + cor0.col0 + 16 AS col2 FROM tab1 AS cor0
----
19
80
96

query I rowsort
SELECT + 52 FROM tab2 cor0
----
52
52
52

query I rowsort
SELECT ALL + + col0 * - col0 + + col2 * ( + col1 ) FROM tab2 AS cor0
----
-4550
-5595
788

query I rowsort
SELECT - - col1 * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT + cor0.col1 * + cor0.col0 AS col1 FROM tab1, tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL 92 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 55 col0 FROM tab0
----
55
55
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col0 * col2 ) col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + cor0.col0 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT + ( - col1 + - col0 ) FROM tab2
----
-137
-38
-96

query I rowsort
SELECT - 30 + - col1 FROM tab0 AS cor0
----
-116
-121
-127

query I rowsort
SELECT - col2 * - ( - col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL 98 * col1 + + col1 FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT ALL - cor0.col1 * col2 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8665
SELECT ALL + + col1 * col1 * CAST( NULL AS SIGNED ) + cor0.col2 / - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8665
SELECT ALL + + col1 * col1 * CAST ( NULL AS INTEGER ) + cor0.col2 / - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 38 + - tab1.col1 * col2 AS col0 FROM tab1
----
-1210
-1366
-532

onlyif mysql # use DIV operator for integer division
query I rowsort label-8667
SELECT - col0 DIV + col0 + - col1 col2 FROM tab2
----
-18
-32
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8667
SELECT - col0 / + col0 + - col1 col2 FROM tab2
----
-18
-32
-60

query I rowsort
SELECT ALL + 1 * + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - - 87 AS col0 FROM tab2 AS cor0
----
87

query I rowsort
SELECT DISTINCT - 2 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2 cor2
----
-2

query I rowsort
SELECT DISTINCT + col0 + 51 AS col1 FROM tab0
----
140
75
86

query I rowsort
SELECT tab1.col0 + + tab1.col0 * col1 - col1 * + ( col0 ) FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + col2 * + 32 + + 17 AS col1 FROM tab0
----
1073
2641
49

query I rowsort
SELECT col0 * - 38 FROM tab0
----
-1330
-3382
-912

query I rowsort
SELECT ALL - col2 * ( col1 ) - col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT - col0 + ( col0 + + col2 ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + cor0.col2 * - 56 + ( col0 ) AS col1 FROM tab1 cor0
----
-3021
-3128
-5296

query I rowsort
SELECT DISTINCT + + col0 * + col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + col2 + + col2 * - col2 + - cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + + ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - ( 49 ) * col2 AS col0 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT + 48 + 68 FROM tab1 AS cor0
----
116
116
116

onlyif mysql # use DIV operator for integer division
query I rowsort label-8683
SELECT DISTINCT + + col1 DIV 36 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8683
SELECT DISTINCT + + col1 / 36 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - 79 * + col2 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT + cor0.col2 * - 76 AS col2 FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT - - cor0.col0 * col0 + cor0.col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT DISTINCT - 53 * + col1 AS col2 FROM tab1 AS cor0
----
-1378
-530
-689

query I rowsort
SELECT col1 * 2 * col1 + 47 * - col2 AS col0 FROM tab1 AS cor0
----
-1186
-2479
-4174

onlyif mysql # use DIV operator for integer division
query I rowsort label-8689
SELECT ALL col2 DIV + 10 FROM tab1
----
5
5
9

skipif mysql # not compatible
query I rowsort label-8689
SELECT ALL col2 / + 10 FROM tab1
----
5
5
9

query I rowsort
SELECT ALL - 76 AS col2 FROM tab2 AS cor0
----
-76
-76
-76

query I rowsort
SELECT ALL + ( - col1 ) * col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col0 + col0 * col0 AS col2 FROM tab2 cor0
----
56
6162
6320

query I rowsort
SELECT DISTINCT - - 28 * col0 AS col0 FROM tab1 cor0
----
1792
2240
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-8694
SELECT ALL - cor0.col1 DIV col0 col2 FROM tab2 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8694
SELECT ALL - cor0.col1 / col0 col2 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT + ( - col0 ) * col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT ( - col2 ) > ( NULL )
----

query I rowsort
SELECT ALL col0 * col1 / col0 FROM tab2 AS cor0 WHERE cor0.col0 >= NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE ( NULL ) <= NULL
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE ( NULL ) <= + col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col0 * + col1 col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT col0 + col0 FROM tab0 WHERE NOT NULL IN ( - col2 * col1 )
----

query I rowsort
SELECT col2 + tab1.col0 * + col0 * col1 AS col1 FROM tab1
----
288
41017
83296

onlyif mysql # use DIV operator for integer division
query I rowsort label-8703
SELECT col1 + + col0 DIV col1 FROM tab2
----
21
31
60

skipif mysql # not compatible
query I rowsort label-8703
SELECT col1 + + col0 / col1 FROM tab2
----
21
31
60

query I rowsort
SELECT ALL col0 * col0 + + col2 AS col2 FROM tab1
----
4153
63
6496

query I rowsort
SELECT DISTINCT + tab2.col0 + - col1 * + col1 AS col2 FROM tab2
----
-210
-3403
-954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - - col1 col1 FROM tab0
----
110
132
180

query I rowsort
SELECT tab1.col1 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - col1 + + col2 - col2 * col1 AS col1 FROM tab1
----
-1165
-1376
-523

query I rowsort
SELECT - - col0 * + col0 + - col2 * - col1 FROM tab0 AS cor0
----
1322
15383
3414

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL + col1 * - col1 + - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-174
-262
-705

query I rowsort
SELECT DISTINCT col2 * col0 + col0 * col1 + - tab1.col2 FROM tab1
----
186
4231
8624

onlyif mysql # use DIV operator for integer division
query I rowsort label-8713
SELECT - col2 DIV - col0 + col0 * col1 + - tab2.col2 AS col2 FROM tab2
----
1305
193
4576

skipif mysql # not compatible
query I rowsort label-8713
SELECT - col2 / - col0 + col0 * col1 + - tab2.col2 AS col2 FROM tab2
----
1305
193
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-8714
SELECT - col2 DIV tab2.col1 AS col0 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-8714
SELECT - col2 / tab2.col1 AS col0 FROM tab2
----
-2
0
0

query I rowsort
SELECT - col2 + col1 + col0 AS col0 FROM tab0
----
131
77
98

query I rowsort
SELECT DISTINCT tab0.col0 * + col0 + - col2 * + col0 FROM tab0
----
-216
1190
623

query I rowsort
SELECT DISTINCT tab0.col2 * col0 - col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT + col1 + col1 * - col0 AS col0 FROM tab1
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-8719
SELECT DISTINCT col0 + col1 DIV - col0 FROM tab0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-8719
SELECT DISTINCT col0 + col1 / - col0 FROM tab0
----
21
33
88

query I rowsort
SELECT + col1 * + col2 + - col0 + + col0 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 + col1 * + col1 col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT ALL - col1 + col2 * + col0 AS col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + col0 * + col2 + + col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-8724
SELECT col1 + - col2 DIV col1 AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8724
SELECT col1 + - col2 / col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - + col0 * col1 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8726
SELECT - col0 * + col1 + col1 DIV + col0 AS col0 FROM tab2 AS cor0
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-8726
SELECT - col0 * + col1 + col1 / + col0 AS col0 FROM tab2 AS cor0
----
-1343
-213
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8727
SELECT DISTINCT - + col0 DIV - col0 - + col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-8727
SELECT DISTINCT - + col0 / - col0 - + col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT DISTINCT + + col0 * col0 - col0 * col2 FROM tab0 AS cor0
----
-216
1190
623

query I rowsort
SELECT tab0.col0 * - col1 + 51 + col2 FROM tab0
----
-1980
-3343
-7966

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8730
SELECT + cor0.col1 + CAST( NULL AS SIGNED ) * 10 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8730
SELECT + cor0.col1 + CAST ( NULL AS INTEGER ) * 10 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * tab0.col2 + col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT col2 + col0 + + col0 AS col0 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT - ( + col2 ) * col0 - col1 AS col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT col2 + col2 - + ( - 90 ) FROM tab2 AS cor0
----
142
144
166

query I rowsort
SELECT ALL + col2 + cor0.col1 * col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + - col0 * - 38 + - col1 * col2 AS col0 FROM tab2 cor0
----
-571
1430
2356

query I rowsort
SELECT col0 * - 89 FROM tab1 AS cor0
----
-267
-5696
-7120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8738
SELECT + cor0.col0 * CAST( col0 AS SIGNED ) * cor0.col0 FROM tab2 cor0
----
343
474552
493039

skipif mysql # not compatible
query I rowsort label-8738
SELECT + cor0.col0 * CAST ( col0 AS INTEGER ) * cor0.col0 FROM tab2 cor0
----
343
474552
493039

query I rowsort
SELECT DISTINCT - ( 81 ) FROM tab2, tab1 AS cor0
----
-81

query I rowsort
SELECT - + col2 + - 40 AS col2 FROM tab2 cor0
----
-66
-67
-78

query I rowsort
SELECT - col1 * - 35 + + 15 FROM tab0 AS cor0
----
3025
3200
3410

skipif mysql # not compatible
query I rowsort
SELECT - col2 - CAST ( col2 AS REAL ) AS col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT - - col0 * - 2 + col2 AS col2 FROM tab2 cor0
----
-120
-130
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-8744
SELECT - col2 * - col2 DIV col2 + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-8744
SELECT - col2 * - col2 / col2 + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8745
SELECT + col1 DIV col1 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8745
SELECT + col1 / col1 AS col1 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8746
SELECT tab1.col1 DIV + col0 col0 FROM tab1
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8746
SELECT tab1.col1 / + col0 col0 FROM tab1
----
0
0
8

query I rowsort
SELECT DISTINCT tab0.col0 * - col2 + + col1 AS col2 FROM tab0 WHERE col2 * col1 > col1
----
-706
-7207

query I rowsort
SELECT - col2 - col0 * - col0 * tab0.col0 AS col0 FROM tab0
----
13791
42874
704887

query I rowsort
SELECT DISTINCT 20 * - cor0.col0 FROM tab1, tab1 AS cor0
----
-1280
-1600
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-8750
SELECT + col0 DIV col0 + + col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-8750
SELECT + col0 / col0 + + col0 FROM tab2 AS cor0
----
79
8
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 - - ( + 29 ) col2 FROM tab0 AS cor0
----
2093
3424
8128

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL < NULL
----

query I rowsort
SELECT - tab2.col2 + col2 * - col0 FROM tab2
----
-2054
-216
-3040

query I rowsort
SELECT ALL - col1 - col1 AS col2 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT col0 FROM tab2 WHERE col2 = ( NULL )
----

query I rowsort
SELECT - col2 + + col1 - col0 AS col2 FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT ALL tab1.col2 FROM tab1 WHERE NULL BETWEEN NULL AND ( col1 )
----

query I rowsort
SELECT ALL - col1 * col0 * col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8760
SELECT tab0.col0 DIV col0 - col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-8760
SELECT tab0.col0 / col0 - col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT + col0 * col0 + - col1 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT - col0 * - ( + cor0.col0 ) FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + 17 * col1 col2 FROM tab1 AS cor0
----
180
234
468

query I rowsort
SELECT cor0.col0 + 88 * col0 FROM tab0 AS cor0
----
2136
3115
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8765
SELECT - CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8765
SELECT - CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 99 * col0 AS col1 FROM tab1 AS cor0
----
297
6336
7920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8767
SELECT DISTINCT CAST( - col0 AS SIGNED ) + cor0.col1 FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-8767
SELECT DISTINCT CAST ( - col0 AS INTEGER ) + cor0.col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col1 * - col2 + col0 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - ( col0 ) - 39 * ( col0 ) FROM tab0 cor0
----
-1400
-3560
-960

query I rowsort
SELECT + + 59 + + col2 * ( col0 * - col1 ) FROM tab1 AS cor0
----
-36421
-4153
-99781

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 + - 21 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 8f9036d8fbe1edb8a35c6a642edcbb6e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8772
SELECT - col0 DIV - 23 AS col0 FROM tab0 AS cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-8772
SELECT - col0 / - 23 AS col0 FROM tab0 AS cor0
----
1
1
3

query I rowsort
SELECT DISTINCT col0 * - 59 FROM tab2 AS cor0
----
-413
-4602
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-8774
SELECT ALL col2 * col2 DIV 52 AS col1 FROM tab1
----
177
56
62

skipif mysql # not compatible
query I rowsort label-8774
SELECT ALL col2 * col2 / 52 AS col1 FROM tab1
----
177
56
62

query I rowsort
SELECT DISTINCT + + 42 FROM tab2, tab1, tab1 AS cor0
----
42

query I rowsort
SELECT DISTINCT + col2 + 85 * col2 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT ALL - - col1 * + col1 + col2 * col1 FROM tab2 AS cor0
----
1798
5015
935

query I rowsort
SELECT + col0 + + 24 * - col2 * + col0 FROM tab0 AS cor0
----
-175063
-18984
-805

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8779
SELECT ALL col0 * CAST( 85 AS SIGNED ) col1 FROM tab1 AS cor0
----
255
5440
6800

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8779
SELECT ALL col0 * CAST ( 85 AS INTEGER ) col1 FROM tab1 AS cor0
----
255
5440
6800

onlyif mysql # use DIV operator for integer division
query I rowsort label-8780
SELECT - col1 + - 6 DIV ( col0 ) FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-8780
SELECT - col1 + - 6 / ( col0 ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + + col2 + col2 - col1 AS col2 FROM tab2 cor0
----
-7
23
59

query I rowsort
SELECT DISTINCT + cor0.col2 + cor0.col0 * 14 FROM tab2 AS cor0
----
1118
1144
125

query I rowsort
SELECT ALL 70 - + tab1.col0 FROM tab1
----
-10
6
67

query I rowsort
SELECT - col2 + - tab0.col1 * - col0 AS col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT + 75 * + col1 FROM tab2
----
1275
2325
4425

query I rowsort
SELECT col2 * + ( col1 ) AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 * 93 AS col2 FROM tab2
----
2418
2511
3534

query I rowsort
SELECT DISTINCT tab0.col0 + + 11 FROM tab0
----
100
35
46

query I rowsort
SELECT DISTINCT col2 + + 35 AS col2 FROM tab2 AS cor0
----
61
62
73

query I rowsort
SELECT DISTINCT - col2 * 51 + + col0 * + col0 FROM tab1
----
-2745
1189
1504

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8791
SELECT ALL - col1 + + CAST( NULL AS DECIMAL ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8791
SELECT ALL - col1 + + CAST ( NULL AS REAL ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 89 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT 86 + + col1 FROM tab1 cor0
----
112
96
99

query I rowsort
SELECT ALL + col0 - col0 * col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + ( + col2 ) * col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT col1 * + 70 FROM tab2
----
1190
2170
4130

query I rowsort
SELECT - 97 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8798
SELECT CAST( NULL AS DECIMAL ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8798
SELECT CAST ( NULL AS REAL ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( cor0.col0 ) col0 FROM tab2, tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - 82 FROM tab1, tab0, tab0 cor0
----
-82

query I rowsort
SELECT ALL + tab2.col2 * - col0 * col2 AS col2 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT ALL col2 * 91 AS col0 FROM tab1
----
4914
5187
8736

query I rowsort
SELECT + col0 * col2 - 27 AS col0 FROM tab1 AS cor0
----
135
3621
7653

onlyif mysql # use DIV operator for integer division
query I rowsort label-8804
SELECT + col2 DIV col1 + - 14 + col2 col0 FROM tab1 AS cor0
----
42
48
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8804
SELECT + col2 / col1 + - 14 + col2 col0 FROM tab1 AS cor0
----
42
48
89

query I rowsort
SELECT DISTINCT + - ( - cor0.col1 ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8806
SELECT - col0 DIV + col2 - ( - col0 + + col2 ) * col2 AS col0 FROM tab1 AS cor0
----
-1536
-2754
398

skipif mysql # not compatible
query I rowsort label-8806
SELECT - col0 / + col2 - ( - col0 + + col2 ) * col2 AS col0 FROM tab1 AS cor0
----
-1536
-2754
398

query I rowsort
SELECT DISTINCT - + col0 * col0 + + col1 * + 0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + 55 + + cor0.col0 * + 15 - - col1 FROM tab1 cor0
----
1025
126
1268

query I rowsort
SELECT + - col2 - + cor0.col0 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + col1 + - cor0.col0 - col0 FROM tab0 AS cor0
----
-87
27
38

query I rowsort
SELECT 43 + + col0 * 35 + - col1 FROM tab1 AS cor0
----
122
2273
2830

onlyif mysql # use DIV operator for integer division
query I rowsort label-8812
SELECT - col0 DIV + col0 + - 71 AS col2 FROM tab2 AS cor0
----
-72
-72
-72

skipif mysql # not compatible
query I rowsort label-8812
SELECT - col0 / + col0 + - 71 AS col2 FROM tab2 AS cor0
----
-72
-72
-72

query I rowsort
SELECT + col2 * cor0.col1 + ( + ( cor0.col0 ) ) - 60 AS col1 FROM tab0 AS cor0
----
2802
72
7491

query I rowsort
SELECT ALL + col2 * + col1 * col0 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - - col1 + + cor0.col2 + col2 AS col1 FROM tab2 cor0
----
111
85
93

query I rowsort
SELECT DISTINCT col1 * + 44 + - col1 AS col1 FROM tab0 cor0
----
3698
3913
4171

query I rowsort
SELECT cor0.col0 * - col0 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL - 29 FROM tab2, tab0 AS cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

query I rowsort
SELECT ALL ( + tab2.col2 ) * col1 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 41 + - 14 col0 FROM tab0 AS cor0
----
27
27
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * 71 col2 FROM tab0 cor0
----
2343
5822
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8822
SELECT + - CAST( NULL AS SIGNED ) * + col1 - + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8822
SELECT + - CAST ( NULL AS INTEGER ) * + col1 - + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 31 * - col1 FROM tab2 AS cor0
----
-1829
-527
-961

query I rowsort
SELECT col1 * col2 * col1 AS col1 FROM tab0 cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT 68 * col0 * col2 FROM tab1 AS cor0
----
11016
248064
522240

onlyif mysql # use DIV operator for integer division
query I rowsort label-8826
SELECT 59 DIV col1 + - cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
2
4
5

skipif mysql # not compatible
query I rowsort label-8826
SELECT 59 / col1 + - cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
2
4
5

query I rowsort
SELECT + - col0 + - col1 AS col2 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT - - cor0.col2 * - col1 + + col1 + - 80 * + col1 FROM tab1 AS cor0
----
-1360
-2275
-3458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) * + col0 col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + 15 + col2 FROM tab2 AS cor0
----
41
42
53

query I rowsort
SELECT + + ( - cor0.col1 ) * - col1 + + col1 + col1 FROM tab1 AS cor0
----
120
195
728

query I rowsort
SELECT DISTINCT col1 + - tab0.col0 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT 12 + - col2 FROM tab2
----
-14
-15
-26

query I rowsort
SELECT DISTINCT + col1 + - 23 + col2 AS col2 FROM tab0
----
150
75
96

query I rowsort
SELECT col0 + col0 + tab1.col1 FROM tab1
----
138
173
32

query I rowsort
SELECT ALL - 97 + col1 AS col0 FROM tab1
----
-71
-84
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-8837
SELECT + 12 * + col2 + + col1 DIV col0 AS col1 FROM tab0
----
14
399
985

skipif mysql # not compatible
query I rowsort label-8837
SELECT + 12 * + col2 + + col1 / col0 AS col1 FROM tab0
----
14
399
985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8839
SELECT + CAST( 56 AS SIGNED ) * - col2 FROM tab1
----
-3024
-3192
-5376

skipif mysql # not compatible
query I rowsort label-8839
SELECT + CAST ( 56 AS INTEGER ) * - col2 FROM tab1
----
-3024
-3192
-5376

query I rowsort
SELECT DISTINCT - col2 + col0 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT - - col2 + ( + 96 ) FROM tab0 AS cor0
----
129
178
97

query I rowsort
SELECT DISTINCT - col2 * + cor0.col0 + cor0.col2 * col1 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT - + col2 + + 73 * - col2 AS col1 FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT ALL + + col2 * - ( + col0 ) + + col2 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL + + col0 * ( col1 * + col0 ) FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT + cor0.col2 + + 93 * + col2 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT DISTINCT - col0 + + 69 * ( - col2 ) AS col0 FROM tab0 AS cor0
----
-104
-2301
-5747

query I rowsort
SELECT ALL col2 * col1 + + col1 * - col1 AS col0 FROM tab2
----
-124
-1947
357

query I rowsort
SELECT - ( + 37 ) * col2 FROM tab2 AS cor0
----
-1406
-962
-999

query I rowsort
SELECT DISTINCT col2 * col1 - - col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL - + cor0.col0 + + cor0.col1 AS col0 FROM tab2 cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-8852
SELECT + - col2 DIV - col2 + 2 AS col2 FROM tab0 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-8852
SELECT + - col2 / - col2 + 2 AS col2 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT DISTINCT - col2 + col2 * - col1 * col2 FROM tab2 AS cor0
----
-22626
-24586
-39910

query I rowsort
SELECT DISTINCT + col2 + 22 AS col0 FROM tab1
----
118
76
79

query I rowsort
SELECT col1 * - 79 AS col2 FROM tab2 AS cor0
----
-1343
-2449
-4661

query I rowsort
SELECT + 25 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT + col0 * - col0 + + col2 AS col1 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + col0 * - ( col1 ) FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + 85 * col2 AS col2 FROM tab1
----
4590
4845
8160

query I rowsort
SELECT + cor0.col2 + 53 AS col0 FROM tab1 AS cor0
----
107
110
149

onlyif mysql # use DIV operator for integer division
query I rowsort label-8861
SELECT + col0 + - col0 DIV cor0.col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-8861
SELECT + col0 + - col0 / cor0.col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT - 79 + col2 AS col1 FROM tab2 AS cor0
----
-41
-52
-53

query I rowsort
SELECT col1 * + col0 * + col2 AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + - col2 * - ( col0 ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + 72 * - col2 + - col2 AS col0 FROM tab2 AS cor0
----
-1898
-1971
-2774

query I rowsort
SELECT ( 82 ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT ALL + 2 * - col2 + + ( - col0 ) * + col0 + 43 * col0 AS col2 FROM tab2 AS cor0
----
-2782
-2920
198

query I rowsort
SELECT DISTINCT + col2 * col2 + col0 * col0 FROM tab1 AS cor0
----
15616
2925
7345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 + + col1 col0 FROM tab0 AS cor0
----
177
182
188

onlyif mysql # use DIV operator for integer division
query I rowsort label-8870
SELECT ALL - col2 * col1 DIV + 78 AS col0 FROM tab0 AS cor0
----
-1
-36
-95

skipif mysql # not compatible
query I rowsort label-8870
SELECT ALL - col2 * col1 / + 78 AS col0 FROM tab0 AS cor0
----
-1
-36
-95

query I rowsort
SELECT ALL - col1 + + 93 * + col0 FROM tab1 AS cor0
----
253
5942
7427

query IIIIIIIII rowsort
SELECT * FROM tab0, tab1, tab1 AS cor0 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT col0 + 77 AS col0 FROM tab1 AS cor0
----
141
157
80

query I rowsort
SELECT ALL 75 + col2 AS col1 FROM tab0 AS cor0
----
108
157
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8875
SELECT DISTINCT - col1 + col1 DIV col0 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-8875
SELECT DISTINCT - col1 + col1 / col0 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT ALL col2 * col1 * col1 AS col1 FROM tab0 cor0
----
244068
679042
9409

query I rowsort
SELECT col0 + - col0 * + cor0.col0 * col1 FROM tab2 cor0
----
-106018
-1512
-358878

query I rowsort
SELECT ALL + + ( col0 ) * - ( col2 ) - + col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT + col0 + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT + + col1 * col0 + - ( cor0.col1 ) AS col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT - col0 + + col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT ALL + 96 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 48 - col2 col2 FROM tab0
----
-130
-49
-81

query I rowsort
SELECT col2 + 86 * - col1 - + 69 FROM tab2
----
-1493
-2708
-5117

query I rowsort
SELECT DISTINCT 9 AS col0 FROM tab1, tab0 AS cor0
----
9

query I rowsort
SELECT + ( 72 ) * - col0 FROM tab2
----
-504
-5616
-5688

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 * - col1 col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT ALL + ( + col1 ) + tab0.col0 FROM tab0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8889
SELECT col0 * - col0 * + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8889
SELECT col0 * - col0 * + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8890
SELECT DISTINCT + ( col2 ) DIV 69 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-8890
SELECT DISTINCT + ( col2 ) / 69 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL - - 11 * col0 FROM tab0 cor0
----
264
385
979

query I rowsort
SELECT - col1 * + 8 AS col1 FROM tab1
----
-104
-208
-80

query I rowsort
SELECT DISTINCT + col1 - + 70 AS col0 FROM tab1
----
-44
-57
-60

query I rowsort
SELECT - - col2 * + 29 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT - col1 + 39 + 15 FROM tab2 AS cor0
----
-5
23
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + cor0.col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + col0 * + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT - ( col2 ) * + col0 + + 21 AS col2 FROM tab0 AS cor0
----
-14
-7277
-771

query I rowsort
SELECT + col1 - col0 * col2 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-8900
SELECT DISTINCT - + cor0.col2 DIV ( col1 ) AS col0 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-8900
SELECT DISTINCT - + cor0.col2 / ( col1 ) AS col0 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT ALL - 30 + tab2.col0 FROM tab2
----
-23
48
49

query I rowsort
SELECT + 50 + 16 + col2 * - tab1.col1 FROM tab1
----
-1182
-1338
-504

query I rowsort
SELECT ALL + 19 * col0 AS col2 FROM tab0 cor0
----
1691
456
665

onlyif mysql # use DIV operator for integer division
query I rowsort label-8904
SELECT + + 72 DIV - cor0.col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-8904
SELECT + + 72 / - cor0.col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT DISTINCT + - col0 * 15 + col2 * - col2 * + cor0.col2 FROM tab1 AS cor0
----
-157509
-186153
-885936

query I rowsort
SELECT + col2 * 50 + cor0.col1 FROM tab2 AS cor0
----
1359
1381
1917

query I rowsort
SELECT - col0 - col0 * + col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL - - 40 * 91 + col1 + 69 FROM tab2 cor0
----
3726
3740
3768

query I rowsort
SELECT ALL - ( col1 ) + + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 9 * - col2 + - col2 AS col2 FROM tab0 AS cor0
----
-10
-330
-820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 53 * 34 + - col0 * - 25 col1 FROM tab2 AS cor0
----
1977
3752
3777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 23 * ( + cor0.col2 ) col0 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT DISTINCT + ( + 64 ) AS col0 FROM tab2 AS cor0
----
64

query I rowsort
SELECT + - ( col0 ) + - col0 - + cor0.col2 AS col1 FROM tab1 AS cor0
----
-185
-256
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 17 - + col0 col1 FROM tab0 AS cor0
----
-18
-7
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-8916
SELECT ALL 72 DIV cor0.col0 + col0 FROM tab1 AS cor0
----
27
65
80

skipif mysql # not compatible
query I rowsort label-8916
SELECT ALL 72 / cor0.col0 + col0 FROM tab1 AS cor0
----
27
65
80

query I rowsort
SELECT DISTINCT - cor0.col2 + 52 + col0 FROM tab1 AS cor0
----
1
36
59

query I rowsort
SELECT + + col0 - 86 * col2 FROM tab1 AS cor0
----
-4641
-4838
-8176

query I rowsort
SELECT DISTINCT col1 + col2 * - cor0.col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * cor0.col0 - col1 col2 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT + 21 * col0 FROM tab2 AS cor0
----
147
1638
1659

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8922
SELECT - col0 / col0 + + CAST( NULL AS SIGNED ) * + ( col0 * + 6 ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8922
SELECT - col0 / col0 + + CAST ( NULL AS INTEGER ) * + ( col0 * + 6 ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 + cor0.col0 AS col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT + + 88 * col0 FROM tab2 AS cor0
----
616
6864
6952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * + col2 + ( + 43 ) col1 FROM tab1 AS cor0
----
-119
-3605
-7637

query I rowsort
SELECT DISTINCT col1 - + 51 AS col2 FROM tab0
----
35
40
46

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) FROM tab2, tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - col0 * col2 + + col1 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-8929
SELECT col0 DIV 48 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8929
SELECT col0 / 48 AS col2 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8930
SELECT DISTINCT col0 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8930
SELECT DISTINCT col0 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8931
SELECT tab1.col2 DIV 31 FROM tab1, tab2 AS cor0
----
9 values hashing to 14abe0a65ffde3428a361c66e935c2aa

skipif mysql # not compatible
query I rowsort label-8931
SELECT tab1.col2 / 31 FROM tab1, tab2 AS cor0
----
9 values hashing to 14abe0a65ffde3428a361c66e935c2aa

query I rowsort
SELECT ALL + + col0 + + col0 * - col0 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1155
-528
-7743

query I rowsort
SELECT ALL col0 * col1 + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8935
SELECT ALL + col2 + CAST( - 65 + - col2 * + col1 AS SIGNED ) FROM tab0 AS cor0
----
-161
-2870
-7445

skipif mysql # not compatible
query I rowsort label-8935
SELECT ALL + col2 + CAST ( - 65 + - col2 * + col1 AS INTEGER ) FROM tab0 AS cor0
----
-161
-2870
-7445

onlyif mysql # use DIV operator for integer division
query I rowsort label-8936
SELECT ( - 94 ) DIV col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-31

skipif mysql # not compatible
query I rowsort label-8936
SELECT ( - 94 ) / col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-31

query I rowsort
SELECT DISTINCT + ( + col0 ) * - col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col1 * + 72 FROM tab2 cor0
----
-1224
-2232
-4248

query I rowsort
SELECT tab1.col2 * + tab1.col1 + - col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT 64 FROM tab1, tab2 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT 81 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 0 * - col2 * col2 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - - 17 AS col1 FROM tab0 AS cor0
----
17
17
17

query I rowsort
SELECT ALL + col1 * + col0 * - cor0.col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8945
SELECT DISTINCT col2 - CAST( 70 + + col0 AS SIGNED ) * col0 AS col2 FROM tab2 AS cor0
----
-11518
-11733
-512

skipif mysql # not compatible
query I rowsort label-8945
SELECT DISTINCT col2 - CAST ( 70 + + col0 AS INTEGER ) * col0 AS col2 FROM tab2 AS cor0
----
-11518
-11733
-512

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 + - 44 - - col2 * cor0.col0 FROM tab2 AS cor0
----
-584
1308
1514

query I rowsort
SELECT DISTINCT - + col1 * - ( + 67 ) - - cor0.col1 AS col2 FROM tab0 AS cor0
----
5848
6188
6596

query I rowsort
SELECT - col2 * - 72 - col2 * cor0.col0 FROM tab1 cor0
----
-768
3726
456

query I rowsort
SELECT - 1 + - ( tab2.col2 ) FROM tab2
----
-27
-28
-39

query I rowsort
SELECT ALL + tab1.col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 91 + + 27 AS col2 FROM tab2
----
-64
-64
-64

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col0 AS REAL ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT col2 + + 60 FROM tab1 AS cor0
----
114
117
156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 60 * 65 col0 FROM tab1 AS cor0
----
3900
3900
3900

query I rowsort
SELECT + ( - 35 ) * cor0.col1 FROM tab1 AS cor0
----
-350
-455
-910

query I rowsort
SELECT + - 29 + col1 * col1 AS col1 FROM tab2 AS cor0
----
260
3452
932

query I rowsort
SELECT ALL - 23 - col2 * + col2 FROM tab2 AS cor0
----
-1467
-699
-752

query I rowsort
SELECT + - col1 + col0 * 48 AS col1 FROM tab0 AS cor0
----
1066
1583
4181

query I rowsort
SELECT DISTINCT + col2 + + col0 * ( - 1 * + col2 ) FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL + col1 * col2 - - 83 FROM tab0 cor0
----
180
2921
7545

onlyif mysql # use DIV operator for integer division
query I rowsort label-8961
SELECT ALL + col0 * - col0 + + col0 DIV - col2 FROM tab0 AS cor0
----
-1260
-576
-7922

skipif mysql # not compatible
query I rowsort label-8961
SELECT ALL + col0 * - col0 + + col0 / - col2 FROM tab0 AS cor0
----
-1260
-576
-7922

query I rowsort
SELECT + - col0 * col1 + col0 * + 89 AS col1 FROM tab0 AS cor0
----
-178
-280
72

query I rowsort
SELECT ALL - 42 AS col1 FROM tab2
----
-42
-42
-42

query I rowsort
SELECT - ( col2 ) * - ( + col2 ) AS col0 FROM tab1 cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 * col1 * + 74 col1 FROM tab2 AS cor0
----
100418
28934
52762

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + ( cor0.col2 ) col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col0 * 97 AS col2 FROM tab2 cor0
----
-679
-7566
-7663

query I rowsort
SELECT DISTINCT + ( + tab1.col0 ) AS col1 FROM tab1
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8970
SELECT + + CAST( NULL AS SIGNED ) * + cor0.col0 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-8970
SELECT + + CAST ( NULL AS INTEGER ) * + cor0.col0 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + 11 + col1 FROM tab1 AS cor0
----
1069
620
637

query I rowsort
SELECT - + col1 * + 38 FROM tab2 cor0
----
-1178
-2242
-646

query I rowsort
SELECT col0 * + 91 * tab0.col1 AS col2 FROM tab0
----
187824
308945
737009

query I rowsort
SELECT + col1 + 91 AS col0 FROM tab0
----
177
182
188

query I rowsort
SELECT + col1 * + col1 + - col0 * col2 AS col0 FROM tab0 AS cor0
----
6604
9374
983

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + col0 + + col2 col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT + 17 FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
243 values hashing to a14896bcbd33addb471227dccce15e32

query I rowsort
SELECT ALL + - cor0.col1 - + col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - + col1 * - 73 AS col2 FROM tab0 AS cor0
----
6278
6643
7081

query I rowsort
SELECT + 40 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8981
SELECT ALL + + col2 + - col2 + - col0 * col0 DIV cor0.col1 AS col2 FROM tab0 cor0
----
-12
-6
-87

skipif mysql # not compatible
query I rowsort label-8981
SELECT ALL + + col2 + - col2 + - col0 * col0 / cor0.col1 AS col2 FROM tab0 cor0
----
-12
-6
-87

query I rowsort
SELECT DISTINCT - - col0 + col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT + col2 + col1 * 12 AS col2 FROM tab0 AS cor0
----
1065
1165
1174

query I rowsort
SELECT + - col0 - ( + col0 + col2 * cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-203
-2184
-3160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8985
SELECT DISTINCT cor0.col0 DIV ( 92 ) - + col0 * col2 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8985
SELECT DISTINCT cor0.col0 / ( 92 ) - + col0 * col2 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + col0 * + col0 + - 32 * - col0 AS col1 FROM tab0 AS cor0
----
10769
1344
2345

query I rowsort
SELECT + col2 - ( col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + + col0 * 85 - + cor0.col2 * cor0.col0 FROM tab2 AS cor0
----
3713
406
4602

query I rowsort
SELECT ( col1 ) * col1 AS col2 FROM tab1
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8990
SELECT ALL + cor0.col0 - + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-8990
SELECT ALL + cor0.col0 - + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - 90 * + cor0.col2 FROM tab0 AS cor0
----
-2970
-7380
-90

query I rowsort
SELECT col0 * 43 * tab1.col0 FROM tab1
----
176128
275200
387

query I rowsort
SELECT ALL col2 + - ( - 20 ) AS col1 FROM tab0
----
102
21
53

query I rowsort
SELECT ALL + cor0.col2 * - col1 + - ( 2 ) AS col1 FROM tab2 AS cor0
----
-1536
-648
-839

query I rowsort
SELECT DISTINCT - col1 * + col2 - + col0 AS col1 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8996
SELECT + CAST( NULL AS SIGNED ) * + col2 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8996
SELECT + CAST ( NULL AS INTEGER ) * + col2 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( - col2 + - col0 ) AS col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT DISTINCT - 86 AS col1 FROM tab1, tab1 cor0
----
-86

query I rowsort
SELECT ALL + 32 AS col0 FROM tab1
----
32
32
32

query I rowsort
SELECT ALL - 10 * cor0.col2 + + col1 FROM tab0 cor0
----
-244
-729
87

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-9002
SELECT + + 12 DIV - cor0.col0 col1 FROM tab1 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9002
SELECT + + 12 / - cor0.col0 col1 FROM tab1 AS cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT - 95 AS col0 FROM tab1 AS cor0
----
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 83 * - col0 + col0 * + col0 col0 FROM tab1 AS cor0
----
-1216
-240
-240

onlyif mysql # use DIV operator for integer division
query I rowsort label-9005
SELECT + - col1 + - col2 DIV - col1 col1 FROM tab2 AS cor0
----
-15
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9005
SELECT + - col1 + - col2 / - col1 col1 FROM tab2 AS cor0
----
-15
-31
-59

query I rowsort
SELECT - + cor0.col2 * + col1 - col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT col2 * + tab0.col2 * - col0 + + col0 * - col2 FROM tab0
----
-26928
-605734
-70

query I rowsort
SELECT DISTINCT - + col2 * + col1 + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query IIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 WHERE NOT NULL > NULL
----

query I rowsort
SELECT + col0 + - col0 * col0 * - col1 FROM tab0 AS cor0
----
118860
49560
720900

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9012
SELECT ALL - tab1.col0 + + 6 + + col0 * - col0 DIV + tab1.col0 FROM tab1
----
-122
-154
0

skipif mysql # not compatible
query I rowsort label-9012
SELECT ALL - tab1.col0 + + 6 + + col0 * - col0 / + tab1.col0 FROM tab1
----
-122
-154
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9013
SELECT ALL 96 + 59 + col2 * col0 DIV tab0.col0 AS col0 FROM tab0
----
156
188
237

skipif mysql # not compatible
query I rowsort label-9013
SELECT ALL 96 + 59 + col2 * col0 / tab0.col0 AS col0 FROM tab0
----
156
188
237

query I rowsort
SELECT ALL + col0 + col1 * col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + col0 AS col0 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + 97 ) col1 FROM tab0 AS cor0
----
-97
-97
-97

query I rowsort
SELECT DISTINCT - - col1 + + col1 AS col2 FROM tab2 cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 + - col2 col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9019
SELECT + - col2 DIV col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9019
SELECT + - col2 / col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + ( + cor0.col0 ) * col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - ( + 85 ) AS col0 FROM tab2
----
-85

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 * + col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - col2 * - col2 * + col1 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-9024
SELECT DISTINCT - - col0 DIV cor0.col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-9024
SELECT DISTINCT - - col0 / cor0.col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT DISTINCT col1 * col2 * col2 AS col1 FROM tab1 cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-9026
SELECT DISTINCT + 98 + - tab0.col2 * col2 DIV col2 FROM tab0
----
16
65
97

skipif mysql # not compatible
query I rowsort label-9026
SELECT DISTINCT + 98 + - tab0.col2 * col2 / col2 FROM tab0
----
16
65
97

query I rowsort
SELECT ( 16 ) * col1 - + tab2.col1 AS col0 FROM tab2
----
255
465
885

query I rowsort
SELECT + ( 82 ) * col1 + + col0 AS col0 FROM tab2
----
1473
2549
4916

query I rowsort
SELECT 86 + 30 FROM tab1
----
116
116
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col2 FROM tab2, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT + ( + 36 ) * col1 FROM tab2
----
1116
2124
612

query I rowsort
SELECT tab2.col0 - 92 AS col2 FROM tab2
----
-13
-14
-85

query I rowsort
SELECT + col1 - col1 * - tab1.col2 AS col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ( 89 ) FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT ALL + col1 + 31 AS col0 FROM tab1 AS cor0
----
41
44
57

query I rowsort
SELECT - col2 + + col2 AS col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9037
SELECT DISTINCT col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9037
SELECT DISTINCT col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT + col1 + + 36 FROM tab0
----
122
127
133

query I rowsort
SELECT ALL 90 AS col2 FROM tab0
----
90
90
90

query I rowsort
SELECT ( + ( tab1.col1 ) ) AS col0 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) + + tab2.col1 col0 FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col0 AS REAL ) + cor0.col2 * ( col2 ) AS col1 FROM tab0 cor0
----
1113
36
6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9044
SELECT CAST( col2 AS SIGNED ) AS col1 FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-9044
SELECT CAST ( col2 AS INTEGER ) AS col1 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL + col2 + 64 FROM tab1 AS cor0
----
118
121
160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col0 + + 82 col2 FROM tab0
----
-1982
-3313
-8017

query I rowsort
SELECT ALL - tab1.col0 AS col1 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT + tab0.col0 - col2 AS col0 FROM tab0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 51 + tab1.col1 col2 FROM tab1, tab2, tab0 AS cor0
----
61
64
77

query I rowsort
SELECT ALL + col0 * col0 + - col0 AS col2 FROM tab1
----
4032
6
6320

query I rowsort
SELECT ( - col1 ) + - ( + col0 ) AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT 1 FROM tab2, tab1, tab1 cor0
----
1

query I rowsort
SELECT DISTINCT + + col0 + col0 - col2 AS col2 FROM tab2 AS cor0
----
-13
120
130

query I rowsort
SELECT ALL + col0 - 0 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + + col2 * + 13 AS col2 FROM tab2 AS cor0
----
338
351
494

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 * + col2 AS col1 FROM tab0 cor0
----
-96
1003
6633

query I rowsort
SELECT ALL + col1 * - col0 * + 68 FROM tab2 AS cor0
----
-14756
-312936
-91324

onlyif mysql # use DIV operator for integer division
query I rowsort label-9058
SELECT DISTINCT + col1 DIV ( - 66 ) + col0 AS col0 FROM tab0 cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-9058
SELECT DISTINCT + col1 / ( - 66 ) + col0 AS col0 FROM tab0 cor0
----
23
34
88

query I rowsort
SELECT - - col0 * col0 AS col2 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT + col2 + ( - cor0.col2 + + col1 ) * + col2 * 1 FROM tab2 AS cor0
----
-760
135
884

query I rowsort
SELECT ALL col2 * 7 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT + col0 * ( col1 ) + col2 AS col2 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT - col1 * - 76 AS col2 FROM tab2 AS cor0
----
1292
2356
4484

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + col0 + CAST ( + col2 AS REAL ) * cor0.col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - col2 * ( + col2 ) AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - cor0.col2 * + 62 FROM tab2 AS cor0
----
-1612
-1674
-2356

query I rowsort
SELECT DISTINCT - col0 * ( 90 ) FROM tab2
----
-630
-7020
-7110

query I rowsort
SELECT + cor0.col2 + + 72 AS col2 FROM tab1 cor0
----
126
129
168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9069
SELECT CAST( NULL AS DECIMAL ) * col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9069
SELECT CAST ( NULL AS REAL ) * col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 * col0 * + cor0.col2 FROM tab2 cor0
----
-1323
-158184
-237158

query I rowsort
SELECT 2 * + 8 * col2 FROM tab2 cor0
----
416
432
608

query I rowsort
SELECT - + cor0.col1 * + col1 - - col1 AS col2 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - - col1 * + col0 + - col1 * cor0.col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + - col0 * - col1 * + col1 AS col2 FROM tab1 AS cor0
----
13533
2054
6410

query I rowsort
SELECT + col0 + col2 * col0 * col0 AS col0 FROM tab0 AS cor0
----
1260
19032
649611

query I rowsort
SELECT 87 - - col1 AS col2 FROM tab1 AS cor0
----
100
113
97

query I rowsort
SELECT DISTINCT - cor0.col2 + + col0 * - 39 FROM tab0 AS cor0
----
-1366
-3553
-969

query I rowsort
SELECT + + 62 + - col1 AS col2 FROM tab0 AS cor0
----
-24
-29
-35

query I rowsort
SELECT DISTINCT 0 FROM tab1, tab1 AS cor0
----
0

query I rowsort
SELECT ALL 84 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9081
SELECT + + col0 * - CAST( NULL AS SIGNED ) 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-9081
SELECT + + col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + + 18 FROM tab2 AS cor0
----
-60
-61
11

query I rowsort
SELECT - 85 * tab1.col2 * ( + 95 ) FROM tab1
----
-436050
-460275
-775200

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab0, tab2, tab1 cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT 44 * col1 AS col2 FROM tab1 AS cor0
----
1144
440
572

query I rowsort
SELECT - - cor0.col1 + col1 * - ( + col2 + + col1 * ( - col1 ) ) AS col2 FROM tab2 AS cor0
----
203904
28985
4284

query I rowsort
SELECT ALL + 24 + col0 * cor0.col1 * col2 FROM tab2 cor0
----
119676
51058
5883

onlyif mysql # use DIV operator for integer division
query I rowsort label-9088
SELECT + 29 DIV + col2 col1 FROM tab0 AS cor0
----
0
0
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9088
SELECT + 29 / + col2 col1 FROM tab0 AS cor0
----
0
0
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-9089
SELECT DISTINCT - col0 + + col0 DIV + cor0.col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-9089
SELECT DISTINCT - col0 + + col0 / + cor0.col0 FROM tab2 AS cor0
----
-6
-77
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9090
SELECT - ( col0 ) * ( col1 ) DIV + col0 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9090
SELECT - ( col0 ) * ( col1 ) / + col0 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + - cor0.col0 * - 99 - - col2 AS col0 FROM tab0 AS cor0
----
2409
3466
8893

query I rowsort
SELECT ALL - col1 * - col1 * - col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT - col2 + + ( + 68 + + col2 ) * 69 AS col1 FROM tab0 AS cor0
----
10268
4760
6936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9094
SELECT cor0.col2 + + CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-9094
SELECT cor0.col2 + + CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - col2 + - col2 - - 51 * col0 AS col0 FROM tab2 AS cor0
----
303
3926
3953

onlyif mysql # use DIV operator for integer division
query I rowsort label-9096
SELECT DISTINCT - col1 DIV - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9096
SELECT DISTINCT - col1 / - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT col2 + + col1 * - 12 AS col2 FROM tab0 AS cor0
----
-1010
-1163
-999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9098
SELECT DISTINCT col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9098
SELECT DISTINCT col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col2 - - ( col1 ) * col2 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT + col1 + 94 AS col1 FROM tab0 AS cor0
----
180
185
191

query I rowsort
SELECT ALL col1 * - col1 * + col1 - + col1 AS col1 FROM tab1 AS cor0
----
-1010
-17602
-2210

query I rowsort
SELECT + col2 * + col2 * - cor0.col1 + col1 FROM tab0 AS cor0
----
-611793
-93568
0

query I rowsort
SELECT DISTINCT cor0.col2 * 45 + 19 * - col2 * 8 FROM tab2 AS cor0
----
-2782
-2889
-4066

query I rowsort
SELECT DISTINCT - - col0 * - 66 * col1 AS col0 FROM tab0 AS cor0
----
-136224
-224070
-534534

onlyif mysql # use DIV operator for integer division
query I rowsort label-9105
SELECT cor0.col1 * ( + 33 ) DIV - col2 - - ( + col1 ) * - col2 FROM tab0 AS cor0
----
-2924
-3298
-7498

skipif mysql # not compatible
query I rowsort label-9105
SELECT cor0.col1 * ( + 33 ) / - col2 - - ( + col1 ) * - col2 FROM tab0 AS cor0
----
-2924
-3298
-7498

onlyif mysql # use DIV operator for integer division
query I rowsort label-9106
SELECT - 79 DIV - col1 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-9106
SELECT - 79 / - col1 FROM tab2
----
1
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 25 * - col1 col1 FROM tab1 cor0
----
-250
-325
-650

query I rowsort
SELECT - 60 + - col2 + col0 AS col0 FROM tab1 cor0
----
-111
-53
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 69 + - 54 * - col1 col2 FROM tab2 AS cor0
----
1605
3117
849

onlyif mysql # use DIV operator for integer division
query I rowsort label-9110
SELECT + col2 DIV 75 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9110
SELECT + col2 / 75 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9111
SELECT DISTINCT - - CAST( 25 AS SIGNED ) * cor0.col0 * - col1 + cor0.col1 col2 FROM tab1 AS cor0
----
-15990
-1924
-25987

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9111
SELECT DISTINCT - - CAST ( 25 AS INTEGER ) * cor0.col0 * - col1 + cor0.col1 col2 FROM tab1 AS cor0
----
-15990
-1924
-25987

query I rowsort
SELECT DISTINCT - - ( cor0.col2 ) * - cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT col1 * - 61 FROM tab2 AS cor0
----
-1037
-1891
-3599

query I rowsort
SELECT - + col2 * + col1 + - col1 AS col0 FROM tab1 cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - 91 + - col1 AS col0 FROM tab1 AS cor0
----
-101
-104
-117

onlyif mysql # use DIV operator for integer division
query I rowsort label-9116
SELECT ALL - col0 DIV 67 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9116
SELECT ALL - col0 / 67 FROM tab1
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 56 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ALL - ( col1 ) + - cor0.col1 FROM tab2 cor0
----
-118
-34
-62

query I rowsort
SELECT - 26 * col2 FROM tab2 AS cor0
----
-676
-702
-988

query I rowsort
SELECT ALL - 37 * 75 FROM tab2
----
-2775
-2775
-2775

onlyif mysql # use DIV operator for integer division
query I rowsort label-9121
SELECT DISTINCT + cor0.col1 DIV col2 + - 74 DIV 57 AS col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9121
SELECT DISTINCT + cor0.col1 / col2 + - 74 / 57 AS col2 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT ALL - 0 * - col0 + + 67 FROM tab1 AS cor0
----
67
67
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + col2 * + 47 col0 FROM tab1 AS cor0
----
2541
2743
4592

query I rowsort
SELECT + + 86 FROM tab1 AS cor0
----
86
86
86

query I rowsort
SELECT ALL + cor0.col0 * col1 * col1 + - col0 AS col2 FROM tab2 AS cor0
----
22752
271440
6720

query I rowsort
SELECT ALL + col0 * col0 + + col2 AS col2 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT - - 2 AS col0 FROM tab0 AS cor0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 - col2 col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - + cor0.col2 * - cor0.col1 + - 47 FROM tab1 AS cor0
----
1201
1357
523

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 78 col1 FROM tab0
----
111
160
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 * + col0 + col0 col0 FROM tab1
----
1200
45
960

query I rowsort
SELECT ( + 30 ) - - tab2.col0 FROM tab2
----
108
109
37

query I rowsort
SELECT 13 + col0 * + col2 FROM tab0
----
48
7311
805

query I rowsort
SELECT ALL + ( col0 ) + col2 * - ( col2 ) AS col2 FROM tab2
----
-1365
-598
-722

onlyif mysql # use DIV operator for integer division
query I rowsort label-9135
SELECT DISTINCT col2 DIV - col1 + - col1 AS col0 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9135
SELECT DISTINCT col2 / - col1 + - col1 AS col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - - ( col2 ) + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + cor0.col2 * + col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - + 20 AS col1 FROM tab1 AS cor0
----
-20
-20
-20

query I rowsort
SELECT DISTINCT - 54 + + col0 * col1 + + col2 FROM tab1 AS cor0
----
1082
643
78

query I rowsort
SELECT DISTINCT + + ( - col1 ) * ( - cor0.col0 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - col2 * - col0 + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + col0 - + col2 * col2 FROM tab1
----
-2913
-3185
-9136

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2, tab0 cor3
----
3645 values hashing to 750b3c1b743e18f68d402d034647fcf2

query I rowsort
SELECT col1 + tab1.col2 * + col1 AS col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT + + col0 * + col1 + - col0 AS col0 FROM tab2 AS cor0
----
1264
210
4524

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to 58b53d9f2c5d79e6fe94b4a97272440e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9147
SELECT ALL + CAST( NULL AS SIGNED ) + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9147
SELECT ALL + CAST ( NULL AS INTEGER ) + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 27 col0 FROM tab0 cor0
----
27

query I rowsort
SELECT + col2 + 96 * + col0 AS col1 FROM tab2
----
699
7514
7622

query I rowsort
SELECT 92 + col0 * + col1 FROM tab1
----
1132
170
732

query I rowsort
SELECT ALL ( + cor0.col0 ) + cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - 98 AS col2 FROM tab0 cor0
----
-98

query I rowsort
SELECT - col0 * col1 * + col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT + col2 * - 92 AS col0 FROM tab2 cor0
----
-2392
-2484
-3496

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( 10 AS REAL ) * + col1 FROM tab0 AS cor0
----
860
910
970

query I rowsort
SELECT - 75 AS col1 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT ALL - 59 + col1 AS col0 FROM tab1 AS cor0
----
-33
-46
-49

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

query I rowsort
SELECT ALL - col0 * 13 * col1 FROM tab0 AS cor0
----
-105287
-26832
-44135

onlyif mysql # use DIV operator for integer division
query I rowsort label-9160
SELECT DISTINCT - + col1 DIV col0 - col2 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-9160
SELECT DISTINCT - + col1 / col0 - col2 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT + col0 * col2 + cor0.col0 + - cor0.col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - - cor0.col0 AS col1 FROM tab2 cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9163
SELECT ALL + CAST( NULL AS SIGNED ) * - tab1.col0 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9163
SELECT ALL + CAST ( NULL AS INTEGER ) * - tab1.col0 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9164
SELECT - - col1 + + CAST( - 60 AS SIGNED ) FROM tab0 AS cor0
----
26
31
37

skipif mysql # not compatible
query I rowsort label-9164
SELECT - - col1 + + CAST ( - 60 AS INTEGER ) FROM tab0 AS cor0
----
26
31
37

query I rowsort
SELECT col2 * col0 * col1 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9166
SELECT - cor0.col0 * CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9166
SELECT - cor0.col0 * CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor2.col2 col2 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL 25 - cor0.col2 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to c654a583c37c3d0f07d367107926c658

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9169
SELECT - tab1.col0 * CAST( 87 + - col0 AS SIGNED ) * - 76 FROM tab1
----
111872
19152
42560

skipif mysql # not compatible
query I rowsort label-9169
SELECT - tab1.col0 * CAST ( 87 + - col0 AS INTEGER ) * - 76 FROM tab1
----
111872
19152
42560

query I rowsort
SELECT DISTINCT 34 AS col0 FROM tab0, tab1 AS cor0
----
34

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 39615739daa2056ffb6e430a8ff0bfc8

query I rowsort
SELECT DISTINCT - ( 61 ) AS col1 FROM tab1, tab2 cor0
----
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-9173
SELECT DISTINCT + col2 DIV + ( col2 ) AS col1 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-9173
SELECT DISTINCT + col2 / + ( col2 ) AS col1 FROM tab1
----
1

query I rowsort
SELECT + 45 - + col0 AS col2 FROM tab2 AS cor0
----
-33
-34
38

query I rowsort
SELECT + col2 + + col2 * 44 FROM tab2 cor0
----
1170
1215
1710

onlyif mysql # use DIV operator for integer division
query I rowsort label-9176
SELECT DISTINCT + - col1 DIV col0 + ( 85 ) * + col0 FROM tab0 AS cor0
----
2037
2973
7564

skipif mysql # not compatible
query I rowsort label-9176
SELECT DISTINCT + - col1 / col0 + ( 85 ) * + col0 FROM tab0 AS cor0
----
2037
2973
7564

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9177
SELECT DISTINCT - - col2 * + cor0.col0 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9177
SELECT DISTINCT - - col2 * + cor0.col0 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - - ( - col0 ) * - col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 21 - cor0.col0 col1 FROM tab1 AS cor0
----
-43
-59
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9180
SELECT tab0.col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9180
SELECT tab0.col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - + col2 + + col2 * - ( - col2 + ( + col0 ) ) FROM tab1 AS cor0
----
-456
1440
2700

query I rowsort
SELECT + col1 + col1 + - col1 FROM tab1
----
10
13
26

query I rowsort
SELECT - col1 * - col1 * col2 + tab2.col0 AS col0 FROM tab2
----
11061
25954
90584

onlyif mysql # use DIV operator for integer division
query I rowsort label-9184
SELECT DISTINCT col2 DIV col2 + + col1 DIV col1 + - col1 FROM tab0
----
-84
-89
-95

skipif mysql # not compatible
query I rowsort label-9184
SELECT DISTINCT col2 / col2 + + col1 / col1 + - col1 FROM tab0
----
-84
-89
-95

query I rowsort
SELECT ALL - col0 * col1 + cor0.col1 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - 18 - + cor0.col0 * col1 FROM tab1 AS cor0
----
-1058
-658
-96

query I rowsort
SELECT ALL + 3 AS col1 FROM tab2
----
3
3
3

query I rowsort
SELECT + - 69 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT DISTINCT - 64 AS col2 FROM tab1, tab0 AS cor0, tab2 cor1
----
-64

query I rowsort
SELECT DISTINCT - col2 * - col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-9191
SELECT DISTINCT - col0 + col2 DIV + ( - col2 ) FROM tab0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-9191
SELECT DISTINCT - col0 + col2 / + ( - col2 ) FROM tab0
----
-25
-36
-90

query I rowsort
SELECT - + 79 FROM tab2, tab2 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT DISTINCT + col0 + ( col1 ) * col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT 15 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9195
SELECT + col2 DIV cor0.col1 + col1 AS col0 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-9195
SELECT + col2 / cor0.col1 + col1 AS col0 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT + col2 + - ( ( - col2 ) ) * + 4 FROM tab2 AS cor0
----
130
135
190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9197
SELECT + CAST( - col2 AS SIGNED ) AS col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9197
SELECT + CAST ( - col2 AS INTEGER ) AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - col2 * 80 AS col1 FROM tab2
----
-2080
-2160
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-9199
SELECT + 33 * - col0 + col2 DIV 2 FROM tab2
----
-218
-2561
-2588

skipif mysql # not compatible
query I rowsort label-9199
SELECT + 33 * - col0 + col2 / 2 FROM tab2
----
-218
-2561
-2588

query I rowsort
SELECT ( tab2.col0 ) AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT + 75 * tab2.col0 FROM tab2
----
525
5850
5925

onlyif mysql # use DIV operator for integer division
query I rowsort label-9202
SELECT col2 DIV 73 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9202
SELECT col2 / 73 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * 72 FROM tab2 AS cor0
----
-1872
-1944
-2736

query I rowsort
SELECT DISTINCT + 34 * col1 FROM tab1 AS cor0
----
340
442
884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * ( - col0 ) col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 col0 FROM tab1 cor0
----
16
16
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 40 * col1 - + 45 col2 FROM tab0 AS cor0
----
-3485
-3685
-3925

query I rowsort
SELECT col2 * + col2 * 40 AS col1 FROM tab1
----
116640
129960
368640

query I rowsort
SELECT + col1 + - cor0.col0 * - col1 AS col2 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT - col0 - col1 * col2 FROM tab2 AS cor0
----
-1612
-725
-844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 80 col1 FROM tab2 AS cor0
----
80
80
80

query I rowsort
SELECT DISTINCT - 83 FROM tab1, tab1 cor0, tab0 AS cor1
----
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col1 - + col1 col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) + + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + cor0.col0 * 24 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT + cor0.col1 + - col1 * col1 AS col0 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL ( - col0 ) * col0 * - 55 FROM tab2 cor0
----
2695
334620
343255

query I rowsort
SELECT ALL + col1 * 50 AS col1 FROM tab0 AS cor0
----
4300
4550
4850

query I rowsort
SELECT ALL ( + col1 ) * cor0.col0 - 64 AS col0 FROM tab0 cor0
----
2000
3331
8035

query I rowsort
SELECT + col2 + - 17 FROM tab0 AS cor0
----
-16
16
65

query I rowsort
SELECT ALL - - ( col2 ) + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + 58 + col2 FROM tab2 AS cor0
----
84
85
96

query I rowsort
SELECT - col1 * - col2 * col0 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 61 * + col2 col1 FROM tab0 AS cor0
----
2013
5002
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-9225
SELECT - + col1 DIV col1 + + col2 + col2 FROM tab2 AS cor0
----
51
53
75

skipif mysql # not compatible
query I rowsort label-9225
SELECT - + col1 / col1 + + col2 + col2 FROM tab2 AS cor0
----
51
53
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9226
SELECT + 45 * col2 - CAST( col0 AS SIGNED ) * col1 FROM tab2 AS cor0
----
-3432
367
998

skipif mysql # not compatible
query I rowsort label-9226
SELECT + 45 * col2 - CAST ( col0 AS INTEGER ) * col1 FROM tab2 AS cor0
----
-3432
367
998

query I rowsort
SELECT 3 AS col2 FROM tab1 cor0
----
3
3
3

query I rowsort
SELECT DISTINCT + - col0 * - cor0.col0 + 75 FROM tab1 AS cor0
----
4171
6475
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * cor0.col1 + - 48 col2 FROM tab1 AS cor0
----
-1296
-1452
-618

onlyif mysql # use DIV operator for integer division
query I rowsort label-9230
SELECT + + 50 * col0 DIV + 58 FROM tab1 cor0
----
2
55
68

skipif mysql # not compatible
query I rowsort label-9230
SELECT + + 50 * col0 / + 58 FROM tab1 cor0
----
2
55
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-9231
SELECT + col0 + - col1 DIV - 73 + 66 * col0 FROM tab2 AS cor0
----
469
5226
5293

skipif mysql # not compatible
query I rowsort label-9231
SELECT + col0 + - col1 / - 73 + 66 * col0 FROM tab2 AS cor0
----
469
5226
5293

onlyif mysql # use DIV operator for integer division
query I rowsort label-9232
SELECT + cor0.col0 DIV col0 AS col1 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9232
SELECT + cor0.col0 / col0 AS col1 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - - col1 * ( col1 + col0 ) AS col0 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT + cor0.col2 + - 14 FROM tab2 cor0
----
12
13
24

query I rowsort
SELECT ALL + ( - col1 ) * + col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + cor1.col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9237
SELECT + 38 * - col2 * CAST( NULL AS DECIMAL ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9237
SELECT + 38 * - col2 * CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0, tab1, tab2 AS cor1
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

query I rowsort
SELECT DISTINCT + - cor0.col1 * ( + col0 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + + col2 + 78 FROM tab0 AS cor0
----
111
160
79

query I rowsort
SELECT DISTINCT + + col0 + 64 + - col1 FROM tab2 cor0
----
126
40
83

query I rowsort
SELECT col0 * col0 + col1 AS col1 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT + col0 + ( cor0.col1 * - col1 ) AS col2 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT col0 + + 43 + - col2 * col1 FROM tab2 AS cor0
----
-1413
-524
-787

query I rowsort
SELECT - col0 * col0 * - col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 * col1 AS col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT col0 + 67 + + col1 * + col2 FROM tab0 AS cor0
----
199
2929
7618

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - ( 46 ) col0 FROM tab1 AS cor0
----
-138
-2944
-3680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9249
SELECT ALL - + col2 * CAST( col2 AS SIGNED ) DIV col2 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-9249
SELECT ALL - + col2 * CAST ( col2 AS INTEGER ) / col2 col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col0 * + 84 AS col2 FROM tab1 AS cor0
----
252
5376
6720

query I rowsort
SELECT col1 - - col0 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL cor0.col2 * - col2 + + col0 AS col0 FROM tab2 cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL - col2 + 93 AS col0 FROM tab1 AS cor0
----
-3
36
39

query I rowsort
SELECT ALL - col2 * 45 + - col2 FROM tab0 AS cor0
----
-1518
-3772
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-9255
SELECT ALL col2 DIV + col0 + - col1 + + col0 FROM tab1 AS cor0
----
-5
54
68

skipif mysql # not compatible
query I rowsort label-9255
SELECT ALL col2 / + col0 + - col1 + + col0 FROM tab1 AS cor0
----
-5
54
68

query I rowsort
SELECT DISTINCT 44 AS col1 FROM tab1, tab0 cor0
----
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9257
SELECT ALL + col1 + - CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9257
SELECT ALL + col1 + - CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + ( col1 ) ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT col0 * 63 * 8 AS col1 FROM tab2
----
3528
39312
39816

query I rowsort
SELECT DISTINCT - - 88 + col0 AS col1 FROM tab0 cor0
----
112
123
177

query I rowsort
SELECT + cor1.col1 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9262
SELECT ALL - + 17 + + col1 * - ( 37 * - col2 + CAST( NULL AS SIGNED ) ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9262
SELECT ALL - + 17 + + col1 * - ( 37 * - col2 + CAST ( NULL AS INTEGER ) ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + col0 * + 31 AS col1 FROM tab2 AS cor0
----
190
2392
2411

query I rowsort
SELECT DISTINCT + 54 + - cor0.col2 FROM tab1 AS cor0
----
-3
-42
0

query I rowsort
SELECT + + 5 * - col1 AS col2 FROM tab0 AS cor0
----
-430
-455
-485

onlyif mysql # use DIV operator for integer division
query I rowsort label-9266
SELECT col1 DIV - col2 - + col1 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9266
SELECT col1 / - col2 - + col1 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9267
SELECT col2 * - tab1.col0 DIV col0 - - col0 FROM tab1
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-9267
SELECT col2 * - tab1.col0 / col0 - - col0 FROM tab1
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9268
SELECT CAST( - 93 AS SIGNED ) FROM tab1
----
-93
-93
-93

skipif mysql # not compatible
query I rowsort label-9268
SELECT CAST ( - 93 AS INTEGER ) FROM tab1
----
-93
-93
-93

query I rowsort
SELECT ALL + col2 * col2 * col1 + + col0 FROM tab1
----
119888
32554
75819

query I rowsort
SELECT DISTINCT col0 + tab0.col1 * - col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT 0 * + col2 + + 11 FROM tab0
----
11
11
11

query I rowsort
SELECT DISTINCT + 92 + col0 * + 46 FROM tab1
----
230
3036
3772

onlyif mysql # use DIV operator for integer division
query I rowsort label-9273
SELECT ALL 10 + - col0 DIV - 43 FROM tab1 AS cor0
----
10
11
11

skipif mysql # not compatible
query I rowsort label-9273
SELECT ALL 10 + - col0 / - 43 FROM tab1 AS cor0
----
10
11
11

query I rowsort
SELECT + 86 - col0 AS col2 FROM tab2 AS cor0
----
7
79
8

query I rowsort
SELECT - - 35 + - col0 FROM tab1 cor0
----
-29
-45
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 15 * - cor0.col0 + - 76 + + 94 * col0 col1 FROM tab2 AS cor0
----
477
6086
6165

query I rowsort
SELECT ALL - - ( cor0.col0 ) - 45 FROM tab1 AS cor0
----
-42
19
35

query I rowsort
SELECT - + cor0.col2 + + col2 * - cor0.col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + + ( + col0 ) + - col2 - + col1 AS col1 FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT DISTINCT + 68 AS col2 FROM tab2 AS cor0
----
68

query I rowsort
SELECT ALL col0 + - 15 AS col2 FROM tab2 AS cor0
----
-8
63
64

query I rowsort
SELECT + 81 + 55 * - cor0.col2 FROM tab2 AS cor0
----
-1349
-1404
-2009

query I rowsort
SELECT DISTINCT 25 AS col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
25

query I rowsort
SELECT DISTINCT - 30 * - 81 FROM tab0 AS cor0
----
2430

query I rowsort
SELECT - ( - 40 ) * - col2 AS col2 FROM tab2 AS cor0
----
-1040
-1080
-1520

query I rowsort
SELECT ALL - + col2 * + 4 FROM tab2 AS cor0
----
-104
-108
-152

onlyif mysql # use DIV operator for integer division
query I rowsort label-9287
SELECT + + 37 * col1 DIV - col1 + col1 col1 FROM tab0 cor0
----
49
54
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9287
SELECT + + 37 * col1 / - col1 + col1 col1 FROM tab0 cor0
----
49
54
60

query I rowsort
SELECT ALL + - 14 + cor0.col2 FROM tab2 AS cor0
----
12
13
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9289
SELECT - 39 DIV - cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 7d0b212d0e579f36e320cc8dda889f32

skipif mysql # not compatible
query I rowsort label-9289
SELECT - 39 / - cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 7d0b212d0e579f36e320cc8dda889f32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 35 * - col1 * col1 col2 FROM tab1 cor0
----
-23660
-3500
-5915

query I rowsort
SELECT + + 24 * - col1 AS col2 FROM tab1 AS cor0
----
-240
-312
-624

query I rowsort
SELECT ALL ( - col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col1 - - col1 AS col1 FROM tab0 cor0
----
0

query I rowsort
SELECT + col2 + 53 FROM tab0
----
135
54
86

query I rowsort
SELECT + - col1 * - cor0.col2 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + - col0 + + 87 * 91 AS col2 FROM tab2 AS cor0
----
7838
7839
7910

query I rowsort
SELECT DISTINCT + 95 FROM tab2, tab1 cor0
----
95

query I rowsort
SELECT - + col0 * - col2 * + col0 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT + 87 + + 21 * - col1 AS col2 FROM tab2 AS cor0
----
-1152
-270
-564

onlyif mysql # use DIV operator for integer division
query I rowsort label-9300
SELECT - col0 DIV - 82 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9300
SELECT - col0 / - 82 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9301
SELECT - CAST( col2 AS SIGNED ) + col2 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-9301
SELECT - CAST ( col2 AS INTEGER ) + col2 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - 52 + - col2 * + col2 FROM tab2 AS cor0
----
-1392
-624
-677

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9303
SELECT DISTINCT - col0 * + CAST( NULL AS SIGNED ) + - tab0.col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-9303
SELECT DISTINCT - col0 * + CAST ( NULL AS INTEGER ) + - tab0.col1 FROM tab0
----
NULL

query I rowsort
SELECT col0 + - ( tab2.col1 ) * + col2 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT ALL + col1 * - col0 + + tab0.col2 + col2 FROM tab0
----
-1998
-3393
-7935

query I rowsort
SELECT DISTINCT + col2 * 46 + 13 AS col2 FROM tab1
----
2497
2635
4429

query I rowsort
SELECT - tab2.col1 * 63 FROM tab2
----
-1071
-1953
-3717

query I rowsort
SELECT col2 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to da83d3eeaeb9e24a3cb14bb7058757dd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 65 + - col1 col2 FROM tab1 cor0
----
-75
-78
-91

query I rowsort
SELECT - col1 + + col2 - - col0 * - ( ( col0 ) ) AS col0 FROM tab1 AS cor0
----
-4049
-6317
19

query I rowsort
SELECT DISTINCT - 77 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-77

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 cor2, tab0 AS cor3
----
3645 values hashing to 4037d65571c1bbf6e0e7d759f858120e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 40 col2 FROM tab0, tab0 AS cor0
----
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-9315
SELECT DISTINCT 89 DIV - col1 FROM tab1 AS cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-9315
SELECT DISTINCT 89 / - col1 FROM tab1 AS cor0
----
-3
-6
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 19 * + col2 col0 FROM tab0
----
1558
19
627

query I rowsort
SELECT - col2 + + cor0.col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT cor0.col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + tab0.col2 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT DISTINCT - 29 AS col0 FROM tab1, tab1 AS cor0, tab1 cor1
----
-29

query I rowsort
SELECT ALL - col0 + ( col0 ) * col1 + col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col2 + ( cor0.col2 ) * col2 AS col0 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT col1 + - col0 * + col2 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9324
SELECT col0 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9324
SELECT col0 * + CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 9 AS col0 FROM tab1 AS cor0
----
9

query I rowsort
SELECT - + ( + col1 ) * - 15 FROM tab0 cor0
----
1290
1365
1455

query I rowsort
SELECT DISTINCT + + 18 + + cor0.col1 FROM tab1 AS cor0
----
28
31
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9328
SELECT DISTINCT - ( col1 ) + + CAST( NULL AS DECIMAL ) - 61 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9328
SELECT DISTINCT - ( col1 ) + + CAST ( NULL AS REAL ) - 61 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col0 - + 17 * col2 FROM tab0
----
-1483
-52
-585

query I rowsort
SELECT ALL - tab1.col1 * col2 + - col0 * - col0 AS col1 FROM tab1
----
-1395
3526
5152

query I rowsort
SELECT + col0 * 12 FROM tab2
----
84
936
948

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0 CROSS JOIN tab1, tab2, tab2 AS cor1
----
3645 values hashing to b62c1ebc681aca72d13feadb888b3be7

query I rowsort
SELECT ALL + tab2.col2 + col2 + col2 FROM tab2
----
114
78
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col0 col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT 56 + - col2 FROM tab1
----
-1
-40
2

query I rowsort
SELECT + col0 * + cor0.col0 + col2 AS col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT 86 * col0 FROM tab1 AS cor0
----
258
5504
6880

query I rowsort
SELECT DISTINCT - col2 * + col0 - col2 * col0 FROM tab2 AS cor0
----
-378
-4056
-6004

query I rowsort
SELECT DISTINCT - ( 41 ) + - col0 * col1 FROM tab0 AS cor0
----
-2105
-3436
-8140

query I rowsort
SELECT + + cor0.col0 + + col2 + + col1 AS col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL + + 69 * - col0 FROM tab1 cor0
----
-207
-4416
-5520

query I rowsort
SELECT - col1 * + col0 - + col2 FROM tab2 cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL + 65 * 22 FROM tab1 AS cor0
----
1430
1430
1430

query I rowsort
SELECT col2 * + 62 FROM tab2
----
1612
1674
2356

query I rowsort
SELECT DISTINCT + col0 * - 92 FROM tab2
----
-644
-7176
-7268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9346
SELECT + col1 + - CAST( NULL AS DECIMAL ) * 90 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9346
SELECT + col1 + - CAST ( NULL AS REAL ) * 90 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 * - 31 AS col0 FROM tab1 AS cor0
----
310
403
806

query I rowsort
SELECT + col1 - + ( + ( + col0 ) ) FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL + col1 * col2 - - ( col1 ) AS col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL - col1 - + col1 * - ( col0 + col0 ) FROM tab1
----
1270
130
2067

onlyif mysql # use DIV operator for integer division
query I rowsort label-9351
SELECT + col2 * col1 DIV col1 - col2 DIV col1 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-9351
SELECT + col2 * col1 / col1 - col2 / col1 FROM tab1
----
52
52
89

query I rowsort
SELECT + col2 + 98 * col1 FROM tab2 AS cor0
----
1704
3065
5808

onlyif mysql # use DIV operator for integer division
query I rowsort label-9353
SELECT col2 + col1 DIV - col1 AS col1 FROM tab1 cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-9353
SELECT col2 + col1 / - col1 AS col1 FROM tab1 cor0
----
53
56
95

query I rowsort
SELECT ALL col0 + 81 + - col0 AS col0 FROM tab2
----
81
81
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + 58 * col0 * col2 col1 FROM tab2 cor0
----
10969
117702
174195

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - cor0.col0 col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9357
SELECT ALL + + CAST( 9 AS SIGNED ) * - cor0.col2 + col0 FROM tab2 AS cor0
----
-156
-236
-263

skipif mysql # not compatible
query I rowsort label-9357
SELECT ALL + + CAST ( 9 AS INTEGER ) * - cor0.col2 + col0 FROM tab2 AS cor0
----
-156
-236
-263

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9358
SELECT ALL + CAST( col0 AS SIGNED ) - - col1 * - col2 col1 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9358
SELECT ALL + CAST ( col0 AS INTEGER ) - - col1 * - col2 col1 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9359
SELECT + CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9359
SELECT + CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 - cor0.col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 * col1 * - ( 26 ) FROM tab1 cor0
----
16650
2054
27053

query I rowsort
SELECT col0 - 40 AS col0 FROM tab1 AS cor0
----
-37
24
40

query I rowsort
SELECT ALL + 40 + - cor0.col0 + + col1 AS col0 FROM tab2 AS cor0
----
-22
21
64

query I rowsort
SELECT - - 94 - + col2 FROM tab1 AS cor0
----
-2
37
40

query I rowsort
SELECT + 34 + col1 * + col1 AS col2 FROM tab2 cor0
----
323
3515
995

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9366
SELECT DISTINCT - col1 * + col1 + - col1 + - CAST( col2 + col1 * + col0 AS SIGNED ) FROM tab1 AS cor0
----
-1318
-807
-834

skipif mysql # not compatible
query I rowsort label-9366
SELECT DISTINCT - col1 * + col1 + - col1 + - CAST ( col2 + col1 * + col0 AS INTEGER ) FROM tab1 AS cor0
----
-1318
-807
-834

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9367
SELECT ALL CAST( NULL AS SIGNED ) - - cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9367
SELECT ALL CAST ( NULL AS INTEGER ) - - cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9368
SELECT 26 * 40 + - col2 * tab0.col1 + col0 DIV col1 AS col2 FROM tab0
----
-1798
-6422
943

skipif mysql # not compatible
query I rowsort label-9368
SELECT 26 * 40 + - col2 * tab0.col1 + col0 / col1 AS col2 FROM tab0
----
-1798
-6422
943

query I rowsort
SELECT col2 * - col0 + + col0 * + col0 AS col1 FROM tab1
----
-1280
-153
448

onlyif mysql # use DIV operator for integer division
query I rowsort label-9370
SELECT + 80 DIV - col2 AS col0 FROM tab0
----
-2
-80
0

skipif mysql # not compatible
query I rowsort label-9370
SELECT + 80 / - col2 AS col0 FROM tab0
----
-2
-80
0

query I rowsort
SELECT tab1.col0 * col1 * col2 FROM tab1
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9372
SELECT CAST( + col2 AS SIGNED ) + tab2.col2 AS col1 FROM tab2
----
52
54
76

skipif mysql # not compatible
query I rowsort label-9372
SELECT CAST ( + col2 AS INTEGER ) + tab2.col2 AS col1 FROM tab2
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9373
SELECT + 98 DIV ( col0 ) AS col2 FROM tab1
----
1
1
32

skipif mysql # not compatible
query I rowsort label-9373
SELECT + 98 / ( col0 ) AS col2 FROM tab1
----
1
1
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-9374
SELECT col0 + - col1 DIV - col0 + - col0 DIV - col1 AS col0 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9374
SELECT col0 + - col1 / - col0 + - col0 / - col1 AS col0 FROM tab0
----
27
37
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9375
SELECT ALL CAST( col2 AS SIGNED ) + col0 * col1 * + col0 AS col0 FROM tab1
----
288
41017
83296

skipif mysql # not compatible
query I rowsort label-9375
SELECT ALL CAST ( col2 AS INTEGER ) + col0 * col1 * + col0 AS col0 FROM tab1
----
288
41017
83296

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col1 AS REAL ) * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 79 AS col2 FROM tab2 AS cor0
----
79

query I rowsort
SELECT - ( - col0 ) * tab1.col0 AS col2 FROM tab1
----
4096
6400
9

query I rowsort
SELECT DISTINCT - 63 + col0 AS col1 FROM tab0
----
-28
-39
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 * + col1 col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - + cor0.col0 * ( + col0 ) + - col2 - - cor0.col2 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT - ( col1 ) + col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col2 * col1 + col0 * - col2 + col0 AS col0 FROM tab0 AS cor0
----
2070
253
97

query I rowsort
SELECT ALL - col2 + col1 * col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL + - col2 + - col2 + col0 FROM tab1 AS cor0
----
-105
-112
-50

query I rowsort
SELECT DISTINCT + - col1 - col0 * + col0 * + col2 FROM tab2 AS cor0
----
-1354
-158243
-237175

query I rowsort
SELECT ALL col2 * col0 + + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT - + 36 * col1 FROM tab1 AS cor0
----
-360
-468
-936

query I rowsort
SELECT DISTINCT + - 97 * col1 FROM tab1 AS cor0
----
-1261
-2522
-970

query I rowsort
SELECT - - col2 + cor0.col2 - + col1 * col1 FROM tab1 AS cor0
----
-568
14
23

query I rowsort
SELECT DISTINCT - col0 * col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT 89 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
63
76
79

query I rowsort
SELECT DISTINCT ( col0 ) - col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT col0 + 9 FROM tab0
----
33
44
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9395
SELECT + col1 + col1 DIV col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-9395
SELECT + col1 + col1 / col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT ALL + - 91 * + cor0.col1 + + col2 * + col0 FROM tab1 AS cor0
----
-2204
2738
6497

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col1 ) * col0 + col0 col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT - col2 + 39 FROM tab0 AS cor0
----
-43
38
6

query I rowsort
SELECT + col2 * ( col2 + col2 ) FROM tab2 AS cor0
----
1352
1458
2888

onlyif mysql # use DIV operator for integer division
query I rowsort label-9400
SELECT ALL col1 DIV + 92 AS col0 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9400
SELECT ALL col1 / + 92 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + 95 AS col2 FROM tab1 AS cor0
----
149
152
191

query I rowsort
SELECT col2 * + 49 * + cor0.col0 FROM tab0 AS cor0
----
1715
357602
38808

query I rowsort
SELECT DISTINCT + col2 * + 24 AS col2 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT ALL + + cor0.col2 + cor0.col1 * cor0.col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-9405
SELECT DISTINCT + col0 DIV - 65 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-9405
SELECT DISTINCT + col0 / - 65 FROM tab2 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9406
SELECT - - col2 + col2 DIV + 71 AS col1 FROM tab0 AS cor0
----
1
33
83

skipif mysql # not compatible
query I rowsort label-9406
SELECT - - col2 + col2 / + 71 AS col1 FROM tab0 AS cor0
----
1
33
83

query I rowsort
SELECT ALL col0 + + col2 * - ( + col1 ) FROM tab2 cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9408
SELECT DISTINCT - cor0.col2 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9408
SELECT DISTINCT - cor0.col2 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col1 + - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-9410
SELECT ALL col0 DIV 24 AS col0 FROM tab0 AS cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-9410
SELECT ALL col0 / 24 AS col0 FROM tab0 AS cor0
----
1
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9411
SELECT - - col2 DIV - ( - col0 ) FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-9411
SELECT - - col2 / - ( - col0 ) FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL - 88 * col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-109824
-123552
-50160

query I rowsort
SELECT DISTINCT - + col0 + ( col2 ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL 48 FROM tab2, tab2 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9415
SELECT ALL + col2 DIV + col1 - + col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-9415
SELECT ALL + col2 / + col1 - + col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - tab0.col2 * - 38 * col1 + col0 FROM tab0
----
107868
283645
3721

query I rowsort
SELECT - tab2.col1 FROM tab2, tab1 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT - - col2 * + 88 - - ( col1 ) FROM tab2 AS cor0
----
2347
2407
3361

query I rowsort
SELECT cor0.col2 * - ( col2 ) - + cor0.col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT + - 88 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to eb8cbefa7d831e1a0183e919e2caef32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9421
SELECT + col1 + + CAST( col1 * col1 AS SIGNED ) FROM tab2 cor0
----
306
3540
992

skipif mysql # not compatible
query I rowsort label-9421
SELECT + col1 + + CAST ( col1 * col1 AS INTEGER ) FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT cor0.col0 + col0 * ( col2 * col0 ) AS col2 FROM tab0 AS cor0
----
1260
19032
649611

query I rowsort
SELECT + 64 FROM tab2, tab1, tab0 cor0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9424
SELECT col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9424
SELECT col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9425
SELECT DISTINCT - col0 DIV + col0 AS col2 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-9425
SELECT DISTINCT - col0 / + col0 AS col2 FROM tab2
----
-1

query I rowsort
SELECT ALL + 67 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT - - col1 * ( - col0 ) FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - col2 - - 16 AS col0 FROM tab0 AS cor0
----
-17
-66
15

query I rowsort
SELECT - col2 + 97 AS col1 FROM tab2 AS cor0
----
59
70
71

query I rowsort
SELECT col0 - 5 FROM tab2 cor0
----
2
73
74

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 4037d65571c1bbf6e0e7d759f858120e

onlyif mysql # use DIV operator for integer division
query I rowsort label-9432
SELECT ALL - col2 DIV 41 + + col0 FROM tab1 AS cor0
----
2
63
78

skipif mysql # not compatible
query I rowsort label-9432
SELECT ALL - col2 / 41 + + col0 FROM tab1 AS cor0
----
2
63
78

query I rowsort
SELECT + + col2 * - col2 - - col2 * - cor0.col0 AS col2 FROM tab0 cor0
----
-14022
-1881
-36

query I rowsort
SELECT DISTINCT 45 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-9435
SELECT DISTINCT CAST( - col1 AS SIGNED ) DIV col0 col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9435
SELECT DISTINCT CAST ( - col1 AS INTEGER ) / col0 col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT + ( 58 ) * + col2 + - col2 AS col2 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT ALL + + 78 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT DISTINCT + - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + - 38 FROM tab0 AS cor0
----
-38
-38
-38

query I rowsort
SELECT - col1 + - col2 * - col0 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT - col0 + - col1 * + ( - 82 ) * + col2 FROM tab1 AS cor0
----
102256
115125
46676

query I rowsort
SELECT ALL - 32 * + 59 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to a964a94a15bc590c638afb0786088b72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 39 * col1 * col0 col0 FROM tab1 AS cor0
----
-24960
-3042
-40560

query I rowsort
SELECT ALL + 51 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT ALL - cor0.col0 - 80 FROM tab2, tab1 cor0
----
9 values hashing to f443c5b75f528eb2b61b798d970af004

onlyif mysql # use DIV operator for integer division
query I rowsort label-9446
SELECT - - col2 + cor0.col1 DIV col0 AS col0 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-9446
SELECT - - col2 + cor0.col1 / col0 AS col0 FROM tab0 AS cor0
----
3
36
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9447
SELECT ( - col0 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9447
SELECT ( - col0 ) * 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-9448
SELECT - 74 + cor0.col0 + + ( - col2 + col1 ) * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9448
SELECT - 74 + cor0.col0 + + ( - col2 + col1 ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 87 * + col2 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT + - col0 * + col2 + - cor0.col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT + + col0 * - col0 + + col2 AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 - - ( col2 ) * ( + col1 ) FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9453
SELECT + col2 DIV col0 col2 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9453
SELECT + col2 / col0 col2 FROM tab1 AS cor0
----
0
1
18

query IIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 WHERE NULL = ( NULL )
----

query I rowsort
SELECT DISTINCT - - col1 * cor0.col1 + + col0 * col2 FROM tab1 AS cor0
----
3748
7849
838

query I rowsort
SELECT - 96 + + col2 AS col1 FROM tab0 cor0
----
-14
-63
-95

query I rowsort
SELECT ( + col0 ) * + tab2.col1 FROM tab2
----
1343
217
4602

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 + ( cor0.col2 ) * col0 + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT 29 * - 22 FROM tab1 cor0
----
-638
-638
-638

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9462
SELECT + col1 + col0 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9462
SELECT + col1 + 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 ALL - - col2 * col0 + - col2 * col1 col2 FROM tab0 cor0
----
-164
-2046
-62

query I rowsort
SELECT DISTINCT + - col0 + col1 + + 36 AS col2 FROM tab1 AS cor0
----
-18
-31
59

query I rowsort
SELECT ALL 32 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT ( + ( + col0 ) ) AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - 50 * 30 * + col2 FROM tab2
----
-39000
-40500
-57000

query I rowsort
SELECT ALL ( 43 * - col2 ) AS col1 FROM tab1
----
-2322
-2451
-4128

query I rowsort
SELECT - col2 * 96 - + col1 AS col0 FROM tab1 cor0
----
-5210
-5482
-9229

query I rowsort
SELECT ALL 51 * - 4 AS col2 FROM tab0 AS cor0
----
-204
-204
-204

query I rowsort
SELECT ( + col2 ) + - col0 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - ( 41 ) FROM tab2 cor0
----
-41

query I rowsort
SELECT ALL + cor0.col1 + 72 * + col2 AS col2 FROM tab2 AS cor0
----
1931
1975
2753

query I rowsort
SELECT - + cor0.col1 * col2 * col0 + - ( col0 ) AS col1 FROM tab2 AS cor0
----
-119730
-51113
-5866

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 23 + - 52 * - cor0.col1 col2 FROM tab2 AS cor0
----
1635
3091
907

query I rowsort
SELECT DISTINCT - 4 FROM tab2 cor0
----
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-9477
SELECT DISTINCT - + cor0.col2 DIV - col0 + + col1 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-9477
SELECT DISTINCT - + cor0.col2 / - col0 + + col1 FROM tab0 AS cor0
----
87
91
97

query I rowsort
SELECT ALL + ( cor0.col2 ) + col2 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9479
SELECT + cor0.col2 * + col1 + + CAST( NULL AS SIGNED ) * + 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-9479
SELECT + cor0.col2 * + col1 + + CAST ( NULL AS INTEGER ) * + col1 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 91 + col1 * col1 FROM tab1 AS cor0
----
191
260
767

query I rowsort
SELECT ( - tab1.col1 + col1 ) AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9482
SELECT - + cor0.col1 DIV + col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-9482
SELECT - + cor0.col1 / + col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9483
SELECT col2 DIV col2 + 49 AS col2 FROM tab0 AS cor0
----
50
50
50

skipif mysql # not compatible
query I rowsort label-9483
SELECT col2 / col2 + 49 AS col2 FROM tab0 AS cor0
----
50
50
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 26 * col0 col0 FROM tab1 cor0
----
1664
2080
78

query I rowsort
SELECT ALL - - 2 * col2 * + col2 AS col1 FROM tab0 AS cor0
----
13448
2
2178

onlyif mysql # use DIV operator for integer division
query I rowsort label-9486
SELECT DISTINCT - col1 * col1 DIV 21 AS col1 FROM tab0 AS cor0
----
-352
-394
-448

skipif mysql # not compatible
query I rowsort label-9486
SELECT DISTINCT - col1 * col1 / 21 AS col1 FROM tab0 AS cor0
----
-352
-394
-448

query I rowsort
SELECT + - col1 * cor0.col0 + 6 AS col1 FROM tab2 AS cor0
----
-1337
-211
-4596

query I rowsort
SELECT ALL - - 51 * - col2 AS col2 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT ALL + col0 + - col0 + - tab0.col0 AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - col0 + - col0 * col2 * 89 AS col1 FROM tab1
----
-14421
-324736
-683600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9491
SELECT ALL - CAST( NULL AS DECIMAL ) * - col1 - + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9491
SELECT ALL - CAST ( NULL AS REAL ) * - col1 - + col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9492
SELECT 99 DIV - col0 FROM tab0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-9492
SELECT 99 / - col0 FROM tab0
----
-1
-2
-4

query I rowsort
SELECT DISTINCT - col2 * ( 25 ) + + col1 + col0 * col0 AS col1 FROM tab1 AS cor0
----
-1315
2681
4013

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + - col1 * + col1 * col1 col2 FROM tab1 AS cor0
----
-1064
-17579
-2277

query I rowsort
SELECT DISTINCT + + col2 + + col0 * + 66 AS col2 FROM tab2 AS cor0
----
489
5174
5252

query I rowsort
SELECT ALL cor0.col2 - cor0.col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + - cor0.col0 * + col2 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 55 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT ( cor0.col2 ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL - 91 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

query I rowsort
SELECT - col2 - ( 21 ) FROM tab1
----
-117
-75
-78

query I rowsort
SELECT col0 + ( 98 * col2 ) FROM tab0
----
133
3258
8125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * ( + col0 ) col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9504
SELECT DISTINCT - + col0 + 71 DIV col0 FROM tab1 AS cor0
----
-63
-80
20

skipif mysql # not compatible
query I rowsort label-9504
SELECT DISTINCT - + col0 + 71 / col0 FROM tab1 AS cor0
----
-63
-80
20

query I rowsort
SELECT ALL + - 13 - 74 FROM tab1 AS cor0
----
-87
-87
-87

query I rowsort
SELECT ALL + + 69 AS col0 FROM tab1 AS cor0
----
69
69
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + - cor0.col2 col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 + col0 - col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + cor0.col0 + - col2 * + col2 FROM tab2 cor0
----
-1365
-598
-722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( - col2 ) * + col0 + col2 * cor0.col0 col0 FROM tab0 AS cor0
----
14596
1584
70

query I rowsort
SELECT + 15 * 47 AS col1 FROM tab1 AS cor0
----
705
705
705

query I rowsort
SELECT DISTINCT + - ( - col0 ) - col1 FROM tab0 AS cor0
----
-2
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9513
SELECT CAST( NULL AS SIGNED ) + 45 * + 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-9513
SELECT CAST ( NULL AS INTEGER ) + 45 * + col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * 88 FROM tab1 AS cor0
----
264
5632
7040

query I rowsort
SELECT DISTINCT + col1 * col2 + - col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - - 92 AS col0 FROM tab1 AS cor0
----
92
92
92

query I rowsort
SELECT ALL cor0.col0 + + col1 * - col1 AS col2 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT ( cor0.col1 ) AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - col0 * - col0 * cor0.col1 + col0 FROM tab1 AS cor0
----
237
41024
83280

query I rowsort
SELECT ALL - + ( + col2 ) - + cor0.col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT cor0.col2 * col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL + cor0.col1 + + 48 * - cor0.col2 FROM tab0 AS cor0
----
-1498
-3845
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 * - col2 col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - 23 * + col2 AS col1 FROM tab0 AS cor0
----
-1886
-23
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-9525
SELECT ALL - - col2 * col1 DIV + ( 6 ) FROM tab2 cor0
----
107
139
255

skipif mysql # not compatible
query I rowsort label-9525
SELECT ALL - - col2 * col1 / + ( 6 ) FROM tab2 cor0
----
107
139
255

query I rowsort
SELECT - col2 * - cor0.col1 + ( 5 ) * cor0.col1 FROM tab0 cor0
----
3268
582
7917

onlyif mysql # use DIV operator for integer division
query I rowsort label-9527
SELECT 47 * col0 * + col2 + - col1 DIV cor0.col1 FROM tab2 AS cor0
----
141093
8882
95315

skipif mysql # not compatible
query I rowsort label-9527
SELECT 47 * col0 * + col2 + - col1 / cor0.col1 FROM tab2 AS cor0
----
141093
8882
95315

query I rowsort
SELECT + ( + col1 ) * col2 + + col2 * - col2 + col2 FROM tab2 AS cor0
----
-760
135
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-9529
SELECT DISTINCT - - 97 * - cor0.col2 DIV + cor0.col2 AS col1 FROM tab0 AS cor0
----
-97

skipif mysql # not compatible
query I rowsort label-9529
SELECT DISTINCT - - 97 * - cor0.col2 / + cor0.col2 AS col1 FROM tab0 AS cor0
----
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9530
SELECT col1 * col2 DIV 76 + + 40 * cor0.col0 AS col0 FROM tab0 cor0
----
1401
3658
997

skipif mysql # not compatible
query I rowsort label-9530
SELECT col1 * col2 / 76 + + 40 * cor0.col0 AS col0 FROM tab0 cor0
----
1401
3658
997

query I rowsort
SELECT ALL - 20 * col0 FROM tab2 cor0
----
-140
-1560
-1580

query I rowsort
SELECT DISTINCT + col2 + + 94 AS col2 FROM tab1 AS cor0
----
148
151
190

query I rowsort
SELECT ALL + col2 + - col1 + + tab1.col0 FROM tab1
----
111
163
31

query I rowsort
SELECT ALL + col2 * + 67 FROM tab1 AS cor0
----
3618
3819
6432

query I rowsort
SELECT DISTINCT col2 + col1 * + 4 FROM tab0 AS cor0
----
377
389
446

query I rowsort
SELECT ALL - cor0.col0 + col0 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + cor0.col0 col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - tab2.col2 + - tab2.col2 FROM tab2
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9539
SELECT DISTINCT + col1 + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-9539
SELECT DISTINCT + col1 + col2 / col0 AS col0 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT ALL col0 + col1 * col1 FROM tab2 AS cor0
----
3559
368
968

query III rowsort
SELECT ALL * FROM tab0 WHERE col1 NOT BETWEEN ( - col0 ) AND NULL
----

query I rowsort
SELECT ALL 58 + + tab1.col0 FROM tab1
----
122
138
61

query I rowsort
SELECT col2 * col0 * - col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT 55 * col0 * col0 FROM tab0
----
31680
435655
67375

query I rowsort
SELECT 3 * + col1 * + col0 AS col2 FROM tab2
----
13806
4029
651

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 * tab2.col1 col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - col1 * col1 - col1 * - col1 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - col1 * col1 - - tab0.col0 FROM tab0
----
-7372
-8192
-9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - col0 col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - col0 * - col1 + - col1 AS col0 FROM tab2
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-9551
SELECT + col0 DIV tab1.col0 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9551
SELECT + col0 / tab1.col0 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL col1 + - col1 - col1 AS col1 FROM tab2
----
-17
-31
-59

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL IN ( - col1 + - col1 )
----

query I rowsort
SELECT DISTINCT + col1 * - tab2.col1 AS col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT col1 * col1 AS col0 FROM tab0 WHERE NULL NOT IN ( col1 * col2 )
----

query I rowsort
SELECT + col1 + tab1.col2 * + col0 + col0 FROM tab1
----
191
3722
7773

query III rowsort
SELECT * FROM tab0 WHERE + col2 + + col0 * col0 NOT IN ( + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT + 55 * - col2 AS col0 FROM tab0 AS cor0
----
-1815
-4510
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + col0 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9560
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9560
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + 72 AS col2 FROM tab2 AS cor0
----
72

query I rowsort
SELECT ALL col2 AS col0 FROM tab1 WHERE NOT NULL BETWEEN col2 + + col1 + col1 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9563
SELECT + col2 DIV + tab2.col1 + col2 * + col1 FROM tab2
----
1534
648
837

skipif mysql # not compatible
query I rowsort label-9563
SELECT + col2 / + tab2.col1 + col2 * + col1 FROM tab2
----
1534
648
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-9564
SELECT ALL - col0 DIV tab1.col1 + - col1 * col1 AS col0 FROM tab1
----
-106
-175
-676

skipif mysql # not compatible
query I rowsort label-9564
SELECT ALL - col0 / tab1.col1 + - col1 * col1 AS col0 FROM tab1
----
-106
-175
-676

query I rowsort
SELECT + col1 * col1 + - col2 + + col1 FROM tab0 AS cor0
----
7449
8290
9505

onlyif mysql # use DIV operator for integer division
query I rowsort label-9566
SELECT col1 + + col0 - col1 DIV col1 AS col1 FROM tab1 AS cor0
----
28
73
92

skipif mysql # not compatible
query I rowsort label-9566
SELECT col1 + + col0 - col1 / col1 AS col1 FROM tab1 AS cor0
----
28
73
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-9567
SELECT col1 + - col2 - col0 DIV + col1 col0 FROM tab1 AS cor0
----
-28
-53
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9567
SELECT col1 + - col2 - col0 / + col1 col0 FROM tab1 AS cor0
----
-28
-53
-89

query I rowsort
SELECT DISTINCT col2 * - col2 + col2 AS col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT + tab1.col2 * col2 + col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT tab2.col0 * col2 + col2 * - col0 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT - col0 + - tab2.col1 FROM tab2 WHERE ( NULL ) NOT IN ( col2 - col2 )
----

query I rowsort
SELECT ALL tab1.col1 * col0 + + col0 * col2 AS col1 FROM tab1
----
240
4288
8720

query I rowsort
SELECT DISTINCT col0 * col0 * - col0 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT col0 * col1 + + col1 AS col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT - col0 - - col2 FROM tab2 WHERE NULL > - col2 + col0 + + col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 * - col0 col2 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT ALL - col0 + - col2 AS col1 FROM tab0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9578
SELECT - CAST( 85 AS SIGNED ) * + cor0.col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7a4ea0d7f64bef1fe05e96bf2dd41774

skipif mysql # not compatible
query I rowsort label-9578
SELECT - CAST ( 85 AS INTEGER ) * + cor0.col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7a4ea0d7f64bef1fe05e96bf2dd41774

onlyif mysql # use DIV operator for integer division
query I rowsort label-9579
SELECT DISTINCT - col0 DIV col0 AS col2 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9579
SELECT DISTINCT - col0 / col0 AS col2 FROM tab1 cor0
----
-1

query I rowsort
SELECT ( col0 ) * + 8 FROM tab2 cor0
----
56
624
632

query I rowsort
SELECT + - col2 * + col1 * 63 AS col1 FROM tab1 AS cor0
----
-35910
-78624
-88452

query I rowsort
SELECT ALL + 28 AS col2 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT DISTINCT - ( + col2 ) * + col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - - col2 + + 97 * - col0 FROM tab2 cor0
----
-652
-7540
-7625

query I rowsort
SELECT DISTINCT - - col2 * - col0 + + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - col0 * + 42 - - col2 * + cor0.col0 * + 2 FROM tab1 cor0
----
12000
198
4608

query I rowsort
SELECT + - col0 * + col0 + + ( col0 ) FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT 74 AS col0 FROM tab1, tab1 cor0, tab2 AS cor1
----
74

query I rowsort
SELECT + col0 + ( - col1 + - col2 ) FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT ALL - col2 * 28 + col0 AS col0 FROM tab0 cor0
----
-2207
-900
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9591
SELECT ALL - col2 * 79 - + col2 * - col1 DIV ( col1 ) AS col0 FROM tab2 AS cor0
----
-2028
-2106
-2964

skipif mysql # not compatible
query I rowsort label-9591
SELECT ALL - col2 * 79 - + col2 * - col1 / ( col1 ) AS col0 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT ALL - 32 FROM tab2
----
-32
-32
-32

query I rowsort
SELECT ALL col0 - - 68 FROM tab2 AS cor0
----
146
147
75

query I rowsort
SELECT DISTINCT + + ( - cor0.col1 ) FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9595
SELECT DISTINCT + CAST( - 91 AS SIGNED ) + col1 FROM tab0 cor0
----
-5
0
6

skipif mysql # not compatible
query I rowsort label-9595
SELECT DISTINCT + CAST ( - 91 AS INTEGER ) + col1 FROM tab0 cor0
----
-5
0
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 3 * - col1 + + col2 * - cor0.col0 * + cor0.col1 + cor0.col0 col2 FROM tab1 AS cor0
----
-36446
-4287
-99799

query I rowsort
SELECT ALL + ( + cor0.col2 ) * col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9598
SELECT DISTINCT + + CAST( 87 AS SIGNED ) * cor0.col0 AS col0 FROM tab2 AS cor0
----
609
6786
6873

skipif mysql # not compatible
query I rowsort label-9598
SELECT DISTINCT + + CAST ( 87 AS INTEGER ) * cor0.col0 AS col0 FROM tab2 AS cor0
----
609
6786
6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-9599
SELECT DISTINCT - col2 + col1 DIV ( - ( - col0 ) ) - cor0.col1 * col2 * col0 FROM tab1 AS cor0
----
-36537
-4258
-99936

skipif mysql # not compatible
query I rowsort label-9599
SELECT DISTINCT - col2 + col1 / ( - ( - col0 ) ) - cor0.col1 * col2 * col0 FROM tab1 AS cor0
----
-36537
-4258
-99936

query I rowsort
SELECT ALL + cor0.col2 + col2 AS col2 FROM tab1 cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-9601
SELECT ALL + - col1 DIV + col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9601
SELECT ALL + - col1 / + col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col2 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + 67 * 41 + col2 AS col2 FROM tab0
----
2748
2780
2829

query I rowsort
SELECT DISTINCT 9 AS col1 FROM tab2
----
9

query I rowsort
SELECT + ( + 69 ) - col1 FROM tab2
----
10
38
52

query I rowsort
SELECT DISTINCT + - 32 * - col2 AS col0 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT + col0 + cor0.col0 * 57 AS col1 FROM tab1 AS cor0
----
174
3712
4640

onlyif mysql # use DIV operator for integer division
query I rowsort label-9608
SELECT DISTINCT 76 DIV - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-9608
SELECT DISTINCT 76 / - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 col1 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL 46 * col1 AS col1 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT - 98 * col0 AS col2 FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT - + ( - col0 ) * cor0.col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + 10 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT - - col1 * + col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - cor0.col2 * + 24 AS col0 FROM tab0 AS cor0
----
-1968
-24
-792

query I rowsort
SELECT DISTINCT - + 34 * col1 + + 82 AS col1 FROM tab0 AS cor0
----
-2842
-3012
-3216

query I rowsort
SELECT 2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT ( col1 ) * - col1 + col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT + + 80 + + col1 * - col2 + - 14 FROM tab2 AS cor0
----
-1468
-580
-771

query I rowsort
SELECT ALL - 70 + cor0.col1 * col1 FROM tab2 AS cor0
----
219
3411
891

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 + col2 * - col2 * - col2 + ( - 60 ) * col0 col0 FROM tab1
----
157338
181410
880032

query I rowsort
SELECT col0 * - 43 * col0 FROM tab2
----
-2107
-261612
-268363

query I rowsort
SELECT DISTINCT + tab1.col0 + + 70 * col1 AS col1 FROM tab1
----
1823
764
990

onlyif mysql # use DIV operator for integer division
query I rowsort label-9624
SELECT col2 DIV 14 col1 FROM tab2
----
1
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9624
SELECT col2 / 14 col1 FROM tab2
----
1
1
2

query I rowsort
SELECT DISTINCT tab1.col1 * col1 + + col2 AS col2 FROM tab1
----
157
265
730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9626
SELECT + col0 + + CAST( col0 AS SIGNED ) * tab0.col2 FROM tab0
----
70
7387
816

skipif mysql # not compatible
query I rowsort label-9626
SELECT + col0 + + CAST ( col0 AS INTEGER ) * tab0.col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT col2 * col1 - + tab1.col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT ALL + + ( col1 ) + - cor0.col2 * 77 FROM tab2 AS cor0
----
-1943
-2048
-2909

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9629
SELECT DISTINCT + - CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9629
SELECT DISTINCT + - CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + + ( col1 ) + - col1 * col1 + col1 * - col2 AS col0 FROM tab0 cor0
----
-10148
-15652
-9409

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-9632
SELECT + + CAST( col1 AS SIGNED ) * - cor0.col0 + 85 + col0 * - col2 FROM tab2 AS cor0
----
-321
-4260
-6545

skipif mysql # not compatible
query I rowsort label-9632
SELECT + + CAST ( col1 AS INTEGER ) * - cor0.col0 + 85 + col0 * - col2 FROM tab2 AS cor0
----
-321
-4260
-6545

query I rowsort
SELECT DISTINCT + 85 FROM tab1 cor0
----
85

query I rowsort
SELECT ALL + 64 * col2 + col0 + + 89 AS col2 FROM tab2 AS cor0
----
1824
1831
2600

query I rowsort
SELECT - col2 * 76 AS col1 FROM tab2 AS cor0
----
-1976
-2052
-2888

query I rowsort
SELECT ALL col0 + - col0 * + col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT + col2 * cor0.col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT tab0.col1 * CAST ( - col1 AS REAL ) col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + col2 + 5 AS col1 FROM tab0 AS cor0
----
38
6
87

query I rowsort
SELECT + 90 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT + + col1 + ( - col1 ) * col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT + + 34 AS col2 FROM tab1 AS cor0
----
34
34
34

query I rowsort
SELECT - + 54 AS col2 FROM tab2 cor0
----
-54
-54
-54

query I rowsort
SELECT - ( col2 ) * + cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - ( col2 ) + - col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT + col1 + + 82 AS col0 FROM tab2 cor0
----
113
141
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9647
SELECT - col0 * cor0.col1 DIV - ( + col0 ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9647
SELECT - col0 * cor0.col1 / - ( + col0 ) FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9648
SELECT ALL + + ( - cor0.col2 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9648
SELECT ALL + + ( - cor0.col2 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + col2 * + ( - col2 ) + - col2 AS col1 FROM tab1 AS cor0
----
157410
185136
884640

query I rowsort
SELECT ALL - - col1 * cor0.col2 + + col2 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-9651
SELECT DISTINCT + col1 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9651
SELECT DISTINCT + col1 / cor0.col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col1 + + col1 - - 80 * + col2 FROM tab1 AS cor0
----
4372
4580
7706

query I rowsort
SELECT DISTINCT + ( col2 ) * col2 * col0 + 83 * + tab2.col1 * col0 FROM tab2
----
225545
23114
434694

onlyif mysql # use DIV operator for integer division
query I rowsort label-9654
SELECT + 73 DIV - col0 + + col1 AS col2 FROM tab2
----
17
21
59

skipif mysql # not compatible
query I rowsort label-9654
SELECT + 73 / - col0 + + col1 AS col2 FROM tab2
----
17
21
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9655
SELECT col0 + col0 DIV + 26 AS col1 FROM tab0 AS cor0
----
24
36
92

skipif mysql # not compatible
query I rowsort label-9655
SELECT col0 + col0 / + 26 AS col1 FROM tab0 AS cor0
----
24
36
92

query I rowsort
SELECT DISTINCT ( col0 ) + + col0 AS col0 FROM tab1
----
128
160
6

query I rowsort
SELECT - cor0.col1 * - 77 FROM tab2 AS cor0
----
1309
2387
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-9658
SELECT + col1 + - cor0.col0 * col1 DIV - col0 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-9658
SELECT + col1 + - cor0.col0 * col1 / - col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + - 23 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
-23

query I rowsort
SELECT DISTINCT - + col0 + - 69 * - col1 + cor0.col1 * + col0 * ( col2 ) FROM tab0 AS cor0
----
10053
670308
74022

query I rowsort
SELECT ALL cor0.col2 + - col1 * - ( col2 * 92 ) FROM tab0 cor0
----
261129
686586
8925

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9662
SELECT + - cor0.col0 - CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-9662
SELECT + - cor0.col0 - CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col2 * - cor0.col0 + - 53 FROM tab2 AS cor0
----
136
1975
2949

query I rowsort
SELECT ALL - col1 + - 91 FROM tab0 AS cor0
----
-177
-182
-188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + 11 col0 FROM tab0 AS cor0
----
-22
-71
10

query I rowsort
SELECT - - col0 * - col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - + col1 + 49 AS col2 FROM tab0 AS cor0
----
-37
-42
-48

query I rowsort
SELECT DISTINCT 6 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9669
SELECT + col0 DIV tab1.col1 AS col1 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-9669
SELECT + col0 / tab1.col1 AS col1 FROM tab1
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9670
SELECT DISTINCT + - col1 * 4 DIV + cor0.col1 FROM tab0 AS cor0
----
-4

skipif mysql # not compatible
query I rowsort label-9670
SELECT DISTINCT + - col1 * 4 / + cor0.col1 FROM tab0 AS cor0
----
-4

query I rowsort
SELECT + col2 + + col2 + col2 AS col2 FROM tab2 AS cor0
----
114
78
81

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to f0b9665afa0b835e4e5097af17c51766

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - tab2.col0 + col1 col0 FROM tab2
----
-24
51
7

query I rowsort
SELECT + - col1 * col2 - 5 * col2 FROM tab0 AS cor0
----
-102
-3003
-7872

query I rowsort
SELECT DISTINCT - 78 * col0 - - col1 AS col2 FROM tab0 cor0
----
-1786
-2633
-6851

query I rowsort
SELECT ALL + col0 - - col1 AS col0 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9677
SELECT ALL - col2 DIV - col0 - + col0 FROM tab2
----
-4
-78
-79

skipif mysql # not compatible
query I rowsort label-9677
SELECT ALL - col2 / - col0 - + col0 FROM tab2
----
-4
-78
-79

query I rowsort
SELECT ALL - tab0.col0 * 58 + 12 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to aa0bf0186428071821f1b66ba9c9ec5f

onlyif mysql # use DIV operator for integer division
query I rowsort label-9679
SELECT DISTINCT col2 * col1 DIV - ( + ( - tab0.col1 ) ) + tab0.col0 DIV col0 - + col0 FROM tab0
----
-33
-6
10

skipif mysql # not compatible
query I rowsort label-9679
SELECT DISTINCT col2 * col1 / - ( + ( - tab0.col1 ) ) + tab0.col0 / col0 - + col0 FROM tab0
----
-33
-6
10

query I rowsort
SELECT - 21 FROM tab2 cor0
----
-21
-21
-21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + cor0.col1 col2 FROM tab2 cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col2 col2 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
54
57
96

query I rowsort
SELECT 37 FROM tab2 cor0
----
37
37
37

query I rowsort
SELECT ALL + ( cor0.col2 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9685
SELECT ALL - ( cor0.col1 ) + CAST( 70 AS SIGNED ) FROM tab0, tab0 AS cor0
----
9 values hashing to 5a41a4f9ec8e7842aff6ae7861607913

skipif mysql # not compatible
query I rowsort label-9685
SELECT ALL - ( cor0.col1 ) + CAST ( 70 AS INTEGER ) FROM tab0, tab0 AS cor0
----
9 values hashing to 5a41a4f9ec8e7842aff6ae7861607913

query I rowsort
SELECT DISTINCT - ( - col1 ) + col1 + col2 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT ( - 71 ) FROM tab0 AS cor0
----
-71
-71
-71

query I rowsort
SELECT + col0 + 66 * col2 AS col2 FROM tab1
----
3567
3826
6416

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab1 cor2
----
3645 values hashing to d95cefa45985203e212af5af5dd9be5b

query I rowsort
SELECT + 60 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT ALL ( tab0.col1 + + col0 * + 11 ) FROM tab0
----
1070
350
482

query I rowsort
SELECT DISTINCT col1 * + 44 AS col0 FROM tab2
----
1364
2596
748

query I rowsort
SELECT DISTINCT 86 AS col2 FROM tab0, tab2 AS cor0
----
86

query I rowsort
SELECT DISTINCT + cor1.col1 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 + - col2 AS col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT - ( + col0 ) + col0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + 47 * 57 AS col0 FROM tab0 AS cor0
----
2679
2679
2679

query I rowsort
SELECT ALL + 51 * + col0 AS col0 FROM tab2 AS cor0
----
357
3978
4029

query I rowsort
SELECT ALL + 30 + - col0 * - col0 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
4183
6526
93

query I rowsort
SELECT - 76 * - col2 FROM tab1
----
4104
4332
7296

query I rowsort
SELECT 24 * cor0.col0 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 1b67170218914cef7057701a7f52b77b

query I rowsort
SELECT ALL col2 * col2 * 24 + - col0 + - col1 * + 51 FROM tab1
----
220441
68655
77402

query I rowsort
SELECT - col1 + - col1 * + col0 AS col2 FROM tab0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT tab2.col0 * - col0 + + 12 FROM tab2
----
-37
-6072
-6229

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT + + col0 + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9707
SELECT - col1 * + col1 - + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-157
-265
-730

skipif mysql # not compatible
query I rowsort label-9707
SELECT - col1 * + col1 - + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT DISTINCT col2 * ( - ( - col1 ) + col1 ) AS col1 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT DISTINCT + col2 + ( col2 ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL col0 * - 81 + - col0 FROM tab2 AS cor0
----
-574
-6396
-6478

query I rowsort
SELECT ALL col1 * + col0 * - col0 + col0 FROM tab1 AS cor0
----
-231
-40896
-83120

query I rowsort
SELECT ALL - col1 - 32 FROM tab1 cor0
----
-42
-45
-58

query I rowsort
SELECT - + cor0.col0 + col2 * + cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9714
SELECT - + col0 * CAST( + col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-9714
SELECT - + col0 * CAST ( + col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9715
SELECT DISTINCT - col2 + - col2 * col0 DIV col2 AS col2 FROM tab1 cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-9715
SELECT DISTINCT - col2 + - col2 * col0 / col2 AS col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT + col2 * - ( + 25 ) FROM tab0 AS cor0
----
-2050
-25
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * - 69 col0 FROM tab1 AS cor0
----
-1794
-690
-897

query I rowsort
SELECT + cor0.col1 + + 13 * 59 AS col1 FROM tab1 AS cor0
----
777
780
793

query I rowsort
SELECT DISTINCT + col1 * - ( - col1 ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - - col0 + 96 AS col0 FROM tab1 AS cor0
----
160
176
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9721
SELECT DISTINCT col1 + - CAST( NULL AS SIGNED ) * cor0.col0 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9721
SELECT DISTINCT col1 + - CAST ( NULL AS INTEGER ) * cor0.col0 col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 * + 53 - - col1 FROM tab1 cor0
----
-1352
-520
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( col2 ) * - col2 col2 FROM tab2 AS cor0
----
-1461
-735
-760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9724
SELECT ALL col2 * 41 DIV col0 + col2 * 75 AS col1 FROM tab1 AS cor0
----
4311
4788
7249

skipif mysql # not compatible
query I rowsort label-9724
SELECT ALL col2 * 41 / col0 + col2 * 75 AS col1 FROM tab1 AS cor0
----
4311
4788
7249

onlyif mysql # use DIV operator for integer division
query I rowsort label-9725
SELECT - - col0 DIV + col1 + col0 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-9725
SELECT - - col0 / + col1 + col0 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT ALL + col2 * - 47 AS col0 FROM tab1 AS cor0
----
-2538
-2679
-4512

query I rowsort
SELECT ALL col2 * + ( col2 * + col0 ) FROM tab0
----
26136
35
598436

query I rowsort
SELECT + - col2 + + 84 * col1 AS col0 FROM tab0 AS cor0
----
7191
7562
8147

query I rowsort
SELECT DISTINCT - col1 + - ( cor0.col2 + col0 ) * 7 AS col1 FROM tab0 AS cor0
----
-1288
-349
-485

query I rowsort
SELECT ALL + col2 * + 85 FROM tab0 AS cor0
----
2805
6970
85

query I rowsort
SELECT + col0 * ( + col2 ) - + cor0.col1 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT - 69 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT + col2 - col2 AS col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9734
SELECT + + col0 * - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9734
SELECT + + col0 * - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * 14 * + col0 FROM tab2 AS cor0
----
686
85176
87374

onlyif mysql # use DIV operator for integer division
query I rowsort label-9736
SELECT + + col1 DIV col0 + + col0 FROM tab0 cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9736
SELECT + + col1 / col0 + + col0 FROM tab0 cor0
----
27
37
90

query I rowsort
SELECT ( 26 ) * - col1 AS col1 FROM tab1 AS cor0
----
-260
-338
-676

query I rowsort
SELECT - cor0.col1 * + col0 + - col1 AS col1 FROM tab0 cor0
----
-2150
-3492
-8190

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col2 AS REAL ) AS col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9740
SELECT DISTINCT CAST( col0 AS SIGNED ) * + col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-9740
SELECT DISTINCT CAST ( col0 AS INTEGER ) * + col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - ( - col1 ) * col1 AS col0 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-9742
SELECT DISTINCT tab1.col0 DIV ( + 22 ) + + col1 AS col2 FROM tab1
----
12
16
26

skipif mysql # not compatible
query I rowsort label-9742
SELECT DISTINCT tab1.col0 / ( + 22 ) + + col1 AS col2 FROM tab1
----
12
16
26

query I rowsort
SELECT DISTINCT col2 * 64 + 39 * + tab0.col1 * col2 FROM tab0
----
112794
296266
3847

query I rowsort
SELECT ALL - tab1.col1 * - ( + col0 ) AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT col1 * 54 + + 3 FROM tab2
----
1677
3189
921

onlyif mysql # use DIV operator for integer division
query I rowsort label-9746
SELECT tab0.col1 DIV - col2 + tab0.col0 + col2 FROM tab0
----
-61
170
55

skipif mysql # not compatible
query I rowsort label-9746
SELECT tab0.col1 / - col2 + tab0.col0 + col2 FROM tab0
----
-61
170
55

query I rowsort
SELECT DISTINCT - 93 + col1 * + col2 FROM tab1 AS cor0
----
1155
1311
477

query I rowsort
SELECT ALL col0 + + col0 + + col0 AS col2 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT - 80 + - col2 AS col0 FROM tab0 AS cor0
----
-113
-162
-81

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-9751
SELECT ALL + col2 DIV + col0 + 72 FROM tab2 AS cor0
----
72
72
75

skipif mysql # not compatible
query I rowsort label-9751
SELECT ALL + col2 / + col0 + 72 FROM tab2 AS cor0
----
72
72
75

query I rowsort
SELECT ALL - ( - 19 ) AS col2 FROM tab2
----
19
19
19

query I rowsort
SELECT - + cor0.col2 AS col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT ALL - + col0 + - col1 * col1 + 25 AS col0 FROM tab2 AS cor0
----
-343
-3534
-943

query I rowsort
SELECT DISTINCT - col1 + + col0 * - ( 18 * - col2 ) AS col0 FROM tab2 AS cor0
----
3371
36445
54019

onlyif mysql # use DIV operator for integer division
query I rowsort label-9756
SELECT - col1 + + col2 DIV - 18 FROM tab2 AS cor0
----
-19
-32
-60

skipif mysql # not compatible
query I rowsort label-9756
SELECT - col1 + + col2 / - 18 FROM tab2 AS cor0
----
-19
-32
-60

query I rowsort
SELECT ALL + cor0.col0 + col2 * - ( col0 ) * + col2 FROM tab0 AS cor0
----
-26112
-598347
0

query I rowsort
SELECT DISTINCT cor0.col2 + - 46 FROM tab1, tab1 AS cor0
----
11
50
8

query I rowsort
SELECT + col0 * col1 - cor0.col0 FROM tab0 AS cor0
----
2040
3360
8010

skipif mysql # not compatible
query I rowsort
SELECT ALL - 71 * col1 + CAST ( - col0 AS REAL ) FROM tab0 AS cor0
----
-6130
-6550
-6922

onlyif mysql # use DIV operator for integer division
query I rowsort label-9761
SELECT 41 DIV - cor0.col1 + - CAST( + ( + col2 ) AS SIGNED ) * col0 AS col2 FROM tab2 cor0
----
-190
-2028
-3004

skipif mysql # not compatible
query I rowsort label-9761
SELECT 41 / - cor0.col1 + - CAST ( + ( + col2 ) AS INTEGER ) * col0 AS col2 FROM tab2 cor0
----
-190
-2028
-3004

query I rowsort
SELECT ALL + + 6 * - col1 FROM tab0 cor0
----
-516
-546
-582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 73 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT cor0.col0 * - col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( cor0.col2 ) col2 FROM tab0, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9766
SELECT - col2 DIV col1 AS col2 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-9766
SELECT - col2 / col1 AS col2 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT 35 FROM tab0, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT ALL + - cor0.col1 + + col1 * col1 AS col0 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 29 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL - 95 * - 28 FROM tab1
----
2660
2660
2660

query I rowsort
SELECT - + cor0.col0 + - col1 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - ( col0 ) * ( 79 ) + col1 AS col2 FROM tab2 AS cor0
----
-522
-6103
-6224

query I rowsort
SELECT - 6 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
18
384
480

query I rowsort
SELECT 72 + + col0 * col0 * col2 FROM tab2 cor0
----
1395
158256
237230

onlyif mysql # use DIV operator for integer division
query I rowsort label-9776
SELECT - col2 DIV - 84 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9776
SELECT - col2 / - 84 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - + col0 * - ( - 16 ) AS col2 FROM tab0 AS cor0
----
-1424
-384
-560

query I rowsort
SELECT ALL + + cor0.col2 * col1 * cor0.col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL + + cor0.col0 * ( col0 + + col0 ) FROM tab1 AS cor0
----
12800
18
8192

query I rowsort
SELECT - + col2 * cor0.col1 * + col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT col0 + - 42 * col2 - 77 FROM tab1 AS cor0
----
-2342
-2407
-4029

query I rowsort
SELECT + col0 - + col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9783
SELECT + - CAST( - col2 AS SIGNED ) * cor0.col2 - + col2 FROM tab1 AS cor0
----
2862
3192
9120

skipif mysql # not compatible
query I rowsort label-9783
SELECT + - CAST ( - col2 AS INTEGER ) * cor0.col2 - + col2 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9784
SELECT + CAST( NULL AS DECIMAL ) * - 93 + - col0 * 38 * + col1 + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9784
SELECT + CAST ( NULL AS REAL ) * - 93 + - col0 * 38 * + col1 + col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 8 AS col0 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

onlyif mysql # use DIV operator for integer division
query I rowsort label-9786
SELECT - + ( 88 ) DIV + col1 - - ( + 40 ) AS col0 FROM tab1 AS cor0
----
32
34
37

skipif mysql # not compatible
query I rowsort label-9786
SELECT - + ( 88 ) / + col1 - - ( + 40 ) AS col0 FROM tab1 AS cor0
----
32
34
37

query I rowsort
SELECT + 62 - col2 FROM tab2 AS cor0
----
24
35
36

query I rowsort
SELECT + 47 * cor0.col2 FROM tab1 AS cor0
----
2538
2679
4512

query I rowsort
SELECT ALL - col1 * - col1 * + col1 AS col0 FROM tab0
----
636056
753571
912673

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( cor0.col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9791
SELECT cor0.col1 DIV - col0 col0 FROM tab2 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9791
SELECT cor0.col1 / - col0 col0 FROM tab2 AS cor0
----
-4
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9792
SELECT ALL + CAST( - 71 AS SIGNED ) + col2 AS col1 FROM tab1 AS cor0
----
-14
-17
25

skipif mysql # not compatible
query I rowsort label-9792
SELECT ALL + CAST ( - 71 AS INTEGER ) + col2 AS col1 FROM tab1 AS cor0
----
-14
-17
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-9793
SELECT - col1 DIV - 60 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9793
SELECT - col1 / - 60 AS col0 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9794
SELECT + 88 DIV col0 FROM tab0 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-9794
SELECT + 88 / col0 FROM tab0 AS cor0
----
0
2
3

query I rowsort
SELECT - col0 * 37 AS col1 FROM tab0 AS cor0
----
-1295
-3293
-888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9796
SELECT DISTINCT + cor0.col0 * - 49 * col1 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9796
SELECT DISTINCT + cor0.col0 * - 49 * col1 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9797
SELECT DISTINCT + col1 * cor0.col2 DIV - col1 col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9797
SELECT DISTINCT + col1 * cor0.col2 / - col1 col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT col0 + - col2 * + ( col0 ) AS col2 FROM tab0 cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9799
SELECT col0 + col1 DIV ( col0 ) AS col1 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-9799
SELECT col0 + col1 / ( col0 ) AS col1 FROM tab1 AS cor0
----
11
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9800
SELECT DISTINCT 98 DIV col2 AS col2 FROM tab0 cor0
----
1
2
98

skipif mysql # not compatible
query I rowsort label-9800
SELECT DISTINCT 98 / col2 AS col2 FROM tab0 cor0
----
1
2
98

query I rowsort
SELECT - col1 + - col1 * - col1 * - col2 - col1 AS col2 FROM tab1 cor0
----
-16250
-36556
-5720

query I rowsort
SELECT DISTINCT + ( tab2.col0 ) * - col0 FROM tab2
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-9803
SELECT + + col0 + + 76 DIV col2 AS col1 FROM tab0 cor0
----
111
26
89

skipif mysql # not compatible
query I rowsort label-9803
SELECT + + col0 + + 76 / col2 AS col1 FROM tab0 cor0
----
111
26
89

query I rowsort
SELECT DISTINCT - 87 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9805
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9805
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9806
SELECT ( col2 ) * + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9806
SELECT ( col2 ) * + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9808
SELECT ALL + col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9808
SELECT ALL + col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9809
SELECT col0 DIV + ( - col0 ) + + col0 col0 FROM tab0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9809
SELECT col0 / + ( - col0 ) + + col0 col0 FROM tab0
----
23
34
88

query I rowsort
SELECT col1 * 40 AS col0 FROM tab1 AS cor0
----
1040
400
520

onlyif mysql # use DIV operator for integer division
query I rowsort label-9811
SELECT - col2 DIV - CAST( col0 * col0 AS SIGNED ) FROM tab1 cor0
----
0
0
6

skipif mysql # not compatible
query I rowsort label-9811
SELECT - col2 / - CAST ( col0 * col0 AS INTEGER ) FROM tab1 cor0
----
0
0
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9812
SELECT DISTINCT + cor0.col1 DIV - 30 AS col0 FROM tab2 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-9812
SELECT DISTINCT + cor0.col1 / - 30 AS col0 FROM tab2 cor0
----
-1
0

query I rowsort
SELECT + - col2 * + ( cor0.col1 ) + + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - col2 * ( - col2 ) * col1 + col2 * col2 AS col1 FROM tab1 AS cor0
----
129024
35739
78732

query I rowsort
SELECT + + col2 + - ( ( + col2 ) ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + col1 * + 60 FROM tab2 AS cor0
----
-1020
-1860
-3540

query I rowsort
SELECT - col2 * col0 + - col1 AS col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT col2 * - col1 * col2 AS col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col1 * - col1 + col1 * + col2 + col2 AS col1 FROM tab1 cor0
----
1513
2134
727

onlyif mysql # use DIV operator for integer division
query I rowsort label-9821
SELECT ALL - col0 DIV - 19 + - 4 col1 FROM tab1 AS cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9821
SELECT ALL - col0 / - 19 + - 4 col1 FROM tab1 AS cor0
----
-1
-4
0

query I rowsort
SELECT + + col0 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9823
SELECT + 29 DIV tab1.col0 + col0 * col1 FROM tab1
----
1040
640
87

skipif mysql # not compatible
query I rowsort label-9823
SELECT + 29 / tab1.col0 + col0 * col1 FROM tab1
----
1040
640
87

query I rowsort
SELECT + col2 + + 67 * col1 + col1 * ( col2 ) AS col1 FROM tab1 AS cor0
----
1297
2215
3200

query I rowsort
SELECT ALL - + col1 + + col2 * - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9826
SELECT DISTINCT col2 * - CAST( + col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-9826
SELECT DISTINCT col2 * - CAST ( + col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - col0 * - 45 FROM tab2 AS cor0
----
315
3510
3555

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9828
SELECT col0 * + CAST( + 3 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
192
240
9

skipif mysql # not compatible
query I rowsort label-9828
SELECT col0 * + CAST ( + 3 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT ALL col0 + 11 AS col0 FROM tab1
----
14
75
91

query I rowsort
SELECT - 65 + col1 * col2 AS col1 FROM tab0 AS cor0
----
2773
32
7397

query I rowsort
SELECT - 31 * col0 * - col1 AS col0 FROM tab2 AS cor0
----
142662
41633
6727

query I rowsort
SELECT ALL + + 88 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT DISTINCT col2 * 16 + - col0 * - col0 FROM tab0
----
1104
1241
9233

query I rowsort
SELECT ALL - - 47 + col0 AS col1 FROM tab1 AS cor0
----
111
127
50

query I rowsort
SELECT - col0 - + col1 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - col2 - - cor0.col0 * 89 AS col2 FROM tab0 AS cor0
----
2103
3114
7839

query I rowsort
SELECT DISTINCT + col2 FROM tab0 WHERE NULL <> + col2 * col1 + - col2
----

query I rowsort
SELECT - col1 FROM tab1 WHERE col2 * col2 <> NULL
----

query I rowsort
SELECT DISTINCT - + col0 + cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + col1 * - col2 * - col1 + col1 FROM tab0 AS cor0
----
244154
679133
9506

query I rowsort
SELECT ALL - col2 * + col2 + col0 FROM tab0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9842
SELECT + tab1.col2 DIV col2 + col0 AS col2 FROM tab1 WHERE col2 NOT IN ( + tab1.col0 )
----
4
65
81

skipif mysql # not compatible
query I rowsort label-9842
SELECT + tab1.col2 / col2 + col0 AS col2 FROM tab1 WHERE col2 NOT IN ( + tab1.col0 )
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9843
SELECT + col0 * col1 + - tab1.col2 DIV + col2 + + col2 FROM tab1
----
1135
131
696

skipif mysql # not compatible
query I rowsort label-9843
SELECT + col0 * col1 + - tab1.col2 / + col2 + + col2 FROM tab1
----
1135
131
696

query I rowsort
SELECT ALL col1 FROM tab0 WHERE NOT + col1 - - col2 IN ( col1 )
----
86
91
97

query I rowsort
SELECT DISTINCT - tab1.col1 AS col1 FROM tab1 WHERE NOT NULL NOT IN ( col0 / - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9846
SELECT DISTINCT col1 * - tab0.col1 DIV col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9846
SELECT DISTINCT col1 * - tab0.col1 / col1 FROM tab0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9847
SELECT - col2 DIV - tab1.col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9847
SELECT - col2 / - tab1.col2 FROM tab1
----
1
1
1

query I rowsort
SELECT + col0 AS col1 FROM tab0 WHERE ( NULL ) <> NULL
----

query I rowsort
SELECT col1 * + col2 + + tab1.col0 * - col0 + - col0 AS col0 FROM tab1
----
-3590
-5232
1392

query I rowsort
SELECT DISTINCT + col0 * + col1 + - col0 FROM tab1 WHERE NOT NULL <= col0 / col2 + col1
----

query I rowsort
SELECT DISTINCT - 2 * - col1 + - col2 FROM tab0
----
100
139
193

query I rowsort
SELECT ALL + 60 * - 75 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to fc53efd7c4089859b7f3238fa1482f68

query I rowsort
SELECT - col2 + col2 - + col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - 47 AS col0 FROM tab0 cor0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT + + col0 * - col2 + - col0 AS col2 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT 53 - col0 FROM tab0 AS cor0
----
-36
18
29

query I rowsort
SELECT DISTINCT tab0.col0 AS col2 FROM tab0, tab2, tab2 AS cor0
----
24
35
89

query I rowsort
SELECT col2 - - ( + col1 + - cor0.col1 ) * - 31 * 17 AS col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9859
SELECT - CAST( NULL AS SIGNED ) + cor1.col1 * cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9859
SELECT - CAST ( NULL AS INTEGER ) + cor1.col1 * cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9860
SELECT DISTINCT cor0.col2 DIV col1 - - col1 DIV col0 AS col0 FROM tab1 AS cor0
----
10
5
7

skipif mysql # not compatible
query I rowsort label-9860
SELECT DISTINCT cor0.col2 / col1 - - col1 / col0 AS col0 FROM tab1 AS cor0
----
10
5
7

query I rowsort
SELECT DISTINCT - col0 + + col2 * 0 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + + col1 * 74 + col2 col2 FROM tab0 AS cor0
----
6311
6725
7082

query I rowsort
SELECT DISTINCT + + 77 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
77

query I rowsort
SELECT DISTINCT - + col2 * - 57 + + cor0.col1 AS col0 FROM tab0 cor0
----
154
1967
4765

query I rowsort
SELECT ALL - col2 - - 48 FROM tab0 AS cor0
----
-34
15
47

query I rowsort
SELECT - col2 * col1 * - col0 FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - 23 col2 FROM tab0 AS cor0
----
-112
-47
-58

query I rowsort
SELECT col1 * ( col0 ) + col2 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9869
SELECT ALL - col1 * CAST( + col0 AS SIGNED ) + + col1 AS col2 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif mysql # not compatible
query I rowsort label-9869
SELECT ALL - col1 * CAST ( + col0 AS INTEGER ) + + col1 AS col2 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL 91 * + 76 AS col1 FROM tab1
----
6916
6916
6916

query I rowsort
SELECT DISTINCT tab2.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
17
31
59

query I rowsort
SELECT ALL - ( - 24 * col1 ) FROM tab2
----
1416
408
744

skipif mysql # not compatible
query I rowsort
SELECT ALL - + CAST ( col2 AS REAL ) * - col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) FROM tab2, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - ( + 8 ) + col2 AS col0 FROM tab0 cor0
----
-7
25
74

query I rowsort
SELECT ALL col1 * + col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - col2 * col1 - cor0.col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL + ( + cor0.col0 ) * 76 AS col0 FROM tab0 cor0
----
1824
2660
6764

onlyif mysql # use DIV operator for integer division
query I rowsort label-9879
SELECT DISTINCT col1 DIV + col0 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-9879
SELECT DISTINCT col1 / + col0 FROM tab2 cor0
----
0
4

query I rowsort
SELECT ALL col1 * + 84 AS col2 FROM tab2
----
1428
2604
4956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 84 col0 FROM tab0
----
84
84
84

query I rowsort
SELECT col0 - + col2 * + col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT - col2 * - cor0.col2 + cor0.col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + tab1.col1 * - col1 AS col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - + col0 * cor0.col1 * cor0.col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ALL col0 * + col2 - col2 * col2 AS col0 FROM tab2
----
-540
1352
1558

query I rowsort
SELECT col2 + - col0 * col0 AS col1 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT ALL - col1 * col2 + + col1 - - col0 * col1 FROM tab1
----
-1300
-195
80

query I rowsort
SELECT ALL - col0 * + tab2.col1 * col0 AS col1 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT ALL + 56 * tab0.col0 FROM tab0
----
1344
1960
4984

query I rowsort
SELECT ( 17 * - tab2.col2 ) FROM tab2
----
-442
-459
-646

onlyif mysql # use DIV operator for integer division
query I rowsort label-9892
SELECT + 37 DIV - col2 AS col2 FROM tab0 AS cor0
----
-1
-37
0

skipif mysql # not compatible
query I rowsort label-9892
SELECT + 37 / - col2 AS col2 FROM tab0 AS cor0
----
-1
-37
0

query I rowsort
SELECT ALL - col0 + + col2 * col0 AS col2 FROM tab2
----
182
1950
2923

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT - col1 = ( + col2 + col1 + + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col0 FROM tab1 AS cor0 WHERE col0 + col1 <= col0
----

query I rowsort
SELECT - col1 + + tab2.col1 FROM tab2
----
0
0
0

query I rowsort
SELECT + col1 + + col0 + - col1 * + col1 AS col0 FROM tab2
----
-193
-3344
-923

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( tab1.col0 + + col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT BETWEEN + col0 / col1 + col0 AND NULL
----

query I rowsort
SELECT DISTINCT col1 FROM tab2 WHERE NOT NULL <> + col1 + col2
----

query III rowsort
SELECT * FROM tab2 WHERE NOT - col0 <= ( NULL )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL <> col0
----

query I rowsort
SELECT - col1 AS col1 FROM tab0 WHERE NOT - col0 NOT IN ( - col2 * col2 )
----

query I rowsort
SELECT col2 * - col0 FROM tab1 WHERE col2 IN ( col0 * tab1.col1 )
----

query I rowsort
SELECT ALL tab1.col0 + - col0 * col0 + - col2 * - tab1.col2 FROM tab1
----
-783
2896
2910

query I rowsort
SELECT ALL + col0 + col1 + col1 AS col1 FROM tab2
----
113
196
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col0 + tab2.col1 * col2 col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT + col1 * cor0.col0 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-3456
-5360
69

query I rowsort
SELECT col1 * col0 + col2 AS col1 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-9910
SELECT - col1 DIV - cor0.col2 - - col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9910
SELECT - col1 / - cor0.col2 - - col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT col1 * col2 = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9912
SELECT DISTINCT col0 + col0 DIV + col1 AS col0 FROM tab2 AS cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-9912
SELECT DISTINCT col0 + col0 / + col1 AS col0 FROM tab2 AS cor0
----
7
79
83

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE col0 BETWEEN ( col0 ) AND NULL
----

query I rowsort
SELECT DISTINCT cor0.col0 * col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT ALL - ( - col2 ) * col0 * cor0.col1 + 47 FROM tab2 AS cor0
----
119699
51081
5906

query I rowsort
SELECT col0 + + 39 FROM tab1 AS cor0
----
103
119
42

query I rowsort
SELECT ALL - - ( 15 ) + col1 * col0 FROM tab1 AS cor0
----
1055
655
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-9918
SELECT ALL - col1 DIV col2 + col2 AS col0 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-9918
SELECT ALL - col1 / col2 + col2 AS col0 FROM tab0 AS cor0
----
-96
31
81

query I rowsort
SELECT ALL - 20 * col0 + col0 FROM tab1
----
-1216
-1520
-57

query I rowsort
SELECT DISTINCT - col1 + - col0 * - col0 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT + - 4 + col1 - cor0.col1 FROM tab1 AS cor0
----
-4
-4
-4

query I rowsort
SELECT - 1 * col2 + + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - + 98 * col2 FROM tab0 cor0
----
-3234
-8036
-98

query I rowsort
SELECT + col1 - + 70 FROM tab0 cor0
----
16
21
27

skipif mysql # not compatible
query I rowsort
SELECT ALL - + CAST ( + 71 AS REAL ) * col1 AS col2 FROM tab1 AS cor0
----
-1846
-710
-923

onlyif mysql # use DIV operator for integer division
query I rowsort label-9926
SELECT DISTINCT - col1 DIV 59 AS col0 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-9926
SELECT DISTINCT - col1 / 59 AS col0 FROM tab2 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 36 col0 FROM tab0 AS cor0
----
36
36
36

query I rowsort
SELECT - col0 * - col2 + col2 - + 77 FROM tab1 AS cor0
----
139
3628
7699

query I rowsort
SELECT DISTINCT + 71 * + col1 + + col0 FROM tab1 cor0
----
1003
1849
774

query I rowsort
SELECT ALL 86 + - col2 AS col0 FROM tab1 AS cor0
----
-10
29
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-9931
SELECT 35 DIV col2 + + col0 DIV - ( col2 ) col2 FROM tab0 AS cor0
----
-1
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9931
SELECT 35 / col2 + + col0 / - ( col2 ) col2 FROM tab0 AS cor0
----
-1
0
1

query I rowsort
SELECT + 41 + + col1 * col2 FROM tab2 AS cor0
----
1575
687
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-9933
SELECT DISTINCT + col0 DIV - cor0.col1 FROM tab1 cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-9933
SELECT DISTINCT + col0 / - cor0.col1 FROM tab1 cor0
----
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col2 * col0 - col1 col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - col1 + - col1 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT + col0 * cor0.col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT cor0.col2 * - col0 * ( col0 ) FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + col2 + - col1 * col0 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT - col0 - - col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT tab0.col1 - 31 AS col1 FROM tab0
----
55
60
66

query I rowsort
SELECT DISTINCT + col0 * col2 * ( col1 ) + 79 + ( - cor0.col2 ) FROM tab1 AS cor0
----
36502
4237
99823

query I rowsort
SELECT 71 AS col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT ALL col0 * ( + col1 * col0 ) AS col0 FROM tab1 cor0
----
234
40960
83200

query I rowsort
SELECT col1 * 1 AS col1 FROM tab1 AS cor0
----
10
13
26

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab0 cor1, tab1 cor2
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

query I rowsort
SELECT ALL + - col2 * + 6 AS col1 FROM tab2 AS cor0
----
-156
-162
-228

onlyif mysql # use DIV operator for integer division
query I rowsort label-9947
SELECT ALL 16 DIV col0 AS col2 FROM tab1
----
0
0
5

skipif mysql # not compatible
query I rowsort label-9947
SELECT ALL 16 / col0 AS col2 FROM tab1
----
0
0
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9948
SELECT col0 + + cor0.col1 * col1 DIV + col0 AS col0 FROM tab0 AS cor0
----
182
303
332

skipif mysql # not compatible
query I rowsort label-9948
SELECT col0 + + cor0.col1 * col1 / + col0 AS col0 FROM tab0 AS cor0
----
182
303
332

query I rowsort
SELECT - col0 * + ( col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col2 * col2 - - col2 AS col0 FROM tab1
----
2970
3306
9312

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + 93 AS col0 FROM tab0 cor0
----
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-9953
SELECT DISTINCT col0 + + col2 DIV col0 FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-9953
SELECT DISTINCT col0 + + col2 / col0 FROM tab2 AS cor0
----
10
78
79

query I rowsort
SELECT ALL + col1 * + col2 * col2 FROM tab0
----
611884
93654
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9955
SELECT - col1 + + CAST( col0 AS SIGNED ) FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-9955
SELECT - col1 + + CAST ( col0 AS INTEGER ) FROM tab0
----
-2
-62
-62

query I rowsort
SELECT col1 + - ( 91 ) FROM tab1
----
-65
-78
-81

query I rowsort
SELECT ALL 82 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 73 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT cor0.col0 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT 74 AS col2 FROM tab2, tab1 cor0
----
74

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab1, tab2 cor1
----
243 values hashing to 6506b295d3a7bcc5ed65956f5b4e38b0

query I rowsort
SELECT - col1 + + 5 AS col1 FROM tab1
----
-21
-5
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 52 * + 87 col2 FROM tab2
----
4524
4524
4524

query I rowsort
SELECT DISTINCT col0 * col0 * col0 + + ( col2 ) * - col1 FROM tab1
----
-1377
261574
510752

query I rowsort
SELECT + ( col2 ) * + tab0.col2 AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT 91 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT DISTINCT + ( col0 ) + col2 AS col0 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9969
SELECT + + 9 DIV col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9969
SELECT + + 9 / col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + ( 20 ) * col0 FROM tab0 cor0
----
1780
480
700

query I rowsort
SELECT DISTINCT + cor0.col1 * - col0 + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL 51 + 10 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 63 col2 FROM tab0 cor0
----
63

query I rowsort
SELECT DISTINCT + tab1.col1 + + tab1.col2 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL tab0.col1 + tab0.col0 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-9976
SELECT col0 DIV col0 + + ( col0 ) FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-9976
SELECT col0 / col0 + + ( col0 ) FROM tab2
----
79
8
80

query I rowsort
SELECT DISTINCT col1 * + col2 + col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT - 87 * col2 AS col1 FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT DISTINCT + col1 * ( 46 ) AS col0 FROM tab2 AS cor0
----
1426
2714
782

query I rowsort
SELECT ALL - col2 * 48 + - col2 FROM tab2 AS cor0
----
-1274
-1323
-1862

query I rowsort
SELECT DISTINCT col0 + - cor0.col0 * 86 AS col1 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT cor0.col0 * - 65 AS col0 FROM tab0 AS cor0
----
-1560
-2275
-5785

query I rowsort
SELECT DISTINCT + + col0 + + ( ( - col2 ) ) AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL - col1 * + ( - col1 ) * col1 + - col0 * 76 * + cor0.col1 + ( col2 ) AS col0 FROM tab0 AS cor0
----
138129
479225
654654

query I rowsort
SELECT + col1 + + ( 57 ) AS col2 FROM tab1 AS cor0
----
67
70
83

query I rowsort
SELECT col2 + 18 AS col1 FROM tab0 AS cor0
----
100
19
51

query I rowsort
SELECT DISTINCT + col0 * - col0 * col1 + - col0 + col2 * + col0 FROM tab2 AS cor0
----
-103174
-1337
-357006

query I rowsort
SELECT + 9 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

query I rowsort
SELECT cor0.col2 - - 26 * + cor1.col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 52c5ff2490f8b04ecb3bfd38220e2d70

query I rowsort
SELECT + tab2.col2 + ( 3 ) FROM tab2, tab0 cor0
----
9 values hashing to 09b81aa37f23915f471d2a1280432bbd

onlyif mysql # use DIV operator for integer division
query I rowsort label-9991
SELECT DISTINCT col1 DIV + col1 col0 FROM tab1
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9991
SELECT DISTINCT col1 / + col1 col0 FROM tab1
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - 88 col1 FROM tab1 AS cor0
----
-4752
-5016
-8448

query I rowsort
SELECT + col2 * + 53 FROM tab2 AS cor0
----
1378
1431
2014

query I rowsort
SELECT + + col1 * 52 AS col0 FROM tab1 cor0
----
1352
520
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-9995
SELECT + col0 DIV + col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9995
SELECT + col0 / + col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL + + 4 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9998
SELECT CAST( NULL AS SIGNED ) * - ( col2 ) 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-9998
SELECT CAST ( NULL AS INTEGER ) * - ( col2 ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + + col0 + - col0 FROM tab0 AS cor0
----
1
33
82

