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 - + 75 * col2 FROM tab1 AS cor0
----
-4050
-4275
-7200

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

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

query I rowsort
SELECT DISTINCT + 32 + cor0.col1 AS col0 FROM tab0 AS cor0
----
118
123
129

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-6
SELECT DISTINCT - col0 * col2 + + col0 DIV col1 AS col2 FROM tab1 AS cor0
----
-162
-3642
-7674

skipif mysql # not compatible
query I rowsort label-6
SELECT DISTINCT - col0 * col2 + + col0 / col1 AS col2 FROM tab1 AS cor0
----
-162
-3642
-7674

query I rowsort
SELECT ALL - 56 FROM tab0 cor0
----
-56
-56
-56

query I rowsort
SELECT + - col2 * + col0 + col2 * + 66 AS col0 FROM tab1 AS cor0
----
-1344
114
3402

query I rowsort
SELECT DISTINCT 81 + + col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
179
200
254

query I rowsort
SELECT + + 48 + col1 FROM tab0 AS cor0
----
134
139
145

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 98 * - col2 col2 FROM tab2
----
-2548
-2646
-3724

query I rowsort
SELECT - 0 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-14
SELECT DISTINCT + 13 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-14
SELECT DISTINCT + 13 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 + + col0 + + col2 * cor0.col2 col0 FROM tab0 AS cor0
----
101
1178
6878

query I rowsort
SELECT ALL col2 * + col2 * + 84 + + col0 + col0 AS col2 FROM tab2 AS cor0
----
121454
56940
61250

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

query I rowsort
SELECT ALL - - 4 FROM tab0 cor0
----
4
4
4

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-20
SELECT - + 40 * cor0.col1 DIV ( - col0 ) + col1 * col0 AS col1 FROM tab0 AS cor0
----
2207
3505
8139

skipif mysql # not compatible
query I rowsort label-20
SELECT - + 40 * cor0.col1 / ( - col0 ) + col1 * col0 AS col1 FROM tab0 AS cor0
----
2207
3505
8139

query I rowsort
SELECT ALL + ( - col1 ) + cor0.col2 * + 56 AS col0 FROM tab2 AS cor0
----
1397
1481
2111

query I rowsort
SELECT DISTINCT 15 - col2 AS col2 FROM tab2 AS cor0
----
-11
-12
-23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( - 46 ) col2 FROM tab2 AS cor0
----
-15
-29
13

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

query I rowsort
SELECT ALL + col0 * - col1 - 8 AS col2 FROM tab0 AS cor0
----
-2072
-3403
-8107

query I rowsort
SELECT DISTINCT cor0.col0 * - ( + col2 ) + + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-28
SELECT ALL - cor0.col1 * - 4 + + col1 DIV - col1 - col2 * col1 AS col2 FROM tab1 AS cor0
----
-1197
-1301
-531

skipif mysql # not compatible
query I rowsort label-28
SELECT ALL - cor0.col1 * - 4 + + col1 / - col1 - col2 * col1 AS col2 FROM tab1 AS cor0
----
-1197
-1301
-531

query I rowsort
SELECT ALL - col1 * + col1 + - col0 * col2 FROM tab1 cor0
----
-3748
-7849
-838

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

skipif mysql # not compatible
query I rowsort label-30
SELECT ALL tab0.col1 / col2 + + col1 AS col0 FROM tab0
----
194
88
92

query I rowsort
SELECT ALL - 25 + col1 AS col2 FROM tab2
----
-8
34
6

query I rowsort
SELECT - 81 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

query I rowsort
SELECT ALL 16 + col2 FROM tab2
----
42
43
54

query I rowsort
SELECT DISTINCT + 66 + - col1 * + col1 AS col2 FROM tab2 AS cor0
----
-223
-3415
-895

query I rowsort
SELECT - 55 * col0 FROM tab0 AS cor0
----
-1320
-1925
-4895

query I rowsort
SELECT ALL col1 - - col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT - 68 * + col1 FROM tab0 cor0
----
-5848
-6188
-6596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 31 col0 FROM tab0 AS cor0
----
-1023
-2542
-31

query I rowsort
SELECT ALL - + 20 * col0 AS col2 FROM tab2 AS cor0
----
-140
-1560
-1580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 17 col1 FROM tab2 AS cor0
----
-17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * cor0.col2 col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-42
SELECT DISTINCT - col2 DIV 36 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-42
SELECT DISTINCT - col2 / 36 FROM tab2 AS cor0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-43
SELECT + CAST( 93 AS SIGNED ) + + col1 FROM tab0 AS cor0
----
179
184
190

skipif mysql # not compatible
query I rowsort label-43
SELECT + CAST ( 93 AS INTEGER ) + + col1 FROM tab0 AS cor0
----
179
184
190

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

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

query I rowsort
SELECT DISTINCT - tab0.col2 - 91 FROM tab0
----
-124
-173
-92

query I rowsort
SELECT ALL 67 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT ALL - col2 + col0 - + 24 FROM tab0
----
-17
-33
10

query I rowsort
SELECT col0 * - 62 AS col2 FROM tab2 AS cor0
----
-434
-4836
-4898

query I rowsort
SELECT ALL col0 + + col2 + col1 AS col2 FROM tab2
----
134
163
65

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

query I rowsort
SELECT ALL - ( col0 ) + - col0 * tab2.col1 FROM tab2
----
-1422
-224
-4680

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

query I rowsort
SELECT ALL + - col0 * 74 FROM tab0 AS cor0
----
-1776
-2590
-6586

query I rowsort
SELECT col1 * - tab2.col0 * ( col2 * + ( + tab2.col2 ) ) AS col2 FROM tab2
----
-158193
-1939292
-3110952

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col1 col2 FROM tab1
----
20
26
52

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

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

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

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

skipif mysql # not compatible
query I rowsort label-60
SELECT DISTINCT - col0 / - cor0.col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 87 * - tab0.col2 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 21ec97af99d455c3bcc29fdf779cddbe

query I rowsort
SELECT ALL + 38 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
134
92
95

query I rowsort
SELECT DISTINCT 77 + + col2 * - col0 AS col1 FROM tab2 AS cor0
----
-112
-1951
-2925

query I rowsort
SELECT + - col0 * 29 FROM tab2 cor0
----
-203
-2262
-2291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 49 ) col0 FROM tab1
----
49
49
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-66
SELECT ALL 35 DIV - tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to ccd77e2770d5a834e59c1674defa88fa

skipif mysql # not compatible
query I rowsort label-66
SELECT ALL 35 / - tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to ccd77e2770d5a834e59c1674defa88fa

query I rowsort
SELECT + 14 + cor0.col2 * col2 FROM tab0 AS cor0
----
1103
15
6738

onlyif mysql # use DIV operator for integer division
query I rowsort label-68
SELECT + col0 + 30 DIV - col0 col1 FROM tab0 AS cor0
----
23
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-68
SELECT + col0 + 30 / - col0 col1 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT - 65 * - col0 - + ( col1 + + col0 ) AS col2 FROM tab0 AS cor0
----
1450
2143
5605

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

query I rowsort
SELECT DISTINCT + col2 * col0 + - cor0.col1 * col2 AS col0 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT ALL ( + col0 ) * 31 + col0 * cor0.col0 * col1 + 30 FROM tab0 AS cor0
----
119940
50310
723600

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

query I rowsort
SELECT ALL - - col0 - col0 * - 6 * - col0 FROM tab0 cor0
----
-3432
-47437
-7315

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-76
SELECT ALL - col2 DIV col1 + col2 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
-1
-4
-6

skipif mysql # not compatible
query I rowsort label-76
SELECT ALL - col2 / col1 + col2 / cor0.col2 AS col1 FROM tab1 AS cor0
----
-1
-4
-6

query I rowsort
SELECT DISTINCT + 19 * - col1 + + cor0.col0 + col2 FROM tab1 AS cor0
----
-437
-69
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-78
SELECT DISTINCT - col2 DIV + col0 + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7395
8281
9409

skipif mysql # not compatible
query I rowsort label-78
SELECT DISTINCT - col2 / + col0 + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7395
8281
9409

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * - col0 + - col0 col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL col2 * + col1 + col1 * 77 FROM tab1 AS cor0
----
1340
2249
3406

query I rowsort
SELECT ALL - col1 * ( + 89 ) AS col2 FROM tab2 cor0
----
-1513
-2759
-5251

onlyif mysql # use DIV operator for integer division
query I rowsort label-83
SELECT - col2 + col0 DIV col2 AS col0 FROM tab1 cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-83
SELECT - col2 + col0 / col2 AS col0 FROM tab1 cor0
----
-54
-56
-96

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

query I rowsort
SELECT col0 + - 26 FROM tab0 AS cor0
----
-2
63
9

query I rowsort
SELECT + col0 * cor0.col0 - - 61 FROM tab2 cor0
----
110
6145
6302

query I rowsort
SELECT - + col2 * cor0.col1 + - col0 - + col0 FROM tab0 AS cor0
----
-167
-2886
-7640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * cor0.col1 * - col0 col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

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

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

query I rowsort
SELECT DISTINCT + col0 * - 33 * col1 FROM tab2 cor0
----
-151866
-44319
-7161

query I rowsort
SELECT + col1 * col2 * - tab2.col0 + col1 FROM tab2
----
-119593
-51017
-5828

query I rowsort
SELECT 82 + tab0.col0 AS col1 FROM tab0
----
106
117
171

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

query I rowsort
SELECT + cor0.col1 + ( cor0.col2 ) * - col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + 24 * col1 + col2 AS col0 FROM tab0 AS cor0
----
2097
2266
2329

query I rowsort
SELECT ALL + 39 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT ALL - col1 * tab2.col2 * + col1 AS col2 FROM tab2
----
-10982
-25947
-90506

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

query I rowsort
SELECT + 68 FROM tab1 cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 cor2, tab1 AS cor3
----
243 values hashing to f36bcae7ad15cdbb1390b15019db66cb

query I rowsort
SELECT DISTINCT tab0.col0 + tab0.col2 * + 20 FROM tab0, tab2 cor0
----
1729
55
684

query I rowsort
SELECT - - 57 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-6027
-6184
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 83 col0 FROM tab1
----
83
83
83

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

skipif mysql # not compatible
query I rowsort label-103
SELECT DISTINCT col2 * - tab0.col0 * - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT - - ( col0 ) * - 78 AS col2 FROM tab2 AS cor0
----
-546
-6084
-6162

query I rowsort
SELECT - + 15 + - col0 AS col0 FROM tab1 AS cor0
----
-18
-79
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) col2 FROM tab2 cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-107
SELECT ALL col2 DIV - col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-107
SELECT ALL col2 / - col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 * + col0 + + 65 + + 31 col0 FROM tab2 AS cor0
----
1439
313
4698

query I rowsort
SELECT - col1 + - col0 * - col0 FROM tab2
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - col0 * + col0 col0 FROM tab0
----
-13824
-42875
-704969

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

query I rowsort
SELECT tab0.col2 * - col0 FROM tab0 WHERE col1 * + col2 IN ( - col0 )
----

query I rowsort
SELECT ALL col0 + + col2 * col1 * + col0 FROM tab0
----
3430
664207
68136

query I rowsort
SELECT 52 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT DISTINCT ( col2 ) * ( 39 ) AS col1 FROM tab1
----
2106
2223
3744

query I rowsort
SELECT + col0 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT - col2 * + tab1.col2 * + tab1.col1 FROM tab1 WHERE col1 BETWEEN NULL AND - col0
----

query I rowsort
SELECT DISTINCT + col0 + - col1 * - col1 AS col1 FROM tab0 WHERE NOT - col1 * col2 * col2 NOT BETWEEN - col0 AND NULL
----

query I rowsort
SELECT col1 * + tab0.col0 * - col2 - col1 * - col2 FROM tab0
----
-3298
-65274
-656656

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col1 * - col1 * + col1 = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-121
SELECT ALL - col0 DIV + col0 col2 FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-121
SELECT ALL - col0 / + col0 col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL col2 + + col0 + - col1 * tab1.col1 FROM tab1
----
-619
21
7

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

query I rowsort
SELECT col2 + + col2 + - col0 AS col1 FROM tab0
----
-33
42
75

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

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

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

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

query I rowsort
SELECT col1 AS col1 FROM tab0 WHERE NOT NULL NOT IN ( col2 )
----

query I rowsort
SELECT ALL col1 * - col2 + - col2 * - col1 FROM tab0 WHERE NOT ( + col2 + + col2 ) NOT BETWEEN col1 AND NULL
----

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

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

query I rowsort
SELECT tab0.col1 + col0 + - col2 AS col2 FROM tab0
----
131
77
98

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col0 + - col1 * col0 <= col0
----

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-138
SELECT DISTINCT col0 + + 62 DIV tab0.col0 FROM tab0
----
26
36
89

skipif mysql # not compatible
query I rowsort label-138
SELECT DISTINCT col0 + + 62 / tab0.col0 FROM tab0
----
26
36
89

query I rowsort
SELECT + 17 * col2 FROM tab2
----
442
459
646

query I rowsort
SELECT tab0.col0 - - col1 * - col0 AS col2 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - col1 + - col1 * - col1 + + col0 * col2 FROM tab1
----
3738
7836
812

query I rowsort
SELECT + - cor0.col1 * 70 AS col2 FROM tab0 AS cor0
----
-6020
-6370
-6790

query I rowsort
SELECT + col1 * 80 AS col2 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT DISTINCT + 65 * col0 - + cor0.col0 FROM tab1 AS cor0
----
192
4096
5120

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

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

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

query I rowsort
SELECT + 2 + - col0 * 10 AS col1 FROM tab2 AS cor0
----
-68
-778
-788

query I rowsort
SELECT DISTINCT - + 45 + cor0.col2 * col2 FROM tab1 AS cor0
----
2871
3204
9171

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

query I rowsort
SELECT DISTINCT - col1 + cor0.col2 - - ( + 96 ) AS col1 FROM tab2 cor0
----
117
63
92

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

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

query I rowsort
SELECT DISTINCT + 33 * cor0.col0 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT 56 + col0 AS col0 FROM tab2 cor0
----
134
135
63

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

query I rowsort
SELECT - 4 * + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 54fe2011393c3e49b7fc4bc423d08ff1

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-157
SELECT DISTINCT + col0 * col1 DIV 24 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
176
426

skipif mysql # not compatible
query I rowsort label-157
SELECT DISTINCT + col0 * col1 / 24 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
176
426

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 48 * + col1 col0 FROM tab1 cor0
----
1248
480
624

query I rowsort
SELECT ALL + - col1 * col2 + 89 FROM tab2 AS cor0
----
-1445
-557
-748

skipif mysql # not compatible
query I rowsort
SELECT ALL + col1 + CAST ( col0 AS REAL ) + + col1 AS col0 FROM tab2 AS cor0
----
113
196
69

query I rowsort
SELECT DISTINCT + cor0.col2 - 78 FROM tab2 AS cor0
----
-40
-51
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 + col2 col0 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + - col0 * - 21 AS col2 FROM tab2 AS cor0
----
147
1638
1659

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-166
SELECT - col1 * - CAST( 46 AS SIGNED ) FROM tab0 AS cor0
----
3956
4186
4462

skipif mysql # not compatible
query I rowsort label-166
SELECT - col1 * - CAST ( 46 AS INTEGER ) FROM tab0 AS cor0
----
3956
4186
4462

query I rowsort
SELECT DISTINCT - col1 * col2 * + col1 AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT + + 11 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

onlyif mysql # use DIV operator for integer division
query I rowsort label-169
SELECT DISTINCT - col1 - col2 DIV + col1 FROM tab2 AS cor0
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-169
SELECT DISTINCT - col1 - col2 / + col1 FROM tab2 AS cor0
----
-19
-31
-59

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-170
SELECT DISTINCT + col2 / - 77 col1 FROM tab0 cor0
----
-1
0

query I rowsort
SELECT col1 * 4 FROM tab2 AS cor0
----
124
236
68

query I rowsort
SELECT + cor0.col2 * ( col2 ) * + col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL + col1 * 34 FROM tab2 AS cor0
----
1054
2006
578

query I rowsort
SELECT + ( 96 ) AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to e03080212e3345d8b37e64e3264019c4

query I rowsort
SELECT DISTINCT - 52 + - ( - col1 ) AS col2 FROM tab2 AS cor0
----
-21
-35
7

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 + cor0.col0 col0 FROM tab2, tab0 cor0
----
9 values hashing to 59e54cb75dbf95e96586d48d3c33f721

query I rowsort
SELECT 15 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT DISTINCT - 43 * 39 AS col2 FROM tab2, tab1 AS cor0
----
-1677

onlyif mysql # use DIV operator for integer division
query I rowsort label-181
SELECT + col1 DIV - col1 + + 30 AS col0 FROM tab2
----
29
29
29

skipif mysql # not compatible
query I rowsort label-181
SELECT + col1 / - col1 + + 30 AS col0 FROM tab2
----
29
29
29

query I rowsort
SELECT + col2 + - col0 * - col2 * + col2 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT tab1.col2 + + 92 * col2 FROM tab1
----
5022
5301
8928

onlyif mysql # use DIV operator for integer division
query I rowsort label-184
SELECT DISTINCT + tab1.col0 + - col2 DIV + col1 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-184
SELECT DISTINCT + tab1.col0 + - col2 / + col1 FROM tab1
----
1
59
73

query I rowsort
SELECT - - col2 * + col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-186
SELECT + - col0 + col2 DIV - col2 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-186
SELECT + - col0 + col2 / - col2 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT ALL - 98 + col2 + - col0 * col0 AS col2 FROM tab1
----
-4137
-53
-6402

query I rowsort
SELECT DISTINCT tab1.col1 + col2 + + col0 FROM tab1
----
131
189
83

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-190
SELECT DISTINCT - 4 * 47 DIV col0 + + col2 + - col1 col0 FROM tab2
----
-30
-35
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-190
SELECT DISTINCT - 4 * 47 / col0 + + col2 + - col1 col0 FROM tab2
----
-30
-35
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT col1 + 48 * + col2 AS col2 FROM tab2
----
1307
1327
1841

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-193
SELECT DISTINCT CAST( col0 AS SIGNED ) * col1 + + col2 FROM tab0
----
2097
3396
8181

skipif mysql # not compatible
query I rowsort label-193
SELECT DISTINCT CAST ( col0 AS INTEGER ) * col1 + + col2 FROM tab0
----
2097
3396
8181

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-195
SELECT + 33 + - 52 * col0 * col0 + col2 * col2 DIV + col0 FROM tab1
----
-212909
-332652
537

skipif mysql # not compatible
query I rowsort label-195
SELECT + 33 + - 52 * col0 * col0 + col2 * col2 / + col0 FROM tab1
----
-212909
-332652
537

query I rowsort
SELECT 48 * col0 AS col1 FROM tab2
----
336
3744
3792

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

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

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

query I rowsort
SELECT - cor0.col1 * - col1 + col0 * + col0 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
1041
6547
9624

query I rowsort
SELECT - 42 * - col1 - col1 AS col0 FROM tab2 AS cor0
----
1271
2419
697

query I rowsort
SELECT + col1 + col1 + + col1 * col1 AS col0 FROM tab2 cor0
----
1023
323
3599

query I rowsort
SELECT ALL - - 36 * col1 AS col1 FROM tab2 AS cor0
----
1116
2124
612

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

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

query I rowsort
SELECT ALL + col1 * ( + 88 ) AS col0 FROM tab1
----
1144
2288
880

query I rowsort
SELECT DISTINCT col0 * col1 + - col2 * - col1 AS col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT DISTINCT - col0 + - 3 * + 37 * - col0 FROM tab2 AS cor0
----
770
8580
8690

onlyif mysql # use DIV operator for integer division
query I rowsort label-208
SELECT ALL col1 DIV col1 + - 42 * cor0.col2 - + col1 AS col1 FROM tab0 AS cor0
----
-138
-1471
-3534

skipif mysql # not compatible
query I rowsort label-208
SELECT ALL col1 / col1 + - 42 * cor0.col2 - + col1 AS col1 FROM tab0 AS cor0
----
-138
-1471
-3534

query I rowsort
SELECT + col0 * + 84 AS col2 FROM tab1 cor0
----
252
5376
6720

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

query I rowsort
SELECT DISTINCT + - col1 + col0 * + col0 * col1 + - cor0.col1 FROM tab1 AS cor0
----
182
40940
83174

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 * col0 col0 FROM tab0 AS cor0
----
1152
1680
4272

onlyif mysql # use DIV operator for integer division
query I rowsort label-214
SELECT col2 DIV 97 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-214
SELECT col2 / 97 AS col2 FROM tab1 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT ALL - col2 + - col2 FROM tab2 AS cor0 WHERE NOT NULL IN ( col2 - - col0 / + col2 )
----

query I rowsort
SELECT DISTINCT col1 + - col0 + cor0.col2 FROM tab0 cor0
----
63
84
95

query I rowsort
SELECT - - col2 * - col2 * - col2 AS col0 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT + 31 + col0 + - col0 * col2 AS col1 FROM tab1
----
-128
-3553
-7569

query I rowsort
SELECT ALL + col0 + - ( - col1 * tab1.col2 ) FROM tab1
----
1328
1407
634

query I rowsort
SELECT col0 * 85 - 82 FROM tab1 AS cor0
----
173
5358
6718

query I rowsort
SELECT + - col1 * + 11 + - col0 FROM tab2 AS cor0
----
-266
-348
-727

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

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

query I rowsort
SELECT ALL + - col1 * col0 * col0 + col2 FROM tab0 AS cor0
----
-118824
-49503
-720729

query I rowsort
SELECT DISTINCT + col1 + + col2 * - col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - cor0.col0 + + 82 * + cor0.col2 * + cor0.col2 col2 FROM tab2 AS cor0
----
124649
59827
61516

query I rowsort
SELECT ALL + cor0.col0 * ( + 12 ) * col0 - ( + 27 ) * - col1 FROM tab2 AS cor0
----
1425
74601
75351

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 + col2 col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - col0 * - 27 FROM tab0 AS cor0
----
2403
648
945

query I rowsort
SELECT DISTINCT - + col2 * col0 + + col2 * - col2 AS col2 FROM tab0 AS cor0
----
-14022
-1881
-36

query I rowsort
SELECT DISTINCT + col2 * 12 + + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1213
-180
-6937

query I rowsort
SELECT col0 * ( cor0.col2 ) + + cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
378
4056
6004

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( - 15 AS REAL ) * col1 + - col1 FROM tab0 cor0
----
-1376
-1456
-1552

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

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

query I rowsort
SELECT ALL + - col0 * col0 + - col2 FROM tab1 AS cor0
----
-4153
-63
-6496

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 cor1, tab0, tab0 cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

onlyif mysql # use DIV operator for integer division
query I rowsort label-242
SELECT + + col1 DIV col1 + col1 * + col1 FROM tab1 cor0
----
101
170
677

skipif mysql # not compatible
query I rowsort label-242
SELECT + + col1 / col1 + col1 * + col1 FROM tab1 cor0
----
101
170
677

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

query I rowsort
SELECT ALL + - 10 + - cor0.col0 FROM tab1 AS cor0
----
-13
-74
-90

query I rowsort
SELECT ALL - col0 + - 51 FROM tab2 AS cor0
----
-129
-130
-58

query I rowsort
SELECT 92 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT DISTINCT - ( - col2 ) + col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - - col2 + col0 * col0 AS col2 FROM tab1 cor0
----
4153
63
6496

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 col2 FROM tab1, tab0 cor0 CROSS JOIN tab0 AS cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

query I rowsort
SELECT 17 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT ALL + 65 + + cor0.col1 FROM tab1 AS cor0
----
75
78
91

query I rowsort
SELECT DISTINCT cor0.col1 * - cor0.col1 FROM tab1, tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + 98 * - col1 * col0 AS col2 FROM tab0 AS cor0
----
-202272
-332710
-793702

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

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

skipif mysql # not compatible
query I rowsort label-256
SELECT ALL - col0 * - CAST ( + col1 AS INTEGER ) - col0 FROM tab2 cor0
----
1264
210
4524

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

skipif mysql # not compatible
query I rowsort label-257
SELECT DISTINCT col0 + CAST ( NULL AS REAL ) - - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-258
SELECT ALL + col1 + CAST( - col1 AS SIGNED ) * - col2 * - 26 FROM tab1 AS cor0
----
-14810
-32435
-36478

skipif mysql # not compatible
query I rowsort label-258
SELECT ALL + col1 + CAST ( - col1 AS INTEGER ) * - col2 * - 26 FROM tab1 AS cor0
----
-14810
-32435
-36478

query I rowsort
SELECT DISTINCT 21 AS col1 FROM tab1
----
21

query I rowsort
SELECT col1 * tab1.col0 + - 77 AS col2 FROM tab1
----
1
563
963

query I rowsort
SELECT + tab0.col1 + 27 FROM tab0, tab0 AS cor0
----
9 values hashing to b8e63e39b3b41774687651a57fe76e61

onlyif mysql # use DIV operator for integer division
query I rowsort label-262
SELECT ALL - col0 DIV - col2 - + col1 FROM tab0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-262
SELECT ALL - col0 / - col2 - + col1 FROM tab0
----
-62
-86
-90

query I rowsort
SELECT col2 + col2 + col1 AS col2 FROM tab0
----
152
255
99

query I rowsort
SELECT ALL - 42 AS col2 FROM tab1
----
-42
-42
-42

query I rowsort
SELECT 76 * 84 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d9b2494a1e5e997f3e969dbba2d1060b

query I rowsort
SELECT 4 - - col2 AS col2 FROM tab2
----
30
31
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-267
SELECT col1 + + 4 DIV - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-267
SELECT col1 + + 4 / - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL col2 * col1 * col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT DISTINCT col2 + - col2 * 44 FROM tab1
----
-2322
-2451
-4128

query I rowsort
SELECT DISTINCT col1 * - 18 + - 75 + col1 FROM tab2
----
-1078
-364
-602

onlyif mysql # use DIV operator for integer division
query I rowsort label-271
SELECT - col0 DIV ( + 60 * col2 + + ( - col0 ) ) FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-271
SELECT - col0 / ( + 60 * col2 + + ( - col0 ) ) FROM tab0
----
-1
0
0

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

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

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

query I rowsort
SELECT + 60 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT - 72 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT - col2 * col1 - col2 * col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

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

query I rowsort
SELECT ALL 47 * + 47 FROM tab1
----
2209
2209
2209

query I rowsort
SELECT DISTINCT col1 * col1 + - col2 AS col2 FROM tab0 AS cor0
----
7363
8199
9408

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col1 AS REAL ) AS col2 FROM tab1
----
10
13
26

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

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

query I rowsort
SELECT DISTINCT + col1 * - col1 + col2 * 4 * cor0.col2 + 33 AS col1 FROM tab2 AS cor0
----
-744
1988
5520

query I rowsort
SELECT 57 * col1 FROM tab0 AS cor0
----
4902
5187
5529

onlyif mysql # use DIV operator for integer division
query I rowsort label-285
SELECT ALL + col0 + col2 DIV + col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-285
SELECT ALL + col0 + col2 / + col0 FROM tab1 AS cor0
----
21
64
81

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-287
SELECT - ( + cor0.col2 ) + + col2 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-287
SELECT - ( + cor0.col2 ) + + col2 / cor0.col1 AS col1 FROM tab2 AS cor0
----
-26
-27
-36

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

query I rowsort
SELECT - 86 + - cor0.col2 * col1 FROM tab2 AS cor0
----
-1620
-732
-923

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

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

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

query I rowsort
SELECT + + col0 + - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

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

skipif mysql # not compatible
query I rowsort label-294
SELECT - ( col1 ) * + ( ( col0 ) ) + + CAST ( + col2 AS INTEGER ) * + col1 AS col2 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT 44 + - col2 + tab0.col0 FROM tab0
----
35
51
78

query I rowsort
SELECT DISTINCT 72 * col1 + col1 * + ( + tab1.col2 ) * col1 FROM tab1
----
17160
38376
6420

query I rowsort
SELECT - + 22 * cor0.col2 + 53 * col0 AS col0 FROM tab0 AS cor0
----
1833
2913
546

query I rowsort
SELECT - - 79 - col0 AS col2 FROM tab1 AS cor0
----
-1
15
76

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

query I rowsort
SELECT + tab2.col0 + 16 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 53c25b7052cbb3298b89c94a5bb072ef

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

query I rowsort
SELECT DISTINCT - cor0.col0 * + 17 AS col2 FROM tab0 AS cor0
----
-1513
-408
-595

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

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

query I rowsort
SELECT 66 - - col1 FROM tab1
----
76
79
92

query I rowsort
SELECT + col0 * - col0 * - ( - col1 ) + - col1 FROM tab0
----
-118922
-49622
-720902

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-309
SELECT + col0 DIV - col1 + 81 AS col1 FROM tab0 cor0
----
81
81
81

skipif mysql # not compatible
query I rowsort label-309
SELECT + col0 / - col1 + 81 AS col1 FROM tab0 cor0
----
81
81
81

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 15 col0 FROM tab0
----
1335
360
525

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 84 ) * col1 * col0 + ( col1 + col2 ) col1 FROM tab2 cor0
----
112867
18286
386653

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

skipif mysql # not compatible
query I rowsort label-313
SELECT ALL CAST ( NULL AS INTEGER ) + + 24 / - col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 22 + col1 + col0 * col2 AS col0 FROM tab2 AS cor0
----
2109
242
3041

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-315
SELECT DISTINCT - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-315
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-316
SELECT DISTINCT - col0 * 49 + cor0.col1 DIV + col0 AS col1 FROM tab1 AS cor0
----
-139
-3136
-3920

skipif mysql # not compatible
query I rowsort label-316
SELECT DISTINCT - col0 * 49 + cor0.col1 / + col0 AS col1 FROM tab1 AS cor0
----
-139
-3136
-3920

query I rowsort
SELECT DISTINCT + col2 * + 93 FROM tab1
----
5022
5301
8928

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

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

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

query I rowsort
SELECT + ( - tab2.col0 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + - 35 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 7fbbc209618bf287c81172ef2c617496

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

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

query I rowsort
SELECT - ( + 84 ) * - col2 FROM tab0 AS cor0
----
2772
6888
84

query I rowsort
SELECT - ( 12 ) + col1 * cor0.col2 AS col1 FROM tab0 cor0
----
2826
7450
85

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

query I rowsort
SELECT - 33 + - col0 AS col1 FROM tab1 AS cor0
----
-113
-36
-97

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

query I rowsort
SELECT - col2 + 62 AS col2 FROM tab2 AS cor0
----
24
35
36

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-330
SELECT + + col0 * CAST( + col0 AS SIGNED ) + - col0 + - col1 AS col0 FROM tab1 AS cor0
----
-20
4022
6307

skipif mysql # not compatible
query I rowsort label-330
SELECT + + col0 * CAST ( + col0 AS INTEGER ) + - col0 + - col1 AS col0 FROM tab1 AS cor0
----
-20
4022
6307

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

query I rowsort
SELECT - col0 + - col2 - + col2 AS col0 FROM tab1
----
-111
-178
-272

query I rowsort
SELECT ALL 19 AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to 39241ace4c29d5a55052e1665aa36823

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 92 + + col0 * - ( + col2 + col0 ) * + col0 col0 FROM tab1 AS cor0
----
-1126308
-421
-495524

query I rowsort
SELECT 62 * - col1 * tab1.col1 FROM tab1
----
-10478
-41912
-6200

query I rowsort
SELECT - 73 * - col0 AS col1 FROM tab1 cor0
----
219
4672
5840

query I rowsort
SELECT DISTINCT + 33 * col2 FROM tab2 AS cor0
----
1254
858
891

query I rowsort
SELECT + + ( col1 ) + - cor0.col2 * col1 + col2 FROM tab0 AS cor0
----
-2719
-7289
1

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

query I rowsort
SELECT - - col1 * 43 FROM tab0 AS cor0
----
3698
3913
4171

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

query I rowsort
SELECT - cor0.col2 * 53 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to e3ba3bfa79647e11f25b0f500737aebb

query I rowsort
SELECT col1 + cor0.col1 * 47 FROM tab1 AS cor0
----
1248
480
624

query I rowsort
SELECT ALL + - col2 * + 55 * col2 + col1 FROM tab0 AS cor0
----
-369729
-59809
42

query I rowsort
SELECT col0 * col0 + cor0.col0 FROM tab0 AS cor0
----
1260
600
8010

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

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

query I rowsort
SELECT ALL 70 * ( - col0 ) + col1 - - col0 * - cor0.col2 FROM tab1 AS cor0
----
-13267
-346
-8118

query I rowsort
SELECT DISTINCT col2 * + 34 + col0 AS col2 FROM tab1 AS cor0
----
1839
2002
3344

query I rowsort
SELECT ALL + + ( 78 ) AS col1 FROM tab1 AS cor0
----
78
78
78

query I rowsort
SELECT DISTINCT - - 29 + + cor0.col1 FROM tab1 AS cor0
----
39
42
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-354
SELECT ALL + + ( + 52 ) DIV + col0 AS col1 FROM tab1 AS cor0
----
0
0
17

skipif mysql # not compatible
query I rowsort label-354
SELECT ALL + + ( + 52 ) / + col0 AS col1 FROM tab1 AS cor0
----
0
0
17

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-356
SELECT DISTINCT + col2 DIV cor0.col1 + + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-356
SELECT DISTINCT + col2 / cor0.col1 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - 74 * col0 - + col0 * ( col1 ) FROM tab1 AS cor0
----
-300
-5376
-6960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 21 * cor0.col2 col1 FROM tab2 AS cor0
----
572
594
836

query I rowsort
SELECT DISTINCT - col2 + + 33 AS col1 FROM tab0 AS cor0
----
-49
0
32

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

query I rowsort
SELECT tab1.col0 * 48 + + tab1.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to ff13040f6b219229be064453d93c2af6

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

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) - col0 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT - 73 - col0 * + col0 FROM tab1 AS cor0
----
-4169
-6473
-82

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

query I rowsort
SELECT DISTINCT 6 + 92 FROM tab2 AS cor0
----
98

query I rowsort
SELECT - col1 * - 29 + + col1 FROM tab0
----
2580
2730
2910

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

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

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

query I rowsort
SELECT + 88 * tab2.col1 FROM tab2, tab1, tab2 cor0
----
27 values hashing to d49f2ec4cff37f52a8fd0c3ee9c42d05

query I rowsort
SELECT - col0 + - cor0.col1 * + col2 + cor0.col2 * col2 AS col2 FROM tab2 AS cor0
----
-115
-936
719

query I rowsort
SELECT ALL - + col2 * col0 + 61 AS col1 FROM tab0 AS cor0
----
-7237
-731
26

query I rowsort
SELECT - col2 + col2 * ( + 75 ) + + col0 * - 64 FROM tab2
----
-2244
-3068
1550

query I rowsort
SELECT DISTINCT + col2 + + col0 * + ( + col2 ) FROM tab0
----
36
7380
825

query I rowsort
SELECT - col0 + col1 + + 27 AS col2 FROM tab2
----
-35
51
8

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-379
SELECT DISTINCT + CAST( - tab0.col0 AS SIGNED ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-379
SELECT DISTINCT + CAST ( - tab0.col0 AS INTEGER ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
-24
-35
-89

query I rowsort
SELECT - 44 - col1 AS col0 FROM tab2
----
-103
-61
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-381
SELECT col2 + 36 + + 13 DIV - col1 FROM tab1 AS cor0
----
131
90
92

skipif mysql # not compatible
query I rowsort label-381
SELECT col2 + 36 + + 13 / - col1 FROM tab1 AS cor0
----
131
90
92

query I rowsort
SELECT + - col0 + - 73 FROM tab0 AS cor0
----
-108
-162
-97

query I rowsort
SELECT ALL col0 * 20 AS col1 FROM tab0 AS cor0
----
1780
480
700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + 40 * col1 col2 FROM tab2 AS cor0
----
1429
3682
4388

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + + cor1.col1 col0 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 2b5ce14343793e82b2c07b009299e0dd

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

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

query I rowsort
SELECT DISTINCT 86 * - col0 AS col1 FROM tab2
----
-602
-6708
-6794

query I rowsort
SELECT ALL - col1 + + col1 * - cor0.col1 + cor0.col0 * col1 AS col0 FROM tab1 AS cor0
----
-624
530
858

query I rowsort
SELECT + col1 * + 31 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT col1 * - col0 + + col0 * - 32 FROM tab1
----
-174
-2688
-3600

query I rowsort
SELECT 97 + col2 FROM tab0
----
130
179
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col2 * + 86 + col2 ) col2 FROM tab2
----
-2210
-2295
-3230

query I rowsort
SELECT + col1 + 52 FROM tab1 AS cor0
----
62
65
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-394
SELECT DISTINCT CAST( 82 AS SIGNED ) * - col1 col1 FROM tab0 AS cor0
----
-7052
-7462
-7954

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-394
SELECT DISTINCT CAST ( 82 AS INTEGER ) * - col1 col1 FROM tab0 AS cor0
----
-7052
-7462
-7954

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

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

query I rowsort
SELECT DISTINCT + col1 * + 81 FROM tab0 AS cor0
----
6966
7371
7857

query I rowsort
SELECT ALL - 74 + + col0 * + col2 AS col0 FROM tab1 AS cor0
----
3574
7606
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-398
SELECT ALL + - CAST( 10 AS SIGNED ) - col1 * col0 * - col0 AS col0 FROM tab1 AS cor0
----
224
40950
83190

skipif mysql # not compatible
query I rowsort label-398
SELECT ALL + - CAST ( 10 AS INTEGER ) - col1 * col0 * - col0 AS col0 FROM tab1 AS cor0
----
224
40950
83190

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

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

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

query I rowsort
SELECT DISTINCT + col0 * 8 FROM tab1 cor0
----
24
512
640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-402
SELECT - CAST( ( col0 ) AS SIGNED ) + - col0 FROM tab0 AS cor0
----
-178
-48
-70

skipif mysql # not compatible
query I rowsort label-402
SELECT - CAST ( ( col0 ) AS INTEGER ) + - col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL + col0 * + 37 FROM tab1 AS cor0
----
111
2368
2960

query I rowsort
SELECT + cor0.col1 + - 95 * cor0.col0 FROM tab0 cor0
----
-2194
-3228
-8364

onlyif mysql # use DIV operator for integer division
query I rowsort label-405
SELECT col1 + + tab1.col0 + col0 DIV + col1 FROM tab1
----
29
80
99

skipif mysql # not compatible
query I rowsort label-405
SELECT col1 + + tab1.col0 + col0 / + col1 FROM tab1
----
29
80
99

query I rowsort
SELECT + ( + col2 ) - - col2 * - col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-407
SELECT - CAST( + 68 AS SIGNED ) + + col2 * + col2 * 16 FROM tab1 AS cor0
----
147388
46588
51916

skipif mysql # not compatible
query I rowsort label-407
SELECT - CAST ( + 68 AS INTEGER ) + + col2 * + col2 * 16 FROM tab1 AS cor0
----
147388
46588
51916

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 52 col1 FROM tab0
----
-17
-28
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-409
SELECT - cor0.col1 DIV - col0 + - ( - col2 ) FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-409
SELECT - cor0.col1 / - col0 + - ( - col2 ) FROM tab1 AS cor0
----
57
62
96

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

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

skipif mysql # not compatible
query I rowsort label-411
SELECT CAST ( NULL AS REAL ) + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + cor0.col1 * + 30 FROM tab2 AS cor0
----
1744
472
903

query I rowsort
SELECT - - col1 + col2 * col0 AS col2 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT ALL col2 * + col2 - ( - ( col2 ) + col2 ) FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-415
SELECT + col2 + + col0 DIV 33 FROM tab0 AS cor0
----
2
33
84

skipif mysql # not compatible
query I rowsort label-415
SELECT + col2 + + col0 / 33 FROM tab0 AS cor0
----
2
33
84

query I rowsort
SELECT DISTINCT + + 14 * + col0 FROM tab2 AS cor0
----
1092
1106
98

query I rowsort
SELECT DISTINCT + + col1 * - col2 + col0 + col2 AS col0 FROM tab2 AS cor0
----
-1430
-529
-803

query I rowsort
SELECT + + col0 * - col2 * col0 + - 96 + - col2 AS col1 FROM tab0 cor0
----
-1322
-19137
-649700

query I rowsort
SELECT - - 14 + + col0 * col0 + col1 FROM tab2 AS cor0
----
6157
6272
94

query I rowsort
SELECT - 77 * col0 * col2 FROM tab0 AS cor0
----
-2695
-561946
-60984

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

query I rowsort
SELECT + tab0.col0 * ( - 6 ) AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c1cb39ecaaec7164742d9e297b399b74

query I rowsort
SELECT - ( - cor0.col2 ) * + 13 FROM tab2 AS cor0
----
338
351
494

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

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

query I rowsort
SELECT - 49 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

onlyif mysql # use DIV operator for integer division
query I rowsort label-427
SELECT - col1 DIV + col0 + col0 * + col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
1381
240
4628

skipif mysql # not compatible
query I rowsort label-427
SELECT - col1 / + col0 + col0 * + col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
1381
240
4628

query I rowsort
SELECT - cor0.col2 * + cor0.col0 + + 6 * + 3 AS col0 FROM tab1 AS cor0
----
-144
-3630
-7662

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

query I rowsort
SELECT ALL - col1 * ( - col2 + + col0 ) FROM tab2
----
-3068
-697
620

query I rowsort
SELECT 68 + 73 FROM tab0, tab1 AS cor0
----
9 values hashing to f127c88dbadbed59c64310450c6f0695

query I rowsort
SELECT DISTINCT + col2 + 99 AS col0 FROM tab0 AS cor0
----
100
132
181

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-434
SELECT CAST( col1 * col1 AS SIGNED ) + col2 - + col0 AS col0 FROM tab2
----
248
3429
981

skipif mysql # not compatible
query I rowsort label-434
SELECT CAST ( col1 * col1 AS INTEGER ) + col2 - + col0 AS col0 FROM tab2
----
248
3429
981

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 * - col1 col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL 84 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT - col1 * + ( + col1 ) + 14 + col1 AS col1 FROM tab2 AS cor0
----
-258
-3408
-916

query I rowsort
SELECT - col0 - 0 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col0 ) * col0 col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - - col2 col1 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-441
SELECT DISTINCT + tab1.col2 - + col1 DIV col0 FROM tab1
----
46
57
96

skipif mysql # not compatible
query I rowsort label-441
SELECT DISTINCT + tab1.col2 - + col1 / col0 FROM tab1
----
46
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 + tab0.col1 * col2 + + col1 col0 FROM tab0
----
229
2948
7642

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

query I rowsort
SELECT col1 + - tab2.col0 * - tab2.col0 FROM tab2
----
6143
6258
80

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

query I rowsort
SELECT - col1 / + col0 AS col0 FROM tab2 WHERE NULL IN ( - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-447
SELECT col0 + + tab1.col2 DIV col1 col2 FROM tab1
----
5
69
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-447
SELECT col0 + + tab1.col2 / col1 col2 FROM tab1
----
5
69
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-448
SELECT DISTINCT - col1 - col0 DIV col2 FROM tab0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-448
SELECT DISTINCT - col1 - col0 / col2 FROM tab0
----
-132
-86
-92

query I rowsort
SELECT - col0 + + col2 * col1 AS col2 FROM tab0
----
2814
62
7373

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

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

query I rowsort
SELECT + col2 + col0 * col1 + - col0 * - col2 FROM tab0 AS cor0
----
15479
2889
3431

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

query III rowsort
SELECT * FROM tab1 WHERE col2 * col1 NOT IN ( col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

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

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

query I rowsort
SELECT col1 - - col1 AS col2 FROM tab0 WHERE + col1 >= ( + col1 )
----
172
182
194

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-458
SELECT ALL col0 DIV - col0 + col0 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-458
SELECT ALL col0 / - col0 + col0 FROM tab0
----
23
34
88

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + 9 col1 FROM tab2 AS cor0
----
16
87
88

query I rowsort
SELECT ALL col0 + 46 FROM tab2 AS cor0
----
124
125
53

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-463
SELECT DISTINCT + - col1 DIV CAST( + ( - col2 ) AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-463
SELECT DISTINCT + - col1 / CAST ( + ( - col2 ) AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT col0 * 1 + col0 * col1 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT col0 + + col1 + ( col1 ) AS col1 FROM tab0 cor0
----
196
229
271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * - 99 + - col1 col0 FROM tab1 AS cor0
----
-323
-6346
-7933

query I rowsort
SELECT cor0.col2 + 44 AS col2 FROM tab2 AS cor0
----
70
71
82

query I rowsort
SELECT DISTINCT + col1 + 45 FROM tab2 cor0
----
104
62
76

query I rowsort
SELECT + - col1 * 61 + - col1 AS col0 FROM tab1 AS cor0
----
-1612
-620
-806

query I rowsort
SELECT DISTINCT + col1 + 1 * col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL + 40 * col1 FROM tab2 AS cor0
----
1240
2360
680

onlyif mysql # use DIV operator for integer division
query I rowsort label-472
SELECT ALL 52 DIV + 51 + cor0.col1 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-472
SELECT ALL 52 / + 51 + cor0.col1 FROM tab1 cor0
----
11
14
27

query I rowsort
SELECT DISTINCT 18 * 70 + col2 * + col1 AS col2 FROM tab0 AS cor0
----
1357
4098
8722

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

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

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

query I rowsort
SELECT ALL - col1 + col2 * col0 FROM tab1 cor0
----
136
3638
7667

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

query I rowsort
SELECT 63 + col1 FROM tab1 AS cor0
----
73
76
89

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

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

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

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

query I rowsort
SELECT ALL + + col1 * 87 FROM tab1 cor0
----
1131
2262
870

query I rowsort
SELECT ALL + - cor0.col2 + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
43
622
73

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

query I rowsort
SELECT - col0 - 32 FROM tab2 cor0
----
-110
-111
-39

query I rowsort
SELECT ( tab2.col2 ) * - col0 + - col0 + - col2 * ( col1 ) AS col1 FROM tab2
----
-1033
-3640
-3727

onlyif mysql # use DIV operator for integer division
query I rowsort label-487
SELECT + col1 * col2 DIV CAST( col0 AS SIGNED ) + col2 AS col2 FROM tab2
----
146
45
46

skipif mysql # not compatible
query I rowsort label-487
SELECT + col1 * col2 / CAST ( col0 AS INTEGER ) + col2 AS col2 FROM tab2
----
146
45
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col2 * col1 * + col1 col1 FROM tab2
----
11061
25954
90584

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

query I rowsort
SELECT col2 + col2 * + tab1.col2 * + col1 FROM tab1
----
119904
32547
75870

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

query I rowsort
SELECT DISTINCT 68 + col1 AS col1 FROM tab0
----
154
159
165

query I rowsort
SELECT col2 * col0 + - col0 + col2 * + col0 FROM tab2 cor0
----
371
3978
5925

query I rowsort
SELECT col2 * + col0 + - col2 + col1 AS col0 FROM tab2 cor0
----
193
2061
2981

onlyif mysql # use DIV operator for integer division
query I rowsort label-495
SELECT DISTINCT + col2 DIV 32 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-495
SELECT DISTINCT + col2 / 32 FROM tab2
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) - + col2 col0 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT tab0.col1 + col0 * col2 AS col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT ( - tab0.col0 ) * + col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - ( + col1 ) * - col2 FROM tab0
----
2838
7462
97

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

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

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

query I rowsort
SELECT ALL - 21 + col2 AS col0 FROM tab0
----
-20
12
61

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

query I rowsort
SELECT ALL - 55 * - col1 + col2 FROM tab0
----
4763
5087
5336

query I rowsort
SELECT - cor0.col0 + 7 FROM tab0, tab0 AS cor0
----
9 values hashing to e3184767e8850074100b3d348b1c355b

query I rowsort
SELECT ALL tab2.col2 + - tab2.col1 + 14 * - ( col1 * - tab2.col1 + col0 ) AS col0 FROM tab2
----
13352
2961
47609

query I rowsort
SELECT ALL col2 + col1 * 80 * - col2 FROM tab2
----
-122694
-51642
-66933

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

query I rowsort
SELECT DISTINCT + col2 * col1 + - col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + 66 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
66

query I rowsort
SELECT - + col1 * 23 AS col1 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT + col2 * + 44 + col2 * col2 * col1 + col0 FROM tab2 cor0
----
23794
26299
41106

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

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

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

query I rowsort
SELECT DISTINCT 93 + + col0 FROM tab2
----
100
171
172

onlyif mysql # use DIV operator for integer division
query I rowsort label-517
SELECT + col0 * 54 + + col1 * - col1 + col0 DIV col2 FROM tab1 AS cor0
----
-514
3357
4151

skipif mysql # not compatible
query I rowsort label-517
SELECT + col0 * 54 + + col1 * - col1 + col0 / col2 FROM tab1 AS cor0
----
-514
3357
4151

query I rowsort
SELECT + - col0 * 98 FROM tab0 AS cor0
----
-2352
-3430
-8722

query I rowsort
SELECT - col2 * ( + 0 ) - col2 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT col0 + + col0 * tab2.col0 * col1 + tab2.col0 AS col2 FROM tab2
----
106255
1533
359112

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

query I rowsort
SELECT ALL + col2 * - col0 - - col1 FROM tab2
----
-158
-1969
-2985

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

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

query I rowsort
SELECT ALL - col2 - col1 AS col2 FROM tab0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * cor0.col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

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

query I rowsort
SELECT ALL - - col1 * + cor0.col0 - - col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL col0 + col2 * - col1 + col2 FROM tab0 cor0
----
-2781
-61
-7291

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-531
SELECT + col0 * cor0.col0 + col0 DIV cor0.col1 FROM tab2 AS cor0
----
49
6085
6245

skipif mysql # not compatible
query I rowsort label-531
SELECT + col0 * cor0.col0 + col0 / cor0.col1 FROM tab2 AS cor0
----
49
6085
6245

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-534
SELECT DISTINCT + - col1 * col1 DIV col0 + col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-233
484
7205

skipif mysql # not compatible
query I rowsort label-534
SELECT DISTINCT + - col1 * col1 / col0 + col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-233
484
7205

onlyif mysql # use DIV operator for integer division
query I rowsort label-535
SELECT - col0 * col1 * - col2 + col2 + - cor0.col0 DIV + col2 FROM tab0 AS cor0
----
3361
664199
68145

skipif mysql # not compatible
query I rowsort label-535
SELECT - col0 * col1 * - col2 + col2 + - cor0.col0 / + col2 FROM tab0 AS cor0
----
3361
664199
68145

query I rowsort
SELECT - - 49 * + col1 FROM tab2 AS cor0
----
1519
2891
833

query I rowsort
SELECT + - 1 * col2 FROM tab1 AS cor0
----
-54
-57
-96

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

query I rowsort
SELECT + + 2 + col2 AS col1 FROM tab2 AS cor0
----
28
29
40

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

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-547
SELECT ALL cor0.col2 DIV - col0 + - col1 FROM tab2 cor0
----
-17
-34
-59

skipif mysql # not compatible
query I rowsort label-547
SELECT ALL cor0.col2 / - col0 + - col1 FROM tab2 cor0
----
-17
-34
-59

query I rowsort
SELECT DISTINCT + - 56 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-1848
-4592
-56

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

query I rowsort
SELECT DISTINCT + 73 * - col1 FROM tab1 AS cor0
----
-1898
-730
-949

query I rowsort
SELECT - - 23 + col1 AS col2 FROM tab0 AS cor0
----
109
114
120

query I rowsort
SELECT ( - col2 + tab0.col0 ) FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL - + cor0.col0 * - col2 + - col0 + - col1 FROM tab1 cor0
----
133
3574
7587

query I rowsort
SELECT ALL + cor0.col1 * cor0.col0 + col1 * - 5 - + col0 FROM tab1 AS cor0
----
-55
526
895

onlyif mysql # use DIV operator for integer division
query I rowsort label-555
SELECT DISTINCT - col2 * col2 + - col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
-2917
-3250
-9217

skipif mysql # not compatible
query I rowsort label-555
SELECT DISTINCT - col2 * col2 + - col2 / + col2 AS col1 FROM tab1 AS cor0
----
-2917
-3250
-9217

query I rowsort
SELECT + + 21 + col2 FROM tab1 AS cor0
----
117
75
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-557
SELECT ALL + - col0 DIV col1 - 29 FROM tab2 AS cor0
----
-29
-30
-33

skipif mysql # not compatible
query I rowsort label-557
SELECT ALL + - col0 / col1 - 29 FROM tab2 AS cor0
----
-29
-30
-33

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

skipif mysql # not compatible
query I rowsort label-558
SELECT col0 * - CAST ( 69 AS INTEGER ) + col1 AS col2 FROM tab2 cor0
----
-452
-5323
-5434

query I rowsort
SELECT ALL cor0.col0 * col0 - col0 FROM tab1 AS cor0
----
4032
6
6320

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

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

query I rowsort
SELECT DISTINCT + col0 + col2 * - col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
22606
24627
39962

query I rowsort
SELECT ALL + col1 * col1 + col0 - col1 * + col2 * col0 AS col0 FROM tab2
----
-116093
-4891
-50666

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 25 col0 FROM tab1
----
1350
1425
2400

query I rowsort
SELECT ALL + 79 + 57 AS col1 FROM tab2
----
136
136
136

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-570
SELECT + ( - cor0.col2 + CAST( 72 AS SIGNED ) ) FROM tab0, tab0 AS cor0
----
9 values hashing to 10d09bc2a82dbff50065fb5e189ca496

skipif mysql # not compatible
query I rowsort label-570
SELECT + ( - cor0.col2 + CAST ( 72 AS INTEGER ) ) FROM tab0, tab0 AS cor0
----
9 values hashing to 10d09bc2a82dbff50065fb5e189ca496

query I rowsort
SELECT DISTINCT 68 + col1 AS col0 FROM tab2
----
127
85
99

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - 44 AS REAL ) + col0 AS col1 FROM tab0
----
-20
-9
45

query I rowsort
SELECT col0 * - 39 - col0 FROM tab1
----
-120
-2560
-3200

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

query I rowsort
SELECT + col1 * col0 + col0 + - ( col1 ) AS col2 FROM tab1 AS cor0
----
1107
55
694

query I rowsort
SELECT ALL col2 + 48 + - col0 AS col2 FROM tab0
----
14
41
57

query I rowsort
SELECT + col1 * + col1 + + 4 + + col0 * - col1 AS col1 FROM tab0 AS cor0
----
186
5336
6018

query I rowsort
SELECT DISTINCT + col2 + + 60 FROM tab0
----
142
61
93

query I rowsort
SELECT DISTINCT 31 + + tab2.col1 AS col0 FROM tab2, tab2 AS cor0
----
48
62
90

query I rowsort
SELECT - col2 * 71 - - col2 AS col2 FROM tab2 AS cor0
----
-1820
-1890
-2660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col2 + col1 col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT - 66 - - 3 * - col1 * - 57 AS col2 FROM tab0 AS cor0
----
14640
15495
16521

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

query I rowsort
SELECT ALL + - cor0.col1 * + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 86c8e75d83d283b29460c020ab5988af

query I rowsort
SELECT tab0.col2 * tab0.col1 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7623ebe74018211e6a4da91fc8c37d6d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 57 + + col0 * 6 + 36 col1 FROM tab0 AS cor0
----
123
189
513

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-590
SELECT CAST ( NULL AS INTEGER ) + tab1.col0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + 48 * + tab0.col0 col1 FROM tab0
----
1176
1715
4361

query I rowsort
SELECT ALL - - cor0.col2 + col2 AS col0 FROM tab1 AS cor0
----
108
114
192

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-594
SELECT ALL 12 DIV cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to be31d481de114b1d25122291681592df

skipif mysql # not compatible
query I rowsort label-594
SELECT ALL 12 / cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to be31d481de114b1d25122291681592df

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

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

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

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

query I rowsort
SELECT ALL + cor0.col0 + - 96 AS col0 FROM tab1 AS cor0
----
-16
-32
-93

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

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

query I rowsort
SELECT - 37 + col2 FROM tab2 AS cor0
----
-10
-11
1

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

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

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

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

query I rowsort
SELECT DISTINCT + cor0.col2 * - col2 * col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

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

query I rowsort
SELECT DISTINCT + 39 + 85 * - col1 AS col0 FROM tab2 AS cor0
----
-1406
-2596
-4976

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

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

query I rowsort
SELECT ALL + 42 + col1 FROM tab1 cor0
----
52
55
68

query I rowsort
SELECT ALL + - 98 * + col1 FROM tab0 AS cor0
----
-8428
-8918
-9506

query I rowsort
SELECT DISTINCT ( cor0.col2 ) + - col2 * col0 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
26169
36
598518

query I rowsort
SELECT - 97 + 17 AS col2 FROM tab0 AS cor0
----
-80
-80
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-611
SELECT DISTINCT 62 DIV col1 AS col2 FROM tab2 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-611
SELECT DISTINCT 62 / col1 AS col2 FROM tab2 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT + - ( 5 ) + col2 AS col0 FROM tab2 cor0
----
21
22
33

query I rowsort
SELECT ALL 12 + 84 FROM tab0 AS cor0
----
96
96
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-614
SELECT - ( - col1 ) * - col1 + CAST( NULL AS DECIMAL ) 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-614
SELECT - ( - col1 ) * - col1 + CAST ( NULL AS REAL ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 + 29 AS col0 FROM tab1
----
191
3677
7709

onlyif mysql # use DIV operator for integer division
query I rowsort label-616
SELECT + + 61 DIV col0 AS col2 FROM tab1 AS cor0
----
0
0
20

skipif mysql # not compatible
query I rowsort label-616
SELECT + + 61 / col0 AS col2 FROM tab1 AS cor0
----
0
0
20

query I rowsort
SELECT + + col1 + 1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT + col2 * + ( - 89 + col2 ) AS col0 FROM tab1 AS cor0
----
-1824
-1890
672

query I rowsort
SELECT - col2 + col1 * col0 * - col2 FROM tab0 AS cor0
----
-3396
-664200
-68145

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

skipif mysql # not compatible
query I rowsort label-620
SELECT ALL + tab0.col1 - + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 19 * col2 FROM tab1
----
1026
1083
1824

onlyif mysql # use DIV operator for integer division
query I rowsort label-622
SELECT ALL cor0.col2 + + col2 DIV col0 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-622
SELECT ALL cor0.col2 + + col2 / col0 FROM tab2 AS cor0
----
26
30
38

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

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

query I rowsort
SELECT - - ( col2 ) * - col0 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - 28 * 7 AS col2 FROM tab0
----
-196
-196
-196

onlyif mysql # use DIV operator for integer division
query I rowsort label-626
SELECT DISTINCT 77 DIV + col0 AS col1 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-626
SELECT DISTINCT 77 / + col0 AS col1 FROM tab0
----
0
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-627
SELECT 89 * 39 DIV - col0 FROM tab0 AS cor0
----
-144
-39
-99

skipif mysql # not compatible
query I rowsort label-627
SELECT 89 * 39 / - col0 FROM tab0 AS cor0
----
-144
-39
-99

query I rowsort
SELECT DISTINCT + 35 * - col2 AS col0 FROM tab2
----
-1330
-910
-945

query I rowsort
SELECT - 43 * + col1 * col0 AS col2 FROM tab2 AS cor0
----
-197886
-57749
-9331

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

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

query I rowsort
SELECT cor0.col1 * cor0.col1 * - col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT + - 1 + col0 * + 78 FROM tab0 cor0
----
1871
2729
6941

query I rowsort
SELECT ALL - + 72 FROM tab2 cor0
----
-72
-72
-72

query I rowsort
SELECT - col2 * - col0 + - 46 AS col2 FROM tab0 AS cor0
----
-11
7252
746

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + cor0.col1 ) * + col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT 92 * col0 AS col1 FROM tab0 AS cor0
----
2208
3220
8188

query I rowsort
SELECT + 19 + + col1 * - 86 AS col0 FROM tab0 cor0
----
-7377
-7807
-8323

query I rowsort
SELECT 77 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT 67 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT 25 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT + col2 + + 99 * - col1 FROM tab0 cor0
----
-8481
-8927
-9602

onlyif mysql # use DIV operator for integer division
query I rowsort label-642
SELECT - col1 + - 8 * col0 DIV col1 FROM tab0 AS cor0
----
-88
-98
-99

skipif mysql # not compatible
query I rowsort label-642
SELECT - col1 + - 8 * col0 / col1 FROM tab0 AS cor0
----
-88
-98
-99

query I rowsort
SELECT ALL col0 + 2 AS col2 FROM tab2 AS cor0
----
80
81
9

query I rowsort
SELECT + cor0.col0 * + 56 AS col0 FROM tab0 AS cor0
----
1344
1960
4984

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-646
SELECT DISTINCT 59 DIV + col0 AS col0 FROM tab2
----
0
8

skipif mysql # not compatible
query I rowsort label-646
SELECT DISTINCT 59 / + col0 AS col0 FROM tab2
----
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-647
SELECT col2 * CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-647
SELECT col2 * CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
1444
676
729

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-649
SELECT - - CAST( - col2 AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-649
SELECT - - CAST ( - col2 AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - + col2 + + 29 * - col0 FROM tab2 AS cor0
----
-2288
-230
-2329

query I rowsort
SELECT - 10 * 19 + + col0 AS col2 FROM tab1 cor0
----
-110
-126
-187

onlyif mysql # use DIV operator for integer division
query I rowsort label-652
SELECT - - col1 + cor0.col0 * col2 DIV 71 AS col0 FROM tab0 AS cor0
----
193
97
97

skipif mysql # not compatible
query I rowsort label-652
SELECT - - col1 + cor0.col0 * col2 / 71 AS col0 FROM tab0 AS cor0
----
193
97
97

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

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

query I rowsort
SELECT + ( - col2 ) * - ( - ( col0 ) ) * - 92 + col1 AS col2 FROM tab1 AS cor0
----
14930
335626
706573

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

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

query I rowsort
SELECT ALL tab0.col0 + - tab0.col2 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 4646ed87e8cc5aacb51f9b4e472c3c4b

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

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

query I rowsort
SELECT DISTINCT col2 * 13 * 86 + col1 FROM tab1
----
107341
60398
63736

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

query I rowsort
SELECT - col2 + col2 + + 36 FROM tab1
----
36
36
36

query I rowsort
SELECT ALL - cor1.col1 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT col0 + col2 - + col0 * - tab0.col2 FROM tab0
----
71
7469
849

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col1 * col1 col0 FROM tab1
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-667
SELECT + - col1 + col2 + + col2 DIV col1 AS col1 FROM tab1 AS cor0
----
30
52
90

skipif mysql # not compatible
query I rowsort label-667
SELECT + - col1 + col2 + + col2 / col1 AS col1 FROM tab1 AS cor0
----
30
52
90

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

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

skipif mysql # not compatible
query I rowsort label-669
SELECT ALL + - col2 * - CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-670
SELECT ALL - col1 * + 79 + - col1 DIV - tab2.col1 FROM tab2
----
-1342
-2448
-4660

skipif mysql # not compatible
query I rowsort label-670
SELECT ALL - col1 * + 79 + - col1 / - tab2.col1 FROM tab2
----
-1342
-2448
-4660

query I rowsort
SELECT + col0 + ( + ( + col1 ) * - 83 + + col2 ) FROM tab0
----
-7081
-7382
-8015

query I rowsort
SELECT ALL + - cor0.col1 + 91 FROM tab1 AS cor0
----
65
78
81

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

query I rowsort
SELECT - 20 * + col1 AS col0 FROM tab0 AS cor0
----
-1720
-1820
-1940

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

skipif mysql # not compatible
query I rowsort label-675
SELECT ALL + - col0 * col1 / col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - - col1 + - col0 * col0 AS col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + - 65 FROM tab0 cor0
----
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 45 * cor0.col2 col0 FROM tab1 AS cor0
----
-2430
-2565
-4320

query I rowsort
SELECT - 50 * + col2 FROM tab0 AS cor0
----
-1650
-4100
-50

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-681
SELECT - + CAST( col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-681
SELECT - + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

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

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

query I rowsort
SELECT ALL ( col2 ) + + col1 * cor0.col1 * cor0.col0 FROM tab0 AS cor0
----
177537
329316
737091

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-685
SELECT DISTINCT + - CAST( col2 AS SIGNED ) + - cor0.col1 FROM tab2 cor0
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-685
SELECT DISTINCT + - CAST ( col2 AS INTEGER ) + - cor0.col1 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - 15 AS col0 FROM tab0 AS cor0
----
-15
-15
-15

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

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

query I rowsort
SELECT DISTINCT - 74 * col2 * + col0 AS col1 FROM tab2 AS cor0
----
-13986
-150072
-222148

query I rowsort
SELECT ALL - 40 * col1 * 41 + 0 AS col0 FROM tab2 AS cor0
----
-27880
-50840
-96760

query I rowsort
SELECT ALL + + 4 * + col2 - - col1 AS col1 FROM tab2 AS cor0
----
139
163
169

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 2 * + col0 col1 FROM tab0 AS cor0
----
178
48
70

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 20 * col1 + cor0.col0 col1 FROM tab2 AS cor0
----
-1102
-261
-613

query I rowsort
SELECT ALL + - 29 + + col1 AS col2 FROM tab2 AS cor0
----
-12
2
30

query I rowsort
SELECT ALL 95 * col2 + + 99 AS col2 FROM tab0 AS cor0
----
194
3234
7889

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 - + col0 * - col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL - - 19 + - col0 FROM tab2 AS cor0
----
-59
-60
12

query I rowsort
SELECT ALL 37 + - col0 AS col0 FROM tab0 AS cor0
----
-52
13
2

query I rowsort
SELECT DISTINCT col2 + col2 * - ( col2 * - col1 ) FROM tab1 cor0
----
119904
32547
75870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-703
SELECT col1 * - CAST( - 96 AS SIGNED ) + + cor0.col2 col1 FROM tab0 AS cor0
----
8289
8818
9313

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-703
SELECT col1 * - CAST ( - 96 AS INTEGER ) + + cor0.col2 col1 FROM tab0 AS cor0
----
8289
8818
9313

query I rowsort
SELECT ALL - col0 + - col1 * cor0.col1 FROM tab0 cor0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT cor0.col2 * - 0 + - 62 FROM tab2 AS cor0
----
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-706
SELECT + col2 + + CAST( col1 AS SIGNED ) DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-706
SELECT + col2 + + CAST ( col1 AS INTEGER ) / cor0.col0 AS col1 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT DISTINCT - + col2 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + - 63 * + 35 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 82d553f894edaf233a912d85a728c78a

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

skipif mysql # not compatible
query I rowsort label-709
SELECT ALL - CAST ( NULL AS INTEGER ) * 90 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

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

query I rowsort
SELECT - 96 - + col2 FROM tab0
----
-129
-178
-97

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

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

query I rowsort
SELECT - + col2 * 88 FROM tab2 cor0
----
-2288
-2376
-3344

query I rowsort
SELECT DISTINCT + cor0.col1 + + 16 AS col2 FROM tab1 AS cor0
----
26
29
42

query I rowsort
SELECT col2 * col0 * + col2 FROM tab0 AS cor0
----
26136
35
598436

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

query I rowsort
SELECT DISTINCT cor0.col2 - col0 * - col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-719
SELECT DISTINCT - - col1 DIV 48 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-719
SELECT DISTINCT - - col1 / 48 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col0 * col1 * col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT - col0 * 79 FROM tab2 cor0
----
-553
-6162
-6241

query I rowsort
SELECT col1 * - col2 + - cor0.col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL + 9 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT + 25 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + ( - col2 ) col1 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT - 10 * cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5c9c7368a966a6fc06b4c9015d350e9d

onlyif mysql # use DIV operator for integer division
query I rowsort label-729
SELECT - col2 DIV 73 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-729
SELECT - col2 / 73 FROM tab1
----
-1
0
0

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-731
SELECT ALL + col2 * col2 * - tab1.col1 + CAST( + col2 AS SIGNED ) FROM tab1
----
-119712
-32433
-75762

skipif mysql # not compatible
query I rowsort label-731
SELECT ALL + col2 * col2 * - tab1.col1 + CAST ( + col2 AS INTEGER ) FROM tab1
----
-119712
-32433
-75762

onlyif mysql # use DIV operator for integer division
query I rowsort label-732
SELECT 64 + + col1 DIV - col1 FROM tab1 AS cor0
----
63
63
63

skipif mysql # not compatible
query I rowsort label-732
SELECT 64 + + col1 / - col1 FROM tab1 AS cor0
----
63
63
63

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

query I rowsort
SELECT ALL - ( - col1 + - 67 * 81 ) AS col1 FROM tab1
----
5437
5440
5453

query I rowsort
SELECT DISTINCT + tab2.col2 * - cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
-1026
-1444
-676
-702
-729
-988

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

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

query I rowsort
SELECT + + col1 + col0 * + col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT ALL + - cor0.col0 * col0 - 5 AS col2 FROM tab2 AS cor0
----
-54
-6089
-6246

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

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

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

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

skipif mysql # not compatible
query I rowsort label-741
SELECT 44 / + col0 FROM tab0 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-742
SELECT + - col2 + col1 DIV + 27 FROM tab0 AS cor0
----
-30
-79
2

skipif mysql # not compatible
query I rowsort label-742
SELECT + - col2 + col1 / + 27 FROM tab0 AS cor0
----
-30
-79
2

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

skipif mysql # not compatible
query I rowsort label-743
SELECT ALL - col2 + col1 * + CAST ( col1 * col2 + 12 * - col1 AS INTEGER ) FROM tab0 AS cor0
----
-103500
155283
579588

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

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

query I rowsort
SELECT ALL - - 14 * cor0.col2 AS col0 FROM tab2 AS cor0
----
364
378
532

query I rowsort
SELECT col1 * - cor0.col0 + - col0 + - 16 FROM tab1 cor0
----
-1136
-720
-97

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

query I rowsort
SELECT ALL + ( - 38 ) FROM tab1 AS cor0
----
-38
-38
-38

query I rowsort
SELECT DISTINCT - 77 * 43 AS col2 FROM tab0 AS cor0
----
-3311

query I rowsort
SELECT - + col0 + + col1 + col0 * 38 * col2 AS col2 FROM tab2 AS cor0
----
114014
7206
77045

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

query I rowsort
SELECT 72 - - col2 * col0 AS col0 FROM tab2
----
2100
261
3074

query IIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 WHERE NULL IN ( + cor0.col1 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 20 col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

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

query I rowsort
SELECT DISTINCT - - col1 * col2 + 56 FROM tab2 AS cor0
----
1590
702
893

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-759
SELECT col2 + - CAST( - col2 AS SIGNED ) * - cor0.col0 * - 59 + + col0 * + col0 * - col1 FROM tab1 AS cor0
----
174329
370016
9378

skipif mysql # not compatible
query I rowsort label-759
SELECT col2 + - CAST ( - col2 AS INTEGER ) * - cor0.col0 * - 59 + + col0 * + col0 * - col1 FROM tab1 AS cor0
----
174329
370016
9378

onlyif mysql # use DIV operator for integer division
query I rowsort label-760
SELECT DISTINCT + 83 DIV + col2 FROM tab0
----
1
2
83

skipif mysql # not compatible
query I rowsort label-760
SELECT DISTINCT + 83 / + col2 FROM tab0
----
1
2
83

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

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

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

query I rowsort
SELECT - col0 + col2 * - col1 + - col2 AS col1 FROM tab0
----
-133
-2895
-7633

query I rowsort
SELECT - + col1 + ( cor0.col1 ) * col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + col0 * 20 + - col1 FROM tab2 AS cor0
----
109
1501
1563

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

query I rowsort
SELECT ALL col0 * - cor0.col1 * - 35 AS col2 FROM tab2 AS cor0
----
161070
47005
7595

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

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

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

skipif mysql # not compatible
query I rowsort label-770
SELECT ALL + 69 / + col0 AS col1 FROM tab1
----
0
1
23

query I rowsort
SELECT - ( + ( + col0 ) ) AS col2 FROM tab2
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-772
SELECT ALL CAST( 3 AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

skipif mysql # not compatible
query I rowsort label-772
SELECT ALL CAST ( 3 AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT DISTINCT - + 76 * + col0 AS col2 FROM tab1 AS cor0
----
-228
-4864
-6080

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

skipif mysql # not compatible
query I rowsort label-774
SELECT col0 / + col1 - + CAST ( NULL AS INTEGER ) / + 44 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - cor0.col2 * + 25 * + col2 AS col2 FROM tab1 AS cor0
----
-230320
-72897
-81161

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

query I rowsort
SELECT + 72 + + col1 FROM tab1 cor0
----
82
85
98

query I rowsort
SELECT ( - cor0.col0 ) + - ( 40 ) FROM tab2 AS cor0
----
-118
-119
-47

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

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

query I rowsort
SELECT + col2 - cor0.col0 * - col1 * col0 AS col0 FROM tab1 AS cor0
----
288
41017
83296

onlyif mysql # use DIV operator for integer division
query I rowsort label-782
SELECT + + 92 DIV cor0.col2 col2 FROM tab0 AS cor0
----
1
2
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-782
SELECT + + 92 / cor0.col2 col2 FROM tab0 AS cor0
----
1
2
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-783
SELECT - + 91 + col0 DIV col0 FROM tab2 AS cor0
----
-90
-90
-90

skipif mysql # not compatible
query I rowsort label-783
SELECT - + 91 + col0 / col0 FROM tab2 AS cor0
----
-90
-90
-90

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 * col1 FROM tab2 AS cor0
----
251
3455
934

onlyif mysql # use DIV operator for integer division
query I rowsort label-785
SELECT ALL + - ( col1 ) DIV col1 - + cor0.col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-785
SELECT ALL + - ( col1 ) / col1 - + cor0.col2 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT col1 * + cor0.col2 - 44 AS col0 FROM tab2 AS cor0
----
1490
602
793

query I rowsort
SELECT ALL + - 2 FROM tab1 cor0
----
-2
-2
-2

query I rowsort
SELECT col2 + cor0.col1 * 68 FROM tab0 AS cor0
----
5881
6270
6597

onlyif mysql # use DIV operator for integer division
query I rowsort label-789
SELECT + col2 DIV + col2 - - col2 DIV col0 FROM tab1 AS cor0
----
1
19
2

skipif mysql # not compatible
query I rowsort label-789
SELECT + col2 / + col2 - - col2 / col0 FROM tab1 AS cor0
----
1
19
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-790
SELECT + col1 DIV col0 + col0 * col1 AS col1 FROM tab2
----
1343
221
4602

skipif mysql # not compatible
query I rowsort label-790
SELECT + col1 / col0 + col0 * col1 AS col1 FROM tab2
----
1343
221
4602

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-792
SELECT + col1 + 13 DIV - col0 AS col1 FROM tab2 cor0
----
17
30
59

skipif mysql # not compatible
query I rowsort label-792
SELECT + col1 + 13 / - col0 AS col1 FROM tab2 cor0
----
17
30
59

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

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

query I rowsort
SELECT DISTINCT col2 + - ( - 95 ) * col0 + + col0 * col1 FROM tab0 AS cor0
----
16636
4377
6721

query I rowsort
SELECT ALL + - col2 + - 58 FROM tab0 AS cor0
----
-140
-59
-91

query I rowsort
SELECT + col1 + ( ( + cor0.col2 ) ) * cor0.col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
119711
51051
5890

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

skipif mysql # not compatible
query I rowsort label-797
SELECT col1 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 53 FROM tab1, tab0 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

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

query I rowsort
SELECT ALL + - cor0.col1 * + ( col1 ) FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - + 5 + 9 AS col0 FROM tab0 AS cor0
----
4

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

query I rowsort
SELECT DISTINCT + 13 * ( - col1 ) + col0 AS col0 FROM tab1 AS cor0
----
-335
-66
-89

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col1 col1 FROM tab1, tab0 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

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

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

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

query I rowsort
SELECT DISTINCT + - 10 FROM tab0 AS cor0
----
-10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 16 + col0 * cor0.col0 * 77 col0 FROM tab2 AS cor0
----
3757
468452
480541

query I rowsort
SELECT DISTINCT - col0 + col2 * + col1 * + ( - 97 ) - col0 FROM tab1 AS cor0
----
-121216
-136194
-55418

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

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

query I rowsort
SELECT DISTINCT + col2 * 96 FROM tab2 AS cor0
----
2496
2592
3648

query I rowsort
SELECT - - 65 * col2 FROM tab2 AS cor0
----
1690
1755
2470

query I rowsort
SELECT - + col0 * col1 + - col1 * col1 FROM tab2 AS cor0
----
-1178
-1632
-8083

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

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

query I rowsort
SELECT DISTINCT + col2 * - 70 AS col2 FROM tab1 AS cor0
----
-3780
-3990
-6720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-820
SELECT - cor0.col0 * col1 + + cor0.col0 * CAST( 8 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-161
-3978
-711

skipif mysql # not compatible
query I rowsort label-820
SELECT - cor0.col0 * col1 + + cor0.col0 * CAST ( 8 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-161
-3978
-711

onlyif mysql # use DIV operator for integer division
query I rowsort label-821
SELECT ALL + col2 * - 25 + col2 DIV 55 AS col0 FROM tab1 AS cor0
----
-1350
-1424
-2399

skipif mysql # not compatible
query I rowsort label-821
SELECT ALL + col2 * - 25 + col2 / 55 AS col0 FROM tab1 AS cor0
----
-1350
-1424
-2399

query I rowsort
SELECT - 36 + col1 * + col2 FROM tab2 AS cor0
----
1498
610
801

onlyif mysql # use DIV operator for integer division
query I rowsort label-823
SELECT ALL - col2 * - col1 DIV col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-823
SELECT ALL - col2 * - col1 / col1 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-824
SELECT ALL - col1 + + 75 * ( col2 ) DIV col1 FROM tab1 AS cor0
----
129
417
540

skipif mysql # not compatible
query I rowsort label-824
SELECT ALL - col1 + + 75 * ( col2 ) / col1 FROM tab1 AS cor0
----
129
417
540

query I rowsort
SELECT - col1 + ( - 13 ) * col1 * col2 FROM tab0 AS cor0
----
-1358
-36980
-97097

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

query I rowsort
SELECT col1 * 78 * - 66 FROM tab1 AS cor0
----
-133848
-51480
-66924

query I rowsort
SELECT ALL + 27 + col2 + col1 * - col0 FROM tab1
----
-556
-917
3

query I rowsort
SELECT - + 54 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-830
SELECT - tab2.col1 * CAST( - 94 + + col2 AS SIGNED ) FROM tab2
----
2077
4012
952

skipif mysql # not compatible
query I rowsort label-830
SELECT - tab2.col1 * CAST ( - 94 + + col2 AS INTEGER ) FROM tab2
----
2077
4012
952

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

query I rowsort
SELECT ALL col0 * 76 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT DISTINCT col1 + + col2 + + col1 * cor0.col1 FROM tab0 AS cor0
----
7515
8454
9507

query I rowsort
SELECT + cor0.col0 * col1 + - 88 FROM tab1 AS cor0
----
-10
552
952

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-836
SELECT + 73 * cor0.col2 DIV col0 FROM tab0 AS cor0
----
100
2
67

skipif mysql # not compatible
query I rowsort label-836
SELECT + 73 * cor0.col2 / col0 FROM tab0 AS cor0
----
100
2
67

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-838
SELECT ALL + col2 DIV + 95 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-838
SELECT ALL + col2 / + 95 AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT DISTINCT - - col0 * + 54 * 7 FROM tab1 AS cor0
----
1134
24192
30240

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - 58 col1 FROM tab0 AS cor0
----
28
33
39

query I rowsort
SELECT DISTINCT - - col2 + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL - 9 FROM tab1, tab1 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 * - col1 col0 FROM tab2 AS cor0
----
1767
3363
969

query I rowsort
SELECT ALL 81 + cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 320a4e9765c8856c092441111046d612

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

query I rowsort
SELECT + col2 + 66 FROM tab2 cor0
----
104
92
93

query I rowsort
SELECT col2 + + cor0.col0 * cor0.col1 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-848
SELECT 64 + + col2 DIV col0 AS col2 FROM tab2 cor0
----
64
64
67

skipif mysql # not compatible
query I rowsort label-848
SELECT 64 + + col2 / col0 AS col2 FROM tab2 cor0
----
64
64
67

query I rowsort
SELECT - - 15 * + col0 + - 81 * - 38 FROM tab1 cor0
----
3123
4038
4278

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

query I rowsort
SELECT col0 + 31 + + col1 * - 50 FROM tab0
----
-4245
-4430
-4784

onlyif mysql # use DIV operator for integer division
query I rowsort label-852
SELECT DISTINCT 82 DIV 69 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-852
SELECT DISTINCT 82 / 69 FROM tab2
----
1

query I rowsort
SELECT ALL tab1.col1 + col1 * col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL - col1 + col0 * + col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL 70 + - cor0.col1 * - 93 AS col2 FROM tab2, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 1cbbb4d38cc82b8807ff0961aa84b6a6

query I rowsort
SELECT ALL + 53 + col1 AS col0 FROM tab0 AS cor0
----
139
144
150

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col0 col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - 53 * - col2 FROM tab1
----
2862
3021
5088

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

query I rowsort
SELECT ALL col2 * ( cor0.col0 ) + + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-861
SELECT ALL + - cor0.col1 DIV ( + col2 ) + cor0.col0 * col2 FROM tab0 cor0
----
-62
7297
790

skipif mysql # not compatible
query I rowsort label-861
SELECT ALL + - cor0.col1 / ( + col2 ) + cor0.col0 * col2 FROM tab0 cor0
----
-62
7297
790

query I rowsort
SELECT DISTINCT col0 * 18 FROM tab2 AS cor0
----
126
1404
1422

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-863
SELECT DISTINCT CAST( + 76 AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
76

skipif mysql # not compatible
query I rowsort label-863
SELECT DISTINCT CAST ( + 76 AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
76

query I rowsort
SELECT ALL - tab0.col1 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT + col2 * col1 + tab0.col0 * 89 FROM tab0
----
15383
3212
4974

query I rowsort
SELECT DISTINCT - ( col1 * col2 ) + ( col2 ) AS col2 FROM tab1
----
-1152
-1350
-513

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

query I rowsort
SELECT DISTINCT - 33 * col2 + - col2 FROM tab1
----
-1836
-1938
-3264

query I rowsort
SELECT cor0.col2 * + 20 AS col1 FROM tab1 AS cor0
----
1080
1140
1920

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-873
SELECT ALL - tab1.col2 * col1 / col2 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-874
SELECT ( + col0 ) * col2 DIV ( + 69 ) AS col2 FROM tab0 AS cor0
----
0
105
11

skipif mysql # not compatible
query I rowsort label-874
SELECT ( + col0 ) * col2 / ( + 69 ) AS col2 FROM tab0 AS cor0
----
0
105
11

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

query I rowsort
SELECT - ( 83 ) * + col0 + ( 49 ) * tab2.col2 * 66 + + col1 FROM tab2
----
116352
77669
86768

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

skipif mysql # not compatible
query I rowsort label-877
SELECT DISTINCT ( - 20 ) * + col2 * CAST ( NULL AS INTEGER ) - col2 AS col0 FROM tab0
----
NULL

query I rowsort
SELECT ( + col1 + + col2 ) * - col1 AS col1 FROM tab2
----
-1798
-5015
-935

query I rowsort
SELECT - col1 * 42 + - col0 * + col2 AS col0 FROM tab2 AS cor0
----
-1491
-3716
-4506

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) * + cor0.col1 + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT + col2 - + 1 AS col1 FROM tab0 AS cor0
----
0
32
81

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

query I rowsort
SELECT ALL + col1 * - 45 * col1 - + col1 AS col0 FROM tab2 cor0
----
-13022
-156704
-43276

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col1 + - col1 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT ALL - 64 * + 47 FROM tab2 AS cor0
----
-3008
-3008
-3008

onlyif mysql # use DIV operator for integer division
query I rowsort label-886
SELECT DISTINCT + col0 DIV + cor0.col1 + col1 AS col2 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-886
SELECT DISTINCT + col0 / + cor0.col1 + col1 AS col2 FROM tab2 AS cor0
----
21
31
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 15 * - col2 * - col0 col2 FROM tab0 AS cor0
----
-109470
-11880
-525

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-889
SELECT - CAST ( 79 AS INTEGER ) col0 FROM tab2
----
-79
-79
-79

query I rowsort
SELECT DISTINCT - 0 * - col0 + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 74 + + col2 FROM tab0
----
107
156
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-892
SELECT - 89 DIV 47 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-892
SELECT - 89 / 47 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-893
SELECT DISTINCT - - col2 + - CAST( ( - col1 ) AS SIGNED ) * + 74 FROM tab0 AS cor0
----
6397
6816
7179

skipif mysql # not compatible
query I rowsort label-893
SELECT DISTINCT - - col2 + - CAST ( ( - col1 ) AS INTEGER ) * + 74 FROM tab0 AS cor0
----
6397
6816
7179

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

query I rowsort
SELECT ALL tab2.col1 + - tab2.col1 * col2 * - col2 FROM tab2
----
22630
24565
39943

query I rowsort
SELECT ( - col1 ) * col2 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT col1 * tab2.col1 * 85 - 68 AS col0 FROM tab2
----
24497
295817
81617

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

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

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

query I rowsort
SELECT DISTINCT 47 * col1 * col2 + col0 * col0 FROM tab1
----
30886
65056
65997

query I rowsort
SELECT - col2 + - col1 * + 97 FROM tab2
----
-1687
-3034
-5749

query I rowsort
SELECT ALL + tab0.col0 + tab0.col0 + - tab0.col2 FROM tab0
----
15
69
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + cor0.col2 col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 02081120b66025475df9f31f465bcbe4

query I rowsort
SELECT ALL cor0.col1 + col1 + - ( + cor0.col2 ) * 23 FROM tab2 AS cor0
----
-480
-559
-840

onlyif mysql # use DIV operator for integer division
query I rowsort label-905
SELECT - col1 DIV 27 + - col2 FROM tab2 AS cor0
----
-28
-28
-38

skipif mysql # not compatible
query I rowsort label-905
SELECT - col1 / 27 + - col2 FROM tab2 AS cor0
----
-28
-28
-38

query I rowsort
SELECT ALL + - col1 * - ( - col1 ) + - col1 AS col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT + col0 + - col1 + col2 FROM tab2 AS cor0
----
100
3
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 * cor0.col1 + col1 - col2 col0 FROM tab0 cor0
----
-7343
-8272
-9313

query I rowsort
SELECT + - 62 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to 98946dcadb23f354040593c91d9c8559

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

skipif mysql # not compatible
query I rowsort label-910
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab0 cor0
----
NULL

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-912
SELECT CAST( + 21 AS SIGNED ) * cor0.col1 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9ad9248ca478f9f31c9328b84537d14c

skipif mysql # not compatible
query I rowsort label-912
SELECT CAST ( + 21 AS INTEGER ) * cor0.col1 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9ad9248ca478f9f31c9328b84537d14c

onlyif mysql # use DIV operator for integer division
query I rowsort label-913
SELECT + - 47 * col1 DIV + cor0.col1 col0 FROM tab0 AS cor0
----
-47
-47
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-913
SELECT + - 47 * col1 / + cor0.col1 col0 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT + + ( 92 ) * + col1 FROM tab2 AS cor0
----
1564
2852
5428

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

query I rowsort
SELECT - 38 + col1 * col1 AS col0 FROM tab1 AS cor0
----
131
62
638

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

query I rowsort
SELECT + + cor0.col1 + + 81 * - col1 + 8 * col2 FROM tab1 cor0
----
-1648
-272
-344

onlyif mysql # use DIV operator for integer division
query I rowsort label-919
SELECT - 66 DIV col1 + col0 * + ( cor0.col2 ) + col0 FROM tab1 AS cor0
----
163
3706
7755

skipif mysql # not compatible
query I rowsort label-919
SELECT - 66 / col1 + col0 * + ( cor0.col2 ) + col0 FROM tab1 AS cor0
----
163
3706
7755

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 80 col2 FROM tab2 AS cor0
----
-80

query I rowsort
SELECT DISTINCT + col1 * - col2 + - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

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

query I rowsort
SELECT ALL - col0 + col2 * col1 + + col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
1563
4154
8848

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

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * - col1 * col1 - - 60 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-246048
-683962
-9469

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

query I rowsort
SELECT ALL - 66 AS col0 FROM tab0 cor0
----
-66
-66
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-932
SELECT - cor0.col0 + - col2 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-5
-69
-87

skipif mysql # not compatible
query I rowsort label-932
SELECT - cor0.col0 + - col2 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-5
-69
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-933
SELECT col1 + 21 * col0 DIV + col1 + cor0.col0 DIV + col2 FROM tab1 cor0
----
142
145
28

skipif mysql # not compatible
query I rowsort label-933
SELECT col1 + 21 * col0 / + col1 + cor0.col0 / + col2 FROM tab1 cor0
----
142
145
28

query I rowsort
SELECT ALL + col0 * + 48 AS col1 FROM tab1 AS cor0
----
144
3072
3840

query I rowsort
SELECT col2 + ( cor0.col2 ) * col2 + - ( - col1 ) AS col0 FROM tab1 cor0
----
2996
3316
9325

query I rowsort
SELECT + col2 + col2 + + 0 AS col1 FROM tab2
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-937
SELECT + col0 * col2 + - CAST( + 86 AS SIGNED ) * cor0.col2 * - col1 AS col2 FROM tab1 cor0
----
115008
120906
52668

skipif mysql # not compatible
query I rowsort label-937
SELECT + col0 * col2 + - CAST ( + 86 AS INTEGER ) * cor0.col2 * - col1 AS col2 FROM tab1 cor0
----
115008
120906
52668

query I rowsort
SELECT + + 45 AS col1 FROM tab2 AS cor0
----
45
45
45

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

skipif mysql # not compatible
query I rowsort label-939
SELECT - - col2 / + col1 + 36 AS col1 FROM tab0 cor0
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 14 * - col0 * col1 col1 FROM tab0 AS cor0
----
-113386
-28896
-47530

query I rowsort
SELECT 20 + col2 AS col2 FROM tab1 AS cor0
----
116
74
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 95 col1 FROM tab0
----
-95
-95
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + + col2 * ( + col0 ) col0 FROM tab0 cor0
----
14596
1584
70

query I rowsort
SELECT ALL + + col2 * + col2 + col1 * - col2 FROM tab0 AS cor0
----
-1749
-738
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 26 + col1 * col0 col0 FROM tab2
----
1369
243
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + - col2 * col2 col0 FROM tab1 AS cor0
----
-2970
-3306
-9312

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 38 + 53 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT + col1 + - 92 * col2 FROM tab2 AS cor0
----
-2333
-2453
-3479

query I rowsort
SELECT ALL col1 * 35 AS col1 FROM tab2 AS cor0
----
1085
2065
595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - ( + col1 ) col0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ( + col2 ) + col1 - + ( - 51 + col1 * - col2 ) AS col2 FROM tab2
----
1670
752
946

query I rowsort
SELECT + 77 * - tab1.col1 - - col0 AS col2 FROM tab1
----
-1999
-706
-921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 40 + + col2 col2 FROM tab1 AS cor0
----
136
94
97

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT col2 + col0 * + tab2.col0 * - col1 - col0 * - col1 FROM tab2
----
-104716
-1275
-354328

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

skipif mysql # not compatible
query I rowsort label-958
SELECT ALL - - CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 30 * col2 * col0 FROM tab1 AS cor0
----
109440
230400
4860

query I rowsort
SELECT ALL + ( + col2 ) * 44 AS col2 FROM tab2 cor0
----
1144
1188
1672

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 * + col0 col1 FROM tab2 AS cor0
----
357
3978
4029

query I rowsort
SELECT - - 83 * 89 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 88f960a69b9672dce43384645a2c92bf

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

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

query I rowsort
SELECT - 88 + cor0.col2 * ( 7 ) * - col2 FROM tab2 AS cor0
----
-10196
-4820
-5191

query I rowsort
SELECT DISTINCT ( - 71 ) * tab0.col1 FROM tab0
----
-6106
-6461
-6887

query I rowsort
SELECT ALL + - col0 + col0 * + 5 FROM tab0 AS cor0
----
140
356
96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-970
SELECT ALL + cor0.col1 DIV 65 + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-970
SELECT ALL + cor0.col1 / 65 + col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-971
SELECT + col1 + CAST( - 86 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
0
11
5

skipif mysql # not compatible
query I rowsort label-971
SELECT + col1 + CAST ( - 86 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
0
11
5

query I rowsort
SELECT DISTINCT + - cor0.col0 * 70 FROM tab1 AS cor0
----
-210
-4480
-5600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * 27 + 98 col0 FROM tab2 AS cor0
----
2204
2231
287

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

skipif mysql # not compatible
query I rowsort label-974
SELECT + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
10
13
26

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-976
SELECT DISTINCT - col2 * + cor0.col1 / col1 col2 FROM tab0 AS cor0
----
-1
-33
-82

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-978
SELECT + col1 + 65 DIV - col0 FROM tab0 AS cor0
----
84
91
96

skipif mysql # not compatible
query I rowsort label-978
SELECT + col1 + 65 / - col0 FROM tab0 AS cor0
----
84
91
96

query I rowsort
SELECT ALL - + ( - 62 ) * - col2 + col0 AS col1 FROM tab1 AS cor0
----
-3345
-3470
-5872

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

query I rowsort
SELECT DISTINCT + col2 * ( - tab2.col1 * col1 ) AS col2 FROM tab2
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-982
SELECT tab0.col0 DIV - 60 FROM tab0, tab0 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-982
SELECT tab0.col0 / - 60 FROM tab0, tab0 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-983
SELECT ALL col0 * - CAST( col1 * col0 AS SIGNED ) FROM tab1
----
-234
-40960
-83200

skipif mysql # not compatible
query I rowsort label-983
SELECT ALL col0 * - CAST ( col1 * col0 AS INTEGER ) FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT - col2 * col2 * col2 AS col0 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT DISTINCT + - 17 + col2 AS col2 FROM tab1 AS cor0
----
37
40
79

query I rowsort
SELECT col0 * col0 + ( - col0 ) AS col2 FROM tab0 AS cor0
----
1190
552
7832

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 + + 1 col2 FROM tab2 cor0
----
1535
647
838

query I rowsort
SELECT ALL - 21 * cor0.col0 + col2 FROM tab1 AS cor0
----
-1287
-1584
-9

query I rowsort
SELECT DISTINCT - + col1 + - col2 * - cor0.col1 * col0 FROM tab0 cor0
----
3298
664027
68026

query I rowsort
SELECT DISTINCT col0 * + col0 + + col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL - 63 * + col1 AS col2 FROM tab0 AS cor0
----
-5418
-5733
-6111

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT col2 * + 84 + - cor0.col0 AS col0 FROM tab0 cor0
----
2748
49
6799

query I rowsort
SELECT ALL - col0 + - 18 FROM tab1 AS cor0
----
-21
-82
-98

query I rowsort
SELECT + cor0.col1 + 56 FROM tab0, tab2, tab0 AS cor0, tab1
----
81 values hashing to 18c16303ea0661744bd957d86338486c

query I rowsort
SELECT DISTINCT col1 * col1 * ( + col1 ) + tab2.col1 AS col1 FROM tab2
----
205438
29822
4930

onlyif mysql # use DIV operator for integer division
query I rowsort label-999
SELECT ALL - ( col1 + ( + col2 ) ) DIV + col2 col0 FROM tab0
----
-2
-3
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-999
SELECT ALL - ( col1 + ( + col2 ) ) / + col2 col0 FROM tab0
----
-2
-3
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1000
SELECT - col0 + col1 DIV col1 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-1000
SELECT - col0 + col1 / col1 FROM tab0
----
-23
-34
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 41 * col2 + 7 col2 FROM tab2 AS cor0
----
26493
34324
62901

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

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

query I rowsort
SELECT col0 * - col2 - - col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-1004
SELECT - col2 DIV + col0 + - cor0.col0 FROM tab2 cor0
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-1004
SELECT - col2 / + col0 + - cor0.col0 FROM tab2 cor0
----
-10
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 ) * col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT 44 AS col1 FROM tab0 cor0
----
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-1007
SELECT ALL - + col1 * - ( + col1 * + col1 ) + col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
1000
17568
2197

skipif mysql # not compatible
query I rowsort label-1007
SELECT ALL - + col1 * - ( + col1 * + col1 ) + col1 / - col0 AS col2 FROM tab1 AS cor0
----
1000
17568
2197

query I rowsort
SELECT 13 * + col0 - - col0 FROM tab1 AS cor0
----
1120
42
896

query I rowsort
SELECT DISTINCT + 62 - - col1 * + col2 AS col0 FROM tab2 AS cor0
----
1596
708
899

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

query I rowsort
SELECT DISTINCT + 66 * cor0.col2 FROM tab0 AS cor0
----
2178
5412
66

query I rowsort
SELECT + ( - col2 ) + cor0.col2 AS col2 FROM tab2 AS cor0
----
0
0
0

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

query I rowsort
SELECT ALL - col0 * - ( - col0 ) * tab2.col0 - + col0 AS col0 FROM tab2
----
-350
-474630
-493118

query I rowsort
SELECT 51 * + 44 FROM tab0, tab1 AS cor0
----
9 values hashing to c80e5a89c0945ca287fe776d3645f02e

query I rowsort
SELECT ALL - tab2.col2 * + 11 - - 15 AS col0 FROM tab2
----
-271
-282
-403

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( 18 AS REAL ) AS col0 FROM tab1 AS cor0
----
18
18
18

query I rowsort
SELECT ALL + cor0.col2 * 72 FROM tab0 AS cor0
----
2376
5904
72

query I rowsort
SELECT ( col1 ) * - col0 + - 9 FROM tab2 AS cor0
----
-1352
-226
-4611

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 31 col2 FROM tab2 cor0
----
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-1021
SELECT - col1 - cor0.col1 DIV - cor0.col1 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-1021
SELECT - col1 - cor0.col1 / - cor0.col1 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT DISTINCT 65 + + col2 AS col2 FROM tab1 cor0
----
119
122
161

query I rowsort
SELECT 65 FROM tab1, tab2 cor0 CROSS JOIN tab2, tab0, tab0 AS cor1, tab1 AS cor2
----
729 values hashing to 861e39188c640bd3b2abc7e4ecff9866

query I rowsort
SELECT DISTINCT + tab2.col1 + - 85 * col1 AS col1 FROM tab2
----
-1428
-2604
-4956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col1 col1 FROM tab1
----
29
74
93

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col2 + - col1 AS REAL ) AS col2 FROM tab1
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 41 ) * - col2 col2 FROM tab2 AS cor0
----
1066
1107
1558

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

query I rowsort
SELECT ALL - 74 * - col0 * col2 + + 54 * col2 FROM tab1 AS cor0
----
14904
273030
573504

query I rowsort
SELECT - - 97 * col1 FROM tab1 AS cor0
----
1261
2522
970

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1032
SELECT DISTINCT 74 + col1 DIV + col2 AS col2 FROM tab0
----
171
75
76

skipif mysql # not compatible
query I rowsort label-1032
SELECT DISTINCT 74 + col1 / + col2 AS col2 FROM tab0
----
171
75
76

query I rowsort
SELECT DISTINCT ( + col0 ) * + col2 + - col1 FROM tab0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-1034
SELECT + 77 + - col0 + - col2 DIV col0 AS col2 FROM tab1
----
-4
13
56

skipif mysql # not compatible
query I rowsort label-1034
SELECT + 77 + - col0 + - col2 / col0 AS col2 FROM tab1
----
-4
13
56

query I rowsort
SELECT - 22 * 73 FROM tab2
----
-1606
-1606
-1606

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1036
SELECT DISTINCT + CAST( + 84 AS SIGNED ) + tab2.col1 AS col0 FROM tab2
----
101
115
143

skipif mysql # not compatible
query I rowsort label-1036
SELECT DISTINCT + CAST ( + 84 AS INTEGER ) + tab2.col1 AS col0 FROM tab2
----
101
115
143

query I rowsort
SELECT + tab0.col1 * - col1 + - tab0.col2 FROM tab0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL - - col0 + cor0.col1 + - col0 * - col2 * + col0 AS col2 FROM tab0 AS cor0
----
1357
19118
649702

query I rowsort
SELECT DISTINCT 95 - cor0.col0 AS col0 FROM tab1 cor0
----
15
31
92

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

query I rowsort
SELECT - ( col1 ) * + col0 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT ALL + 51 * - cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 3d321bd74a48e90cf2e28988de65ea65

query I rowsort
SELECT 80 * + col2 + 67 AS col2 FROM tab2 AS cor0
----
2147
2227
3107

query I rowsort
SELECT ALL - col0 * - col2 + col2 * + col0 AS col1 FROM tab1 AS cor0
----
15360
324
7296

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

query I rowsort
SELECT + + 40 * - col0 - - ( - col1 + col2 ) FROM tab1 AS cor0
----
-2513
-3117
-92

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1047
SELECT DISTINCT - col0 + + cor0.col1 / - cor0.col0 col0 FROM tab2 AS cor0
----
-11
-78
-79

query I rowsort
SELECT + col2 + col1 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + + col1 * 29 * col1 FROM tab1 AS cor0
----
19604
2900
4901

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col2 * + 73 col2 FROM tab0 AS cor0
----
-2376
-5904
-72

query I rowsort
SELECT col1 * ( ( - cor0.col1 ) * ( col0 ) ) AS col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - col0 + col0 * + 88 AS col0 FROM tab0 cor0
----
2088
3045
7743

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

query I rowsort
SELECT cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-1055
SELECT DISTINCT - - 54 DIV - col1 AS col2 FROM tab1 AS cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-1055
SELECT DISTINCT - - 54 / - col1 AS col2 FROM tab1 AS cor0
----
-2
-4
-5

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

query I rowsort
SELECT DISTINCT + - 63 * - cor0.col1 + + cor0.col0 FROM tab0 cor0
----
5442
5822
6146

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

query I rowsort
SELECT 35 FROM tab0, tab0 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # use DIV operator for integer division
query I rowsort label-1060
SELECT 94 DIV - 36 FROM tab1
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-1060
SELECT 94 / - 36 FROM tab1
----
-2
-2
-2

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

query I rowsort
SELECT col0 + - ( col2 ) FROM tab2
----
-20
41
52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1064
SELECT ALL - col2 * 4 + col1 DIV col1 + + col1 FROM tab0 cor0
----
-236
-45
94

skipif mysql # not compatible
query I rowsort label-1064
SELECT ALL - col2 * 4 + col1 / col1 + + col1 FROM tab0 cor0
----
-236
-45
94

query I rowsort
SELECT - col1 + + 45 * col1 FROM tab2 AS cor0
----
1364
2596
748

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

query I rowsort
SELECT cor0.col1 * 93 + col0 FROM tab2 AS cor0
----
1660
2890
5565

query I rowsort
SELECT + col1 + 67 * col1 * col1 FROM tab0 AS cor0
----
495618
554918
630500

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1070
SELECT + 20 * - col2 + - col0 DIV col1 AS col1 FROM tab2 cor0
----
-521
-540
-764

skipif mysql # not compatible
query I rowsort label-1070
SELECT + 20 * - col2 + - col0 / col1 AS col1 FROM tab2 cor0
----
-521
-540
-764

query I rowsort
SELECT 50 * col2 + col1 * - ( cor0.col1 ) AS col2 FROM tab0 AS cor0
----
-4181
-5746
-9359

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 28 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT ALL + 18 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT DISTINCT + 64 * col0 + - col2 AS col2 FROM tab1 AS cor0
----
138
4039
5024

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

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

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

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

query I rowsort
SELECT - ( + col1 ) AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - 40 * 36 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-1440

query I rowsort
SELECT col1 + col1 * - ( + tab1.col2 ) AS col2 FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-1081
SELECT tab1.col0 DIV - tab1.col1 + + col1 FROM tab1
----
26
4
7

skipif mysql # not compatible
query I rowsort label-1081
SELECT tab1.col0 / - tab1.col1 + + col1 FROM tab1
----
26
4
7

query I rowsort
SELECT DISTINCT tab0.col1 * + 8 AS col0 FROM tab0
----
688
728
776

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

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

query I rowsort
SELECT ALL - col0 - + 88 AS col0 FROM tab1 cor0
----
-152
-168
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * - ( ( - col0 ) ) col0 FROM tab2 AS cor0
----
49
6084
6241

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

query I rowsort
SELECT ALL - 97 + ( col0 ) FROM tab2
----
-18
-19
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 * + 19 col0 FROM tab2
----
133
1482
1501

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col1 * + cor0.col1 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 91d49d3adc7877233e272569d01ad74f

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

query I rowsort
SELECT DISTINCT col2 + + 62 FROM tab2
----
100
88
89

query I rowsort
SELECT ALL - - col1 + + col2 * - ( - col0 ) FROM tab2 cor0
----
2087
220
3019

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1095
SELECT col2 + + col2 DIV ( col1 ) AS col0 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-1095
SELECT col2 + + col2 / ( col1 ) AS col0 FROM tab2 AS cor0
----
26
27
40

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

query I rowsort
SELECT DISTINCT 27 + 69 FROM tab2, tab1, tab2 AS cor0
----
96

query I rowsort
SELECT DISTINCT 85 * 76 FROM tab2
----
6460

query I rowsort
SELECT + col2 + col1 * - 89 FROM tab0 AS cor0
----
-7621
-8017
-8632

query I rowsort
SELECT ALL - col0 * - cor0.col2 + 85 FROM tab1 AS cor0
----
247
3733
7765

query I rowsort
SELECT 68 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

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

query I rowsort
SELECT ALL - 40 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT ALL + 83 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 70 col2 FROM tab1 AS cor0
----
-210
-4480
-5600

query I rowsort
SELECT + col1 + 90 FROM tab2 AS cor0
----
107
121
149

query I rowsort
SELECT DISTINCT - 96 AS col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-96

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1109
SELECT - col0 * - CAST( + col2 AS SIGNED ) + - col0 FROM tab1
----
159
3584
7600

skipif mysql # not compatible
query I rowsort label-1109
SELECT - col0 * - CAST ( + col2 AS INTEGER ) + - col0 FROM tab1
----
159
3584
7600

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

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

query I rowsort
SELECT - col2 * - ( col1 ) + - col0 FROM tab0 cor0
----
2814
62
7373

query I rowsort
SELECT + 30 * col2 + col1 AS col0 FROM tab0 AS cor0
----
1076
127
2551

onlyif mysql # use DIV operator for integer division
query I rowsort label-1114
SELECT + + 57 + col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
58
58
58

skipif mysql # not compatible
query I rowsort label-1114
SELECT + + 57 + col0 / + col0 AS col0 FROM tab2 AS cor0
----
58
58
58

query I rowsort
SELECT + ( col2 ) + + col0 + + col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT - col0 * - 46 AS col1 FROM tab1 AS cor0
----
138
2944
3680

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

query I rowsort
SELECT DISTINCT cor0.col2 + - col2 * + ( - 60 ) FROM tab1 cor0
----
3294
3477
5856

query I rowsort
SELECT ALL 76 FROM tab2, tab1 AS cor0, tab2 cor1, tab1, tab1 AS cor2
----
243 values hashing to 2e3c38d7a8933f7f9a9ceb9b36c2e90c

query I rowsort
SELECT DISTINCT + tab1.col0 - - tab1.col1 AS col0 FROM tab1, tab2, tab0 cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1121
SELECT DISTINCT - col0 * col2 + cor0.col0 DIV col0 + col2 * col2 AS col0 FROM tab2 AS cor0
----
-1351
-1557
541

skipif mysql # not compatible
query I rowsort label-1121
SELECT DISTINCT - col0 * col2 + cor0.col0 / col0 + col2 * col2 AS col0 FROM tab2 AS cor0
----
-1351
-1557
541

query I rowsort
SELECT ALL - col0 * + col2 + 91 AS col1 FROM tab1 AS cor0
----
-3557
-71
-7589

onlyif mysql # use DIV operator for integer division
query I rowsort label-1123
SELECT DISTINCT + col1 + - col1 DIV col1 FROM tab1 cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-1123
SELECT DISTINCT + col1 + - col1 / col1 FROM tab1 cor0
----
12
25
9

query I rowsort
SELECT - col0 * 2 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT + col0 - - 67 FROM tab1 cor0
----
131
147
70

query I rowsort
SELECT - col0 + 69 FROM tab2 AS cor0
----
-10
-9
62

query I rowsort
SELECT + col0 * + ( 41 ) + col2 AS col2 FROM tab2 AS cor0
----
314
3224
3277

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

query I rowsort
SELECT col1 * 70 AS col1 FROM tab1 cor0
----
1820
700
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-1130
SELECT + col0 * col2 DIV col1 FROM tab0 cor0
----
0
80
9

skipif mysql # not compatible
query I rowsort label-1130
SELECT + col0 * col2 / col1 FROM tab0 cor0
----
0
80
9

query I rowsort
SELECT ALL ( col2 * + 12 ) FROM tab1
----
1152
648
684

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

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

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

query I rowsort
SELECT col1 * - 7 * col0 FROM tab2 AS cor0
----
-1519
-32214
-9401

query I rowsort
SELECT + ( - cor0.col2 ) - col0 * - col2 FROM tab1 AS cor0
----
108
3591
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-1136
SELECT col2 DIV 49 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1136
SELECT col2 / 49 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT - col2 + 19 + - col0 FROM tab1 AS cor0
----
-102
-157
-38

query I rowsort
SELECT + - col0 - + 57 * - col0 FROM tab1 cor0
----
168
3584
4480

query I rowsort
SELECT + 2 + + 76 + col1 AS col0 FROM tab1 cor0
----
104
88
91

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

skipif mysql # not compatible
query I rowsort
SELECT ALL col1 * + CAST ( + col0 AS REAL ) FROM tab1
----
1040
640
78

query I rowsort
SELECT col0 * + 97 * col1 AS col0 FROM tab2
----
130271
21049
446394

query I rowsort
SELECT DISTINCT col1 + 49 FROM tab2
----
108
66
80

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - col2 * col0 * + ( 82 ) + - col0 * ( col1 ) FROM tab0 AS cor0
----
-606535
-6265
-67008

query I rowsort
SELECT + 75 + + col2 AS col0 FROM tab2 AS cor0
----
101
102
113

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1148
SELECT col2 + 13 DIV col2 col0 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1148
SELECT col2 + 13 / col2 col0 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1149
SELECT + col2 * col1 DIV - col2 + + tab1.col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1149
SELECT + col2 * col1 / - col2 + + tab1.col1 FROM tab1
----
0
0
0

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

query I rowsort
SELECT + col1 + + col1 * col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT 21 + col0 FROM tab0
----
110
45
56

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col1 + + col1 AS col2 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT + col1 * + col0 + 9 * 32 AS col1 FROM tab0 AS cor0
----
2352
3683
8387

query I rowsort
SELECT + ( 76 ) FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT ALL col2 * 55 * col1 FROM tab2
----
35530
46035
84370

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

query I rowsort
SELECT + 20 + col2 * 77 AS col1 FROM tab1 AS cor0
----
4178
4409
7412

query I rowsort
SELECT DISTINCT - 23 * cor0.col2 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1216
-1301
-2195

query I rowsort
SELECT ALL - col2 + col0 - + col1 AS col2 FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT DISTINCT - - 67 + - col1 AS col1 FROM tab2 cor0
----
36
50
8

query I rowsort
SELECT DISTINCT + col0 + col0 + 47 AS col1 FROM tab2 AS cor0
----
203
205
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 27 + col2 col2 FROM tab1 AS cor0
----
27
30
69

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

query I rowsort
SELECT DISTINCT 39 * col1 FROM tab0 AS cor0
----
3354
3549
3783

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

query I rowsort
SELECT + - ( col1 ) + 13 * 97 FROM tab2 AS cor0
----
1202
1230
1244

onlyif mysql # use DIV operator for integer division
query I rowsort label-1168
SELECT + col2 + + 45 DIV + 87 AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1168
SELECT + col2 + + 45 / + 87 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL col1 + - 76 + + col0 FROM tab1
----
-2
-47
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + ( - 8 ) * col2 col2 FROM tab0 AS cor0
----
-288
-43
-745

query I rowsort
SELECT ALL ( + 52 ) FROM tab1 AS cor0
----
52
52
52

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

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

query I rowsort
SELECT DISTINCT - 92 AS col0 FROM tab0, tab0 AS cor0, tab1 cor1
----
-92

query I rowsort
SELECT ALL + 29 * col2 + + cor0.col2 FROM tab0 AS cor0
----
2460
30
990

query I rowsort
SELECT DISTINCT + col1 * - 60 + - col2 FROM tab0 AS cor0
----
-5193
-5542
-5821

query I rowsort
SELECT + + col1 * ( col1 ) + + col2 AS col1 FROM tab1 AS cor0
----
157
265
730

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col2 ) * + col0 - - 92 * - cor0.col1 col0 FROM tab1 AS cor0
----
-2554
-4568
-8876

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( - ( col1 ) ) * 31 col0 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT ALL - 60 + col1 + + col2 * col2 FROM tab0 AS cor0
----
1115
38
6755

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

skipif mysql # not compatible
query I rowsort label-1184
SELECT ALL + CAST ( col2 AS INTEGER ) + col0 FROM tab1 AS cor0
----
121
176
57

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

query I rowsort
SELECT ALL - + 21 * - col0 AS col2 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT DISTINCT 8 + - col0 AS col1 FROM tab1 AS cor0
----
-56
-72
5

query I rowsort
SELECT - 57 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT col2 * 61 + - col2 FROM tab0 AS cor0
----
1980
4920
60

query I rowsort
SELECT DISTINCT 62 + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1186
-1342
-508

query I rowsort
SELECT ALL - col1 * 56 * col0 - - 72 * col0 FROM tab0 AS cor0
----
-113856
-187600
-447136

query I rowsort
SELECT DISTINCT ( 70 ) + col0 * - 86 FROM tab1 AS cor0
----
-188
-5434
-6810

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

query I rowsort
SELECT + + cor0.col2 + col1 * col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT 12 - + ( - col2 + 38 ) * - col1 FROM tab0
----
-3992
3601
442

query I rowsort
SELECT - 91 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 6ec4feac5c635ab8e5da71006896acab

query I rowsort
SELECT ALL + 33 + - col1 + + col2 * 97 AS col0 FROM tab0 AS cor0
----
3148
33
7896

query I rowsort
SELECT DISTINCT - 69 * + col2 AS col0 FROM tab2 AS cor0
----
-1794
-1863
-2622

query I rowsort
SELECT DISTINCT 15 * + 34 FROM tab2
----
510

query I rowsort
SELECT + cor1.col2 AS col1 FROM tab2, tab2 cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL col1 * 91 + cor0.col0 FROM tab1 AS cor0
----
1263
2369
974

query I rowsort
SELECT DISTINCT cor0.col0 * 24 * - col1 - col1 AS col0 FROM tab1 cor0
----
-15370
-1898
-24973

query I rowsort
SELECT + 51 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT + + col1 + + 21 AS col1 FROM tab0 AS cor0
----
107
112
118

query I rowsort
SELECT ALL col2 + col0 * cor0.col0 FROM tab1 AS cor0
----
4153
63
6496

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

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

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

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

query I rowsort
SELECT DISTINCT col2 + col0 - - ( 66 ) FROM tab1
----
123
187
242

query I rowsort
SELECT col0 + 35 AS col0 FROM tab2
----
113
114
42

query I rowsort
SELECT col0 + - col0 + + 12 FROM tab0
----
12
12
12

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

query I rowsort
SELECT DISTINCT col2 + + ( - col1 * - col1 ) FROM tab2
----
327
3507
988

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

query I rowsort
SELECT col1 * + 43 + + col1 * - col0 AS col1 FROM tab2
----
-2065
-612
1116

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

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

query I rowsort
SELECT - tab0.col0 * 50 FROM tab0
----
-1200
-1750
-4450

query I rowsort
SELECT 46 AS col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT + col2 * + col1 * col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
3492
664209
68198

query I rowsort
SELECT - col2 + + 51 * cor0.col1 AS col1 FROM tab0 AS cor0
----
4353
4559
4946

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE col2 + col2 <> NULL
----

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

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

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

query I rowsort
SELECT - col1 + + col0 AS col0 FROM tab0 WHERE NOT NULL IN ( col2 * col1 * + tab0.col0 )
----

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

query I rowsort
SELECT DISTINCT + col1 * col1 - col0 FROM tab0
----
7372
8192
9374

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

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

query I rowsort
SELECT tab2.col1 * - col1 * - col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT ALL + col2 * col1 + col0 - col0 * col1 AS col2 FROM tab0 AS cor0
----
-3263
-548
798

query I rowsort
SELECT + col1 * col2 + - col2 FROM tab1
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - - col0 col1 FROM tab2
----
14
156
158

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

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

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2, tab1 AS cor0 WHERE NOT NULL NOT IN ( + tab0.col2 )
----

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL = NULL OR NOT ( - col2 ) IN ( cor0.col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT + col2 * cor0.col1 * + col2 AS col2 FROM tab1 AS cor0
----
119808
32490
75816

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

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

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) <> + col2
----

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

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

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

query I rowsort
SELECT 53 * - col0 FROM tab1 AS cor0
----
-159
-3392
-4240

onlyif mysql # use DIV operator for integer division
query I rowsort label-1244
SELECT ALL + col1 * cor0.col1 DIV + ( - col2 ) FROM tab0 cor0
----
-100
-224
-9409

skipif mysql # not compatible
query I rowsort label-1244
SELECT ALL + col1 * cor0.col1 / + ( - col2 ) FROM tab0 cor0
----
-100
-224
-9409

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

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

query I rowsort
SELECT - + col0 * 50 FROM tab0 AS cor0
----
-1200
-1750
-4450

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

query I rowsort
SELECT + col2 * + 59 + 51 AS col0 FROM tab2 AS cor0
----
1585
1644
2293

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

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

query I rowsort
SELECT + - col2 + + col0 * - 49 FROM tab0 AS cor0
----
-1209
-1716
-4443

query I rowsort
SELECT ALL 45 * tab1.col2 FROM tab1
----
2430
2565
4320

query I rowsort
SELECT - - col1 * + 48 + + col0 FROM tab1 AS cor0
----
1251
544
704

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

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

query I rowsort
SELECT col0 + - col1 + col2 * - tab2.col1 * + col1 AS col2 FROM tab2
----
-10920
-25971
-90487

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

query I rowsort
SELECT ALL col2 + tab2.col1 FROM tab2 WHERE NOT + col1 IN ( - col2 )
----
55
58
85

query I rowsort
SELECT DISTINCT - tab2.col1 * + col1 - col1 FROM tab2
----
-306
-3540
-992

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 * - col2 + col2 col0 FROM tab2
----
-1449
-591
-779

query I rowsort
SELECT ALL - col1 * - col1 * tab0.col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT ALL + col0 * col1 + + col2 - + col2 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-1263
SELECT ALL tab0.col2 * tab0.col0 + - col0 DIV tab0.col2 col1 FROM tab0
----
0
7297
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1263
SELECT ALL tab0.col2 * tab0.col0 + - col0 / tab0.col2 col1 FROM tab0
----
0
7297
792

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col0 * - col0 col0 FROM tab1 cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - col0 * col1 AS col0 FROM tab1 WHERE NOT col1 * + col1 IN ( - tab1.col0 )
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1267
SELECT ALL col1 * + col2 + col1 DIV col0 FROM tab0
----
2841
7463
99

skipif mysql # not compatible
query I rowsort label-1267
SELECT ALL col1 * + col2 + col1 / col0 FROM tab0
----
2841
7463
99

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

query I rowsort
SELECT ALL col2 + + tab0.col0 * col1 * col2 FROM tab0
----
3396
664200
68145

query I rowsort
SELECT ALL + 75 * - col2 AS col1 FROM tab0
----
-2475
-6150
-75

query I rowsort
SELECT ALL 34 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT DISTINCT col1 * 40 - - col2 * + col2 AS col2 FROM tab1 AS cor0
----
3649
3956
9736

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

query I rowsort
SELECT - + col1 * col1 + col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT + + col2 * - col2 + col0 AS col2 FROM tab2 AS cor0
----
-1365
-598
-722

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1279
SELECT col1 * + CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - col2 + + 94 * col0 * - col0 FROM tab2 cor0
----
-4633
-571922
-586692

query I rowsort
SELECT + col2 * 12 + cor0.col2 FROM tab0 AS cor0
----
1066
13
429

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

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

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

query I rowsort
SELECT + col1 * 99 FROM tab2 AS cor0
----
1683
3069
5841

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 - col0 * 10 + + col0 col0 FROM tab2 cor0
----
-63
-702
-711

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

query I rowsort
SELECT + - 72 + + col0 FROM tab0 AS cor0
----
-37
-48
17

query I rowsort
SELECT DISTINCT - col2 + + col0 + col1 AS col1 FROM tab0
----
131
77
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1290
SELECT + CAST( 79 AS SIGNED ) * col0 FROM tab2
----
553
6162
6241

skipif mysql # not compatible
query I rowsort label-1290
SELECT + CAST ( 79 AS INTEGER ) * col0 FROM tab2
----
553
6162
6241

query I rowsort
SELECT - cor0.col1 * cor0.col1 * 20 + + col2 * cor0.col2 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-18464
-4298
-68918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 + + 17 * col1 col1 FROM tab2 AS cor0
----
1107
406
561

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

query I rowsort
SELECT - - 44 * + col2 AS col1 FROM tab0 AS cor0
----
1452
3608
44

query I rowsort
SELECT ALL - 75 FROM tab2 cor0
----
-75
-75
-75

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

query I rowsort
SELECT + + cor0.col0 + col2 - cor0.col2 * + col0 FROM tab0 AS cor0
----
-7127
-735
1

query I rowsort
SELECT DISTINCT - + 97 + + col1 * col0 * + col2 AS col2 FROM tab0 AS cor0
----
3298
664021
68015

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 96 + + col2 col0 FROM tab2 AS cor0
----
-58
-69
-70

query I rowsort
SELECT + 19 * col0 FROM tab1 AS cor0
----
1216
1520
57

query I rowsort
SELECT ALL + col2 * - col0 + + col0 + col2 AS col0 FROM tab0 AS cor0
----
-7127
-735
1

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1303
SELECT col1 - + col2 * + col0 DIV - col0 AS col1 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-1303
SELECT col1 - + col2 * + col0 / - col0 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL 34 + + col2 AS col2 FROM tab1 AS cor0
----
130
88
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-1305
SELECT DISTINCT + - ( + col0 ) DIV col2 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-1305
SELECT DISTINCT + - ( + col0 ) / col2 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
-11
-13
-26

query I rowsort
SELECT - col1 * cor0.col1 + col0 * col0 FROM tab1 AS cor0
----
-667
3996
6231

query I rowsort
SELECT ALL + - col2 * col2 + col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL ( - 76 ) AS col0 FROM tab0 AS cor0
----
-76
-76
-76

query I rowsort
SELECT DISTINCT - col1 + 18 * col1 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT DISTINCT + 66 * col0 AS col1 FROM tab0 AS cor0
----
1584
2310
5874

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

query I rowsort
SELECT ALL - cor1.col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT + + ( 10 ) AS col0 FROM tab0 AS cor0
----
10
10
10

query I rowsort
SELECT ALL - 34 + 28 * col1 AS col0 FROM tab0 AS cor0
----
2374
2514
2682

query I rowsort
SELECT ALL - col2 + + col0 * + col0 * + col2 AS col0 FROM tab0 AS cor0
----
1224
18975
649440

query I rowsort
SELECT ALL + 45 AS col2 FROM tab1
----
45
45
45

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 + - cor0.col0 col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT ALL + + 24 * col0 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT - col1 * + 42 AS col2 FROM tab1
----
-1092
-420
-546

query I rowsort
SELECT - ( col2 ) * - col2 * + col2 FROM tab2
----
17576
19683
54872

query I rowsort
SELECT - ( 48 ) * col0 + col1 * col2 FROM tab2 AS cor0
----
-2210
-3146
501

query I rowsort
SELECT 7 * col0 + col0 FROM tab0
----
192
280
712

query I rowsort
SELECT ALL col2 * + 6 - - col1 AS col0 FROM tab0
----
103
284
583

query I rowsort
SELECT - 55 + - tab0.col2 + col1 AS col1 FROM tab0
----
-2
-46
41

query I rowsort
SELECT ALL - col2 - - tab1.col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT col0 + col1 - col2 FROM tab1
----
-25
-3
17

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1329
SELECT + 19 DIV col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1329
SELECT + 19 / col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + ( - col1 ) * + col1 * + 4 FROM tab2 AS cor0
----
-1156
-13924
-3844

query I rowsort
SELECT DISTINCT + 13 * 58 + - col1 FROM tab1 AS cor0
----
728
741
744

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

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

query I rowsort
SELECT DISTINCT - + 7 + col2 FROM tab2 AS cor0
----
19
20
31

query I rowsort
SELECT - col1 * - col1 + + col2 AS col0 FROM tab1 AS cor0
----
157
265
730

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

skipif mysql # not compatible
query I rowsort label-1335
SELECT + ( 83 ) / - col0 FROM tab1 AS cor0
----
-1
-1
-27

query I rowsort
SELECT ALL - ( col2 ) * col0 + 60 * col0 AS col1 FROM tab1 AS cor0
----
-2880
18
192

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + 70 * col2 col0 FROM tab2 cor0
----
1879
1921
2677

onlyif mysql # use DIV operator for integer division
query I rowsort label-1340
SELECT 25 + - col2 DIV 78 FROM tab2 AS cor0
----
25
25
25

skipif mysql # not compatible
query I rowsort label-1340
SELECT 25 + - col2 / 78 FROM tab2 AS cor0
----
25
25
25

query I rowsort
SELECT + 87 AS col1 FROM tab1, tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2, tab1 AS cor3
----
729 values hashing to 352918c8a330192f9931ffbf9472da33

query I rowsort
SELECT ALL + col2 + cor0.col2 * + col1 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT col2 * + 19 + + col0 FROM tab2 AS cor0
----
520
572
801

query I rowsort
SELECT - col0 * 67 + - cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
-13261
-2380
-2400

query I rowsort
SELECT - + col0 + + 40 * col1 FROM tab0 cor0
----
3416
3551
3845

query I rowsort
SELECT DISTINCT + - col2 * + ( - cor0.col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL + col2 * 97 FROM tab1 AS cor0
----
5238
5529
9312

query I rowsort
SELECT DISTINCT + col2 + - ( - cor0.col2 ) * col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + + col1 * cor0.col2 + col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

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

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

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

query I rowsort
SELECT ALL col2 * 99 FROM tab1
----
5346
5643
9504

query I rowsort
SELECT DISTINCT + + cor0.col1 * 77 AS col2 FROM tab0 AS cor0
----
6622
7007
7469

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

query I rowsort
SELECT DISTINCT col0 * 14 AS col1 FROM tab2
----
1092
1106
98

query I rowsort
SELECT ALL 27 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) * - col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + 2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT DISTINCT + ( 5 ) AS col0 FROM tab2
----
5

query I rowsort
SELECT - cor0.col1 * ( col1 ) FROM tab0 cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-1361
SELECT - 50 DIV col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-1361
SELECT - 50 / col0 FROM tab0
----
-1
-2
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1362
SELECT 36 DIV - col0 AS col0 FROM tab0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1362
SELECT 36 / - col0 AS col0 FROM tab0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # use DIV operator for integer division
query I rowsort label-1364
SELECT ALL + 6 DIV col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1364
SELECT ALL + 6 / col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 - 11 * col2 AS col1 FROM tab0 AS cor0
----
-277
-811
86

query I rowsort
SELECT DISTINCT + col2 * 86 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT ALL - col0 + 23 FROM tab0 AS cor0
----
-1
-12
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * ( 21 ) + col1 col1 FROM tab1 AS cor0
----
1354
1693
89

query I rowsort
SELECT + 27 + - col1 AS col0 FROM tab0
----
-59
-64
-70

query I rowsort
SELECT DISTINCT + ( + col0 ) + - tab2.col0 FROM tab2
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1371
SELECT DISTINCT - tab2.col0 * col1 + + CAST( col0 AS SIGNED ) AS col0 FROM tab2
----
-1264
-210
-4524

skipif mysql # not compatible
query I rowsort label-1371
SELECT DISTINCT - tab2.col0 * col1 + + CAST ( col0 AS INTEGER ) AS col0 FROM tab2
----
-1264
-210
-4524

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1373
SELECT + col1 DIV 74 + - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1373
SELECT + col1 / 74 + - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1374
SELECT - cor0.col2 DIV ( - 46 * cor0.col0 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1374
SELECT - cor0.col2 / ( - 46 * cor0.col0 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 55 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT - 48 + col2 FROM tab0 AS cor0
----
-15
-47
34

query I rowsort
SELECT ALL + col1 + col1 * + 63 FROM tab2 AS cor0
----
1088
1984
3776

query I rowsort
SELECT ALL - 70 + col1 * - col1 FROM tab1 cor0
----
-170
-239
-746

query I rowsort
SELECT DISTINCT + col2 - + cor0.col0 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-1380
SELECT ALL tab2.col2 * col1 DIV col1 AS col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-1380
SELECT ALL tab2.col2 * col1 / col1 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - 17 + + 75 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0, tab0 cor2
----
58

query I rowsort
SELECT - - col0 + - 41 FROM tab0 AS cor0
----
-17
-6
48

query I rowsort
SELECT - 84 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

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

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

query I rowsort
SELECT ALL - col2 * 22 FROM tab0 AS cor0
----
-1804
-22
-726

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 + - col2 * 17 col2 FROM tab2
----
-364
-452
-567

query I rowsort
SELECT + 77 + - col0 + - col2 AS col0 FROM tab0
----
-94
20
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col2 * tab1.col0 col2 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - col2 + + col0 * 20 + col0 AS col1 FROM tab2
----
120
1612
1621

query I rowsort
SELECT col1 * col1 + - 29 AS col1 FROM tab2
----
260
3452
932

query I rowsort
SELECT + 65 * col2 + ( + col0 * + col2 + col2 ) AS col0 FROM tab2
----
1971
3744
5510

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1393
SELECT CAST( - col0 AS SIGNED ) + - col1 FROM tab0 cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-1393
SELECT CAST ( - col0 AS INTEGER ) + - col1 FROM tab0 cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 23 - col2 * col2 col1 FROM tab2 AS cor0
----
-1421
-653
-706

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

query I rowsort
SELECT ALL - col1 * 48 - col0 * + col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-100464
-36960
-5460

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 21 - - col2 col1 FROM tab0 cor0
----
1839
1993
2038

query I rowsort
SELECT DISTINCT - col0 - + 62 AS col1 FROM tab0 AS cor0
----
-151
-86
-97

query I rowsort
SELECT - 75 + - col2 AS col2 FROM tab1 AS cor0
----
-129
-132
-171

query I rowsort
SELECT + col2 * + 97 - + col0 FROM tab1 AS cor0
----
5235
5465
9232

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

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

query I rowsort
SELECT ( 31 ) * col1 AS col0 FROM tab1
----
310
403
806

query I rowsort
SELECT cor1.col1 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

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

skipif mysql # not compatible
query I rowsort label-1406
SELECT CAST ( NULL AS REAL ) * - col1 + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT ALL ( col2 ) - + col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT col0 * + col1 * + tab1.col0 - 2 FROM tab1
----
232
40958
83198

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

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

query I rowsort
SELECT ALL + col2 * 8 - col0 * col0 AS col1 FROM tab0
----
-1217
-312
-7265

query I rowsort
SELECT 56 + col2 FROM tab0
----
138
57
89

query I rowsort
SELECT ALL 36 * + col1 + - col0 FROM tab2 AS cor0
----
1109
2046
533

query I rowsort
SELECT ALL - col2 * col2 + + ( + col1 ) - col2 * 43 * - col1 FROM tab1 AS cor0
----
21271
44461
57482

query I rowsort
SELECT ALL + col1 - 13 * col2 * 48 FROM tab0
----
-20506
-51077
-527

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col2 AS REAL ) * + col0 - + col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT ALL 69 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT 84 FROM tab2, tab1 cor0
----
84

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

skipif mysql # not compatible
query I rowsort label-1419
SELECT CAST ( col0 AS INTEGER ) + - col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col1 + col1 * col2 AS col0 FROM tab1
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1421
SELECT DISTINCT - - col1 * - col2 + - CAST( + 66 AS SIGNED ) * + col2 * + col0 - + col2 FROM tab1 AS cor0
----
-12150
-241395
-508224

skipif mysql # not compatible
query I rowsort label-1421
SELECT DISTINCT - - col1 * - col2 + - CAST ( + 66 AS INTEGER ) * + col2 * + col0 - + col2 FROM tab1 AS cor0
----
-12150
-241395
-508224

onlyif mysql # use DIV operator for integer division
query I rowsort label-1422
SELECT DISTINCT - col0 DIV col1 + - ( col2 ) * col0 FROM tab2 AS cor0
----
-189
-2029
-3006

skipif mysql # not compatible
query I rowsort label-1422
SELECT DISTINCT - col0 / col1 + - ( col2 ) * col0 FROM tab2 AS cor0
----
-189
-2029
-3006

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1424
SELECT ALL - 81 DIV col0 + + 79 FROM tab2 AS cor0
----
68
78
78

skipif mysql # not compatible
query I rowsort label-1424
SELECT ALL - 81 / col0 + + 79 FROM tab2 AS cor0
----
68
78
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1425
SELECT - 78 DIV col0 + + ( 44 + + col0 * 18 ) AS col1 FROM tab1 AS cor0
----
1195
1484
72

skipif mysql # not compatible
query I rowsort label-1425
SELECT - 78 / col0 + + ( 44 + + col0 * 18 ) AS col1 FROM tab1 AS cor0
----
1195
1484
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1426
SELECT ALL + cor0.col1 + col2 DIV 62 FROM tab2 cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1426
SELECT ALL + cor0.col1 + col2 / 62 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - col2 * col0 * - 98 FROM tab0 AS cor0
----
3430
715204
77616

query I rowsort
SELECT - 42 + + col2 AS col0 FROM tab2 AS cor0
----
-15
-16
-4

query I rowsort
SELECT + col0 * col0 + ( col2 ) AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL col2 * - col2 * tab0.col2 AS col0 FROM tab0
----
-1
-35937
-551368

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 * + 17 col0 FROM tab0
----
1513
408
595

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1433
SELECT DISTINCT + + col2 DIV + col1 + + 38 AS col1 FROM tab2 AS cor0
----
38
40

skipif mysql # not compatible
query I rowsort label-1433
SELECT DISTINCT + + col2 / + col1 + + 38 AS col1 FROM tab2 AS cor0
----
38
40

query I rowsort
SELECT + col0 + + 79 * 94 FROM tab0 AS cor0
----
7450
7461
7515

query I rowsort
SELECT DISTINCT + col2 * - 92 AS col2 FROM tab1 AS cor0
----
-4968
-5244
-8832

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

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

query I rowsort
SELECT + + col1 + 84 * 72 FROM tab2 cor0
----
6065
6079
6107

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

query I rowsort
SELECT DISTINCT + - col0 * + col2 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - 95 AS col2 FROM tab0 AS cor0
----
-95
-95
-95

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + 27 * + col0 col2 FROM tab0 cor0
----
2485
681
946

query I rowsort
SELECT DISTINCT - 48 + 76 * cor0.col1 AS col1 FROM tab1 cor0
----
1928
712
940

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

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

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

query I rowsort
SELECT + col2 * + 46 AS col2 FROM tab1 AS cor0
----
2484
2622
4416

query I rowsort
SELECT DISTINCT + 4 * 37 AS col1 FROM tab0 AS cor0
----
148

query I rowsort
SELECT DISTINCT + ( col0 ) * - col0 FROM tab1
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1449
SELECT - + col0 + col2 DIV + 7 AS col1 FROM tab1 AS cor0
----
-56
-67
4

skipif mysql # not compatible
query I rowsort label-1449
SELECT - + col0 + col2 / + 7 AS col1 FROM tab1 AS cor0
----
-56
-67
4

query I rowsort
SELECT cor0.col1 * - ( 80 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to aecd51c8b7b5398743117a92a0a593fb

onlyif mysql # use DIV operator for integer division
query I rowsort label-1451
SELECT ALL - - 68 DIV col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1451
SELECT ALL - - 68 / col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1452
SELECT ALL col0 * 38 DIV 72 AS col2 FROM tab1 AS cor0
----
1
33
42

skipif mysql # not compatible
query I rowsort label-1452
SELECT ALL col0 * 38 / 72 AS col2 FROM tab1 AS cor0
----
1
33
42

query I rowsort
SELECT + + col0 * + 42 + + ( col0 ) AS col2 FROM tab1 AS cor0
----
129
2752
3440

query I rowsort
SELECT + col2 * - ( 88 ) FROM tab0 AS cor0
----
-2904
-7216
-88

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

query I rowsort
SELECT + - cor0.col1 * - 83 + col1 + col0 FROM tab0 AS cor0
----
7248
7733
8183

query I rowsort
SELECT ALL - - 92 + + cor0.col1 FROM tab1 AS cor0
----
102
105
118

query I rowsort
SELECT ALL + + 19 * col0 FROM tab0 AS cor0
----
1691
456
665

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

query I rowsort
SELECT ALL 55 + - ( col0 ) * - 47 + + col2 FROM tab1
----
250
3120
3911

query I rowsort
SELECT 2 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0, tab0 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 97b43fbe79eecd0bc6921392403b666d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( 78 ) * - col0 col2 FROM tab0 AS cor0
----
-1872
-2730
-6942

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

query I rowsort
SELECT - - cor0.col2 * + cor0.col2 * - col0 AS col1 FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1466
SELECT CAST( NULL AS DECIMAL ) AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1466
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 24 * + col2 - col1 AS col2 FROM tab2
----
565
617
895

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

query I rowsort
SELECT - col0 + + col2 + 9 FROM tab2 AS cor0
----
-32
-43
29

query I rowsort
SELECT - cor0.col0 + cor0.col1 + + col1 AS col0 FROM tab1 AS cor0
----
-44
-54
49

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

query I rowsort
SELECT + col0 * + 91 FROM tab2
----
637
7098
7189

query I rowsort
SELECT ( - 46 * - col2 ) AS col0 FROM tab1
----
2484
2622
4416

query I rowsort
SELECT + col0 + - 12 + + col0 FROM tab1
----
-6
116
148

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1476
SELECT ALL - 38 + - tab2.col1 DIV col0 FROM tab2
----
-38
-38
-42

skipif mysql # not compatible
query I rowsort label-1476
SELECT ALL - 38 + - tab2.col1 / col0 FROM tab2
----
-38
-38
-42

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

query I rowsort
SELECT - - col1 * cor0.col2 + + 14 FROM tab1 AS cor0
----
1262
1418
584

query I rowsort
SELECT DISTINCT + 25 FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab0 cor1
----
25

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

query I rowsort
SELECT ALL - 97 AS col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

query I rowsort
SELECT - 53 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 2876418587c77a182d88db2907b0a51a

query I rowsort
SELECT col0 * 96 + col0 + col2 FROM tab2 AS cor0
----
706
7592
7701

query I rowsort
SELECT 66 * col1 FROM tab2
----
1122
2046
3894

query I rowsort
SELECT - cor0.col0 + + 7 * - col0 FROM tab1 AS cor0
----
-24
-512
-640

query I rowsort
SELECT + 68 * cor0.col0 - + tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 74b57370168ff49a609754b9ec6758a4

query I rowsort
SELECT - ( + 40 ) FROM tab0
----
-40
-40
-40

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

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

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

query I rowsort
SELECT + 36 + ( + col1 ) AS col0 FROM tab2 AS cor0
----
53
67
95

query I rowsort
SELECT ALL + 55 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + col0 * ( 67 ) FROM tab1
----
201
4288
5360

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

query I rowsort
SELECT + 10 * 92 * col2 AS col2 FROM tab0 AS cor0
----
30360
75440
920

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

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

skipif mysql # not compatible
query I rowsort label-1497
SELECT DISTINCT + - CAST ( - 36 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
36

query I rowsort
SELECT + + 34 * - 46 AS col1 FROM tab2 AS cor0
----
-1564
-1564
-1564

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * + 84 + + cor0.col0 col2 FROM tab0 AS cor0
----
-7200
-7555
-8113

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

skipif mysql # not compatible
query I rowsort label-1500
SELECT - - cor0.col1 / ( col1 * col1 ) + - ( - col2 ) FROM tab0 AS cor0
----
1
33
82

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

query I rowsort
SELECT + + cor0.col1 * col1 - + col0 AS col2 FROM tab0 AS cor0
----
7372
8192
9374

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

query I rowsort
SELECT col0 + + col1 * + col2 * col0 + col1 * col2 AS col0 FROM tab2 AS cor0
----
121264
51759
6703

query I rowsort
SELECT ALL + col1 + 4 * col0 FROM tab0 AS cor0
----
182
237
447

query I rowsort
SELECT DISTINCT - + col1 * col1 + + 65 FROM tab2 AS cor0
----
-224
-3416
-896

query I rowsort
SELECT ALL + ( 54 ) AS col1 FROM tab1
----
54
54
54

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1509
SELECT DISTINCT + + ( cor0.col1 ) * + col1 + + col1 DIV col0 FROM tab1 AS cor0
----
100
169
684

skipif mysql # not compatible
query I rowsort label-1509
SELECT DISTINCT + + ( cor0.col1 ) * + col1 + + col1 / col0 FROM tab1 AS cor0
----
100
169
684

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

query I rowsort
SELECT ALL 75 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT DISTINCT col2 * 57 FROM tab2 AS cor0
----
1482
1539
2166

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

query I rowsort
SELECT + col2 + 15 AS col0 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT ALL + col2 * - ( + col2 * - col0 ) - - 46 * + 64 AS col1 FROM tab2 AS cor0
----
117020
55672
8047

onlyif mysql # use DIV operator for integer division
query I rowsort label-1516
SELECT ALL - col0 + col1 * + col2 DIV col2 FROM tab1 cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-1516
SELECT ALL - col0 + col1 * + col2 / col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT ALL + col0 * 97 - col2 AS col0 FROM tab2 AS cor0
----
652
7540
7625

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

query I rowsort
SELECT DISTINCT + col0 * + 43 FROM tab1 AS cor0
----
129
2752
3440

onlyif mysql # use DIV operator for integer division
query I rowsort label-1520
SELECT DISTINCT col2 + cor0.col1 * - col2 DIV col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-1520
SELECT DISTINCT col2 + cor0.col1 * - col2 / col2 FROM tab0 AS cor0
----
-53
-9
-96

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

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

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

query I rowsort
SELECT ALL + col0 * col0 + + col2 * col2 FROM tab0 AS cor0
----
1226
14645
1665

query I rowsort
SELECT ALL + col2 * + 3 AS col0 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT DISTINCT + col2 + col1 + 96 * col1 FROM tab0 AS cor0
----
8375
8909
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-1527
SELECT - 92 + + col2 DIV - 61 FROM tab1
----
-92
-92
-93

skipif mysql # not compatible
query I rowsort label-1527
SELECT - 92 + + col2 / - 61 FROM tab1
----
-92
-92
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1528
SELECT - tab0.col1 * CAST( NULL AS DECIMAL ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1528
SELECT - tab0.col1 * CAST ( NULL AS REAL ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col0 + 18 AS col1 FROM tab2 AS cor0
----
25
96
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1530
SELECT ALL col1 DIV + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1530
SELECT ALL col1 / + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + col0 + - ( 60 ) FROM tab1 AS cor0
----
-57
20
4

query I rowsort
SELECT DISTINCT cor0.col0 + + col1 - 32 * - 98 AS col1 FROM tab2 AS cor0
----
3174
3232
3273

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) * + col1 + + col1 * - col0 * col1 col2 FROM tab1 AS cor0
----
-13351
-1352
-6300

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

query I rowsort
SELECT DISTINCT + 95 FROM tab1 cor0
----
95

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1539
SELECT col1 + - col1 * - CAST ( col1 AS INTEGER ) AS col2 FROM tab0 cor0
----
7482
8372
9506

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

query I rowsort
SELECT DISTINCT - - 21 - col1 AS col2 FROM tab0 AS cor0
----
-65
-70
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 28 + cor0.col2 col0 FROM tab0 AS cor0
----
110
29
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1543
SELECT + col0 + - cor0.col1 * col0 + + cor0.col0 DIV + col2 col2 FROM tab1 AS cor0
----
-575
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1543
SELECT + col0 + - cor0.col1 * col0 + + cor0.col0 / + col2 col2 FROM tab1 AS cor0
----
-575
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-1544
SELECT - + col0 DIV cor0.col0 + - col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-1544
SELECT - + col0 / cor0.col0 + - col0 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT + col1 * cor0.col1 - + col2 AS col0 FROM tab2 cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT col2 + + col1 * col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT - col1 + + col2 * tab2.col2 FROM tab2
----
1427
617
698

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

query I rowsort
SELECT col0 * col1 + - col0 + tab1.col1 FROM tab1
----
101
586
973

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL >= ( NULL ) AND NULL = NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) >= + col0 * col0 AND ( - col1 * - col0 ) BETWEEN ( + col0 ) AND col1 * col1
----

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

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

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

query I rowsort
SELECT + - col0 * col0 + - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT + col2 + - col0 + + col2 AS col2 FROM tab2 WHERE ( - col1 ) >= + col2
----

query I rowsort
SELECT col0 * + tab2.col1 AS col1 FROM tab2 WHERE NOT col1 NOT BETWEEN NULL AND - tab2.col2 * col0
----

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

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

query I rowsort
SELECT - ( col0 * col1 ) + - tab0.col0 * + tab0.col1 AS col1 FROM tab0
----
-16198
-4128
-6790

query I rowsort
SELECT ALL + col2 * - col2 * cor0.col1 AS col1 FROM tab0 cor0
----
-611884
-93654
-97

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

skipif mysql # not compatible
query I rowsort label-1562
SELECT DISTINCT + 4 / - col2 AS col0 FROM tab0 AS cor0
----
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + col2 * + col1 col0 FROM tab0 AS cor0
----
2814
62
7373

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

query I rowsort
SELECT + - 20 AS col0 FROM tab1 AS cor0
----
-20
-20
-20

query I rowsort
SELECT ALL - col2 * cor0.col0 + cor0.col1 - col2 * col1 FROM tab2 AS cor0
----
-3503
-3631
-995

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

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL <= - col0
----

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

query I rowsort
SELECT - col2 + + tab1.col2 * col1 + col1 AS col0 FROM tab1
----
1165
1376
523

query I rowsort
SELECT col2 + tab0.col1 AS col0 FROM tab0
----
119
173
98

query III rowsort
SELECT * FROM tab1 WHERE ( + col1 * - col2 ) IN ( col0 )
----

query I rowsort
SELECT DISTINCT + col0 + col1 * col0 AS col2 FROM tab2 WHERE + col0 * col2 <= ( NULL )
----

query I rowsort
SELECT - col1 AS col1 FROM tab2 WHERE NULL = col2
----

query I rowsort
SELECT ALL - tab1.col0 * + col0 - col2 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT ALL - col1 * + col1 + col1 + col1 FROM tab0 WHERE NOT NULL NOT BETWEEN NULL AND col2
----

query I rowsort
SELECT ALL + col1 + col1 * - tab1.col2 * col2 AS col0 FROM tab1 WHERE NOT col2 NOT IN ( + col2 )
----
-119795
-32480
-75790

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

query I rowsort
SELECT ALL tab1.col0 - tab1.col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT - cor0.col2 + col1 * - ( 18 ) FROM tab1 AS cor0
----
-237
-330
-522

query I rowsort
SELECT col1 * col0 + col0 * - 31 AS col2 FROM tab0 AS cor0
----
1320
2310
5340

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

query I rowsort
SELECT col2 + col0 * + col0 AS col0 FROM tab2
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1584
SELECT ALL cor0.col1 DIV + col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1584
SELECT ALL cor0.col1 / + col0 AS col0 FROM tab0 AS cor0
----
1
2
3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1586
SELECT - + col0 + col1 DIV - ( - col1 ) FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-1586
SELECT - + col0 + col1 / - ( - col1 ) FROM tab0 AS cor0
----
-23
-34
-88

query III rowsort
SELECT * FROM tab0 cor0 WHERE ( col1 ) = NULL
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col1 / col0 = col1 * - col1 + col2
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT ALL + col1 * col0 - col1 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT col2 * col2 + - col1 AS col1 FROM tab1
----
2890
3239
9203

query I rowsort
SELECT - col2 + col0 * col0 FROM tab0
----
1224
543
7839

query I rowsort
SELECT cor0.col0 * + 59 + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 14a62cc167c9e0f5a0baaa18cc94abd7

query I rowsort
SELECT ALL + ( cor0.col0 ) * ( col0 ) + - col2 FROM tab1 AS cor0
----
-45
4039
6304

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1595
SELECT - CAST ( NULL AS REAL ) / + tab1.col0 + col2 / - ( + col0 ) col2 FROM tab1
----
NULL
NULL
NULL

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

query I rowsort
SELECT - 68 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT ( - tab1.col1 + tab1.col0 ) FROM tab1, tab1 cor0
----
9 values hashing to 318a6997409c5decbbc3333c9d493ad3

query I rowsort
SELECT ALL 94 - col0 * col2 * tab2.col1 AS col0 FROM tab2
----
-119558
-50940
-5765

query I rowsort
SELECT DISTINCT 86 - tab2.col2 FROM tab2
----
48
59
60

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

query I rowsort
SELECT + 38 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT ALL + col1 * + col1 * col0 AS col2 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT ALL - col1 + cor0.col0 * - 81 FROM tab0 cor0
----
-2030
-2932
-7300

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 76 col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

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

query I rowsort
SELECT DISTINCT - col1 - col2 * + col2 AS col0 FROM tab1 AS cor0
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-1609
SELECT DISTINCT col2 DIV + col0 + - 73 FROM tab1
----
-55
-72
-73

skipif mysql # not compatible
query I rowsort label-1609
SELECT DISTINCT col2 / + col0 + - 73 FROM tab1
----
-55
-72
-73

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1611
SELECT - col1 + ( cor0.col0 ) * - col2 + - ( col2 ) DIV cor0.col2 FROM tab0 AS cor0
----
-133
-7390
-879

skipif mysql # not compatible
query I rowsort label-1611
SELECT - col1 + ( cor0.col0 ) * - col2 + - ( col2 ) / cor0.col2 FROM tab0 AS cor0
----
-133
-7390
-879

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

query I rowsort
SELECT + col2 + - ( 47 + col0 ) AS col1 FROM tab0 AS cor0
----
-38
-54
-81

query I rowsort
SELECT + + ( + col2 ) + - cor0.col2 AS col2 FROM tab2 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT DISTINCT + 6 FROM tab0 cor0
----
6

query I rowsort
SELECT - + 36 * col2 AS col2 FROM tab1 AS cor0
----
-1944
-2052
-3456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1619
SELECT DISTINCT + - CAST( + col2 AS SIGNED ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1621
SELECT ALL CAST( NULL AS DECIMAL ) + + tab1.col0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1621
SELECT ALL CAST ( NULL AS REAL ) + + tab1.col0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col0 * 68 AS col1 FROM tab1
----
204
4352
5440

query I rowsort
SELECT - + 41 * + ( col0 ) AS col2 FROM tab1 AS cor0
----
-123
-2624
-3280

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

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

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

query I rowsort
SELECT ALL - ( 70 ) AS col1 FROM tab1 AS cor0
----
-70
-70
-70

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

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

skipif mysql # not compatible
query I rowsort label-1628
SELECT col0 / ( col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT CAST ( ( col0 ) AS REAL ) AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - col2 * ( col2 * col0 ) FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT ALL ( col0 ) * + col2 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + - cor0.col1 * col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-1633
SELECT + - ( + col2 ) + + col0 DIV - cor0.col0 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-1633
SELECT + - ( + col2 ) + + col0 / - cor0.col0 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1635
SELECT - col0 + col2 * - col1 DIV col1 FROM tab0 AS cor0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-1635
SELECT - col0 + col2 * - col1 / col1 FROM tab0 AS cor0
----
-171
-36
-57

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

skipif mysql # not compatible
query I rowsort label-1636
SELECT DISTINCT + - CAST ( col0 AS INTEGER ) + cor0.col0 AS col0 FROM tab2 AS cor0
----
0

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

query I rowsort
SELECT - cor0.col1 * col2 + + col2 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( ( - cor0.col1 ) ) + col2 * - col2 col2 FROM tab0 AS cor0
----
-1003
-6633
96

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

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

skipif mysql # not compatible
query I rowsort label-1641
SELECT ALL + 72 / - col1 FROM tab0
----
0
0
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1643
SELECT DISTINCT + 45 DIV col1 FROM tab1
----
1
3
4

skipif mysql # not compatible
query I rowsort label-1643
SELECT DISTINCT + 45 / col1 FROM tab1
----
1
3
4

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

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

query I rowsort
SELECT DISTINCT - col1 + 55 + - col2 AS col2 FROM tab0 AS cor0
----
-118
-43
-64

query I rowsort
SELECT + + col1 + - 4 FROM tab0 AS cor0
----
82
87
93

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

query I rowsort
SELECT + cor0.col0 * + col2 + 90 * cor0.col0 FROM tab1 AS cor0
----
14880
432
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 78 + + col1 - + col1 col2 FROM tab2 AS cor0
----
2028
2106
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-1651
SELECT DISTINCT col0 + col1 DIV 13 AS col2 FROM tab2 AS cor0
----
80
82
9

skipif mysql # not compatible
query I rowsort label-1651
SELECT DISTINCT col0 + col1 / 13 AS col2 FROM tab2 AS cor0
----
80
82
9

query I rowsort
SELECT - col0 + col2 + 97 * + col0 FROM tab1 AS cor0
----
342
6201
7776

query I rowsort
SELECT DISTINCT + - col0 + + 5 * cor0.col2 FROM tab0 AS cor0
----
-30
141
321

query I rowsort
SELECT + + col2 * + col1 * - cor0.col0 + + col0 FROM tab2 cor0
----
-119574
-50955
-5852

query I rowsort
SELECT - cor0.col2 - 55 FROM tab2 AS cor0
----
-81
-82
-93

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

skipif mysql # not compatible
query I rowsort label-1656
SELECT ALL col2 + + CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 + 81 AS col2 FROM tab0 cor0
----
-10
-16
-5

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

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

query I rowsort
SELECT DISTINCT - col0 * + col1 + - col1 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT cor0.col0 - - 45 FROM tab0 AS cor0
----
134
69
80

query I rowsort
SELECT DISTINCT - col2 + + 57 + + col2 AS col2 FROM tab1
----
57

query I rowsort
SELECT cor0.col0 + - col1 + col1 FROM tab1 AS cor0
----
3
64
80

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1664
SELECT ALL - tab0.col0 * CAST( col2 AS SIGNED ) + col2 * - col1 AS col1 FROM tab0
----
-132
-14760
-3630

skipif mysql # not compatible
query I rowsort label-1664
SELECT ALL - tab0.col0 * CAST ( col2 AS INTEGER ) + col2 * - col1 AS col1 FROM tab0
----
-132
-14760
-3630

onlyif mysql # use DIV operator for integer division
query I rowsort label-1665
SELECT ALL col0 DIV col0 + + ( + col2 ) FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-1665
SELECT ALL col0 / col0 + + ( + col2 ) FROM tab2
----
27
28
39

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

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

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

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

query I rowsort
SELECT + col0 - - ( 66 * - col1 ) FROM tab1 AS cor0
----
-1713
-596
-778

query I rowsort
SELECT ALL + + col2 * + 13 FROM tab0 AS cor0
----
1066
13
429

onlyif mysql # use DIV operator for integer division
query I rowsort label-1671
SELECT DISTINCT - - col2 + + col2 * col1 DIV cor0.col0 AS col2 FROM tab1 cor0
----
111
522
65

skipif mysql # not compatible
query I rowsort label-1671
SELECT DISTINCT - - col2 + + col2 * col1 / cor0.col0 AS col2 FROM tab1 cor0
----
111
522
65

query I rowsort
SELECT ALL + col2 * - col0 + col2 * + col1 AS col1 FROM tab2 AS cor0
----
-2356
-494
648

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + ( 84 ) col2 FROM tab1 AS cor0
----
-12
27
30

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

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

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( cor0.col1 AS REAL ) + col0 + - 84 * + col1 AS col2 FROM tab2 AS cor0
----
-1332
-2566
-4819

query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 + col2 FROM tab1 cor0
----
157
265
730

query I rowsort
SELECT + 87 + cor1.col0 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 314435df25d6b45be70954fa0a56577c

query I rowsort
SELECT DISTINCT - - ( - col2 ) + + ( cor0.col2 ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + 34 - col1 FROM tab1 AS cor0
----
21
24
8

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

query I rowsort
SELECT 62 * col1 AS col0 FROM tab0 AS cor0
----
5332
5642
6014

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

query I rowsort
SELECT + + cor0.col1 + - 32 FROM tab1 AS cor0
----
-19
-22
-6

query I rowsort
SELECT ALL - 26 FROM tab0, tab0 AS cor0
----
9 values hashing to 47d0574274146de273829785364ada39

query I rowsort
SELECT + 72 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ALL + ( tab0.col0 ) * col2 FROM tab0
----
35
7298
792

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

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

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

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

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

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

query I rowsort
SELECT + 52 + + cor0.col1 FROM tab2 AS cor0
----
111
69
83

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

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

query I rowsort
SELECT - - col0 + + col1 * - 56 AS col1 FROM tab0 AS cor0
----
-4792
-5007
-5397

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1698
SELECT + col0 * cor0.col0 + CAST( + 58 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
-1517
4037
4576

skipif mysql # not compatible
query I rowsort label-1698
SELECT + col0 * cor0.col0 + CAST ( + 58 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
-1517
4037
4576

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1701
SELECT ALL - col0 * col0 DIV col1 AS col2 FROM tab2
----
-1
-103
-367

skipif mysql # not compatible
query I rowsort label-1701
SELECT ALL - col0 * col0 / col1 AS col2 FROM tab2
----
-1
-103
-367

query I rowsort
SELECT ALL - 52 * cor0.col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-2805
-2900
-4912

onlyif mysql # use DIV operator for integer division
query I rowsort label-1703
SELECT + - ( + col1 ) DIV + cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-1703
SELECT + - ( + col1 ) / + cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT DISTINCT - col2 - 21 AS col1 FROM tab0 AS cor0
----
-103
-22
-54

query I rowsort
SELECT 7 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 83 ) + cor0.col2 col1 FROM tab1 cor0
----
-26
-29
13

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

query I rowsort
SELECT ALL - col0 + - 26 FROM tab1
----
-106
-29
-90

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1711
SELECT - 15 DIV + 22 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1711
SELECT - 15 / + 22 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col1 * tab2.col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to ae9e2bb55fd656eb6c7fb22bc2bb0f90

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
86
91
97

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

query I rowsort
SELECT ALL - + cor0.col1 * + 43 * col0 FROM tab1 AS cor0
----
-27520
-3354
-44720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - col1 col0 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 + + cor0.col0 col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT + col1 * + col2 * col2 + - col1 * col0 FROM tab0
----
-3298
603785
91590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col0 + col1 * col1 col1 FROM tab2 AS cor0
----
1150
3291
5509

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

skipif mysql # not compatible
query I rowsort label-1720
SELECT - - col1 * CAST ( col2 * col0 AS INTEGER ) + - 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 73 * + tab0.col1 + cor0.col2 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d788cd1a73137965203265c12eaea28d

query I rowsort
SELECT DISTINCT + col0 * - 33 AS col2 FROM tab2 AS cor0
----
-231
-2574
-2607

query I rowsort
SELECT + col1 + - col1 * cor0.col2 * col2 AS col2 FROM tab1 AS cor0
----
-119795
-32480
-75790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1724
SELECT ALL - cor0.col2 + CAST( + col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-1724
SELECT ALL - cor0.col2 + CAST ( + col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + col1 * - col0 + + 76 FROM tab2 AS cor0
----
-1267
-141
-4526

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

skipif mysql # not compatible
query I rowsort label-1726
SELECT + + col0 + + CAST ( + col0 + - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - ( cor0.col2 ) FROM tab1, tab2 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT - 16 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col1 * - 83 col0 FROM tab0
----
-7138
-7553
-8051

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + + col2 col2 FROM tab1
----
-1152
-1350
-513

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

query I rowsort
SELECT 5 FROM tab0, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT DISTINCT - col0 * + 99 FROM tab0 AS cor0
----
-2376
-3465
-8811

query I rowsort
SELECT ALL - cor0.col0 + + ( + 31 + col0 ) FROM tab2 AS cor0
----
31
31
31

query I rowsort
SELECT - - col1 * - col1 - - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-182
-5332
-6014

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

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

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

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

query I rowsort
SELECT ALL - + cor0.col2 * + 63 * - col2 AS col2 FROM tab0 AS cor0
----
423612
63
68607

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

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

query I rowsort
SELECT - tab1.col1 + + tab1.col1 * + 19 * + ( cor0.col1 ) FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
81 values hashing to 5322c93f0a2ced5447e17d4c6b53db67

query I rowsort
SELECT DISTINCT - - col1 - - col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 * col2 col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - + 41 + + col2 AS col1 FROM tab0 AS cor0
----
-40
-8
41

query I rowsort
SELECT ALL - - col2 * col1 * cor0.col2 + + ( - cor0.col0 ) - col2 AS col0 FROM tab1 AS cor0
----
119632
32369
75759

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

skipif mysql # not compatible
query I rowsort label-1748
SELECT DISTINCT + CAST ( NULL AS REAL ) * col0 + col1 * - col0 FROM tab1 AS cor0
----
NULL

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

query I rowsort
SELECT ALL - ( + cor0.col2 ) + + col1 - + col0 FROM tab0 AS cor0
----
-80
29
61

query I rowsort
SELECT ALL + tab0.col2 + + ( + tab0.col2 ) FROM tab0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 15 + col1 * + col2 col1 FROM tab1
----
1449
1530
2448

query I rowsort
SELECT ALL - col1 + col1 * - tab0.col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT - 79 + ( col0 ) + col2 * col2 AS col1 FROM tab0 AS cor0
----
-43
1034
6734

query I rowsort
SELECT + + 28 * + col1 + - cor0.col1 FROM tab0 AS cor0
----
2322
2457
2619

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

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

query I rowsort
SELECT DISTINCT - - col2 + + 42 AS col1 FROM tab0 AS cor0
----
124
43
75

query I rowsort
SELECT + + 35 * - col1 + col0 * cor0.col1 + + col1 AS col0 FROM tab1 AS cor0
----
-806
300
598

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

query I rowsort
SELECT ALL + 83 * col1 * col1 + + col2 * col0 AS col2 FROM tab0 AS cor0
----
614660
694621
780982

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1762
SELECT DISTINCT 45 DIV - col0 + 27 FROM tab0 cor0
----
26
27

skipif mysql # not compatible
query I rowsort label-1762
SELECT DISTINCT 45 / - col0 + 27 FROM tab0 cor0
----
26
27

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 * ( - col1 + + col1 * cor0.col1 ) AS col1 FROM tab0 AS cor0
----
628627
745208
903263

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

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

query I rowsort
SELECT DISTINCT + - col0 * col1 * 63 + col0 FROM tab0 cor0
----
-130008
-213850
-510148

query I rowsort
SELECT ALL + 29 * + col1 + 78 * + col1 AS col2 FROM tab0 AS cor0
----
10379
9202
9737

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

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

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

query I rowsort
SELECT DISTINCT + 83 * + cor0.col2 + + ( col0 ) FROM tab2 AS cor0
----
2236
2248
3233

query I rowsort
SELECT + col2 * - 37 AS col1 FROM tab0 AS cor0
----
-1221
-3034
-37

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

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

query I rowsort
SELECT col2 * 86 + 49 + - cor0.col1 * + 66 AS col0 FROM tab2 AS cor0
----
-1609
2195
325

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

query I rowsort
SELECT 93 + - tab0.col1 + tab0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 5d770ec1434a6cba7cf549e578c99cb9

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

query I rowsort
SELECT DISTINCT cor1.col1 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1778
SELECT - col2 * col1 DIV - col0 + + CAST( col0 AS SIGNED ) col1 FROM tab1 AS cor0
----
471
72
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1778
SELECT - col2 * col1 / - col0 + + CAST ( col0 AS INTEGER ) col1 FROM tab1 AS cor0
----
471
72
95

query I rowsort
SELECT + col2 * - col1 + col2 * + 34 * col1 FROM tab1 AS cor0
----
18810
41184
46332

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 81 col0 FROM tab2
----
81

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

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

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

query I rowsort
SELECT ALL 86 * - col0 FROM tab2
----
-602
-6708
-6794

query I rowsort
SELECT - ( 69 ) AS col2 FROM tab1, tab0, tab0 cor0
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT ALL + 70 * col1 * - col2 FROM tab2
----
-107380
-45220
-58590

query I rowsort
SELECT + 85 * col2 AS col1 FROM tab1 AS cor0
----
4590
4845
8160

query I rowsort
SELECT + cor0.col0 + 37 AS col1 FROM tab0 AS cor0
----
126
61
72

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

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

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

query I rowsort
SELECT + cor0.col1 * 85 + - 2 AS col0 FROM tab1 AS cor0
----
1103
2208
848

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

query I rowsort
SELECT DISTINCT + 25 * - cor0.col0 FROM tab2, tab1, tab2 AS cor0
----
-175
-1950
-1975

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

skipif mysql # not compatible
query I rowsort label-1794
SELECT ALL CAST ( NULL AS INTEGER ) * cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query IIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT - + 86 + - ( col1 ) FROM tab2 AS cor0
----
-103
-117
-145

query I rowsort
SELECT DISTINCT + 75 + + 92 AS col0 FROM tab0, tab0 AS cor0
----
167

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 * - col1 + cor0.col0 col1 FROM tab0 AS cor0
----
4754
5094
5370

query I rowsort
SELECT DISTINCT 86 AS col1 FROM tab0 AS cor0
----
86

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

query I rowsort
SELECT - 22 + + cor0.col0 FROM tab0 cor0
----
13
2
67

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

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

query I rowsort
SELECT ( + col2 ) * - col0 + - 91 AS col2 FROM tab2 AS cor0
----
-2119
-280
-3093

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

query I rowsort
SELECT ALL + 19 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT + col2 * 0 FROM tab0
----
0
0
0

query I rowsort
SELECT + cor1.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + col0 AS REAL ) AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT - 38 AS col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT - 91 + + 6 * + col1 * - col0 AS col2 FROM tab0 cor0
----
-12475
-20461
-48685

query I rowsort
SELECT ( - 22 ) + col2 FROM tab2 AS cor0
----
16
4
5

query I rowsort
SELECT ALL - cor1.col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT ALL + - 33 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT ALL 36 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

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

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

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

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

query I rowsort
SELECT ALL col1 - - 77 AS col2 FROM tab0
----
163
168
174

onlyif mysql # use DIV operator for integer division
query I rowsort label-1820
SELECT DISTINCT cor0.col0 + - 65 DIV + 83 col1 FROM tab1, tab2, tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1820
SELECT DISTINCT cor0.col0 + - 65 / + 83 col1 FROM tab1, tab2, tab2 AS cor0
----
7
78
79

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

skipif mysql # not compatible
query I rowsort label-1821
SELECT - + col1 * CAST ( col0 AS INTEGER ) * + col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - col2 * 74 + ( col2 ) AS col0 FROM tab0 AS cor0
----
-2409
-5986
-73

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

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

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

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

query I rowsort
SELECT + col0 + col2 + col0 * - col2 FROM tab1 AS cor0
----
-105
-3527
-7504

query I rowsort
SELECT DISTINCT - 78 * cor0.col1 * + col1 AS col1 FROM tab0 AS cor0
----
-576888
-645918
-733902

query I rowsort
SELECT DISTINCT + + col0 + col0 * col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT - + col2 + - col2 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT ALL - - 6 + + col1 AS col0 FROM tab1 cor0
----
16
19
32

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1832
SELECT DISTINCT - + col0 * - col1 DIV col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-1832
SELECT DISTINCT - + col0 * - col1 / col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - cor0.col1 + - col2 + - 69 FROM tab2 AS cor0
----
-124
-127
-154

query I rowsort
SELECT ALL - 56 * col1 FROM tab1 AS cor0
----
-1456
-560
-728

query I rowsort
SELECT ALL + col2 + 72 - col2 FROM tab2 cor0
----
72
72
72

query I rowsort
SELECT DISTINCT + col0 * - 48 AS col2 FROM tab0 AS cor0
----
-1152
-1680
-4272

query I rowsort
SELECT DISTINCT + col2 * + 64 AS col2 FROM tab2 AS cor0
----
1664
1728
2432

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

query I rowsort
SELECT DISTINCT - + col1 * + col1 + col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT col1 - 15 * - col1 FROM tab2 AS cor0
----
272
496
944

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

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

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

skipif mysql # not compatible
query I rowsort label-1843
SELECT ALL col1 * CAST ( ( + col1 ) * col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT - cor0.col1 + - 43 * col2 FROM tab0 AS cor0
----
-140
-1505
-3617

query I rowsort
SELECT - - col1 + + col1 * - col2 FROM tab1 AS cor0
----
-1235
-1378
-560

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

skipif mysql # not compatible
query I rowsort label-1846
SELECT + 0 / + col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1847
SELECT DISTINCT 84 DIV + cor0.col0 FROM tab1, tab2 AS cor0
----
1
12

skipif mysql # not compatible
query I rowsort label-1847
SELECT DISTINCT 84 / + cor0.col0 FROM tab1, tab2 AS cor0
----
1
12

query I rowsort
SELECT - col2 * 6 AS col0 FROM tab0 AS cor0
----
-198
-492
-6

query I rowsort
SELECT - col1 * col2 - - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + cor0.col1 + - col2 + - 48 col1 FROM tab1 cor0
----
-5
25
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL + col2 * col1 * + col2 AS col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ALL 77 - col2 FROM tab1
----
-19
20
23

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

query I rowsort
SELECT DISTINCT - col1 + + col1 * col0 * - col0 AS col2 FROM tab1 AS cor0
----
-260
-40970
-83213

query I rowsort
SELECT ALL + 17 + col1 + + col1 AS col1 FROM tab1 cor0
----
37
43
69

query I rowsort
SELECT DISTINCT 29 + - col1 FROM tab1 AS cor0
----
16
19
3

query I rowsort
SELECT - col1 + + col2 * - col2 FROM tab0
----
-1175
-6815
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 66 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT + 80 * col1 * col1 + col1 AS col2 FROM tab2 AS cor0
----
23137
278539
76911

onlyif mysql # use DIV operator for integer division
query I rowsort label-1861
SELECT col1 DIV col1 + + col2 DIV 28 col2 FROM tab0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1861
SELECT col1 / col1 + + col2 / 28 col2 FROM tab0
----
1
2
3

query I rowsort
SELECT - 38 * col0 + col0 FROM tab1
----
-111
-2368
-2960

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

query I rowsort
SELECT DISTINCT col2 * col1 + tab1.col0 * + 56 + col0 AS col0 FROM tab1
----
1575
4218
5808

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

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

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

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

query I rowsort
SELECT - 33 FROM tab0, tab0 cor0
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT ALL - col2 * + ( col2 * + col1 ) + - col0 FROM tab1 AS cor0
----
-119888
-32554
-75819

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

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

skipif mysql # not compatible
query I rowsort label-1871
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL cor0.col0 - - col1 * col2 FROM tab0 cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-1873
SELECT ALL - CAST( cor0.col1 AS SIGNED ) DIV - col2 + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1873
SELECT ALL - CAST ( cor0.col1 AS INTEGER ) / - col2 + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1874
SELECT ALL CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1874
SELECT ALL CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
86
91
97

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

query I rowsort
SELECT - ( cor0.col0 ) * col2 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT + 18 + - col2 FROM tab1 AS cor0
----
-36
-39
-78

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

query I rowsort
SELECT ALL - ( 3 ) * col1 + 32 FROM tab2 cor0
----
-145
-19
-61

query I rowsort
SELECT DISTINCT col0 * + col1 - + cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

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

skipif mysql # not compatible
query I rowsort label-1881
SELECT DISTINCT CAST ( NULL AS REAL ) * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col1 + 37 FROM tab2 AS cor0
----
54
68
96

query I rowsort
SELECT ALL + col0 * - cor0.col2 + col0 + col0 * col0 FROM tab1 AS cor0
----
-1200
-150
512

query I rowsort
SELECT DISTINCT col0 + - 21 * - col0 FROM tab2 cor0
----
154
1716
1738

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

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

query I rowsort
SELECT col0 + cor0.col1 * + 50 FROM tab1 AS cor0
----
1303
564
730

query I rowsort
SELECT DISTINCT + col0 + cor0.col2 * - cor0.col0 FROM tab2 cor0
----
-182
-1950
-2923

query I rowsort
SELECT - 54 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

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

skipif mysql # not compatible
query I rowsort label-1889
SELECT ALL + cor0.col1 + - CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - cor0.col2 - - cor0.col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1891
SELECT col2 * CAST( + 32 AS SIGNED ) + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
1924
2404
3241

skipif mysql # not compatible
query I rowsort label-1891
SELECT col2 * CAST ( + 32 AS INTEGER ) + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
1924
2404
3241

onlyif mysql # use DIV operator for integer division
query I rowsort label-1892
SELECT + cor0.col2 * col1 DIV col1 + col0 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-1892
SELECT + cor0.col2 * col1 / col1 + col0 FROM tab0 AS cor0
----
171
36
57

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

query I rowsort
SELECT + 46 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1895
SELECT DISTINCT CAST( NULL AS SIGNED ) * 45 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-1895
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 45 FROM tab1
----
NULL

query I rowsort
SELECT ALL + 61 * col2 AS col0 FROM tab0 cor0
----
2013
5002
61

query I rowsort
SELECT 11 * + 96 - col2 AS col0 FROM tab1 AS cor0
----
1002
960
999

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

query I rowsort
SELECT DISTINCT + + 88 AS col1 FROM tab2 AS cor0
----
88

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1901
SELECT ALL + CAST( - col0 AS SIGNED ) * - cor0.col0 + col0 * cor0.col1 FROM tab0 cor0
----
16020
2640
4620

skipif mysql # not compatible
query I rowsort label-1901
SELECT ALL + CAST ( - col0 AS INTEGER ) * - cor0.col0 + col0 * cor0.col1 FROM tab0 cor0
----
16020
2640
4620

query I rowsort
SELECT - + col2 * - 16 + col0 AS col1 FROM tab1 AS cor0
----
1616
867
976

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

query I rowsort
SELECT ALL + 64 * 59 AS col2 FROM tab1 AS cor0
----
3776
3776
3776

query I rowsort
SELECT - - col0 * col1 - - col0 * - 43 FROM tab0 AS cor0
----
1032
1890
4272

query I rowsort
SELECT DISTINCT + cor0.col2 * 50 FROM tab0 AS cor0
----
1650
4100
50

query I rowsort
SELECT ALL 38 + col2 FROM tab1 AS cor0
----
134
92
95

query I rowsort
SELECT - - col2 + + 41 AS col2 FROM tab0 AS cor0
----
123
42
74

query I rowsort
SELECT ALL + cor0.col2 * + 92 FROM tab1 AS cor0
----
4968
5244
8832

query I rowsort
SELECT 10 * - col0 + + col0 AS col0 FROM tab2 AS cor0
----
-63
-702
-711

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

query I rowsort
SELECT + col1 + col2 * - col1 * + 79 + col2 FROM tab0 AS cor0
----
-224083
-589325
-7565

onlyif mysql # use DIV operator for integer division
query I rowsort label-1913
SELECT + col1 DIV + cor0.col1 + col0 * 62 + + cor0.col2 FROM tab0 AS cor0
----
1522
2172
5601

skipif mysql # not compatible
query I rowsort label-1913
SELECT + col1 / + cor0.col1 + col0 * 62 + + cor0.col2 FROM tab0 AS cor0
----
1522
2172
5601

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1915
SELECT 48 DIV + col1 + ( - col0 * col0 ) + 19 col2 FROM tab1 AS cor0
----
-4073
-6378
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1915
SELECT 48 / + col1 + ( - col0 * col0 ) + 19 col2 FROM tab1 AS cor0
----
-4073
-6378
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-1916
SELECT DISTINCT + col1 DIV - cor0.col0 + + 5 col0 FROM tab0 AS cor0
----
2
3
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1916
SELECT DISTINCT + col1 / - cor0.col0 + + 5 col0 FROM tab0 AS cor0
----
2
3
4

query I rowsort
SELECT - 51 + + col2 AS col0 FROM tab1 AS cor0
----
3
45
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + col1 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + 11 * col0 + - col0 * 78 AS col2 FROM tab2 AS cor0
----
-469
-5226
-5293

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 53 col1 FROM tab0 AS cor0
----
-53
-53
-53

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + ( col1 + col1 ) col0 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT ALL + - 34 FROM tab1, tab0 AS cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

onlyif mysql # use DIV operator for integer division
query I rowsort label-1924
SELECT DISTINCT - col0 DIV - 44 FROM tab0 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-1924
SELECT DISTINCT - col0 / - 44 FROM tab0 AS cor0
----
0
2

query I rowsort
SELECT - ( - 9 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL col2 * + 25 AS col0 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT ALL 79 - - col2 AS col0 FROM tab0
----
112
161
80

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

skipif mysql # not compatible
query I rowsort label-1928
SELECT + + CAST ( col1 AS INTEGER ) + + col2 * - col0 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 65 ) col0 FROM tab0 AS cor0
----
65
65
65

query I rowsort
SELECT - col1 + + 4 FROM tab2
----
-13
-27
-55

query I rowsort
SELECT ALL + ( - 17 * col1 ) AS col1 FROM tab2
----
-1003
-289
-527

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - ( col1 ) col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT col0 * - 57 + + col1 AS col1 FROM tab1
----
-145
-3638
-4547

query I rowsort
SELECT DISTINCT + 24 FROM tab1, tab0, tab2 AS cor0
----
24

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1937
SELECT + CAST( ( col0 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-1937
SELECT + CAST ( ( col0 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1940
SELECT col0 * col2 DIV - 38 FROM tab2 AS cor0
----
-4
-53
-79

skipif mysql # not compatible
query I rowsort label-1940
SELECT col0 * col2 / - 38 FROM tab2 AS cor0
----
-4
-53
-79

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

query I rowsort
SELECT DISTINCT - col0 + + 9 + + col0 * col0 FROM tab1 AS cor0
----
15
4041
6329

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + tab0.col0 + 8 col2 FROM tab0
----
179
44
65

query I rowsort
SELECT tab2.col2 + col1 + col2 * col2 AS col1 FROM tab2
----
1499
761
787

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

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

query I rowsort
SELECT ALL - + col2 * + ( - col2 ) * - ( col2 ) AS col0 FROM tab2 cor0
----
-17576
-19683
-54872

query I rowsort
SELECT + + 44 * 16 + - col1 * - 45 FROM tab2 AS cor0
----
1469
2099
3359

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1949
SELECT DISTINCT + CAST( - col1 AS SIGNED ) * - col1 + 24 AS col0 FROM tab1 AS cor0
----
124
193
700

skipif mysql # not compatible
query I rowsort label-1949
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) * - col1 + 24 AS col0 FROM tab1 AS cor0
----
124
193
700

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

query I rowsort
SELECT ALL + 92 + + col1 * col1 FROM tab2 AS cor0
----
1053
3573
381

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

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

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

query I rowsort
SELECT - col2 * col0 + 86 AS col2 FROM tab1 cor0
----
-3562
-7594
-76

query I rowsort
SELECT DISTINCT 62 * - col1 + - col2 AS col0 FROM tab0 AS cor0
----
-5365
-5724
-6015

query I rowsort
SELECT ALL + col1 * + col0 + + ( col0 ) AS col1 FROM tab1 AS cor0
----
1120
704
81

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

query I rowsort
SELECT ALL + col2 * - cor0.col2 * - col2 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT ALL - col2 + ( col1 ) * cor0.col1 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT - - cor0.col1 + col0 * col0 AS col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT - col1 * ( ( + col0 ) ) + - col2 * + col1 AS col1 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT - + col2 * 78 FROM tab1 AS cor0
----
-4212
-4446
-7488

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1965
SELECT + - col0 * col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-1965
SELECT + - col0 * col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
-1
-10
-11

query I rowsort
SELECT ALL - col0 * + 74 * - cor0.col2 - col0 AS col0 FROM tab2 AS cor0
----
13979
149994
222069

onlyif mysql # use DIV operator for integer division
query I rowsort label-1967
SELECT ( col1 ) DIV - col2 + tab1.col2 col0 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1967
SELECT ( col1 ) / - col2 + tab1.col2 col0 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1968
SELECT DISTINCT col0 * col0 DIV col1 AS col2 FROM tab0
----
12
6
87

skipif mysql # not compatible
query I rowsort label-1968
SELECT DISTINCT col0 * col0 / col1 AS col2 FROM tab0
----
12
6
87

query I rowsort
SELECT DISTINCT - col1 + - ( - col1 ) * - cor0.col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

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

skipif mysql # not compatible
query I rowsort label-1970
SELECT DISTINCT - col0 / col1 AS col0 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1971
SELECT ALL col1 DIV + 66 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1971
SELECT ALL col1 / + 66 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col1 * 90 FROM tab0 AS cor0
----
-7740
-8190
-8730

query I rowsort
SELECT DISTINCT col0 * 44 + col1 FROM tab0 cor0
----
1142
1637
4007

query I rowsort
SELECT + 32 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT + - 83 * - col2 FROM tab2 AS cor0
----
2158
2241
3154

query I rowsort
SELECT ( + 64 ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
1664
640
832

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

query I rowsort
SELECT col1 + + ( - 93 ) FROM tab2
----
-34
-62
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 17 * + col1 + - cor0.col0 col2 FROM tab2 AS cor0
----
210
520
925

query I rowsort
SELECT DISTINCT 31 * - col2 FROM tab2 AS cor0
----
-1178
-806
-837

query I rowsort
SELECT DISTINCT 11 * col1 + col2 FROM tab2 AS cor0
----
225
368
675

query I rowsort
SELECT ALL + 2 * col0 + + cor0.col1 * col2 + - cor0.col2 * - 49 * 80 AS col0 FROM tab0 cor0
----
132246
329080
4087

query I rowsort
SELECT ALL + + ( - col0 ) * + cor0.col0 * + ( col2 ) AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

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

query I rowsort
SELECT col2 * + 66 - - tab2.col1 AS col0 FROM tab2
----
1775
1813
2525

query I rowsort
SELECT ( tab2.col0 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + 17 + 37 AS col1 FROM tab0
----
54

query I rowsort
SELECT + ( col0 ) * col2 + tab2.col2 + col0 * col1 FROM tab2
----
433
4383
6656

query I rowsort
SELECT ALL + 7 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT ALL 14 * + 8 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 121b64fd841a20f87520daa7774d37c9

query I rowsort
SELECT DISTINCT + ( + col1 + 47 ) * ( tab0.col2 ) AS col1 FROM tab0
----
11316
144
4389

query I rowsort
SELECT DISTINCT + - cor0.col1 * col0 * ( + 48 * col2 ) FROM tab2 cor0
----
-2449632
-281232
-5743296

query I rowsort
SELECT ALL - - cor0.col2 * + col2 + 3 FROM tab0 AS cor0
----
1092
4
6727

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1995
SELECT ( col0 ) DIV - 79 + - 20 FROM tab0 AS cor0
----
-20
-20
-21

skipif mysql # not compatible
query I rowsort label-1995
SELECT ( col0 ) / - 79 + - 20 FROM tab0 AS cor0
----
-20
-20
-21

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

query I rowsort
SELECT DISTINCT + ( - col0 ) - 34 FROM tab2 AS cor0
----
-112
-113
-41

query I rowsort
SELECT - ( col0 ) * + col0 + 97 * - col1 FROM tab0 AS cor0
----
-10634
-16748
-8918

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

query I rowsort
SELECT ALL - - col2 * + col1 + - 16 FROM tab2 AS cor0
----
1518
630
821

query I rowsort
SELECT DISTINCT - + col2 + - col2 * - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL + col1 * - col2 * col2 + + col2 FROM tab0
----
-611802
-93621
-96

query I rowsort
SELECT - col0 * + col2 - ( col2 + col1 * - col1 ) FROM tab1 AS cor0
----
-3605
-7607
460

query I rowsort
SELECT - col2 + - 37 * tab1.col2 + - 7 * tab1.col0 AS col0 FROM tab1
----
-2073
-2614
-4208

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

query I rowsort
SELECT + 6 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT DISTINCT - col2 * col0 + col0 * cor0.col0 FROM tab2 AS cor0
----
-140
3239
4056

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - ( - cor0.col1 ) col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2009
SELECT DISTINCT col0 * col2 DIV + col1 - - col2 * tab1.col1 AS col1 FROM tab1
----
1410
1838
934

skipif mysql # not compatible
query I rowsort label-2009
SELECT DISTINCT col0 * col2 / + col1 - - col2 * tab1.col1 AS col1 FROM tab1
----
1410
1838
934

query I rowsort
SELECT ALL 70 * col2 FROM tab1
----
3780
3990
6720

query I rowsort
SELECT ( ( - col1 ) ) * - col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 65 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT + col0 * - ( col1 ) + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2014
SELECT ALL CAST( 78 AS SIGNED ) + col1 AS col1 FROM tab2 AS cor0
----
109
137
95

skipif mysql # not compatible
query I rowsort label-2014
SELECT ALL CAST ( 78 AS INTEGER ) + col1 AS col1 FROM tab2 AS cor0
----
109
137
95

query I rowsort
SELECT ALL - - 22 * col1 AS col2 FROM tab1 cor0
----
220
286
572

query I rowsort
SELECT 77 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 38f487c2147ee2fe05527e38c5e0503b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2017
SELECT + col1 DIV + 69 + col1 col2 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2017
SELECT + col1 / + 69 + col1 col2 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT + 3 AS col2 FROM tab0
----
3

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

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

query I rowsort
SELECT col1 * col2 - - 73 FROM tab1 AS cor0
----
1321
1477
643

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2022
SELECT ALL + CAST( cor0.col1 AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif mysql # not compatible
query I rowsort label-2022
SELECT ALL + CAST ( cor0.col1 AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT 21 * - col2 + - 65 FROM tab2 AS cor0
----
-611
-632
-863

query I rowsort
SELECT + - col2 - col2 AS col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 - 75 AS col1 FROM tab0 AS cor0
----
22
2763
7387

query I rowsort
SELECT 59 * - col1 AS col0 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT ALL - col2 * + col1 * 25 FROM tab0 AS cor0
----
-186550
-2425
-70950

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 63 col1 FROM tab1, tab2 cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT - col2 * - col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
0
1056
6642

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

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

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

query I rowsort
SELECT DISTINCT + ( - col1 ) * cor0.col1 + - col1 AS col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT col0 + + 48 * 29 FROM tab2 AS cor0
----
1399
1470
1471

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

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

query I rowsort
SELECT ALL + + col2 * ( - col1 ) + col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT col0 * ( - 52 ) FROM tab0 cor0
----
-1248
-1820
-4628

query I rowsort
SELECT - + col1 * 80 AS col1 FROM tab0 AS cor0
----
-6880
-7280
-7760

query I rowsort
SELECT - col1 * + col0 + - col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

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

query I rowsort
SELECT ALL 19 * ( col1 ) AS col2 FROM tab2 AS cor0
----
1121
323
589

query I rowsort
SELECT - 4 * col1 FROM tab2 AS cor0
----
-124
-236
-68

query I rowsort
SELECT ALL 22 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to c6f049334398e3533dd6996714479a2f

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab2 cor1, tab0 AS cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT ALL 10 * col2 * col0 FROM tab2 AS cor0
----
1890
20280
30020

query I rowsort
SELECT ALL + 81 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT + col2 + - 33 * col1 * col0 FROM tab1 AS cor0
----
-21063
-2520
-34224

onlyif mysql # use DIV operator for integer division
query I rowsort label-2050
SELECT + - col0 * 94 DIV col0 AS col1 FROM tab2 AS cor0
----
-94
-94
-94

skipif mysql # not compatible
query I rowsort label-2050
SELECT + - col0 * 94 / col0 AS col1 FROM tab2 AS cor0
----
-94
-94
-94

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

query I rowsort
SELECT ALL - col0 + cor0.col0 * + ( + col1 * col1 ) FROM tab2 AS cor0
----
22752
271440
6720

onlyif mysql # use DIV operator for integer division
query I rowsort label-2053
SELECT DISTINCT - col1 DIV 25 FROM tab0 AS cor0
----
-3

skipif mysql # not compatible
query I rowsort label-2053
SELECT DISTINCT - col1 / 25 FROM tab0 AS cor0
----
-3

query I rowsort
SELECT DISTINCT - col2 - ( 29 ) FROM tab1 AS cor0
----
-125
-83
-86

query I rowsort
SELECT ALL - - 65 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

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

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

skipif mysql # not compatible
query I rowsort label-2057
SELECT ALL col0 / + 60 AS col0 FROM tab0
----
0
0
1

query I rowsort
SELECT tab1.col0 * ( - col0 ) FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT + cor0.col1 * 11 * + col2 + col2 FROM tab2 AS cor0
----
16900
7144
9234

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

query I rowsort
SELECT - + col1 * ( - 46 ) AS col1 FROM tab0 AS cor0
----
3956
4186
4462

query I rowsort
SELECT DISTINCT + col1 * - col0 * + cor0.col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 + CAST ( col1 AS REAL ) FROM tab1 cor0
----
-28
-47
-83

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2065
SELECT col1 + col2 DIV 56 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2065
SELECT col1 + col2 / 56 FROM tab2
----
17
31
59

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

query I rowsort
SELECT DISTINCT - tab0.col0 * tab0.col1 + - col2 AS col0 FROM tab0
----
-2097
-3396
-8181

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

query I rowsort
SELECT ALL col0 * col1 * col1 AS col0 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT - col0 * tab1.col1 * col1 + col1 AS col1 FROM tab1
----
-13507
-2002
-6390

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col1 * + col0 col0 FROM tab1
----
576
75
960

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL BETWEEN ( + col1 ) AND col2 * + col1
----

query I rowsort
SELECT ALL - col2 * - col2 * col2 FROM tab0
----
1
35937
551368

query I rowsort
SELECT ALL col2 * - col1 * col0 + - tab0.col0 AS col0 FROM tab0
----
-3430
-664207
-68136

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

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

query I rowsort
SELECT ALL + col1 + - col2 + + col2 AS col0 FROM tab0 cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2078
SELECT ALL + col2 + col2 * + CAST( 53 AS SIGNED ) * col2 AS col2 FROM tab2 cor0
----
35854
38664
76570

skipif mysql # not compatible
query I rowsort label-2078
SELECT ALL + col2 + col2 * + CAST ( 53 AS INTEGER ) * col2 AS col2 FROM tab2 cor0
----
35854
38664
76570

query I rowsort
SELECT DISTINCT + - ( - cor0.col1 ) + 26 AS col0 FROM tab1 cor0
----
36
39
52

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

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

query I rowsort
SELECT ALL - + cor0.col2 * col2 - + 37 AS col1 FROM tab1 AS cor0
----
-2953
-3286
-9253

query I rowsort
SELECT ALL 74 AS col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col1 + col2 * - cor0.col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT ALL 13 + col1 - - 42 AS col2 FROM tab0 AS cor0
----
141
146
152

query I rowsort
SELECT + 44 AS col1 FROM tab0 cor0
----
44
44
44

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

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

query I rowsort
SELECT tab1.col1 + 90 FROM tab1, tab1 AS cor0
----
9 values hashing to 4ed593bf6cd0fce7ae36d721382ce1ab

query I rowsort
SELECT DISTINCT 81 + col2 FROM tab2 cor0
----
107
108
119

query I rowsort
SELECT 12 * col2 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-14976
-16848
-6840

query I rowsort
SELECT DISTINCT + 65 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT 4 AS col0 FROM tab2 AS cor0
----
4
4
4

query I rowsort
SELECT ALL - + 42 * col2 * 51 FROM tab1 AS cor0
----
-115668
-122094
-205632

onlyif mysql # use DIV operator for integer division
query I rowsort label-2095
SELECT + cor0.col0 DIV - cor0.col1 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1347
-217
-4603

skipif mysql # not compatible
query I rowsort label-2095
SELECT + cor0.col0 / - cor0.col1 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1347
-217
-4603

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

query I rowsort
SELECT ALL - + col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

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

query I rowsort
SELECT ALL - + col1 * ( 45 * col0 ) + cor0.col2 * - col0 AS col2 FROM tab2 AS cor0
----
-209118
-63437
-9954

query I rowsort
SELECT DISTINCT cor0.col1 * + 22 FROM tab2, tab0 AS cor0
----
1892
2002
2134

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

query I rowsort
SELECT 68 * col0 * - col2 AS col0 FROM tab1 AS cor0
----
-11016
-248064
-522240

query I rowsort
SELECT + 82 * - 19 AS col0 FROM tab1 AS cor0
----
-1558
-1558
-1558

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

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

query I rowsort
SELECT + ( 59 ) * - col1 FROM tab2
----
-1003
-1829
-3481

query I rowsort
SELECT ALL - 48 AS col1 FROM tab1
----
-48
-48
-48

query I rowsort
SELECT - col2 + - col2 * - col0 + + col0 AS col0 FROM tab0 AS cor0
----
69
7305
783

query I rowsort
SELECT + 73 * - 86 FROM tab1 AS cor0
----
-6278
-6278
-6278

onlyif mysql # use DIV operator for integer division
query I rowsort label-2109
SELECT - 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-2109
SELECT - col2 + col1 / - col0 col0 FROM tab1 AS cor0
----
-57
-62
-96

query I rowsort
SELECT DISTINCT - + col2 * 19 FROM tab0 AS cor0
----
-1558
-19
-627

query I rowsort
SELECT + col0 + - cor0.col2 + ( 36 ) AS col0 FROM tab1 AS cor0
----
-15
20
43

query I rowsort
SELECT ALL - cor0.col1 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT 9 + + col2 + - col0 AS col2 FROM tab1
----
2
25
60

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2115
SELECT + CAST( col1 AS SIGNED ) + col0 FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort label-2115
SELECT + CAST ( col1 AS INTEGER ) + col0 FROM tab2
----
137
38
96

query I rowsort
SELECT + cor0.col2 * 74 AS col2 FROM tab0 AS cor0
----
2442
6068
74

query I rowsort
SELECT - col0 + - 87 * - ( + cor0.col2 ) AS col0 FROM tab1 cor0
----
4695
4895
8272

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

query I rowsort
SELECT 2 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT - 22 * + col1 AS col0 FROM tab1 cor0
----
-220
-286
-572

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2122
SELECT 24 - col2 DIV col0 AS col2 FROM tab2 AS cor0
----
21
24
24

skipif mysql # not compatible
query I rowsort label-2122
SELECT 24 - col2 / col0 AS col2 FROM tab2 AS cor0
----
21
24
24

query I rowsort
SELECT - - ( + col2 ) - cor0.col2 FROM tab0 AS cor0
----
0
0
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2125
SELECT + ( 21 ) DIV - col0 + + 28 * col0 * col1 FROM tab0 AS cor0
----
226772
57792
95060

skipif mysql # not compatible
query I rowsort label-2125
SELECT + ( 21 ) / - col0 + + 28 * col0 * col1 FROM tab0 AS cor0
----
226772
57792
95060

query I rowsort
SELECT col1 * 30 AS col0 FROM tab2
----
1770
510
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-2127
SELECT + 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-2127
SELECT + col2 / col1 col1 FROM tab1
----
2
5
7

query I rowsort
SELECT + 67 * + 45 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 3d3f102f82145555faf0fad636d83dde

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

skipif mysql # not compatible
query I rowsort label-2129
SELECT DISTINCT col0 / + ( col1 ) FROM tab2
----
0
1
4

query I rowsort
SELECT - 49 + + col2 FROM tab1 AS cor0
----
47
5
8

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

query I rowsort
SELECT + ( + col1 ) * 61 AS col1 FROM tab1 AS cor0
----
1586
610
793

query I rowsort
SELECT + 18 * col1 AS col1 FROM tab1 cor0
----
180
234
468

query I rowsort
SELECT ALL + ( + 67 + + col0 ) FROM tab2
----
145
146
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-2135
SELECT ALL - col0 + - col0 DIV + col1 FROM tab2 cor0
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-2135
SELECT ALL - col0 + - col0 / + col1 FROM tab2 cor0
----
-7
-79
-83

query I rowsort
SELECT DISTINCT + col1 + - col1 * cor0.col1 - col0 FROM tab1 cor0
----
-154
-236
-653

query I rowsort
SELECT ALL 37 + + col2 AS col2 FROM tab0 AS cor0
----
119
38
70

query I rowsort
SELECT ALL + - col0 * - 10 + + cor0.col1 + col1 AS col0 FROM tab0 cor0
----
1072
412
544

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

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

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

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

query I rowsort
SELECT ALL col1 - 30 FROM tab0 AS cor0
----
56
61
67

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

skipif mysql # not compatible
query I rowsort label-2142
SELECT DISTINCT col0 * + col0 * CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0
----
NULL

query I rowsort
SELECT tab1.col0 * col0 * - ( col1 ) - - col1 FROM tab1
----
-208
-40950
-83187

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

query I rowsort
SELECT cor0.col0 * 86 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c1ffe1d49dc434366f4e5a12cf3dd55a

query I rowsort
SELECT - col2 * col1 - + col2 * col0 AS col1 FROM tab0
----
-132
-14760
-3630

query I rowsort
SELECT DISTINCT + cor0.col1 * col1 + col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL - 4 FROM tab2, tab1 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

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

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

query I rowsort
SELECT + + 42 * - cor0.col1 * + col0 FROM tab0 AS cor0
----
-142590
-340158
-86688

onlyif mysql # use DIV operator for integer division
query I rowsort label-2152
SELECT col2 + col2 DIV + col0 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-41
-52
23

skipif mysql # not compatible
query I rowsort label-2152
SELECT col2 + col2 / + col0 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-41
-52
23

query I rowsort
SELECT - + 59 * 45 - col2 AS col2 FROM tab1 AS cor0
----
-2709
-2712
-2751

query I rowsort
SELECT - 16 * col0 FROM tab0 cor0
----
-1424
-384
-560

query I rowsort
SELECT - - col2 + - col0 + - cor0.col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT 40 * cor1.col1 AS col1 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to f690cfc113fcbc4e8309efe2dd405161

query I rowsort
SELECT - col1 + col0 * + 47 AS col1 FROM tab2 AS cor0
----
298
3607
3696

onlyif mysql # use DIV operator for integer division
query I rowsort label-2158
SELECT ALL + col2 + cor0.col1 DIV 5 AS col1 FROM tab0 AS cor0
----
100
20
50

skipif mysql # not compatible
query I rowsort label-2158
SELECT ALL + col2 + cor0.col1 / 5 AS col1 FROM tab0 AS cor0
----
100
20
50

query I rowsort
SELECT - 91 * + 62 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0c9b93e19f61130d14368aa828810c30

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

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

query I rowsort
SELECT - 50 + col1 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-1298
-1454
-620

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

query I rowsort
SELECT ALL + 57 + - 73 AS col2 FROM tab2 AS cor0
----
-16
-16
-16

query I rowsort
SELECT ALL 69 * + 73 AS col2 FROM tab0 AS cor0
----
5037
5037
5037

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

query I rowsort
SELECT DISTINCT + 11 * 82 FROM tab0 AS cor0
----
902

query I rowsort
SELECT + - 63 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
-25
-36
-37

query I rowsort
SELECT ALL + 12 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT ALL - + col2 + col0 * col2 * 95 FROM tab0 AS cor0
----
3324
693228
75207

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

query I rowsort
SELECT ALL + col1 * 14 + + col2 AS col1 FROM tab1 AS cor0
----
197
278
418

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2172
SELECT ALL CAST( 22 AS SIGNED ) * col1 * + 64 + col0 FROM tab0 AS cor0
----
121112
128217
136611

skipif mysql # not compatible
query I rowsort label-2172
SELECT ALL CAST ( 22 AS INTEGER ) * col1 * + 64 + col0 FROM tab0 AS cor0
----
121112
128217
136611

query I rowsort
SELECT DISTINCT + cor2.col1 * 22 FROM tab1, tab1 cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
220
286
572

query I rowsort
SELECT - 97 + col1 AS col1 FROM tab1
----
-71
-84
-87

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

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

query I rowsort
SELECT DISTINCT + cor0.col0 + 92 AS col2 FROM tab0 AS cor0
----
116
127
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-2178
SELECT + col1 * cor0.col0 + - col0 DIV col2 FROM tab0 cor0
----
2064
3360
8098

skipif mysql # not compatible
query I rowsort label-2178
SELECT + col1 * cor0.col0 + - col0 / col2 FROM tab0 cor0
----
2064
3360
8098

query I rowsort
SELECT - + col1 * col1 - - col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( cor1.col1 AS REAL ) AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - 78 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b6e4cc21599216686f0cf45b85668b2c

query I rowsort
SELECT DISTINCT col2 * ( - col2 ) * - col0 + col0 AS col2 FROM tab2
----
114155
5110
52806

query I rowsort
SELECT DISTINCT col2 + ( col1 * + col0 ) AS col0 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL + cor0.col1 + - 87 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 041f71edf97135fb663f285b7e3b2f3f

query I rowsort
SELECT DISTINCT col1 * - col1 * - 57 + - tab0.col2 * - ( tab0.col0 ) + col2 FROM tab0
----
422397
479397
536349

query I rowsort
SELECT + col2 * + 99 AS col2 FROM tab0
----
3267
8118
99

query I rowsort
SELECT col1 * 83 AS col0 FROM tab1
----
1079
2158
830

query I rowsort
SELECT DISTINCT - col1 + col0 * - ( col0 ) * col2 FROM tab2
----
-1354
-158243
-237175

onlyif mysql # use DIV operator for integer division
query I rowsort label-2189
SELECT + col0 DIV ( col2 ) - col2 FROM tab0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-2189
SELECT + col0 / ( col2 ) - col2 FROM tab0
----
-33
-81
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2190
SELECT + tab2.col1 + - CAST( - 82 AS SIGNED ) * tab2.col0 + - col1 FROM tab2
----
574
6396
6478

skipif mysql # not compatible
query I rowsort label-2190
SELECT + tab2.col1 + - CAST ( - 82 AS INTEGER ) * tab2.col0 + - col1 FROM tab2
----
574
6396
6478

onlyif mysql # use DIV operator for integer division
query I rowsort label-2191
SELECT col2 + + 66 DIV + cor0.col0 FROM tab1 AS cor0
----
58
76
96

skipif mysql # not compatible
query I rowsort label-2191
SELECT col2 + + 66 / + cor0.col0 FROM tab1 AS cor0
----
58
76
96

query I rowsort
SELECT + tab0.col1 + - 64 * - col1 AS col2 FROM tab0
----
5590
5915
6305

query I rowsort
SELECT ALL + col0 + - 31 FROM tab0
----
-7
4
58

query I rowsort
SELECT - col1 + + ( - col1 + + 10 ) AS col1 FROM tab0 AS cor0
----
-162
-172
-184

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

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

query I rowsort
SELECT + col1 + cor0.col1 * col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-2197
SELECT - - col0 DIV col0 + + 72 AS col0 FROM tab0 cor0
----
73
73
73

skipif mysql # not compatible
query I rowsort label-2197
SELECT - - col0 / col0 + + 72 AS col0 FROM tab0 cor0
----
73
73
73

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

query I rowsort
SELECT 6 * + col0 AS col0 FROM tab2
----
42
468
474

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 71 * col1 col1 FROM tab0
----
6106
6461
6887

query I rowsort
SELECT + + col2 * - col0 * col0 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1296
-158158
-237120

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

query I rowsort
SELECT ALL - + col1 + 6 * col1 AS col0 FROM tab1 AS cor0
----
130
50
65

query I rowsort
SELECT DISTINCT + 96 AS col2 FROM tab1, tab2 AS cor0
----
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2207
SELECT tab1.col1 + + col1 DIV - col0 FROM tab1
----
10
13
18

skipif mysql # not compatible
query I rowsort label-2207
SELECT tab1.col1 + + col1 / - col0 FROM tab1
----
10
13
18

query I rowsort
SELECT DISTINCT - 61 + col1 AS col2 FROM tab2 AS cor0
----
-2
-30
-44

query I rowsort
SELECT DISTINCT - ( col2 ) * - ( + col2 ) + - col0 * + col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-21387
-270842
-5998

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 + + col1 col0 FROM tab0 AS cor0
----
13
2
7

query I rowsort
SELECT - col1 - 57 FROM tab1 cor0
----
-67
-70
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2213
SELECT ALL + col2 * col2 + col2 DIV col0 FROM tab2 cor0
----
1444
676
732

skipif mysql # not compatible
query I rowsort label-2213
SELECT ALL + col2 * col2 + col2 / col0 FROM tab2 cor0
----
1444
676
732

query I rowsort
SELECT DISTINCT + col0 * + 70 + - col0 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT DISTINCT + col2 - 25 * col1 FROM tab0 AS cor0
----
-2117
-2193
-2424

query I rowsort
SELECT ALL - col0 * - ( + 18 ) FROM tab1 AS cor0
----
1152
1440
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-2217
SELECT - col2 DIV - col1 - 86 * col1 col1 FROM tab2 AS cor0
----
-1460
-2666
-5074

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2217
SELECT - col2 / - col1 - 86 * col1 col1 FROM tab2 AS cor0
----
-1460
-2666
-5074

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 - - col0 * - col0 col0 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT - col0 + + 90 AS col1 FROM tab2 AS cor0
----
11
12
83

query I rowsort
SELECT col2 + col1 + - col0 AS col0 FROM tab0
----
63
84
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 47 + - col0 ) col2 FROM tab2
----
-40
31
32

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

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

query I rowsort
SELECT ALL - 26 * tab1.col2 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to ea89d22f3eccb8f4ee8c422cffd62204

query I rowsort
SELECT 30 * col2 - + ( - tab1.col1 ) AS col2 FROM tab1
----
1646
1720
2893

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + - col1 + - col1 + - 38 * - col0 FROM tab1 AS cor0
----
2412
3014
62

query I rowsort
SELECT ALL col0 * ( + col1 ) * + col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT + cor0.col0 * col0 + + 4 * col0 + 78 * - col0 AS col0 FROM tab2 cor0
----
-469
312
395

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2232
SELECT + col0 + CAST( 98 AS SIGNED ) * cor0.col0 + ( col2 ) AS col0 FROM tab1 AS cor0
----
351
6393
8016

skipif mysql # not compatible
query I rowsort label-2232
SELECT + col0 + CAST ( 98 AS INTEGER ) * cor0.col0 + ( col2 ) AS col0 FROM tab1 AS cor0
----
351
6393
8016

query I rowsort
SELECT col2 * + 97 AS col2 FROM tab0 AS cor0
----
3201
7954
97

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

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

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

query I rowsort
SELECT + col2 + 51 FROM tab0
----
133
52
84

query I rowsort
SELECT + 76 + ( col2 ) FROM tab0 AS cor0
----
109
158
77

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

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

query I rowsort
SELECT cor1.col0 * - 52 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 76171c9b19f267521c183d98cd130edb

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

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

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

query I rowsort
SELECT + col0 * 17 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT + + cor0.col1 + 4 * - 75 * + cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 03454769640a936b1f28147f0c19b9a6

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2247
SELECT ALL - 14 DIV - col0 AS col1 FROM tab1 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2247
SELECT ALL - 14 / - col0 AS col1 FROM tab1 AS cor0
----
0
0
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2248
SELECT + - col2 DIV + 66 + - col1 + 3 FROM tab1 AS cor0
----
-11
-23
-7

skipif mysql # not compatible
query I rowsort label-2248
SELECT + - col2 / + 66 + - col1 + 3 FROM tab1 AS cor0
----
-11
-23
-7

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

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

query I rowsort
SELECT col0 + - col1 - col2 FROM tab1
----
-29
-3
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 88 * + col0 + + col1 col1 FROM tab2
----
647
6923
6969

query I rowsort
SELECT - ( - 55 ) AS col2 FROM tab2
----
55
55
55

query I rowsort
SELECT DISTINCT - col1 + - 4 FROM tab0
----
-101
-90
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col0 + + col2 col2 FROM tab0
----
253
37
90

query I rowsort
SELECT ALL ( col0 ) + col2 * - ( col0 ) FROM tab0
----
-7209
-768
0

query I rowsort
SELECT + col2 + + 88 + col1 AS col1 FROM tab0 cor0
----
186
207
261

query I rowsort
SELECT - - col0 * + 18 AS col2 FROM tab1 AS cor0
----
1152
1440
54

query I rowsort
SELECT ALL - col2 + 51 FROM tab0 AS cor0
----
-31
18
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-2259
SELECT + 57 DIV col0 AS col1 FROM tab2
----
0
0
8

skipif mysql # not compatible
query I rowsort label-2259
SELECT + 57 / col0 AS col1 FROM tab2
----
0
0
8

query I rowsort
SELECT + cor0.col0 + + 0 FROM tab2 cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2261
SELECT - + col0 * CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-2261
SELECT - + col0 * CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2262
SELECT DISTINCT + - col1 * - CAST( - 18 AS SIGNED ) FROM tab2 AS cor0
----
-1062
-306
-558

skipif mysql # not compatible
query I rowsort label-2262
SELECT DISTINCT + - col1 * - CAST ( - 18 AS INTEGER ) FROM tab2 AS cor0
----
-1062
-306
-558

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2263
SELECT ALL + - col0 * CAST( col1 * cor0.col0 AS SIGNED ) + col2 FROM tab0 AS cor0
----
-118824
-49503
-720729

skipif mysql # not compatible
query I rowsort label-2263
SELECT ALL + - col0 * CAST ( col1 * cor0.col0 AS INTEGER ) + col2 FROM tab0 AS cor0
----
-118824
-49503
-720729

query I rowsort
SELECT + col2 * col1 * col0 - - 80 FROM tab1
----
36560
4292
99920

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 85 col2 FROM tab2
----
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2267
SELECT - CAST( NULL AS DECIMAL ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2267
SELECT - CAST ( NULL AS REAL ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

query I rowsort
SELECT + col1 - - 75 AS col0 FROM tab1 AS cor0
----
101
85
88

query I rowsort
SELECT - col1 + - 86 FROM tab1 AS cor0
----
-112
-96
-99

query I rowsort
SELECT ALL - col2 * - 68 - + 12 * - col2 AS col1 FROM tab1
----
4320
4560
7680

query I rowsort
SELECT col2 * 70 + 36 FROM tab2 cor0
----
1856
1926
2696

query I rowsort
SELECT + col2 * - tab0.col1 * + 18 FROM tab0
----
-134316
-1746
-51084

onlyif mysql # use DIV operator for integer division
query I rowsort label-2274
SELECT col2 + col1 + + 42 DIV col1 AS col0 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-2274
SELECT col2 + col1 + + 42 / col1 AS col0 FROM tab0
----
119
173
98

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

query I rowsort
SELECT ALL 23 + + col2 AS col1 FROM tab0 cor0
----
105
24
56

query I rowsort
SELECT ALL + - 20 * col0 FROM tab2 AS cor0
----
-140
-1560
-1580

query I rowsort
SELECT DISTINCT - 82 * cor0.col2 + col0 AS col2 FROM tab1 cor0
----
-4425
-4610
-7792

query I rowsort
SELECT cor0.col2 * col2 * col2 AS col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL + col2 + + col2 + + 1 * + cor0.col0 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT DISTINCT + + col0 * ( + col1 ) + + col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT col2 * col1 + col1 * + col0 AS col0 FROM tab1 AS cor0
----
1210
1482
2288

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2284
SELECT DISTINCT - + col1 DIV 2 - + cor0.col1 AS col1 FROM tab1 AS cor0
----
-15
-19
-39

skipif mysql # not compatible
query I rowsort label-2284
SELECT DISTINCT - + col1 / 2 - + cor0.col1 AS col1 FROM tab1 AS cor0
----
-15
-19
-39

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + ( col1 ) col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - 88 col0 FROM tab1 AS cor0
----
-62
-75
-78

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

query I rowsort
SELECT ALL col1 + col0 * - 42 FROM tab0
----
-1373
-3647
-922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col1 + col1 col0 FROM tab1
----
1261
1430
580

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2292
SELECT - - col1 DIV 14 + 94 * cor0.col0 AS col2 FROM tab2 cor0
----
660
7336
7427

skipif mysql # not compatible
query I rowsort label-2292
SELECT - - col1 / 14 + 94 * cor0.col0 AS col2 FROM tab2 cor0
----
660
7336
7427

onlyif mysql # use DIV operator for integer division
query I rowsort label-2293
SELECT - col0 * + 25 + - col1 DIV col0 AS col2 FROM tab2 cor0
----
-179
-1950
-1975

skipif mysql # not compatible
query I rowsort label-2293
SELECT - col0 * + 25 + - col1 / col0 AS col2 FROM tab2 cor0
----
-179
-1950
-1975

query I rowsort
SELECT + + col0 * + 8 FROM tab1 cor0
----
24
512
640

query I rowsort
SELECT ALL 83 * - ( col2 + - 85 ) AS col2 FROM tab0 AS cor0
----
249
4316
6972

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

query I rowsort
SELECT DISTINCT - 23 + - col1 AS col1 FROM tab2 AS cor0
----
-40
-54
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2298
SELECT DISTINCT + 72 * cor0.col0 DIV - col0 FROM tab2 AS cor0
----
-72

skipif mysql # not compatible
query I rowsort label-2298
SELECT DISTINCT + 72 * cor0.col0 / - col0 FROM tab2 AS cor0
----
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + + ( 54 ) * - col1 * + CAST ( col2 * col1 + + col0 AS REAL ) col1 FROM tab2 AS cor0
----
-1412856
-5135832
-665550

query I rowsort
SELECT DISTINCT - 18 + 4 FROM tab2 AS cor0
----
-14

onlyif mysql # use DIV operator for integer division
query I rowsort label-2301
SELECT ALL + col0 + + cor0.col1 DIV col2 AS col2 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2301
SELECT ALL + col0 + + cor0.col1 / col2 AS col2 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2302
SELECT + - 71 - cor0.col2 DIV - col2 col1 FROM tab0 AS cor0
----
-70
-70
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2302
SELECT + - 71 - cor0.col2 / - col2 col1 FROM tab0 AS cor0
----
-70
-70
-70

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - + col0 * col1 col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT - col1 + ( col0 ) + col2 FROM tab1
----
111
163
31

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

skipif mysql # not compatible
query I rowsort label-2306
SELECT ( col2 ) * + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT col2 + - col2 * + 65 FROM tab2 AS cor0
----
-1664
-1728
-2432

query I rowsort
SELECT 9 * - col1 AS col2 FROM tab2 AS cor0
----
-153
-279
-531

query I rowsort
SELECT DISTINCT - col2 * col0 + 71 AS col1 FROM tab2 AS cor0
----
-118
-1957
-2931

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2311
SELECT ALL CAST( - col1 AS SIGNED ) DIV - col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-2311
SELECT ALL CAST ( - col1 AS INTEGER ) / - col0 FROM tab1
----
0
0
8

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2313
SELECT - 99 DIV col1 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2313
SELECT - 99 / col1 AS col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL + 60 + - col0 FROM tab1
----
-20
-4
57

query I rowsort
SELECT DISTINCT - col1 + col1 + col0 * 93 FROM tab1
----
279
5952
7440

query I rowsort
SELECT - 45 + + col0 * + col2 FROM tab1 AS cor0
----
117
3603
7635

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

query I rowsort
SELECT ALL - 4 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT ALL - 44 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2321
SELECT ALL + + CAST( + col1 AS SIGNED ) + col1 FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-2321
SELECT ALL + + CAST ( + col1 AS INTEGER ) + col1 FROM tab2 AS cor0
----
118
34
62

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

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

query I rowsort
SELECT DISTINCT + 89 + col0 FROM tab1 AS cor0
----
153
169
92

query I rowsort
SELECT DISTINCT + 87 + - 98 FROM tab0 AS cor0
----
-11

query I rowsort
SELECT - 49 AS col0 FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT DISTINCT - 36 * ( - col2 ) * - 2 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-107
-2400
-5993

query I rowsort
SELECT ALL + cor0.col1 + + 68 FROM tab2 AS cor0
----
127
85
99

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

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

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

query I rowsort
SELECT ( - col2 ) + col0 + col2 * col1 AS col0 FROM tab0
----
131
2829
7469

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

query I rowsort
SELECT + col2 * - col1 + col1 * cor0.col0 FROM tab1 AS cor0
----
-1326
-208
70

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col0 col0 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT col2 * - col2 * + col2 AS col2 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT tab2.col2 + cor0.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 73feda3cdfbb1052036b56d1a1e9df2d

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

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

query I rowsort
SELECT tab2.col1 * - 50 AS col0 FROM tab2
----
-1550
-2950
-850

query I rowsort
SELECT + col0 * 55 AS col2 FROM tab0
----
1320
1925
4895

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

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

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

query I rowsort
SELECT + 97 * col1 AS col0 FROM tab1 AS cor0
----
1261
2522
970

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2345
SELECT col0 + col0 DIV - col2 AS col2 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-2345
SELECT col0 + col0 / - col2 AS col2 FROM tab1 AS cor0
----
3
63
80

query I rowsort
SELECT + 87 + col1 AS col1 FROM tab0 AS cor0
----
173
178
184

query I rowsort
SELECT ALL + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - 98 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1274
-2548
-980

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

query I rowsort
SELECT ALL - 85 + - col0 AS col0 FROM tab0
----
-109
-120
-174

query I rowsort
SELECT - col2 * col1 + cor0.col2 FROM tab1 AS cor0
----
-1152
-1350
-513

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

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

query I rowsort
SELECT col2 AS col2 FROM tab2 WHERE NOT - col0 - + col0 <> ( col2 * - col1 )
----

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2356
SELECT ALL + col1 / col2 col2 FROM tab0
----
1
2
97

query I rowsort
SELECT tab1.col2 * col1 + tab1.col0 + col0 AS col2 FROM tab1
----
1408
1410
698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 col1 FROM tab0 WHERE NOT ( NULL ) IN ( + col2 )
----

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

query I rowsort
SELECT DISTINCT tab1.col0 + + col1 * - col0 - - col0 AS col0 FROM tab1
----
-512
-72
-880

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

skipif mysql # not compatible
query I rowsort label-2361
SELECT ALL - tab0.col1 * + col2 / col2 AS col0 FROM tab0
----
-86
-91
-97

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2363
SELECT + col1 DIV - col1 + col1 + + col1 FROM tab1
----
19
25
51

skipif mysql # not compatible
query I rowsort label-2363
SELECT + col1 / - col1 + col1 + + col1 FROM tab1
----
19
25
51

query I rowsort
SELECT col2 AS col2 FROM tab2 AS cor0 WHERE NOT ( - col1 ) > - col1 * + col0
----

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab0 AS cor0 WHERE NOT ( + col0 ) IN ( col1 + col1 )
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2366
SELECT col1 DIV + cor0.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-2366
SELECT col1 / + cor0.col1 col1 FROM tab1 AS cor0
----
1
1
1

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

query I rowsort
SELECT DISTINCT col1 * - col2 FROM tab1 WHERE ( NULL ) BETWEEN ( - col2 ) AND ( NULL )
----

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

query I rowsort
SELECT ALL - col2 AS col1 FROM tab0 WHERE col1 BETWEEN NULL AND + col2 * + col0
----

query I rowsort
SELECT col1 * col0 + col1 * - col0 * col1 AS col1 FROM tab0
----
-175440
-325920
-728910

onlyif mysql # use DIV operator for integer division
query I rowsort label-2372
SELECT DISTINCT - col0 * col2 DIV + tab1.col0 AS col1 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2372
SELECT DISTINCT - col0 * col2 / + tab1.col0 AS col1 FROM tab1
----
-54
-57
-96

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

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

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

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

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

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

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NULL < col1
----

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

skipif mysql # not compatible
query I rowsort label-2380
SELECT ALL tab2.col0 * col1 / col1 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2381
SELECT DISTINCT col1 DIV + tab1.col0 FROM tab1
----
0
8

skipif mysql # not compatible
query I rowsort label-2381
SELECT DISTINCT col1 / + tab1.col0 FROM tab1
----
0
8

query I rowsort
SELECT ALL + col1 * col0 - - col1 AS col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL col0 - tab1.col1 * col2 AS col1 FROM tab1
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2384
SELECT ALL - - ( + 8 ) DIV col0 - - 19 FROM tab1 AS cor0
----
19
19
21

skipif mysql # not compatible
query I rowsort label-2384
SELECT ALL - - ( + 8 ) / col0 - - 19 FROM tab1 AS cor0
----
19
19
21

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

query I rowsort
SELECT ALL col0 - ( col0 ) FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2387
SELECT DISTINCT tab1.col2 DIV - tab1.col1 + col1 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-2387
SELECT DISTINCT tab1.col2 / - tab1.col1 + col1 FROM tab1
----
24
5
6

query I rowsort
SELECT col2 + - col1 * + col1 AS col2 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT ALL + 82 + + 87 FROM tab1 AS cor0
----
169
169
169

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2391
SELECT ALL + 42 DIV col0 + col2 col1 FROM tab0
----
2
34
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2391
SELECT ALL + 42 / col0 + col2 col1 FROM tab0
----
2
34
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 76 col1 FROM tab1 cor0
----
-76
-76
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2393
SELECT DISTINCT + ( col1 ) * col0 + col0 DIV - col0 + col2 FROM tab1 AS cor0
----
1135
131
696

skipif mysql # not compatible
query I rowsort label-2393
SELECT DISTINCT + ( col1 ) * col0 + col0 / - col0 + col2 FROM tab1 AS cor0
----
1135
131
696

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

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

query I rowsort
SELECT + + 79 * - cor0.col2 + - col2 FROM tab1 AS cor0
----
-4320
-4560
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2397
SELECT - col1 * - col0 - col2 DIV col1 FROM tab1 AS cor0
----
1033
635
76

skipif mysql # not compatible
query I rowsort label-2397
SELECT - col1 * - col0 - col2 / col1 FROM tab1 AS cor0
----
1033
635
76

query I rowsort
SELECT ALL + + ( 97 ) * col0 + + cor0.col1 * - col1 AS col1 FROM tab0 AS cor0
----
-5068
-6014
352

query I rowsort
SELECT DISTINCT - ( + 63 ) + - col1 * - 95 FROM tab1 AS cor0
----
1172
2407
887

query I rowsort
SELECT ALL + 96 * col0 + + col1 + + col0 FROM tab0 AS cor0
----
2414
3492
8724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2401
SELECT DISTINCT - 85 DIV + col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2401
SELECT DISTINCT - 85 / + col1 AS col0 FROM tab0 AS cor0
----
0

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

query I rowsort
SELECT - + 67 FROM tab0 AS cor0
----
-67
-67
-67

query I rowsort
SELECT - 61 * + 5 - col2 AS col0 FROM tab1 AS cor0
----
-359
-362
-401

query I rowsort
SELECT ALL + cor0.col1 + - 33 AS col0 FROM tab0 AS cor0
----
53
58
64

query I rowsort
SELECT DISTINCT - col1 + 16 * col1 AS col1 FROM tab0 AS cor0
----
1290
1365
1455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2407
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2407
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 87 * col2 col1 FROM tab0
----
2871
7134
87

query I rowsort
SELECT ALL + cor0.col1 FROM tab0, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * col0 * 75 col0 FROM tab1 AS cor0
----
12150
273600
576000

query I rowsort
SELECT - 37 AS col0 FROM tab0 AS cor0
----
-37
-37
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + cor0.col0 * ( 35 ) col0 FROM tab1 AS cor0
----
2183
2704
51

query I rowsort
SELECT DISTINCT - ( col2 ) + col2 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT col1 * - col2 + col2 * ( - cor0.col0 ) FROM tab2 AS cor0
----
-1026
-3562
-3648

query I rowsort
SELECT ALL + col0 + - col2 AS col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT - 43 + cor0.col0 + + 65 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to d6688037d795d34bc5318ce0365147b0

query I rowsort
SELECT ALL - col1 * + 55 - + col2 AS col2 FROM tab0 AS cor0
----
-4763
-5087
-5336

onlyif mysql # use DIV operator for integer division
query I rowsort label-2418
SELECT ALL - col0 * 16 DIV 72 FROM tab0 cor0
----
-19
-5
-7

skipif mysql # not compatible
query I rowsort label-2418
SELECT ALL - col0 * 16 / 72 FROM tab0 cor0
----
-19
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * 67 col1 FROM tab1 AS cor0
----
3618
3819
6432

query I rowsort
SELECT + + col0 + - ( col1 ) FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + col2 * cor0.col0 + - col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL + 72 AS col0 FROM tab2
----
72
72
72

query I rowsort
SELECT - col2 + 25 AS col1 FROM tab0 cor0
----
-57
-8
24

query I rowsort
SELECT DISTINCT + col0 + + 43 AS col1 FROM tab2 AS cor0
----
121
122
50

query I rowsort
SELECT col2 * col2 * col2 AS col1 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL - + col1 * ( - col2 ) FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - cor0.col1 * ( + col0 ) AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2428
SELECT ALL tab2.col1 DIV col1 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2428
SELECT ALL tab2.col1 / col1 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT - col1 * 71 FROM tab2 AS cor0
----
-1207
-2201
-4189

onlyif mysql # use DIV operator for integer division
query I rowsort label-2430
SELECT DISTINCT - col0 DIV + ( ( + col1 ) ) AS col2 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2430
SELECT DISTINCT - col0 / + ( ( + col1 ) ) AS col2 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT - - cor0.col2 * 75 FROM tab2 cor0
----
1950
2025
2850

query I rowsort
SELECT ALL + 10 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT ALL 2 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT + - col2 * col2 + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT 59 * - 0 AS col0 FROM tab0, tab0 AS cor0
----
0

query I rowsort
SELECT + + ( + col0 ) + - col1 * + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-2437
SELECT + - 81 + + col0 DIV cor0.col0 FROM tab2 AS cor0
----
-80
-80
-80

skipif mysql # not compatible
query I rowsort label-2437
SELECT + - 81 + + col0 / cor0.col0 FROM tab2 AS cor0
----
-80
-80
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2438
SELECT DISTINCT - + col1 * col2 * - CAST( - 6 AS SIGNED ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-3430
-7501
-8450

skipif mysql # not compatible
query I rowsort label-2438
SELECT DISTINCT - + col1 * col2 * - CAST ( - 6 AS INTEGER ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-3430
-7501
-8450

query I rowsort
SELECT ALL tab1.col2 * - col1 + tab1.col2 AS col0 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT - col1 * + col0 + 25 AS col2 FROM tab0 AS cor0
----
-2039
-3370
-8074

onlyif mysql # use DIV operator for integer division
query I rowsort label-2441
SELECT col2 DIV + ( col1 + col0 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2441
SELECT col2 / + ( col1 + col0 ) AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2442
SELECT DISTINCT - - col0 DIV - cor0.col0 + ( 29 ) AS col1 FROM tab2 AS cor0
----
28

skipif mysql # not compatible
query I rowsort label-2442
SELECT DISTINCT - - col0 / - cor0.col0 + ( 29 ) AS col1 FROM tab2 AS cor0
----
28

query I rowsort
SELECT DISTINCT + 68 * - col2 FROM tab1
----
-3672
-3876
-6528

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2444
SELECT - - col0 / col0 + CAST( NULL AS DECIMAL ) * - col1 + - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2444
SELECT - - col0 / col0 + CAST ( NULL AS REAL ) * - col1 + - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + col2 - 80 FROM tab2 cor0
----
1454
566
757

query I rowsort
SELECT - + col0 + col0 + + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL ( - col2 ) + ( - 40 ) AS col0 FROM tab0 AS cor0
----
-122
-41
-73

query I rowsort
SELECT - col0 + col2 + + 75 AS col1 FROM tab1 AS cor0
----
126
68
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 62 col2 FROM tab0 cor0
----
151
86
97

query I rowsort
SELECT ALL col2 + 50 * 91 FROM tab0 AS cor0
----
4551
4583
4632

query I rowsort
SELECT - - col2 + - ( 42 ) * + col1 * col0 AS col2 FROM tab1 AS cor0
----
-26823
-3222
-43584

query I rowsort
SELECT DISTINCT ( + col2 ) * - col0 AS col0 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor1.col1 col2 FROM tab2, tab1 AS cor0, tab2 cor1
----
17
31
59

query I rowsort
SELECT ALL - cor0.col0 * 24 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1, tab0 AS cor2
----
243 values hashing to ba658ab9199e9d1b9f0b7afc14766316

query I rowsort
SELECT - - ( cor0.col1 ) + + col2 FROM tab1 cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 60 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT + cor0.col2 + - tab2.col1 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 8d4f084d3560870b9fbbdc5acc1f3ed3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2458
SELECT CAST( - col1 + + col0 AS SIGNED ) AS col2 FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-2458
SELECT CAST ( - col1 + + col0 AS INTEGER ) AS col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT + 73 FROM tab2, tab1 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT + col0 * 21 * col2 AS col1 FROM tab1
----
161280
3402
76608

onlyif mysql # use DIV operator for integer division
query I rowsort label-2461
SELECT + col2 DIV + 6 AS col2 FROM tab2
----
4
4
6

skipif mysql # not compatible
query I rowsort label-2461
SELECT + col2 / + 6 AS col2 FROM tab2
----
4
4
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2462
SELECT + col2 DIV + 1 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2462
SELECT + col2 / + 1 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab2, tab0 cor0, tab1 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT + ( cor0.col0 ) + - col2 DIV ( col1 + col2 ) AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2465
SELECT + ( cor0.col0 ) + - col2 / ( col1 + col2 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - 62 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + 46 * - col0 col2 FROM tab0
----
-1190
-1707
-4185

query I rowsort
SELECT DISTINCT - col2 + - col2 * - col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + ( + col0 ) * cor0.col2 AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - 35 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT - col2 * col2 + + ( col1 ) + - col2 * 82 AS col2 FROM tab1
----
-17075
-7318
-7913

query I rowsort
SELECT - col2 - col1 * 0 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 82 + col1 col0 FROM tab1 cor0
----
108
92
95

query I rowsort
SELECT ALL col1 + - 49 * col1 + tab1.col2 * col0 AS col2 FROM tab1
----
-1086
3168
7056

onlyif mysql # use DIV operator for integer division
query I rowsort label-2475
SELECT + col2 + 64 DIV - col0 FROM tab1
----
33
56
96

skipif mysql # not compatible
query I rowsort label-2475
SELECT + col2 + 64 / - col0 FROM tab1
----
33
56
96

query I rowsort
SELECT 84 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # use DIV operator for integer division
query I rowsort label-2477
SELECT + col1 - ( - tab1.col2 ) * col1 DIV col2 AS col2 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-2477
SELECT + col1 - ( - tab1.col2 ) * col1 / col2 AS col2 FROM tab1
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT col2 * + CAST ( + col0 AS REAL ) col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2479
SELECT DISTINCT tab2.col2 + CAST( + col1 AS SIGNED ) FROM tab2
----
55
58
85

skipif mysql # not compatible
query I rowsort label-2479
SELECT DISTINCT tab2.col2 + CAST ( + col1 AS INTEGER ) FROM tab2
----
55
58
85

query I rowsort
SELECT - + col1 * col2 * 71 + + col0 FROM tab1 AS cor0
----
-40406
-88528
-99681

query I rowsort
SELECT + + 38 AS col2 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT ALL - col2 + col0 + cor0.col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + col0 * + 76 + - col0 AS col0 FROM tab1 AS cor0
----
225
4800
6000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2484
SELECT ALL - CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2484
SELECT ALL - CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - + 41 * col2 + col0 AS col1 FROM tab2 AS cor0
----
-1100
-1479
-988

query I rowsort
SELECT ALL + + col1 - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT tab2.col2 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT + col2 + 53 AS col1 FROM tab1 cor0
----
107
110
149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 * + 96 col0 FROM tab1 AS cor0
----
-5568
-5568
-5568

query I rowsort
SELECT - 98 + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-20
542
942

query I rowsort
SELECT DISTINCT + ( - col0 ) + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - 41 + 46 * col1 * + col2 + col0 FROM tab1 AS cor0
----
26243
57447
64546

onlyif mysql # use DIV operator for integer division
query I rowsort label-2493
SELECT ALL - ( - 40 ) DIV col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2493
SELECT ALL - ( - 40 ) / col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + cor0.col1 + 78 FROM tab2 AS cor0
----
109
137
95

query I rowsort
SELECT + 99 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT DISTINCT - col1 + col1 * + col0 AS col0 FROM tab0 cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col1 + - ( - 95 ) * col2 FROM tab0 AS cor0
----
-2
3049
7699

query I rowsort
SELECT + cor0.col0 + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 43cd4d6bf46fb9ce15caf369cb36598e

onlyif mysql # use DIV operator for integer division
query I rowsort label-2501
SELECT ALL - col0 DIV - col0 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2501
SELECT ALL - col0 / - col0 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT 53 * - 94 FROM tab2, tab0 AS cor0
----
9 values hashing to c534132496783d820087b950f422eed9

query I rowsort
SELECT + col1 + + ( + cor0.col2 ) * col0 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col0 col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2505
SELECT + CAST( NULL AS SIGNED ) * - cor0.col2 + col2 / - 82 - + ( - col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2505
SELECT + CAST ( NULL AS INTEGER ) * - cor0.col2 + col2 / - 82 - + ( - col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( 90 ) FROM tab2, tab1 cor0
----
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2507
SELECT ALL - col0 * tab1.col1 DIV - col0 AS col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2507
SELECT ALL - col0 * tab1.col1 / - col0 AS col1 FROM tab1
----
10
13
26

query I rowsort
SELECT - col1 + col2 * - col2 AS col1 FROM tab2
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + col2 * - col1 * tab0.col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT col2 + 64 * - col1 AS col1 FROM tab2
----
-1050
-1957
-3750

query I rowsort
SELECT ALL 26 + col2 * col2 + col1 AS col0 FROM tab0
----
1201
124
6841

query I rowsort
SELECT 47 + + cor0.col2 FROM tab1 AS cor0
----
101
104
143

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 64 * col1 + cor0.col1 col2 FROM tab2 AS cor0
----
1105
2015
3835

query I rowsort
SELECT ALL ( + col2 ) + 74 * col1 AS col1 FROM tab2 AS cor0
----
1296
2321
4392

query I rowsort
SELECT ALL - + 30 + col0 FROM tab0 AS cor0
----
-6
5
59

query I rowsort
SELECT DISTINCT + - cor0.col2 * - col0 + col1 + + 8 FROM tab2 AS cor0
----
2095
228
3027

query I rowsort
SELECT + 80 * col0 FROM tab1
----
240
5120
6400

query I rowsort
SELECT DISTINCT - ( col2 ) + - col0 * tab0.col2 FROM tab0
----
-36
-7380
-825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2519
SELECT - ( - col1 ) + + CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2519
SELECT - ( - col1 ) + + CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2520
SELECT ALL + col1 DIV col0 FROM tab1 cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-2520
SELECT ALL + col1 / col0 FROM tab1 cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2521
SELECT DISTINCT - + 91 DIV + col1 + + 27 * col2 * col2 AS col2 FROM tab0 AS cor0
----
181547
27
29402

skipif mysql # not compatible
query I rowsort label-2521
SELECT DISTINCT - + 91 / + col1 + + 27 * col2 * col2 AS col2 FROM tab0 AS cor0
----
181547
27
29402

query I rowsort
SELECT ALL - + 20 * col0 FROM tab1 AS cor0
----
-1280
-1600
-60

query I rowsort
SELECT ALL + + 27 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2524
SELECT col0 + col2 DIV + ( + col2 * + col2 ) FROM tab0 AS cor0
----
24
36
89

skipif mysql # not compatible
query I rowsort label-2524
SELECT col0 + col2 / + ( + col2 * + col2 ) FROM tab0 AS cor0
----
24
36
89

query I rowsort
SELECT DISTINCT + + ( + col0 ) + + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT - - cor0.col1 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL cor0.col1 + + col2 * ( col1 ) AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - 83 * col2 AS col0 FROM tab2 AS cor0
----
-2158
-2241
-3154

query I rowsort
SELECT ALL - cor0.col0 * - col2 + + col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT ( col2 ) * - 74 FROM tab1
----
-3996
-4218
-7104

query I rowsort
SELECT + col1 + + col0 * col0 AS col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT - 16 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2533
SELECT ALL cor0.col0 - CAST( NULL AS SIGNED ) * 63 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2533
SELECT ALL cor0.col0 - CAST ( NULL AS INTEGER ) * 63 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 37 FROM tab2, tab0, tab0 cor0
----
37

skipif mysql # not compatible
query I rowsort
SELECT col0 + - CAST ( + col0 AS REAL ) AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * + col2 col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL 72 * cor0.col0 + - ( - 99 + col0 ) FROM tab2 AS cor0
----
5637
5708
596

query I rowsort
SELECT + cor1.col2 * + 98 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 955a20ecd6f2a10a9bc6a1cf70f173e7

query I rowsort
SELECT cor0.col2 + ( + col2 ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - col1 + - col2 * 8 FROM tab2 AS cor0
----
-247
-267
-321

query I rowsort
SELECT - - 41 * 45 - - col2 FROM tab0 AS cor0
----
1846
1878
1927

query I rowsort
SELECT ALL col0 * col2 * - col2 + - col1 AS col1 FROM tab2 AS cor0
----
-114093
-5134
-52787

query I rowsort
SELECT 76 * col1 * + col2 FROM tab0 AS cor0
----
215688
567112
7372

query I rowsort
SELECT - cor0.col2 - - cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 17 * - col2 FROM tab1 cor0
----
-1632
-918
-969

query I rowsort
SELECT ( cor0.col2 ) - col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col1 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - ( + col1 ) + + col1 * + cor0.col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + 63 * - col2 + - col0 FROM tab1 AS cor0
----
-3405
-3655
-6128

query I rowsort
SELECT ALL + + col0 * 20 FROM tab1 AS cor0
----
1280
1600
60

query I rowsort
SELECT - - 10 * cor0.col0 + - col1 FROM tab0 AS cor0
----
154
253
799

query I rowsort
SELECT DISTINCT - 22 + - col1 FROM tab2 AS cor0
----
-39
-53
-81

query I rowsort
SELECT ALL col0 * + 4 - - col1 FROM tab0 cor0
----
182
237
447

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2554
SELECT - CAST( NULL AS SIGNED ) * col2 + col2 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2554
SELECT - CAST ( NULL AS INTEGER ) * col2 + col2 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 23 * + col2 col0 FROM tab0 AS cor0
----
1886
23
759

query I rowsort
SELECT - - col1 * col1 + - ( - 31 ) FROM tab2 AS cor0
----
320
3512
992

query I rowsort
SELECT - col2 * col2 + - col0 FROM tab0 AS cor0
----
-1113
-36
-6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 + 91 col0 FROM tab1 cor0
----
1131
169
731

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 + col1 col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT 41 + 20 FROM tab2
----
61

query I rowsort
SELECT - 58 FROM tab0, tab2 cor0, tab2, tab0 AS cor1
----
81 values hashing to 897f42d096eff3935f4f50603850c23b

query I rowsort
SELECT DISTINCT + 45 + - col0 * tab0.col2 * - col1 AS col1 FROM tab0
----
3440
664163
68157

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 + cor0.col2 col1 FROM tab1 AS cor0
----
-3
0
39

query I rowsort
SELECT - ( cor0.col2 ) * - col0 + col1 AS col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT - col0 + - 38 FROM tab2 AS cor0
----
-116
-117
-45

query I rowsort
SELECT col1 * col2 + col0 * + col2 AS col2 FROM tab1 cor0
----
1566
4218
8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2567
SELECT - + col0 * - 13 * cor0.col0 + + CAST( + 1 AS SIGNED ) * + col2 col0 FROM tab2 AS cor0
----
664
79118
81171

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2567
SELECT - + col0 * - 13 * cor0.col0 + + CAST ( + 1 AS INTEGER ) * + col2 col0 FROM tab2 AS cor0
----
664
79118
81171

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2568
SELECT ALL - + CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2568
SELECT ALL - + CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + - col1 + + col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT - ( - 22 ) * col0 AS col2 FROM tab0 AS cor0
----
1958
528
770

query I rowsort
SELECT ALL - - 64 * + col0 + - col2 FROM tab0 AS cor0
----
1503
2239
5614

query I rowsort
SELECT col2 + - ( + cor0.col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 49 + + col1 * col2 FROM tab1 AS cor0
----
1297
1453
619

onlyif mysql # use DIV operator for integer division
query I rowsort label-2574
SELECT - - 86 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2574
SELECT - - 86 / cor0.col1 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2575
SELECT col1 * col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2575
SELECT col1 * col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2576
SELECT col0 DIV - cor0.col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2576
SELECT col0 / - cor0.col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + cor1.col1 * cor1.col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 11afcae511dc5af9fcc80b9c18958911

query I rowsort
SELECT ALL + 79 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2579
SELECT - col2 DIV + ( - col0 ) col0 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2579
SELECT - col2 / + ( - col0 ) col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT DISTINCT - - cor0.col1 * + col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + - cor0.col1 * 23 + - col2 FROM tab2 AS cor0
----
-1383
-429
-740

query I rowsort
SELECT DISTINCT cor0.col2 * + cor0.col2 * + col0 + + col1 FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT ALL - - col0 * 24 + col1 AS col2 FROM tab2 AS cor0
----
1913
1931
199

query I rowsort
SELECT DISTINCT + - col2 * col0 + - 90 + col1 AS col2 FROM tab1 AS cor0
----
-226
-3728
-7757

query I rowsort
SELECT ALL - col0 * col0 + - col2 AS col0 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT - col2 + - col1 * + col2 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT - tab0.col1 * tab0.col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT col0 * + ( + 52 ) + col2 FROM tab2
----
391
4082
4146

query I rowsort
SELECT + tab1.col2 + 66 FROM tab1
----
120
123
162

onlyif mysql # use DIV operator for integer division
query I rowsort label-2590
SELECT - tab0.col0 * col0 + col0 DIV - col2 AS col0 FROM tab0
----
-1260
-576
-7922

skipif mysql # not compatible
query I rowsort label-2590
SELECT - tab0.col0 * col0 + col0 / - col2 AS col0 FROM tab0
----
-1260
-576
-7922

onlyif mysql # use DIV operator for integer division
query I rowsort label-2591
SELECT DISTINCT ( cor0.col2 ) DIV cor0.col0 FROM tab2, tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-2591
SELECT DISTINCT ( cor0.col2 ) / cor0.col0 FROM tab2, tab2 AS cor0
----
0
3

query I rowsort
SELECT - col0 * + 88 FROM tab2
----
-616
-6864
-6952

query I rowsort
SELECT ALL - + ( + col0 ) * ( + col2 ) * + col1 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + + ( + col0 ) + + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL - ( - col2 ) * col2 - + col1 AS col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - col0 * col1 * + col2 + - col1 * + col1 AS col1 FROM tab0 AS cor0
----
-12804
-672399
-75508

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab1, tab1 AS cor0, tab0 cor1
----
3
64
80

query I rowsort
SELECT DISTINCT - 13 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-13

query I rowsort
SELECT - 88 + 75 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

query I rowsort
SELECT ALL - + col0 * col1 + - 58 AS col2 FROM tab1 AS cor0
----
-1098
-136
-698

query I rowsort
SELECT DISTINCT ( col1 ) * - ( + col1 * cor0.col1 + - 24 ) FROM tab1 AS cor0
----
-16952
-1885
-760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2602
SELECT DISTINCT + col0 - + col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-2602
SELECT DISTINCT + col0 - + col2 / + col1 AS col0 FROM tab2 AS cor0
----
7
77
78

query I rowsort
SELECT ALL - - 95 + col1 * + ( + col0 ) FROM tab2 AS cor0
----
1438
312
4697

query I rowsort
SELECT DISTINCT - 25 * - col2 + 88 FROM tab1 AS cor0
----
1438
1513
2488

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * col2 + + ( col2 ) * - ( col2 ) FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT col0 * col0 + 36 FROM tab0 AS cor0
----
1261
612
7957

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2607
SELECT - col1 + + col0 * + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2607
SELECT - col1 + + col0 * + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( - cor0.col0 ) * + 62 FROM tab2 cor0
----
-434
-4836
-4898

onlyif mysql # use DIV operator for integer division
query I rowsort label-2609
SELECT ALL + tab2.col0 DIV col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2609
SELECT ALL + tab2.col0 / col1 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL 85 * + col2 FROM tab1
----
4590
4845
8160

onlyif mysql # use DIV operator for integer division
query I rowsort label-2611
SELECT DISTINCT - ( tab0.col0 + tab0.col2 ) DIV - col2 AS col2 FROM tab0
----
1
2
36

skipif mysql # not compatible
query I rowsort label-2611
SELECT DISTINCT - ( tab0.col0 + tab0.col2 ) / - col2 AS col2 FROM tab0
----
1
2
36

query I rowsort
SELECT ALL - col0 - 68 FROM tab2 AS cor0
----
-146
-147
-75

query I rowsort
SELECT ALL 44 * 55 FROM tab0
----
2420
2420
2420

query I rowsort
SELECT ALL + ( ( - col2 ) ) * + col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - - 97 * 47 + col0 FROM tab0 AS cor0
----
4583
4594
4648

query I rowsort
SELECT - cor0.col0 + - col2 AS col0 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + col0 * col1 AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - ( + col0 ) * - cor0.col0 + + 96 AS col1 FROM tab0 AS cor0
----
1321
672
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2619
SELECT ALL + - 14 / + col1 + cor0.col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2619
SELECT ALL + - 14 / + col1 + cor0.col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col0 + + 49 FROM tab2 AS cor0
----
127
128
56

query I rowsort
SELECT DISTINCT - 23 * - col0 FROM tab0 cor0
----
2047
552
805

query I rowsort
SELECT - 50 * col2 AS col2 FROM tab1 AS cor0
----
-2700
-2850
-4800

query I rowsort
SELECT - 20 * cor0.col1 FROM tab1 AS cor0
----
-200
-260
-520

query I rowsort
SELECT + 83 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT col1 * col1 + col0 FROM tab0
----
7420
8370
9444

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2626
SELECT - CAST( NULL AS SIGNED ) * ( col2 ) - 87 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2626
SELECT - CAST ( NULL AS INTEGER ) * ( col2 ) - 87 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 - col2 * - 82 FROM tab0 cor0
----
2739
6806
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col0 * - 83 col2 FROM tab2 AS cor0
----
-550
-6415
-6540

query I rowsort
SELECT - + col2 + + 30 AS col2 FROM tab2 AS cor0
----
-8
3
4

query I rowsort
SELECT - + col0 * - 42 + + 56 FROM tab2 cor0
----
3332
3374
350

query I rowsort
SELECT ALL - col2 + - cor0.col2 * col2 * + col1 AS col1 FROM tab2 AS cor0
----
-22626
-24586
-39910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2632
SELECT ALL - col0 * CAST( NULL AS SIGNED ) + cor0.col0 * + cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2632
SELECT ALL - col0 * CAST ( NULL AS INTEGER ) + cor0.col0 * + cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col1 ) * - col1 * col0 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - + col1 * - 93 AS col1 FROM tab2 AS cor0
----
1581
2883
5487

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + col0 col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL cor0.col2 * - 10 AS col2 FROM tab0 cor0
----
-10
-330
-820

query I rowsort
SELECT - col2 - - col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab1.col2 * col2 + + tab1.col0 - col1 AS col2 FROM tab1
----
2893
3303
9283

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 + col0 * 96 + col0 * col1 col1 FROM tab0
----
2304
3360
8544

query I rowsort
SELECT ALL tab1.col0 + + 74 AS col1 FROM tab1
----
138
154
77

query I rowsort
SELECT ALL + + col0 + 66 AS col1 FROM tab0 AS cor0
----
101
155
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2642
SELECT ALL - col0 DIV - 11 AS col2 FROM tab2 AS cor0
----
0
7
7

skipif mysql # not compatible
query I rowsort label-2642
SELECT ALL - col0 / - 11 AS col2 FROM tab2 AS cor0
----
0
7
7

query I rowsort
SELECT ALL col1 + + col0 * - col0 AS col2 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT ALL - col0 + - tab2.col1 AS col2 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT + col2 + - 6 + - 28 FROM tab2
----
-7
-8
4

query I rowsort
SELECT DISTINCT tab0.col0 + tab0.col0 + col2 FROM tab0
----
260
71
81

query I rowsort
SELECT + 40 * col1 + + col1 * - col2 AS col0 FROM tab0 AS cor0
----
-3822
3783
602

query I rowsort
SELECT DISTINCT 19 FROM tab0, tab2 AS cor0
----
19

query I rowsort
SELECT DISTINCT + col2 + + col2 * + 0 + col0 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col2 col1 FROM tab1
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2651
SELECT tab1.col2 * + CAST( - col1 + col1 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2651
SELECT tab1.col2 * + CAST ( - col1 + col1 AS INTEGER ) FROM tab1
----
0
0
0

query I rowsort
SELECT + ( + col2 ) * cor0.col2 + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + - col2 + 36 AS col2 FROM tab0 AS cor0
----
-46
3
35

query I rowsort
SELECT DISTINCT - col1 + 62 AS col0 FROM tab1 cor0
----
36
49
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2655
SELECT DISTINCT - + CAST( 50 AS SIGNED ) * col1 * col2 AS col2 FROM tab2 AS cor0
----
-32300
-41850
-76700

skipif mysql # not compatible
query I rowsort label-2655
SELECT DISTINCT - + CAST ( 50 AS INTEGER ) * col1 * col2 AS col2 FROM tab2 AS cor0
----
-32300
-41850
-76700

query I rowsort
SELECT ALL + 93 + col0 FROM tab2 AS cor0
----
100
171
172

query I rowsort
SELECT - tab0.col1 * - col1 + col0 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT ( - col2 * ( col2 ) ) FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - col0 * col2 * col1 AS col0 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - - 52 - col0 * + 89 FROM tab2 AS cor0
----
-571
-6890
-6979

query I rowsort
SELECT DISTINCT - col1 * - col1 + ( 42 ) FROM tab1 AS cor0
----
142
211
718

query I rowsort
SELECT DISTINCT 18 * col1 - + col1 * - col2 FROM tab1 AS cor0
----
1482
1872
750

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 32 col2 FROM tab0 cor0
----
-32
-32
-32

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + cor0.col0 + - 39 FROM tab1 cor0
----
-36
25
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-2666
SELECT + col2 DIV 29 AS col2 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2666
SELECT + col2 / 29 AS col2 FROM tab0
----
0
1
2

query I rowsort
SELECT DISTINCT - - col0 + + col0 AS col2 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - col2 + + 86 AS col1 FROM tab0 AS cor0
----
4
53
85

query I rowsort
SELECT + col1 + 84 * cor0.col2 AS col1 FROM tab2 AS cor0
----
2243
2299
3209

query I rowsort
SELECT DISTINCT - 42 * col2 + col1 AS col0 FROM tab0 AS cor0
----
-1300
-3353
55

query I rowsort
SELECT + 69 AS col2 FROM tab2 AS cor0
----
69
69
69

query I rowsort
SELECT DISTINCT + ( + col0 ) * cor0.col0 + - col0 * + cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 85 + + col0 AS col2 FROM tab2 AS cor0
----
-6
-7
-78

query I rowsort
SELECT DISTINCT - + col1 * + col1 + col2 + - cor0.col0 FROM tab0 AS cor0
----
-7387
-8288
-9443

query I rowsort
SELECT + col1 - 7 FROM tab1
----
19
3
6

query I rowsort
SELECT - 99 + - 72 FROM tab2
----
-171
-171
-171

query I rowsort
SELECT DISTINCT col0 + - 16 * col2 AS col1 FROM tab0
----
-1223
-504
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 32 - - 17 col2 FROM tab2
----
49
49
49

query I rowsort
SELECT 29 - - 32 AS col1 FROM tab1
----
61
61
61

query I rowsort
SELECT DISTINCT 48 + + tab1.col2 * - col2 AS col2 FROM tab1
----
-2868
-3201
-9168

query I rowsort
SELECT - ( col2 ) * col1 + col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT + 20 + tab2.col1 FROM tab2
----
37
51
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 + + col0 col1 FROM tab2 cor0
----
100
3
45

query I rowsort
SELECT ALL + 79 AS col0 FROM tab2 AS cor0
----
79
79
79

query I rowsort
SELECT col2 * - cor0.col1 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2686
SELECT - col1 DIV + 77 - - col1 AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-2686
SELECT - col1 / + 77 - - col1 AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - - ( + col2 ) + col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + 44 * col1 + col2 FROM tab2 AS cor0
----
1391
2622
786

query I rowsort
SELECT ( + col1 ) + col0 * + tab1.col1 FROM tab1
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 45 * col0 + - col2 * col1 col1 FROM tab0
----
-1758
-3457
1478

query I rowsort
SELECT ALL ( cor0.col0 ) + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + ( col2 ) + - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT 30 + - col0 * col2 AS col0 FROM tab1 AS cor0
----
-132
-3618
-7650

query I rowsort
SELECT DISTINCT col0 FROM tab1 WHERE NULL > NULL
----

query I rowsort
SELECT ALL col2 * col0 * tab1.col2 + - col2 FROM tab1
----
207879
737184
8694

onlyif mysql # use DIV operator for integer division
query I rowsort label-2696
SELECT - col2 * cor0.col1 + + col2 DIV col2 + col2 AS col0 FROM tab1 AS cor0
----
-1151
-1349
-512

skipif mysql # not compatible
query I rowsort label-2696
SELECT - col2 * cor0.col1 + + col2 / col2 + col2 AS col0 FROM tab1 AS cor0
----
-1151
-1349
-512

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col1 col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT + + col0 * - col1 + - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT DISTINCT col1 + tab1.col0 * col0 AS col1 FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL - col0 + tab1.col2 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 * col0 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - + col1 * cor0.col1 col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT + - col0 * cor0.col1 + - cor0.col1 + col0 FROM tab0 cor0
----
-2126
-3457
-8101

query I rowsort
SELECT ALL cor0.col0 * - col1 * col1 AS col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT col1 * cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + cor0.col0 col1 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col2 + - col1 col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT - cor0.col0 - col0 * + col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL col1 * + col2 + col0 FROM tab0 AS cor0
----
132
2862
7551

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL >= NULL
----

query I rowsort
SELECT col1 * col0 - + cor0.col2 FROM tab0 AS cor0 WHERE NOT NULL IN ( - col0 - - cor0.col2 * - cor0.col0 )
----

query I rowsort
SELECT ALL + col2 + - tab1.col0 * col1 AS col0 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT col0 * + col0 + col1 AS col2 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT col0 + - col0 * + col1 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT + col0 - + tab0.col2 FROM tab0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2716
SELECT + cor0.col2 DIV - col2 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2716
SELECT + cor0.col2 / - col2 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2717
SELECT DISTINCT + col2 DIV cor0.col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2717
SELECT DISTINCT + col2 / cor0.col0 FROM tab1 cor0
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2718
SELECT + col2 - - col2 DIV - col0 FROM tab0 AS cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-2718
SELECT + col2 - - col2 / - col0 FROM tab0 AS cor0
----
1
32
82

query I rowsort
SELECT ALL + col2 + - col0 * col0 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2720
SELECT ALL - col1 DIV - col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2720
SELECT ALL - col1 / - col0 FROM tab0 cor0
----
1
2
3

query I rowsort
SELECT DISTINCT + col1 * col2 + + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL + col0 * col0 + + col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col2 - - col0 col0 FROM tab1
----
111
178
272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + tab2.col0 - + tab2.col0 col1 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT ALL col1 + + col1 - tab0.col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + - cor0.col2 * col2 * + col2 + col0 * col0 AS col2 FROM tab0 AS cor0
----
-35361
-543447
1224

query I rowsort
SELECT DISTINCT + + col1 * + col2 AS col1 FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - + cor0.col0 + col1 * - col1 * col2 AS col1 FROM tab1 AS cor0
----
-16304
-36507
-5764

query I rowsort
SELECT ALL - col0 + - col0 + col0 * - col0 AS col0 FROM tab1
----
-15
-4224
-6560

onlyif mysql # use DIV operator for integer division
query I rowsort label-2731
SELECT col1 DIV col1 + + col1 + - col0 FROM tab2
----
-18
-61
25

skipif mysql # not compatible
query I rowsort label-2731
SELECT col1 / col1 + + col1 + - col0 FROM tab2
----
-18
-61
25

query I rowsort
SELECT ALL tab0.col0 * col2 - col1 AS col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT ALL col0 * - col2 + ( + col0 ) FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + col1 + + ( 55 * col1 ) FROM tab1 AS cor0
----
1456
560
728

query I rowsort
SELECT DISTINCT + + 81 + cor0.col2 FROM tab1 AS cor0
----
135
138
177

onlyif mysql # use DIV operator for integer division
query I rowsort label-2736
SELECT col0 + cor0.col2 DIV - 42 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2736
SELECT col0 + cor0.col2 / - 42 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + ( 46 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
46

query I rowsort
SELECT ALL + 75 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

onlyif mysql # use DIV operator for integer division
query I rowsort label-2739
SELECT DISTINCT + col0 DIV + 65 AS col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2739
SELECT DISTINCT + col0 / + 65 AS col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL - cor0.col2 + ( - 51 ) AS col2 FROM tab0 AS cor0
----
-133
-52
-84

query I rowsort
SELECT ALL + cor0.col1 + ( + 59 ) FROM tab1 AS cor0
----
69
72
85

query I rowsort
SELECT + + col2 * 59 + + 95 FROM tab2 cor0
----
1629
1688
2337

query I rowsort
SELECT + col2 * - 10 + col2 AS col1 FROM tab0 cor0
----
-297
-738
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2744
SELECT - col2 DIV + 30 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2744
SELECT - col2 / + 30 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL + cor1.col2 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL col1 + tab1.col1 AS col1 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL - col0 + ( col2 ) AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col0 * - col0 - - col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - ( + col2 ) - col1 AS col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + cor2.col0 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT + ( + col1 ) + cor0.col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 13 + col0 * col2 AS col2 FROM tab0 AS cor0
----
48
7311
805

query I rowsort
SELECT DISTINCT + - col1 - ( col0 ) * col0 * col1 FROM tab2 AS cor0
----
-106114
-1550
-359015

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - col0 AS REAL ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 43 + cor0.col0 AS col0 FROM tab2 AS cor0
----
121
122
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2756
SELECT ALL 84 * col2 - CAST( NULL AS SIGNED ) / + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2756
SELECT ALL 84 * col2 - CAST ( NULL AS INTEGER ) / + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2757
SELECT ALL + + col0 DIV + col1 + col2 FROM tab1 AS cor0
----
102
54
63

skipif mysql # not compatible
query I rowsort label-2757
SELECT ALL + + col0 / + col1 + col2 FROM tab1 AS cor0
----
102
54
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2758
SELECT col2 DIV col1 - - col0 * col2 FROM tab1 AS cor0
----
164
3653
7687

skipif mysql # not compatible
query I rowsort label-2758
SELECT col2 / col1 - - col0 * col2 FROM tab1 AS cor0
----
164
3653
7687

query I rowsort
SELECT + 82 - col2 FROM tab0 AS cor0
----
0
49
81

query I rowsort
SELECT ALL + + col1 * - col2 - col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT col0 * cor0.col0 + - col1 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 58 - col1 col0 FROM tab1 AS cor0
----
-68
-71
-84

query I rowsort
SELECT ALL 47 * + col2 FROM tab2 cor0
----
1222
1269
1786

query I rowsort
SELECT DISTINCT + - 57 + + col0 AS col1 FROM tab2 AS cor0
----
-50
21
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2765
SELECT ALL CAST( 63 AS SIGNED ) - - col1 FROM tab2
----
122
80
94

skipif mysql # not compatible
query I rowsort label-2765
SELECT ALL CAST ( 63 AS INTEGER ) - - col1 FROM tab2
----
122
80
94

query I rowsort
SELECT 73 * - col0 + - col1 * 45 AS col1 FROM tab2 AS cor0
----
-1906
-6532
-8349

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 * - col0 col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 57 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2769
SELECT + CAST( + 73 AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

skipif mysql # not compatible
query I rowsort label-2769
SELECT + CAST ( + 73 AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

onlyif mysql # use DIV operator for integer division
query I rowsort label-2770
SELECT ALL 7 + - col2 DIV - col0 + - col0 FROM tab2
----
-71
-72
3

skipif mysql # not compatible
query I rowsort label-2770
SELECT ALL 7 + - col2 / - col0 + - col0 FROM tab2
----
-71
-72
3

query I rowsort
SELECT - + col2 - col1 FROM tab0 cor0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2772
SELECT - ( tab1.col1 ) * CAST( + col0 AS SIGNED ) AS col2 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-2772
SELECT - ( tab1.col1 ) * CAST ( + col0 AS INTEGER ) AS col2 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2773
SELECT col1 * col0 DIV + col2 FROM tab1
----
1
10
11

skipif mysql # not compatible
query I rowsort label-2773
SELECT col1 * col0 / + col2 FROM tab1
----
1
10
11

query I rowsort
SELECT DISTINCT - 8 * + col2 FROM tab0
----
-264
-656
-8

query I rowsort
SELECT - + 84 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

query I rowsort
SELECT + col1 * + col0 + - col0 + + 62 AS col0 FROM tab0
----
2102
3422
8072

query I rowsort
SELECT ( col2 ) * col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - ( + col0 ) * col2 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2779
SELECT col2 + col1 DIV - col1 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-2779
SELECT col2 + col1 / - col1 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL ( cor0.col2 ) * cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + 91 * - col0 FROM tab0 AS cor0
----
-2184
-3185
-8099

query I rowsort
SELECT ALL + col2 + 20 AS col2 FROM tab0 AS cor0
----
102
21
53

query I rowsort
SELECT DISTINCT - 53 FROM tab1 cor0
----
-53

query I rowsort
SELECT DISTINCT - col2 * - 9 AS col0 FROM tab1 AS cor0
----
486
513
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-2785
SELECT - CAST( + col2 AS SIGNED ) * + col1 + + cor0.col2 DIV col2 FROM tab0 cor0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-2785
SELECT - CAST ( + col2 AS INTEGER ) * + col1 + + cor0.col2 / col2 FROM tab0 cor0
----
-2837
-7461
-96

query I rowsort
SELECT ALL - 21 + - col1 FROM tab2 cor0
----
-38
-52
-80

query I rowsort
SELECT ALL - - ( col0 ) * + col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - + 65 + ( col1 ) * ( col0 ) AS col0 FROM tab0 AS cor0
----
1999
3330
8034

query I rowsort
SELECT - 52 * col2 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT DISTINCT + + col2 * - col0 + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + ( + 66 ) FROM tab2 cor0
----
66
66
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2792
SELECT DISTINCT col0 DIV col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2792
SELECT DISTINCT col0 / col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + ( tab0.col1 + - col2 * 91 ) FROM tab0
----
-2917
-7371
6

query I rowsort
SELECT ALL 21 + 53 FROM tab2
----
74
74
74

query I rowsort
SELECT cor0.col0 * ( - col0 ) + + 17 AS col1 FROM tab2 AS cor0
----
-32
-6067
-6224

query I rowsort
SELECT ALL + 91 + col0 FROM tab1
----
155
171
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 50 col1 FROM tab2, tab2 cor0
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2798
SELECT col0 + CAST( col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-2798
SELECT col0 + CAST ( col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT col0 * ( - col1 ) + col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT col0 * - 64 AS col0 FROM tab1 AS cor0
----
-192
-4096
-5120

query I rowsort
SELECT + + col1 * - col0 + col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT - + col0 + + col2 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT - col1 * col1 + col2 + + col2 AS col1 FROM tab1
----
-568
14
23

query I rowsort
SELECT DISTINCT + col2 * 74 * col0 + col1 * + tab2.col2 - col2 FROM tab2
----
14796
151580
222756

onlyif mysql # use DIV operator for integer division
query I rowsort label-2805
SELECT DISTINCT tab1.col2 * + col0 DIV col0 - col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-2805
SELECT DISTINCT tab1.col2 * + col0 / col0 - col2 FROM tab1
----
0

query I rowsort
SELECT - + 38 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT DISTINCT + col0 - - col0 * - tab0.col0 * col0 FROM tab0
----
-13800
-42840
-704880

query I rowsort
SELECT cor2.col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 cor2, tab1 AS cor3
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT - cor0.col1 * - cor0.col2 - + col2 * col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 * + ( 98 ) * - col2 - col0 AS col1 FROM tab1 cor0
----
-285771
-318466
-903248

onlyif mysql # use DIV operator for integer division
query I rowsort label-2811
SELECT DISTINCT col2 DIV CAST( + col2 AS SIGNED ) - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-2811
SELECT DISTINCT col2 / CAST ( + col2 AS INTEGER ) - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - tab2.col0 + CAST ( 10 + + col1 AS REAL ) AS col2 FROM tab2
----
-52
-9
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2813
SELECT DISTINCT cor0.col0 DIV - col0 AS col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2813
SELECT DISTINCT cor0.col0 / - col0 AS col1 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - 20 AS col0 FROM tab2 AS cor0
----
-20

query I rowsort
SELECT 67 * 70 * - col2 + + col1 * - col2 FROM tab2 cor0
----
-123474
-127467
-178866

query I rowsort
SELECT + ( + 87 ) * + col0 + 20 AS col2 FROM tab1 AS cor0
----
281
5588
6980

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + + col2 + 9 col0 FROM tab0
----
180
45
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2818
SELECT DISTINCT tab0.col2 + tab0.col0 DIV tab0.col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-2818
SELECT DISTINCT tab0.col2 + tab0.col0 / tab0.col2 FROM tab0
----
33
36
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + 43 + cor0.col2 col0 FROM tab1 AS cor0
----
-2268
-2394
-4032

query I rowsort
SELECT ALL + + 70 * 85 + + col0 AS col1 FROM tab2 AS cor0
----
5957
6028
6029

query I rowsort
SELECT DISTINCT - col0 * - col1 + + col1 * 11 AS col2 FROM tab1 AS cor0
----
1183
364
750

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2822
SELECT col1 * CAST( NULL AS DECIMAL ) / + ( col0 + + 82 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2822
SELECT col1 * CAST ( NULL AS REAL ) / + ( col0 + + 82 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 20 * + col0 + col1 FROM tab1 cor0
----
1290
1613
86

query I rowsort
SELECT + 40 * + col2 FROM tab1 cor0
----
2160
2280
3840

query I rowsort
SELECT ALL 64 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT ALL ( col1 + + col0 ) * 86 AS col1 FROM tab0
----
11352
15480
9460

query I rowsort
SELECT ALL + col1 * ( - 31 ) AS col0 FROM tab0 AS cor0
----
-2666
-2821
-3007

query I rowsort
SELECT DISTINCT - col0 + + cor0.col1 * col2 FROM tab1 AS cor0
----
1168
1401
506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2829
SELECT ALL - + col0 * 18 DIV - col1 AS col1 FROM tab1 AS cor0
----
110
115
2

skipif mysql # not compatible
query I rowsort label-2829
SELECT ALL - + col0 * 18 / - col1 AS col1 FROM tab1 AS cor0
----
110
115
2

query I rowsort
SELECT DISTINCT - col2 * + col0 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - col0 * - ( - col0 ) * + col0 + col0 + ( + col1 + col0 ) FROM tab1 AS cor0
----
-262006
-511827
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2832
SELECT DISTINCT - col1 + CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2832
SELECT DISTINCT - col1 + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + 57 AS col2 FROM tab2, tab0, tab2 AS cor0
----
57

query I rowsort
SELECT ALL + cor0.col0 FROM tab2, tab1, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT - + col0 * + col2 + 7 FROM tab0 AS cor0
----
-28
-7291
-785

query I rowsort
SELECT - + col1 * col1 AS col0 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + + 18 + col0 AS col2 FROM tab0 AS cor0
----
107
42
53

query I rowsort
SELECT col2 * col0 * - col0 - col0 FROM tab1 WHERE NOT col2 NOT BETWEEN col2 AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2839
SELECT ALL tab0.col1 + + tab0.col1 DIV + col1 + col2 * - col0 FROM tab0
----
-705
-7206
63

skipif mysql # not compatible
query I rowsort label-2839
SELECT ALL tab0.col1 + + tab0.col1 / + col1 + col2 * - col0 FROM tab0
----
-705
-7206
63

query I rowsort
SELECT - tab0.col1 AS col2 FROM tab0 WHERE NOT ( - col2 / + col0 ) = ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 col2 FROM tab0 WHERE ( NULL ) IN ( - col2 )
----

query I rowsort
SELECT col2 + - col2 * + col1 * - 83 FROM tab2
----
127348
53656
69498

query I rowsort
SELECT DISTINCT col1 + col2 * 12 FROM tab1
----
1165
674
694

onlyif mysql # use DIV operator for integer division
query I rowsort label-2844
SELECT DISTINCT + col1 + + col2 DIV + tab2.col0 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-2844
SELECT DISTINCT + col1 + + col2 / + tab2.col0 FROM tab2
----
17
34
59

query I rowsort
SELECT + 64 + col0 + col0 AS col2 FROM tab2
----
220
222
78

query I rowsort
SELECT - cor0.col0 + - col2 + col0 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT 40 + col2 * col0 FROM tab2 cor0
----
2068
229
3042

query I rowsort
SELECT 14 * col0 AS col1 FROM tab0
----
1246
336
490

query I rowsort
SELECT + col2 * col1 * ( + col2 ) AS col1 FROM tab0
----
611884
93654
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 16 + cor0.col1 * + col1 col2 FROM tab0 AS cor0
----
7412
8297
9425

query I rowsort
SELECT col2 AS col2 FROM tab0 WHERE ( NULL ) NOT IN ( col0 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) IN ( + col1 + col2 * - col1 )
----

query I rowsort
SELECT DISTINCT - col1 FROM tab2 WHERE ( - col1 ) NOT BETWEEN NULL AND - col2 * col2
----
-17
-31
-59

query I rowsort
SELECT col0 * col1 + col0 + col2 AS col0 FROM tab0 WHERE - col1 > + col1
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT NULL <> + cor0.col1
----

query III rowsort
SELECT * FROM tab0 cor0 WHERE NULL NOT IN ( col0 )
----

query I rowsort
SELECT ALL - tab0.col0 * col1 * + col2 AS col0 FROM tab0 WHERE NOT - col2 NOT IN ( - col1 * - col1 / + col0 )
----

query I rowsort
SELECT + col0 - - tab1.col0 AS col0 FROM tab1
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2859
SELECT ALL + col0 DIV tab0.col2 + - col0 FROM tab0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-2859
SELECT ALL + col0 / tab0.col2 + - col0 FROM tab0
----
-24
-88
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col0 + col0 * col1 col2 FROM tab0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col2 col1 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * + col1 - col1 FROM tab1
----
156
650
90

query I rowsort
SELECT DISTINCT col0 + col0 * - tab1.col2 AS col2 FROM tab1 WHERE NOT NULL NOT BETWEEN - col1 + - col0 + + col1 / - col0 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2864
SELECT ALL + col0 * - col0 DIV + col0 + col2 AS col2 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-2864
SELECT ALL + col0 * - col0 / + col0 + col2 AS col2 FROM tab0
----
-34
-7
9

query III rowsort
SELECT * FROM tab1 WHERE - col1 NOT BETWEEN + col2 AND NULL
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col1 + + col1 * col0 * - col2 + tab2.col1 * tab2.col1 AS col2 FROM tab2
----
-116112
-4867
-50728

onlyif mysql # use DIV operator for integer division
query I rowsort label-2867
SELECT col0 DIV - col2 + col2 + - col2 col2 FROM tab0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2867
SELECT col0 / - col2 + col2 + - col2 col2 FROM tab0
----
-1
-35
0

query I rowsort
SELECT DISTINCT - col2 + - col1 * + col1 FROM tab2
----
-327
-3507
-988

query I rowsort
SELECT ALL col1 * - col2 * col2 FROM tab0 WHERE NOT col2 NOT BETWEEN NULL AND + col0
----

query I rowsort
SELECT ALL + 85 * 76 AS col1 FROM tab1
----
6460
6460
6460

query I rowsort
SELECT - 39 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to a08a82dc9276c0173448e9a1c89dba93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 col0 FROM tab1, tab1 cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ( - col2 + - col2 ) AS col0 FROM tab0
----
-164
-2
-66

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( - col2 AS REAL ) AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL col0 * + 1 + - col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2876
SELECT - 60 * + cor0.col2 - CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2876
SELECT - 60 * + cor0.col2 - CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
24
35
89

query I rowsort
SELECT 6 + - col1 AS col1 FROM tab1 cor0
----
-20
-4
-7

query I rowsort
SELECT + col2 * - col0 + + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - ( col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL 75 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

onlyif mysql # use DIV operator for integer division
query I rowsort label-2882
SELECT + cor0.col2 DIV - 52 + - col1 + col1 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2882
SELECT + cor0.col2 / - 52 + - col1 + col1 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - col1 + + cor0.col1 + 7 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT - col0 * 49 AS col0 FROM tab1 AS cor0
----
-147
-3136
-3920

onlyif mysql # use DIV operator for integer division
query I rowsort label-2885
SELECT + cor0.col1 + + ( 99 ) + + col2 DIV - ( col2 ) AS col1 FROM tab1 cor0
----
108
111
124

skipif mysql # not compatible
query I rowsort label-2885
SELECT + cor0.col1 + + ( 99 ) + + col2 / - ( col2 ) AS col1 FROM tab1 cor0
----
108
111
124

query I rowsort
SELECT col2 + + col0 + - cor0.col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT cor0.col1 * tab2.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 95981a80d3d59cb4fd463f4a7ad46da1

query I rowsort
SELECT - col1 * 13 FROM tab1 AS cor0
----
-130
-169
-338

query I rowsort
SELECT ALL + 36 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT 64 * + cor1.col1 * + cor1.col2 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 967fd47361f50e74be9bd4d26d625b22

query I rowsort
SELECT - cor1.col0 * - cor1.col0 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 8ec1e5b752a6eed5f6e85ed78b46af3c

query I rowsort
SELECT ALL - col1 * - cor0.col1 + col0 AS col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT ALL - + col2 * col0 - + col1 * col2 * col0 FROM tab0 AS cor0
----
-3430
-671416
-68904

query I rowsort
SELECT + col1 + col0 * + col0 AS col0 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2895
SELECT DISTINCT col2 DIV 51 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2895
SELECT DISTINCT col2 / 51 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2896
SELECT DISTINCT - - col2 DIV - 68 + + ( + col2 * - CAST( + 51 AS SIGNED ) ) FROM tab0 AS cor0
----
-1683
-4183
-51

skipif mysql # not compatible
query I rowsort label-2896
SELECT DISTINCT - - col2 / - 68 + + ( + col2 * - CAST ( + 51 AS INTEGER ) ) FROM tab0 AS cor0
----
-1683
-4183
-51

query I rowsort
SELECT DISTINCT - - col0 + + ( + col0 * col2 ) AS col1 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2898
SELECT ALL + cor0.col1 * + 45 * + 4 - col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2898
SELECT ALL + cor0.col1 * + 45 * + 4 - col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + cor0.col2 * + 82 AS col1 FROM tab0 AS cor0
----
117
2730
6813

query I rowsort
SELECT DISTINCT + col0 * + 17 FROM tab1 AS cor0
----
1088
1360
51

query I rowsort
SELECT ALL col2 - - col2 * col0 AS col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT col2 + ( + 81 ) FROM tab0 AS cor0
----
114
163
82

query I rowsort
SELECT DISTINCT - col2 * col1 + - 49 FROM tab0 AS cor0
----
-146
-2887
-7511

query I rowsort
SELECT ALL - col2 - - ( col1 ) AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL + - col1 * - ( + col2 * - col2 ) AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-2906
SELECT 86 DIV col1 AS col0 FROM tab2
----
1
2
5

skipif mysql # not compatible
query I rowsort label-2906
SELECT 86 / col1 AS col0 FROM tab2
----
1
2
5

query I rowsort
SELECT DISTINCT + col1 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2908
SELECT - col1 + CAST( 42 AS SIGNED ) FROM tab0 AS cor0
----
-44
-49
-55

skipif mysql # not compatible
query I rowsort label-2908
SELECT - col1 + CAST ( 42 AS INTEGER ) FROM tab0 AS cor0
----
-44
-49
-55

query I rowsort
SELECT + col2 + 91 AS col0 FROM tab0 AS cor0
----
124
173
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-2910
SELECT DISTINCT - col0 DIV - CAST( + col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2910
SELECT DISTINCT - col0 / - CAST ( + col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 65 col0 FROM tab1 AS cor0
----
65
65
65

query I rowsort
SELECT - col0 + + ( col2 ) AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT + - 14 + col0 * - col2 AS col1 FROM tab2 cor0
----
-203
-2042
-3016

query I rowsort
SELECT - 45 * col2 * + col0 AS col0 FROM tab1 AS cor0
----
-164160
-345600
-7290

onlyif mysql # use DIV operator for integer division
query I rowsort label-2915
SELECT ALL - 75 DIV + col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2915
SELECT ALL - 75 / + col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT DISTINCT - ( - col1 ) + - col1 AS col2 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col2 ) - - col0 col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + + 14 * col0 AS col0 FROM tab2 AS cor0
----
1092
1106
98

query I rowsort
SELECT DISTINCT 55 AS col2 FROM tab0, tab1 AS cor0
----
55

query I rowsort
SELECT ALL + ( + ( col0 ) ) * + 89 FROM tab1
----
267
5696
7120

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
3645 values hashing to 0c9c9a26da1b45580001288543ac8dbe

query I rowsort
SELECT DISTINCT 28 * - cor0.col0 AS col0 FROM tab2, tab1 AS cor0
----
-1792
-2240
-84

query I rowsort
SELECT DISTINCT - ( col0 ) AS col0 FROM tab1 cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 71 col1 FROM tab1 AS cor0
----
71
71
71

query I rowsort
SELECT ALL - 43 * + col0 + ( 30 * - col2 ) FROM tab1 AS cor0
----
-1749
-4462
-6320

query I rowsort
SELECT ALL + - ( + col0 ) + col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + - 36 * col2 AS col0 FROM tab2 AS cor0
----
-1368
-936
-972

onlyif mysql # use DIV operator for integer division
query I rowsort label-2928
SELECT + cor0.col1 + + col0 DIV + col2 FROM tab0 cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-2928
SELECT + cor0.col1 + + col0 / + col2 FROM tab0 cor0
----
132
86
92

query I rowsort
SELECT DISTINCT - + ( col2 ) * - 57 AS col0 FROM tab1 cor0
----
3078
3249
5472

query I rowsort
SELECT ALL + ( col0 ) + 56 * + col1 AS col2 FROM tab1 AS cor0
----
1459
624
808

onlyif mysql # use DIV operator for integer division
query I rowsort label-2931
SELECT DISTINCT cor0.col2 + - cor0.col1 DIV - 58 AS col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2931
SELECT DISTINCT cor0.col2 + - cor0.col1 / - 58 AS col0 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT - 67 * col0 FROM tab1 AS cor0
----
-201
-4288
-5360

query I rowsort
SELECT 48 * - col1 + - col0 FROM tab1
----
-1251
-544
-704

query I rowsort
SELECT DISTINCT - tab1.col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
1
33
82

query I rowsort
SELECT + ( col0 ) + col2 + - col0 * - col1 FROM tab1
----
1216
135
761

query I rowsort
SELECT ALL - 40 - col2 FROM tab2
----
-66
-67
-78

query I rowsort
SELECT + - 59 AS col1 FROM tab0 AS cor0
----
-59
-59
-59

query I rowsort
SELECT ALL + - 90 * col2 AS col0 FROM tab0 AS cor0
----
-2970
-7380
-90

query I rowsort
SELECT - col0 + col0 * + 3 AS col2 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * + cor0.col1 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2942
SELECT col0 DIV col0 AS col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2942
SELECT col0 / col0 AS col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + 51 AS col1 FROM tab1 AS cor0
----
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 + col1 * - col0 col2 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT - col1 + - 62 * + col0 * - col1 FROM tab0 AS cor0
----
127882
210393
502047

query I rowsort
SELECT DISTINCT 79 + - ( col0 ) FROM tab2 AS cor0
----
0
1
72

query I rowsort
SELECT - 66 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT ALL - ( col2 ) * + col2 * 15 AS col1 FROM tab2 AS cor0
----
-10140
-10935
-21660

query I rowsort
SELECT - col0 * ( + col2 ) + - col2 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2950
SELECT + - col1 + CAST( col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-2950
SELECT + - col1 + CAST ( col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT col0 * - 64 + col1 FROM tab2
----
-417
-4933
-5039

query I rowsort
SELECT DISTINCT col0 + 26 * - col0 AS col2 FROM tab1 AS cor0
----
-1600
-2000
-75

query I rowsort
SELECT ALL - ( 71 ) + cor0.col2 FROM tab2 AS cor0
----
-33
-44
-45

query I rowsort
SELECT ALL + - 1 * - 97 + cor0.col1 AS col1 FROM tab0 AS cor0
----
183
188
194

query I rowsort
SELECT ALL cor1.col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - col1 * - col2 + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + 93 + - col2 AS col2 FROM tab2 AS cor0
----
55
66
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 39 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT DISTINCT - + col2 * + cor0.col0 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - - 52 AS col0 FROM tab0 AS cor0
----
52

query I rowsort
SELECT ( 35 ) * + col1 + ( 31 ) FROM tab1 AS cor0
----
381
486
941

query I rowsort
SELECT DISTINCT - - col2 * - 94 AS col1 FROM tab0 AS cor0
----
-3102
-7708
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2963
SELECT - 2 DIV + col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2963
SELECT - 2 / + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 27 * + col1 FROM tab1 AS cor0
----
-270
-351
-702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * cor0.col1 * - col2 col0 FROM tab2 AS cor0
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 33 col2 FROM tab0 AS cor0
----
-32
0
49

query I rowsort
SELECT + col1 * - col1 + 80 FROM tab2 AS cor0
----
-209
-3401
-881

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2968
SELECT + col1 + CAST( NULL AS SIGNED ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2968
SELECT + col1 + CAST ( NULL AS INTEGER ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + cor1.col2 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
-54
-57
-96

query I rowsort
SELECT ALL - 93 * cor0.col1 FROM tab0 cor0
----
-7998
-8463
-9021

onlyif mysql # use DIV operator for integer division
query I rowsort label-2971
SELECT - col2 + col0 DIV ( col0 ) + + col0 FROM tab0 AS cor0
----
-8
35
8

skipif mysql # not compatible
query I rowsort label-2971
SELECT - col2 + col0 / ( col0 ) + + col0 FROM tab0 AS cor0
----
-8
35
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col1 * - 6 col1 FROM tab1 AS cor0
----
-102
-3
18

query I rowsort
SELECT col0 + col0 + - col2 * col1 FROM tab0 AS cor0
----
-27
-2790
-7284

query I rowsort
SELECT ALL cor0.col0 + - 3 FROM tab2, tab2 AS cor0
----
9 values hashing to 85b52568483fea439f9ebc94d6d56c47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 54 * - col0 col0 FROM tab1 AS cor0
----
-162
-3456
-4320

query I rowsort
SELECT DISTINCT - ( - col2 ) * col2 + 8 AS col2 FROM tab1 AS cor0
----
2924
3257
9224

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2977
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2977
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT + - 82 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

query I rowsort
SELECT ALL - ( + tab1.col0 + - 58 * col0 ) AS col2 FROM tab1
----
171
3648
4560

query I rowsort
SELECT - col1 - 47 FROM tab1
----
-57
-60
-73

query I rowsort
SELECT - col2 + col2 * + 52 AS col1 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT DISTINCT + cor1.col0 * + ( - 80 ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
-1920
-2800
-7120

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab1, tab0 AS cor0
----
92

query I rowsort
SELECT ( - tab2.col0 * 61 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 04c39039b4048d900af1c8e9b7691776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2985
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - ( + col0 * col2 ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2985
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - ( + col0 * col2 ) FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2986
SELECT + col0 * - col1 DIV col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-2986
SELECT + col0 * - col1 / col1 FROM tab2
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2987
SELECT DISTINCT + ( + 94 ) * col0 * CAST( NULL AS SIGNED ) + col2 * - col0 + + col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2987
SELECT DISTINCT + ( + 94 ) * col0 * CAST ( NULL AS INTEGER ) + col2 * - col0 + + col0 FROM tab2 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col0 col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2989
SELECT - CAST( col1 + - col0 AS SIGNED ) * + col0 AS col2 FROM tab0
----
-1488
-178
-2170

skipif mysql # not compatible
query I rowsort label-2989
SELECT - CAST ( col1 + - col0 AS INTEGER ) * + col0 AS col2 FROM tab0
----
-1488
-178
-2170

query I rowsort
SELECT - - 66 - + 84 AS col1 FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT - col0 * + col1 + - col1 AS col1 FROM tab2 AS cor0
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-2992
SELECT ( 98 ) DIV - cor1.col0 + 34 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 49af4543dd752ab5a83981987c7ae51d

skipif mysql # not compatible
query I rowsort label-2992
SELECT ( 98 ) / - cor1.col0 + 34 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 49af4543dd752ab5a83981987c7ae51d

query I rowsort
SELECT + col2 - - col0 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - + 13 + cor0.col2 FROM tab0 AS cor0
----
-12
20
69

query I rowsort
SELECT - - ( col0 ) * cor0.col1 - + 73 FROM tab1 AS cor0
----
5
567
967

query I rowsort
SELECT col0 * + col1 + 53 FROM tab2 AS cor0
----
1396
270
4655

onlyif mysql # use DIV operator for integer division
query I rowsort label-2997
SELECT - - cor0.col0 + col0 * col0 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
135
146
3

skipif mysql # not compatible
query I rowsort label-2997
SELECT - - cor0.col0 + col0 * col0 / cor0.col2 AS col2 FROM tab1 AS cor0
----
135
146
3

query I rowsort
SELECT - 54 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

query I rowsort
SELECT tab2.col2 * col1 + - tab2.col2 FROM tab2
----
1508
608
810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3000
SELECT + - CAST( NULL AS DECIMAL ) - 99 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3000
SELECT + - CAST ( NULL AS REAL ) - 99 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 - + col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col2 AS REAL ) + col1 FROM tab2
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3003
SELECT 21 + - col1 DIV col0 FROM tab1 AS cor0
----
13
21
21

skipif mysql # not compatible
query I rowsort label-3003
SELECT 21 + - col1 / col0 FROM tab1 AS cor0
----
13
21
21

query I rowsort
SELECT DISTINCT + - 4 * - col0 AS col2 FROM tab0 AS cor0
----
140
356
96

query I rowsort
SELECT ALL + 80 * + ( col1 ) + col2 FROM tab1 cor0
----
1136
2134
857

query I rowsort
SELECT ALL - col0 * + 72 AS col2 FROM tab2 AS cor0
----
-504
-5616
-5688

query I rowsort
SELECT DISTINCT 47 + cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
1581
693
884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * col0 + col0 col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT - col0 + - 64 * + col0 FROM tab0 AS cor0
----
-1560
-2275
-5785

query I rowsort
SELECT DISTINCT + 37 + 51 AS col0 FROM tab2 AS cor0
----
88

query I rowsort
SELECT ALL + 39 * col1 FROM tab0 AS cor0
----
3354
3549
3783

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 42 * - col2 col1 FROM tab1 AS cor0
----
2268
2394
4032

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * cor0.col1 * col1 - col0 col2 FROM tab0 AS cor0
----
244044
678953
9374

query I rowsort
SELECT - 21 + col2 + col2 FROM tab2 cor0
----
31
33
55

query I rowsort
SELECT ALL + ( col1 ) + - 64 * ( - col1 ) AS col2 FROM tab2
----
1105
2015
3835

onlyif mysql # use DIV operator for integer division
query I rowsort label-3016
SELECT + + cor0.col0 * + col1 DIV - ( col1 ) + col2 * cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

skipif mysql # not compatible
query I rowsort label-3016
SELECT + + cor0.col0 * + col1 / - ( col1 ) + col2 * cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT col0 * + col0 + - col2 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT - 71 AS col1 FROM tab1 cor0
----
-71
-71
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-3019
SELECT ALL cor0.col0 + col2 DIV - col1 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-3019
SELECT ALL cor0.col0 + col2 / - col1 FROM tab2 AS cor0
----
7
77
78

query I rowsort
SELECT DISTINCT + ( + 77 ) FROM tab2, tab0 AS cor0
----
77

query I rowsort
SELECT DISTINCT + col0 - - 52 FROM tab0 AS cor0
----
141
76
87

query I rowsort
SELECT + col1 + col1 * + col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + 94 * 20 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a16bf61aaf6f4e70a66965b60b055c45

query I rowsort
SELECT DISTINCT + 35 AS col1 FROM tab0
----
35

query I rowsort
SELECT DISTINCT - + col0 * + ( col2 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + col0 + col2 * col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + col1 * + 32 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT + col2 * + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + - col0 + ( col1 * + col1 ) FROM tab0 AS cor0
----
7372
8192
9374

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3030
SELECT ALL + col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3030
SELECT ALL + col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3031
SELECT + col0 * cor0.col2 DIV 82 FROM tab0 cor0
----
0
89
9

skipif mysql # not compatible
query I rowsort label-3031
SELECT + col0 * cor0.col2 / 82 FROM tab0 cor0
----
0
89
9

query I rowsort
SELECT ALL cor0.col2 * 59 FROM tab1 AS cor0
----
3186
3363
5664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 70 col0 FROM tab0 AS cor0
----
-19
35
46

query I rowsort
SELECT ALL col2 - col0 * col0 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL col0 + + ( col2 + - cor0.col1 ) FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT ALL cor0.col0 * + 58 FROM tab2 cor0
----
406
4524
4582

query I rowsort
SELECT + + col2 + + col1 AS col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT + + ( cor0.col1 ) + - col0 * + col0 * - 27 FROM tab2 AS cor0
----
1354
164327
168524

query I rowsort
SELECT ( - 91 ) * col0 FROM tab1 AS cor0
----
-273
-5824
-7280

query I rowsort
SELECT DISTINCT + col1 * + 53 AS col0 FROM tab2
----
1643
3127
901

query I rowsort
SELECT ALL + 91 * - col1 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT DISTINCT + 92 + col0 AS col0 FROM tab1 cor0
----
156
172
95

query I rowsort
SELECT + col2 * col2 + cor0.col2 * cor0.col0 * col0 FROM tab0 cor0
----
1226
20097
656246

onlyif mysql # use DIV operator for integer division
query I rowsort label-3044
SELECT DISTINCT - + col2 DIV col0 + + ( 91 ) AS col2 FROM tab0 AS cor0
----
90
91

skipif mysql # not compatible
query I rowsort label-3044
SELECT DISTINCT - + col2 / col0 + + ( 91 ) AS col2 FROM tab0 AS cor0
----
90
91

query I rowsort
SELECT ALL + col1 + col2 * ( col0 ) FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 77 * + col2 + - ( ( + col1 ) ) + - col1 col2 FROM tab0 AS cor0
----
-117
2369
6132

query I rowsort
SELECT tab2.col2 - tab2.col1 * - col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT col2 + 97 + col1 FROM tab1
----
164
177
206

query I rowsort
SELECT DISTINCT - 87 AS col2 FROM tab2, tab0 AS cor0
----
-87

query I rowsort
SELECT ALL - col0 * - ( tab0.col0 ) FROM tab0
----
1225
576
7921

query I rowsort
SELECT 96 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT ALL + tab0.col1 * col1 + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT 58 + + col2 * ( + tab2.col2 ) AS col2 FROM tab2
----
1502
734
787

query I rowsort
SELECT DISTINCT - tab2.col1 + col2 + 30 AS col0 FROM tab2
----
-3
26
51

query I rowsort
SELECT 86 + - col2 FROM tab1 AS cor0
----
-10
29
32

query I rowsort
SELECT ALL + + col2 * - cor0.col0 + + 64 FROM tab0 AS cor0
----
-7234
-728
29

query I rowsort
SELECT DISTINCT + tab2.col2 + - col2 * ( 59 ) FROM tab2
----
-1508
-1566
-2204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col1 ) col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ( + col0 ) + + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + - col2 + ( col2 + col1 ) * col0 FROM tab1 AS cor0
----
186
4231
8624

query I rowsort
SELECT ALL col1 * col1 - + col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT + col1 * - cor0.col1 + - col1 * 40 FROM tab0 AS cor0
----
-10836
-11921
-13289

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3063
SELECT - + CAST( - col2 AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-3063
SELECT - + CAST ( - col2 AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - 19 + - cor0.col1 FROM tab0 AS cor0
----
-105
-110
-116

query I rowsort
SELECT ALL col1 * - col2 + col2 FROM tab2 cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-3066
SELECT DISTINCT + col2 DIV col1 + col2 AS col0 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-3066
SELECT DISTINCT + col2 / col1 + col2 AS col0 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT ALL - - ( col0 ) * + cor0.col1 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT 11 AS col1 FROM tab1, tab1 cor0, tab2 AS cor1
----
11

query I rowsort
SELECT DISTINCT col2 + col2 * col0 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - col0 * col0 + 51 FROM tab0 AS cor0
----
-1174
-525
-7870

query I rowsort
SELECT ALL - 58 + col0 * col2 * 42 FROM tab0 AS cor0
----
1412
306458
33206

query I rowsort
SELECT DISTINCT - col2 - + col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT 45 * col2 + + col1 AS col0 FROM tab1 cor0
----
2456
2575
4333

query I rowsort
SELECT - 74 * col0 AS col1 FROM tab0 cor0
----
-1776
-2590
-6586

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 32 col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * col2 col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT - col2 * + col1 * col1 AS col0 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT - cor0.col1 + ( + col2 ) * + col1 + - col1 * + col2 * - col2 AS col1 FROM tab1 AS cor0
----
121043
33050
77194

query I rowsort
SELECT + col1 * 36 FROM tab1
----
360
468
936

query I rowsort
SELECT DISTINCT - tab0.col2 * - 46 AS col2 FROM tab0
----
1518
3772
46

query I rowsort
SELECT ALL + col0 * - ( col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col0 + 75 FROM tab2 AS cor0
----
-3
-4
68

query I rowsort
SELECT ALL - col2 * ( 26 ) * - col0 FROM tab1 AS cor0
----
199680
4212
94848

query I rowsort
SELECT DISTINCT + + col0 * 80 + ( col1 ) AS col2 FROM tab1 AS cor0
----
266
5130
6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3085
SELECT + CAST( NULL AS SIGNED ) + - cor0.col0 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3085
SELECT + CAST ( NULL AS INTEGER ) + - cor0.col0 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 1 + + col0 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3087
SELECT ALL tab2.col1 * - col0 * + ( - col2 * - 19 ) + + ( col2 * CAST( NULL AS SIGNED ) ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3087
SELECT ALL tab2.col1 * - col0 * + ( - col2 * - 19 ) + + ( col2 * CAST ( NULL AS INTEGER ) ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 + CAST ( col0 AS REAL ) AS col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT + - ( + col0 ) + + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + + 10 * - ( + col0 ) + cor0.col2 FROM tab1 AS cor0
----
-583
-704
24

query I rowsort
SELECT DISTINCT + col2 * - 20 + 6 AS col0 FROM tab0
----
-14
-1634
-654

onlyif mysql # use DIV operator for integer division
query I rowsort label-3092
SELECT - tab1.col2 + - col0 DIV col2 AS col2 FROM tab1
----
-54
-58
-96

skipif mysql # not compatible
query I rowsort label-3092
SELECT - tab1.col2 + - col0 / col2 AS col2 FROM tab1
----
-54
-58
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3093
SELECT + col1 + col1 DIV col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-3093
SELECT + col1 + col1 / col1 FROM tab1
----
11
14
27

query I rowsort
SELECT col0 + col2 + + tab2.col0 FROM tab2
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-3095
SELECT DISTINCT col1 DIV + 60 + + col2 AS col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3095
SELECT DISTINCT col1 / + 60 + + col2 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + col0 + ( col2 * + tab0.col2 ) FROM tab0
----
1113
36
6813

query I rowsort
SELECT - ( 48 ) * - col0 * - 10 AS col2 FROM tab0 AS cor0
----
-11520
-16800
-42720

query I rowsort
SELECT + col0 + 86 * - col1 AS col2 FROM tab0 AS cor0
----
-7372
-7737
-8307

query I rowsort
SELECT - col0 + 50 FROM tab2 AS cor0
----
-28
-29
43

query I rowsort
SELECT DISTINCT 19 * + col0 AS col1 FROM tab0
----
1691
456
665

query I rowsort
SELECT ( + 84 * tab1.col1 ) + tab1.col0 AS col1 FROM tab1
----
1172
2187
904

query I rowsort
SELECT col1 * + 67 * col0 FROM tab2
----
14539
308334
89981

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col0 - - 88 col2 FROM tab2
----
10
81
9

query I rowsort
SELECT - col1 * 20 FROM tab0 cor0
----
-1720
-1820
-1940

onlyif mysql # use DIV operator for integer division
query I rowsort label-3105
SELECT + - col2 + col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-3105
SELECT + - col2 + col1 / + col1 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3106
SELECT + col0 + CAST( NULL AS SIGNED ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3106
SELECT + col0 + CAST ( NULL AS INTEGER ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3107
SELECT DISTINCT - col0 * - CAST( NULL AS DECIMAL ) + - col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3107
SELECT DISTINCT - col0 * - CAST ( NULL AS REAL ) + - col2 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + - col2 * + 30 FROM tab1 AS cor0
----
-1620
-1710
-2880

query I rowsort
SELECT col0 * ( col1 ) * - col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT + + col1 - + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + + col0 * cor0.col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3112
SELECT - col0 * CAST( col0 + col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-238
-8112
-9243

skipif mysql # not compatible
query I rowsort label-3112
SELECT - col0 * CAST ( col0 + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-238
-8112
-9243

query I rowsort
SELECT - col0 * 76 AS col2 FROM tab2 AS cor0
----
-532
-5928
-6004

query I rowsort
SELECT DISTINCT - - cor2.col0 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0, tab2 AS cor2
----
7
78
79

query I rowsort
SELECT ALL + col1 * + col1 * - col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3116
SELECT - col2 DIV + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3116
SELECT - col2 / + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col0 * - col2 + col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT + cor1.col0 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to ee8b23a58dda2d92e14ed437e06ed8d2

query I rowsort
SELECT + col2 + 96 * + tab2.col0 AS col2 FROM tab2
----
699
7514
7622

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3120
SELECT - col0 * CAST( NULL AS DECIMAL ) - + col0 * - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3120
SELECT - col0 * CAST ( NULL AS REAL ) - + col0 * - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 50 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

query I rowsort
SELECT ALL - 89 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c36e597b7bc5727536f5bb580e6cebbc

query I rowsort
SELECT ALL ( 5 ) + col0 AS col2 FROM tab2 AS cor0
----
12
83
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * tab1.col0 col0 FROM tab1
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3125
SELECT + col2 + CAST( col1 * col2 AS SIGNED ) AS col2 FROM tab2
----
1560
684
864

skipif mysql # not compatible
query I rowsort label-3125
SELECT + col2 + CAST ( col1 * col2 AS INTEGER ) AS col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT + col0 + 6 FROM tab0 AS cor0
----
30
41
95

query I rowsort
SELECT col2 + - col2 * - col0 AS col1 FROM tab2
----
2054
216
3040

query I rowsort
SELECT col2 * + 58 + - tab2.col1 AS col1 FROM tab2
----
1449
1535
2187

query I rowsort
SELECT - 28 * ( tab2.col1 ) AS col0 FROM tab2
----
-1652
-476
-868

query I rowsort
SELECT + ( + col2 ) * cor0.col2 + ( - cor0.col1 ) AS col0 FROM tab0 cor0
----
-96
1003
6633

onlyif mysql # use DIV operator for integer division
query I rowsort label-3131
SELECT ALL + 43 DIV - col0 AS col0 FROM tab1 AS cor0
----
-14
0
0

skipif mysql # not compatible
query I rowsort label-3131
SELECT ALL + 43 / - col0 AS col0 FROM tab1 AS cor0
----
-14
0
0

query I rowsort
SELECT + col2 * col2 + 12 * - col2 AS col1 FROM tab0 AS cor0
----
-11
5740
693

query I rowsort
SELECT - - 97 + - col1 AS col0 FROM tab1 AS cor0
----
71
84
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-3134
SELECT ALL - - 50 * + col1 + 31 DIV + col0 AS col1 FROM tab0 AS cor0
----
4301
4550
4850

skipif mysql # not compatible
query I rowsort label-3134
SELECT ALL - - 50 * + col1 + 31 / + col0 AS col1 FROM tab0 AS cor0
----
4301
4550
4850

query I rowsort
SELECT ALL - 83 + col1 AS col1 FROM tab1
----
-57
-70
-73

query I rowsort
SELECT ALL tab0.col2 - + col1 AS col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ( col1 ) * col2 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL ( + col1 ) - + col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3139
SELECT - 38 DIV col1 AS col2 FROM tab2 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-3139
SELECT - 38 / col1 AS col2 FROM tab2 cor0
----
-1
-2
0

query I rowsort
SELECT ALL + 1 + - col0 FROM tab2
----
-6
-77
-78

query I rowsort
SELECT + 94 + cor0.col0 * col0 * + 48 AS col2 FROM tab1 AS cor0
----
196702
307294
526

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * - col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col1 * col0 + - col2 * + col0 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT + 64 * - col1 FROM tab1 AS cor0
----
-1664
-640
-832

query I rowsort
SELECT - col0 * + col0 + + col2 AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ( col1 ) + + ( col2 + col0 * + col1 ) FROM tab1 AS cor0
----
1149
158
707

onlyif mysql # use DIV operator for integer division
query I rowsort label-3147
SELECT DISTINCT - col0 DIV cor0.col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-3147
SELECT DISTINCT - col0 / cor0.col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT col0 * - tab0.col0 * + ( - tab0.col1 ) + col2 FROM tab0
----
118826
49569
720893

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( - cor0.col1 ) col2 FROM tab1, tab0, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL col0 + + col1 * - 0 AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + 5 + - col2 FROM tab1 AS cor0
----
-49
-52
-91

query I rowsort
SELECT DISTINCT 31 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
31

query I rowsort
SELECT DISTINCT col0 * + tab1.col1 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT + + col2 * col1 + + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT col0 * 62 FROM tab1 AS cor0
----
186
3968
4960

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + col0 * 35 FROM tab2 AS cor0
----
245
2730
2765

onlyif mysql # use DIV operator for integer division
query I rowsort label-3158
SELECT ALL - col1 + col2 + - 56 * col0 DIV - CAST( ( col0 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
23
52
77

skipif mysql # not compatible
query I rowsort label-3158
SELECT ALL - col1 + col2 + - 56 * col0 / - CAST ( ( col0 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
23
52
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-3159
SELECT ALL - - col1 - - 54 DIV - 89 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3159
SELECT ALL - - col1 - - 54 / - 89 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + cor0.col2 * ( col0 ) AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT 54 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-3162
SELECT DISTINCT - col2 + - ( col2 ) * + col0 + ( col2 + col1 ) DIV - ( cor0.col2 + col0 ) FROM tab1 cor0
----
-217
-3705
-7776

skipif mysql # not compatible
query I rowsort label-3162
SELECT DISTINCT - col2 + - ( col2 ) * + col0 + ( col2 + col1 ) / - ( cor0.col2 + col0 ) FROM tab1 cor0
----
-217
-3705
-7776

query I rowsort
SELECT ALL + col0 + + col1 * 34 FROM tab1 AS cor0
----
404
522
887

onlyif mysql # use DIV operator for integer division
query I rowsort label-3164
SELECT col2 DIV col0 col2 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3164
SELECT col2 / col0 col2 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL + 92 + + tab0.col2 AS col0 FROM tab0
----
125
174
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3166
SELECT ALL col1 DIV - col1 + - col0 * 69 AS col1 FROM tab0
----
-1657
-2416
-6142

skipif mysql # not compatible
query I rowsort label-3166
SELECT ALL col1 / - col1 + - col0 * 69 AS col1 FROM tab0
----
-1657
-2416
-6142

query I rowsort
SELECT - ( ( + col2 ) ) + + 44 * - col1 FROM tab0 AS cor0
----
-3817
-4086
-4269

query I rowsort
SELECT DISTINCT ( + ( col1 ) ) * - col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3169
SELECT + CAST( NULL AS SIGNED ) + + ( col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3169
SELECT + CAST ( NULL AS INTEGER ) + + ( col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 47 * col0 col1 FROM tab0 cor0
----
1128
1645
4183

onlyif mysql # use DIV operator for integer division
query I rowsort label-3171
SELECT - col1 * - col0 DIV - col0 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-3171
SELECT - col1 * - col0 / - col0 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3172
SELECT ALL ( + col2 ) DIV col1 + + tab2.col1 * col0 * col1 FROM tab2
----
22833
271518
6727

skipif mysql # not compatible
query I rowsort label-3172
SELECT ALL ( + col2 ) / col1 + + tab2.col1 * col0 * col1 FROM tab2
----
22833
271518
6727

query I rowsort
SELECT DISTINCT + 9 + + col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
1543
655
846

onlyif mysql # use DIV operator for integer division
query I rowsort label-3174
SELECT ALL - + col2 DIV + 11 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-89
-97
-98

skipif mysql # not compatible
query I rowsort label-3174
SELECT ALL - + col2 / + 11 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-89
-97
-98

query I rowsort
SELECT DISTINCT + + 9 * - 12 + - cor0.col2 - col1 AS col1 FROM tab2 AS cor0
----
-163
-166
-193

query I rowsort
SELECT DISTINCT + ( col1 ) * col2 + + cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
167
2886
7640

query I rowsort
SELECT DISTINCT - col0 - col0 AS col1 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT - col2 * 53 AS col2 FROM tab2 cor0
----
-1378
-1431
-2014

query I rowsort
SELECT ALL - + col1 * 88 AS col2 FROM tab0 cor0
----
-7568
-8008
-8536

query I rowsort
SELECT - col2 + - ( col0 ) AS col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - - col1 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3182
SELECT CAST( NULL AS DECIMAL ) * + col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3182
SELECT CAST ( NULL AS REAL ) * + col0 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 60 * + col0 + 5 AS col0 FROM tab0 AS cor0
----
1445
2105
5345

onlyif mysql # use DIV operator for integer division
query I rowsort label-3184
SELECT DISTINCT - 94 DIV col0 + + tab2.col2 DIV col0 AS col0 FROM tab2
----
-1
-10

skipif mysql # not compatible
query I rowsort label-3184
SELECT DISTINCT - 94 / col0 + + tab2.col2 / col0 AS col0 FROM tab2
----
-1
-10

query I rowsort
SELECT DISTINCT col2 * tab0.col1 * + col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL - tab0.col0 - col1 AS col1 FROM tab0
----
-110
-132
-180

query III rowsort
SELECT * FROM tab1 WHERE + col2 + + col2 * - tab1.col2 + col0 <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 col1 FROM tab2 WHERE NOT NULL >= ( col0 )
----

query I rowsort
SELECT ALL tab1.col2 * - col0 * col2 + + col2 * + tab1.col1 FROM tab1
----
-207366
-7344
-736032

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 * col0 + col0 + - col0 IN ( + col2 )
----

query I rowsort
SELECT DISTINCT - tab0.col2 * col0 * + col2 FROM tab0
----
-26136
-35
-598436

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) BETWEEN + col1 * col2 AND NULL
----

query I rowsort
SELECT DISTINCT - tab2.col1 + + col1 AS col0 FROM tab2
----
0

query I rowsort
SELECT - col1 - - tab1.col0 AS col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL - col1 FROM tab1 WHERE NULL > ( - col2 / col0 )
----

query I rowsort
SELECT col1 * + col1 * + col1 - + col0 FROM tab0
----
636032
753482
912638

query I rowsort
SELECT + tab0.col0 FROM tab0 WHERE NOT ( col1 ) IN ( tab0.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - tab1.col2 * + col1 col0 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT ALL col1 + tab1.col1 * - col0 AS col0 FROM tab1
----
-1027
-52
-630

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE + col0 IN ( col0 + + col1 * col2 )
----

query I rowsort
SELECT tab1.col0 * + col1 FROM tab1 WHERE NOT + col2 / + col2 + col1 * col2 NOT IN ( - col2 )
----

query I rowsort
SELECT col1 + + col0 + - col0 FROM tab0
----
86
91
97

query I rowsort
SELECT + col1 + + col2 * col2 + col1 AS col2 FROM tab1
----
2968
3269
9242

query I rowsort
SELECT ALL - tab1.col2 * - col0 * - tab1.col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT tab2.col2 - tab2.col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT col1 * - col2 * col2 FROM tab2 WHERE NOT ( NULL ) > - col0
----

query I rowsort
SELECT + col0 + col1 * + col2 AS col2 FROM tab1
----
1328
1407
634

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab2 cor0 CROSS JOIN tab1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT col0 FROM tab0 WHERE NOT ( NULL ) = ( col1 * col0 )
----

query I rowsort
SELECT DISTINCT - - col2 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col0 * - cor0.col2 col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT col2 * col1 + + col2 * col1 * col1 AS col2 FROM tab1 AS cor0
----
17472
37908
6270

query I rowsort
SELECT col2 * cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT col1 + + tab0.col2 * - col1 * col1 FROM tab0
----
-243982
-678951
-9312

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( col0 / col2 ) <> ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3216
SELECT col0 * + cor0.col0 + - cor0.col1 + - cor0.col2 DIV + col0 FROM tab1 AS cor0
----
-35
4086
6386

skipif mysql # not compatible
query I rowsort label-3216
SELECT col0 * + cor0.col0 + - cor0.col1 + - cor0.col2 / + col0 FROM tab1 AS cor0
----
-35
4086
6386

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab1 AS cor2, tab0
----
13122 values hashing to 0436f20859a73331883c6e6899aecb3d

query I rowsort
SELECT - + cor0.col0 * 54 FROM tab0 AS cor0
----
-1296
-1890
-4806

query I rowsort
SELECT + - col1 * + 64 + col2 * col0 FROM tab0 cor0
----
-4712
-6173
1474

query I rowsort
SELECT - - 90 + - 10 AS col1 FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT ALL cor0.col0 * - col1 + col1 * + 87 AS col1 FROM tab1 AS cor0
----
2184
230
91

query I rowsort
SELECT DISTINCT + - ( 42 ) + col2 FROM tab0 cor0
----
-41
-9
40

query I rowsort
SELECT DISTINCT col0 + - col1 * col1 AS col1 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3224
SELECT - col0 DIV 99 + + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3224
SELECT - col0 / 99 + + col1 FROM tab0 AS cor0
----
86
91
97

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to be7848c91584d04f21fd5bbb0d239aca

query I rowsort
SELECT + - 50 + + col0 AS col0 FROM tab0 AS cor0
----
-15
-26
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-3227
SELECT - col2 DIV + cor0.col1 + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3227
SELECT - col2 / + cor0.col1 + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3228
SELECT - 81 * col1 DIV - 89 + + 6 FROM tab0 AS cor0
----
84
88
94

skipif mysql # not compatible
query I rowsort label-3228
SELECT - 81 * col1 / - 89 + + 6 FROM tab0 AS cor0
----
84
88
94

query I rowsort
SELECT + 67 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3230
SELECT - col0 + - col0 DIV 74 col0 FROM tab2 AS cor0
----
-7
-79
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3230
SELECT - col0 + - col0 / 74 col0 FROM tab2 AS cor0
----
-7
-79
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3231
SELECT ALL + ( - col2 + + CAST( NULL AS SIGNED ) ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3231
SELECT ALL + ( - col2 + + CAST ( NULL AS INTEGER ) ) FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col1 + + col0 col0 FROM tab0 cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - - cor0.col1 * - 27 FROM tab2 AS cor0
----
-1593
-459
-837

query I rowsort
SELECT ALL - - col0 * cor0.col0 + col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL + col0 * - col1 * - col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT ALL + col1 * ( col1 ) - col1 * col0 FROM tab1 AS cor0
----
-540
-871
598

query I rowsort
SELECT - ( - 98 ) * col0 AS col1 FROM tab2 AS cor0
----
686
7644
7742

query I rowsort
SELECT + + ( - col0 ) + col1 + col0 FROM tab2 cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3239
SELECT + + 70 DIV col1 + col2 + - 8 AS col2 FROM tab1 AS cor0
----
48
56
93

skipif mysql # not compatible
query I rowsort label-3239
SELECT + + 70 / col1 + col2 + - 8 AS col2 FROM tab1 AS cor0
----
48
56
93

query I rowsort
SELECT DISTINCT - ( + tab0.col0 ) + - tab0.col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT col2 + + 51 AS col0 FROM tab1
----
105
108
147

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3242
SELECT DISTINCT + + col0 + - col0 + col1 * - CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-3242
SELECT DISTINCT + + col0 + - col0 + col1 * - CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + col1 + col0 * col1 AS col0 FROM tab1 cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-3244
SELECT ALL 56 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3244
SELECT ALL 56 / col0 AS col0 FROM tab2 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - cor0.col2 * col1 + ( + 20 ) col0 FROM tab1 AS cor0
----
-1241
-1410
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * - col0 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col0 - 28 AS col2 FROM tab2 AS cor0
----
-21
50
51

query I rowsort
SELECT - 7 + - col0 AS col0 FROM tab1 cor0
----
-10
-71
-87

query I rowsort
SELECT DISTINCT - - col0 + col0 * 21 AS col1 FROM tab2 AS cor0
----
154
1716
1738

onlyif mysql # use DIV operator for integer division
query I rowsort label-3250
SELECT cor0.col2 * col0 DIV - 20 + + col1 FROM tab0 AS cor0
----
-273
47
96

skipif mysql # not compatible
query I rowsort label-3250
SELECT cor0.col2 * col0 / - 20 + + col1 FROM tab0 AS cor0
----
-273
47
96

query I rowsort
SELECT DISTINCT - - col0 * + col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL col2 * cor0.col1 + - 51 FROM tab0 AS cor0
----
2787
46
7411

query I rowsort
SELECT ALL - col1 + cor0.col2 * - col2 FROM tab2 cor0
----
-1461
-735
-760

query I rowsort
SELECT - col2 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col0 + col2 - 52 * ( + col1 ) AS col1 FROM tab2 AS cor0
----
-1592
-3120
-925

query I rowsort
SELECT cor0.col2 * + col0 + col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-3257
SELECT ALL - - col0 DIV + col1 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3257
SELECT ALL - - col0 / + col1 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 - + 59 AS col0 FROM tab0 AS cor0
----
-1148
-60
-6783

query I rowsort
SELECT DISTINCT col0 + + 64 AS col2 FROM tab1
----
128
144
67

query I rowsort
SELECT DISTINCT + ( col1 ) + - col0 * ( - col1 * - tab0.col1 ) AS col0 FROM tab0
----
-177418
-329218
-736918

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT col1 + - 5 * col0 AS col1 FROM tab2
----
-331
-378
-4

query I rowsort
SELECT ALL - col2 + col0 * col1 FROM tab2
----
1305
190
4576

query I rowsort
SELECT ALL cor0.col1 * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL cor0.col2 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 * col0 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + col0 * 81 FROM tab1 cor0
----
243
5184
6480

query I rowsort
SELECT - col1 * col1 * ( col0 * 84 ) - col2 * col1 AS col0 FROM tab0 cor0
----
-14913174
-27662557
-61916218

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3269
SELECT + col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3269
SELECT + col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * 6 FROM tab2 AS cor0
----
42
468
474

query I rowsort
SELECT + 15 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT cor0.col0 * 88 + col1 * col1 + + col2 FROM tab1 AS cor0
----
5789
7305
994

query I rowsort
SELECT + col1 * ( + col1 * - col2 ) AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT col1 + 49 + - col0 AS col1 FROM tab1 AS cor0
----
-18
-5
72

query I rowsort
SELECT DISTINCT col2 * col0 + - col2 AS col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT col1 * + 22 - - col2 AS col1 FROM tab2 AS cor0
----
1324
412
709

query I rowsort
SELECT - col1 + col2 + + tab1.col1 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT + col2 + 66 AS col1 FROM tab0
----
148
67
99

query I rowsort
SELECT + col2 + 22 * col2 + - col2 * col2 * col1 FROM tab2 cor0
----
-21978
-23674
-39286

query I rowsort
SELECT ALL 56 * + col1 + col0 FROM tab1 AS cor0
----
1459
624
808

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3281
SELECT + - CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3281
SELECT + - CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 - tab0.col2 AS col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT ALL col1 * + 21 + + col0 + + col1 FROM tab0
----
1916
2091
2169

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col1 + tab1.col2 col1 FROM tab1
----
29
3
77

query I rowsort
SELECT DISTINCT + ( 43 ) FROM tab1, tab1 AS cor0
----
43

query I rowsort
SELECT - col0 * + 32 - - col2 * ( - 48 ) FROM tab0 cor0
----
-1168
-2352
-6784

onlyif mysql # use DIV operator for integer division
query I rowsort label-3287
SELECT DISTINCT - 44 DIV col0 + + col0 col0 FROM tab1 AS cor0
----
-11
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3287
SELECT DISTINCT - 44 / col0 + + col0 col0 FROM tab1 AS cor0
----
-11
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 20 col1 FROM tab1
----
30
33
46

query I rowsort
SELECT + 34 - - col1 FROM tab1 AS cor0
----
44
47
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3290
SELECT ALL + - CAST( col2 AS SIGNED ) + col1 * + col2 col0 FROM tab0 AS cor0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3290
SELECT ALL + - CAST ( col2 AS INTEGER ) + col1 * + col2 col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT + col2 + col0 + - col1 AS col2 FROM tab2 cor0
----
100
3
45

query I rowsort
SELECT DISTINCT 33 FROM tab1 cor0
----
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + col1 col1 FROM tab0 cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL - + col1 * - col1 + + cor0.col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + col1 * 70 + col0 * 78 * col2 + + col1 * 26 FROM tab1 AS cor0
----
15132
285504
600288

query I rowsort
SELECT DISTINCT + + ( + col0 ) + - col2 + col2 * 52 FROM tab1 cor0
----
2757
2971
4976

query I rowsort
SELECT - - 33 FROM tab1 AS cor0
----
33
33
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-3298
SELECT DISTINCT - col1 + ( cor0.col2 ) DIV col1 FROM tab1 cor0
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-3298
SELECT DISTINCT - col1 + ( cor0.col2 ) / col1 FROM tab1 cor0
----
-24
-5
-6

query I rowsort
SELECT DISTINCT - - col2 + + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col1 + + col0 * + 89 AS col0 FROM tab1 AS cor0
----
293
5706
7133

query I rowsort
SELECT ALL col1 * - col1 + 94 + col2 * - col0 * - 32 AS col0 FROM tab0 AS cor0
----
-8195
18042
225349

onlyif mysql # use DIV operator for integer division
query I rowsort label-3302
SELECT ALL - 8 DIV col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3302
SELECT ALL - 8 / col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 7 + + cor0.col1 FROM tab0 AS cor0
----
79
84
90

query I rowsort
SELECT ALL - col2 * - col0 - ( + 89 ) AS col2 FROM tab2 AS cor0
----
100
1939
2913

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 + 90 * - cor0.col0 * - 49 FROM tab2 cor0
----
30870
343980
348390

query I rowsort
SELECT DISTINCT - - ( + col1 ) * 63 + col0 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-2366
2716
3354

query I rowsort
SELECT - + 50 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1300
-500
-650

query I rowsort
SELECT ALL col1 + + col2 * col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - col1 * + 95 FROM tab2 AS cor0
----
-1615
-2945
-5605

query I rowsort
SELECT ALL - col1 + + col0 * 19 AS col2 FROM tab0 AS cor0
----
1600
370
568

query I rowsort
SELECT 80 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to fea98c25258e93c9ff3d86ecc4f58d8a

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + cor0.col2 * CAST ( + col1 AS REAL ) col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - 7 * - cor1.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
49
546
553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - col0 col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - col1 * + col2 * 87 FROM tab1 AS cor0
----
-108576
-122148
-49590

query I rowsort
SELECT DISTINCT + col0 * - 15 FROM tab2 AS cor0
----
-105
-1170
-1185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + ( cor0.col1 ) col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 46 + - col2 * col2 FROM tab1 AS cor0
----
-2870
-3203
-9170

query I rowsort
SELECT DISTINCT 59 + col2 * - ( - col1 ) FROM tab2 AS cor0
----
1593
705
896

query I rowsort
SELECT + - col2 * - col2 - ( + col1 ) * col2 FROM tab2 AS cor0
----
-108
-858
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-3323
SELECT - cor0.col0 DIV + col0 + cor0.col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-3323
SELECT - cor0.col0 / + col0 + cor0.col2 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT ( col1 ) * + col1 - col1 * col2 FROM tab0 AS cor0
----
4558
819
9312

query I rowsort
SELECT DISTINCT - col0 * - ( col0 ) FROM tab1
----
4096
6400
9

query I rowsort
SELECT - + 53 AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 2876418587c77a182d88db2907b0a51a

query I rowsort
SELECT - col0 - 69 FROM tab0 AS cor0
----
-104
-158
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 89 col0 FROM tab0
----
-89
-89
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3329
SELECT CAST( + 39 AS SIGNED ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

skipif mysql # not compatible
query I rowsort label-3329
SELECT CAST ( + 39 AS INTEGER ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT DISTINCT - ( col1 ) * col1 FROM tab0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3331
SELECT ALL - CAST( NULL AS DECIMAL ) * - 24 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3331
SELECT ALL - CAST ( NULL AS REAL ) * - 24 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 51 * ( col1 + + cor0.col1 ) FROM tab1 AS cor0
----
-1020
-1326
-2652

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT - + col0 DIV 65 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3333
SELECT - + col0 / 65 AS col2 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3334
SELECT ALL col1 DIV ( col1 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3334
SELECT ALL col1 / ( col1 ) FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 + + col1 col2 FROM tab2 AS cor0
----
-5
37
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 17 col2 FROM tab0 cor0
----
17
17
17

query I rowsort
SELECT DISTINCT 80 * col2 AS col1 FROM tab2
----
2080
2160
3040

query I rowsort
SELECT ALL - ( col1 * + col0 ) AS col2 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3339
SELECT DISTINCT col2 DIV - cor0.col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-3339
SELECT DISTINCT col2 / - cor0.col0 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT 79 * col2 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT DISTINCT + cor0.col1 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT col2 + 2 FROM tab1 AS cor0
----
56
59
98

query I rowsort
SELECT col2 + + 17 AS col1 FROM tab1 AS cor0
----
113
71
74

query I rowsort
SELECT + col2 * + ( + 61 ) FROM tab1
----
3294
3477
5856

query I rowsort
SELECT ALL 92 * 17 - cor0.col0 * + ( + col0 ) * + col0 AS col1 FROM tab0 cor0
----
-12260
-41311
-703405

query I rowsort
SELECT DISTINCT + - 87 + - col2 * - col2 FROM tab0 AS cor0
----
-86
1002
6637

query I rowsort
SELECT col2 + tab0.col1 + - 52 FROM tab0
----
121
46
67

query I rowsort
SELECT DISTINCT tab0.col1 - + tab0.col0 AS col2 FROM tab0
----
2
62

query I rowsort
SELECT + col1 * cor0.col0 + 58 * - 68 * - col0 - + ( + 30 ) AS col0 FROM tab1 AS cor0
----
11880
253026
316530

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3350
SELECT - 71 + col1 + + CAST( col1 AS SIGNED ) FROM tab2 cor0
----
-37
-9
47

skipif mysql # not compatible
query I rowsort label-3350
SELECT - 71 + col1 + + CAST ( col1 AS INTEGER ) FROM tab2 cor0
----
-37
-9
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 - col1 col1 FROM tab2 AS cor0
----
39
67
81

query I rowsort
SELECT DISTINCT + col2 * col0 * col1 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3353
SELECT + col0 + - col2 DIV 22 + ( col2 * cor0.col1 ) FROM tab1 AS cor0
----
1324
1405
632

skipif mysql # not compatible
query I rowsort label-3353
SELECT + col0 + - col2 / 22 + ( col2 * cor0.col1 ) FROM tab1 AS cor0
----
1324
1405
632

query I rowsort
SELECT ALL 18 + - col1 FROM tab2 AS cor0
----
-13
-41
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 72 * - cor0.col0 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8f2f245e55958c0fe887818bee200447

query I rowsort
SELECT + + cor0.col2 + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT 5 AS col2 FROM tab0, tab0 AS cor0
----
5

query I rowsort
SELECT - cor0.col1 * - ( col0 ) FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3359
SELECT DISTINCT + - col0 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3359
SELECT DISTINCT + - col0 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col0 * col0 + + 42 AS col2 FROM tab1 AS cor0
----
4138
51
6442

query I rowsort
SELECT DISTINCT - col1 * - col1 + + col2 + - col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-3362
SELECT DISTINCT col2 DIV col1 + - col1 AS col1 FROM tab2 AS cor0
----
-15
-31
-59

skipif mysql # not compatible
query I rowsort label-3362
SELECT DISTINCT col2 / col1 + - col1 AS col1 FROM tab2 AS cor0
----
-15
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 57 col1 FROM tab1 AS cor0
----
121
137
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3364
SELECT - cor1.col1 DIV - 77 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-3364
SELECT - cor1.col1 / - 77 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - 79 - col2 AS col1 FROM tab1
----
-133
-136
-175

query I rowsort
SELECT DISTINCT 66 AS col0 FROM tab0
----
66

query I rowsort
SELECT DISTINCT + col2 + + cor0.col2 AS col2 FROM tab0 cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 - cor0.col0 col1 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL - + col1 + + 27 FROM tab0 AS cor0
----
-59
-64
-70

query I rowsort
SELECT ALL - + 69 FROM tab0 cor0
----
-69
-69
-69

query I rowsort
SELECT + + cor0.col1 * col1 + + 90 FROM tab1 AS cor0
----
190
259
766

query I rowsort
SELECT ALL - col2 + - col2 * ( col2 ) AS col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 + - col2 col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - 3 + col1 FROM tab2 AS cor0
----
14
28
56

query I rowsort
SELECT ALL col2 * - col2 * + col2 + 44 AS col1 FROM tab2 AS cor0
----
-17532
-19639
-54828

query I rowsort
SELECT + ( - col2 ) + - col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL + - col2 + col1 * col1 + col2 AS col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3378
SELECT col2 * ( + col1 * CAST( col1 AS SIGNED ) ) - + col2 FROM tab1
----
16128
36450
5643

skipif mysql # not compatible
query I rowsort label-3378
SELECT col2 * ( + col1 * CAST ( col1 AS INTEGER ) ) - + col2 FROM tab1
----
16128
36450
5643

query I rowsort
SELECT ALL - 17 AS col1 FROM tab2
----
-17
-17
-17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 + + col1 + - cor0.col0 * col0 col0 FROM tab0 cor0
----
1574
2267
269

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - col0 + - col0 AS REAL ) FROM tab1
----
-128
-160
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3382
SELECT DISTINCT - 55 + col2 DIV 49 + col1 col1 FROM tab0 AS cor0
----
31
37
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3382
SELECT DISTINCT - 55 + col2 / 49 + col1 col1 FROM tab0 AS cor0
----
31
37
42

query I rowsort
SELECT ALL - + 7 + col0 FROM tab0 AS cor0
----
17
28
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3384
SELECT ALL - cor0.col2 * cor0.col1 DIV - ( 29 ) - - col1 * 42 FROM tab2 AS cor0
----
1330
2530
736

skipif mysql # not compatible
query I rowsort label-3384
SELECT ALL - cor0.col2 * cor0.col1 / - ( 29 ) - - col1 * 42 FROM tab2 AS cor0
----
1330
2530
736

query I rowsort
SELECT - ( col0 ) + col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - 77 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT + + col2 * - col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - tab2.col0 * 20 AS col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
-140
-1560
-1580

onlyif mysql # use DIV operator for integer division
query I rowsort label-3389
SELECT - - col1 + - 76 DIV col2 FROM tab0 AS cor0
----
21
84
91

skipif mysql # not compatible
query I rowsort label-3389
SELECT - - col1 + - 76 / col2 FROM tab0 AS cor0
----
21
84
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-3390
SELECT + - col1 * 45 + + col2 DIV - col2 FROM tab0 AS cor0
----
-3871
-4096
-4366

skipif mysql # not compatible
query I rowsort label-3390
SELECT + - col1 * 45 + + col2 / - col2 FROM tab0 AS cor0
----
-3871
-4096
-4366

query I rowsort
SELECT tab1.col2 + col1 AS col2 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3392
SELECT ALL col1 * - 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-3392
SELECT ALL col1 * - col2 * CAST ( NULL AS INTEGER ) col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3393
SELECT - 68 DIV col1 AS col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-3393
SELECT - 68 / col1 AS col1 FROM tab2 AS cor0
----
-1
-2
-4

query I rowsort
SELECT + col0 * col0 + tab1.col0 * col0 FROM tab1
----
12800
18
8192

query I rowsort
SELECT - + ( col2 ) * col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL 73 + 78 FROM tab0 cor0
----
151
151
151

query I rowsort
SELECT - col1 + cor0.col1 * + col2 AS col0 FROM tab0 AS cor0
----
0
2752
7371

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - tab0.col0 * col0 + col0 * + ( - 54 * tab0.col0 ) col2 FROM tab0
----
-31647
-435573
-67374

query I rowsort
SELECT DISTINCT col1 * col0 + col1 + col1 * - ( - 1 ) AS col0 FROM tab2
----
1377
279
4720

query I rowsort
SELECT DISTINCT + col1 + - 99 FROM tab1
----
-73
-86
-89

query I rowsort
SELECT DISTINCT tab0.col0 + ( + 54 ) FROM tab0
----
143
78
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3402
SELECT col0 * + 80 + + col1 * - col1 DIV + col1 FROM tab2
----
529
6181
6303

skipif mysql # not compatible
query I rowsort label-3402
SELECT col0 * + 80 + + col1 * - col1 / + col1 FROM tab2
----
529
6181
6303

query I rowsort
SELECT ALL 17 * - col2 + col2 AS col2 FROM tab0 AS cor0
----
-1312
-16
-528

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + - ( col0 ) * CAST ( - col1 AS REAL ) FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT + ( col2 ) AS col1 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 + + 51 col0 FROM tab2 AS cor0
----
110
68
82

query I rowsort
SELECT DISTINCT - - col0 * 26 AS col0 FROM tab0 AS cor0
----
2314
624
910

query I rowsort
SELECT DISTINCT 46 + + col1 AS col1 FROM tab2 AS cor0
----
105
63
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-3409
SELECT - - 46 + - 89 DIV + col2 FROM tab1 cor0
----
45
45
46

skipif mysql # not compatible
query I rowsort label-3409
SELECT - - 46 + - 89 / + col2 FROM tab1 cor0
----
45
45
46

query I rowsort
SELECT ALL + + 3 + - 15 AS col2 FROM tab1 AS cor0
----
-12
-12
-12

query I rowsort
SELECT ALL ( - col2 ) * - col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT - - col0 * + 36 AS col1 FROM tab2 cor0
----
252
2808
2844

query I rowsort
SELECT DISTINCT + 34 FROM tab2, tab0 cor0, tab2 AS cor1
----
34

query I rowsort
SELECT + - 10 AS col0 FROM tab1 cor0
----
-10
-10
-10

query I rowsort
SELECT - + ( - ( + col2 ) ) AS col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3416
SELECT ALL + 8 DIV col0 + + cor0.col0 FROM tab1 AS cor0
----
5
64
80

skipif mysql # not compatible
query I rowsort label-3416
SELECT ALL + 8 / col0 + + cor0.col0 FROM tab1 AS cor0
----
5
64
80

query I rowsort
SELECT - tab2.col1 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT + - 90 AS col0 FROM tab2 AS cor0
----
-90
-90
-90

query I rowsort
SELECT ALL + + 71 + - col2 FROM tab1 AS cor0
----
-25
14
17

query I rowsort
SELECT - col0 * col1 + ( + 64 ) FROM tab0 AS cor0
----
-2000
-3331
-8035

query I rowsort
SELECT ALL - + col0 * cor0.col2 + - 25 FROM tab1 AS cor0
----
-187
-3673
-7705

onlyif mysql # use DIV operator for integer division
query I rowsort label-3422
SELECT - col0 * + col1 + - 23 DIV col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3422
SELECT - col0 * + col1 + - 23 / col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + + col2 * col0 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + 81 + - col0 * - 74 FROM tab1 AS cor0
----
303
4817
6001

query I rowsort
SELECT - + 66 * col1 + + col1 AS col1 FROM tab1 cor0
----
-1690
-650
-845

query I rowsort
SELECT DISTINCT - col1 + col2 * - col2 + 75 AS col1 FROM tab0 AS cor0
----
-1100
-23
-6740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col0 + cor0.col0 * 47 * col0 - cor0.col1 * + 42 col1 FROM tab0 cor0
----
23484
368554
53536

onlyif mysql # use DIV operator for integer division
query I rowsort label-3428
SELECT 5 DIV - col2 + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3428
SELECT 5 / - col2 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ( col2 ) * ( cor0.col1 ) * + col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT + col1 + 62 * - cor0.col0 FROM tab0 AS cor0
----
-1402
-2073
-5427

query I rowsort
SELECT DISTINCT - 95 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-95

query I rowsort
SELECT DISTINCT - + col1 * + 24 FROM tab2 AS cor0
----
-1416
-408
-744

query I rowsort
SELECT - + col1 * - 78 + - col2 FROM tab2 AS cor0
----
1288
2391
4576

query I rowsort
SELECT ALL - cor0.col1 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3435
SELECT DISTINCT col1 DIV + col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3435
SELECT DISTINCT col1 / + col2 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL + col2 * col2 + - col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT - col2 * + 22 + col0 * col0 * col2 + col1 FROM tab0 AS cor0
----
1300
18368
647809

query I rowsort
SELECT DISTINCT - - cor0.col0 + 63 AS col1 FROM tab2 AS cor0
----
141
142
70

query I rowsort
SELECT - cor0.col0 * col2 + - col0 AS col1 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + 52 * col0 FROM tab0
----
1248
1820
4628

query I rowsort
SELECT DISTINCT + - 40 * col1 AS col0 FROM tab0 AS cor0
----
-3440
-3640
-3880

query I rowsort
SELECT ALL col0 + - col2 + ( tab0.col0 ) AS col1 FROM tab0
----
15
69
96

query I rowsort
SELECT + - 77 + + col2 FROM tab1 AS cor0
----
-20
-23
19

query I rowsort
SELECT + 10 * col1 FROM tab1 AS cor0
----
100
130
260

onlyif mysql # use DIV operator for integer division
query I rowsort label-3445
SELECT + col2 DIV col1 + - cor0.col2 + col1 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-3445
SELECT + col2 / col1 + - cor0.col2 + col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3446
SELECT + + col2 DIV cor0.col1 + cor0.col2 AS col0 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3446
SELECT + + col2 / cor0.col1 + cor0.col2 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * 47 FROM tab1
----
141
3008
3760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3448
SELECT 32 DIV + 69 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-3448
SELECT 32 / + 69 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + col2 * + 3 FROM tab2 cor0
----
114
78
81

query I rowsort
SELECT DISTINCT - 24 + cor0.col1 FROM tab2, tab1 AS cor0
----
-11
-14
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3451
SELECT ALL col2 DIV 19 col2 FROM tab2
----
1
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3451
SELECT ALL col2 / 19 col2 FROM tab2
----
1
1
2

query I rowsort
SELECT ( col1 ) * col2 + col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL - 35 * col0 * col0 + col2 FROM tab2
----
-1688
-212914
-218397

query I rowsort
SELECT ALL 87 * - tab1.col0 + - col0 * col0 + col0 AS col2 FROM tab1
----
-13280
-267
-9600

query I rowsort
SELECT DISTINCT + 39 * + col1 + col1 AS col1 FROM tab2
----
1240
2360
680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3456
SELECT ALL - CAST( NULL AS DECIMAL ) + - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3456
SELECT ALL - CAST ( NULL AS REAL ) + - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 26 AS col0 FROM tab0, tab1 AS cor0
----
26

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 10 AS REAL ) * + col2 AS col2 FROM tab2 cor0
----
260
270
380

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 74 col1 FROM tab1 AS cor0
----
222
4736
5920

query I rowsort
SELECT ALL - col2 * col2 * col2 AS col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 AS REAL ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + 83 - + col1 FROM tab0
----
-14
-3
-8

query I rowsort
SELECT DISTINCT - col0 + - col0 AS col2 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT ALL + col0 + col0 AS col2 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT - col2 * col2 + 73 FROM tab0 AS cor0
----
-1016
-6651
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-3466
SELECT col0 DIV col2 + + 32 * + 43 FROM tab1 AS cor0
----
1376
1376
1377

skipif mysql # not compatible
query I rowsort label-3466
SELECT col0 / col2 + + 32 * + 43 FROM tab1 AS cor0
----
1376
1376
1377

query I rowsort
SELECT 67 * col0 + - col0 AS col1 FROM tab0
----
1584
2310
5874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col1 * + col2 col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT ALL - - col1 * - 63 + - ( + col0 ) * col0 * - col0 FROM tab1 AS cor0
----
-1611
261514
511181

query I rowsort
SELECT ALL col2 * - col1 + + col2 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + col0 * 42 + ( col1 ) AS col2 FROM tab1 AS cor0
----
152
2698
3373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3472
SELECT ALL col1 * CAST( + col0 AS SIGNED ) + + col0 + + col1 AS col1 FROM tab0 AS cor0
----
2174
3527
8279

skipif mysql # not compatible
query I rowsort label-3472
SELECT ALL col1 * CAST ( + col0 AS INTEGER ) + + col0 + + col1 AS col1 FROM tab0 AS cor0
----
2174
3527
8279

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 + CAST ( col0 AS REAL ) + col1 * + col1 AS col0 FROM tab1 AS cor0
----
154
236
653

query I rowsort
SELECT ALL tab1.col2 * + tab1.col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col1 * + ( - 38 ) AS col2 FROM tab2 cor0
----
-1178
-2242
-646

query I rowsort
SELECT col2 * col0 * 32 FROM tab0 AS cor0
----
1120
233536
25344

query I rowsort
SELECT ALL + - col2 - cor0.col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + col1 * - col0 + + 2 FROM tab1 AS cor0
----
-1038
-638
-76

query I rowsort
SELECT DISTINCT + col2 * col0 + - col0 * col2 * - cor0.col1 - - col1 AS col2 FROM tab2 AS cor0
----
121739
54053
6079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col2 * col2 col1 FROM tab1 cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT + col0 * - col0 - col2 * col2 AS col2 FROM tab1 AS cor0
----
-15616
-2925
-7345

query I rowsort
SELECT col1 * col1 + + col1 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1079
-470
-728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 + + cor0.col1 col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL + col2 + + cor0.col0 + col0 AS col2 FROM tab1 cor0
----
185
256
60

query I rowsort
SELECT DISTINCT - col0 * col1 + col2 + col2 FROM tab0 AS cor0
----
-1998
-3393
-7935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + cor0.col1 col2 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3487
SELECT ALL - col1 + col1 * cor0.col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3487
SELECT ALL - col1 + col1 * cor0.col2 / + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 + + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT cor0.col2 * col0 * + col2 FROM tab2 AS cor0
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-3490
SELECT - - col0 DIV - col0 + col1 DIV cor0.col0 FROM tab2 AS cor0
----
-1
-1
3

skipif mysql # not compatible
query I rowsort label-3490
SELECT - - col0 / - col0 + col1 / cor0.col0 FROM tab2 AS cor0
----
-1
-1
3

query I rowsort
SELECT - 1 * + cor0.col2 + cor0.col1 * - col2 + cor0.col1 * cor0.col1 FROM tab0 AS cor0
----
4525
737
9311

query I rowsort
SELECT ALL + + col0 * - col2 * col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - 75 * + col2 FROM tab0 AS cor0
----
-2475
-6150
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-3494
SELECT 29 + + col1 DIV - cor0.col2 + col1 * - col1 FROM tab0 AS cor0
----
-7369
-8253
-9477

skipif mysql # not compatible
query I rowsort label-3494
SELECT 29 + + col1 / - cor0.col2 + col1 * - col1 FROM tab0 AS cor0
----
-7369
-8253
-9477

onlyif mysql # use DIV operator for integer division
query I rowsort label-3495
SELECT ALL 64 DIV - col1 FROM tab1 AS cor0
----
-2
-4
-6

skipif mysql # not compatible
query I rowsort label-3495
SELECT ALL 64 / - col1 FROM tab1 AS cor0
----
-2
-4
-6

query I rowsort
SELECT DISTINCT - col1 * col1 - tab1.col0 * col2 AS col2 FROM tab1
----
-3748
-7849
-838

query I rowsort
SELECT ALL - 83 * col0 * col0 - + col1 FROM tab2
----
-4098
-505031
-518020

query I rowsort
SELECT DISTINCT + + col2 * + col0 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT DISTINCT 6 * - col1 FROM tab0 AS cor0
----
-516
-546
-582

query I rowsort
SELECT - + col1 - col0 * col1 AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - + col0 + col2 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT + 36 - + col0 AS col0 FROM tab0
----
-53
1
12

query I rowsort
SELECT + col0 * - col2 + - col0 FROM tab0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT - 96 + col0 * col1 * + col1 FROM tab2
----
22735
271422
6631

query I rowsort
SELECT DISTINCT + col2 + - col0 * - col0 FROM tab2
----
6110
6279
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + - col1 * col0 col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT col2 * + col1 + col2 AS col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL col2 * col2 - + col2 AS col2 FROM tab2 AS cor0
----
1406
650
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 89 + col2 col0 FROM tab2
----
115
116
127

query I rowsort
SELECT 42 * - 28 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 2bcf588a08ea6a1382b5ee8cb1670816

onlyif mysql # use DIV operator for integer division
query I rowsort label-3511
SELECT DISTINCT col2 DIV 36 FROM tab0
----
0
2

skipif mysql # not compatible
query I rowsort label-3511
SELECT DISTINCT col2 / 36 FROM tab0
----
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3512
SELECT + CAST( NULL AS SIGNED ) * col0 + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3512
SELECT + CAST ( NULL AS INTEGER ) * col0 + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col2 + - col0 AS REAL ) FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3514
SELECT ALL + col1 DIV - col1 col0 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3514
SELECT ALL + col1 / - col1 col0 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3515
SELECT 25 DIV - col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-3515
SELECT 25 / - col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT + col0 + + col1 * + 90 * col1 AS col0 FROM tab0 AS cor0
----
665664
745379
846845

query I rowsort
SELECT ALL + 26 * 11 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 35c7ea775742d01022acba3f694a02ce

query I rowsort
SELECT 14 * col1 AS col0 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT + - 48 * + col1 + + col0 AS col2 FROM tab1 AS cor0
----
-1245
-416
-544

query I rowsort
SELECT - 55 * - col0 AS col0 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT - col1 * col2 + col2 * + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 66 + 78 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to a9cc77a5f1bc643a947b8c416f454170

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT ALL + + col1 + + 58 DIV col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3523
SELECT ALL + + col1 + + 58 / col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col0 * + col1 + - cor0.col0 - col0 FROM tab2 AS cor0
----
1185
203
4446

query I rowsort
SELECT - 25 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

query I rowsort
SELECT ALL - tab2.col2 + + tab2.col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - + col1 + ( 7 + - col1 ) FROM tab0 AS cor0
----
-165
-175
-187

onlyif mysql # use DIV operator for integer division
query I rowsort label-3528
SELECT - cor0.col0 DIV 34 - cor0.col2 * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7464
-98

skipif mysql # not compatible
query I rowsort label-3528
SELECT - cor0.col0 / 34 - cor0.col2 * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7464
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3529
SELECT + cor0.col0 * CAST( NULL AS SIGNED ) - col1 * cor0.col1 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3529
SELECT + cor0.col0 * CAST ( NULL AS INTEGER ) - col1 * cor0.col1 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + + 8 AS col1 FROM tab1 AS cor0
----
104
62
65

query I rowsort
SELECT ALL + col2 + 4 AS col1 FROM tab0 AS cor0
----
37
5
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3532
SELECT ALL - col2 * CAST( NULL AS SIGNED ) * col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3532
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) * col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * + 67 + col1 * + col2 FROM tab0 AS cor0
----
-2924
-6402
1365

query I rowsort
SELECT - - col1 + + cor0.col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + 35 * + 75 AS col1 FROM tab2 AS cor0
----
2625
2625
2625

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3536
SELECT + CAST( NULL AS SIGNED ) * + ( col1 ) * - col2 + + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3536
SELECT + CAST ( NULL AS INTEGER ) * + ( col1 ) * - col2 + + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 ) * + col1 + 2 FROM tab0 AS cor0
----
2066
3397
8101

query I rowsort
SELECT - + ( - col2 ) + - col1 * + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL + + ( + 69 ) + - col1 * - cor0.col2 FROM tab0 AS cor0
----
166
2907
7531

query I rowsort
SELECT ALL 34 + 39 AS col0 FROM tab1 AS cor0
----
73
73
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3541
SELECT - CAST( cor0.col2 AS SIGNED ) * - col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-3541
SELECT - CAST ( cor0.col2 AS INTEGER ) * - col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col2 * + 28 * col0 AS col1 FROM tab2 AS cor0
----
-5292
-56784
-84056

query I rowsort
SELECT DISTINCT + - col0 + col2 * col0 + 54 * - col1 * col0 AS col2 FROM tab0 AS cor0
----
-110688
-183330
-430137

query I rowsort
SELECT ALL + col0 + col0 + + ( + 96 ) AS col2 FROM tab1 AS cor0
----
102
224
256

query I rowsort
SELECT + 14 * col0 * - ( - col1 ) + col2 * - col1 FROM tab1 AS cor0
----
-312
13312
8390

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3546
SELECT DISTINCT - - 34 * col0 + CAST( col2 * col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
10400
264
5824

skipif mysql # not compatible
query I rowsort label-3546
SELECT DISTINCT - - 34 * col0 + CAST ( col2 * col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
10400
264
5824

query I rowsort
SELECT DISTINCT + - col1 - col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT + 47 * + cor0.col1 + + col1 FROM tab0 AS cor0
----
4128
4368
4656

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3549
SELECT ALL CAST( NULL AS SIGNED ) / - 41 AS col1 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3549
SELECT ALL CAST ( NULL AS INTEGER ) / - 41 AS col1 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 26 * col1 FROM tab0
----
2236
2366
2522

query I rowsort
SELECT - 64 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT DISTINCT + - col1 + + 28 FROM tab2 cor0
----
-3
-31
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3553
SELECT + - col0 * CAST( NULL AS SIGNED ) * - 50 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3553
SELECT + - col0 * CAST ( NULL AS INTEGER ) * - 50 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - tab2.col0 AS col1 FROM tab2, tab1 cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 75 col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
75

query I rowsort
SELECT DISTINCT col0 * - ( 16 ) FROM tab1
----
-1024
-1280
-48

query I rowsort
SELECT + tab0.col0 * 76 AS col2 FROM tab0
----
1824
2660
6764

onlyif mysql # use DIV operator for integer division
query I rowsort label-3558
SELECT + tab0.col0 * 52 DIV + tab0.col2 AS col2 FROM tab0
----
1820
37
56

skipif mysql # not compatible
query I rowsort label-3558
SELECT + tab0.col0 * 52 / + tab0.col2 AS col2 FROM tab0
----
1820
37
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-3559
SELECT + col0 DIV - tab0.col1 col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3559
SELECT + col0 / - tab0.col1 col2 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3560
SELECT col0 + CAST( NULL AS SIGNED ) * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3560
SELECT col0 + CAST ( NULL AS INTEGER ) * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + - cor0.col0 * - 58 AS col1 FROM tab1 AS cor0
----
148
3702
4627

query I rowsort
SELECT + col2 + col2 * + 80 * col1 FROM tab1 AS cor0
----
112374
45657
99936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3563
SELECT DISTINCT + col2 * + CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3563
SELECT DISTINCT + col2 * + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

query I rowsort
SELECT ALL + 15 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT + col1 + + tab1.col0 * ( col0 ) FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL col0 * 60 + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2736
-4416
591

query I rowsort
SELECT - col2 * - 4 FROM tab0 AS cor0
----
132
328
4

query I rowsort
SELECT DISTINCT + col1 - + 94 FROM tab1 AS cor0
----
-68
-81
-84

query I rowsort
SELECT col0 * cor0.col1 + 23 AS col0 FROM tab1 AS cor0
----
101
1063
663

query I rowsort
SELECT DISTINCT + col2 + col1 * col0 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - + col2 * col2 - col1 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL + col0 + 66 FROM tab1 AS cor0
----
130
146
69

query I rowsort
SELECT DISTINCT col0 * ( + col2 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * 28 FROM tab0 cor0
----
2296
28
924

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 * col2 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - col1 + + cor0.col2 * col1 * col2 FROM tab2 AS cor0
----
22568
24531
39825

query I rowsort
SELECT DISTINCT col1 * 0 + cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - col2 + + 20 AS col1 FROM tab2 AS cor0
----
-18
-6
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3579
SELECT CAST( col0 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-3579
SELECT CAST ( col0 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-3580
SELECT col1 + + 45 DIV + 92 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3580
SELECT col1 + + 45 / + 92 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT - cor0.col2 * - cor0.col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL - 39 + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f4eb5a1036e5bd9f1cbd8ed824f35cab

query I rowsort
SELECT ALL - col1 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 cor1, tab1 cor2, tab2 AS cor3
----
3645 values hashing to 81a27955147133c47c9e8e63dacc5c37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 32 ) col1 FROM tab2, tab1 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT - - col2 * col2 + + col2 + col2 FROM tab0 AS cor0
----
1155
3
6888

query I rowsort
SELECT ALL - col2 * - col1 AS col2 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3588
SELECT ALL 67 + + col2 DIV col0 FROM tab1 AS cor0
----
67
68
85

skipif mysql # not compatible
query I rowsort label-3588
SELECT ALL 67 + + col2 / col0 FROM tab1 AS cor0
----
67
68
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3589
SELECT ALL + col1 DIV col2 + col0 - - col1 * - 69 FROM tab1
----
-1791
-626
-817

skipif mysql # not compatible
query I rowsort label-3589
SELECT ALL + col1 / col2 + col0 - - col1 * - 69 FROM tab1
----
-1791
-626
-817

onlyif mysql # use DIV operator for integer division
query I rowsort label-3590
SELECT - ( + col0 ) DIV col2 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-3590
SELECT - ( + col0 ) / col2 FROM tab0
----
-1
-35
0

query I rowsort
SELECT 39 + tab0.col1 * - col1 FROM tab0
----
-7357
-8242
-9370

query I rowsort
SELECT ALL + 22 + - col2 FROM tab2
----
-16
-4
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3593
SELECT DISTINCT - col2 + col1 DIV 48 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3593
SELECT DISTINCT - col2 + col1 / 48 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT 78 + - col2 * - col2 AS col1 FROM tab0
----
1167
6802
79

query I rowsort
SELECT cor0.col0 + - col0 * - 23 AS col0 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT ALL + + ( - col0 ) * + 55 FROM tab0 AS cor0
----
-1320
-1925
-4895

query I rowsort
SELECT DISTINCT + 79 + + col1 FROM tab0 AS cor0
----
165
170
176

query I rowsort
SELECT ALL + - cor0.col1 + col1 - + col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col0 * col2 + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3600
SELECT DISTINCT + col1 + col2 + CAST( NULL AS DECIMAL ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-3600
SELECT DISTINCT + col1 + col2 + CAST ( NULL AS REAL ) AS col2 FROM tab2
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3601
SELECT ( tab1.col1 ) * - CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3601
SELECT ( tab1.col1 ) * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + tab1.col1 * col1 + col0 * col0 * + tab1.col0 AS col2 FROM tab1
----
262244
512169
703

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 78 * - col1 col0 FROM tab1 cor0
----
-1014
-2028
-780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 + col1 * - ( + cor0.col2 ) col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - 75 * col2 FROM tab0
----
-2475
-6150
-75

query I rowsort
SELECT + 25 + + 75 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to fdbc64d082fd12518b9c868f375d2675

query I rowsort
SELECT + col1 + 38 FROM tab2 AS cor0
----
55
69
97

query I rowsort
SELECT - cor0.col2 + - ( col0 ) FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - + col2 + ( + col2 ) * - col1 AS col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT col0 + cor0.col0 AS col2 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT DISTINCT - col0 * - 66 AS col1 FROM tab0 AS cor0
----
1584
2310
5874

onlyif mysql # use DIV operator for integer division
query I rowsort label-3612
SELECT ALL - cor0.col1 DIV + ( cor0.col1 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort label-3612
SELECT ALL - cor0.col1 / + ( cor0.col1 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3613
SELECT + col0 DIV - col0 + col0 * + col1 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-3613
SELECT + col0 / - col0 + col0 * + col1 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT ALL - 94 AS col0 FROM tab2
----
-94
-94
-94

query I rowsort
SELECT ALL - 15 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3616
SELECT + ( col1 ) + + col1 DIV - col1 AS col0 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3616
SELECT + ( col1 ) + + col1 / - col1 AS col0 FROM tab1
----
12
25
9

query I rowsort
SELECT + + 71 * - col1 FROM tab1 AS cor0
----
-1846
-710
-923

query I rowsort
SELECT DISTINCT ( - col2 ) * col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + - col2 - + col0 * col1 FROM tab1 AS cor0
----
-1136
-132
-697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 73 + 34 col0 FROM tab2 AS cor0
----
-39
-39
-39

query I rowsort
SELECT ALL + + 57 AS col0 FROM tab1 AS cor0
----
57
57
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3622
SELECT DISTINCT + CAST( col0 AS SIGNED ) AS col0 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3622
SELECT DISTINCT + CAST ( col0 AS INTEGER ) AS col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL + + col2 - col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL - ( col2 ) * + col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + 19 + col1 AS col0 FROM tab0 AS cor0
----
105
110
116

query I rowsort
SELECT - + col2 * col1 - 92 FROM tab2 AS cor0
----
-1626
-738
-929

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 86 * cor0.col1 col1 FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT col0 + col1 + - 48 FROM tab0 AS cor0
----
132
62
84

query I rowsort
SELECT ALL 11 * col1 AS col1 FROM tab2 cor0
----
187
341
649

onlyif mysql # use DIV operator for integer division
query I rowsort label-3630
SELECT ALL + col0 + col0 DIV - 10 AS col1 FROM tab1 AS cor0
----
3
58
72

skipif mysql # not compatible
query I rowsort label-3630
SELECT ALL + col0 + col0 / - 10 AS col1 FROM tab1 AS cor0
----
3
58
72

query I rowsort
SELECT DISTINCT - - col2 * col0 * + 19 AS col0 FROM tab0 AS cor0
----
138662
15048
665

query I rowsort
SELECT - tab2.col2 * - col2 * col1 AS col0 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT + tab0.col1 * - tab0.col1 AS col2 FROM tab0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col1 * col0 + col2 * col2 + + col0 col1 FROM tab1
----
2673
2841
8256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) * - col1 + col1 col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - 2 + + 91 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT - + col1 + + col1 * + col1 AS col0 FROM tab1 AS cor0
----
156
650
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 * 78 * - col2 + col0 col2 FROM tab2 AS cor0
----
136423
93366
96883

query I rowsort
SELECT ALL cor0.col1 * 73 FROM tab2, tab2 AS cor0
----
9 values hashing to 16904f09a58f8a5e61fe067c938b7df7

query I rowsort
SELECT - col2 * cor0.col2 + + col0 + 2 FROM tab1 cor0
----
-2911
-3183
-9134

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 4805bcb9c04e49d1f6f82defa880d751

query I rowsort
SELECT ALL col2 + + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT + 45 * col1 AS col2 FROM tab2
----
1395
2655
765

query I rowsort
SELECT DISTINCT 37 + col1 AS col1 FROM tab0 AS cor0
----
123
128
134

query I rowsort
SELECT ALL - + 44 + col1 * col1 + col1 AS col0 FROM tab1 AS cor0
----
138
658
66

query I rowsort
SELECT 6 * + 36 * + col0 FROM tab0
----
19224
5184
7560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3647
SELECT ALL - 81 * col1 + - col0 DIV col1 + - col2 FROM tab0
----
-6999
-7453
-7858

skipif mysql # not compatible
query I rowsort label-3647
SELECT ALL - 81 * col1 + - col0 / col1 + - col2 FROM tab0
----
-6999
-7453
-7858

query I rowsort
SELECT tab1.col1 + + col1 - - col1 FROM tab1
----
30
39
78

query I rowsort
SELECT col2 * - 56 AS col2 FROM tab1 cor0
----
-3024
-3192
-5376

query I rowsort
SELECT 53 * + col2 AS col0 FROM tab2
----
1378
1431
2014

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3651
SELECT ALL + CAST( NULL AS SIGNED ) * 64 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3651
SELECT ALL + CAST ( NULL AS INTEGER ) * 64 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 95 * tab0.col0 * col1 + + tab0.col2 FROM tab0
----
196113
322526
769487

query I rowsort
SELECT + cor0.col1 + + col0 * + col0 FROM tab1 AS cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 35 col2 FROM tab2 AS cor0
----
-1330
-910
-945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3655
SELECT - col2 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-3655
SELECT - col2 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL 0 * + col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL 91 FROM tab0 AS cor0 CROSS JOIN tab0, tab0 cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

query I rowsort
SELECT + col2 - ( 60 ) FROM tab1 AS cor0
----
-3
-6
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + cor0.col1 - col0 * + col1 col1 FROM tab0 cor0
----
-1945
-3297
-7926

onlyif mysql # use DIV operator for integer division
query I rowsort label-3660
SELECT - - col0 * col0 DIV col1 col0 FROM tab2 AS cor0
----
1
103
367

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3660
SELECT - - col0 * col0 / col1 col0 FROM tab2 AS cor0
----
1
103
367

onlyif mysql # use DIV operator for integer division
query I rowsort label-3661
SELECT DISTINCT - col1 DIV ( - tab0.col0 ) FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3661
SELECT DISTINCT - col1 / ( - tab0.col0 ) FROM tab0
----
1
2
3

query I rowsort
SELECT + col2 + + col2 * + col1 FROM tab2
----
1560
684
864

skipif mysql # not compatible
query I rowsort
SELECT col1 + CAST ( + col0 AS REAL ) AS col1 FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3664
SELECT - CAST( NULL AS DECIMAL ) + 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-3664
SELECT - CAST ( NULL AS REAL ) + col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 86 + - col0 * + col2 + + cor0.col1 FROM tab2 AS cor0
----
-1883
-2899
-72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3666
SELECT - CAST( NULL AS SIGNED ) * + col2 - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3666
SELECT - CAST ( NULL AS INTEGER ) * + col2 - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * ( - tab1.col0 ) * col0 + 12 * - col0 AS col1 FROM tab1
----
-270
-41728
-84160

query I rowsort
SELECT DISTINCT - col2 + - col2 AS col2 FROM tab1 AS cor0
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-3669
SELECT DISTINCT + + col2 DIV col0 + cor0.col2 col0 FROM tab2 AS cor0
----
26
30
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3669
SELECT DISTINCT + + col2 / col0 + cor0.col2 col0 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col1 * col0 + + col1 * col2 + col2 FROM tab0 AS cor0
----
15643
3493
4935

query I rowsort
SELECT DISTINCT + 5 * - col2 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT ALL - col1 + cor0.col2 AS col1 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3674
SELECT DISTINCT col0 DIV - 68 AS col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3674
SELECT DISTINCT col0 / - 68 AS col2 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL ( + col1 ) + cor0.col1 * col2 * col0 FROM tab2 cor0
----
119711
51051
5890

query I rowsort
SELECT - + 85 * col2 + + col2 FROM tab0 AS cor0
----
-2772
-6888
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3677
SELECT DISTINCT CAST( - 7 AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-7

skipif mysql # not compatible
query I rowsort label-3677
SELECT DISTINCT CAST ( - 7 AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-7

query I rowsort
SELECT + col1 * col2 + 80 FROM tab1 AS cor0
----
1328
1484
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-3679
SELECT - + col1 DIV col0 + ( + col2 ) AS col0 FROM tab2 cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-3679
SELECT - + col1 / col0 + ( + col2 ) AS col0 FROM tab2 cor0
----
23
26
38

query I rowsort
SELECT + 91 * col0 AS col0 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT ALL - 62 + col0 FROM tab1 AS cor0
----
-59
18
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 77 + col1 col0 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT + 37 * - col2 + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-12768
-4914
-5358

query I rowsort
SELECT col1 * + col2 + - col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-3685
SELECT col1 DIV CAST( col1 AS SIGNED ) AS col2 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3685
SELECT col1 / CAST ( col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3686
SELECT + + col0 DIV 74 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3686
SELECT + + col0 / 74 FROM tab2 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3687
SELECT DISTINCT + col2 + CAST( NULL AS DECIMAL ) + col0 AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3687
SELECT DISTINCT + col2 + CAST ( NULL AS REAL ) + col0 AS col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT + 18 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-3689
SELECT DISTINCT col2 DIV 6 FROM tab1 AS cor0
----
16
9

skipif mysql # not compatible
query I rowsort label-3689
SELECT DISTINCT col2 / 6 FROM tab1 AS cor0
----
16
9

query I rowsort
SELECT DISTINCT - - cor0.col1 + - 98 * col1 FROM tab0 AS cor0
----
-8342
-8827
-9409

query I rowsort
SELECT ALL + col2 + 74 FROM tab2
----
100
101
112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( cor0.col1 ) * col2 * - col1 + cor0.col1 * col1 col0 FROM tab1 cor0
----
-16055
-35828
-5600

onlyif mysql # use DIV operator for integer division
query I rowsort label-3693
SELECT DISTINCT + + 19 DIV cor0.col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3693
SELECT DISTINCT + + 19 / cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT col0 * col0 + - col0 FROM tab1 cor0
----
4032
6
6320

query I rowsort
SELECT ALL - + ( 89 ) * col1 + + col1 AS col2 FROM tab0 cor0
----
-7568
-8008
-8536

onlyif mysql # use DIV operator for integer division
query I rowsort label-3696
SELECT ALL ( + ( - col0 ) ) + ( ( cor0.col1 ) ) DIV - 49 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3696
SELECT ALL ( + ( - col0 ) ) + ( ( cor0.col1 ) ) / - 49 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - 16 - - col2 FROM tab1 AS cor0
----
38
41
80

query I rowsort
SELECT DISTINCT + - 6 * cor0.col0 * - cor0.col2 FROM tab1 cor0
----
21888
46080
972

query I rowsort
SELECT ALL + - col0 * - col1 + + col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-3700
SELECT + + ( + cor0.col1 ) DIV col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3700
SELECT + + ( + cor0.col1 ) / col2 FROM tab0 AS cor0
----
1
2
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3701
SELECT - + ( col0 ) DIV - col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3701
SELECT - + ( col0 ) / - col2 AS col1 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT DISTINCT + col1 * - col0 + + ( cor0.col0 ) FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - 13 + - col2 AS col2 FROM tab1 AS cor0
----
-109
-67
-70

query I rowsort
SELECT + ( cor0.col0 ) + - col2 * col1 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-3705
SELECT DISTINCT + - 86 DIV - cor0.col0 + - ( cor0.col2 ) DIV - cor0.col0 + ( - col1 ) FROM tab1 cor0
----
-11
-9
20

skipif mysql # not compatible
query I rowsort label-3705
SELECT DISTINCT + - 86 / - cor0.col0 + - ( cor0.col2 ) / - cor0.col0 + ( - col1 ) FROM tab1 cor0
----
-11
-9
20

query I rowsort
SELECT + 32 + - ( col1 + 26 * - col0 ) FROM tab2
----
183
2001
2069

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3707
SELECT DISTINCT + col0 + + CAST( NULL AS SIGNED ) * + cor0.col2 * - col2 col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3707
SELECT DISTINCT + col0 + + CAST ( NULL AS INTEGER ) * + cor0.col2 * - col2 col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - col0 + + ( + 11 ) FROM tab0 AS cor0
----
-13
-24
-78

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab1 AS cor1, tab1, tab1 cor2
----
3645 values hashing to 93e5b836e3f52f458344e73ebce589b5

query I rowsort
SELECT DISTINCT - cor0.col1 + 89 AS col0 FROM tab0 AS cor0
----
-2
-8
3

query I rowsort
SELECT DISTINCT 0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
0

query I rowsort
SELECT ALL - col2 * ( ( col1 ) ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL cor0.col2 + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3714
SELECT DISTINCT + - col0 + - 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-3714
SELECT DISTINCT + - col0 + - CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( tab0.col2 ) FROM tab0, tab2 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3716
SELECT DISTINCT - CAST( col2 AS SIGNED ) * - cor0.col0 * 25 + + col2 FROM tab2 cor0
----
4752
50726
75088

skipif mysql # not compatible
query I rowsort label-3716
SELECT DISTINCT - CAST ( col2 AS INTEGER ) * - cor0.col0 * 25 + + col2 FROM tab2 cor0
----
4752
50726
75088

query I rowsort
SELECT DISTINCT - + col0 + cor0.col2 * col1 AS col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT - 42 + - 87 AS col2 FROM tab1 AS cor0
----
-129
-129
-129

query I rowsort
SELECT DISTINCT + - 94 + - 84 FROM tab1 AS cor0
----
-178

onlyif mysql # use DIV operator for integer division
query I rowsort label-3720
SELECT ALL - + 9 + + col0 DIV - col0 AS col1 FROM tab1 AS cor0
----
-10
-10
-10

skipif mysql # not compatible
query I rowsort label-3720
SELECT ALL - + 9 + + col0 / - col0 AS col1 FROM tab1 AS cor0
----
-10
-10
-10

query I rowsort
SELECT - col0 * + col2 + + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL - col0 * + col1 + col1 AS col2 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT 40 + col1 FROM tab1 AS cor0
----
50
53
66

query I rowsort
SELECT + + 12 - + col2 * col1 FROM tab0 AS cor0
----
-2826
-7450
-85

query I rowsort
SELECT col2 * - col1 + + col0 + - col2 * + col1 AS col1 FROM tab0 AS cor0
----
-14835
-159
-5652

query I rowsort
SELECT - + cor0.col1 + 66 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to b616a6b156ff18d2bdd13f2cb7ffbc5a

query I rowsort
SELECT ALL 23 * col1 AS col1 FROM tab2 AS cor0
----
1357
391
713

query I rowsort
SELECT + col2 + ( col1 ) + col0 FROM tab0
----
133
143
262

query I rowsort
SELECT + 33 + tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 3fb85cc92e03b2fed91dc4bdcc1caf96

query I rowsort
SELECT ALL + + 71 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT - 31 + col0 FROM tab0
----
-7
4
58

query I rowsort
SELECT 54 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT + col1 * - 46 AS col1 FROM tab2
----
-1426
-2714
-782

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3734
SELECT ALL - CAST( NULL AS SIGNED ) + col0 / col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3734
SELECT ALL - CAST ( NULL AS INTEGER ) + col0 / col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col0 * 65 AS col2 FROM tab2 cor0
----
455
5070
5135

query I rowsort
SELECT DISTINCT - - ( col2 ) + cor0.col1 * col0 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT 46 * - col0 + - col0 + ( + col1 ) FROM tab2 AS cor0
----
-298
-3607
-3696

query I rowsort
SELECT - ( 31 * + col2 ) AS col1 FROM tab2
----
-1178
-806
-837

query I rowsort
SELECT + col0 - + 76 AS col0 FROM tab2 AS cor0
----
-69
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col1 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3741
SELECT - col1 - + col1 DIV + ( 52 ) FROM tab2
----
-17
-31
-60

skipif mysql # not compatible
query I rowsort label-3741
SELECT - col1 - + col1 / + ( 52 ) FROM tab2
----
-17
-31
-60

query I rowsort
SELECT - tab0.col1 - - col2 * - 98 AS col0 FROM tab0
----
-195
-3320
-8127

query I rowsort
SELECT ALL col1 * - col2 * col1 AS col1 FROM tab0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 66 * - col2 col2 FROM tab2
----
1716
1782
2508

query I rowsort
SELECT + cor0.col2 * 96 FROM tab1, tab0 AS cor0
----
9 values hashing to 40abdfefbb76d43d86389529789c402d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3746
SELECT ALL + col1 DIV + 73 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3746
SELECT ALL + col1 / + 73 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 + col0 * + col1 AS col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT col1 * + cor0.col2 * 70 FROM tab2 AS cor0
----
107380
45220
58590

query I rowsort
SELECT DISTINCT + col2 * + 85 FROM tab1
----
4590
4845
8160

onlyif mysql # use DIV operator for integer division
query I rowsort label-3750
SELECT - - col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3750
SELECT - - col2 / + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT DISTINCT col2 * + ( col1 ) * + col1 FROM tab2 cor0
----
10982
25947
90506

query I rowsort
SELECT ALL + col2 + - 69 FROM tab2 cor0
----
-31
-42
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3753
SELECT DISTINCT cor0.col1 DIV + 13 AS col1 FROM tab0 AS cor0
----
6
7

skipif mysql # not compatible
query I rowsort label-3753
SELECT DISTINCT cor0.col1 / + 13 AS col1 FROM tab0 AS cor0
----
6
7

query I rowsort
SELECT DISTINCT col2 * col2 + + ( col2 ) * 58 * + 33 FROM tab2 cor0
----
50440
52407
74176

query I rowsort
SELECT + - col1 + col1 * - ( - 61 ) AS col0 FROM tab2 AS cor0
----
1020
1860
3540

onlyif mysql # use DIV operator for integer division
query I rowsort label-3756
SELECT + 44 * - col1 DIV tab1.col1 AS col2 FROM tab1
----
-44
-44
-44

skipif mysql # not compatible
query I rowsort label-3756
SELECT + 44 * - col1 / tab1.col1 AS col2 FROM tab1
----
-44
-44
-44

query I rowsort
SELECT 2 AS col0 FROM tab1, tab2 cor0, tab0 cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-3758
SELECT col1 + 3 DIV - cor0.col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3758
SELECT col1 + 3 / - cor0.col2 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3759
SELECT DISTINCT col0 - col1 DIV col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3759
SELECT DISTINCT col0 - col1 / col2 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3760
SELECT DISTINCT ( 9 ) DIV cor1.col1 AS col0 FROM tab0, tab1 cor0, tab0 cor1
----
0

skipif mysql # not compatible
query I rowsort label-3760
SELECT DISTINCT ( 9 ) / cor1.col1 AS col0 FROM tab0, tab1 cor0, tab0 cor1
----
0

query I rowsort
SELECT ALL - 38 * 56 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c963aa286fa7a68353886bef7d325977

query I rowsort
SELECT + col0 * - tab1.col1 AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - 11 * 89 FROM tab0 AS cor0
----
-979
-979
-979

query I rowsort
SELECT 13 * col1 FROM tab0 AS cor0
----
1118
1183
1261

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3765
SELECT - col2 * CAST( NULL AS DECIMAL ) col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3765
SELECT - col2 * CAST ( NULL AS REAL ) col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + ( + col0 ) FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 + + 80 col1 FROM tab1
----
-20
-596
-89

query I rowsort
SELECT - 41 + col1 FROM tab1 AS cor0
----
-15
-28
-31

query I rowsort
SELECT 99 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT DISTINCT 42 * + col1 + col1 AS col0 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT DISTINCT + cor0.col0 * + col0 * col2 FROM tab0 cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT + 20 AS col0 FROM tab0 cor0
----
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 18 * - col1 col0 FROM tab0 AS cor0
----
1548
1638
1746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3774
SELECT ALL - CAST( NULL AS SIGNED ) * + tab2.col0 + col0 * - 93 / col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3774
SELECT ALL - CAST ( NULL AS INTEGER ) * + tab2.col0 + col0 * - 93 / col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 22 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

query I rowsort
SELECT DISTINCT tab2.col0 AS col0 FROM tab2, tab0 AS cor0, tab1 cor1
----
7
78
79

query I rowsort
SELECT ALL + cor1.col0 * - 0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 15 * + tab0.col0 col1 FROM tab0
----
1335
360
525

onlyif mysql # use DIV operator for integer division
query I rowsort label-3779
SELECT + cor0.col1 * cor0.col2 DIV + col0 FROM tab2 AS cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-3779
SELECT + cor0.col1 * cor0.col2 / + col0 FROM tab2 AS cor0
----
119
19
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT - col2 * col0 * - 89 + + col2 DIV CAST( ( col0 ) AS SIGNED ) AS col2 FROM tab0 AS cor0
----
3115
649522
70489

skipif mysql # not compatible
query I rowsort label-3780
SELECT - col2 * col0 * - 89 + + col2 / CAST ( ( col0 ) AS INTEGER ) AS col2 FROM tab0 AS cor0
----
3115
649522
70489

onlyif mysql # use DIV operator for integer division
query I rowsort label-3781
SELECT cor0.col0 DIV 63 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3781
SELECT cor0.col0 / 63 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + ( 61 ) + cor0.col0 + + col0 col0 FROM tab2 AS cor0
----
1661
1742
2476

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3783
SELECT col2 * ( 8 ) + col1 * CAST( - col0 AS SIGNED ) col1 FROM tab2 AS cor0
----
-1
-1039
-4394

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3783
SELECT col2 * ( 8 ) + col1 * CAST ( - col0 AS INTEGER ) col1 FROM tab2 AS cor0
----
-1
-1039
-4394

query I rowsort
SELECT ( col1 + + col2 ) AS col1 FROM tab0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 73 - col2 col0 FROM tab2
----
35
46
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col1 + - col0 col0 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-3787
SELECT + + 78 DIV ( col1 ) AS col2 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-3787
SELECT + + 78 / ( col1 ) AS col2 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT DISTINCT col0 * - 91 + + cor0.col1 FROM tab0 AS cor0
----
-2098
-3088
-8008

query I rowsort
SELECT + - col0 * col0 * + col0 + + 85 * col0 FROM tab0 AS cor0
----
-11784
-39900
-697404

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3790
SELECT + - CAST( + col1 AS SIGNED ) + col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-3790
SELECT + - CAST ( + col1 AS INTEGER ) + col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT + - 99 + - col0 FROM tab1 AS cor0
----
-102
-163
-179

query I rowsort
SELECT ALL + col0 * + col1 * - col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT - col2 + - 27 AS col0 FROM tab0 cor0
----
-109
-28
-60

query I rowsort
SELECT ALL + col2 + + col1 - col1 * + col1 * tab0.col1 FROM tab0
----
-635937
-753398
-912575

query I rowsort
SELECT DISTINCT - col2 * - col0 * + col2 - col1 FROM tab0
----
-62
26050
598345

query I rowsort
SELECT + col0 * + col0 * + 90 + + 47 * col0 FROM tab1
----
371648
579760
951

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab1, tab0, tab0 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-3798
SELECT + col2 * - col2 + col1 + col1 DIV - tab1.col0 col0 FROM tab1
----
-2898
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3798
SELECT + col2 * - col2 + col1 + col1 / - tab1.col0 col0 FROM tab1
----
-2898
-3239
-9203

query I rowsort
SELECT DISTINCT + tab1.col0 FROM tab1, tab0, tab0 AS cor0
----
3
64
80

query I rowsort
SELECT - col1 * col0 - + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT DISTINCT 25 FROM tab1, tab2, tab2 AS cor0
----
25

query I rowsort
SELECT ALL + tab0.col0 + + col0 * - col1 + - col1 FROM tab0
----
-2126
-3457
-8101

query I rowsort
SELECT ALL + col2 * tab1.col0 + + 17 FROM tab1
----
179
3665
7697

query I rowsort
SELECT ALL - 4 + + col0 + + col0 AS col1 FROM tab2
----
10
152
154

query I rowsort
SELECT ALL col1 * + col1 + col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT - col1 + + col2 * col0 + - col2 AS col1 FROM tab0 AS cor0
----
-63
673
7125

query I rowsort
SELECT DISTINCT col1 * 54 AS col2 FROM tab0 AS cor0
----
4644
4914
5238

query I rowsort
SELECT + - col0 + - 87 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-2112
-3080
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-3809
SELECT ALL + cor0.col0 + 48 * col1 DIV col0 FROM tab1 AS cor0
----
419
71
87

skipif mysql # not compatible
query I rowsort label-3809
SELECT ALL + cor0.col0 + 48 * col1 / col0 FROM tab1 AS cor0
----
419
71
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 73 + col0 col2 FROM tab0 AS cor0
----
-6254
-6554
-7046

query I rowsort
SELECT DISTINCT col0 * 9 FROM tab1 cor0
----
27
576
720

onlyif mysql # use DIV operator for integer division
query I rowsort label-3812
SELECT ALL + - col1 + - col1 DIV col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-3812
SELECT ALL + - col1 + - col1 / col1 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT + col2 * - 8 FROM tab1 AS cor0
----
-432
-456
-768

query I rowsort
SELECT ALL + + col1 * 79 AS col2 FROM tab0 AS cor0
----
6794
7189
7663

query I rowsort
SELECT - cor0.col2 * cor0.col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT + cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL - - col1 + - col0 * - cor0.col1 AS col1 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + col2 + - 9 - col1 FROM tab2 AS cor0
----
-13
-42
12

query I rowsort
SELECT ALL + - ( - cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - col1 * col2 + col2 * + col2 AS col0 FROM tab0 AS cor0
----
-1749
-738
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3821
SELECT - cor0.col1 DIV + col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3821
SELECT - cor0.col1 / + col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 7 * col1 AS col0 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT + + 54 * col0 FROM tab0 AS cor0
----
1296
1890
4806

onlyif mysql # use DIV operator for integer division
query I rowsort label-3824
SELECT - - col1 DIV col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3824
SELECT - - col1 / col0 AS col0 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3825
SELECT 5 DIV + col2 FROM tab0 AS cor0
----
0
0
5

skipif mysql # not compatible
query I rowsort label-3825
SELECT 5 / + col2 FROM tab0 AS cor0
----
0
0
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 19 + col0 col0 FROM tab1 AS cor0
----
22
83
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + col2 * cor0.col1 col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT - ( col2 ) + col2 * col2 AS col0 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT - col1 * - col0 + col0 * + col1 AS col0 FROM tab2 AS cor0
----
2686
434
9204

query I rowsort
SELECT ALL + - 0 - - col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - col1 * col0 + + cor0.col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - 56 + col2 FROM tab1 AS cor0
----
-2
1
40

query I rowsort
SELECT DISTINCT + - col1 + col1 - cor0.col0 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3834
SELECT - 27 * col0 DIV + col2 + + col2 FROM tab1 AS cor0
----
27
53
74

skipif mysql # not compatible
query I rowsort label-3834
SELECT - 27 * col0 / + col2 + + col2 FROM tab1 AS cor0
----
27
53
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-3835
SELECT ALL + 57 DIV col1 + col2 + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1560
687
865

skipif mysql # not compatible
query I rowsort label-3835
SELECT ALL + 57 / col1 + col2 + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1560
687
865

query I rowsort
SELECT + ( col0 ) + + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT col0 + - col2 * col2 AS col0 FROM tab0
----
-1065
-6635
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3838
SELECT - CAST( - 72 AS SIGNED ) * - col2 + col0 * col2 col1 FROM tab2
----
-1755
156
266

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3838
SELECT - CAST ( - 72 AS INTEGER ) * - col2 + col0 * col2 col1 FROM tab2
----
-1755
156
266

onlyif mysql # use DIV operator for integer division
query I rowsort label-3839
SELECT ( col2 ) * col1 + + tab1.col2 DIV + col1 AS col1 FROM tab1
----
1255
1406
575

skipif mysql # not compatible
query I rowsort label-3839
SELECT ( col2 ) * col1 + + tab1.col2 / + col1 AS col1 FROM tab1
----
1255
1406
575

query I rowsort
SELECT ALL + ( col1 ) + - col1 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 85 * + cor0.col1 + col2 FROM tab0 AS cor0
----
7343
7817
8246

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3842
SELECT CAST( NULL AS SIGNED ) + tab0.col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3842
SELECT CAST ( NULL AS INTEGER ) + tab0.col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 col2 FROM tab2
----
77
77
77

query I rowsort
SELECT DISTINCT + col0 * + 59 FROM tab2
----
413
4602
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 23 col2 FROM tab2 AS cor0
----
23
23
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT - col1 * + col1 - col0 FROM tab1
----
-164
-249
-679

query I rowsort
SELECT ALL - 81 * + ( - col0 ) + 52 AS col2 FROM tab2 AS cor0
----
619
6370
6451

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - + 79 AS col0 FROM tab0 AS cor0
----
-79
-79
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3851
SELECT + 71 DIV - cor0.col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-3851
SELECT + 71 / - cor0.col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 70 col1 FROM tab0
----
-70
-70
-70

query I rowsort
SELECT - + col2 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - col1 * - col2 + ( - 12 ) AS col0 FROM tab2 cor0
----
1522
634
825

query I rowsort
SELECT DISTINCT - ( - cor1.col2 ) * + cor1.col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
1444
676
729

query I rowsort
SELECT - col1 + cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT 40 AS col1 FROM tab2 cor0
----
40
40
40

query I rowsort
SELECT - + col1 * ( 94 ) AS col0 FROM tab1 AS cor0
----
-1222
-2444
-940

query I rowsort
SELECT col1 * cor0.col2 * col2 AS col1 FROM tab0 cor0
----
611884
93654
97

query I rowsort
SELECT - col2 * - 64 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT - - col2 + + col0 * + col1 AS col1 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT ALL + col2 * + col0 + + 25 AS col0 FROM tab1 AS cor0
----
187
3673
7705

query I rowsort
SELECT + cor0.col2 * col0 + + cor0.col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL - - col0 * + ( - col1 ) + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + 1 col2 FROM tab0 AS cor0
----
-23
-34
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3866
SELECT DISTINCT + cor0.col2 + + CAST( NULL AS SIGNED ) * - cor0.col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3866
SELECT DISTINCT + cor0.col2 + + CAST ( NULL AS INTEGER ) * - cor0.col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 * col1 + + 76 + - cor0.col1 * + col0 FROM tab2 AS cor0
----
-1913
-6060
-978

query I rowsort
SELECT - - col0 + 43 FROM tab1 AS cor0
----
107
123
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-3869
SELECT DISTINCT + col1 + 95 DIV - col1 AS col0 FROM tab1 cor0
----
1
23
6

skipif mysql # not compatible
query I rowsort label-3869
SELECT DISTINCT + col1 + 95 / - col1 AS col0 FROM tab1 cor0
----
1
23
6

query I rowsort
SELECT DISTINCT - col2 * col2 - - cor0.col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT col0 + - cor0.col0 * + 98 FROM tab1 AS cor0
----
-291
-6208
-7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3872
SELECT ALL + col2 * CAST( - col2 AS SIGNED ) + + col0 * - 95 - - 77 AS col2 FROM tab1 AS cor0
----
-16739
-3124
-9252

skipif mysql # not compatible
query I rowsort label-3872
SELECT ALL + col2 * CAST ( - col2 AS INTEGER ) + + col0 * - 95 - - 77 AS col2 FROM tab1 AS cor0
----
-16739
-3124
-9252

query I rowsort
SELECT DISTINCT + col0 - ( cor0.col0 + - col1 ) * - ( ( cor0.col1 ) ) FROM tab0 AS cor0
----
-5308
-5979
-93

query I rowsort
SELECT DISTINCT + 76 + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-1988
-3319
-8023

query I rowsort
SELECT DISTINCT - + 23 + - col0 FROM tab2 AS cor0
----
-101
-102
-30

query I rowsort
SELECT ALL + 31 AS col2 FROM tab1 AS cor0
----
31
31
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-3877
SELECT DISTINCT - + ( col0 ) DIV - col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3877
SELECT DISTINCT - + ( col0 ) / - col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col1 + col1 * - cor0.col1 * 87 FROM tab2 cor0
----
-25126
-302788
-83576

query I rowsort
SELECT + + 26 + 97 AS col2 FROM tab2 AS cor0
----
123
123
123

query I rowsort
SELECT DISTINCT col1 + - ( 39 ) AS col1 FROM tab0
----
47
52
58

query I rowsort
SELECT ALL - col0 * - col1 + col0 FROM tab2
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3882
SELECT col0 DIV + 99 + tab2.col1 * - col1 * 92 FROM tab2
----
-26588
-320252
-88412

skipif mysql # not compatible
query I rowsort label-3882
SELECT col0 / + 99 + tab2.col1 * - col1 * 92 FROM tab2
----
-26588
-320252
-88412

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3883
SELECT - col2 * CAST( + col1 AS SIGNED ) FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-3883
SELECT - col2 * CAST ( + col1 AS INTEGER ) FROM tab2
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3884
SELECT ALL col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3884
SELECT ALL col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3885
SELECT ALL tab0.col2 DIV col1 + col0 * - col0 * - col2 AS col0 FROM tab0
----
1225
19008
649522

skipif mysql # not compatible
query I rowsort label-3885
SELECT ALL tab0.col2 / col1 + col0 * - col0 * - col2 AS col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT + col1 + - 96 FROM tab1
----
-70
-83
-86

query I rowsort
SELECT DISTINCT + col0 * - col0 + + 87 AS col1 FROM tab1 AS cor0
----
-4009
-6313
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 - + col2 col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - - ( - col0 ) * cor0.col0 + cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
-3996
-6231
667

query I rowsort
SELECT - ( - col0 ) + 73 * + col0 AS col1 FROM tab0 AS cor0
----
1776
2590
6586

query I rowsort
SELECT + 19 * col0 - - 8 * col1 AS col2 FROM tab2 AS cor0
----
1637
1954
381

query I rowsort
SELECT ALL col0 * - cor0.col2 + 67 AS col1 FROM tab1 AS cor0
----
-3581
-7613
-95

query I rowsort
SELECT ALL + - 76 FROM tab1 cor0
----
-76
-76
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3894
SELECT - + col1 DIV + cor0.col1 + 73 DIV + 33 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3894
SELECT - + col1 / + cor0.col1 + 73 / + 33 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 32 * - col0 FROM tab2 AS cor0
----
224
2496
2528

onlyif mysql # use DIV operator for integer division
query I rowsort label-3896
SELECT col2 DIV col2 - col0 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3896
SELECT col2 / col2 - col0 FROM tab1
----
-2
-63
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT + col1 DIV + col1 + - col2 * col2 + col1 * + col2 FROM tab0
----
1750
739
97

skipif mysql # not compatible
query I rowsort label-3897
SELECT + col1 / + col1 + - col2 * col2 + col1 * + col2 FROM tab0
----
1750
739
97

query I rowsort
SELECT 34 * + ( + col1 + col0 ) AS col2 FROM tab1
----
2516
3162
986

query I rowsort
SELECT DISTINCT - tab2.col0 * - 32 AS col2 FROM tab2
----
224
2496
2528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 * col0 ) col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + 1 * col1 + col1 FROM tab1
----
20
26
52

query I rowsort
SELECT + + col1 * col0 - 74 FROM tab1 AS cor0
----
4
566
966

query I rowsort
SELECT + col0 * col2 - ( col0 ) AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT col1 * col1 + - ( col0 ) FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT ALL + ( + col2 ) * 25 AS col1 FROM tab1 AS cor0
----
1350
1425
2400

query I rowsort
SELECT DISTINCT + col1 + col1 * + ( - cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL col2 + + col2 - + col1 * col0 FROM tab2 AS cor0
----
-1267
-163
-4550

query I rowsort
SELECT ALL + col2 + + col1 * + 64 FROM tab2 cor0
----
1126
2011
3802

query I rowsort
SELECT - 50 * + col0 AS col1 FROM tab2 AS cor0
----
-350
-3900
-3950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3910
SELECT DISTINCT - col2 * col0 + + CAST( NULL AS DECIMAL ) * col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3910
SELECT DISTINCT - col2 * col0 + + CAST ( NULL AS REAL ) * col2 AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3911
SELECT ALL + 46 * col0 - cor0.col2 DIV col1 col1 FROM tab1 AS cor0
----
136
2939
3673

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3911
SELECT ALL + 46 * col0 - cor0.col2 / col1 col1 FROM tab1 AS cor0
----
136
2939
3673

query I rowsort
SELECT - - 6 * - col2 FROM tab0 cor0
----
-198
-492
-6

query I rowsort
SELECT - 95 - + tab0.col0 FROM tab0
----
-119
-130
-184

query I rowsort
SELECT DISTINCT 87 * col0 + col2 FROM tab0
----
2121
3046
7825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3915
SELECT col0 + col2 DIV col1 + 33 FROM tab0
----
122
57
68

skipif mysql # not compatible
query I rowsort label-3915
SELECT col0 + col2 / col1 + 33 FROM tab0
----
122
57
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 44 * - col1 * col2 col1 FROM tab1 cor0
----
25080
54912
61776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col0 col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT 94 * - 72 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d7190c82cefbd2c04f867eae77a8d2c4

query I rowsort
SELECT + col2 * col1 + + col0 AS col1 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL col0 + ( - col2 * + col1 ) AS col1 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT + 22 * col1 + col0 FROM tab1 AS cor0
----
284
366
575

query I rowsort
SELECT DISTINCT - - col1 + - col0 * col0 AS col1 FROM tab0 cor0
----
-1128
-490
-7830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3923
SELECT - + col0 * - CAST( NULL AS SIGNED ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3923
SELECT - + col0 * - CAST ( NULL AS INTEGER ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3925
SELECT - CAST( - col0 AS SIGNED ) AS col2 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3925
SELECT - CAST ( - col0 AS INTEGER ) AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT + 4 AS col0 FROM tab0
----
4
4
4

query I rowsort
SELECT DISTINCT 69 AS col2 FROM tab0, tab1 AS cor0
----
69

query I rowsort
SELECT ALL - 35 * col1 * col1 AS col2 FROM tab2 cor0
----
-10115
-121835
-33635

onlyif mysql # use DIV operator for integer division
query I rowsort label-3929
SELECT + CAST( 98 AS SIGNED ) DIV col1 FROM tab1 AS cor0
----
3
7
9

skipif mysql # not compatible
query I rowsort label-3929
SELECT + CAST ( 98 AS INTEGER ) / col1 FROM tab1 AS cor0
----
3
7
9

query I rowsort
SELECT - ( + col2 ) + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL 33 + + col2 FROM tab2 AS cor0
----
59
60
71

query I rowsort
SELECT DISTINCT + col1 * col0 - - col2 * + col2 AS col0 FROM tab2 AS cor0
----
2787
5278
946

query I rowsort
SELECT DISTINCT - col1 * - col2 + col2 + col1 FROM tab0 AS cor0
----
195
2957
7635

query I rowsort
SELECT ALL + 25 - col0 * col2 FROM tab1 AS cor0
----
-137
-3623
-7655

query I rowsort
SELECT ALL - - cor0.col1 * ( col0 * - 5 ) FROM tab0 AS cor0
----
-10320
-16975
-40495

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3936
SELECT ALL CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3936
SELECT ALL CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3937
SELECT DISTINCT + - 92 DIV + col0 + + col1 AS col0 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-3937
SELECT DISTINCT + - 92 / + col0 + + col1 AS col0 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT DISTINCT + - col0 * 0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - col1 + col0 AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3940
SELECT ALL + + col1 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3940
SELECT ALL + + col1 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 57 AS col1 FROM tab2, tab0 AS cor0, tab1 cor1
----
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3942
SELECT DISTINCT + + col0 DIV - col1 + - col0 * col2 * col0 FROM tab1 cor0
----
-233478
-486
-614406

skipif mysql # not compatible
query I rowsort label-3942
SELECT DISTINCT + + col0 / - col1 + - col0 * col2 * col0 FROM tab1 cor0
----
-233478
-486
-614406

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 + 29 col1 FROM tab2, tab1 AS cor0
----
47

query I rowsort
SELECT 12 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3945
SELECT col0 DIV + 96 + col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3945
SELECT col0 / + 96 + col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3946
SELECT DISTINCT - - col1 DIV - 74 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3946
SELECT DISTINCT - - col1 / - 74 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL - col0 * + ( + col1 ) + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3948
SELECT col1 + CAST( NULL AS SIGNED ) * - col1 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3948
SELECT col1 + CAST ( NULL AS INTEGER ) * - col1 * + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * 33 FROM tab0 AS cor0
----
2838
3003
3201

query I rowsort
SELECT + cor0.col2 * 64 + - col2 AS col2 FROM tab1 cor0
----
3402
3591
6048

query I rowsort
SELECT DISTINCT col0 * 45 + + col2 AS col0 FROM tab2
----
342
3536
3593

query I rowsort
SELECT - - 35 * 18 + col1 AS col0 FROM tab2 AS cor0
----
647
661
689

query I rowsort
SELECT - - col2 + + 83 FROM tab1 AS cor0
----
137
140
179

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 45 AS REAL ) FROM tab2, tab0 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT + col2 + + col1 + + 56 * col0 FROM tab1
----
248
3651
4589

query I rowsort
SELECT DISTINCT + col1 FROM tab2 AS cor0 WHERE NOT col2 * col2 + - col0 NOT BETWEEN col1 AND NULL
----

query I rowsort
SELECT + tab0.col1 AS col1 FROM tab0 WHERE col0 + col2 IN ( - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3958
SELECT DISTINCT + cor0.col0 DIV - cor0.col0 FROM tab0, tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3958
SELECT DISTINCT + cor0.col0 / - cor0.col0 FROM tab0, tab2 AS cor0
----
-1

query I rowsort
SELECT col1 + col2 - - col2 FROM tab1
----
124
134
205

query I rowsort
SELECT col1 * - col2 * + col1 AS col2 FROM tab1
----
-16224
-36504
-5700

query IIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT + - col1 + col1 + col2 * + col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + + col2 * + cor0.col2 + cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
2973
3370
9392

query I rowsort
SELECT + + col2 * col1 + col2 + + col0 FROM tab0 cor0
----
133
2895
7633

query I rowsort
SELECT col2 - - col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT col1 + - col2 + + col0 * col0 AS col1 FROM tab1 AS cor0
----
-19
4049
6317

query I rowsort
SELECT + col1 * col2 + col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + + cor0.col2 * col1 + + col0 + - col1 AS col0 FROM tab0 cor0
----
2776
35
7460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL tab1.col2 * tab1.col0 + tab1.col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT + col1 * col0 + - cor0.col0 * - col2 FROM tab2 cor0
----
406
4345
6630

query I rowsort
SELECT DISTINCT + col0 * col0 + - col1 FROM tab2 AS cor0
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 62 col0 FROM tab2 cor0
----
62

query I rowsort
SELECT + + col0 + - col1 + - 78 FROM tab1 AS cor0
----
-101
-11
-24

query I rowsort
SELECT - col2 * cor0.col2 * - col0 AS col1 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT ALL + col0 + - 58 AS col2 FROM tab2 cor0
----
-51
20
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3977
SELECT + col1 DIV + 80 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3977
SELECT + col1 / + 80 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT ALL - col1 + - 54 * 24 FROM tab2 AS cor0
----
-1313
-1327
-1355

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - ( - cor0.col1 ) + col2 col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - - cor0.col2 * ( + col1 ) FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - col0 * 69 FROM tab0 AS cor0
----
-1656
-2415
-6141

query I rowsort
SELECT - - col1 + + col1 FROM tab1 cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3983
SELECT - col2 DIV ( - col2 ) FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3983
SELECT - col2 / ( - col2 ) FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - col2 + col2 - + ( + col2 ) * - col2 * - col2 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT DISTINCT + col2 + - 46 FROM tab0 AS cor0
----
-13
-45
36

query I rowsort
SELECT DISTINCT - col0 + + col0 * - col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT + + cor0.col0 * + col1 * col2 + col2 AS col1 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT ALL - col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - + col2 * - col1 + cor0.col0 AS col2 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT ALL cor0.col0 + + 91 * col0 * + col0 AS col0 FROM tab0 AS cor0
----
111510
52440
720900

query I rowsort
SELECT ALL + col0 * col2 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT - col1 + + col0 * + tab2.col1 FROM tab2
----
1326
186
4543

query I rowsort
SELECT + col0 * - col0 AS col1 FROM tab0 WHERE ( + col0 ) = NULL
----

query I rowsort
SELECT DISTINCT + col1 - - tab2.col1 AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT - col1 AS col2 FROM tab2 WHERE - col0 NOT IN ( + col0 / col0 )
----
-17
-31
-59

query I rowsort
SELECT ALL - col2 - - col1 * - col2 FROM tab2
----
-1560
-684
-864

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT BETWEEN col2 + col2 AND ( NULL )
----

query I rowsort
SELECT - col0 * col2 + + tab1.col2 AS col1 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT ALL tab0.col1 + + tab0.col0 * col0 * - col1 AS col1 FROM tab0
----
-118728
-49450
-720720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 - - col0 col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT + - cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + - col1 * + col0 + col1 + - col2 * - col1 FROM tab0 AS cor0
----
-3201
-546
860

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 + 20 col1 FROM tab2 AS cor0
----
-169
-2008
-2982

query I rowsort
SELECT - col1 * col2 + col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + - 47 + col0 FROM tab0 AS cor0
----
-12
-23
42

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL BETWEEN NULL AND ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4007
SELECT col2 + - col0 DIV col2 + - col2 AS col2 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-4007
SELECT col2 + - col0 / col2 + - col2 AS col2 FROM tab0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col0 + - col2 col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT tab0.col2 + tab0.col0 * col1 * + col2 + + col2 AS col2 FROM tab0
----
3397
664282
68178

query I rowsort
SELECT DISTINCT + col2 - - col2 AS col1 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4011
SELECT ALL + col2 * tab0.col1 - tab0.col2 DIV col2 FROM tab0
----
2837
7461
96

skipif mysql # not compatible
query I rowsort label-4011
SELECT ALL + col2 * tab0.col1 - tab0.col2 / col2 FROM tab0
----
2837
7461
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 col2 FROM tab2 WHERE NOT + col0 * col0 <= NULL
----

query I rowsort
SELECT DISTINCT col2 + - col1 AS col0 FROM tab0 WHERE NOT NULL > NULL
----

query I rowsort
SELECT ALL - col2 * - col0 - - col1 FROM tab0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 + + 75 col2 FROM tab0
----
108
157
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 - col1 col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + - col0 + - 83 * col1 AS col1 FROM tab2 AS cor0
----
-1490
-2580
-4975

onlyif mysql # use DIV operator for integer division
query I rowsort label-4018
SELECT ALL + + col0 + ( + col1 + cor0.col1 ) * col2 DIV 32 AS col0 FROM tab0 cor0
----
201
41
555

skipif mysql # not compatible
query I rowsort label-4018
SELECT ALL + + col0 + ( + col1 + cor0.col1 ) * col2 / 32 AS col0 FROM tab0 cor0
----
201
41
555

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + 50 + col1 col2 FROM tab2 AS cor0
----
146
187
88

query I rowsort
SELECT DISTINCT - + col0 + col2 AS col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT 53 * - 37 AS col0 FROM tab0 AS cor0
----
-1961
-1961
-1961

query I rowsort
SELECT + 27 + col0 FROM tab0 AS cor0
----
116
51
62

query I rowsort
SELECT ( - 79 ) FROM tab1 AS cor0
----
-79
-79
-79

query I rowsort
SELECT DISTINCT - col1 + 75 AS col0 FROM tab1 AS cor0
----
49
62
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4025
SELECT ALL + CAST( NULL AS DECIMAL ) / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4025
SELECT ALL + CAST ( NULL AS REAL ) / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( + 35 ) * + col1 AS col2 FROM tab1 AS cor0
----
-350
-455
-910

query I rowsort
SELECT ALL 56 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT ALL - - col1 + col2 AS col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT - cor0.col0 + + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + col0 * - col1 * cor0.col1 + + 9 + - col0 FROM tab0 AS cor0
----
-177519
-329341
-737089

query I rowsort
SELECT + 15 * col2 + col2 * cor0.col0 FROM tab1 AS cor0
----
4503
9120
972

query I rowsort
SELECT ALL - 7 * col0 + + 82 AS col2 FROM tab0 cor0
----
-163
-541
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4033
SELECT + col2 DIV - cor0.col2 + + col0 + + col1 * cor0.col0 * + col2 FROM tab1 AS cor0
----
36543
4214
99919

skipif mysql # not compatible
query I rowsort label-4033
SELECT + col2 / - cor0.col2 + + col0 + + col1 * cor0.col0 * + col2 FROM tab1 AS cor0
----
36543
4214
99919

query I rowsort
SELECT - 78 * col1 + - ( 96 ) * col0 AS col2 FROM tab2 AS cor0
----
-12090
-3090
-8910

query I rowsort
SELECT ALL + col0 * - cor0.col0 + + 13 AS col1 FROM tab1 AS cor0
----
-4083
-6387
4

query I rowsort
SELECT - 23 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1225
1381
547

query I rowsort
SELECT DISTINCT - col1 + 85 - col0 * col0 AS col0 FROM tab2
----
-6058
-6173
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4038
SELECT ALL CAST( + col1 AS SIGNED ) - col0 FROM tab2
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-4038
SELECT ALL CAST ( + col1 AS INTEGER ) - col0 FROM tab2
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4039
SELECT col2 - + 30 * tab2.col2 * CAST( NULL AS SIGNED ) col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4039
SELECT col2 - + 30 * tab2.col2 * CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + 66 FROM tab2
----
-1716
-1782
-2508

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4041
SELECT + CAST( NULL AS SIGNED ) * - col0 * + col0 + col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4041
SELECT + CAST ( NULL AS INTEGER ) * - col0 * + col0 + col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col2 + - col0 + - 76 FROM tab2 AS cor0
----
-110
-180
-193

query I rowsort
SELECT ALL - + col1 - - col0 * - col0 FROM tab2 AS cor0
----
-6143
-6258
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4044
SELECT DISTINCT + + col1 DIV col0 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-4044
SELECT DISTINCT + + col1 / col0 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT - ( + col2 ) - ( - col2 ) * col1 * + col1 AS col1 FROM tab2 AS cor0
----
10944
25920
90480

query I rowsort
SELECT + col1 * col2 * - cor0.col0 AS col2 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT col1 * ( col2 ) + col1 * - ( + 85 ) FROM tab0 AS cor0
----
-273
-4472
-8148

query I rowsort
SELECT - - col2 * + col1 * ( col2 ) + cor0.col2 FROM tab1 AS cor0
----
119904
32547
75870

query I rowsort
SELECT + col1 * - col1 + + col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT + - col1 * - col2 + 88 FROM tab2 AS cor0
----
1622
734
925

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4051
SELECT + cor0.col2 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4051
SELECT + cor0.col2 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + - ( col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + 62 + cor0.col0 FROM tab2 AS cor0
----
103
114
42

query I rowsort
SELECT + ( + col1 ) * - 67 * col1 AS col2 FROM tab2
----
-19363
-233227
-64387

onlyif mysql # use DIV operator for integer division
query I rowsort label-4055
SELECT ALL - col1 DIV tab1.col0 + + 58 FROM tab1
----
50
58
58

skipif mysql # not compatible
query I rowsort label-4055
SELECT ALL - col1 / tab1.col0 + + 58 FROM tab1
----
50
58
58

query I rowsort
SELECT ALL col1 + - tab2.col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT 1 AS col0 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT - col2 + + ( col0 ) AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT col0 + 23 FROM tab0 AS cor0
----
112
47
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-4060
SELECT DISTINCT 40 DIV + ( col0 ) AS col2 FROM tab2
----
0
5

skipif mysql # not compatible
query I rowsort label-4060
SELECT DISTINCT 40 / + ( col0 ) AS col2 FROM tab2
----
0
5

query I rowsort
SELECT + + col1 * col0 + - col2 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + col1 * col0 + col0 * 35 AS col1 FROM tab1 AS cor0
----
183
2880
3840

query I rowsort
SELECT ALL - ( ( + col2 ) ) FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4064
SELECT + CAST( NULL AS SIGNED ) * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4064
SELECT + CAST ( NULL AS INTEGER ) * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * - col0 + - col1 AS col0 FROM tab2 AS cor0
----
-6143
-6258
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4066
SELECT ALL CAST( NULL AS SIGNED ) * col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4066
SELECT ALL CAST ( NULL AS INTEGER ) * col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - cor0.col1 * col1 * col0 AS col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL + col0 + - col2 * - col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT - - col2 * - col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4070
SELECT DISTINCT 8 DIV 41 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-4070
SELECT DISTINCT 8 / 41 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
0

query I rowsort
SELECT - - col0 + - col0 + col0 AS col0 FROM tab2 cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4072
SELECT - col2 * col1 DIV col1 FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-4072
SELECT - col2 * col1 / col1 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 4 * - cor0.col2 col1 FROM tab2 AS cor0
----
104
108
152

query I rowsort
SELECT - - 0 + cor0.col1 * + cor0.col1 * - col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT DISTINCT + ( 39 ) + - col2 FROM tab2 AS cor0
----
1
12
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-4076
SELECT - col2 * + col2 * - cor0.col0 + CAST( col1 AS SIGNED ) DIV - cor0.col0 AS col0 FROM tab2 cor0
----
114076
5099
52728

skipif mysql # not compatible
query I rowsort label-4076
SELECT - col2 * + col2 * - cor0.col0 + CAST ( col1 AS INTEGER ) / - cor0.col0 AS col0 FROM tab2 cor0
----
114076
5099
52728

query I rowsort
SELECT DISTINCT - 73 + cor0.col0 * col1 AS col1 FROM tab0 AS cor0
----
1991
3322
8026

onlyif mysql # use DIV operator for integer division
query I rowsort label-4078
SELECT col2 * col1 DIV - col2 + cor0.col2 DIV - col1 FROM tab1 AS cor0
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-4078
SELECT col2 * col1 / - col2 + cor0.col2 / - col1 FROM tab1 AS cor0
----
-15
-20
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-4079
SELECT ALL + 75 - + 27 DIV col2 FROM tab1 AS cor0
----
75
75
75

skipif mysql # not compatible
query I rowsort label-4079
SELECT ALL + 75 - + 27 / col2 FROM tab1 AS cor0
----
75
75
75

query I rowsort
SELECT DISTINCT 83 * - col0 AS col2 FROM tab1 AS cor0
----
-249
-5312
-6640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4081
SELECT - col1 * - col1 * col1 + + CAST( NULL AS SIGNED ) * + 84 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4081
SELECT - col1 * - col1 * col1 + + CAST ( NULL AS INTEGER ) * + 84 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4082
SELECT ALL + CAST( - cor0.col0 AS SIGNED ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-4082
SELECT ALL + CAST ( - cor0.col0 AS INTEGER ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + col1 - + col0 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL col0 + 88 - cor0.col0 AS col2 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT - - 5 + + col2 * + col0 FROM tab1 AS cor0
----
167
3653
7685

query I rowsort
SELECT DISTINCT - - 31 AS col2 FROM tab1 cor0
----
31

query I rowsort
SELECT ALL - col1 + col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 * tab1.col1 + - col0 * col0 AS col0 FROM tab1
----
-3456
-5360
69

query I rowsort
SELECT col2 * - col2 + + col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL - col1 + + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL 78 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

onlyif mysql # use DIV operator for integer division
query I rowsort label-4092
SELECT - col0 * - col1 DIV + col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4092
SELECT - col0 * - col1 / + col1 FROM tab0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4093
SELECT + col1 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4093
SELECT + col1 * - CAST ( NULL AS REAL ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 28 FROM tab2, tab2 AS cor0
----
28

query I rowsort
SELECT DISTINCT col2 * - col2 - col1 * - col1 AS col1 FROM tab1
----
-2240
-3149
-9047

query I rowsort
SELECT - col0 - 98 AS col2 FROM tab0
----
-122
-133
-187

query I rowsort
SELECT - col0 + col0 + tab1.col0 FROM tab1
----
3
64
80

query I rowsort
SELECT + col1 * 53 * 31 + tab2.col0 * + col2 - 47 FROM tab2
----
30886
51075
98918

query I rowsort
SELECT DISTINCT - col0 - - ( col1 ) FROM tab1
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-4100
SELECT col2 DIV + 69 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4100
SELECT col2 / + 69 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL 59 AS col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT ALL col2 * ( + col2 ) FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT 20 AS col0 FROM tab2 AS cor0
----
20

query I rowsort
SELECT DISTINCT - col2 * + ( col0 * + col2 ) + + col2 AS col2 FROM tab1 cor0
----
-207879
-737184
-8694

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 cor2
----
972 values hashing to 635619591835474e6aa6acdff4ab166c

query I rowsort
SELECT - - cor0.col2 + col0 FROM tab2 cor0
----
104
117
34

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to 624c4b72c6f348b0f702418bfe39bd29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4108
SELECT ALL + col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4108
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + - col2 * col0 * 39 AS col2 FROM tab2
----
-117040
-7344
-79066

onlyif mysql # use DIV operator for integer division
query I rowsort label-4110
SELECT DISTINCT + CAST( - col0 AS SIGNED ) DIV col1 + col0 FROM tab2
----
7
75
77

skipif mysql # not compatible
query I rowsort label-4110
SELECT DISTINCT + CAST ( - col0 AS INTEGER ) / col1 + col0 FROM tab2
----
7
75
77

query I rowsort
SELECT ALL - col1 + 34 FROM tab0
----
-52
-57
-63

query I rowsort
SELECT ALL ( col2 ) * - col2 * - 33 + - col0 FROM tab2
----
22230
24050
47573

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( col0 ) col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - - ( - cor0.col1 ) * - col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + - ( ( + col0 ) ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + col1 + col2 * - col1 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL + 34 * 76 * col0 + + col2 * + 65 FROM tab0
----
235306
64161
90505

query I rowsort
SELECT ( + col2 ) + + col0 * + col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + cor0.col0 + - col0 * + col2 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - col2 + col1 * col0 AS col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT ALL + col0 * cor0.col2 + + ( + 37 ) FROM tab1 AS cor0
----
199
3685
7717

query I rowsort
SELECT DISTINCT - 5 + - col1 AS col2 FROM tab0 AS cor0
----
-102
-91
-96

query I rowsort
SELECT ALL + 6 * col2 FROM tab1
----
324
342
576

query I rowsort
SELECT DISTINCT - col0 + col0 * 67 AS col2 FROM tab0 AS cor0
----
1584
2310
5874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - 90 * + cor0.col2 col0 FROM tab1 AS cor0
----
14580
328320
691200

query I rowsort
SELECT + col0 * col0 * - col2 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT - col0 * + col1 * + 74 AS col0 FROM tab2 AS cor0
----
-16058
-340548
-99382

query I rowsort
SELECT DISTINCT + - col2 * - 79 * + col2 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
114114
53430
57618

query I rowsort
SELECT DISTINCT col1 * - ( ( + col1 ) * + cor0.col0 ) FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT - col2 + - 28 AS col0 FROM tab2 AS cor0
----
-54
-55
-66

query I rowsort
SELECT ALL + col2 + + 96 * cor0.col0 AS col0 FROM tab2 AS cor0
----
699
7514
7622

onlyif mysql # use DIV operator for integer division
query I rowsort label-4132
SELECT - cor0.col2 DIV 89 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4132
SELECT - cor0.col2 / 89 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + tab1.col1 + - col1 * col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col0 * ( col1 ) FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + ( - ( - tab0.col2 ) ) * ( + 10 ) + - col1 AS col0 FROM tab0
----
-87
244
729

query I rowsort
SELECT 5 AS col1 FROM tab0, tab1, tab0 cor0, tab0 AS cor1
----
81 values hashing to 0da436460d6fcea5a1eb4b1d2219d7c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 12 * col0 col2 FROM tab1
----
33
704
880

query I rowsort
SELECT ALL col0 * col2 + col0 AS col1 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL + 97 * col0 + col2 AS col2 FROM tab1
----
345
6265
7856

query I rowsort
SELECT ( - ( + col1 ) * + 82 ) + ( - col0 ) AS col0 FROM tab1
----
-1146
-2135
-884

query I rowsort
SELECT 49 + + col1 FROM tab2 AS cor0
----
108
66
80

query I rowsort
SELECT ALL ( - col2 ) + + col2 * col0 AS col1 FROM tab1 AS cor0
----
108
3591
7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4143
SELECT - - CAST( ( - col2 ) AS SIGNED ) + + col1 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-4143
SELECT - - CAST ( ( - col2 ) AS INTEGER ) + + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - col1 * 50 + col1 FROM tab0 AS cor0
----
-4214
-4459
-4753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4145
SELECT - CAST( + col0 AS SIGNED ) * - cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-4145
SELECT - CAST ( + col0 AS INTEGER ) * - cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4146
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col1 col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4146
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col1 col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 29 col0 FROM tab1
----
-29

query I rowsort
SELECT DISTINCT + 8 * col1 FROM tab1 AS cor0
----
104
208
80

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
3
64
80

query I rowsort
SELECT - cor0.col2 + col2 * col0 AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT - + col0 + - col1 * cor0.col1 FROM tab1 cor0
----
-164
-249
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + 20 * + col0 AS col1 FROM tab1 AS cor0
----
1280
1600
60

query I rowsort
SELECT DISTINCT - + 53 FROM tab0 AS cor0
----
-53

query I rowsort
SELECT 55 * col2 * + 88 FROM tab0 cor0
----
159720
396880
4840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4156
SELECT ALL col1 + ( + col0 ) DIV col1 col2 FROM tab1
----
16
19
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4156
SELECT ALL col1 + ( + col0 ) / col1 col2 FROM tab1
----
16
19
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4157
SELECT ALL CAST( NULL AS SIGNED ) + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4157
SELECT ALL CAST ( NULL AS INTEGER ) + col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col2 + - cor0.col1 FROM tab2 cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4159
SELECT + - col1 - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4159
SELECT + - col1 - col2 / col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + - col2 * 66 AS col0 FROM tab2 AS cor0
----
-1716
-1782
-2508

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4161
SELECT DISTINCT cor0.col2 + CAST( NULL AS SIGNED ) + + col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4161
SELECT DISTINCT cor0.col2 + CAST ( NULL AS INTEGER ) + + col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT col1 * col2 + col2 * + col1 * 32 + + col1 * col1 * + CAST ( + ( col1 ) AS REAL ) FROM tab2
----
256001
26231
57412

query I rowsort
SELECT DISTINCT col0 + - 32 + tab0.col0 FROM tab0
----
146
16
38

query I rowsort
SELECT DISTINCT tab1.col1 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
10
13
26

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 DISTINCT + col0 + - ( + 75 ) col1 FROM tab1 AS cor0
----
-11
-72
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4167
SELECT ALL - cor0.col2 + - col1 DIV col1 FROM tab0 cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-4167
SELECT ALL - cor0.col2 + - col1 / col1 FROM tab0 cor0
----
-2
-34
-83

query I rowsort
SELECT col0 * + col1 + + col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT - col0 + - col2 * - col0 AS col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT + + col1 * - col0 + - 92 * col2 AS col0 FROM tab1 AS cor0
----
-5046
-5884
-9872

query I rowsort
SELECT - col0 * - col1 - - col2 AS col1 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT ALL - cor0.col2 + + col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col0 - col1 * col2 * col2 FROM tab2 AS cor0
----
-22606
-24627
-39962

query I rowsort
SELECT - col1 * - cor0.col2 * - col2 + + cor0.col0 * 36 AS col0 FROM tab1 AS cor0
----
-116928
-30186
-75708

query I rowsort
SELECT ALL - cor0.col0 * - col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL col2 + ( - tab0.col1 ) FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL - cor1.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT + col0 * ( col0 ) + - col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-140
3239
4056

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) * col1 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + ( 83 ) * + col0 + col2 * + col0 FROM tab1 AS cor0
----
14320
411
8960

query I rowsort
SELECT DISTINCT - 43 + ( + cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-12
-26
16

query I rowsort
SELECT - + 98 + - col2 FROM tab0 AS cor0
----
-131
-180
-99

query I rowsort
SELECT DISTINCT col0 * ( + col1 ) FROM tab1
----
1040
640
78

query I rowsort
SELECT ( cor0.col0 ) - - col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 30 - - cor0.col2 AS col2 FROM tab2 AS cor0
----
56
57
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4186
SELECT col2 * + cor0.col2 + + CAST( - col1 * col1 AS SIGNED ) FROM tab0 AS cor0
----
-1557
-6307
-9408

skipif mysql # not compatible
query I rowsort label-4186
SELECT col2 * + cor0.col2 + + CAST ( - col1 * col1 AS INTEGER ) FROM tab0 AS cor0
----
-1557
-6307
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + cor0.col0 + col0 col1 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4188
SELECT ALL ( col0 ) * + CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4188
SELECT ALL ( col0 ) * + CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 91 col1 FROM tab1, tab0 AS cor0
----
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-4190
SELECT 48 DIV cor0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

skipif mysql # not compatible
query I rowsort label-4190
SELECT 48 / cor0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

query I rowsort
SELECT ALL + col1 * + cor0.col0 + - col0 FROM tab2 AS cor0
----
1264
210
4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col0 col1 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + 39 + col0 FROM tab1 AS cor0
----
103
119
42

query I rowsort
SELECT ALL + col0 + col0 * col1 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4195
SELECT - col2 * - cor0.col1 * - col0 + + col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4195
SELECT - col2 * - cor0.col1 * - col0 + + col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + cor0.col0 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT col1 * - 68 * - col0 + col0 + ( cor0.col2 ) FROM tab1 AS cor0
----
43641
5361
70896

query I rowsort
SELECT DISTINCT + col1 * + col0 * - col2 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - col1 + + col2 * 8 FROM tab1 AS cor0
----
406
446
755

query I rowsort
SELECT - - cor0.col1 + - ( - col0 ) * cor0.col2 FROM tab0 AS cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 64 * + tab1.col0 col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to c95766286c2b0d3f89f84b680f6247d6

query I rowsort
SELECT + ( + ( col0 ) ) * cor0.col0 + ( col2 ) AS col1 FROM tab2 AS cor0
----
6110
6279
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 86 + col2 col0 FROM tab0 AS cor0
----
-4
-53
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col0 * - col1 col0 FROM tab2 cor0
----
106097
1519
358956

query I rowsort
SELECT 24 * cor1.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to bb25ca4074ccb1223fe58165a6eeecff

query I rowsort
SELECT col0 + + cor0.col0 * + col2 AS col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - 80 AS col0 FROM tab1
----
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 10 col1 FROM tab1
----
10
10
10

skipif mysql # not compatible
query I rowsort
SELECT - ( col1 ) * CAST ( - col2 AS REAL ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4210
SELECT - - cor0.col0 + col1 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-4210
SELECT - - cor0.col0 + col1 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col0 * col2 col1 FROM tab0 cor0
----
1225
19008
649522

query I rowsort
SELECT - cor0.col2 + - col1 * col2 * + 89 FROM tab1 AS cor0
----
-111168
-125010
-50787

onlyif mysql # use DIV operator for integer division
query I rowsort label-4213
SELECT ALL + - cor0.col1 + + col1 DIV - ( 75 ) FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-4213
SELECT ALL + - cor0.col1 + + col1 / - ( 75 ) FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT - + 51 * + col2 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT ( + col0 ) * col0 - - col2 FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL ( - 88 ) FROM tab0
----
-88
-88
-88

query I rowsort
SELECT DISTINCT + 36 * + col0 FROM tab0 AS cor0
----
1260
3204
864

query I rowsort
SELECT + 67 FROM tab2 cor0
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-4219
SELECT DISTINCT cor0.col1 * - col2 - 61 DIV - 54 col2 FROM tab2 AS cor0
----
-1533
-645
-836

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4219
SELECT DISTINCT cor0.col1 * - col2 - 61 / - 54 col2 FROM tab2 AS cor0
----
-1533
-645
-836

query I rowsort
SELECT DISTINCT - 5 * col2 + + col2 FROM tab0 AS cor0
----
-132
-328
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4221
SELECT ALL - col2 * - col0 + ( + col2 ) DIV + col1 AS col1 FROM tab2 AS cor0
----
189
2028
3004

skipif mysql # not compatible
query I rowsort label-4221
SELECT ALL - col2 * - col0 + ( + col2 ) / + col1 AS col1 FROM tab2 AS cor0
----
189
2028
3004

query I rowsort
SELECT ALL - col1 * col2 - - 7 AS col2 FROM tab0 AS cor0
----
-2831
-7455
-90

query I rowsort
SELECT ALL + 34 + + cor0.col1 FROM tab2 AS cor0
----
51
65
93

query I rowsort
SELECT DISTINCT 31 + + col0 AS col0 FROM tab1
----
111
34
95

query I rowsort
SELECT + 21 + - col0 FROM tab0
----
-14
-3
-68

query I rowsort
SELECT col2 * col1 - ( 74 + - col0 ) AS col0 FROM tab2
----
1538
651
770

query I rowsort
SELECT + col0 + + tab2.col1 AS col0 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4228
SELECT 80 + col2 * col2 DIV col2 FROM tab0
----
113
162
81

skipif mysql # not compatible
query I rowsort label-4228
SELECT 80 + col2 * col2 / col2 FROM tab0
----
113
162
81

query I rowsort
SELECT DISTINCT + 70 AS col2 FROM tab0, tab2, tab1 AS cor0
----
70

query I rowsort
SELECT DISTINCT + tab0.col1 * 57 FROM tab0
----
4902
5187
5529

query I rowsort
SELECT 53 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT col0 * 21 AS col0 FROM tab2
----
147
1638
1659

query I rowsort
SELECT + col0 * 62 * + 75 AS col1 FROM tab2
----
32550
362700
367350

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( - col2 ) col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - col1 * 39 AS col0 FROM tab0 AS cor0
----
-3354
-3549
-3783

query I rowsort
SELECT ALL - col2 + - col0 * col0 AS col2 FROM tab1
----
-4153
-63
-6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 * + CAST ( + col1 AS REAL ) + + col2 col0 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT ALL 41 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL col1 + + 5 AS col2 FROM tab0
----
102
91
96

query I rowsort
SELECT ALL + 90 * - tab1.col1 AS col1 FROM tab1
----
-1170
-2340
-900

query I rowsort
SELECT 47 + - col0 AS col0 FROM tab1
----
-17
-33
44

query I rowsort
SELECT ALL - 40 * + 44 FROM tab1 AS cor0
----
-1760
-1760
-1760

query I rowsort
SELECT DISTINCT - ( - col0 ) * col2 + col2 * col1 FROM tab2 AS cor0
----
1026
3562
3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-4244
SELECT col2 DIV - 12 AS col1 FROM tab1 cor0
----
-4
-4
-8

skipif mysql # not compatible
query I rowsort label-4244
SELECT col2 / - 12 AS col1 FROM tab1 cor0
----
-4
-4
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4245
SELECT cor0.col0 + col1 DIV col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-4245
SELECT cor0.col0 + col1 / col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT ALL + 88 AS col2 FROM tab1 cor0
----
88
88
88

query I rowsort
SELECT DISTINCT - col0 * - ( + col2 ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT cor0.col1 * 9 + + col0 FROM tab2 AS cor0
----
232
286
609

onlyif mysql # use DIV operator for integer division
query I rowsort label-4249
SELECT - col2 + col2 DIV - col1 FROM tab1 AS cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-4249
SELECT - col2 + col2 / - col1 FROM tab1 AS cor0
----
-103
-56
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4250
SELECT + ( + col0 ) DIV cor0.col0 + 84 FROM tab0 AS cor0
----
85
85
85

skipif mysql # not compatible
query I rowsort label-4250
SELECT + ( + col0 ) / cor0.col0 + 84 FROM tab0 AS cor0
----
85
85
85

query I rowsort
SELECT + col2 * col2 * col2 AS col0 FROM tab0 cor0
----
1
35937
551368

query I rowsort
SELECT + 87 + - 80 AS col0 FROM tab2 AS cor0
----
7
7
7

query I rowsort
SELECT col0 * + col0 + - col2 * 33 * col2 FROM tab1 AS cor0
----
-103121
-297728
-96219

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4254
SELECT + col2 + CAST( NULL AS SIGNED ) + + col1 * tab0.col0 * - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4254
SELECT + col2 + CAST ( NULL AS INTEGER ) + + col1 * tab0.col0 * - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 19 * + 69 + + col0 col2 FROM tab0
----
-1222
-1276
-1287

query I rowsort
SELECT + col0 + + col2 + - tab0.col1 FROM tab0
----
-29
-61
80

query I rowsort
SELECT DISTINCT + ( 52 * + col2 ) FROM tab0
----
1716
4264
52

query I rowsort
SELECT DISTINCT ( 63 ) FROM tab2
----
63

query I rowsort
SELECT + 87 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT DISTINCT + ( + 74 ) FROM tab1
----
74

query I rowsort
SELECT ALL - - 7 * col2 + - col1 FROM tab0 AS cor0
----
-90
145
483

query I rowsort
SELECT DISTINCT + - ( col1 ) * col0 + + col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

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 + 47 * col2 col0 FROM tab2 AS cor0
----
1222
1269
1786

query I rowsort
SELECT ALL + ( + col0 ) + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0, tab2 AS cor1, tab2 cor2
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4267
SELECT - + 0 + + col2 * col0 DIV + col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4267
SELECT - + 0 + + col2 * col0 / + col0 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 col0 FROM tab2
----
72
72
72

query I rowsort
SELECT ( 95 ) * - col2 AS col1 FROM tab2
----
-2470
-2565
-3610

query I rowsort
SELECT - col0 * + 0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - tab0.col1 * + tab0.col0 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 09a48fec24dd5ded01e53ec00cd6a7a1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4272
SELECT 72 + col1 DIV + ( + col0 ) AS col2 FROM tab2
----
72
72
76

skipif mysql # not compatible
query I rowsort label-4272
SELECT 72 + col1 / + ( + col0 ) AS col2 FROM tab2
----
72
72
76

query I rowsort
SELECT DISTINCT + 7 * col1 FROM tab2 cor0
----
119
217
413

query I rowsort
SELECT ALL col1 * col2 + - 68 AS col1 FROM tab2 AS cor0
----
1466
578
769

onlyif mysql # use DIV operator for integer division
query I rowsort label-4275
SELECT ALL + 8 DIV col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4275
SELECT ALL + 8 / col0 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4276
SELECT DISTINCT col0 * col1 * CAST( col1 AS SIGNED ) AS col2 FROM tab0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-4276
SELECT DISTINCT col0 * col1 * CAST ( col1 AS INTEGER ) AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + + col1 + + 25 FROM tab2 cor0
----
42
56
84

query I rowsort
SELECT ALL - cor0.col0 * - 35 FROM tab0 AS cor0
----
1225
3115
840

query I rowsort
SELECT DISTINCT col1 + 0 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - col0 * 87 + + ( - col1 ) FROM tab2 cor0
----
-640
-6845
-6890

query I rowsort
SELECT ALL - - col0 * col2 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + + col0 * + ( cor0.col2 ) * - col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - - col1 * + 67 * - col0 AS col2 FROM tab1 AS cor0
----
-42880
-5226
-69680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4284
SELECT DISTINCT col1 DIV - CAST( ( col0 ) AS SIGNED ) FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-4284
SELECT DISTINCT col1 / - CAST ( ( col0 ) AS INTEGER ) FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT + + col0 + 86 AS col1 FROM tab1 cor0
----
150
166
89

query I rowsort
SELECT col0 * - col0 * col0 FROM tab2 AS cor0
----
-343
-474552
-493039

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 3 col1 FROM tab1, tab0 cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT DISTINCT - ( - 99 ) * - tab0.col0 AS col1 FROM tab0, tab0 AS cor0
----
-2376
-3465
-8811

onlyif mysql # use DIV operator for integer division
query I rowsort label-4289
SELECT ALL 62 DIV 92 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-4289
SELECT ALL 62 / 92 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - ( col2 ) * - col2 + - col1 col2 FROM tab2 AS cor0
----
17517
19652
54855

query I rowsort
SELECT DISTINCT - col0 * - col1 - col1 AS col1 FROM tab2
----
1326
186
4543

query I rowsort
SELECT - - col0 + 86 * col0 + - col0 * 53 FROM tab0 cor0
----
1190
3026
816

query I rowsort
SELECT DISTINCT 17 AS col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4294
SELECT + + 43 DIV 35 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4294
SELECT + + 43 / 35 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4295
SELECT DISTINCT - CAST( - col1 AS SIGNED ) + col2 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-4295
SELECT DISTINCT - CAST ( - col1 AS INTEGER ) + col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4296
SELECT + 75 + - col0 DIV col2 FROM tab1 AS cor0
----
74
75
75

skipif mysql # not compatible
query I rowsort label-4296
SELECT + 75 + - col0 / col2 FROM tab1 AS cor0
----
74
75
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4297
SELECT + col1 + cor0.col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4297
SELECT + col1 + cor0.col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + col1 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - + 51 * - col1 FROM tab1 AS cor0
----
1326
510
663

onlyif mysql # use DIV operator for integer division
query I rowsort label-4300
SELECT - col2 * - col1 * - 76 + + col0 * col1 DIV + ( col1 + col1 ) AS col1 FROM tab1 AS cor0
----
-106703
-43288
-94808

skipif mysql # not compatible
query I rowsort label-4300
SELECT - col2 * - col1 * - 76 + + col0 * col1 / + ( col1 + col1 ) AS col1 FROM tab1 AS cor0
----
-106703
-43288
-94808

onlyif mysql # use DIV operator for integer division
query I rowsort label-4301
SELECT + col2 DIV col0 + col0 AS col0 FROM tab2 cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-4301
SELECT + col2 / col0 + col0 AS col0 FROM tab2 cor0
----
10
78
79

query I rowsort
SELECT + 86 + - cor0.col0 * - ( cor0.col0 ) FROM tab0 AS cor0
----
1311
662
8007

query I rowsort
SELECT ALL - 54 * + col0 FROM tab1
----
-162
-3456
-4320

query I rowsort
SELECT ( + 80 ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT DISTINCT + col2 * col0 + cor0.col2 * - col0 * col2 AS col2 FROM tab2 AS cor0
----
-111074
-4914
-50700

query I rowsort
SELECT ALL + col1 + - cor0.col0 + col0 * - col1 FROM tab1 AS cor0
----
-1107
-55
-694

query I rowsort
SELECT ALL + col2 - + col0 AS col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - + col1 * - cor0.col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + col1 * col0 * + col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL col0 * + col2 * col0 AS col0 FROM tab2 AS cor0
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * + col0 col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col2 * - col0 + + col1 * - col0 AS col2 FROM tab1
----
-240
-4288
-8720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col0 col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT col1 * col0 + + col1 * col2 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT DISTINCT 55 AS col2 FROM tab2
----
55

query I rowsort
SELECT - tab2.col0 + + col1 * + col2 * - col1 FROM tab2
----
-11061
-25954
-90584

query I rowsort
SELECT + ( - col1 + - col1 ) * - col0 AS col2 FROM tab1
----
1280
156
2080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 * - tab0.col0 col1 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-4319
SELECT col2 DIV tab0.col2 + + col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4319
SELECT col2 / tab0.col2 + + col1 FROM tab0
----
87
92
98

query I rowsort
SELECT ALL + - col0 + col2 * - col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT + col1 + col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT col1 + col1 * tab0.col1 * - col1 FROM tab0
----
-635970
-753480
-912576

query I rowsort
SELECT + col2 * col0 - col2 FROM tab1
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - - col2 col1 FROM tab1
----
121
176
57

query I rowsort
SELECT col1 * + col0 * tab0.col2 + - col0 * col1 AS col2 FROM tab0 WHERE NULL <> col0
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT - col0 * + col2 * col0 IN ( + col1 + + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + col2 * col0 * - col0 col2 FROM tab2
----
-1134
-156156
-234156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + - col1 col1 FROM tab0
----
-1322
-662
-8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-4329
SELECT ALL - col2 * + col2 + + col2 DIV - tab0.col1 AS col0 FROM tab0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-4329
SELECT ALL - col2 * + col2 + + col2 / - tab0.col1 AS col0 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - + 75 * - col2 * ( col0 ) FROM tab1 AS cor0
----
12150
273600
576000

query I rowsort
SELECT - - cor2.col0 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2, tab0 AS cor2
----
243 values hashing to ee8b23a58dda2d92e14ed437e06ed8d2

query I rowsort
SELECT ALL 68 + + col1 FROM tab2 AS cor0
----
127
85
99

query I rowsort
SELECT DISTINCT col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ( 95 ) FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT + 99 * cor0.col2 FROM tab2 AS cor0
----
2574
2673
3762

query III rowsort
SELECT * FROM tab2 WHERE NOT ( col0 * - col2 + + col2 ) < NULL
----

query I rowsort
SELECT ALL - col2 * + col2 * + tab2.col1 AS col0 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT ALL col2 FROM tab1 WHERE NOT NULL > ( col2 )
----

query I rowsort
SELECT ALL - tab2.col0 * col1 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - - 12 FROM tab1 cor0
----
12
12
12

query I rowsort
SELECT DISTINCT - col2 * tab0.col1 + tab0.col2 FROM tab0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4342
SELECT + tab1.col2 DIV - col1 AS col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4342
SELECT + tab1.col2 / - col1 AS col1 FROM tab1
----
-2
-5
-7

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NULL NOT IN ( - col0 + col0 * - cor0.col2 + - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4344
SELECT DISTINCT col1 + col1 DIV - cor0.col1 - col1 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4344
SELECT DISTINCT col1 + col1 / - cor0.col1 - col1 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT ALL - cor0.col0 FROM tab2 AS cor0 WHERE ( col0 * + col1 - - col2 ) > ( col0 + col1 * col2 )
----
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4346
SELECT DISTINCT - col1 + cor0.col0 + + cor0.col2 DIV - col1 FROM tab0 AS cor0
----
-2
-62

skipif mysql # not compatible
query I rowsort label-4346
SELECT DISTINCT - col1 + cor0.col0 + + cor0.col2 / - col1 FROM tab0 AS cor0
----
-2
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4347
SELECT + tab0.col0 DIV col1 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4347
SELECT + tab0.col0 / col1 col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - cor0.col0 + - cor0.col1 * col1 AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL NOT IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4350
SELECT DISTINCT - tab1.col1 DIV col1 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-4350
SELECT DISTINCT - tab1.col1 / col1 FROM tab1
----
-1

query I rowsort
SELECT + col0 * - col0 * col1 + col2 + col2 FROM tab1
----
-126
-40846
-83008

onlyif mysql # use DIV operator for integer division
query I rowsort label-4352
SELECT ALL col0 * + col0 DIV col0 AS col2 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4352
SELECT ALL col0 * + col0 / col0 AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - tab1.col2 * col1 * col0 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4354
SELECT col1 * col0 DIV col2 AS col1 FROM tab0
----
3395
62
98

skipif mysql # not compatible
query I rowsort label-4354
SELECT col1 * col0 / col2 AS col1 FROM tab0
----
3395
62
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4355
SELECT + col0 * col2 + - col2 DIV col2 AS col1 FROM tab1
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-4355
SELECT + col0 * col2 + - col2 / col2 AS col1 FROM tab1
----
161
3647
7679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 + tab0.col2 col0 FROM tab0
----
1122
2
6806

query I rowsort
SELECT + tab0.col2 * col0 * + col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT - col1 + - col0 - col2 AS col0 FROM tab0
----
-133
-143
-262

query I rowsort
SELECT + col0 * - col2 * col0 AS col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT col1 * - col1 - tab2.col0 FROM tab2
----
-3559
-368
-968

query I rowsort
SELECT ALL col1 * + tab2.col2 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col0 + + col0 * - col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - col2 * col0 * col2 FROM tab1 WHERE + col0 + col0 BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 * - col1 col0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT col1 * tab1.col1 * col1 AS col1 FROM tab1
----
1000
17576
2197

query I rowsort
SELECT ALL - 63 + - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1288
-639
-7984

query I rowsort
SELECT DISTINCT + + col2 + - col0 * - col2 * + col0 FROM tab2 AS cor0
----
1350
158210
237196

query I rowsort
SELECT ALL - + cor0.col1 + - col0 * col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT - col2 * col2 + 60 * + col1 FROM tab1
----
-1356
-2649
-8436

query I rowsort
SELECT - - col2 - ( col0 ) FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT cor0.col0 * ( - col2 ) * col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - 8 col0 FROM tab2 AS cor0
----
-25
-39
-67

query I rowsort
SELECT - tab1.col2 * - tab1.col0 + col1 + col1 AS col2 FROM tab1
----
214
3668
7706

query I rowsort
SELECT col2 * - 39 + + col2 AS col1 FROM tab0 AS cor0
----
-1254
-3116
-38

query I rowsort
SELECT col1 * - col1 + col0 * + ( col1 ) AS col1 FROM tab1 AS cor0
----
-598
540
871

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( - col1 AS REAL ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - ( + 28 ) FROM tab2 AS cor0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT col2 + - 81 * col1 * - col0 AS col0 FROM tab2
----
108821
17604
372788

query I rowsort
SELECT ALL col2 * - ( + 5 ) FROM tab2
----
-130
-135
-190

query I rowsort
SELECT - 42 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

onlyif mysql # use DIV operator for integer division
query I rowsort label-4381
SELECT ALL col2 DIV 70 + - 62 DIV + tab2.col0 AS col1 FROM tab2
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4381
SELECT ALL col2 / 70 + - 62 / + tab2.col0 AS col1 FROM tab2
----
-8
0
0

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 CROSS JOIN tab0 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab2, tab2 cor1
----
972 values hashing to 82def1c3361e635dd4cf447edc22edb9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 65 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT + + col1 * 32 FROM tab2 AS cor0
----
1888
544
992

query I rowsort
SELECT ALL + + col1 * + 6 AS col2 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT ALL + 74 FROM tab2 cor0
----
74
74
74

query I rowsort
SELECT DISTINCT - 48 * 1 AS col2 FROM tab0 AS cor0
----
-48

query I rowsort
SELECT ( col2 ) * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + ( col0 ) * - col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col0 + cor0.col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4392
SELECT - CAST( NULL AS DECIMAL ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4392
SELECT - CAST ( NULL AS REAL ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 38 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT ALL - ( - col0 ) * col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + + ( + cor0.col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4397
SELECT 86 DIV + col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4397
SELECT 86 / + col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + col0 + col0 * + 93 FROM tab2 AS cor0
----
658
7332
7426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + 57 * - col2 * cor0.col0 col2 FROM tab0 AS cor0
----
-1898
-415895
-45058

query I rowsort
SELECT col1 * ( 45 ) FROM tab1 cor0
----
1170
450
585

onlyif mysql # use DIV operator for integer division
query I rowsort label-4401
SELECT col0 + + col0 DIV 58 + col2 AS col1 FROM tab1 AS cor0
----
122
177
57

skipif mysql # not compatible
query I rowsort label-4401
SELECT col0 + + col0 / 58 + col2 AS col1 FROM tab1 AS cor0
----
122
177
57

query I rowsort
SELECT col1 + ( col0 ) - + col2 AS col1 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT DISTINCT - col0 * col2 + ( + col1 ) AS col0 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4404
SELECT DISTINCT + col0 * - col2 + + col2 * col1 DIV 74 + col2 FROM tab1 AS cor0
----
-3584
-7568
-90

skipif mysql # not compatible
query I rowsort label-4404
SELECT DISTINCT + col0 * - col2 + + col2 * col1 / 74 + col2 FROM tab1 AS cor0
----
-3584
-7568
-90

query I rowsort
SELECT DISTINCT - - col2 + - ( - col1 ) AS col2 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4406
SELECT + col2 + + ( 63 ) * col1 DIV col0 FROM tab1 cor0
----
106
600
66

skipif mysql # not compatible
query I rowsort label-4406
SELECT + col2 + + ( 63 ) * col1 / col0 FROM tab1 cor0
----
106
600
66

query I rowsort
SELECT - 50 * ( - col2 ) + col2 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT + col0 * 97 FROM tab0
----
2328
3395
8633

query I rowsort
SELECT cor0.col2 * cor0.col0 + - col2 + 30 FROM tab1 cor0
----
138
3621
7614

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4410
SELECT - + CAST( NULL AS SIGNED ) + 9 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4410
SELECT - + CAST ( NULL AS INTEGER ) + 9 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col2 + col0 + - cor0.col2 * col2 FROM tab0 cor0
----
-1032
-6553
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4412
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) * 70 + - col0 col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4412
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) * 70 + - col0 col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT cor0.col2 * col2 + + col1 * + col1 FROM tab0 AS cor0
----
15005
8485
9410

query I rowsort
SELECT + + cor0.col1 + - 9 * col1 * + col0 AS col2 FROM tab1 cor0
----
-5750
-676
-9347

query I rowsort
SELECT - cor0.col1 + - 38 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a00f337301ff88b2f810666faabbb6c8

query I rowsort
SELECT 85 * - col1 AS col0 FROM tab0
----
-7310
-7735
-8245

query I rowsort
SELECT + + col0 + col2 * + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - col1 + 99 FROM tab2 AS cor0
----
40
68
82

query I rowsort
SELECT ALL - - cor0.col2 + + col0 * - col2 + - col2 * col1 FROM tab2 AS cor0
----
-3536
-3610
-999

query I rowsort
SELECT ALL col1 * col2 - - 8 FROM tab1 AS cor0
----
1256
1412
578

query I rowsort
SELECT ALL - 14 AS col1 FROM tab0 AS cor0
----
-14
-14
-14

query I rowsort
SELECT ALL + 60 FROM tab1, tab0 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - ( + col0 ) col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - col2 + col2 * col1 * ( col2 * col1 ) AS col0 FROM tab2 cor0
----
2353130
417278
700542

query I rowsort
SELECT + col1 * col0 + + ( - col2 ) + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-1697
1
2548

query I rowsort
SELECT ALL - 56 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 34348c65780193c8d601ab14b29af6e7

query I rowsort
SELECT ALL + + 15 + col2 AS col1 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT - 21 + col1 * - col1 FROM tab0 AS cor0
----
-7417
-8302
-9430

onlyif mysql # use DIV operator for integer division
query I rowsort label-4429
SELECT ALL + tab1.col1 DIV - 24 AS col0 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4429
SELECT ALL + tab1.col1 / - 24 AS col0 FROM tab1
----
-1
0
0

query I rowsort
SELECT ( - 61 ) * + col0 - + ( + col2 ) FROM tab1
----
-237
-3961
-4976

query I rowsort
SELECT ALL ( tab2.col0 ) + tab2.col2 * 14 FROM tab2
----
385
442
611

query I rowsort
SELECT + + col0 * + col1 + col0 + col2 * + col2 FROM tab2 AS cor0
----
2866
5356
953

query I rowsort
SELECT ( col0 ) + - col0 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - 76 * + col2 + cor0.col0 * 99 FROM tab2 AS cor0
----
10709
2745
9698

query I rowsort
SELECT + 30 + + col1 * 73 + - col0 FROM tab1
----
1925
696
899

onlyif mysql # use DIV operator for integer division
query I rowsort label-4436
SELECT ALL + col0 + col0 DIV - col2 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-4436
SELECT ALL + col0 + col0 / - col2 FROM tab1 AS cor0
----
3
63
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4437
SELECT col1 - col2 DIV - ( 45 * + col0 ) AS col2 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4437
SELECT col1 - col2 / - ( 45 * + col0 ) AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - - 86 * col2 + - 51 AS col1 FROM tab0 cor0
----
2787
35
7001

query I rowsort
SELECT + - cor0.col1 + col0 * cor0.col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-4440
SELECT ALL + + col0 DIV col0 - + col0 * col2 FROM tab2 AS cor0
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-4440
SELECT ALL + + col0 / col0 - + col0 * col2 FROM tab2 AS cor0
----
-188
-2027
-3001

query I rowsort
SELECT col0 + + 68 * tab2.col0 AS col2 FROM tab2
----
483
5382
5451

query I rowsort
SELECT - col0 * + ( + col2 ) * col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT + 19 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

onlyif mysql # use DIV operator for integer division
query I rowsort label-4444
SELECT ALL - - col1 DIV - CAST( ( - col2 ) * + ( - col0 ) AS SIGNED ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4444
SELECT ALL - - col1 / - CAST ( ( - col2 ) * + ( - col0 ) AS INTEGER ) FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + ( + col1 ) + col0 col2 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT - + col2 + - 59 AS col2 FROM tab0 AS cor0
----
-141
-60
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-4447
SELECT ALL + + col1 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4447
SELECT ALL + + col1 / col0 AS col2 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT col2 + + 96 + + col2 AS col2 FROM tab0 AS cor0
----
162
260
98

query I rowsort
SELECT + col0 + 97 * 40 AS col2 FROM tab0 AS cor0
----
3904
3915
3969

query I rowsort
SELECT 10 * col1 AS col0 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT 53 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT col2 * 95 + - col1 AS col2 FROM tab0
----
-2
3049
7699

query I rowsort
SELECT + 53 + + 81 FROM tab0
----
134
134
134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + col1 col1 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT col0 * 3 FROM tab2
----
21
234
237

query I rowsort
SELECT DISTINCT + + ( + cor0.col0 ) * + col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4457
SELECT ALL + 22 * col0 DIV + cor0.col1 AS col0 FROM tab2 AS cor0
----
102
29
4

skipif mysql # not compatible
query I rowsort label-4457
SELECT ALL + 22 * col0 / + cor0.col1 AS col0 FROM tab2 AS cor0
----
102
29
4

query I rowsort
SELECT ALL col1 * - 24 AS col2 FROM tab1 AS cor0
----
-240
-312
-624

query I rowsort
SELECT ALL - 83 + col2 + - col0 AS col1 FROM tab0 AS cor0
----
-117
-74
-90

query I rowsort
SELECT col0 - col1 * col2 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT - + col1 + + col0 * 77 AS col2 FROM tab1 AS cor0
----
205
4918
6147

query I rowsort
SELECT ALL + col2 + - col0 * + col2 AS col1 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - 74 + + cor0.col1 FROM tab1 AS cor0
----
-48
-61
-64

query I rowsort
SELECT - 15 AS col1 FROM tab2 AS cor0
----
-15
-15
-15

query I rowsort
SELECT DISTINCT + col2 * - col2 + + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT + 84 * col0 + - 39 AS col0 FROM tab1 cor0
----
213
5337
6681

query I rowsort
SELECT ALL - col2 + + cor0.col2 * 64 AS col2 FROM tab2 AS cor0
----
1638
1701
2394

query I rowsort
SELECT col1 - + col2 * 25 AS col2 FROM tab1 cor0
----
-1324
-1415
-2387

onlyif mysql # use DIV operator for integer division
query I rowsort label-4469
SELECT ALL col2 DIV col1 AS col0 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4469
SELECT ALL col2 / col1 AS col0 FROM tab2 cor0
----
0
0
2

query I rowsort
SELECT DISTINCT + 16 AS col0 FROM tab2 AS cor0
----
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + tab1.col0 col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT ( - 19 ) AS col1 FROM tab1
----
-19
-19
-19

query I rowsort
SELECT - col1 * - 33 + col1 AS col1 FROM tab0
----
2924
3094
3298

query I rowsort
SELECT ALL col2 * 30 * - col1 AS col1 FROM tab0
----
-223860
-2910
-85140

query I rowsort
SELECT ALL col0 * - 51 * col1 AS col2 FROM tab2 AS cor0
----
-11067
-234702
-68493

onlyif mysql # use DIV operator for integer division
query I rowsort label-4476
SELECT + - col0 + + col1 DIV - col0 AS col1 FROM tab2 AS cor0
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-4476
SELECT + - col0 + + col1 / - col0 AS col1 FROM tab2 AS cor0
----
-11
-78
-79

query I rowsort
SELECT ALL col2 + + col0 * col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL cor0.col0 * - 78 FROM tab2 cor0
----
-546
-6084
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-4479
SELECT + - ( + 24 ) + + col0 DIV + col0 AS col0 FROM tab0 cor0
----
-23
-23
-23

skipif mysql # not compatible
query I rowsort label-4479
SELECT + - ( + 24 ) + + col0 / + col0 AS col0 FROM tab0 cor0
----
-23
-23
-23

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0 WHERE NULL <= NULL
----

query I rowsort
SELECT DISTINCT col1 * - col1 * col2 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT + col2 * - ( - col2 * - col2 ) FROM tab2 AS cor0
----
-17576
-19683
-54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-4483
SELECT 77 DIV cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c0421ddc6799a3dd508f30102de0f6b8

skipif mysql # not compatible
query I rowsort label-4483
SELECT 77 / cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c0421ddc6799a3dd508f30102de0f6b8

query I rowsort
SELECT ( - 65 ) FROM tab0 AS cor0
----
-65
-65
-65

query I rowsort
SELECT - cor0.col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + 31 * - col1 AS col0 FROM tab1 AS cor0
----
-310
-403
-806

query I rowsort
SELECT + - 23 * col2 * + col1 + col2 * cor0.col0 FROM tab1 cor0
----
-21024
-32130
-9462

query I rowsort
SELECT - col2 + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + + col1 * col1 * + 15 AS col1 FROM tab2 AS cor0
----
14415
4335
52215

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4490
SELECT - + col2 + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4490
SELECT - + col2 + CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col0 * - col0 FROM tab1 cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col2 + - ( - tab2.col0 ) + col2 * col1 col0 FROM tab2
----
-719
115
936

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
24
35
89

query I rowsort
SELECT col0 * ( + col1 ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 56 col0 FROM tab1, tab1 cor0, tab0 AS cor1
----
-56

query I rowsort
SELECT 73 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL + 83 * tab0.col2 FROM tab0
----
2739
6806
83

query I rowsort
SELECT - - col1 + + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + col2 - 53 AS col2 FROM tab1 AS cor0
----
1
4
43

query I rowsort
SELECT ALL - col2 + 5 * col1 FROM tab0 AS cor0
----
373
397
484

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4501
SELECT DISTINCT + - col1 * + col0 + col0 * - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4501
SELECT DISTINCT + - col1 * + col0 + col0 * - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4502
SELECT - CAST( NULL AS SIGNED ) FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4502
SELECT - CAST ( NULL AS INTEGER ) FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col0 * - ( tab1.col2 ) * col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT - 58 * col2 * + col2 + col2 AS col1 FROM tab1 AS cor0
----
-169074
-188385
-534432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 - - col1 col1 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT + 78 * 14 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
1035
1038
996

query I rowsort
SELECT ALL - col2 + + 54 AS col2 FROM tab2 cor0
----
16
27
28

query I rowsort
SELECT - col2 * + col0 + + col1 AS col1 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 24 col2 FROM tab0 AS cor0
----
24

query I rowsort
SELECT col1 * 70 FROM tab1
----
1820
700
910

query I rowsort
SELECT ALL col0 * tab0.col2 + - col2 FROM tab0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4512
SELECT DISTINCT - col0 * ( - col0 ) * - col2 + CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4512
SELECT DISTINCT - col0 * ( - col0 ) * - col2 + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

query I rowsort
SELECT ALL - col2 + 87 FROM tab1
----
-9
30
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 col1 FROM tab2 AS cor0
----
51
51
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + 44 ) col0 FROM tab2
----
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 23 + + col1 * - col2 col2 FROM tab2 AS cor0
----
-1511
-623
-814

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 ) * ( col2 ) + - cor0.col2 col2 FROM tab1 AS cor0
----
-1344
-1458
-627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4518
SELECT - ( cor0.col1 ) * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4518
SELECT - ( cor0.col1 ) * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 93 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
93

query I rowsort
SELECT ( 1 ) AS col1 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT - col1 * col1 - - cor0.col1 AS col2 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - ( col2 ) + + 96 AS col2 FROM tab0 cor0
----
14
63
95

query I rowsort
SELECT ALL - tab2.col1 * + 66 + + 28 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0ae6cb4ff3be626503dc056777e8a208

query I rowsort
SELECT DISTINCT - col2 + 5 * - col1 + ( col1 ) AS col0 FROM tab1
----
-148
-158
-97

query I rowsort
SELECT + tab2.col1 * - col1 + col0 * col0 * - col0 FROM tab2
----
-1304
-478033
-493328

query I rowsort
SELECT - 91 + + col0 FROM tab1 AS cor0
----
-11
-27
-88

query I rowsort
SELECT + col1 + col2 + col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT ALL + + col2 * + ( col0 ) * col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4529
SELECT ALL + 82 DIV cor0.col2 FROM tab1, tab0 cor0
----
9 values hashing to f2fbbd98266a955ee9877179f5a27810

skipif mysql # not compatible
query I rowsort label-4529
SELECT ALL + 82 / cor0.col2 FROM tab1, tab0 cor0
----
9 values hashing to f2fbbd98266a955ee9877179f5a27810

query I rowsort
SELECT - ( + 96 ) AS col0 FROM tab1 AS cor0
----
-96
-96
-96

query I rowsort
SELECT + col2 * 4 FROM tab2 AS cor0
----
104
108
152

onlyif mysql # use DIV operator for integer division
query I rowsort label-4532
SELECT DISTINCT - - col0 DIV + col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4532
SELECT DISTINCT - - col0 / + col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL 56 + col2 * ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
1145
57
6780

query I rowsort
SELECT DISTINCT + + 39 * col2 * + 16 FROM tab0 AS cor0
----
20592
51168
624

query I rowsort
SELECT ALL 3 AS col1 FROM tab2 cor0
----
3
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 * + col0 col1 FROM tab0 cor0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4537
SELECT ALL - col2 + + cor0.col0 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4537
SELECT ALL - col2 + + cor0.col0 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 + - 1 + + col0 * col1 FROM tab0 AS cor0
----
15396
2855
3429

query I rowsort
SELECT 24 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT DISTINCT + - col0 + col2 * + ( cor0.col1 ) * - col2 FROM tab2 AS cor0
----
-22606
-24627
-39962

query I rowsort
SELECT - ( - 12 ) FROM tab2
----
12
12
12

query I rowsort
SELECT + - cor0.col2 * + ( col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 * col2 + + col0 col2 FROM tab1 AS cor0
----
119888
32554
75819

query I rowsort
SELECT + 58 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT col0 + + col2 * + ( col2 ) FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT + + col2 * 94 FROM tab1 AS cor0
----
5076
5358
9024

onlyif mysql # use DIV operator for integer division
query I rowsort label-4547
SELECT ALL + col2 DIV cor0.col1 + + 66 AS col2 FROM tab1 AS cor0
----
68
71
73

skipif mysql # not compatible
query I rowsort label-4547
SELECT ALL + col2 / cor0.col1 + + 66 AS col2 FROM tab1 AS cor0
----
68
71
73

query I rowsort
SELECT DISTINCT - col2 * + ( - col1 * - col2 ) AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 34 col2 FROM tab2 cor0
----
112
113
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4550
SELECT ALL - col1 * CAST( NULL AS SIGNED ) + 39 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4550
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) + 39 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4551
SELECT col0 DIV - 92 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4551
SELECT col0 / - 92 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 66 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT DISTINCT 52 + + cor0.col1 * col2 + 57 * col2 AS col2 FROM tab1 cor0
----
3871
4534
6772

query I rowsort
SELECT - 22 - + cor0.col2 AS col1 FROM tab1 AS cor0
----
-118
-76
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 81 + col0 * - col2 col2 FROM tab2 AS cor0
----
-2109
-270
-3083

query I rowsort
SELECT DISTINCT - ( + ( + col0 ) ) + col0 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL + 12 AS col2 FROM tab1 cor0 CROSS JOIN tab1, tab2 cor1, tab0 AS cor2, tab1 AS cor3
----
243 values hashing to 009580ad7795d0f2b23f7f164938fe70

query I rowsort
SELECT ALL col0 + + 40 FROM tab2 AS cor0
----
118
119
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-4559
SELECT ALL + - 58 DIV col1 + + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4559
SELECT ALL + - 58 / col1 + + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 74 col0 FROM tab1 AS cor0
----
-74
-74
-74

query I rowsort
SELECT DISTINCT ( + col0 ) - - col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL col2 * col1 * col1 + - col2 FROM tab1 AS cor0
----
16128
36450
5643

query I rowsort
SELECT - - col2 * 96 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT + col2 * 25 + - 29 FROM tab2
----
621
646
921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4565
SELECT + col0 - CAST( - col2 AS SIGNED ) AS col1 FROM tab2
----
104
117
34

skipif mysql # not compatible
query I rowsort label-4565
SELECT + col0 - CAST ( - col2 AS INTEGER ) AS col1 FROM tab2
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4566
SELECT CAST( - col1 AS SIGNED ) + - col2 + 73 FROM tab1
----
-36
-7
6

skipif mysql # not compatible
query I rowsort label-4566
SELECT CAST ( - col1 AS INTEGER ) + - col2 + 73 FROM tab1
----
-36
-7
6

query I rowsort
SELECT DISTINCT 72 * cor0.col1 AS col1 FROM tab0, tab1 AS cor0
----
1872
720
936

onlyif mysql # use DIV operator for integer division
query I rowsort label-4568
SELECT - 89 + + 21 DIV col0 + + 22 * + col0 AS col2 FROM tab1
----
-16
1319
1671

skipif mysql # not compatible
query I rowsort label-4568
SELECT - 89 + + 21 / col0 + + 22 * + col0 AS col2 FROM tab1
----
-16
1319
1671

query I rowsort
SELECT - - ( col2 ) * + col1 - ( + 47 ) * cor0.col1 FROM tab0 AS cor0
----
-1204
-4462
3185

query I rowsort
SELECT DISTINCT + 69 * + col1 + - col2 FROM tab2 AS cor0
----
1135
2112
4045

onlyif mysql # use DIV operator for integer division
query I rowsort label-4571
SELECT ALL - col0 DIV 8 + col2 + 94 FROM tab2 AS cor0
----
111
121
123

skipif mysql # not compatible
query I rowsort label-4571
SELECT ALL - col0 / 8 + col2 + 94 FROM tab2 AS cor0
----
111
121
123

onlyif mysql # use DIV operator for integer division
query I rowsort label-4572
SELECT 99 + 0 DIV + col1 FROM tab1 AS cor0
----
99
99
99

skipif mysql # not compatible
query I rowsort label-4572
SELECT 99 + 0 / + col1 FROM tab1 AS cor0
----
99
99
99

query I rowsort
SELECT ALL + col1 - 14 FROM tab1 cor0
----
-1
-4
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col0 col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + + cor0.col0 * ( col1 ) AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - col1 + - 90 AS col1 FROM tab0
----
-176
-181
-187

query I rowsort
SELECT DISTINCT - cor1.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 10 + col0 AS col2 FROM tab1
----
13
74
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4579
SELECT DISTINCT + - col2 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4579
SELECT DISTINCT + - col2 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col2 * ( col2 * col1 ) AS col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT - - col0 + col0 * ( col2 * cor0.col1 ) + - col2 FROM tab2 AS cor0
----
119704
51075
5839

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4582
SELECT tab0.col0 + CAST( 84 * col1 AS SIGNED ) FROM tab0
----
7248
7733
8183

skipif mysql # not compatible
query I rowsort label-4582
SELECT tab0.col0 + CAST ( 84 * col1 AS INTEGER ) FROM tab0
----
7248
7733
8183

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - 57 * - col2 col0 FROM tab1
----
3052
3239
5459

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 + - col0 * col2 col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - col2 * 0 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - ( col0 + - col1 ) col2 FROM tab2
----
-1482
-4898
168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4587
SELECT ALL col2 * - CAST( NULL AS DECIMAL ) * + col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4587
SELECT ALL col2 * - CAST ( NULL AS REAL ) * + col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col2 col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + col2 + - 84 * 73 FROM tab0 cor0
----
-6050
-6099
-6131

query I rowsort
SELECT DISTINCT + col0 - - cor0.col1 AS col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - tab0.col1 * + tab0.col2 * 53 + - col1 col0 FROM tab0
----
-150467
-395495
-5237

onlyif mysql # use DIV operator for integer division
query I rowsort label-4592
SELECT DISTINCT + col1 DIV - col0 + col2 AS col1 FROM tab1
----
46
57
96

skipif mysql # not compatible
query I rowsort label-4592
SELECT DISTINCT + col1 / - col0 + col2 AS col1 FROM tab1
----
46
57
96

query I rowsort
SELECT DISTINCT 88 + - tab1.col0 * - tab1.col2 * col2 AS col2 FROM tab1
----
208024
737368
8836

query I rowsort
SELECT + + cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4595
SELECT - 43 + col0 DIV 68 AS col2 FROM tab2 AS cor0
----
-42
-42
-43

skipif mysql # not compatible
query I rowsort label-4595
SELECT - 43 + col0 / 68 AS col2 FROM tab2 AS cor0
----
-42
-42
-43

query I rowsort
SELECT - col1 + + col0 + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT - 65 * - ( + col0 ) AS col0 FROM tab0
----
1560
2275
5785

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4598
SELECT + CAST( NULL AS DECIMAL ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4598
SELECT + CAST ( NULL AS REAL ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + tab1.col1 ) * - 0 + 40 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 + - tab0.col0 col1 FROM tab0, tab2, tab1 cor0
----
9 values hashing to ae22909705672dcb483690ac21345259

query I rowsort
SELECT ALL + col1 * + col0 + + col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + col2 * + col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col2 + col2 + cor0.col2 * ( col1 * - col2 ) FROM tab0 AS cor0
----
-611720
-93588
-95

query I rowsort
SELECT DISTINCT + ( - col2 ) + col0 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + col2 * + col0 + tab2.col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4606
SELECT ALL + col1 * col2 DIV - 11 + col2 + + col0 AS col2 FROM tab1
----
-70
63
70

skipif mysql # not compatible
query I rowsort label-4606
SELECT ALL + col1 * col2 / - 11 + col2 + + col0 AS col2 FROM tab1
----
-70
63
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 * 34 col1 FROM tab2
----
238
2652
2686

onlyif mysql # use DIV operator for integer division
query I rowsort label-4608
SELECT + + col0 DIV 2 FROM tab0 cor0
----
12
17
44

skipif mysql # not compatible
query I rowsort label-4608
SELECT + + col0 / 2 FROM tab0 cor0
----
12
17
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-4609
SELECT DISTINCT - col2 DIV col1 + 37 AS col2 FROM tab1 AS cor0
----
30
32
35

skipif mysql # not compatible
query I rowsort label-4609
SELECT DISTINCT - col2 / col1 + 37 AS col2 FROM tab1 AS cor0
----
30
32
35

query I rowsort
SELECT DISTINCT cor0.col2 * 69 AS col0 FROM tab1 AS cor0
----
3726
3933
6624

query I rowsort
SELECT + col2 * 14 AS col1 FROM tab1 AS cor0
----
1344
756
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-4612
SELECT ALL + 68 DIV 12 FROM tab0, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

skipif mysql # not compatible
query I rowsort label-4612
SELECT ALL + 68 / 12 FROM tab0, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col2 * - cor0.col0 col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT 47 - col0 FROM tab1 AS cor0
----
-17
-33
44

query I rowsort
SELECT + col1 * col0 + + col1 + + ( 53 + col2 ) AS col2 FROM tab2 cor0
----
1451
328
4740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 + cor0.col0 + cor0.col2 col0 FROM tab1 AS cor0
----
4217
6576
66

query I rowsort
SELECT + 99 * + 21 + + col0 FROM tab0 AS cor0
----
2103
2114
2168

query I rowsort
SELECT DISTINCT col2 + - 45 * - col1 FROM tab1
----
1224
507
681

query I rowsort
SELECT DISTINCT - col0 + ( col1 ) + + col0 FROM tab2
----
17
31
59

query I rowsort
SELECT + col1 * 79 AS col0 FROM tab0 AS cor0
----
6794
7189
7663

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4621
SELECT - CAST( NULL AS DECIMAL ) * - col0 + col0 * col0 * 28 + + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4621
SELECT - CAST ( NULL AS REAL ) * - col0 + col0 * col0 * 28 + + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + col1 * + col2 + + 18 FROM tab2 AS cor0
----
1526
626
828

query I rowsort
SELECT ( col2 ) + col1 * ( + col1 ) AS col2 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-4624
SELECT + col0 * + col2 + - tab1.col0 DIV col0 - col0 AS col2 FROM tab1
----
158
3583
7599

skipif mysql # not compatible
query I rowsort label-4624
SELECT + col0 * + col2 + - tab1.col0 / col0 - col0 AS col2 FROM tab1
----
158
3583
7599

onlyif mysql # use DIV operator for integer division
query I rowsort label-4625
SELECT - ( + col1 ) DIV col2 AS col1 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4625
SELECT - ( + col1 ) / col2 AS col1 FROM tab0
----
-1
-2
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4626
SELECT DISTINCT CAST( col2 + col0 AS SIGNED ) FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-4626
SELECT DISTINCT CAST ( col2 + col0 AS INTEGER ) FROM tab0
----
171
36
57

query I rowsort
SELECT tab1.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - - col1 * col2 + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL 73 * + col1 FROM tab2 AS cor0
----
1241
2263
4307

query I rowsort
SELECT - 36 AS col2 FROM tab1 cor0
----
-36
-36
-36

query I rowsort
SELECT 31 * - col1 FROM tab2 cor0
----
-1829
-527
-961

query I rowsort
SELECT ALL - 35 AS col1 FROM tab2 AS cor0
----
-35
-35
-35

query I rowsort
SELECT - - col1 + col0 + col0 * col1 AS col1 FROM tab1 AS cor0
----
107
1133
714

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 92 - cor0.col0 * col1 col1 FROM tab1 AS cor0
----
-548
-948
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-4635
SELECT - col0 DIV + col2 AS col0 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4635
SELECT - col0 / + col2 AS col0 FROM tab1
----
-1
0
0

query I rowsort
SELECT ALL + ( 18 + col1 ) * col2 AS col2 FROM tab1
----
1596
2376
2976

query I rowsort
SELECT - - col1 * - col2 + col0 FROM tab1 cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4638
SELECT - + col2 + CAST( cor0.col1 AS SIGNED ) FROM tab0 cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-4638
SELECT - + col2 + CAST ( cor0.col1 AS INTEGER ) FROM tab0 cor0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4639
SELECT ( - col1 * CAST( NULL AS SIGNED ) + - tab1.col0 ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4639
SELECT ( - col1 * CAST ( NULL AS INTEGER ) + - tab1.col0 ) AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4640
SELECT ALL + cor0.col1 + + CAST( NULL AS SIGNED ) + - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4640
SELECT ALL + cor0.col1 + + CAST ( NULL AS INTEGER ) + - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 - cor0.col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - tab0.col0 - - col0 FROM tab0
----
0

query I rowsort
SELECT + ( - col2 ) * 4 AS col0 FROM tab2
----
-104
-108
-152

query I rowsort
SELECT DISTINCT tab0.col1 * col1 - - ( col2 * - col0 ) FROM tab0
----
6604
9374
983

query I rowsort
SELECT DISTINCT 21 * col1 FROM tab0
----
1806
1911
2037

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * - col1 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4647
SELECT - 31 DIV + col1 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4647
SELECT - 31 / + col1 FROM tab2
----
-1
-1
0

query I rowsort
SELECT - col2 * col0 * + col2 FROM tab0 cor0
----
-26136
-35
-598436

query I rowsort
SELECT col2 + col1 * ( col0 ) FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + 12 * + col0 + - col0 AS col0 FROM tab0
----
264
385
979

onlyif mysql # use DIV operator for integer division
query I rowsort label-4651
SELECT + col1 * col0 + col2 * col1 DIV + 94 AS col1 FROM tab0 AS cor0
----
2094
3396
8178

skipif mysql # not compatible
query I rowsort label-4651
SELECT + col1 * col0 + col2 * col1 / + 94 AS col1 FROM tab0 AS cor0
----
2094
3396
8178

onlyif mysql # use DIV operator for integer division
query I rowsort label-4652
SELECT - col2 DIV + col1 + + 50 * col1 col0 FROM tab0 AS cor0
----
4300
4550
4850

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4652
SELECT - col2 / + col1 + + 50 * col1 col0 FROM tab0 AS cor0
----
4300
4550
4850

query I rowsort
SELECT ALL + + cor0.col2 * + col1 - - col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + col1 + - col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - col2 + 89 AS col0 FROM tab0 AS cor0
----
56
7
88

query I rowsort
SELECT + + col2 - col2 * col1 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4657
SELECT DISTINCT + - col2 * CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-4657
SELECT DISTINCT + - col2 * CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - cor0.col1 - cor0.col2 * - col0 * col1 AS col2 FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT ALL - - col2 + - 23 FROM tab2 AS cor0
----
15
3
4

query I rowsort
SELECT + col2 + 80 * + cor0.col1 FROM tab0 AS cor0
----
6913
7362
7761

query I rowsort
SELECT col1 * ( 95 ) AS col1 FROM tab0 cor0
----
8170
8645
9215

query I rowsort
SELECT DISTINCT + - col2 * + col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 + - col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT ALL - 60 * - col2 FROM tab1
----
3240
3420
5760

query I rowsort
SELECT col1 + - col2 * col0 AS col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - ( 52 ) FROM tab1
----
-52

query I rowsort
SELECT + - col0 * 11 + col2 * + col2 FROM tab0 AS cor0
----
-384
5745
825

query I rowsort
SELECT ALL - 12 * - cor0.col2 + col0 FROM tab2 AS cor0
----
331
390
535

query I rowsort
SELECT + col2 * - 92 AS col2 FROM tab2 AS cor0
----
-2392
-2484
-3496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 4 col0 FROM tab0 AS cor0
----
4
4
4

query I rowsort
SELECT ALL + 58 * col1 AS col2 FROM tab2 AS cor0
----
1798
3422
986

query I rowsort
SELECT DISTINCT - + 85 AS col1 FROM tab1 AS cor0
----
-85

query I rowsort
SELECT + ( col0 ) * + cor0.col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4674
SELECT ALL - + col1 + - cor0.col2 DIV col0 FROM tab2 AS cor0
----
-17
-34
-59

skipif mysql # not compatible
query I rowsort label-4674
SELECT ALL - + col1 + - cor0.col2 / col0 FROM tab2 AS cor0
----
-17
-34
-59

query I rowsort
SELECT DISTINCT 0 AS col1 FROM tab0, tab1 cor0
----
0

query I rowsort
SELECT - ( - 97 ) AS col0 FROM tab2
----
97
97
97

query I rowsort
SELECT DISTINCT + - 15 AS col1 FROM tab1 AS cor0
----
-15

query I rowsort
SELECT 79 * cor0.col0 * 32 FROM tab2 AS cor0
----
17696
197184
199712

query I rowsort
SELECT ALL + col0 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4680
SELECT + - 79 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4680
SELECT + - 79 / + col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4681
SELECT DISTINCT - cor0.col2 DIV - col0 + 61 * - col1 AS col1 FROM tab0 AS cor0
----
-5245
-5551
-5917

skipif mysql # not compatible
query I rowsort label-4681
SELECT DISTINCT - cor0.col2 / - col0 + 61 * - col1 AS col1 FROM tab0 AS cor0
----
-5245
-5551
-5917

query I rowsort
SELECT - 36 * + col1 AS col1 FROM tab1 AS cor0
----
-360
-468
-936

onlyif mysql # use DIV operator for integer division
query I rowsort label-4683
SELECT ALL + - col2 DIV - col0 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4683
SELECT ALL + - col2 / - col0 AS col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT DISTINCT - + col2 * col2 + + col0 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT + col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - col1 * col1 - cor0.col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT DISTINCT col2 * col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + - col2 * + col0 * col2 + + ( col0 ) * + 49 * + 93 FROM tab1 AS cor0
----
-372720
4923
83712

onlyif mysql # use DIV operator for integer division
query I rowsort label-4689
SELECT + col2 DIV col0 + col2 AS col1 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-4689
SELECT + col2 / col0 + col2 AS col1 FROM tab0 AS cor0
----
1
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4690
SELECT col1 - col2 DIV col1 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-4690
SELECT col1 - col2 / col1 FROM tab1
----
24
5
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * col2 + col0 col1 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT ALL + col0 * col2 + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 + + col1 col0 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-4694
SELECT ALL - col1 DIV col0 + + cor0.col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-4694
SELECT ALL - col1 / col0 + + cor0.col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT ALL + 46 + - col2 * 42 + 15 AS col1 FROM tab1 AS cor0
----
-2207
-2333
-3971

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4696
SELECT ALL + - cor0.col1 * CAST( + 88 AS SIGNED ) FROM tab2 AS cor0
----
-1496
-2728
-5192

skipif mysql # not compatible
query I rowsort label-4696
SELECT ALL + - cor0.col1 * CAST ( + 88 AS INTEGER ) FROM tab2 AS cor0
----
-1496
-2728
-5192

query I rowsort
SELECT + col0 + - 44 AS col1 FROM tab2 AS cor0
----
-37
34
35

query I rowsort
SELECT ALL cor0.col1 + ( cor0.col2 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

query I rowsort
SELECT 78 + + col2 AS col1 FROM tab1 cor0
----
132
135
174

query I rowsort
SELECT ALL ( col0 ) + cor0.col2 * + col2 AS col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT col2 * + col2 * - col1 + + 79 FROM tab1 AS cor0
----
-119729
-32411
-75737

query I rowsort
SELECT + ( - col2 ) * col1 + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4703
SELECT + + CAST( NULL AS SIGNED ) * ( col1 ) + ( col2 + - col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4703
SELECT + + CAST ( NULL AS INTEGER ) * ( col1 ) + ( col2 + - col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 78 * col1 + + col1 + col2 AS col1 FROM tab0 AS cor0
----
6827
7271
7664

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2, tab0 AS cor3
----
3645 values hashing to 3b4587ab6c08d2179c6df094d2f76ad7

query I rowsort
SELECT ALL + 71 FROM tab1, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT - col0 * ( - ( col0 ) ) FROM tab2
----
49
6084
6241

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 cor2
----
972 values hashing to 591a9a93560839231c038a1e10bd240a

query I rowsort
SELECT + ( tab0.col0 ) + - col2 * - 29 * col1 AS col2 FROM tab0
----
216487
2848
82326

query I rowsort
SELECT 21 + + 94 AS col2 FROM tab1
----
115
115
115

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4711
SELECT ALL - CAST( NULL AS SIGNED ) + tab0.col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4711
SELECT ALL - CAST ( NULL AS INTEGER ) + tab0.col1 AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4712
SELECT ALL CAST( NULL AS SIGNED ) * - col2 + col0 * + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4712
SELECT ALL CAST ( NULL AS INTEGER ) * - col2 + col0 * + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4713
SELECT ALL - ( tab1.col0 ) * col2 DIV col0 + + 15 * - tab1.col1 AS col1 FROM tab1
----
-207
-291
-444

skipif mysql # not compatible
query I rowsort label-4713
SELECT ALL - ( tab1.col0 ) * col2 / col0 + + 15 * - tab1.col1 AS col1 FROM tab1
----
-207
-291
-444

query I rowsort
SELECT ALL 81 + col0 * - tab2.col0 AS col0 FROM tab2
----
-6003
-6160
32

query I rowsort
SELECT ALL col1 + col2 AS col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col1 + + 55 - + col1 FROM tab0 AS cor0
----
55

query I rowsort
SELECT DISTINCT 98 * + 65 + - col1 - + ( col0 ) FROM tab1 AS cor0
----
6277
6296
6341

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 24 * col2 col1 FROM tab0
----
179088
2328
68112

query I rowsort
SELECT col2 * col2 * col0 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT ALL + - ( - 16 ) * col0 + col1 FROM tab0 AS cor0
----
1515
470
657

query I rowsort
SELECT - + ( col0 ) + col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT col1 * + col2 * - cor0.col2 + col0 - - col2 AS col1 FROM tab1 cor0
----
-119632
-32369
-75759

query I rowsort
SELECT ALL + - col1 + + 17 + - col0 AS col0 FROM tab2 AS cor0
----
-120
-21
-79

query I rowsort
SELECT - col0 + - 95 FROM tab1 AS cor0
----
-159
-175
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col0 col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT 15 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT ALL 43 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT ALL 46 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT col0 + col2 * cor0.col2 + + 41 FROM tab2 AS cor0
----
1564
777
795

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4730
SELECT + CAST( + 86 AS SIGNED ) - col2 AS col1 FROM tab1 AS cor0
----
-10
29
32

skipif mysql # not compatible
query I rowsort label-4730
SELECT + CAST ( + 86 AS INTEGER ) - col2 AS col1 FROM tab1 AS cor0
----
-10
29
32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4731
SELECT - col2 + col2 * col2 * CAST( - col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-22626
-24586
-39910

skipif mysql # not compatible
query I rowsort label-4731
SELECT - col2 + col2 * col2 * CAST ( - col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-22626
-24586
-39910

query I rowsort
SELECT DISTINCT - cor0.col0 - + cor1.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-106
-13
-16
-29
-74
-77
-90
-93

query I rowsort
SELECT + col0 * 43 + - col0 AS col1 FROM tab0 cor0
----
1008
1470
3738

query I rowsort
SELECT ALL - ( - col1 ) * - col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT 35 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT DISTINCT col1 * + 88 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
1458
2701
5166

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - 14 * col2 col1 FROM tab1 AS cor0
----
-1264
-734
-753

query I rowsort
SELECT DISTINCT - 1 * - cor0.col2 AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + ( 25 ) AS col2 FROM tab2, tab1 cor0
----
25

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1, tab1 cor2
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + tab1.col0 col0 FROM tab1
----
29
74
93

query I rowsort
SELECT - ( + tab2.col1 ) + - col1 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT + + 77 * - col1 FROM tab1 AS cor0
----
-1001
-2002
-770

query I rowsort
SELECT DISTINCT - 83 FROM tab2, tab2 AS cor0
----
-83

query I rowsort
SELECT ALL - 73 FROM tab0, tab1 cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT col2 - 90 * col1 FROM tab1
----
-1074
-2286
-843

query I rowsort
SELECT DISTINCT - ( - tab2.col2 ) * col2 - col2 AS col1 FROM tab2
----
1406
650
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4748
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + col1 * col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4748
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + col1 * col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + ( + 25 ) FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT 89 * - col2 * col0 AS col2 FROM tab1 AS cor0
----
-14418
-324672
-683520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col1 + col2 col1 FROM tab2 AS cor0
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-4752
SELECT - 41 + col2 DIV col0 FROM tab2 AS cor0
----
-38
-41
-41

skipif mysql # not compatible
query I rowsort label-4752
SELECT - 41 + col2 / col0 FROM tab2 AS cor0
----
-38
-41
-41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4753
SELECT - col1 * col0 / + cor0.col2 + + col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4753
SELECT - col1 * col0 / + cor0.col2 + + col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col2 * col2 * + 14 AS col2 FROM tab0 AS cor0
----
-14
-15246
-94136

query I rowsort
SELECT + col1 * 68 * col2 AS col1 FROM tab2 AS cor0
----
104312
43928
56916

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
-7
-78
-79

query I rowsort
SELECT + - col2 * ( cor0.col1 * - cor0.col2 ) + cor0.col2 AS col2 FROM tab2 AS cor0
----
22626
24586
39910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4758
SELECT ALL col2 * CAST( col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-4758
SELECT ALL col2 * CAST ( col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4759
SELECT ALL + col2 DIV 33 AS col2 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4759
SELECT ALL + col2 / 33 AS col2 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT + 60 * + 87 + - cor1.col2 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 233d6460d8bb78cf9991e525ca79d29b

query I rowsort
SELECT + 19 + - cor0.col1 * - col1 AS col0 FROM tab1 AS cor0
----
119
188
695

query I rowsort
SELECT ALL + col0 - col2 * ( + col1 ) FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + cor0.col1 * + cor0.col2 * col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - col0 - - col0 * col2 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT - - ( + col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col2 + col1 * 95 FROM tab1
----
1007
1331
2524

onlyif mysql # use DIV operator for integer division
query I rowsort label-4767
SELECT ( + col2 ) DIV + 87 + col0 col2 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4767
SELECT ( + col2 ) / + 87 + col0 col2 FROM tab2
----
7
78
79

query I rowsort
SELECT 34 * + col1 - + 94 FROM tab1
----
246
348
790

query I rowsort
SELECT ALL 9 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT tab1.col1 * 15 FROM tab1
----
150
195
390

query I rowsort
SELECT - + 66 * col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1498
-2213
-5783

onlyif mysql # use DIV operator for integer division
query I rowsort label-4772
SELECT - - 89 * col2 + - col2 DIV 51 FROM tab1 AS cor0
----
4805
5072
8543

skipif mysql # not compatible
query I rowsort label-4772
SELECT - - 89 * col2 + - col2 / 51 FROM tab1 AS cor0
----
4805
5072
8543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + - ( col2 ) * 5 col2 FROM tab1 AS cor0
----
-244
-275
-467

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 65 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT ALL tab2.col2 + + 70 FROM tab2
----
108
96
97

query I rowsort
SELECT ALL 62 * 60 FROM tab1
----
3720
3720
3720

query I rowsort
SELECT + col2 * + col1 + + col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-4778
SELECT ALL - col2 * col1 DIV + col0 + + col2 AS col1 FROM tab0 AS cor0
----
-1
-1
-85

skipif mysql # not compatible
query I rowsort label-4778
SELECT ALL - col2 * col1 / + col0 + + col2 AS col1 FROM tab0 AS cor0
----
-1
-1
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4779
SELECT - CAST( NULL AS DECIMAL ) * - col1 / col0 + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4779
SELECT - CAST ( NULL AS REAL ) * - col1 / col0 + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + - col1 * - col1 FROM tab1 cor0
----
43
622
73

query I rowsort
SELECT DISTINCT + col0 * col1 * col2 + - ( col1 ) AS col1 FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT - ( cor0.col2 ) + col1 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL 42 + - 17 FROM tab0 AS cor0
----
25
25
25

query I rowsort
SELECT + + 36 AS col1 FROM tab1 AS cor0
----
36
36
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4785
SELECT ALL CAST( - col0 AS SIGNED ) * col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

skipif mysql # not compatible
query I rowsort label-4785
SELECT ALL CAST ( - col0 AS INTEGER ) * col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4786
SELECT CAST( NULL AS SIGNED ) * - cor0.col2 + - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4786
SELECT CAST ( NULL AS INTEGER ) * - cor0.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-4787
SELECT ALL - CAST( NULL AS SIGNED ) / 36 + + col2 - + col1 * + ( - cor0.col2 * + CAST( NULL AS SIGNED ) ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4787
SELECT ALL - CAST ( NULL AS INTEGER ) / 36 + + col2 - + col1 * + ( - cor0.col2 * + 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-4788
SELECT ALL col0 * col0 DIV + col1 col1 FROM tab1
----
0
409
492

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4788
SELECT ALL col0 * col0 / + col1 col1 FROM tab1
----
0
409
492

query I rowsort
SELECT + 73 + 25 FROM tab2 AS cor0
----
98
98
98

query I rowsort
SELECT - cor0.col1 * ( 88 ) AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1688092a1528c8577b0cd808ddf99200

query I rowsort
SELECT DISTINCT - ( + col1 ) + - col1 FROM tab0 AS cor0
----
-172
-182
-194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * + col1 * cor0.col2 col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - ( + col2 * tab2.col1 ) AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT ( + col2 ) * - 28 FROM tab0 AS cor0
----
-2296
-28
-924

query I rowsort
SELECT DISTINCT - + 53 + col0 * col2 FROM tab1 AS cor0
----
109
3595
7627

onlyif mysql # use DIV operator for integer division
query I rowsort label-4796
SELECT col2 * col0 DIV + col0 + + col1 * + col1 * + col0 FROM tab0 AS cor0
----
177537
329316
737091

skipif mysql # not compatible
query I rowsort label-4796
SELECT col2 * col0 / + col0 + + col1 * + col1 * + col0 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT DISTINCT + + 35 * col0 + col2 * - col2 AS col1 FROM tab1 AS cor0
----
-1009
-2811
-6416

query I rowsort
SELECT DISTINCT - ( - col0 ) * col2 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + col0 + - col0 * - cor0.col0 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 88 * - col0 col0 FROM tab2 AS cor0
----
-616
-6864
-6952

query I rowsort
SELECT - 44 * cor0.col0 FROM tab1 AS cor0
----
-132
-2816
-3520

query I rowsort
SELECT - 49 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to adfccb10c9468825d9961e3613140f89

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 AS col0 FROM tab0 cor0
----
2
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4804
SELECT + cor0.col0 DIV + 34 + + ( - col0 + ( 25 ) ) FROM tab1 AS cor0
----
-38
-53
22

skipif mysql # not compatible
query I rowsort label-4804
SELECT + cor0.col0 / + 34 + + ( - col0 + ( 25 ) ) FROM tab1 AS cor0
----
-38
-53
22

query I rowsort
SELECT + + col1 + 98 FROM tab1 AS cor0
----
108
111
124

query I rowsort
SELECT DISTINCT + col0 + - 10 AS col1 FROM tab0 AS cor0
----
14
25
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4807
SELECT CAST( NULL AS SIGNED ) + 20 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4807
SELECT CAST ( NULL AS INTEGER ) + 20 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - + col0 * - col0 + cor0.col2 + - col0 AS col1 FROM tab2 AS cor0
----
6032
6200
69

query I rowsort
SELECT DISTINCT col0 + 65 AS col2 FROM tab2 AS cor0
----
143
144
72

query I rowsort
SELECT ALL col2 + col2 * cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT + + col1 - 33 FROM tab1 AS cor0
----
-20
-23
-7

query I rowsort
SELECT + + col1 * 35 + cor0.col2 * col2 + col1 AS col0 FROM tab0 cor0
----
10000
3493
4185

query I rowsort
SELECT + col1 + col1 * - ( - col1 ) * col1 + - col0 * col1 FROM tab2 AS cor0
----
200836
29605
3587

query I rowsort
SELECT DISTINCT - col0 * col0 * - 20 AS col2 FROM tab0 AS cor0
----
11520
158420
24500

query I rowsort
SELECT DISTINCT col2 * col0 * col0 FROM tab1 cor0
----
233472
486
614400

query I rowsort
SELECT + + col0 + + col0 + cor0.col1 FROM tab0 AS cor0
----
134
167
269

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - col2 + col2 col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4818
SELECT - + CAST( NULL AS DECIMAL ) + col0 - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4818
SELECT - + CAST ( NULL AS REAL ) + col0 - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4819
SELECT DISTINCT 69 DIV + ( cor0.col1 ) FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4819
SELECT DISTINCT 69 / + ( cor0.col1 ) FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + 74 * 3 FROM tab0 AS cor0
----
222
222
222

query I rowsort
SELECT col1 + col2 * col0 + - ( - cor0.col0 ) FROM tab1 AS cor0
----
191
3722
7773

query I rowsort
SELECT DISTINCT + ( - col1 ) * + cor0.col1 * col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL + col2 + tab1.col1 AS col0 FROM tab1
----
109
67
80

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2, tab1 AS cor3
----
3645 values hashing to 1c1b1a313871216b88e662d7d3078b12

query I rowsort
SELECT ALL + 69 AS col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4826
SELECT - 90 DIV + col2 AS col0 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4826
SELECT - 90 / + col2 AS col0 FROM tab1 cor0
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4827
SELECT - col1 + CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4827
SELECT - col1 + CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 8 * col1 FROM tab0
----
688
728
776

query I rowsort
SELECT col1 * col1 + col0 AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT + col1 + - col1 + + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 79 col2 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
-79

query I rowsort
SELECT ALL + 87 * col1 - - cor0.col2 * ( 92 ) AS col0 FROM tab2 AS cor0
----
4975
5181
7525

query I rowsort
SELECT + col0 + ( - col2 ) * - col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT DISTINCT + col1 + - col2 * ( col2 ) AS col0 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT - 44 + col0 FROM tab1
----
-41
20
36

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab2, tab1, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT DISTINCT 56 * + col1 * - col1 AS col1 FROM tab0
----
-414176
-463736
-526904

query I rowsort
SELECT DISTINCT 26 * - col2 + + col1 * + col1 AS col2 FROM tab0 AS cor0
----
6149
6538
9383

query I rowsort
SELECT + - ( ( - col2 ) ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT 53 AS col0 FROM tab2
----
53
53
53

query I rowsort
SELECT DISTINCT + 99 * + col1 + col1 + - cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
-2249
-316
-7916

query I rowsort
SELECT cor0.col0 + + col2 * - 72 * 85 AS col0 FROM tab0 AS cor0
----
-201936
-501751
-6085

onlyif mysql # use DIV operator for integer division
query I rowsort label-4843
SELECT ALL - col0 DIV + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4843
SELECT ALL - col0 / + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - 57 * tab1.col0 FROM tab1
----
-171
-3648
-4560

query I rowsort
SELECT 93 + cor0.col2 FROM tab2 AS cor0
----
119
120
131

query I rowsort
SELECT + 65 + - 85 AS col2 FROM tab0, tab2, tab2 AS cor0, tab1
----
81 values hashing to 3d45fa4e6631691e5f0e0ca86982e9c2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT col1 DIV - 29 FROM tab0
----
-2
-3
-3

skipif mysql # not compatible
query I rowsort label-4847
SELECT col1 / - 29 FROM tab0
----
-2
-3
-3

query I rowsort
SELECT - col0 * + ( col2 ) AS col0 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 39 col1 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to 9c9fbbb9cf0068f5900dff6ceb1046eb

query I rowsort
SELECT DISTINCT col1 * - 15 AS col2 FROM tab1
----
-150
-195
-390

query I rowsort
SELECT - - col1 * ( 3 ) FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT col2 * col1 * col0 AS col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT + ( col1 ) * - col2 * - 9 FROM tab0 cor0
----
25542
67158
873

query I rowsort
SELECT - col0 * col2 + + col1 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4855
SELECT - - 52 DIV col0 + + col1 AS col1 FROM tab1 AS cor0
----
10
13
43

skipif mysql # not compatible
query I rowsort label-4855
SELECT - - 52 / col0 + + col1 AS col1 FROM tab1 AS cor0
----
10
13
43

query I rowsort
SELECT ALL 18 FROM tab0, tab1 cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ( - 69 ) + - tab1.col0 AS col1 FROM tab1
----
-133
-149
-72

query I rowsort
SELECT + 11 * - col1 + + col2 FROM tab1 AS cor0
----
-232
-47
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 97 + + cor0.col0 col0 FROM tab0 AS cor0
----
-62
-73
-8

query I rowsort
SELECT DISTINCT + 97 + ( - col2 ) FROM tab0 AS cor0
----
15
64
96

query I rowsort
SELECT - 23 * - 53 + cor0.col1 + ( + col2 ) * - col0 AS col2 FROM tab2 AS cor0
----
-1766
-750
1061

query I rowsort
SELECT + ( 31 ) + - col1 FROM tab0 AS cor0
----
-55
-60
-66

query I rowsort
SELECT - col0 * + 39 + + col0 FROM tab1 AS cor0
----
-114
-2432
-3040

query I rowsort
SELECT - + 53 FROM tab0 cor0
----
-53
-53
-53

query I rowsort
SELECT ALL + cor0.col2 + ( col1 ) AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col0 * ( + col2 ) + - col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL + col1 + - 68 FROM tab2 AS cor0
----
-37
-51
-9

query I rowsort
SELECT - col0 * col0 + col1 AS col2 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT - col0 + ( 0 ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + - col0 + + cor0.col2 * + col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT + cor0.col1 + + ( - 55 * col1 ) AS col2 FROM tab1 AS cor0
----
-1404
-540
-702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4872
SELECT ALL - CAST( NULL AS DECIMAL ) / - 22 + + cor0.col0 * 79 * - col2 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4872
SELECT ALL - CAST ( NULL AS REAL ) / - 22 + + cor0.col0 * 79 * - col2 + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 89 AS col1 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT ALL - 46 * + 61 * - col1 AS col0 FROM tab1 AS cor0
----
28060
36478
72956

query I rowsort
SELECT + ( - col1 ) * col2 * + 23 AS col0 FROM tab0 cor0
----
-171626
-2231
-65274

query I rowsort
SELECT ALL - col2 * - cor0.col0 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL col1 * + 96 + col2 * col2 + col1 FROM tab2
----
3093
3736
6399

query I rowsort
SELECT ALL col1 + 88 AS col0 FROM tab2
----
105
119
147

query I rowsort
SELECT ALL + ( col1 ) + - col1 * - 6 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT DISTINCT col2 * + cor0.col0 AS col0 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4881
SELECT ALL - + CAST( NULL AS SIGNED ) + col0 * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4881
SELECT ALL - + CAST ( NULL AS INTEGER ) + col0 * col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + ( - col0 ) FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT cor0.col1 + col0 * + col2 AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT col1 * + ( tab2.col1 ) + + col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT DISTINCT - col1 - - col0 FROM tab1 cor0
----
-23
54
67

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 + ( cor0.col2 ) * - col0 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4888
SELECT DISTINCT col1 + + col0 DIV - ( 10 ) FROM tab2 AS cor0
----
10
31
52

skipif mysql # not compatible
query I rowsort label-4888
SELECT DISTINCT col1 + + col0 / - ( 10 ) FROM tab2 AS cor0
----
10
31
52

query I rowsort
SELECT DISTINCT + - col1 + - col0 * - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL - col1 * + col0 - ( + col2 ) AS col0 FROM tab1 cor0
----
-1136
-132
-697

onlyif mysql # use DIV operator for integer division
query I rowsort label-4891
SELECT DISTINCT ( col2 ) DIV + col0 AS col0 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-4891
SELECT DISTINCT ( col2 ) / + col0 AS col0 FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT ALL - col1 * + col0 + col2 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + col1 * cor0.col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + ( + col1 ) * col0 - + ( - col2 ) AS col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - 41 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 47b9ef972839428f4f71d9f5b0944edf

query I rowsort
SELECT ALL - 98 AS col1 FROM tab2
----
-98
-98
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4897
SELECT + 88 + col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
106
88
89

skipif mysql # not compatible
query I rowsort label-4897
SELECT + 88 + col2 / + col0 AS col1 FROM tab1 AS cor0
----
106
88
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + + col2 * ( col0 ) col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - col1 * col1 + 70 FROM tab1 AS cor0
----
-30
-606
-99

query I rowsort
SELECT DISTINCT ( + col0 ) + + 85 FROM tab2
----
163
164
92

query I rowsort
SELECT - col1 * col2 + col0 AS col0 FROM tab1
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4902
SELECT DISTINCT 68 * col2 + + CAST( NULL AS SIGNED ) + col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4902
SELECT DISTINCT 68 * col2 + + CAST ( NULL AS INTEGER ) + col0 FROM tab0
----
NULL

query I rowsort
SELECT ALL + col0 * - col0 + ( 27 ) AS col1 FROM tab1
----
-4069
-6373
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4904
SELECT col1 * col2 + col1 + col1 * tab0.col1 DIV - CAST( + 78 AS SIGNED ) FROM tab0
----
2830
74
7447

skipif mysql # not compatible
query I rowsort label-4904
SELECT col1 * col2 + col1 + col1 * tab0.col1 / - CAST ( + 78 AS INTEGER ) FROM tab0
----
2830
74
7447

query I rowsort
SELECT DISTINCT - col2 * - col2 + - ( - col2 ) * col0 FROM tab2
----
2704
4446
918

query I rowsort
SELECT - col0 + - col2 + cor0.col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + 38 * - col0 + col1 * + col2 FROM tab2
----
-1430
-2356
571

onlyif mysql # use DIV operator for integer division
query I rowsort label-4908
SELECT ALL - col1 + col2 + 15 DIV col1 FROM tab1
----
28
48
84

skipif mysql # not compatible
query I rowsort label-4908
SELECT ALL - col1 + col2 + 15 / col1 FROM tab1
----
28
48
84

query I rowsort
SELECT + 87 AS col0 FROM tab1
----
87
87
87

query I rowsort
SELECT ( + cor0.col2 ) FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT DISTINCT - col2 + + ( col2 + cor0.col0 ) * + cor0.col2 * 53 FROM tab0 AS cor0
----
1907
743084
99660

onlyif mysql # use DIV operator for integer division
query I rowsort label-4912
SELECT - col1 DIV + CAST( col1 AS SIGNED ) + col2 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-4912
SELECT - col1 / + CAST ( col1 AS INTEGER ) + col2 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT DISTINCT col1 + 96 FROM tab0 AS cor0
----
182
187
193

query I rowsort
SELECT ALL + col0 + + 22 FROM tab1 cor0
----
102
25
86

query I rowsort
SELECT DISTINCT + + col2 - - ( ( col1 ) ) * - col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + + col2 * col1 + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL col1 * - 45 * - col1 AS col1 FROM tab2 AS cor0
----
13005
156645
43245

query I rowsort
SELECT ALL col1 + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL - col1 * ( cor0.col2 ) + - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4920
SELECT DISTINCT col2 - - CAST( 76 AS SIGNED ) * col0 AS col2 FROM tab1 cor0
----
282
4921
6176

skipif mysql # not compatible
query I rowsort label-4920
SELECT DISTINCT col2 - - CAST ( 76 AS INTEGER ) * col0 AS col2 FROM tab1 cor0
----
282
4921
6176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4921
SELECT DISTINCT - col0 * + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4921
SELECT DISTINCT - col0 * + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4922
SELECT + col2 + + CAST( col2 AS SIGNED ) * col1 AS col1 FROM tab2 AS cor0
----
1560
684
864

skipif mysql # not compatible
query I rowsort label-4922
SELECT + col2 + + CAST ( col2 AS INTEGER ) * col1 AS col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - - cor0.col1 + + col1 + + cor0.col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT ALL + + cor0.col1 * 89 * cor0.col1 AS col2 FROM tab2 AS cor0
----
25721
309809
85529

query I rowsort
SELECT DISTINCT - 63 * col0 AS col0 FROM tab1 cor0
----
-189
-4032
-5040

query I rowsort
SELECT DISTINCT - - ( - col1 ) + cor0.col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ( + col0 ) * + col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4928
SELECT - col2 * - col1 DIV - cor0.col1 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-4928
SELECT - col2 * - col1 / - cor0.col1 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + 70 + cor0.col0 * + col0 AS col1 FROM tab2 AS cor0
----
119
6154
6311

query I rowsort
SELECT - 22 * col1 AS col2 FROM tab0 AS cor0
----
-1892
-2002
-2134

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4931
SELECT + CAST( - 18 AS SIGNED ) * + col2 AS col0 FROM tab0 AS cor0
----
-1476
-18
-594

skipif mysql # not compatible
query I rowsort label-4931
SELECT + CAST ( - 18 AS INTEGER ) * + col2 AS col0 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT DISTINCT - 34 + - col0 * col1 AS col2 FROM tab0 AS cor0
----
-2098
-3429
-8133

query I rowsort
SELECT col0 + + ( col0 ) FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT - 6 * + col2 AS col0 FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT DISTINCT + + 10 + + col0 AS col1 FROM tab2 AS cor0
----
17
88
89

query IIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 098e223d780e18b6582523fd6f55eec9

query I rowsort
SELECT ALL - - ( - 80 ) + col0 FROM tab1 AS cor0
----
-16
-77
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 24 * 95 FROM tab0, tab1 AS cor0
----
9 values hashing to 6cde0a92016cb5a01d191e8bebd78f5b

query I rowsort
SELECT + ( - 39 ) + col2 * - col1 FROM tab0 AS cor0
----
-136
-2877
-7501

query I rowsort
SELECT + 37 + - col2 FROM tab2
----
-1
10
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 57 + col2 col2 FROM tab2 cor0
----
83
84
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + ( - col1 ) col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + - 68 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT - col2 - - col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT 96 + - col0 * - ( 30 ) + - col0 * - col1 FROM tab2 cor0
----
3809
523
7038

query I rowsort
SELECT ALL + 29 AS col1 FROM tab1 AS cor0
----
29
29
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-4948
SELECT DISTINCT 77 DIV col0 AS col0 FROM tab2 AS cor0
----
0
11

skipif mysql # not compatible
query I rowsort label-4948
SELECT DISTINCT 77 / col0 AS col0 FROM tab2 AS cor0
----
0
11

query I rowsort
SELECT DISTINCT 53 * cor0.col0 FROM tab0, tab2 AS cor0
----
371
4134
4187

onlyif mysql # use DIV operator for integer division
query I rowsort label-4950
SELECT col1 DIV - 37 + 24 FROM tab1 cor0
----
24
24
24

skipif mysql # not compatible
query I rowsort label-4950
SELECT col1 / - 37 + 24 FROM tab1 cor0
----
24
24
24

query I rowsort
SELECT - - col1 + - ( ( col1 ) ) * col2 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - 24 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-24

query I rowsort
SELECT ALL 50 + 67 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to fffa05abe62cb539edc957636b354583

query I rowsort
SELECT ALL col1 * 31 AS col2 FROM tab1 cor0
----
310
403
806

query I rowsort
SELECT ALL col1 * - 70 + 74 * + col0 + cor0.col1 FROM tab0 AS cor0
----
-4103
-4158
307

query I rowsort
SELECT + col2 + + 66 AS col2 FROM tab1 AS cor0
----
120
123
162

query I rowsort
SELECT DISTINCT - col2 + 84 * col2 * + col2 FROM tab1 AS cor0
----
244890
272859
774048

query I rowsort
SELECT - col1 + - 75 * + col2 AS col0 FROM tab1 AS cor0
----
-4076
-4285
-7213

query I rowsort
SELECT col2 * 62 + col0 FROM tab0 AS cor0
----
2070
5173
97

query I rowsort
SELECT col0 + cor0.col0 + ( - col2 ) * - cor0.col1 FROM tab0 AS cor0
----
167
2886
7640

query I rowsort
SELECT DISTINCT - - col2 * + cor0.col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + col1 + - col1 * + col2 * - col2 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT ALL - - 60 AS col0 FROM tab0 cor0
----
60
60
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-4964
SELECT DISTINCT + 47 DIV 96 + - col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4964
SELECT DISTINCT + 47 / 96 + - col1 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4965
SELECT + CAST( NULL AS SIGNED ) + - cor0.col1 * - col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4965
SELECT + CAST ( NULL AS INTEGER ) + - cor0.col1 * - col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 60 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT DISTINCT + + 0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col2 * - col0 * - col1 + + col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
106240
40576
4221

query I rowsort
SELECT DISTINCT col0 + col1 * + col2 * + 80 + + cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
110919
45094
98672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 32 * col0 col0 FROM tab0 AS cor0
----
1120
2848
768

query I rowsort
SELECT DISTINCT + - col2 + col2 AS col0 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4972
SELECT ALL - CAST( + col2 AS SIGNED ) AS col0 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4972
SELECT ALL - CAST ( + col2 AS INTEGER ) AS col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - col2 * + col2 - - col1 * - cor0.col2 FROM tab0 AS cor0
----
-14186
-3927
-98

query I rowsort
SELECT ALL + - col1 * col2 + + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT + ( - tab1.col1 ) AS col2 FROM tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 50 * + cor0.col2 + cor0.col1 col1 FROM tab0 AS cor0
----
147
1736
4191

query I rowsort
SELECT col2 * col0 + 25 * col1 + col2 AS col0 FROM tab1
----
3955
8101
866

query I rowsort
SELECT - 10 * - col2 + - 11 - + col0 * - col1 FROM tab0
----
2383
3394
8908

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT col0 * col2 DIV + CAST( 31 + + col0 AS SIGNED ) FROM tab2
----
18
27
4

skipif mysql # not compatible
query I rowsort label-4979
SELECT col0 * col2 / + CAST ( 31 + + col0 AS INTEGER ) FROM tab2
----
18
27
4

query I rowsort
SELECT DISTINCT - 5 * + col1 + - 74 - col1 FROM tab2
----
-176
-260
-428

query I rowsort
SELECT DISTINCT + 50 - + col2 AS col2 FROM tab0
----
-32
17
49

query I rowsort
SELECT ALL + cor1.col1 * + 99 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to aa91a59559437f741c639d28c6832662

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 72 + + col2 col2 FROM tab2
----
-34
-45
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 + col1 col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + 55 + col0 FROM tab2 AS cor0
----
133
134
62

query I rowsort
SELECT + - ( 47 ) AS col1 FROM tab1 AS cor0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT 69 + - col0 FROM tab0 AS cor0
----
-20
34
45

query I rowsort
SELECT ALL + col2 * - 43 AS col0 FROM tab1 cor0
----
-2322
-2451
-4128

onlyif mysql # use DIV operator for integer division
query I rowsort label-4989
SELECT + col0 DIV cor0.col1 - + col0 FROM tab2 AS cor0
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-4989
SELECT + col0 / cor0.col1 - + col0 FROM tab2 AS cor0
----
-7
-75
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( + col0 ) col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT col0 + col0 * + col2 * ( col0 ) AS col1 FROM tab1 AS cor0
----
233536
489
614480

query I rowsort
SELECT ALL + 1 * - cor0.col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + col2 * - col1 * + 26 AS col1 FROM tab1 AS cor0
----
-14820
-32448
-36504

query I rowsort
SELECT - col0 * tab2.col2 + col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT 44 + - col1 FROM tab1
----
18
31
34

query I rowsort
SELECT + + 49 + - col1 FROM tab1 AS cor0
----
23
36
39

query I rowsort
SELECT ALL - + cor0.col2 * + col0 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT + - 23 + + col0 FROM tab2 AS cor0
----
-16
55
56

query I rowsort
SELECT DISTINCT + col0 + col2 * + ( - col0 ) * col1 AS col1 FROM tab2 AS cor0
----
-119574
-50955
-5852

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5000
SELECT ALL - cor0.col2 - - cor0.col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5000
SELECT ALL - cor0.col2 - - cor0.col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 41 + - col1 AS col2 FROM tab2 AS cor0
----
-18
10
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-5002
SELECT DISTINCT + col0 * col2 DIV - 55 FROM tab0
----
-132
-14
0

skipif mysql # not compatible
query I rowsort label-5002
SELECT DISTINCT + col0 * col2 / - 55 FROM tab0
----
-132
-14
0

query I rowsort
SELECT - tab0.col0 + + 5 * col1 FROM tab0
----
366
406
450

onlyif mysql # use DIV operator for integer division
query I rowsort label-5004
SELECT col2 DIV - ( col2 ) FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5004
SELECT col2 / - ( col2 ) FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5005
SELECT DISTINCT - col2 * ( - 60 ) DIV col1 FROM tab2 AS cor0
----
134
26
52

skipif mysql # not compatible
query I rowsort label-5005
SELECT DISTINCT - col2 * ( - 60 ) / col1 FROM tab2 AS cor0
----
134
26
52

query I rowsort
SELECT - col1 * 28 AS col0 FROM tab1 AS cor0
----
-280
-364
-728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 + + col0 + col1 col2 FROM tab1 AS cor0
----
116
52
97

query I rowsort
SELECT DISTINCT + + ( + 43 ) FROM tab2 cor0
----
43

query I rowsort
SELECT DISTINCT + - 61 AS col0 FROM tab0 AS cor0
----
-61

query I rowsort
SELECT 92 * col1 AS col0 FROM tab1 AS cor0
----
1196
2392
920

query I rowsort
SELECT ALL - 74 + cor0.col1 FROM tab0 cor0
----
12
17
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-5012
SELECT 27 * col2 - - cor0.col2 DIV ( + col1 + - cor0.col0 ) AS col1 FROM tab0 AS cor0
----
2255
27
891

skipif mysql # not compatible
query I rowsort label-5012
SELECT 27 * col2 - - cor0.col2 / ( + col1 + - cor0.col0 ) AS col1 FROM tab0 AS cor0
----
2255
27
891

query I rowsort
SELECT DISTINCT + 79 + ( + col2 ) AS col0 FROM tab2 AS cor0
----
105
106
117

query I rowsort
SELECT + col0 * cor0.col2 - col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5015
SELECT - - col0 + cor0.col0 DIV col2 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-5015
SELECT - - col0 + cor0.col0 / col2 FROM tab1 AS cor0
----
3
65
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 1 col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + col0 + + cor0.col1 * - col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT ALL - + cor0.col0 + + cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT - col2 + - ( col1 * - col0 ) FROM tab0
----
2031
3394
8017

query I rowsort
SELECT ALL - col1 * - ( col2 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 43 * - 32 FROM tab0 AS cor0
----
1376

onlyif mysql # use DIV operator for integer division
query I rowsort label-5022
SELECT DISTINCT - - 65 DIV cor0.col0 FROM tab1 AS cor0
----
0
1
21

skipif mysql # not compatible
query I rowsort label-5022
SELECT DISTINCT - - 65 / cor0.col0 FROM tab1 AS cor0
----
0
1
21

query I rowsort
SELECT ALL ( tab1.col1 + col2 ) FROM tab1
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5024
SELECT + cor0.col1 + col2 DIV col1 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5024
SELECT + cor0.col1 + col2 / col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - cor0.col0 * - col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL 93 * col0 + - col0 * ( + col1 ) FROM tab0
----
-140
168
178

query I rowsort
SELECT ALL + ( 65 ) * + col2 + + col0 * col2 FROM tab2
----
1944
3718
5472

query I rowsort
SELECT - 53 - col1 * - 92 FROM tab2 AS cor0
----
1511
2799
5375

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * + col2 - 84 col2 FROM tab1 AS cor0
----
2832
3165
9132

query I rowsort
SELECT + col1 + + col1 + - col0 AS col0 FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT - col1 * col2 + cor0.col2 + - col2 * - col2 FROM tab0 AS cor0
----
-1716
-656
-95

query I rowsort
SELECT ALL 52 + + 73 + + tab0.col2 FROM tab0
----
126
158
207

query I rowsort
SELECT ALL - tab2.col2 + - col1 + tab2.col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 89 + - col1 AS col2 FROM tab2
----
30
58
72

query I rowsort
SELECT + + col1 * 8 AS col0 FROM tab0 AS cor0
----
688
728
776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col2 col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL + - col0 * + ( col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + + col1 + ( 92 ) AS col2 FROM tab1 AS cor0
----
102
105
118

query I rowsort
SELECT ALL + col1 * + col1 + + 93 FROM tab2 AS cor0
----
1054
3574
382

query I rowsort
SELECT ALL col1 * - 33 FROM tab2 AS cor0
----
-1023
-1947
-561

query I rowsort
SELECT ALL + col2 + - col1 * + 23 * + 84 AS col1 FROM tab2
----
-113962
-32806
-59865

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col0 FROM tab0, tab1 AS cor0, tab1, tab1 cor1
----
10
13
26

query I rowsort
SELECT DISTINCT + 28 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2, tab0 AS cor3
----
28

query I rowsort
SELECT ALL + col0 * cor0.col0 + + 31 FROM tab2 AS cor0
----
6115
6272
80

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col1 + 44 AS col1 FROM tab2 AS cor0
----
103
61
75

query I rowsort
SELECT DISTINCT - col2 + - col0 * + 13 + - col1 AS col0 FROM tab2 AS cor0
----
-1082
-1099
-149

query I rowsort
SELECT DISTINCT + col0 + + ( col2 ) AS col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + col2 * 90 + + col0 FROM tab2 AS cor0
----
2418
2437
3499

query I rowsort
SELECT + + col0 * + col1 + - col2 AS col1 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT - 29 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
-29

query I rowsort
SELECT - col2 + col1 * 39 FROM tab2 AS cor0
----
1182
2275
625

query I rowsort
SELECT + - col1 * ( + col0 ) + col0 FROM tab1 AS cor0
----
-576
-75
-960

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab2 cor2
----
3645 values hashing to 7781e11d4a9fc844b7b93d320748f7c1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 * tab0.col2 - col0 * + col2 * tab0.col0 col1 FROM tab0
----
-1226
-20097
-656246

query I rowsort
SELECT ALL + col1 - col1 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 * - col0 + col2 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT tab0.col2 * - col2 - - col1 AS col1 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT + col1 * - col1 * tab2.col1 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT DISTINCT + tab1.col1 + + col2 - col0 * col2 AS col0 FROM tab1
----
-3581
-7571
-82

query I rowsort
SELECT col2 * - col1 * col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT col0 / - col1 + - col1 - - col2 AS col0 FROM tab0 WHERE NOT ( col0 ) NOT BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT DISTINCT col2 + + col1 * col2 AS col0 FROM tab2
----
1560
684
864

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( col2 ) NOT BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - tab1.col1 col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT col2 + + col1 * tab0.col2 FROM tab0
----
2871
7544
98

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 DISTINCT cor0.col1 * col1 * col1 col2 FROM tab1 cor0
----
1000
17576
2197

query I rowsort
SELECT cor2.col2 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT + 35 + col0 FROM tab2 cor0
----
113
114
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5071
SELECT DISTINCT + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5071
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5072
SELECT col2 + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5072
SELECT col2 + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + cor0.col0 * - ( cor0.col0 * + cor0.col1 ) FROM tab2 AS cor0
----
-106080
-1488
-358897

query I rowsort
SELECT - ( - col0 ) + col1 * - ( col2 ) + 61 * - col2 AS col1 FROM tab0 AS cor0
----
-123
-12375
-4827

query I rowsort
SELECT 4 * + col2 AS col2 FROM tab0 cor0
----
132
328
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) * + col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - 3 AS col2 FROM tab0, tab0 cor0
----
-3

query I rowsort
SELECT + col2 * + col2 + ( + col1 ) AS col2 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT ALL - - col1 + - col0 FROM tab0 cor0
----
2
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5080
SELECT - col0 + - CAST( col1 AS SIGNED ) col1 FROM tab1 AS cor0
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5080
SELECT - col0 + - CAST ( col1 AS INTEGER ) col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - col0 * 5 + - col0 + col2 FROM tab0 AS cor0
----
-111
-209
-452

query I rowsort
SELECT col1 * 55 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT - - col2 + cor0.col2 + 88 * col1 AS col1 FROM tab1 AS cor0
----
1336
2396
994

query I rowsort
SELECT ALL + col2 + - col0 * 64 FROM tab1 AS cor0
----
-138
-4039
-5024

query I rowsort
SELECT DISTINCT col2 * + cor0.col2 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL cor0.col1 + + 70 * + cor0.col2 + + col0 AS col0 FROM tab1 AS cor0
----
3809
4064
6813

query I rowsort
SELECT + col2 + col2 * col0 FROM tab2 cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col1 * 91 + + cor0.col2 * col2 col2 FROM tab0 AS cor0
----
15005
8828
8915

query I rowsort
SELECT 96 FROM tab2 cor0
----
96
96
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5090
SELECT - ( + cor0.col0 ) DIV col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5090
SELECT - ( + cor0.col0 ) / col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - - 71 + - col2 FROM tab2 AS cor0
----
33
44
45

query I rowsort
SELECT DISTINCT ( col0 ) + + col0 + - col1 FROM tab0 AS cor0
----
-27
-38
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5093
SELECT ALL CAST( col0 * col0 + + col2 AS SIGNED ) AS col1 FROM tab0
----
1226
609
8003

skipif mysql # not compatible
query I rowsort label-5093
SELECT ALL CAST ( col0 * col0 + + col2 AS INTEGER ) AS col1 FROM tab0
----
1226
609
8003

query I rowsort
SELECT ALL + 4 + col2 + - col2 FROM tab1 AS cor0
----
4
4
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT ALL + - col0 DIV col1 col2 FROM tab2 cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5095
SELECT ALL + - col0 / col1 col2 FROM tab2 cor0
----
-1
-4
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5096
SELECT DISTINCT + col2 * - col0 + CAST( 19 AS SIGNED ) col1 FROM tab2 AS cor0
----
-170
-2009
-2983

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5096
SELECT DISTINCT + col2 * - col0 + CAST ( 19 AS INTEGER ) col1 FROM tab2 AS cor0
----
-170
-2009
-2983

query I rowsort
SELECT ALL - ( - col1 ) * - 58 * - cor0.col0 + + col0 AS col0 FROM tab1 AS cor0
----
37184
4527
60400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 10 * - col1 col0 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT 93 + tab2.col2 FROM tab2
----
119
120
131

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 col0 FROM tab1
----
11
11
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 82 ) * + tab2.col2 col0 FROM tab2
----
2132
2214
3116

onlyif mysql # use DIV operator for integer division
query I rowsort label-5102
SELECT ALL col1 DIV + col0 + col1 * col0 FROM tab2
----
1343
221
4602

skipif mysql # not compatible
query I rowsort label-5102
SELECT ALL col1 / + col0 + col1 * col0 FROM tab2
----
1343
221
4602

query I rowsort
SELECT + col0 + col2 + tab2.col1 FROM tab2
----
134
163
65

query I rowsort
SELECT tab0.col0 * - col2 * + col2 - col2 * - col2 AS col0 FROM tab0
----
-25047
-34
-591712

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 + + col1 * + col1 col0 FROM tab0
----
14792
16562
18818

query I rowsort
SELECT DISTINCT tab0.col0 + - cor0.col0 FROM tab0, tab2, tab2 cor0
----
9 values hashing to ca8ec3f73e2033fdfd432059c411d9ca

onlyif mysql # use DIV operator for integer division
query I rowsort label-5107
SELECT - col2 + - col0 DIV col0 + + col1 AS col0 FROM tab2
----
-22
3
32

skipif mysql # not compatible
query I rowsort label-5107
SELECT - col2 + - col0 / col0 + + col1 AS col0 FROM tab2
----
-22
3
32

query I rowsort
SELECT DISTINCT + + col2 * - col1 * - col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL - 98 AS col1 FROM tab0
----
-98
-98
-98

query I rowsort
SELECT DISTINCT - 61 * col1 FROM tab1
----
-1586
-610
-793

query I rowsort
SELECT ALL tab1.col2 * 35 FROM tab1
----
1890
1995
3360

query I rowsort
SELECT ALL col0 * - 1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + col0 * - 96 FROM tab1
----
-288
-6144
-7680

query I rowsort
SELECT 50 * + col0 * col0 FROM tab2 AS cor0
----
2450
304200
312050

query I rowsort
SELECT ALL - - 53 FROM tab1 cor0
----
53
53
53

query I rowsort
SELECT + + col2 * - col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * col0 * + col1 col0 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT col2 - col2 * + col0 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL + cor0.col0 * - col0 - cor0.col0 FROM tab1 cor0
----
-12
-4160
-6480

query I rowsort
SELECT ALL cor0.col0 * + col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - ( tab0.col1 ) * - tab0.col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 + - cor0.col1 * col2 + + col2 FROM tab1 AS cor0
----
-1083
-2400
-2754

query I rowsort
SELECT DISTINCT - + 68 - + col0 AS col2 FROM tab2 AS cor0
----
-146
-147
-75

query I rowsort
SELECT DISTINCT col2 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT col0 + col1 * col1 + - col2 * col1 * - col2 AS col2 FROM tab1 AS cor0
----
120057
32654
76495

query I rowsort
SELECT DISTINCT - col0 * col0 - + col1 AS col0 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT DISTINCT col1 FROM tab1 AS cor0 WHERE ( col2 ) >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5128
SELECT + cor0.col1 DIV + col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5128
SELECT + cor0.col1 / + col0 AS col0 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5129
SELECT - col1 DIV - tab1.col1 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5129
SELECT - col1 / - tab1.col1 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT col0 AS col0 FROM tab0 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT DISTINCT - tab1.col2 * - col1 + col0 AS col1 FROM tab1
----
1328
1407
634

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL NOT IN ( + tab1.col1 + + tab1.col1 * - col2 )
----

query III rowsort
SELECT * FROM tab2 WHERE col0 * col1 * col0 BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT col1 + col2 * - col1 AS col2 FROM tab0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 - + col0 * + col0 col1 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT + col2 + - col1 * col0 AS col0 FROM tab1 WHERE ( NULL ) BETWEEN NULL AND col2 - - col0
----

query I rowsort
SELECT + cor0.col1 + cor0.col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + - col0 * col1 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT - - col0 * col2 + - col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-5140
SELECT ALL - col0 + - col0 * col1 DIV col0 AS col0 FROM tab0 AS cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-5140
SELECT ALL - col0 + - col0 * col1 / col0 AS col0 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5141
SELECT ALL col1 + col0 DIV cor0.col2 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-5141
SELECT ALL col1 + col0 / cor0.col2 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT ALL + + col1 + + col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL + col0 + - cor0.col1 * - col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 col1 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT col1 * + col1 + col1 FROM tab1
----
110
182
702

query I rowsort
SELECT col2 + - col2 * - col2 * col2 AS col0 FROM tab0
----
2
35970
551450

query I rowsort
SELECT ALL + col2 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + + col2 + - col0 - col0 AS col1 FROM tab0 AS cor0
----
-15
-69
-96

query I rowsort
SELECT DISTINCT col2 * col2 + col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT - tab1.col1 + col1 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col2 * + col1 + col0 AS col1 FROM tab0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 0 * + col0 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 44 AS col0 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT + tab0.col1 * + tab0.col1 * col1 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT - - col1 + 51 + col1 * 10 AS col0 FROM tab1 AS cor0
----
161
194
337

query I rowsort
SELECT + 27 + 18 * col2 AS col0 FROM tab1 cor0
----
1053
1755
999

query I rowsort
SELECT ALL + ( cor0.col2 ) + ( col0 ) AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - - 92 AS col1 FROM tab2 AS cor0
----
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5159
SELECT - col2 DIV + col1 + 55 * col2 + col0 AS col2 FROM tab1 cor0
----
2971
3194
5353

skipif mysql # not compatible
query I rowsort label-5159
SELECT - col2 / + col1 + 55 * col2 + col0 AS col2 FROM tab1 cor0
----
2971
3194
5353

query I rowsort
SELECT - - cor0.col0 + - col0 + + 69 * + col0 AS col0 FROM tab1 AS cor0
----
207
4416
5520

query I rowsort
SELECT ( - col2 ) * + tab1.col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5162
SELECT + CAST( + col2 AS SIGNED ) * - col2 * - col0 AS col0 FROM tab1
----
207936
737280
8748

skipif mysql # not compatible
query I rowsort label-5162
SELECT + CAST ( + col2 AS INTEGER ) * - col2 * - col0 AS col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT 70 FROM tab1, tab0 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT ALL - col1 * - tab1.col2 * + tab1.col2 AS col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT - col2 * 58 AS col1 FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT + tab0.col1 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5167
SELECT 89 + + col2 DIV - col0 FROM tab2
----
86
89
89

skipif mysql # not compatible
query I rowsort label-5167
SELECT 89 + + col2 / - col0 FROM tab2
----
86
89
89

query I rowsort
SELECT col2 + - 79 * ( + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-1305
-2422
-4635

onlyif mysql # use DIV operator for integer division
query I rowsort label-5169
SELECT DISTINCT tab2.col2 DIV 51 AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-5169
SELECT DISTINCT tab2.col2 / 51 AS col2 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5170
SELECT - col1 + + 91 DIV col0 FROM tab1 AS cor0
----
-12
-9
4

skipif mysql # not compatible
query I rowsort label-5170
SELECT - col1 + + 91 / col0 FROM tab1 AS cor0
----
-12
-9
4

query I rowsort
SELECT + - ( - 55 ) FROM tab2 AS cor0
----
55
55
55

query I rowsort
SELECT DISTINCT 16 + + col0 AS col0 FROM tab0 AS cor0
----
105
40
51

query I rowsort
SELECT ( col1 ) + col0 * col2 * col0 AS col0 FROM tab1 cor0
----
233482
512
614413

query I rowsort
SELECT col1 + + 96 AS col2 FROM tab0 AS cor0
----
182
187
193

query I rowsort
SELECT DISTINCT - ( col2 ) * - col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - ( + cor0.col1 ) * col1 + col1 * + 94 FROM tab2 AS cor0
----
1309
1953
2065

onlyif mysql # use DIV operator for integer division
query I rowsort label-5177
SELECT DISTINCT - + 12 + 78 DIV col1 AS col1 FROM tab2 AS cor0
----
-10
-11
-8

skipif mysql # not compatible
query I rowsort label-5177
SELECT DISTINCT - + 12 + 78 / col1 AS col1 FROM tab2 AS cor0
----
-10
-11
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 19 col1 FROM tab1 AS cor0
----
-19

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col2 FROM tab0 cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT + cor0.col2 - + col2 * + col1 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5181
SELECT DISTINCT - CAST( NULL AS DECIMAL ) + + 16 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5181
SELECT DISTINCT - CAST ( NULL AS REAL ) + + 16 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL - col2 * cor0.col1 * col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + col0 * + 61 FROM tab2
----
427
4758
4819

query I rowsort
SELECT 51 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT ( tab1.col0 ) AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + ( - col2 ) ) + - col0 * 71 col2 FROM tab2 cor0
----
-470
-5512
-5571

query I rowsort
SELECT ALL ( - 44 ) + + col2 FROM tab2 AS cor0
----
-17
-18
-6

query I rowsort
SELECT ALL + - 24 AS col1 FROM tab0 AS cor0
----
-24
-24
-24

query I rowsort
SELECT ALL + 33 * col0 * col1 + ( + col1 ) * col1 AS col0 FROM tab0 cor0
----
121444
275548
75508

query I rowsort
SELECT + - 94 * - cor0.col0 FROM tab2 AS cor0
----
658
7332
7426

onlyif mysql # use DIV operator for integer division
query I rowsort label-5191
SELECT 0 + col0 DIV - 11 + cor0.col1 DIV col1 AS col2 FROM tab2 AS cor0
----
-6
-6
1

skipif mysql # not compatible
query I rowsort label-5191
SELECT 0 + col0 / - 11 + cor0.col1 / col1 AS col2 FROM tab2 AS cor0
----
-6
-6
1

query I rowsort
SELECT - ( + cor0.col1 ) * + 95 + + col2 * + col2 AS col1 FROM tab1 AS cor0
----
2299
446
7981

query I rowsort
SELECT 7 * - col1 - + 63 FROM tab2
----
-182
-280
-476

query I rowsort
SELECT col0 + + 29 AS col0 FROM tab1
----
109
32
93

query I rowsort
SELECT col2 * col0 * col0 + col1 * - col0 FROM tab1
----
232832
408
613360

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5196
SELECT - col2 + - CAST( 7 + col2 AS SIGNED ) FROM tab0
----
-171
-73
-9

skipif mysql # not compatible
query I rowsort label-5196
SELECT - col2 + - CAST ( 7 + col2 AS INTEGER ) FROM tab0
----
-171
-73
-9

query I rowsort
SELECT + + col2 + - ( col1 ) AS col0 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT ALL + - cor0.col1 * + col1 + - cor0.col2 - - col2 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col1 * 24 AS col2 FROM tab2 AS cor0
----
1416
408
744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * col2 col0 FROM tab2 cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + col0 col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL col0 + + cor0.col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL - col2 * + ( col1 ) * + col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT col0 + - col2 + - col2 AS col1 FROM tab1 AS cor0
----
-105
-112
-50

query I rowsort
SELECT ALL - ( col0 ) * 63 AS col2 FROM tab2 cor0
----
-441
-4914
-4977

onlyif mysql # use DIV operator for integer division
query I rowsort label-5206
SELECT - ( col0 ) DIV 38 AS col1 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-5206
SELECT - ( col0 ) / 38 AS col1 FROM tab1 AS cor0
----
-1
-2
0

query I rowsort
SELECT - col2 * + 24 * + col2 + - col0 AS col2 FROM tab1
----
-221264
-69987
-78040

query I rowsort
SELECT DISTINCT + ( col2 ) * - 18 * - ( + col0 ) + - ( col2 * - cor0.col1 ) + - col2 AS col0 FROM tab2 AS cor0
----
38012
4212
54644

query I rowsort
SELECT DISTINCT + + 6 + col0 FROM tab0 AS cor0
----
30
41
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5210
SELECT DISTINCT + 95 DIV + col1 FROM tab2 AS cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-5210
SELECT DISTINCT + 95 / + col1 FROM tab2 AS cor0
----
1
3
5

query I rowsort
SELECT + - 4 * col2 * - 68 AS col1 FROM tab0 AS cor0
----
22304
272
8976

onlyif mysql # use DIV operator for integer division
query I rowsort label-5212
SELECT col1 + col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-5212
SELECT col1 + col0 / + col0 AS col2 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT DISTINCT + 4 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5214
SELECT - - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5214
SELECT - - CAST ( NULL AS REAL ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT 17 + col1 AS col2 FROM tab0 AS cor0
----
103
108
114

query I rowsort
SELECT ALL - cor0.col0 * + 36 * - 28 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c10708b66d32dc3f760353ebbcfed5ec

query I rowsort
SELECT ALL + col2 * col0 + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT + - 73 * col2 - - col2 FROM tab1 AS cor0
----
-3888
-4104
-6912

query I rowsort
SELECT + 39 * 68 + + col0 FROM tab2 AS cor0
----
2659
2730
2731

query I rowsort
SELECT DISTINCT - ( 94 ) + - col0 AS col1 FROM tab0 AS cor0
----
-118
-129
-183

query I rowsort
SELECT ALL ( 23 ) + + col0 AS col0 FROM tab1 AS cor0
----
103
26
87

query I rowsort
SELECT ALL ( + 87 ) * col2 + 34 AS col0 FROM tab0 AS cor0
----
121
2905
7168

query I rowsort
SELECT col0 + 22 * col0 FROM tab0
----
2047
552
805

query I rowsort
SELECT DISTINCT - ( - col2 ) * - cor0.col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - 91 + - 20 * - col1 FROM tab0 cor0
----
1629
1729
1849

query I rowsort
SELECT + + 42 + - col0 FROM tab1 AS cor0
----
-22
-38
39

query I rowsort
SELECT + 20 + + 73 FROM tab1 AS cor0
----
93
93
93

query I rowsort
SELECT + col2 * - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT - ( - tab0.col0 * - col1 ) AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 * + col1 * + col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT DISTINCT ( + 14 ) FROM tab2, tab1 AS cor0, tab1 cor1
----
14

query I rowsort
SELECT + col2 * col1 + + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - - 59 + cor0.col1 - col0 FROM tab1 cor0
----
-8
5
82

query I rowsort
SELECT - cor0.col1 + col1 * 41 AS col2 FROM tab0 AS cor0
----
3440
3640
3880

query I rowsort
SELECT ALL + 72 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT DISTINCT col2 + col0 + + tab0.col2 AS col1 FROM tab0
----
253
37
90

query I rowsort
SELECT ALL col0 * + 21 AS col0 FROM tab1 AS cor0
----
1344
1680
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5238
SELECT DISTINCT + cor0.col1 + - CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5238
SELECT DISTINCT + cor0.col1 + - CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - col1 + + col1 * - col0 * - col2 FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT DISTINCT - - col2 * + 30 FROM tab2 AS cor0
----
1140
780
810

query I rowsort
SELECT DISTINCT + ( ( + cor0.col0 ) ) + cor0.col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 85 * col2 col0 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT + 51 * col1 + + cor0.col1 AS col0 FROM tab1 cor0
----
1352
520
676

query I rowsort
SELECT - - col2 * cor0.col2 + - col2 AS col0 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5245
SELECT DISTINCT + + ( + ( col2 ) ) + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5245
SELECT DISTINCT + + ( + ( col2 ) ) + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5246
SELECT ALL + ( + col1 ) DIV col1 - CAST( col1 * col2 AS SIGNED ) col0 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5246
SELECT ALL + ( + col1 ) / col1 - CAST ( col1 * col2 AS INTEGER ) col0 FROM tab1 AS cor0
----
-1247
-1403
-569

query I rowsort
SELECT ALL + - 53 AS col2 FROM tab0 AS cor0
----
-53
-53
-53

query I rowsort
SELECT - cor0.col0 * + col0 + + col2 * - col2 FROM tab0 AS cor0
----
-1226
-14645
-1665

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 46 * + col1 - col2 col1 FROM tab2 AS cor0
----
-1453
-2740
-820

query I rowsort
SELECT - 8 * 47 AS col0 FROM tab2 AS cor0
----
-376
-376
-376

query I rowsort
SELECT ALL - - 83 AS col0 FROM tab0 AS cor0
----
83
83
83

query I rowsort
SELECT col1 * col2 * tab2.col1 AS col0 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT DISTINCT - col2 * col0 + - 83 FROM tab0
----
-118
-7381
-875

query I rowsort
SELECT DISTINCT col2 * ( col0 * - col2 ) + - col2 * + col1 FROM tab1
----
-10152
-208506
-738528

query I rowsort
SELECT + 39 + - col0 FROM tab2 AS cor0
----
-39
-40
32

query I rowsort
SELECT + ( col1 ) - - col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + 94 * - col0 FROM tab1
----
-282
-6016
-7520

query I rowsort
SELECT + + 43 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT ALL + col1 * col0 * 52 FROM tab1
----
33280
4056
54080

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT col0 * col1 - - col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 3eea7cef970c8ff51d71b8a23ee129bf

query I rowsort
SELECT ALL + + col2 * - 51 + 52 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-1013
2170
2730

query I rowsort
SELECT DISTINCT - col0 - + 78 FROM tab1 AS cor0
----
-142
-158
-81

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 * + CAST ( - col0 AS REAL ) FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL col0 + + 33 AS col0 FROM tab1 AS cor0
----
113
36
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5267
SELECT + col0 + CAST( NULL AS SIGNED ) * - col1 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5267
SELECT + col0 + CAST ( NULL AS INTEGER ) * - col1 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 70 * + col0 FROM tab0 AS cor0
----
-1680
-2450
-6230

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5269
SELECT + CAST( NULL AS SIGNED ) * - cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5269
SELECT + CAST ( NULL AS INTEGER ) * - cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 38 * + col2 + + col2 AS col1 FROM tab2 cor0
----
-1406
-962
-999

query I rowsort
SELECT ALL ( - col2 ) * - cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - - 93 + + 73 FROM tab1 AS cor0
----
166
166
166

query I rowsort
SELECT - + cor0.col1 * 12 + + col2 FROM tab0 AS cor0
----
-1010
-1163
-999

onlyif mysql # use DIV operator for integer division
query I rowsort label-5274
SELECT 65 DIV + col1 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-5274
SELECT 65 / + col1 FROM tab1 AS cor0
----
2
5
6

query I rowsort
SELECT + 1 + + ( cor0.col0 ) FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT + 20 * + col0 AS col0 FROM tab0 AS cor0
----
1780
480
700

query I rowsort
SELECT - + 5 AS col0 FROM tab1 AS cor0
----
-5
-5
-5

query I rowsort
SELECT ALL 75 FROM tab1, tab2 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 AS REAL ) AS col1 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5280
SELECT ALL + cor0.col1 DIV + col1 + cor0.col2 * col1 AS col1 FROM tab1 AS cor0
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-5280
SELECT ALL + cor0.col1 / + col1 + cor0.col2 * col1 AS col1 FROM tab1 AS cor0
----
1249
1405
571

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col0 * + col2 AS col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + - col0 - - col1 FROM tab0 cor0
----
2
62

query I rowsort
SELECT DISTINCT + col2 * - col1 + ( - cor0.col2 * col0 ) FROM tab2 AS cor0
----
-1026
-3562
-3648

query I rowsort
SELECT DISTINCT + - 64 * - cor0.col2 FROM tab2 cor0
----
1664
1728
2432

query I rowsort
SELECT DISTINCT ( ( col2 ) * 2 ) FROM tab2
----
52
54
76

query I rowsort
SELECT col2 + - col2 * + 37 AS col2 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT col0 - - col1 * + 31 * ( - col1 ) AS col0 FROM tab0
----
-229252
-256622
-291644

query I rowsort
SELECT - ( - col2 + ( col0 ) ) FROM tab0
----
-34
-7
9

query I rowsort
SELECT - col1 + - col0 * col2 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT - col2 + - 33 FROM tab0 AS cor0
----
-115
-34
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5291
SELECT ALL - col1 DIV + 10 FROM tab0 AS cor0
----
-8
-9
-9

skipif mysql # not compatible
query I rowsort label-5291
SELECT ALL - col1 / + 10 FROM tab0 AS cor0
----
-8
-9
-9

query I rowsort
SELECT ALL cor0.col2 - col0 * cor0.col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT + - 7 + col2 FROM tab0 AS cor0
----
-6
26
75

query I rowsort
SELECT ALL ( + 16 ) * cor0.col2 - 90 FROM tab0 AS cor0
----
-74
1222
438

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + + col0 col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL + ( 71 ) FROM tab1, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT DISTINCT 67 + - col2 * + tab1.col2 AS col2 FROM tab1
----
-2849
-3182
-9149

query I rowsort
SELECT DISTINCT - 3 * 30 + tab1.col0 * ( - 55 ) * + col0 FROM tab1
----
-225370
-352090
-585

query I rowsort
SELECT ( col2 + col2 ) * col0 * col2 FROM tab2
----
10206
105456
228152

onlyif mysql # use DIV operator for integer division
query I rowsort label-5300
SELECT DISTINCT + - ( cor0.col0 ) DIV col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5300
SELECT DISTINCT + - ( cor0.col0 ) / col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5302
SELECT ALL - col0 + 7 DIV + col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5302
SELECT ALL - col0 + 7 / + col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - - cor0.col2 * 77 FROM tab0 AS cor0
----
2541
6314
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col1 * - col1 col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL - col2 + col2 * + cor0.col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT col2 + - 13 * col2 FROM tab1 AS cor0
----
-1152
-648
-684

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col1 col2 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT ALL + - col1 * + 21 FROM tab1 AS cor0
----
-210
-273
-546

query I rowsort
SELECT DISTINCT col1 + + cor0.col1 * - col1 AS col1 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT + - col2 * ( - col2 ) + + cor0.col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL cor0.col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - - 51 AS col0 FROM tab0 cor0
----
51
51
51

query I rowsort
SELECT 27 + col0 FROM tab1 cor0
----
107
30
91

query I rowsort
SELECT DISTINCT 12 * + col0 AS col1 FROM tab1 AS cor0
----
36
768
960

query I rowsort
SELECT DISTINCT - - 25 * - col1 * + 35 AS col1 FROM tab2 AS cor0
----
-14875
-27125
-51625

query I rowsort
SELECT ( - col1 ) * - col0 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + + ( ( cor0.col0 ) ) FROM tab0, tab0 cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5318
SELECT ALL col2 DIV cor0.col0 + + col0 + - col2 FROM tab0 AS cor0
----
-8
34
7

skipif mysql # not compatible
query I rowsort label-5318
SELECT ALL col2 / cor0.col0 + + col0 + - col2 FROM tab0 AS cor0
----
-8
34
7

query I rowsort
SELECT DISTINCT + cor0.col0 * cor0.col1 AS col0 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5320
SELECT - - 48 * cor0.col0 + CAST( - 15 AS SIGNED ) FROM tab0 AS cor0
----
1137
1665
4257

skipif mysql # not compatible
query I rowsort label-5320
SELECT - - 48 * cor0.col0 + CAST ( - 15 AS INTEGER ) FROM tab0 AS cor0
----
1137
1665
4257

query I rowsort
SELECT DISTINCT 62 + + col2 FROM tab2
----
100
88
89

query I rowsort
SELECT DISTINCT col1 * col2 * tab2.col2 + col2 AS col2 FROM tab2
----
22626
24586
39910

onlyif mysql # use DIV operator for integer division
query I rowsort label-5323
SELECT col2 DIV ( + ( col1 ) ) FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5323
SELECT col2 / ( + ( col1 ) ) FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT col0 * - ( 37 ) * col1 + - ( col0 ) + - col0 AS col2 FROM tab0 AS cor0
----
-125685
-299841
-76416

query I rowsort
SELECT ALL - col0 + 28 * col0 FROM tab1 AS cor0
----
1728
2160
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5326
SELECT ALL col2 + col0 * 86 DIV col2 AS col0 FROM tab0
----
175
3011
95

skipif mysql # not compatible
query I rowsort label-5326
SELECT ALL col2 + col0 * 86 / col2 AS col0 FROM tab0
----
175
3011
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5327
SELECT col0 + col1 * - CAST( NULL AS SIGNED ) col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5327
SELECT col0 + col1 * - CAST ( NULL AS INTEGER ) col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 50 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT DISTINCT - tab2.col2 + col0 * + ( + 85 ) FROM tab2
----
568
6604
6677

query I rowsort
SELECT - + col2 + - 73 FROM tab1 AS cor0
----
-127
-130
-169

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col0 - cor0.col0 col0 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-5332
SELECT - col0 DIV col0 + - 52 * col2 FROM tab1 AS cor0
----
-2809
-2965
-4993

skipif mysql # not compatible
query I rowsort label-5332
SELECT - col0 / col0 + - 52 * col2 FROM tab1 AS cor0
----
-2809
-2965
-4993

query I rowsort
SELECT + col0 * 26 FROM tab0
----
2314
624
910

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

onlyif mysql # use DIV operator for integer division
query I rowsort label-5336
SELECT ALL - + col1 DIV cor0.col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-5336
SELECT ALL - + col1 / cor0.col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT col1 + ( + col0 ) FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - 35 * col1 * + col0 AS col1 FROM tab0
----
-118825
-283465
-72240

query I rowsort
SELECT DISTINCT + - 98 FROM tab2, tab0, tab1 AS cor0
----
-98

query I rowsort
SELECT - ( col1 ) + + col0 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL ( - ( + col2 ) ) * 46 - col1 FROM tab2 AS cor0
----
-1255
-1273
-1765

query I rowsort
SELECT cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + cor1.col0 * - 10 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 165c1d010d2c42bd2eff7cbbbaa985ef

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5344
SELECT DISTINCT + 6 + col1 * CAST( 5 AS SIGNED ) * col0 AS col0 FROM tab2 AS cor0
----
1091
23016
6721

skipif mysql # not compatible
query I rowsort label-5344
SELECT DISTINCT + 6 + col1 * CAST ( 5 AS INTEGER ) * col0 AS col0 FROM tab2 AS cor0
----
1091
23016
6721

query I rowsort
SELECT DISTINCT + cor0.col2 * col1 * - col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - 87 * cor0.col0 FROM tab2 AS cor0
----
-609
-6786
-6873

query I rowsort
SELECT 28 * + col1 + + 13 FROM tab0 AS cor0
----
2421
2561
2729

query I rowsort
SELECT DISTINCT + - 0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - 6 * col0 FROM tab1 AS cor0
----
-18
-384
-480

query I rowsort
SELECT DISTINCT - 13 * + col1 + + col1 + + 91 FROM tab2 AS cor0
----
-113
-281
-617

query I rowsort
SELECT DISTINCT - + col0 + + col0 * - col1 + + 20 FROM tab0 cor0
----
-2068
-3410
-8168

query I rowsort
SELECT 18 + col0 FROM tab2 AS cor0
----
25
96
97

query I rowsort
SELECT DISTINCT + 20 AS col0 FROM tab0 AS cor0
----
20

query I rowsort
SELECT ALL - col2 * + col2 * ( + col0 ) + col2 * 64 * - col2 AS col2 FROM tab1 AS cor0
----
-1327104
-195372
-415872

query I rowsort
SELECT ALL - 21 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to cdcb40c9e1bb9a33ce9167a0d2bac0b1

query III rowsort
SELECT * FROM tab1 WHERE + col2 IN ( + col0 )
----

query I rowsort
SELECT col0 + col1 * col1 FROM tab2
----
3559
368
968

query I rowsort
SELECT DISTINCT + col2 * tab1.col1 * col1 + + col0 FROM tab1
----
16304
36507
5764

query I rowsort
SELECT ALL - 70 AS col2 FROM tab1
----
-70
-70
-70

query I rowsort
SELECT DISTINCT + 56 * col1 FROM tab0
----
4816
5096
5432

onlyif mysql # use DIV operator for integer division
query I rowsort label-5361
SELECT + 21 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5361
SELECT + 21 / cor0.col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col2 * - col2 - col0 AS col2 FROM tab1
----
-2919
-3313
-9296

query I rowsort
SELECT ALL col0 - + col2 * + col2 AS col2 FROM tab2
----
-1365
-598
-722

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN NULL AND ( col1 )
----

query I rowsort
SELECT col1 * col2 * + col1 + + col1 AS col2 FROM tab2
----
10999
25978
90565

query I rowsort
SELECT - col2 * - col1 * col2 + + cor0.col1 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT col1 + - col2 * + tab0.col0 AS col0 FROM tab0
----
-706
-7207
62

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) BETWEEN NULL AND col1
----

query I rowsort
SELECT DISTINCT tab0.col2 * - tab0.col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - col0 * + tab1.col0 + + col0 * - col1 FROM tab1
----
-4736
-7440
-87

query I rowsort
SELECT + col0 - - tab1.col1 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT + tab2.col1 + col0 AS col2 FROM tab2 WHERE NOT NULL >= ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 col2 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - col2 + tab1.col2 * col0 AS col2 FROM tab1
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col1 col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL col1 * col0 AS col1 FROM tab2 WHERE NOT NULL > ( col0 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT - col2 + - col2 * - col1 IN ( col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - col1 AS col2 FROM tab1 WHERE col2 <> ( NULL )
----

query I rowsort
SELECT - col1 * col0 * + col0 + + col1 FROM tab2
----
-106080
-1488
-358897

query III rowsort
SELECT * FROM tab1 WHERE NULL IN ( tab1.col2 * col0 + col1 / col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 * - col1 col0 FROM tab0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-5382
SELECT col2 - + col0 DIV + col0 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5382
SELECT col2 - + col0 / + col0 FROM tab0
----
0
32
81

query I rowsort
SELECT col1 - - col1 * - col2 FROM tab2
----
-1475
-629
-806

query III rowsort
SELECT * FROM tab0 WHERE col1 + + col1 IN ( + col2 * col0 )
----

query I rowsort
SELECT ALL - ( col2 ) + col1 AS col0 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL - tab1.col0 * col0 + - col0 * - ( + tab1.col0 ) AS col2 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5387
SELECT + + CAST( NULL AS SIGNED ) + 61 * tab0.col2 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5387
SELECT + + CAST ( NULL AS INTEGER ) + 61 * tab0.col2 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT col2 + - 72 FROM tab0
----
-39
-71
10

query I rowsort
SELECT + tab2.col0 * + tab2.col2 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + 9 ) + + col1 col2 FROM tab2 cor0
----
26
40
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( cor0.col2 ) * col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 31 col1 FROM tab2 AS cor0
----
31
31
31

query I rowsort
SELECT col2 * + cor0.col1 + + ( col1 ) FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col2 ) col1 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + ( col0 ) * + col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT col0 - + cor0.col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL + 56 * + col1 AS col0 FROM tab2 AS cor0
----
1736
3304
952

query I rowsort
SELECT DISTINCT + 27 * + col2 + - 59 * - col0 - col2 FROM tab0 AS cor0
----
2091
2274
7383

onlyif mysql # use DIV operator for integer division
query I rowsort label-5399
SELECT DISTINCT - - col1 + + col2 DIV col0 AS col2 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-5399
SELECT DISTINCT - - col1 + + col2 / col0 AS col2 FROM tab0 AS cor0
----
87
91
97

query I rowsort
SELECT DISTINCT 66 + tab2.col0 * col2 FROM tab2
----
2094
255
3068

query I rowsort
SELECT 0 - - col1 AS col2 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL - + col0 + - col0 * 60 * ( col1 * - col0 ) AS col1 FROM tab2 AS cor0
----
21537282
6365741
91133

query I rowsort
SELECT - col1 * - col1 + 2 + - cor0.col0 FROM tab1 AS cor0
----
38
675
91

query I rowsort
SELECT DISTINCT - cor0.col0 * - col2 + - col1 AS col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - + 79 + - cor0.col1 FROM tab1 cor0
----
-105
-89
-92

query I rowsort
SELECT DISTINCT - col2 + ( + ( - cor0.col0 ) ) * cor0.col2 AS col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL - col2 + + 20 AS col0 FROM tab2 AS cor0
----
-18
-6
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5408
SELECT + col2 DIV 59 col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5408
SELECT + col2 / 59 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * ( 98 ) AS col1 FROM tab1 AS cor0
----
5292
5586
9408

query I rowsort
SELECT DISTINCT - 89 * col0 FROM tab0
----
-2136
-3115
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5411
SELECT ALL - + col1 / - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5411
SELECT ALL - + col1 / - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + cor0.col1 col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - col1 * - 70 + + 72 FROM tab2 AS cor0
----
1262
2242
4202

query I rowsort
SELECT ALL col2 * ( - cor0.col1 ) FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5415
SELECT - - CAST( NULL AS SIGNED ) + 46 + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5415
SELECT - - CAST ( NULL AS INTEGER ) + 46 + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( cor0.col0 ) * tab0.col2 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 54522441dbf7fb56e19a888572d1f6e3

query I rowsort
SELECT - col0 + - col0 * - col0 + 96 FROM tab0 AS cor0
----
1286
648
7928

query I rowsort
SELECT ALL 90 * 15 AS col1 FROM tab2 cor0
----
1350
1350
1350

onlyif mysql # use DIV operator for integer division
query I rowsort label-5419
SELECT DISTINCT + col2 DIV ( + col2 + col1 ) FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5419
SELECT DISTINCT + col2 / ( + col2 + col1 ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT ( 49 ) + col1 AS col1 FROM tab2 AS cor0
----
108
66
80

query I rowsort
SELECT DISTINCT 41 * col0 + - cor0.col2 FROM tab1 AS cor0
----
2567
3184
69

query I rowsort
SELECT 81 + col0 + col2 * - col0 AS col2 FROM tab0 AS cor0
----
-687
-7128
81

query I rowsort
SELECT DISTINCT - - col0 + + col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL + col2 - ( col0 * - col0 ) AS col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT DISTINCT col0 + - col2 * col2 AS col1 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT ( - col2 ) * tab1.col0 * col2 + - col1 + col0 * col2 FROM tab1
----
-204298
-729613
-8612

query I rowsort
SELECT - col2 * - col1 * col2 + cor0.col2 FROM tab1 cor0
----
119904
32547
75870

query I rowsort
SELECT 30 + cor0.col0 FROM tab0 AS cor0
----
119
54
65

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - tab0.col2 col0 FROM tab0, tab1, tab2 AS cor0
----
1
33
82

query I rowsort
SELECT ALL col0 * + tab0.col1 + + col1 * tab0.col1 FROM tab0
----
12804
16380
9460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col0 ) * + tab1.col0 + col1 * - tab1.col2 col0 FROM tab1
----
-1413
-4666
-7648

query I rowsort
SELECT DISTINCT ( - col0 ) * col2 * col0 + col0 * col2 AS col2 FROM tab1
----
-229824
-324
-606720

onlyif mysql # use DIV operator for integer division
query I rowsort label-5434
SELECT DISTINCT + col1 DIV - col0 + col1 AS col2 FROM tab2
----
17
27
59

skipif mysql # not compatible
query I rowsort label-5434
SELECT DISTINCT + col1 / - col0 + col1 AS col2 FROM tab2
----
17
27
59

query I rowsort
SELECT DISTINCT col1 + - 87 * col1 FROM tab2
----
-1462
-2666
-5074

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5436
SELECT CAST( NULL AS SIGNED ) * tab0.col1 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5436
SELECT CAST ( NULL AS INTEGER ) * tab0.col1 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( 14 ) + tab0.col0 * col0 AS col0 FROM tab0
----
1239
590
7935

query I rowsort
SELECT DISTINCT + - 73 * - col2 FROM tab0 AS cor0
----
2409
5986
73

query I rowsort
SELECT DISTINCT - col1 * - col2 + - col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT - 70 + col2 AS col2 FROM tab2 AS cor0
----
-32
-43
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 + col2 col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col0 * col0 * - col2 + + col1 FROM tab0 AS cor0
----
-1128
-18922
-649431

query I rowsort
SELECT DISTINCT + cor0.col2 * col1 + col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + - col0 * col0 - + col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT + - col0 * + col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col2 * col1 * - col0 + + col2 FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT DISTINCT - + 79 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-79

query I rowsort
SELECT ALL col0 * 7 * + col1 FROM tab1
----
4480
546
7280

query I rowsort
SELECT ALL + 98 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT DISTINCT col1 * tab2.col0 * tab2.col2 AS col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT tab0.col0 * + ( - col0 ) * col1 + col0 * - col2 FROM tab0
----
-118860
-50328
-728109

query I rowsort
SELECT DISTINCT - - col2 + - col0 * - 52 AS col0 FROM tab1 cor0
----
210
3385
4256

query I rowsort
SELECT DISTINCT - - col2 * - cor0.col0 - ( col2 ) FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-5454
SELECT ALL - col2 DIV + col1 - - 14 col2 FROM tab0 AS cor0
----
14
14
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5454
SELECT ALL - col2 / + col1 - - 14 col2 FROM tab0 AS cor0
----
14
14
14

query I rowsort
SELECT cor0.col0 + - col1 * - col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + col2 + - col2 * + 11 AS col1 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT DISTINCT + cor0.col0 * col1 + + col0 AS col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT ALL + col0 + ( + cor0.col2 ) - - col2 FROM tab2 AS cor0
----
130
155
61

query I rowsort
SELECT - col0 * 40 * col2 FROM tab2 AS cor0
----
-120080
-7560
-81120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5460
SELECT DISTINCT col2 + CAST( + 63 AS SIGNED ) + - col1 AS col2 FROM tab0 AS cor0
----
-33
10
54

skipif mysql # not compatible
query I rowsort label-5460
SELECT DISTINCT col2 + CAST ( + 63 AS INTEGER ) + - col1 AS col2 FROM tab0 AS cor0
----
-33
10
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5461
SELECT - cor0.col1 + - CAST( col2 AS SIGNED ) * - col0 * cor0.col0 AS col2 FROM tab0 cor0
----
1128
18922
649431

skipif mysql # not compatible
query I rowsort label-5461
SELECT - cor0.col1 + - CAST ( col2 AS INTEGER ) * - col0 * cor0.col0 AS col2 FROM tab0 cor0
----
1128
18922
649431

query I rowsort
SELECT ALL + 32 AS col1 FROM tab1 AS cor0
----
32
32
32

query I rowsort
SELECT DISTINCT - col2 + ( col1 * col1 ) AS col1 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT ALL + ( + ( col1 ) ) FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL + ( col1 ) * col1 + col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5466
SELECT - CAST( - col2 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-5466
SELECT - CAST ( - col2 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5467
SELECT DISTINCT col0 + col1 DIV + cor0.col1 col1 FROM tab0 AS cor0
----
25
36
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5467
SELECT DISTINCT col0 + col1 / + cor0.col1 col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT + - col1 + cor0.col2 * + col0 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE ( NULL ) IN ( col0 )
----

query I rowsort
SELECT - col0 - cor0.col2 * - col0 AS col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT cor0.col0 * + col2 + - col1 * - col2 * - col0 FROM tab0 AS cor0
----
-3360
-656820
-67320

query I rowsort
SELECT + col2 * + col0 + + col1 * col1 FROM tab0 AS cor0
----
15579
8188
9444

query I rowsort
SELECT - col1 FROM tab1 WHERE NOT NULL = ( NULL )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL >= ( + col0 + + col2 )
----

query I rowsort
SELECT DISTINCT col1 + - tab1.col1 * + col1 FROM tab1
----
-156
-650
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5476
SELECT + - col2 + col2 DIV + col2 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5476
SELECT + - col2 + col2 / + col2 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT + col2 + - cor0.col1 * col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - - col2 * - col2 + - col2 AS col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 col2 FROM tab2
----
66
66
66

query I rowsort
SELECT + col0 * - tab1.col0 + + col0 FROM tab1
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5481
SELECT DISTINCT - tab0.col0 * + col2 DIV col2 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5481
SELECT DISTINCT - tab0.col0 * + col2 / col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT + col1 FROM tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL OR NOT ( NULL ) BETWEEN ( + col1 ) AND - col2
----

query I rowsort
SELECT tab2.col2 * + col2 * col2 + - col0 FROM tab2
----
17498
19676
54793

query I rowsort
SELECT cor0.col2 * + col1 + + col2 AS col0 FROM tab0 cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5485
SELECT col2 + CAST( + col1 AS SIGNED ) * col0 AS col0 FROM tab1 cor0
----
1136
132
697

skipif mysql # not compatible
query I rowsort label-5485
SELECT col2 + CAST ( + col1 AS INTEGER ) * col0 AS col0 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT ALL + col0 * - col1 + - 79 * + col0 FROM tab0 AS cor0
----
-15130
-3960
-6160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5487
SELECT ALL col1 * + ( cor0.col0 * cor0.col1 ) + + CAST( NULL AS SIGNED ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5487
SELECT ALL col1 * + ( cor0.col0 * cor0.col1 ) + + CAST ( NULL AS INTEGER ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - cor0.col1 * ( - col1 ) FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + col2 + 53 * cor0.col1 FROM tab0 AS cor0
----
4591
4905
5142

query I rowsort
SELECT ALL - 24 * col1 AS col1 FROM tab2 cor0
----
-1416
-408
-744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * 97 col0 FROM tab2 AS cor0
----
2522
2619
3686

query I rowsort
SELECT + + col2 * ( - col1 * 58 ) AS col0 FROM tab0 AS cor0
----
-164604
-432796
-5626

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 43 col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5494
SELECT ALL - - 26 + col1 DIV + col0 FROM tab1 AS cor0
----
26
26
34

skipif mysql # not compatible
query I rowsort label-5494
SELECT ALL - - 26 + col1 / + col0 FROM tab1 AS cor0
----
26
26
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5495
SELECT CAST( NULL AS SIGNED ) + + tab1.col2 * col1 + col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5495
SELECT CAST ( NULL AS INTEGER ) + + tab1.col2 * col1 + col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * cor0.col1 - col1 * - 6 * col0 FROM tab1 AS cor0
----
1872
4410
7488

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 56 col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ( + col1 ) + col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - 3 * col0 + 78 AS col0 FROM tab1 AS cor0
----
-114
-162
69

query I rowsort
SELECT col1 * + col1 + col1 - col2 AS col1 FROM tab0 AS cor0
----
7449
8290
9505

query I rowsort
SELECT DISTINCT - tab0.col1 * - tab0.col1 - col2 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT ALL - 78 - + col0 * - 59 FROM tab0
----
1338
1987
5173

query I rowsort
SELECT + + col2 * ( ( + cor0.col1 ) ) AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - + cor0.col1 * + col0 * - col0 + - col2 - - 16 FROM tab0 AS cor0
----
118840
49519
720745

query I rowsort
SELECT + col0 * ( + 78 ) + col2 AS col0 FROM tab1 AS cor0
----
288
5049
6336

query I rowsort
SELECT - col2 * col2 * - cor0.col1 + - col2 FROM tab0 AS cor0
----
611802
93621
96

query I rowsort
SELECT DISTINCT col2 - - ( - cor0.col0 ) * col1 * + ( - col0 + + col0 ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col0 * + ( + col1 ) - + col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 + - ( - col0 ) col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - cor0.col2 ) col0 FROM tab1, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

onlyif mysql # use DIV operator for integer division
query I rowsort label-5511
SELECT + col0 * col1 * + ( cor0.col2 ) - - ( 69 ) DIV + col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

skipif mysql # not compatible
query I rowsort label-5511
SELECT + col0 * col1 * + ( cor0.col2 ) - - ( 69 ) / + col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5512
SELECT ALL col2 - CAST( - col2 AS SIGNED ) DIV col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-5512
SELECT ALL col2 - CAST ( - col2 AS INTEGER ) / col2 AS col1 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5513
SELECT + col0 DIV + col2 + col0 * - col2 * col0 FROM tab1 AS cor0
----
-233471
-486
-614400

skipif mysql # not compatible
query I rowsort label-5513
SELECT + col0 / + col2 + col0 * - col2 * col0 FROM tab1 AS cor0
----
-233471
-486
-614400

query I rowsort
SELECT - + col2 + - 17 * col2 AS col1 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT DISTINCT - - col0 * + col1 * 39 + cor0.col0 FROM tab0 AS cor0
----
132440
315950
80520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + col0 col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL col0 + 6 * col2 FROM tab2 AS cor0
----
169
234
307

query I rowsort
SELECT col1 + col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - - col2 - ( 7 ) FROM tab2 AS cor0
----
19
20
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-5521
SELECT + - col2 * col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5521
SELECT + - col2 * col0 / - col0 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + col1 + - col2 * - col0 FROM tab2
----
2087
220
3019

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab0 AS cor1
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT DISTINCT + col0 + - col0 AS col0 FROM tab2 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 2 col1 FROM tab2 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT - + col0 * col0 * - col2 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT 98 * - 46 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c4e0eca26e1daabf33a86b843526d8e2

query I rowsort
SELECT cor1.col1 * cor0.col2 AS col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6b6947fcb54b3e9529d0c75cfb5b2d32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 col2 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT col2 * col0 + col1 + 74 AS col2 FROM tab0 AS cor0
----
206
7463
952

query I rowsort
SELECT ALL - - ( 38 ) * - col2 + + col1 * + 92 AS col2 FROM tab0 AS cor0
----
5256
6658
8886

query I rowsort
SELECT + - ( - cor0.col1 ) + + col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5533
SELECT DISTINCT - 61 * ( col1 ) DIV + col2 + - col1 AS col1 FROM tab1 AS cor0
----
-20
-21
-55

skipif mysql # not compatible
query I rowsort label-5533
SELECT DISTINCT - 61 * ( col1 ) / + col2 + - col1 AS col1 FROM tab1 AS cor0
----
-20
-21
-55

query I rowsort
SELECT - 58 * + col2 - col1 AS col0 FROM tab2 AS cor0
----
-1567
-1597
-2221

query I rowsort
SELECT ALL - 96 * - col2 AS col1 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT ALL - cor0.col1 * + col0 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT 17 + + col0 FROM tab0 AS cor0
----
106
41
52

query I rowsort
SELECT - - 72 + col1 - - col0 AS col2 FROM tab1 AS cor0
----
101
146
165

query I rowsort
SELECT ALL + col0 * - 63 + col2 AS col0 FROM tab1 AS cor0
----
-135
-3975
-4944

query I rowsort
SELECT DISTINCT + 17 AS col2 FROM tab1 AS cor0
----
17

query I rowsort
SELECT DISTINCT + - cor0.col0 * + ( - col0 ) + - 92 AS col1 FROM tab1 AS cor0
----
-83
4004
6308

query I rowsort
SELECT + col1 + - ( - col1 ) * + col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT 4 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - 26 * - tab0.col1 col1 FROM tab0
----
2260
2455
2557

query I rowsort
SELECT col0 - - 35 * 52 AS col0 FROM tab1
----
1823
1884
1900

onlyif mysql # use DIV operator for integer division
query I rowsort label-5546
SELECT 80 DIV cor0.col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to e2794b931ab7a5b03271568cc564e553

skipif mysql # not compatible
query I rowsort label-5546
SELECT 80 / cor0.col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to e2794b931ab7a5b03271568cc564e553

query I rowsort
SELECT + 48 + + 62 + col2 FROM tab0 AS cor0
----
111
143
192

query I rowsort
SELECT DISTINCT - ( 75 ) * + col2 AS col1 FROM tab1 AS cor0
----
-4050
-4275
-7200

query I rowsort
SELECT ALL ( - col2 ) + col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT + 55 + - col1 AS col0 FROM tab1
----
29
42
45

query I rowsort
SELECT col2 * + col0 + 1 AS col2 FROM tab0
----
36
7299
793

query I rowsort
SELECT DISTINCT + col2 * 35 - + 83 * col0 AS col1 FROM tab0 AS cor0
----
-2870
-4517
-837

query I rowsort
SELECT ALL + + 46 + + col0 FROM tab0 cor0
----
135
70
81

query I rowsort
SELECT DISTINCT + cor0.col0 * tab0.col2 AS col0 FROM tab0, tab1, tab0 AS cor0
----
9 values hashing to 54522441dbf7fb56e19a888572d1f6e3

query I rowsort
SELECT DISTINCT 19 AS col1 FROM tab2, tab2 AS cor0, tab2 cor1
----
19

query I rowsort
SELECT DISTINCT cor0.col0 - 18 FROM tab2, tab0, tab2 cor0
----
-11
60
61

query I rowsort
SELECT ALL col0 * + col1 + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT + cor0.col0 * + 24 FROM tab0 cor0
----
2136
576
840

query I rowsort
SELECT DISTINCT 99 FROM tab1, tab0 AS cor0
----
99

query I rowsort
SELECT DISTINCT col2 * 51 AS col1 FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT ALL - col1 - + 11 AS col2 FROM tab0 AS cor0
----
-102
-108
-97

query I rowsort
SELECT DISTINCT - + cor0.col2 * 73 AS col1 FROM tab2 AS cor0
----
-1898
-1971
-2774

query I rowsort
SELECT ALL - col0 * + col2 + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - tab1.col2 * - 61 FROM tab1, tab0 cor0
----
9 values hashing to 4e743e0f52fe290648d09d671bc05229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col1 col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col2 * 12 FROM tab2 cor0
----
312
324
456

query I rowsort
SELECT DISTINCT col2 * - ( + col2 ) AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL + + col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5569
SELECT DISTINCT - cor0.col2 * + CAST( NULL AS DECIMAL ) + 88 / - col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5569
SELECT DISTINCT - cor0.col2 * + CAST ( NULL AS REAL ) + 88 / - col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + + cor0.col1 - + 24 FROM tab2 AS cor0
----
-7
35
7

query I rowsort
SELECT + 30 * col1 AS col0 FROM tab1
----
300
390
780

query I rowsort
SELECT - - 96 * + col2 FROM tab2 AS cor0
----
2496
2592
3648

query I rowsort
SELECT - col0 + cor0.col2 * 80 FROM tab2 AS cor0
----
2002
2153
2961

query I rowsort
SELECT col1 * cor0.col2 + - col2 * cor0.col0 FROM tab2 AS cor0
----
-2356
-494
648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + ( + ( - col1 ) ) col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col2 + - 63 AS col0 FROM tab2 AS cor0
----
-25
-36
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 * + col0 col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT + - cor0.col2 + ( col1 ) FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - cor0.col1 + 42 * col2 AS col0 FROM tab0 cor0
----
-55
1300
3353

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + col1 col2 FROM tab1 cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5581
SELECT - col1 DIV - 47 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5581
SELECT - col1 / - 47 - + cor0.col1 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + + col1 * - 42 - col0 * 79 FROM tab2 AS cor0
----
-1855
-6955
-8640

onlyif mysql # use DIV operator for integer division
query I rowsort label-5583
SELECT - col1 * col0 + cor0.col0 DIV - 60 FROM tab0 AS cor0
----
-2064
-3395
-8100

skipif mysql # not compatible
query I rowsort label-5583
SELECT - col1 * col0 + cor0.col0 / - 60 FROM tab0 AS cor0
----
-2064
-3395
-8100

query I rowsort
SELECT DISTINCT + col0 + + col2 * col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + col0 + col2 + - cor0.col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - - 6 + col0 * - ( cor0.col0 ) FROM tab0 AS cor0
----
-1219
-570
-7915

query I rowsort
SELECT ALL col2 * - col0 + 95 AS col0 FROM tab2 AS cor0
----
-1933
-2907
-94

query I rowsort
SELECT - 30 + - 81 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d4f73a52cfca99b0df979cd0eaff8cc7

query I rowsort
SELECT DISTINCT - 59 - col2 FROM tab0 AS cor0
----
-141
-60
-92

query I rowsort
SELECT - 77 + + col1 + + col0 AS col0 FROM tab2
----
-39
19
60

query I rowsort
SELECT ALL - col1 + - ( 88 ) * col1 AS col0 FROM tab2 AS cor0
----
-1513
-2759
-5251

query I rowsort
SELECT tab1.col0 - 44 FROM tab1, tab2 cor0
----
9 values hashing to dd91c463d30dfbae6c37135bdec4fc6a

query I rowsort
SELECT ALL + col1 * 29 FROM tab1 cor0
----
290
377
754

query I rowsort
SELECT + ( col0 ) * - col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + + 65 + 95 AS col2 FROM tab1 AS cor0
----
160
160
160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * - col1 col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + 20 + - col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1069
-6704
19

query I rowsort
SELECT + 3 + + col0 * - col0 AS col2 FROM tab1 AS cor0
----
-4093
-6
-6397

query I rowsort
SELECT ALL col0 * + tab2.col2 * col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT 10 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT ALL - 97 + col2 AS col0 FROM tab1 cor0
----
-1
-40
-43

query I rowsort
SELECT DISTINCT - 2 * + col1 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-5603
SELECT ALL - cor0.col2 DIV - col1 AS col2 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5603
SELECT ALL - cor0.col2 / - col1 AS col2 FROM tab2 cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 24 col2 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT cor0.col0 - cor0.col1 AS col2 FROM tab2, tab2 cor0, tab1 cor1
----
27 values hashing to 49c3ea57db097be5fdc5dd314554025d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5606
SELECT - + ( - col0 ) DIV + col1 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-5606
SELECT - + ( - col0 ) / + col1 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 83 ) + - col1 * - cor0.col1 col0 FROM tab2 AS cor0
----
206
3398
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 20 col1 FROM tab0
----
-1640
-20
-660

query I rowsort
SELECT + 58 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

onlyif mysql # use DIV operator for integer division
query I rowsort label-5610
SELECT ALL col2 DIV + tab2.col0 AS col1 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-5610
SELECT ALL col2 / + tab2.col0 AS col1 FROM tab2
----
0
0
3

query I rowsort
SELECT ( tab1.col1 ) + - col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - ( + cor0.col0 ) * + col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5613
SELECT 17 + col2 DIV - col1 FROM tab1
----
10
12
15

skipif mysql # not compatible
query I rowsort label-5613
SELECT 17 + col2 / - col1 FROM tab1
----
10
12
15

query I rowsort
SELECT ALL + col2 + - 87 * 12 * col2 AS col0 FROM tab1 cor0
----
-100128
-56322
-59451

query I rowsort
SELECT DISTINCT + cor0.col0 + + col0 + + col0 * col2 AS col1 FROM tab2 AS cor0
----
203
2184
3160

query I rowsort
SELECT DISTINCT col0 + + col0 * col1 AS col2 FROM tab0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-5617
SELECT ALL tab0.col0 DIV - tab0.col0 + col0 AS col2 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-5617
SELECT ALL tab0.col0 / - tab0.col0 + col0 AS col2 FROM tab0
----
23
34
88

query I rowsort
SELECT ALL - col1 + + tab1.col1 AS col2 FROM tab1
----
0
0
0

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 cor1, tab2 cor2, tab0 AS cor3
----
3645 values hashing to e3dd03163bf3bbebd049e3a988dfe640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5620
SELECT - col2 + - CAST( + col2 AS SIGNED ) AS col2 FROM tab2
----
-52
-54
-76

skipif mysql # not compatible
query I rowsort label-5620
SELECT - col2 + - CAST ( + col2 AS INTEGER ) AS col2 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT ALL - col2 + 23 AS col1 FROM tab0 AS cor0
----
-10
-59
22

query I rowsort
SELECT DISTINCT + + col1 * 99 AS col2 FROM tab1 cor0
----
1287
2574
990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5623
SELECT - col2 * ( ( + cor0.col0 ) ) + CAST( + col2 AS SIGNED ) * col1 + + 33 AS col1 FROM tab0 AS cor0
----
197
2079
95

skipif mysql # not compatible
query I rowsort label-5623
SELECT - col2 * ( ( + cor0.col0 ) ) + CAST ( + col2 AS INTEGER ) * col1 + + 33 AS col1 FROM tab0 AS cor0
----
197
2079
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5624
SELECT DISTINCT - - col1 + col0 DIV + col0 AS col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-5624
SELECT DISTINCT - - col1 + col0 / + col0 AS col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT col0 * + col1 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + col1 * + col2 + + 1 FROM tab1 AS cor0
----
1249
1405
571

query I rowsort
SELECT ALL col1 * 66 AS col0 FROM tab1 AS cor0
----
1716
660
858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5628
SELECT ALL col0 * CAST( NULL AS DECIMAL ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5628
SELECT ALL col0 * CAST ( NULL AS REAL ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + + cor0.col2 * + cor0.col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL ( - col1 ) * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - 82 FROM tab0 cor0
----
-82
-82
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5632
SELECT col2 DIV col1 AS col2 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5632
SELECT col2 / col1 AS col2 FROM tab2 cor0
----
0
0
2

query I rowsort
SELECT DISTINCT 4 * col1 FROM tab2 AS cor0
----
124
236
68

query I rowsort
SELECT + 90 * - col0 FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT - - col1 * col1 * 93 AS col0 FROM tab2 AS cor0
----
26877
323733
89373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5636
SELECT + + col0 + + 35 * ( - cor0.col0 ) * - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
105149
6622
71058

skipif mysql # not compatible
query I rowsort label-5636
SELECT + + col0 + + 35 * ( - cor0.col0 ) * - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
105149
6622
71058

query I rowsort
SELECT col2 + ( + col1 ) AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL col0 + + col2 - - col0 * + col2 * + col2 FROM tab0 AS cor0
----
26193
598607
71

query I rowsort
SELECT col2 * col0 + + 18 AS col0 FROM tab0
----
53
7316
810

query I rowsort
SELECT cor0.col2 * + 83 FROM tab2 AS cor0
----
2158
2241
3154

query I rowsort
SELECT + 53 + + col0 + col0 FROM tab2 AS cor0
----
209
211
67

query I rowsort
SELECT ALL - - 6 * col1 + + col2 AS col2 FROM tab0 AS cor0
----
549
583
628

onlyif mysql # use DIV operator for integer division
query I rowsort label-5643
SELECT ALL + col2 DIV col2 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5643
SELECT ALL + col2 / col2 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + 94 * col0 * col0 FROM tab0 AS cor0
----
115150
54144
744574

query I rowsort
SELECT ALL - + col2 + - 1 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT - 25 * col1 AS col2 FROM tab2 cor0
----
-1475
-425
-775

onlyif mysql # use DIV operator for integer division
query I rowsort label-5648
SELECT ALL + - col0 DIV 82 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5648
SELECT ALL + - col0 / 82 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + - ( + col1 ) + - col2 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - + ( col1 ) * col2 * + 48 AS col2 FROM tab2 AS cor0
----
-31008
-40176
-73632

query I rowsort
SELECT DISTINCT col2 + + col1 * col1 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT - tab1.col1 + + col0 AS col0 FROM tab1
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-5653
SELECT + col0 + - col2 DIV col1 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5653
SELECT + col0 + - col2 / col1 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) + col0 * 44 col1 FROM tab0 AS cor0
----
1142
1637
4007

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 87 + - ( col1 ) col0 FROM tab2 cor0
----
-104
-118
-146

query I rowsort
SELECT ( - 61 ) * - col2 + + col1 AS col1 FROM tab0
----
158
2099
5093

query I rowsort
SELECT - col0 * + col0 * + col2 + tab0.col2 AS col1 FROM tab0
----
-1224
-18975
-649440

query I rowsort
SELECT - + 53 * col2 AS col0 FROM tab0 cor0
----
-1749
-4346
-53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5659
SELECT ALL CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5659
SELECT ALL CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( col0 ) + - col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + col0 * col0 + col2 * + col0 AS col0 FROM tab2 AS cor0
----
238
8112
9243

query I rowsort
SELECT + cor0.col0 + cor0.col0 * - 77 FROM tab2 cor0
----
-532
-5928
-6004

query I rowsort
SELECT - - col2 * - col0 + + cor0.col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + 45 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5665
SELECT - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5665
SELECT - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT - 97 * + col2 AS col2 FROM tab1 AS cor0
----
-5238
-5529
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-5668
SELECT - col1 + col1 DIV col0 FROM tab1 AS cor0
----
-10
-13
-18

skipif mysql # not compatible
query I rowsort label-5668
SELECT - col1 + col1 / col0 FROM tab1 AS cor0
----
-10
-13
-18

onlyif mysql # use DIV operator for integer division
query I rowsort label-5669
SELECT DISTINCT - col2 + + col2 DIV - ( col1 ) + + ( 74 * + col0 ) AS col2 FROM tab2 AS cor0
----
491
5746
5806

skipif mysql # not compatible
query I rowsort label-5669
SELECT DISTINCT - col2 + + col2 / - ( col1 ) + + ( 74 * + col0 ) AS col2 FROM tab2 AS cor0
----
491
5746
5806

query I rowsort
SELECT ALL col0 * + col1 + + col2 AS col2 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT ALL + 69 + + ( col1 ) AS col1 FROM tab2 AS cor0
----
100
128
86

query I rowsort
SELECT ( 91 + tab2.col2 ) FROM tab2
----
117
118
129

query I rowsort
SELECT - + ( - col0 ) + col1 * - cor0.col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - - col2 + col2 * - col2 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT + col1 + - 65 AS col0 FROM tab1 AS cor0
----
-39
-52
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5676
SELECT ALL col2 * CAST( NULL AS SIGNED ) + 72 * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5676
SELECT ALL col2 * CAST ( NULL AS INTEGER ) + 72 * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - col2 * 39 FROM tab0
----
-1263
-3109
-4

query I rowsort
SELECT + col2 - 23 AS col2 FROM tab2
----
15
3
4

query I rowsort
SELECT - col0 * col1 * col2 + + col2 + - col1 FROM tab0
----
-3491
-664127
-68165

onlyif mysql # use DIV operator for integer division
query I rowsort label-5680
SELECT DISTINCT tab0.col0 DIV col2 - col0 DIV col0 FROM tab0
----
-1
0
34

skipif mysql # not compatible
query I rowsort label-5680
SELECT DISTINCT tab0.col0 / col2 - col0 / col0 FROM tab0
----
-1
0
34

query I rowsort
SELECT DISTINCT + col1 - col2 * + 75 AS col0 FROM tab2
----
-1891
-1994
-2833

query I rowsort
SELECT + col2 * + ( col0 ) + cor0.col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5683
SELECT DISTINCT + col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5683
SELECT DISTINCT + col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT 32 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5685
SELECT - CAST( NULL AS SIGNED ) * - tab0.col1 * - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5685
SELECT - CAST ( NULL AS INTEGER ) * - tab0.col1 * - col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 64 ) col0 FROM tab0
----
-64
-64
-64

query I rowsort
SELECT - col1 + + 71 + - col2 AS col1 FROM tab0 AS cor0
----
-102
-27
-48

query I rowsort
SELECT + - col0 + - cor0.col0 * - col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT - - 7 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT col1 * - cor0.col2 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT 39 AS col0 FROM tab1, tab0, tab1 AS cor0, tab0 AS cor1
----
81 values hashing to 9c9fbbb9cf0068f5900dff6ceb1046eb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5692
SELECT - cor0.col1 + - cor0.col1 * + CAST( col2 AS SIGNED ) FROM tab2 cor0
----
-1593
-663
-868

skipif mysql # not compatible
query I rowsort label-5692
SELECT - cor0.col1 + - cor0.col1 * + CAST ( col2 AS INTEGER ) FROM tab2 cor0
----
-1593
-663
-868

query I rowsort
SELECT + col2 + col1 * - col2 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT col2 + col1 * - 62 FROM tab1
----
-1558
-563
-710

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 + col2 col0 FROM tab1 AS cor0
----
119
77
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 8 col1 FROM tab0 AS cor0
----
-8
-8
-8

query I rowsort
SELECT ALL cor0.col0 + + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL col1 + - cor0.col0 * - 79 AS col1 FROM tab2 AS cor0
----
584
6221
6258

query I rowsort
SELECT ALL - col2 + cor0.col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT 78 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 64 * + col0 col1 FROM tab2
----
448
4992
5056

query I rowsort
SELECT ALL + col1 * ( col0 ) FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col0 * ( 26 ) FROM tab0 AS cor0
----
2314
624
910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 col0 FROM tab2
----
16
16
16

query I rowsort
SELECT ALL - col1 * + col1 * - 85 AS col1 FROM tab2
----
24565
295885
81685

query I rowsort
SELECT ALL cor0.col1 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL cor0.col0 * cor0.col0 + col2 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5709
SELECT DISTINCT - col1 * col2 + cor0.col1 + CAST( col0 * cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
-1300
-195
80

skipif mysql # not compatible
query I rowsort label-5709
SELECT DISTINCT - col1 * col2 + cor0.col1 + CAST ( col0 * cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
-1300
-195
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( - col1 ) * - cor0.col2 col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL - cor0.col0 + + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + 92 * - col1 + cor0.col2 * col1 FROM tab2 AS cor0
----
-2015
-3894
-918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5713
SELECT ALL col2 + + col1 + cor0.col0 * CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5713
SELECT ALL col2 + + col1 + cor0.col0 * CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + - col2 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT ALL - ( + col2 ) + + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + ( col0 ) + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - ( + col0 ) * cor0.col2 + ( - col0 ) FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT + + col1 * + ( cor0.col0 ) * - ( col1 ) AS col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) + - col2 AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5720
SELECT DISTINCT tab2.col0 - 96 DIV col0 FROM tab2
----
-6
77
78

skipif mysql # not compatible
query I rowsort label-5720
SELECT DISTINCT tab2.col0 - 96 / col0 FROM tab2
----
-6
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5721
SELECT DISTINCT col1 + + col0 DIV col0 - col0 AS col2 FROM tab2
----
-18
-61
25

skipif mysql # not compatible
query I rowsort label-5721
SELECT DISTINCT col1 + + col0 / col0 - col0 AS col2 FROM tab2
----
-18
-61
25

query I rowsort
SELECT ALL + - 20 * - col1 * + col1 FROM tab1 AS cor0
----
13520
2000
3380

onlyif mysql # use DIV operator for integer division
query I rowsort label-5723
SELECT ALL col2 DIV col0 + + col0 * tab1.col2 AS col1 FROM tab1
----
180
3648
7681

skipif mysql # not compatible
query I rowsort label-5723
SELECT ALL col2 / col0 + + col0 * tab1.col2 AS col1 FROM tab1
----
180
3648
7681

query I rowsort
SELECT - cor0.col0 * 13 + - col0 FROM tab2 AS cor0
----
-1092
-1106
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5725
SELECT DISTINCT + CAST( cor0.col2 AS SIGNED ) * + col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-5725
SELECT DISTINCT + CAST ( cor0.col2 AS INTEGER ) * + col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5726
SELECT - CAST( NULL AS SIGNED ) + col2 * - cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5726
SELECT - CAST ( NULL AS INTEGER ) + col2 * - cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col0 ) + + tab2.col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL + 59 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ALL - - col1 * col0 + - cor0.col0 * + col2 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT ALL col2 * col2 + col1 * col1 + - col1 FROM tab0 AS cor0
----
14914
8399
9313

query I rowsort
SELECT + col0 * 20 + - col2 FROM tab0 cor0
----
1698
447
699

query I rowsort
SELECT ALL col0 + 74 FROM tab1 AS cor0
----
138
154
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 13 col2 FROM tab1
----
-1248
-702
-741

query I rowsort
SELECT ALL + 56 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5735
SELECT DISTINCT ( + 5 ) * col0 + - ( cor0.col1 + col2 ) * CAST( ( - col2 ) AS SIGNED ) FROM tab2 AS cor0
----
1601
2485
2600

skipif mysql # not compatible
query I rowsort label-5735
SELECT DISTINCT ( + 5 ) * col0 + - ( cor0.col1 + col2 ) * CAST ( ( - col2 ) AS INTEGER ) FROM tab2 AS cor0
----
1601
2485
2600

query I rowsort
SELECT DISTINCT - 65 + - col2 * col0 * + col1 AS col0 FROM tab1 AS cor0
----
-36545
-4277
-99905

query I rowsort
SELECT ALL - ( + ( + cor0.col0 ) ) + ( + 84 ) - - cor0.col2 * - col2 FROM tab2 AS cor0
----
-1439
-652
-670

onlyif mysql # use DIV operator for integer division
query I rowsort label-5738
SELECT DISTINCT + 68 DIV col2 FROM tab0 AS cor0
----
0
2
68

skipif mysql # not compatible
query I rowsort label-5738
SELECT DISTINCT + 68 / col2 FROM tab0 AS cor0
----
0
2
68

query I rowsort
SELECT + + ( - 90 ) FROM tab2 AS cor0
----
-90
-90
-90

query I rowsort
SELECT ALL cor0.col1 - cor0.col1 * cor0.col1 FROM tab1 cor0
----
-156
-650
-90

query I rowsort
SELECT col2 * + ( col2 ) * ( + col1 ) FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL + - 57 + + col1 * col2 AS col2 FROM tab2 AS cor0
----
1477
589
780

query I rowsort
SELECT ALL + 65 * + 74 FROM tab1 cor0
----
4810
4810
4810

query I rowsort
SELECT - - ( - 33 ) FROM tab1 AS cor0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + 28 * col0 col2 FROM tab1 AS cor0
----
1782
2227
58

query I rowsort
SELECT + - cor0.col2 * col1 + - col0 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-15561
-3492
-4902

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5747
SELECT - CAST( col1 AS SIGNED ) * + col1 * + 29 + 4 FROM tab1 AS cor0
----
-19600
-2896
-4897

skipif mysql # not compatible
query I rowsort label-5747
SELECT - CAST ( col1 AS INTEGER ) * + col1 * + 29 + 4 FROM tab1 AS cor0
----
-19600
-2896
-4897

query I rowsort
SELECT - - 91 AS col0 FROM tab1 cor0
----
91
91
91

query I rowsort
SELECT 67 * + col2 FROM tab1 AS cor0
----
3618
3819
6432

query I rowsort
SELECT + + ( - col2 ) + + col0 * col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT + 27 * - col1 AS col0 FROM tab0 cor0
----
-2322
-2457
-2619

query I rowsort
SELECT - col2 * + col1 * cor0.col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + 72 * col1 + ( col2 ) * + tab2.col1 * tab2.col0 AS col1 FROM tab2
----
123900
52258
8091

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - ( cor0.col1 ) - + 71 * + col2 FROM tab2 AS cor0
----
-1905
-1948
-2715

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 * col1 col2 FROM tab2 AS cor0
----
1798
3422
986

query I rowsort
SELECT DISTINCT + ( + col2 ) + + ( - col2 ) * col2 * + col0 FROM tab0 AS cor0
----
-26103
-34
-598354

query I rowsort
SELECT - - 46 - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2018
-3349
-8053

query I rowsort
SELECT ALL - ( + col1 ) AS col0 FROM tab2 cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 62 col2 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT + cor0.col1 * col2 - - ( 34 ) * col0 AS col2 FROM tab2 AS cor0
----
1075
3332
4186

query I rowsort
SELECT + - cor0.col2 - - col0 FROM tab2 cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5763
SELECT ALL col2 + col2 * CAST( 36 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1406
962
999

skipif mysql # not compatible
query I rowsort label-5763
SELECT ALL col2 + col2 * CAST ( 36 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1406
962
999

query I rowsort
SELECT DISTINCT col1 * cor0.col0 + col1 * col1 * + col0 FROM tab2 AS cor0
----
24174
276120
6944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5765
SELECT + 8 + - cor0.col2 * ( col2 + + col2 ) DIV + ( - col1 ) FROM tab0 AS cor0
----
155
33
8

skipif mysql # not compatible
query I rowsort label-5765
SELECT + 8 + - cor0.col2 * ( col2 + + col2 ) / + ( - col1 ) FROM tab0 AS cor0
----
155
33
8

query I rowsort
SELECT DISTINCT - + 52 + + col1 FROM tab0 cor0
----
34
39
45

query I rowsort
SELECT DISTINCT + + cor0.col0 - ( col1 ) AS col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT DISTINCT - col0 - + col1 FROM tab2 cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5769
SELECT - - col0 DIV + ( col2 ) + - col0 AS col0 FROM tab1 AS cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-5769
SELECT - - col0 / + ( col2 ) + - col0 AS col0 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT + - col0 + + col0 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT 50 + + tab2.col1 FROM tab2
----
109
67
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5773
SELECT + 42 DIV 21 col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5773
SELECT + 42 / 21 col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 43 col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT - col2 + - col1 + - cor0.col1 FROM tab2 cor0
----
-144
-72
-89

query I rowsort
SELECT + + cor0.col1 + + 15 * 12 FROM tab1 AS cor0
----
190
193
206

query I rowsort
SELECT - + col2 + + col0 + + 0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT + + col0 * col0 + 43 * - cor0.col2 - - col2 FROM tab2 AS cor0
----
-1085
4645
4992

onlyif mysql # use DIV operator for integer division
query I rowsort label-5779
SELECT + col2 + + 33 DIV - 79 + col2 DIV + 89 AS col2 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5779
SELECT + col2 + + 33 / - 79 + col2 / + 89 AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + col2 + - cor0.col1 * 69 * col2 FROM tab2 AS cor0
----
-105820
-44536
-57726

query I rowsort
SELECT ALL 44 + col1 + - 25 FROM tab1
----
29
32
45

query I rowsort
SELECT + col0 * - col0 + col0 AS col2 FROM tab2
----
-42
-6006
-6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * 88 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 745dbe316202e59b0fdd0f07d929c4d1

query I rowsort
SELECT - tab1.col2 + tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 1c0f12b2ac8c8b522b92205460500f94

query I rowsort
SELECT + col2 - 24 FROM tab2 AS cor0
----
14
2
3

query I rowsort
SELECT + col1 * ( + col1 ) FROM tab2
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * + cor0.col2 col1 FROM tab2, tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - + col1 + col1 * col1 AS col2 FROM tab0 cor0
----
7310
8190
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5789
SELECT ( cor0.col2 ) + - col0 * CAST( col2 AS SIGNED ) col0 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5789
SELECT ( cor0.col2 ) + - col0 * CAST ( col2 AS INTEGER ) col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + 5 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 0 col1 FROM tab2
----
0
0
0

query I rowsort
SELECT 7 * - tab2.col0 AS col2 FROM tab2
----
-49
-546
-553

query I rowsort
SELECT - ( cor0.col2 ) * + col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + + col1 + + col0 * col0 AS col2 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - - col2 * - col2 - cor0.col1 FROM tab1 cor0
----
-2942
-3259
-9229

query I rowsort
SELECT ALL - - 41 AS col0 FROM tab1 AS cor0
----
41
41
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5797
SELECT + 6 + col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5797
SELECT + 6 + col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + col0 * 1 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + - 94 + col0 FROM tab0 AS cor0
----
-5
-59
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5800
SELECT CAST( NULL AS DECIMAL ) * col0 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5800
SELECT CAST ( NULL AS REAL ) * col0 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + ( cor0.col1 ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + ( col0 ) + 76 * col0 FROM tab2 AS cor0
----
539
6006
6083

onlyif mysql # use DIV operator for integer division
query I rowsort label-5803
SELECT - 87 DIV col1 FROM tab1 AS cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-5803
SELECT - 87 / col1 FROM tab1 AS cor0
----
-3
-6
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5804
SELECT ALL - ( col0 ) * col1 * - col1 + col2 * CAST( NULL AS SIGNED ) / + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5804
SELECT ALL - ( col0 ) * col1 * - col1 + col2 * CAST ( NULL AS INTEGER ) / + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + col1 + - col0 * + col2 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT 6 + + col1 AS col1 FROM tab0 AS cor0
----
103
92
97

query I rowsort
SELECT DISTINCT cor0.col1 + - 59 AS col0 FROM tab1 AS cor0
----
-33
-46
-49

query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 8 FROM tab0, tab1 cor0, tab2 AS cor1
----
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5810
SELECT tab2.col2 DIV - col1 AS col0 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-5810
SELECT tab2.col2 / - col1 AS col0 FROM tab2
----
-2
0
0

query I rowsort
SELECT ALL + + 57 FROM tab0 cor0
----
57
57
57

query I rowsort
SELECT ALL ( + col2 ) + col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5813
SELECT ALL col1 DIV 24 - col2 col0 FROM tab0
----
-30
-79
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5813
SELECT ALL col1 / 24 - col2 col0 FROM tab0
----
-30
-79
3

query I rowsort
SELECT - ( 20 ) + col2 AS col0 FROM tab0
----
-19
13
62

query I rowsort
SELECT col0 * - 75 AS col2 FROM tab1
----
-225
-4800
-6000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col1 * - col1 + - col0 col1 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT ( - col2 ) + col1 * + col0 AS col0 FROM tab0
----
2031
3394
8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 28 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT + ( 0 ) AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT 26 * - 42 FROM tab2, tab0 AS cor0, tab0 cor1, tab0 AS cor2
----
81 values hashing to 3254d29399eda4866afad954772535be

query I rowsort
SELECT - 72 + - col1 AS col0 FROM tab1 AS cor0
----
-82
-85
-98

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2, tab0 AS cor3
----
13122 values hashing to 01b247553a8eda280d50abc8047c3598

query I rowsort
SELECT ALL col0 + 89 AS col2 FROM tab0
----
113
124
178

query I rowsort
SELECT DISTINCT col0 + 83 AS col2 FROM tab1 AS cor0
----
147
163
86

query I rowsort
SELECT DISTINCT - cor0.col0 + + ( col1 ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + + col1 + col1 * col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ( col0 ) + - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT 84 + + col0 AS col0 FROM tab1 cor0
----
148
164
87

query I rowsort
SELECT ALL - + 90 * col0 AS col1 FROM tab2 AS cor0
----
-630
-7020
-7110

onlyif mysql # use DIV operator for integer division
query I rowsort label-5830
SELECT DISTINCT - col0 + col0 DIV - ( col0 ) FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-5830
SELECT DISTINCT - col0 + col0 / - ( col0 ) FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT ALL - + col0 * col0 + + col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - ( + cor0.col1 ) * col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT col0 + col2 * 29 AS col2 FROM tab2 AS cor0
----
1181
790
832

query I rowsort
SELECT DISTINCT - cor0.col0 + - col2 + - col0 FROM tab0 AS cor0
----
-260
-71
-81

query I rowsort
SELECT DISTINCT + - 76 + col2 AS col2 FROM tab0 AS cor0
----
-43
-75
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5836
SELECT ALL + col1 DIV cor0.col0 - 18 * + col2 FROM tab1 AS cor0
----
-1026
-1728
-964

skipif mysql # not compatible
query I rowsort label-5836
SELECT ALL + col1 / cor0.col0 - 18 * + col2 FROM tab1 AS cor0
----
-1026
-1728
-964

query I rowsort
SELECT DISTINCT + tab0.col0 * - ( col0 ) AS col0 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5838
SELECT + col2 DIV - tab1.col2 + col0 * col2 AS col2 FROM tab1
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-5838
SELECT + col2 / - tab1.col2 + col0 * col2 AS col2 FROM tab1
----
161
3647
7679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5839
SELECT ALL + - cor0.col2 * - CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-5839
SELECT ALL + - cor0.col2 * - CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col0 + + 51 FROM tab2 cor0
----
129
130
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5841
SELECT DISTINCT - CAST( NULL AS SIGNED ) - - col1 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5841
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - - col1 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - ( col0 ) * - cor0.col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + ( 54 ) - col0 * col0 * + 6 FROM tab1 AS cor0
----
-24522
-38346
0

query I rowsort
SELECT - 99 * + ( + col2 ) - + col2 FROM tab0 AS cor0
----
-100
-3300
-8200

query I rowsort
SELECT DISTINCT - col2 + - col2 * - col2 - - ( ( col2 ) ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + - ( + col1 ) * col2 + 21 * - col1 FROM tab1 AS cor0
----
-1521
-1950
-780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 33 * col1 * + col1 + col1 col2 FROM tab1 AS cor0
----
-22282
-3290
-5564

query I rowsort
SELECT 80 + col0 FROM tab2 cor0
----
158
159
87

query I rowsort
SELECT DISTINCT - + col2 + col0 * col0 FROM tab1 cor0
----
-45
4039
6304

onlyif mysql # use DIV operator for integer division
query I rowsort label-5850
SELECT ALL - - col0 DIV col2 + col2 AS col1 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-5850
SELECT ALL - - col0 / col2 + col2 AS col1 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT ALL - col2 + ( + col0 ) - col2 * col0 FROM tab2 AS cor0
----
-1976
-209
-2961

onlyif mysql # use DIV operator for integer division
query I rowsort label-5852
SELECT ALL + - col2 DIV col0 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2837
7462
97

skipif mysql # not compatible
query I rowsort label-5852
SELECT ALL + - col2 / col0 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2837
7462
97

query I rowsort
SELECT + col0 - col2 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL + tab0.col1 - + 80 AS col2 FROM tab0
----
11
17
6

query I rowsort
SELECT col0 + - 99 + col1 FROM tab0 AS cor0
----
11
33
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5856
SELECT + col1 * - CAST( NULL AS SIGNED ) + - col0 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5856
SELECT + col1 * - CAST ( NULL AS INTEGER ) + - col0 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 * 37 + col0 AS col1 FROM tab0 AS cor0
----
1330
3382
912

query I rowsort
SELECT + 82 FROM tab1, tab2 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col0 col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL + + col2 * + col0 AS col0 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5861
SELECT DISTINCT col2 DIV 4 AS col1 FROM tab1
----
13
14
24

skipif mysql # not compatible
query I rowsort label-5861
SELECT DISTINCT col2 / 4 AS col1 FROM tab1
----
13
14
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT col2 + col1 * + col0 AS col0 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT - 91 + - 57 * - tab1.col1 * col0 AS col2 FROM tab1
----
36389
4355
59189

query I rowsort
SELECT 67 + col0 FROM tab2
----
145
146
74

query I rowsort
SELECT DISTINCT + - cor0.col2 * + col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + + col1 * col1 + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + col1 + + col0 * cor0.col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - ( + col1 ) + - col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5870
SELECT DISTINCT col0 + - col1 * col0 + 62 DIV - cor0.col1 FROM tab2 AS cor0
----
-1267
-212
-4525

skipif mysql # not compatible
query I rowsort label-5870
SELECT DISTINCT col0 + - col1 * col0 + 62 / - cor0.col1 FROM tab2 AS cor0
----
-1267
-212
-4525

query I rowsort
SELECT DISTINCT + ( tab0.col2 ) + + tab0.col0 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5872
SELECT 38 DIV + col1 AS col2 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5872
SELECT 38 / + col1 AS col2 FROM tab2
----
0
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5873
SELECT DISTINCT tab1.col2 DIV col2 AS col0 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-5873
SELECT DISTINCT tab1.col2 / col2 AS col0 FROM tab1
----
1

query I rowsort
SELECT DISTINCT 79 * + col0 AS col2 FROM tab0 AS cor0
----
1896
2765
7031

query I rowsort
SELECT DISTINCT + - col0 + - col1 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT + 71 - - col1 * cor0.col2 * + col2 AS col0 FROM tab0 cor0
----
168
611955
93725

query I rowsort
SELECT ALL 81 * col1 + + ( col2 ) * + col1 AS col2 FROM tab2 AS cor0
----
2023
3348
6313

query I rowsort
SELECT + - ( + col1 ) AS col0 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5879
SELECT ( tab1.col2 ) * + CAST( NULL AS SIGNED ) - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5879
SELECT ( tab1.col2 ) * + CAST ( NULL AS INTEGER ) - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * 91 * - 17 - col2 AS col1 FROM tab1 cor0
----
-148608
-83592
-88236

query I rowsort
SELECT col1 * col1 - - col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL cor0.col1 - ( - col0 ) FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5883
SELECT DISTINCT - + col0 * col2 DIV - col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5883
SELECT DISTINCT - + col0 * col2 / - col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT cor0.col0 * 3 AS col0 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT ALL - col1 * col2 * - col1 FROM tab1 AS cor0
----
16224
36504
5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 * - col0 col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT - col1 * 92 * col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-123539
-19933
-423325

query I rowsort
SELECT ALL + cor0.col1 + col2 AS col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - 86 AS col0 FROM tab2
----
-86
-86
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5890
SELECT ALL - + CAST( col0 AS SIGNED ) + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-5890
SELECT ALL - + CAST ( col0 AS INTEGER ) + col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 + + col1 col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT 2 + + col1 * + col2 * 78 FROM tab0 AS cor0
----
221366
582038
7568

query I rowsort
SELECT - col1 * col0 + + col2 * ( 80 ) FROM tab2 cor0
----
-2522
1697
1943

onlyif mysql # use DIV operator for integer division
query I rowsort label-5894
SELECT CAST( col2 AS SIGNED ) DIV + col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5894
SELECT CAST ( col2 AS INTEGER ) / + col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + ( 72 ) * col1 AS col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT + + cor0.col1 + - col2 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5897
SELECT - col2 DIV - ( + col0 ) FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5897
SELECT - col2 / - ( + col0 ) FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL col2 * 84 * + tab1.col0 FROM tab1
----
13608
306432
645120

query I rowsort
SELECT col2 * 17 FROM tab0 AS cor0
----
1394
17
561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 47 col2 FROM tab0
----
136
71
82

query I rowsort
SELECT - - col0 + - col0 + - 78 FROM tab0 AS cor0
----
-78
-78
-78

query I rowsort
SELECT ALL + col1 * + ( col2 ) + + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL - col2 - cor0.col2 AS col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL cor0.col0 + - 41 AS col2 FROM tab0 AS cor0
----
-17
-6
48

query I rowsort
SELECT DISTINCT + col2 + - col2 * 10 FROM tab0 AS cor0
----
-297
-738
-9

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 * ( col2 ) AS col1 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5907
SELECT - + col0 DIV 14 + 57 * + col0 + + ( - 84 + col0 ) FROM tab1 cor0
----
3624
4551
90

skipif mysql # not compatible
query I rowsort label-5907
SELECT - + col0 / 14 + 57 * + col0 + + ( - 84 + col0 ) FROM tab1 cor0
----
3624
4551
90

query I rowsort
SELECT ALL - + col2 * 83 AS col0 FROM tab0 AS cor0
----
-2739
-6806
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5909
SELECT DISTINCT col0 * ( col0 ) + - col0 * - CAST( + col0 AS SIGNED ) + col2 FROM tab0 AS cor0
----
1185
15924
2451

skipif mysql # not compatible
query I rowsort label-5909
SELECT DISTINCT col0 * ( col0 ) + - col0 * - CAST ( + col0 AS INTEGER ) + col2 FROM tab0 AS cor0
----
1185
15924
2451

onlyif mysql # use DIV operator for integer division
query I rowsort label-5910
SELECT DISTINCT - - cor0.col2 DIV - col2 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5910
SELECT DISTINCT - - cor0.col2 / - col2 FROM tab1 cor0
----
-1

query I rowsort
SELECT ALL + col0 * + col0 + - cor0.col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT - + cor0.col0 + + cor0.col0 * + cor0.col0 AS col1 FROM tab2 cor0
----
42
6006
6162

query I rowsort
SELECT DISTINCT + col2 - 64 * + col1 AS col1 FROM tab1 AS cor0
----
-1610
-583
-736

query I rowsort
SELECT ALL - col0 * - 16 AS col0 FROM tab2 AS cor0
----
112
1248
1264

query I rowsort
SELECT DISTINCT col1 + + col2 - - col0 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5916
SELECT - CAST( NULL AS SIGNED ) * 88 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5916
SELECT - CAST ( NULL AS INTEGER ) * 88 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5917
SELECT ALL tab0.col0 + 49 * - col0 DIV col0 FROM tab0
----
-14
-25
40

skipif mysql # not compatible
query I rowsort label-5917
SELECT ALL tab0.col0 + 49 * - col0 / col0 FROM tab0
----
-14
-25
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col2 col0 FROM tab2, tab0 cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT - - col0 + col2 * ( - ( col1 ) ) + + col1 AS col2 FROM tab2 AS cor0
----
-1397
-550
-799

onlyif mysql # use DIV operator for integer division
query I rowsort label-5920
SELECT col1 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5920
SELECT col1 / cor0.col0 AS col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT cor0.col2 + cor0.col2 AS col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL 90 * + cor0.col2 AS col0 FROM tab0 cor0
----
2970
7380
90

query I rowsort
SELECT ALL - 91 + col0 FROM tab2 AS cor0
----
-12
-13
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5924
SELECT + col2 - + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-5924
SELECT + col2 - + col1 / col2 AS col0 FROM tab0 AS cor0
----
-96
31
81

query I rowsort
SELECT ALL + col1 * - ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col2 * - tab2.col2 * col2 FROM tab2
----
-17576
-19683
-54872

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 * col2 * + col0 col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT - col0 * col0 * ( + col1 ) FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT + col2 + - col1 - tab0.col1 FROM tab0
----
-100
-139
-193

query I rowsort
SELECT 32 * - col0 + ( - col0 ) - - col2 * 29 AS col0 FROM tab2
----
-1505
-1820
552

onlyif mysql # use DIV operator for integer division
query I rowsort label-5931
SELECT col0 + + col1 DIV col1 col1 FROM tab0 AS cor0
----
25
36
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5931
SELECT col0 + + col1 / col1 col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - + col2 + - col0 * col2 AS col2 FROM tab1 cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT col0 + ( cor0.col2 ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col1 * col1 + - ( - col1 ) - col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + + 14 * 78 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to be4a4c0ce91e3d0695820677835e2902

query I rowsort
SELECT col1 + - col0 * col0 + - col0 FROM tab2
----
-25
-6103
-6303

query I rowsort
SELECT ALL col2 + - col2 * col0 AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT ALL + col2 * col1 * - col1 + + tab2.col2 * col1 FROM tab2
----
-10336
-25110
-88972

onlyif mysql # use DIV operator for integer division
query I rowsort label-5939
SELECT col2 + col0 + 29 DIV col1 AS col0 FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-5939
SELECT col2 + col0 + 29 / col1 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT col2 + - 51 * tab2.col1 * + col0 FROM tab2
----
-11040
-234676
-68455

query I rowsort
SELECT - tab2.col1 + col0 * col2 FROM tab2
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col2 col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + 56 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT + + col0 * + col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col0 * ( + col2 * col1 ) AS col2 FROM tab2
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * cor0.col1 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - ( - tab1.col0 ) AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL ( col1 ) + - col2 * - ( cor0.col2 ) FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT + col1 + 59 * cor0.col0 - - col1 * - col2 AS col0 FROM tab1 cor0
----
-1201
3216
3485

query I rowsort
SELECT DISTINCT + 21 AS col2 FROM tab2
----
21

query I rowsort
SELECT ALL + ( + col1 ) * col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL col2 - - col0 * ( - 85 * col0 ) AS col1 FROM tab2 AS cor0
----
-4138
-517114
-530447

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + cor0.col1 + ( 29 ) col2 FROM tab1 cor0
----
129
198
705

query I rowsort
SELECT + + col2 * col1 + - 19 FROM tab1 AS cor0
----
1229
1385
551

query I rowsort
SELECT DISTINCT + - 12 + col1 FROM tab0 AS cor0
----
74
79
85

query I rowsort
SELECT + 23 + - col1 FROM tab1 AS cor0
----
-3
10
13

query I rowsort
SELECT - + col1 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - col0 * col0 + + 67 AS col0 FROM tab1 AS cor0
----
-4029
-6333
58

query I rowsort
SELECT DISTINCT - col1 + + col2 * - col0 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL + 39 * col2 + + ( - col0 ) AS col1 FROM tab1 AS cor0
----
2103
2159
3664

query I rowsort
SELECT DISTINCT - - 22 * col0 FROM tab2 AS cor0
----
154
1716
1738

query I rowsort
SELECT ALL - + col0 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - col1 - - col0 * col2 AS col0 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-5964
SELECT ( - col0 ) * + cor0.col0 DIV + ( col0 ) FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5964
SELECT ( - col0 ) * + cor0.col0 / + ( col0 ) FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL 42 + col0 AS col1 FROM tab1 AS cor0
----
106
122
45

query I rowsort
SELECT - 7 * - col2 AS col2 FROM tab0 AS cor0
----
231
574
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 3 col1 FROM tab1, tab1 cor0
----
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 60 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT ALL + col2 * col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL + col0 * cor0.col2 * - col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-5971
SELECT DISTINCT ( + cor0.col0 ) DIV col0 col0 FROM tab1 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5971
SELECT DISTINCT ( + cor0.col0 ) / col0 col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT ALL 5 FROM tab2, tab2 cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to 0da436460d6fcea5a1eb4b1d2219d7c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 col0 FROM tab2 AS cor0
----
56
56
56

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to f8426cd4d01ba96a72d7348574fbbc8e

query I rowsort
SELECT ( col1 ) + + col1 FROM tab0 AS cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 52 + + col0 col0 FROM tab2 AS cor0
----
130
131
59

query I rowsort
SELECT + 97 * + col0 + 85 AS col2 FROM tab1 AS cor0
----
376
6293
7845

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col0 AS REAL ) * col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT + 97 * 43 AS col0 FROM tab0
----
4171
4171
4171

onlyif mysql # use DIV operator for integer division
query I rowsort label-5980
SELECT + col0 DIV + col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5980
SELECT + col0 / + col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 6 col1 FROM tab0 AS cor0
----
-516
-546
-582

query I rowsort
SELECT DISTINCT + + cor0.col2 * + 50 AS col0 FROM tab0 AS cor0
----
1650
4100
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-5983
SELECT ALL - - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5983
SELECT ALL - - col2 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + + col1 col2 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT - ( + col1 + - col2 ) FROM tab2
----
-33
-4
21

query I rowsort
SELECT + tab2.col0 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5987
SELECT ALL col2 DIV 13 AS col2 FROM tab0
----
0
2
6

skipif mysql # not compatible
query I rowsort label-5987
SELECT ALL col2 / 13 AS col2 FROM tab0
----
0
2
6

query I rowsort
SELECT ALL + tab2.col2 * col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col0 * ( + col1 ) FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5990
SELECT col0 DIV + 92 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5990
SELECT col0 / + 92 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 74 col2 FROM tab2 AS cor0
----
1924
1998
2812

query I rowsort
SELECT ALL + ( - 51 ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5993
SELECT ALL - col1 + + CAST( NULL AS SIGNED ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5993
SELECT ALL - col1 + + CAST ( NULL AS INTEGER ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 95 * - 11 * col1 FROM tab2 cor0
----
-17765
-32395
-61655

query I rowsort
SELECT DISTINCT col1 + + cor0.col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - + col2 * 44 + + col0 AS col0 FROM tab2 AS cor0
----
-1066
-1181
-1593

query I rowsort
SELECT ALL + ( - col1 + + col2 ) AS col1 FROM tab1
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5998
SELECT + CAST( NULL AS DECIMAL ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5998
SELECT + CAST ( NULL AS REAL ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( - ( col1 ) ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - + 83 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT tab1.col0 + + col2 * - 72 FROM tab1
----
-3885
-4040
-6832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 46 col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT + ( + cor0.col1 ) * - col1 + + col0 * col1 + - col0 * 24 FROM tab0 AS cor0
----
-2318
-5908
-6854

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + cor0.col0 - col2 * - 1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT cor0.col2 * col2 + + 90 AS col0 FROM tab1 AS cor0
----
3006
3339
9306

query I rowsort
SELECT DISTINCT + + cor0.col0 * cor0.col2 AS col2 FROM tab0, tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 62 AS col2 FROM tab2, tab1 AS cor0, tab0 cor1
----
62

query I rowsort
SELECT + + col1 + ( + col2 + col1 ) FROM tab1 cor0
----
106
122
77

query I rowsort
SELECT DISTINCT + 20 * - col1 AS col0 FROM tab2 AS cor0
----
-1180
-340
-620

query I rowsort
SELECT + + 73 + - cor0.col2 * col1 FROM tab1 AS cor0
----
-1175
-1331
-497

query I rowsort
SELECT - ( + 71 ) + - tab2.col1 FROM tab2
----
-102
-130
-88

query I rowsort
SELECT + 35 * 66 AS col0 FROM tab2 AS cor0
----
2310
2310
2310

query I rowsort
SELECT - ( col2 ) * - col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + cor1.col0 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 52 - + 23 * - col1 col0 FROM tab2
----
1409
443
765

query I rowsort
SELECT - col1 + + 91 + col2 * col1 AS col2 FROM tab1
----
1326
1469
651

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 52 * + col1 * - col2 + 83 col1 FROM tab0 AS cor0
----
147659
388107
5127

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 49 * col2 col2 FROM tab2 AS cor0
----
1274
1323
1862

onlyif mysql # use DIV operator for integer division
query I rowsort label-6020
SELECT ALL + col1 + col2 + col0 DIV - col1 AS col1 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-6020
SELECT ALL + col1 + col2 + col0 / - col1 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL 0 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT + - col1 * - col2 - - col2 * col1 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT ALL + + col0 * col0 + - ( - col1 * - col2 ) AS col2 FROM tab0 AS cor0
----
-2262
1128
459

query I rowsort
SELECT DISTINCT - + 17 * + col0 AS col2 FROM tab2 AS cor0
----
-119
-1326
-1343

onlyif mysql # use DIV operator for integer division
query I rowsort label-6025
SELECT - + col2 DIV col0 + - 78 AS col1 FROM tab0 cor0
----
-78
-78
-79

skipif mysql # not compatible
query I rowsort label-6025
SELECT - + col2 / col0 + - 78 AS col1 FROM tab0 cor0
----
-78
-78
-79

query I rowsort
SELECT + col1 * col1 + 15 AS col1 FROM tab2 AS cor0
----
304
3496
976

query I rowsort
SELECT DISTINCT - + 10 AS col0 FROM tab0 AS cor0
----
-10

onlyif mysql # use DIV operator for integer division
query I rowsort label-6028
SELECT ALL + + col1 + + col0 DIV ( - col0 ) AS col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6028
SELECT ALL + + col1 + + col0 / ( - col0 ) AS col2 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL + 54 * col0 + col2 + + col2 FROM tab2 cor0
----
4264
432
4342

query I rowsort
SELECT col2 - - col0 * + col1 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - col2 + 52 * col1 AS col2 FROM tab2 cor0
----
1585
3042
846

query I rowsort
SELECT ALL + - cor0.col0 * + 28 + + col2 * + cor0.col0 FROM tab1 AS cor0
----
1856
5440
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6033
SELECT - col0 * CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6033
SELECT - col0 * CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 6 * + col1 * + col0 AS col0 FROM tab2 AS cor0
----
1302
27612
8058

query I rowsort
SELECT ALL - + cor0.col0 + - col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - tab0.col1 AS col0 FROM tab0, tab1 cor0, tab2 cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - 89 + + col0 AS col0 FROM tab1 AS cor0
----
-25
-86
-9

query I rowsort
SELECT ALL + cor0.col1 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL 53 * + col0 AS col2 FROM tab2 AS cor0
----
371
4134
4187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + - col1 col2 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT - 99 * - col2 * col1 AS col2 FROM tab2 AS cor0
----
151866
63954
82863

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6042
SELECT ALL + CAST( NULL AS SIGNED ) / 30 + + col1 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6042
SELECT ALL + CAST ( NULL AS INTEGER ) / 30 + + col1 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + ( - col0 ) ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - 90 * + ( col0 ) FROM tab0 AS cor0
----
-2160
-3150
-8010

query I rowsort
SELECT DISTINCT + + 29 * + 50 FROM tab1 AS cor0
----
1450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 18 col2 FROM tab1 AS cor0
----
-18

query I rowsort
SELECT DISTINCT + cor0.col1 * + 44 FROM tab0 AS cor0
----
3784
4004
4268

query I rowsort
SELECT + 26 + col0 * col0 FROM tab1 AS cor0
----
35
4122
6426

query I rowsort
SELECT ALL + - 84 AS col1 FROM tab2 AS cor0
----
-84
-84
-84

query I rowsort
SELECT ALL 34 * col0 FROM tab1 AS cor0
----
102
2176
2720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6051
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6051
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ( ( cor0.col0 ) ) * col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6053
SELECT ALL 94 DIV col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6053
SELECT ALL 94 / col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + col2 * ( + cor0.col1 * + col0 ) AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - 58 FROM tab0, tab1 AS cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT - + 43 AS col2 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT + col1 * + col2 * tab0.col0 FROM tab0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6058
SELECT + CAST( - col1 AS SIGNED ) * col0 + + col2 col2 FROM tab1
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6058
SELECT + CAST ( - col1 AS INTEGER ) * col0 + + col2 col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT - cor0.col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT cor0.col1 * - 35 + - col1 * col0 FROM tab1 AS cor0
----
-1495
-988
-990

query I rowsort
SELECT - col2 * 27 + cor0.col0 * col0 FROM tab1 cor0
----
-1449
2557
3808

query I rowsort
SELECT + col1 * ( - col1 ) + cor0.col0 * col0 FROM tab0 AS cor0
----
-360
-6820
-8184

query I rowsort
SELECT col0 * - col0 - col0 * - col0 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT tab1.col0 + 13 FROM tab1
----
16
77
93

query I rowsort
SELECT ALL + cor0.col0 + ( - col0 ) * + col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT - col1 * + col2 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + + col2 + col0 * - 46 FROM tab0 AS cor0
----
-1071
-1609
-4012

query I rowsort
SELECT ALL + ( - 73 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 47 - col2 col2 FROM tab0 AS cor0
----
-35
14
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-6070
SELECT ALL - - col1 DIV - col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6070
SELECT ALL - - col1 / - col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - + cor0.col0 * col0 + - col0 AS col0 FROM tab0 cor0
----
-1260
-600
-8010

query I rowsort
SELECT 44 * + col0 FROM tab2 AS cor0
----
308
3432
3476

query I rowsort
SELECT - 95 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6074
SELECT DISTINCT - + CAST( + col2 AS SIGNED ) + col2 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6074
SELECT DISTINCT - + CAST ( + col2 AS INTEGER ) + col2 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - 39 * col2 FROM tab2 AS cor0
----
-1014
-1053
-1482

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6076
SELECT - CAST( NULL AS DECIMAL ) * 87 * col2 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6076
SELECT - CAST ( NULL AS REAL ) * 87 * col2 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 7 + + col1 * + col1 FROM tab1 AS cor0
----
162
669
93

query I rowsort
SELECT DISTINCT + cor0.col2 + 9 FROM tab2 AS cor0
----
35
36
47

query I rowsort
SELECT - 12 * + col0 FROM tab1
----
-36
-768
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6080
SELECT col1 + + cor0.col2 DIV cor0.col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-6080
SELECT col1 + + cor0.col2 / cor0.col1 FROM tab1 AS cor0
----
15
20
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-6081
SELECT - 45 DIV col2 + - col1 col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6081
SELECT - 45 / col2 + - col1 col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + + 79 * - cor0.col2 + - col2 + col0 AS col0 FROM tab2 AS cor0
----
-2002
-2153
-2961

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) AS col2 FROM tab1, tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort
SELECT + ( - cor0.col1 ) * + col0 + CAST ( + 52 AS REAL ) + col2 / - ( col0 * col1 ) AS col0 FROM tab2 AS cor0
----
-1291
-165
-4550

query I rowsort
SELECT col0 * + col1 * col1 AS col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT - + col0 * cor0.col0 + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT + - 29 + + col0 AS col2 FROM tab2 AS cor0
----
-22
49
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 74 col2 FROM tab0
----
74
74
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-6089
SELECT cor0.col0 DIV + cor0.col2 + CAST( col1 AS SIGNED ) + + col2 * + col0 AS col0 FROM tab1 AS cor0
----
188
3659
7693

skipif mysql # not compatible
query I rowsort label-6089
SELECT cor0.col0 / + cor0.col2 + CAST ( col1 AS INTEGER ) + + col2 * + col0 AS col0 FROM tab1 AS cor0
----
188
3659
7693

query I rowsort
SELECT DISTINCT + + col1 * col0 + col0 + col2 FROM tab2 cor0
----
1460
251
4706

query I rowsort
SELECT - 94 * - tab1.col1 AS col0 FROM tab1
----
1222
2444
940

query I rowsort
SELECT ALL col2 + - col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT - col0 * - cor0.col2 * - col2 - - col2 AS col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT DISTINCT - col2 * 86 AS col1 FROM tab1 AS cor0
----
-4644
-4902
-8256

query I rowsort
SELECT - ( col2 ) * col0 + 73 FROM tab1
----
-3575
-7607
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6096
SELECT - CAST( NULL AS SIGNED ) FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6096
SELECT - CAST ( NULL AS INTEGER ) FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT ( + 24 ) * + cor0.col2 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT col1 + col2 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-24
51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 * + tab0.col2 col1 FROM tab0
----
1
35937
551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-6100
SELECT - tab1.col1 DIV - 2 FROM tab1
----
13
5
6

skipif mysql # not compatible
query I rowsort label-6100
SELECT - tab1.col1 / - 2 FROM tab1
----
13
5
6

query I rowsort
SELECT + col1 * 2 + col1 * col1 * + col1 - - col0 AS col2 FROM tab0 AS cor0
----
636252
753842
912902

onlyif mysql # use DIV operator for integer division
query I rowsort label-6102
SELECT + cor0.col2 * + cor0.col0 + col1 + + 8 DIV col1 FROM tab0 AS cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-6102
SELECT + cor0.col2 * + cor0.col0 + col1 + + 8 / col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT - + cor0.col0 - + col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - 67 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to fbe03b15d6b951410b38f7e98895006f

query I rowsort
SELECT DISTINCT - tab2.col2 + + col1 * 98 FROM tab2
----
1628
3011
5756

query I rowsort
SELECT 41 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT ( col2 ) * tab2.col0 * col0 AS col1 FROM tab2
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 30 - + col0 * - col1 col0 FROM tab1 AS cor0
----
1010
48
610

query I rowsort
SELECT col1 + - col1 * - col0 AS col2 FROM tab1
----
104
1053
650

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL BETWEEN + col2 AND NULL
----

query I rowsort
SELECT DISTINCT + col1 * - col1 - - col1 * + col2 FROM tab0
----
-4558
-819
-9312

query I rowsort
SELECT + col2 * col2 + - tab2.col2 * col2 - + col0 * + tab2.col1 FROM tab2
----
-1343
-217
-4602

query III rowsort
SELECT * FROM tab0 WHERE NULL BETWEEN col1 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col2 - - col0 col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + col1 + col0 + col2 AS col1 FROM tab1
----
131
189
83

query I rowsort
SELECT + col0 AS col0 FROM tab2 WHERE NOT col0 / col0 NOT IN ( - col2 )
----

query I rowsort
SELECT tab0.col2 + col1 AS col1 FROM tab0 WHERE + col0 NOT IN ( + col1 + + col2 )
----
119
173
98

query I rowsort
SELECT - col1 * col1 * col1 FROM tab1
----
-1000
-17576
-2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-6119
SELECT col2 DIV + col0 + tab1.col1 * + col0 FROM tab1 WHERE + col1 * col1 - col1 NOT IN ( col0 )
----
1041
640
96

skipif mysql # not compatible
query I rowsort label-6119
SELECT col2 / + col0 + tab1.col1 * + col0 FROM tab1 WHERE + col1 * col1 - col1 NOT IN ( col0 )
----
1041
640
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * - tab0.col0 * - tab0.col2 col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT ALL tab0.col1 - - tab0.col0 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT + col0 - + tab0.col1 * - col1 * - col1 AS col1 FROM tab0
----
-636032
-753482
-912638

query I rowsort
SELECT ALL col1 AS col2 FROM tab2 WHERE ( NULL ) <> NULL
----

query I rowsort
SELECT DISTINCT + col1 + col1 * + col2 AS col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT + col1 + - col1 * + col2 AS col2 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT - col2 AS col2 FROM tab0 WHERE col1 * col0 IN ( + col1 * + col1 * + col1 )
----

query I rowsort
SELECT - + col1 * cor0.col1 * col0 + col0 AS col0 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT ALL - tab0.col1 + + col0 * + col1 FROM tab0
----
1978
3298
8008

query III rowsort
SELECT * FROM tab1 WHERE NOT + col1 * + tab1.col1 <> col0 * + col1
----

query I rowsort
SELECT DISTINCT + col0 FROM tab1 WHERE NULL NOT IN ( - col1 * col2 + - col0 )
----

query I rowsort
SELECT col2 + col1 * + col2 FROM tab1 AS cor0
----
1344
1458
627

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT col1 NOT IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6133
SELECT ALL - col1 DIV col1 + col1 - - col0 FROM tab0 AS cor0
----
109
131
179

skipif mysql # not compatible
query I rowsort label-6133
SELECT ALL - col1 / col1 + col1 - - col0 FROM tab0 AS cor0
----
109
131
179

query I rowsort
SELECT DISTINCT + col0 * col1 * col1 + cor0.col2 - col0 * + col0 * + col0 FROM tab2 AS cor0
----
-203008
-470170
6411

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 col0 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT DISTINCT - col2 * 74 FROM tab1 AS cor0
----
-3996
-4218
-7104

skipif mysql # not compatible
query I rowsort
SELECT - col0 + + CAST ( col0 AS REAL ) * col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT - col2 * - ( cor0.col0 ) + - col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL - col1 * + col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + cor0.col0 * - col1 * col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * ( + col0 ) * cor0.col1 col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col1 * 4 FROM tab1 AS cor0
----
104
40
52

query I rowsort
SELECT + + cor0.col2 * ( + col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + 53 AS col0 FROM tab0 AS cor0
----
-53
-53
-53

query I rowsort
SELECT DISTINCT - 18 + - col2 * col1 FROM tab2 AS cor0
----
-1552
-664
-855

query I rowsort
SELECT DISTINCT col0 * + 71 AS col0 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT ALL + 65 * - ( + col1 ) - 67 AS col2 FROM tab2 AS cor0
----
-1172
-2082
-3902

query I rowsort
SELECT + 80 FROM tab2, tab0 cor0, tab2 AS cor1, tab1 cor2
----
81 values hashing to 2815a2e064e1815ac3a10bcd8b0ab19c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6149
SELECT tab1.col1 + CAST( 14 + col0 AS SIGNED ) FROM tab1
----
107
43
88

skipif mysql # not compatible
query I rowsort label-6149
SELECT tab1.col1 + CAST ( 14 + col0 AS INTEGER ) FROM tab1
----
107
43
88

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT 17 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 71801088bb30ca6eac036729ebfbbace

query I rowsort
SELECT col2 * ( tab1.col0 ) - + col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL + 57 FROM tab2, tab2 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT DISTINCT - - 2 AS col1 FROM tab1 AS cor0
----
2

query I rowsort
SELECT col1 * + col1 + 57 + col1 FROM tab0 AS cor0
----
7539
8429
9563

query I rowsort
SELECT DISTINCT - - ( - col0 ) * ( col0 ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + 78 * col1 FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT col1 - + cor0.col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT col1 * - col0 + 69 FROM tab0 cor0
----
-1995
-3326
-8030

query I rowsort
SELECT col2 * tab1.col0 + col1 AS col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT col1 * col0 * + col0 + - col2 * + col2 * + col2 + + col0 AS col2 FROM tab0
----
118859
13623
169532

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 10 col0 FROM tab2 AS cor0
----
10
10
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 + - col2 col0 FROM tab0 AS cor0
----
-253
-37
-90

query I rowsort
SELECT DISTINCT col2 * - tab0.col2 + + col1 AS col0 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT + 75 + col0 AS col1 FROM tab0
----
110
164
99

query I rowsort
SELECT DISTINCT - col1 + + col1 * + col0 + - tab2.col0 * + col2 FROM tab2
----
-1676
-3
2515

query I rowsort
SELECT - col1 + + 95 FROM tab0 AS cor0
----
-2
4
9

query I rowsort
SELECT ALL + cor0.col0 + 14 AS col2 FROM tab1 AS cor0
----
17
78
94

query I rowsort
SELECT DISTINCT col0 * 74 - - cor0.col0 * - col1 AS col2 FROM tab2 AS cor0
----
1170
301
4503

query I rowsort
SELECT col1 + 84 FROM tab1 cor0
----
110
94
97

query I rowsort
SELECT + - col1 + ( col2 ) FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6172
SELECT DISTINCT + col1 + + col1 + + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6172
SELECT DISTINCT + col1 + + col1 + + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT col1 * col1 * col0 AS col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT - col0 + col2 * col0 FROM tab1
----
159
3584
7600

query I rowsort
SELECT DISTINCT col0 + tab2.col2 * - col0 AS col1 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - col1 + col2 * - col1 AS col0 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT col1 + - col2 + + col0 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT + + col0 * + col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - 3 * - col0 FROM tab0 AS cor0
----
105
267
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-6180
SELECT 3 DIV - cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-6180
SELECT 3 / - cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + ( + 15 ) FROM tab2
----
15
15
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 + + col0 col0 FROM tab2 WHERE NOT ( NOT NULL <= ( + col0 ) AND NOT ( col2 ) <= NULL ) AND NOT ( NULL ) < NULL
----

query I rowsort
SELECT DISTINCT - 12 * + col0 FROM tab1
----
-36
-768
-960

query I rowsort
SELECT ( col1 + col0 ) FROM tab0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6185
SELECT - CAST( col1 AS SIGNED ) col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6185
SELECT - CAST ( col1 AS INTEGER ) col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + 8 * 96 + col2 * + col2 FROM tab0 AS cor0
----
1857
7492
769

query I rowsort
SELECT - 26 * col1 FROM tab0 AS cor0
----
-2236
-2366
-2522

query I rowsort
SELECT ALL - col1 * col0 + - col0 AS col1 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT + 75 * col0 FROM tab2
----
525
5850
5925

onlyif mysql # use DIV operator for integer division
query I rowsort label-6190
SELECT + 59 + col2 DIV + ( + col1 ) FROM tab2
----
59
59
61

skipif mysql # not compatible
query I rowsort label-6190
SELECT + 59 + col2 / + ( + col1 ) FROM tab2
----
59
59
61

query I rowsort
SELECT DISTINCT + col0 + col1 * - col0 * - 89 FROM tab1
----
57024
6945
92640

query I rowsort
SELECT - col0 * col1 + col1 * 68 + - tab0.col1 AS col1 FROM tab0
----
-2002
3104
3698

query I rowsort
SELECT tab2.col1 + tab2.col2 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT + + ( + col0 ) + - ( + cor0.col0 ) * col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + + tab2.col1 + tab2.col2 AS col1 FROM tab2, tab0, tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + col2 col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + - cor0.col2 * - col1 * - ( col1 ) + col2 FROM tab0 cor0
----
-244035
-678960
-9408

query I rowsort
SELECT - + col2 * - col2 * ( - col2 ) + + col2 * - col0 FROM tab0 cor0
----
-36
-36729
-558666

query I rowsort
SELECT ALL + - cor0.col0 * 20 + + 28 AS col2 FROM tab2 AS cor0
----
-112
-1532
-1552

query I rowsort
SELECT ALL - col1 + + ( + cor0.col0 * col2 ) AS col1 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-6201
SELECT DISTINCT + col2 DIV + ( cor0.col1 + cor0.col1 ) AS col0 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-6201
SELECT DISTINCT + col2 / + ( cor0.col1 + cor0.col1 ) AS col0 FROM tab0 cor0
----
0

query I rowsort
SELECT + col0 * 67 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT ( col2 ) + - tab0.col0 * tab0.col1 AS col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT 83 + col0 * col0 * + 90 AS col0 FROM tab2
----
4493
547643
561773

query I rowsort
SELECT + 59 AS col2 FROM tab2
----
59
59
59

query I rowsort
SELECT + + col0 * col1 + + ( col2 ) FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col2 * + 50 + + col1 FROM tab0 cor0
----
147
1736
4191

query I rowsort
SELECT + col0 + col1 + col2 AS col0 FROM tab1
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6209
SELECT tab1.col0 DIV + tab1.col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6209
SELECT tab1.col0 / + tab1.col2 FROM tab1
----
0
0
1

query I rowsort
SELECT col0 + col1 - - col1 FROM tab0
----
196
229
271

onlyif mysql # use DIV operator for integer division
query I rowsort label-6211
SELECT + - col2 * cor0.col1 DIV + col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-465
56
65

skipif mysql # not compatible
query I rowsort label-6211
SELECT + - col2 * cor0.col1 / + col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-465
56
65

query I rowsort
SELECT + cor0.col1 + - col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT + - cor0.col1 + - col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - cor0.col0 * col1 + + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-6215
SELECT ALL - col2 DIV col1 - col1 FROM tab1 AS cor0
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-6215
SELECT ALL - col2 / col1 - col1 FROM tab1 AS cor0
----
-15
-20
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-6216
SELECT ALL - - col1 + cor0.col2 + col0 DIV - col2 AS col2 FROM tab1 AS cor0
----
109
66
80

skipif mysql # not compatible
query I rowsort label-6216
SELECT ALL - - col1 + cor0.col2 + col0 / - col2 AS col2 FROM tab1 AS cor0
----
109
66
80

query I rowsort
SELECT DISTINCT - + col2 + + col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL col2 * col0 * col2 - - col1 FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT + col0 + col1 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT ( col2 * col2 + - col2 ) FROM tab1
----
2862
3192
9120

query I rowsort
SELECT ALL + + tab1.col1 - cor0.col2 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d71cc5ecf1aacb631cf199fd150bf079

onlyif mysql # use DIV operator for integer division
query I rowsort label-6222
SELECT - cor0.col2 + col2 DIV + col0 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-6222
SELECT - cor0.col2 + col2 / + col0 FROM tab1 AS cor0
----
-36
-57
-95

query I rowsort
SELECT 35 * - col2 AS col2 FROM tab2 AS cor0
----
-1330
-910
-945

query I rowsort
SELECT ALL + 30 * col0 FROM tab2
----
210
2340
2370

query I rowsort
SELECT - ( col0 * + col1 ) AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - cor0.col0 + + col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + 31 * + col1 - col2 FROM tab0
----
2633
2739
3006

query I rowsort
SELECT + - col0 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6229
SELECT DISTINCT - 23 DIV col0 FROM tab2
----
-3
0

skipif mysql # not compatible
query I rowsort label-6229
SELECT DISTINCT - 23 / col0 FROM tab2
----
-3
0

query I rowsort
SELECT DISTINCT - col2 - - col2 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - col2 * cor0.col2 + - col1 AS col2 FROM tab2 AS cor0
----
-1461
-735
-760

onlyif mysql # use DIV operator for integer division
query I rowsort label-6232
SELECT DISTINCT + col1 + - col0 * 69 DIV col0 FROM tab0 AS cor0
----
17
22
28

skipif mysql # not compatible
query I rowsort label-6232
SELECT DISTINCT + col1 + - col0 * 69 / col0 FROM tab0 AS cor0
----
17
22
28

query I rowsort
SELECT ALL + cor0.col2 * col1 + + ( - col2 ) - - col0 FROM tab2 AS cor0
----
1586
687
817

query I rowsort
SELECT ALL 95 - col0 * ( + col1 ) FROM tab1 AS cor0
----
-545
-945
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col2 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col0 * col2 * col1 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - - col2 + + col1 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - cor0.col1 * 63 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 9e25b9d39d87c243b8ff77a0d637140a

query I rowsort
SELECT ALL - 86 + cor0.col2 FROM tab2 AS cor0
----
-48
-59
-60

query I rowsort
SELECT DISTINCT - + 4 * col0 AS col0 FROM tab1 AS cor0
----
-12
-256
-320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 91 + + col2 col1 FROM tab2 AS cor0
----
-53
-64
-65

query I rowsort
SELECT ALL col0 + ( + col0 ) AS col0 FROM tab0 cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + ( - 65 ) col2 FROM tab2 AS cor0
----
1690
1755
2470

query I rowsort
SELECT col1 * tab0.col2 - + col0 * col1 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT DISTINCT - + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6246
SELECT DISTINCT col1 DIV + 83 AS col0 FROM tab0 cor0
----
1

skipif mysql # not compatible
query I rowsort label-6246
SELECT DISTINCT col1 / + 83 AS col0 FROM tab0 cor0
----
1

query I rowsort
SELECT col2 * ( 14 ) + - col2 AS col1 FROM tab2 AS cor0
----
338
351
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + 16 + - cor0.col1 + + col0 col2 FROM tab0 AS cor0
----
-1314
-590
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6249
SELECT DISTINCT - cor0.col2 + CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-6249
SELECT DISTINCT - cor0.col2 + CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + col1 * 95 AS col0 FROM tab0 AS cor0
----
8170
8645
9215

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 + - 89 AS col1 FROM tab2 AS cor0
----
1445
557
748

query I rowsort
SELECT col0 * + col1 * col0 + col1 AS col0 FROM tab1
----
260
40970
83213

query I rowsort
SELECT + 31 - + col2 AS col1 FROM tab0
----
-2
-51
30

query I rowsort
SELECT - ( - 42 ) + cor0.col2 * 16 AS col1 FROM tab1 cor0
----
1578
906
954

query I rowsort
SELECT DISTINCT + 85 + + 56 * col0 AS col1 FROM tab2 cor0
----
4453
4509
477

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 - ( + 44 ) + cor0.col0 AS col0 FROM tab1 AS cor0
----
-41
20
36

query I rowsort
SELECT cor0.col0 + - 94 AS col2 FROM tab0 AS cor0
----
-5
-59
-70

query I rowsort
SELECT ALL + - 79 * - 47 AS col0 FROM tab2 AS cor0
----
3713
3713
3713

onlyif mysql # use DIV operator for integer division
query I rowsort label-6260
SELECT ALL + col2 * - cor0.col1 * col1 + - cor0.col2 * col0 + col2 DIV cor0.col2 FROM tab0 AS cor0
----
-244859
-686339
-9443

skipif mysql # not compatible
query I rowsort label-6260
SELECT ALL + col2 * - cor0.col1 * col1 + - cor0.col2 * col0 + col2 / cor0.col2 FROM tab0 AS cor0
----
-244859
-686339
-9443

query I rowsort
SELECT - - 38 + col2 FROM tab0 AS cor0
----
120
39
71

query I rowsort
SELECT + ( + col1 ) * - col2 + col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + + 15 + - cor0.col2 + + col1 AS col0 FROM tab0 cor0
----
111
24
68

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT col1 * - col0 - + col1 FROM tab0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-6266
SELECT ALL - col0 * col1 DIV ( col0 ) FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6266
SELECT ALL - col0 * col1 / ( col0 ) FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + tab1.col1 * - cor0.col0 FROM tab1, tab0 cor0
----
9 values hashing to 81a8fcf7518fbae07bfeaffb3ad3a436

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6268
SELECT ALL + CAST( - col1 AS SIGNED ) + col2 AS col2 FROM tab2
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-6268
SELECT ALL + CAST ( - col1 AS INTEGER ) + col2 AS col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT + 4 * 94 FROM tab1
----
376
376
376

query I rowsort
SELECT - + col0 + + col1 - col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - - col0 + + 5 AS col2 FROM tab0 AS cor0
----
29
40
94

query I rowsort
SELECT - col0 + cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT ALL + 70 + + col2 FROM tab1
----
124
127
166

query I rowsort
SELECT DISTINCT col2 + col2 * col1 * 27 FROM tab0
----
201556
2620
76659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 96 + - cor0.col1 * + ( col0 ) * - col2 + + ( 76 ) * + col0 col0 FROM tab1 AS cor0
----
106016
41440
4536

query I rowsort
SELECT DISTINCT + 69 + + 87 + - col1 FROM tab2
----
125
139
97

query I rowsort
SELECT - cor0.col2 * - col0 + ( col2 ) * - col1 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT + 25 + - col0 * + col0 FROM tab1 cor0
----
-4071
-6375
16

query I rowsort
SELECT ALL 63 + + col2 AS col2 FROM tab0
----
145
64
96

query I rowsort
SELECT 59 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ( - col1 ) * - col1 FROM tab1
----
100
169
676

query I rowsort
SELECT - col0 * 48 + col0 * 91 AS col2 FROM tab1
----
129
2752
3440

query I rowsort
SELECT 85 + col1 FROM tab2 AS cor0
----
102
116
144

query I rowsort
SELECT - + col0 * col2 + - ( col2 ) FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL - - 56 + col1 * + col1 AS col2 FROM tab2 AS cor0
----
1017
345
3537

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col2 * col2 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6287
SELECT - col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-6287
SELECT - col2 / + col1 AS col2 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT DISTINCT 22 * cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
277
382
626

query I rowsort
SELECT col2 + + 0 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL col1 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - col0 * col0 - - 51 AS col0 FROM tab1 cor0
----
-4045
-6349
42

query I rowsort
SELECT + col1 + + 4 FROM tab2 AS cor0
----
21
35
63

query I rowsort
SELECT ALL - col2 * + cor0.col2 + 44 AS col1 FROM tab0 AS cor0
----
-1045
-6680
43

query I rowsort
SELECT ALL + ( + col0 ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + ( + 36 ) + col1 FROM tab0 cor0
----
122
127
133

query I rowsort
SELECT DISTINCT 2 FROM tab1 cor0
----
2

query I rowsort
SELECT - col0 - - 50 AS col0 FROM tab0 AS cor0
----
-39
15
26

query I rowsort
SELECT col2 + - 97 AS col2 FROM tab1 AS cor0
----
-1
-40
-43

query I rowsort
SELECT cor0.col0 * col1 + - cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col0 - - col1 * col1 AS col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT - cor0.col2 * + col0 * col1 + + cor0.col2 FROM tab2 AS cor0
----
-119626
-50996
-5832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6302
SELECT - + col1 * CAST( col2 AS SIGNED ) + + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-6302
SELECT - + col1 * CAST ( col2 AS INTEGER ) + + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT + + 58 AS col1 FROM tab2, tab1, tab1 AS cor0
----
58

query I rowsort
SELECT col2 * col0 * + 3 AS col1 FROM tab1 AS cor0
----
10944
23040
486

query I rowsort
SELECT + col0 - ( cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + + col2 + col2 + + col2 FROM tab2 AS cor0
----
114
78
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6307
SELECT ALL - CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6307
SELECT ALL - CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col1 * col2 col0 FROM tab0 cor0
----
2805
7380
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6309
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col1 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6309
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col1 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT tab0.col2 + tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to e5ee086d16e1b2450d3f7ac8d26a0f7b

query I rowsort
SELECT + 67 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT ALL - 91 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

query I rowsort
SELECT ALL 93 * - tab1.col2 FROM tab1
----
-5022
-5301
-8928

query I rowsort
SELECT DISTINCT + cor1.col1 AS col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
10
13
26

query I rowsort
SELECT tab1.col0 * + ( - ( cor0.col0 ) * 1 ) + tab1.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 5db66d9ff22f24675fe46f95b754ba6f

query I rowsort
SELECT ALL - 41 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 47b9ef972839428f4f71d9f5b0944edf

query I rowsort
SELECT ALL + + 10 * + col0 FROM tab1 cor0
----
30
640
800

query I rowsort
SELECT ALL - - col2 * ( + col1 ) * - col1 AS col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT cor0.col1 * tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 9dd217b6385bf38f78d8b6e6b7864578

query I rowsort
SELECT DISTINCT - + cor1.col2 * 23 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-1886
-23
-759

query I rowsort
SELECT ALL 73 * 54 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to dbe32c2bd666bd4a6f6b7c8bda1e3e1f

query I rowsort
SELECT + tab1.col1 - col0 * col2 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL 35 + 9 * cor0.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 09c7293531d6e24ab6a9b578a1301ca7

query I rowsort
SELECT ALL - col1 - + ( col1 ) FROM tab2
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6325
SELECT DISTINCT tab1.col0 * + 68 + + col0 - - col1 DIV 70 FROM tab1
----
207
4416
5520

skipif mysql # not compatible
query I rowsort label-6325
SELECT DISTINCT tab1.col0 * + 68 + + col0 - - col1 / 70 FROM tab1
----
207
4416
5520

query I rowsort
SELECT ALL + col0 * ( col2 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col1 * 31 AS col2 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT - + cor0.col2 * + col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT 74 + - col1 AS col0 FROM tab2
----
15
43
57

query I rowsort
SELECT tab2.col0 - - col1 AS col1 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6331
SELECT ALL - col2 * 80 + - col1 DIV - col2 AS col2 FROM tab0
----
-2638
-6559
17

skipif mysql # not compatible
query I rowsort label-6331
SELECT ALL - col2 * 80 + - col1 / - col2 AS col2 FROM tab0
----
-2638
-6559
17

query I rowsort
SELECT col1 - 32 FROM tab2
----
-1
-15
27

query I rowsort
SELECT DISTINCT - col0 * + ( - col0 ) * + col2 AS col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT + + col0 * cor0.col2 + - col1 AS col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL + col2 * col1 + cor0.col1 AS col2 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT - col0 * + col2 + 6 FROM tab1 AS cor0
----
-156
-3642
-7674

query I rowsort
SELECT - 92 + + col1 * col2 FROM tab1 AS cor0
----
1156
1312
478

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6338
SELECT CAST( NULL AS SIGNED ) * + col1 * col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6338
SELECT CAST ( NULL AS INTEGER ) * + col1 * col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + - col1 - + 52 FROM tab1 AS cor0
----
-104
-72
-78

query I rowsort
SELECT ALL 39 AS col0 FROM tab2 cor0
----
39
39
39

query I rowsort
SELECT DISTINCT cor0.col2 * + cor0.col0 + + 65 FROM tab0 AS cor0
----
100
7363
857

query I rowsort
SELECT ( - col1 ) + cor0.col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - col2 + 76 FROM tab1
----
-20
19
22

query I rowsort
SELECT ALL col2 + - 86 AS col0 FROM tab0
----
-4
-53
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6345
SELECT DISTINCT - col0 DIV tab1.col1 + col0 * + col0 * col1 AS col2 FROM tab1
----
234
40954
83194

skipif mysql # not compatible
query I rowsort label-6345
SELECT DISTINCT - col0 / tab1.col1 + col0 * + col0 * col1 AS col2 FROM tab1
----
234
40954
83194

query I rowsort
SELECT col1 * - ( 99 ) FROM tab2
----
-1683
-3069
-5841

query I rowsort
SELECT DISTINCT col2 + 51 FROM tab0
----
133
52
84

query I rowsort
SELECT col2 + - ( + 76 ) * - col0 AS col1 FROM tab1 AS cor0
----
282
4921
6176

query I rowsort
SELECT - + col2 * - col1 + ( col0 ) + + cor0.col0 FROM tab2 AS cor0
----
1690
804
851

onlyif mysql # use DIV operator for integer division
query I rowsort label-6350
SELECT col2 * - col2 + + col0 DIV + col1 col1 FROM tab1 AS cor0
----
-2916
-3243
-9210

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6350
SELECT col2 * - col2 + + col0 / + col1 col1 FROM tab1 AS cor0
----
-2916
-3243
-9210

query I rowsort
SELECT DISTINCT + col1 + 70 * col2 FROM tab0 AS cor0
----
167
2396
5831

onlyif mysql # use DIV operator for integer division
query I rowsort label-6352
SELECT ALL + col1 + col2 DIV + col1 + ( + cor0.col1 ) FROM tab2 AS cor0
----
118
36
62

skipif mysql # not compatible
query I rowsort label-6352
SELECT ALL + col1 + col2 / + col1 + ( + cor0.col1 ) FROM tab2 AS cor0
----
118
36
62

query I rowsort
SELECT DISTINCT - 51 AS col0 FROM tab2 cor0
----
-51

query I rowsort
SELECT ALL + 22 + col2 * - col0 FROM tab0 AS cor0
----
-13
-7276
-770

onlyif mysql # use DIV operator for integer division
query I rowsort label-6355
SELECT + col2 DIV cor0.col2 + + col1 DIV 72 FROM tab0 cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-6355
SELECT + col2 / cor0.col2 + + col1 / 72 FROM tab0 cor0
----
2
2
2

query I rowsort
SELECT + - col0 + + col1 * + col0 AS col0 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-6357
SELECT ALL + col0 * - 92 + cor0.col0 DIV + 98 AS col0 FROM tab2 AS cor0
----
-644
-7176
-7268

skipif mysql # not compatible
query I rowsort label-6357
SELECT ALL + col0 * - 92 + cor0.col0 / + 98 AS col0 FROM tab2 AS cor0
----
-644
-7176
-7268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6358
SELECT - - CAST( col0 AS SIGNED ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6358
SELECT - - CAST ( col0 AS INTEGER ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6359
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col2 * + col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6359
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col2 * + col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col2 * + ( col2 ) - + col1 AS col0 FROM tab2
----
1427
617
698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6361
SELECT DISTINCT col0 + + CAST( NULL AS DECIMAL ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6361
SELECT DISTINCT col0 + + CAST ( NULL AS REAL ) FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + - col2 * col2 + + col0 + - 42 * - 11 * + col1 AS col2 FROM tab0 AS cor0
----
35407
38667
44848

query I rowsort
SELECT DISTINCT col1 + 47 AS col1 FROM tab2 AS cor0
----
106
64
78

query I rowsort
SELECT - 56 AS col2 FROM tab1 cor0
----
-56
-56
-56

query I rowsort
SELECT ALL col0 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + 93 * cor0.col2 * cor0.col0 + + 12 FROM tab0 AS cor0
----
3267
678726
73668

query I rowsort
SELECT ALL - col1 + - 6 FROM tab2 cor0
----
-23
-37
-65

query I rowsort
SELECT DISTINCT - - 12 * + 37 + - col1 AS col2 FROM tab0 AS cor0
----
347
353
358

query I rowsort
SELECT + - 29 * col2 AS col1 FROM tab1 cor0
----
-1566
-1653
-2784

query I rowsort
SELECT ALL col2 * col1 * cor0.col0 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-6371
SELECT DISTINCT - 81 DIV col0 AS col0 FROM tab1 AS cor0
----
-1
-27

skipif mysql # not compatible
query I rowsort label-6371
SELECT DISTINCT - 81 / col0 AS col0 FROM tab1 AS cor0
----
-1
-27

query I rowsort
SELECT + cor0.col2 * col1 + ( - 58 ) AS col0 FROM tab1 cor0
----
1190
1346
512

query I rowsort
SELECT ALL + + 25 AS col2 FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT ALL cor0.col1 + - col2 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6375
SELECT DISTINCT - col2 DIV 1 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6375
SELECT DISTINCT - col2 / 1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + - col2 + - col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT ALL 44 + col1 * col2 FROM tab2 AS cor0
----
1578
690
881

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6378
SELECT col2 + - col0 * - CAST( col2 + - col0 AS SIGNED ) FROM tab1 cor0
----
-391
1376
207

skipif mysql # not compatible
query I rowsort label-6378
SELECT col2 + - col0 * - CAST ( col2 + - col0 AS INTEGER ) FROM tab1 cor0
----
-391
1376
207

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 49 + cor0.col0 * + col0 col1 FROM tab1 AS cor0
----
4145
58
6449

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) * - ( col0 + - col0 ) * col1 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL - - col1 + 82 * - col2 FROM tab0 AS cor0
----
-2620
-6633
15

query I rowsort
SELECT 28 + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3269368cff2c9c90d08ead957a117673

query I rowsort
SELECT + + cor0.col1 * col1 + cor0.col2 FROM tab1 cor0
----
157
265
730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + cor0.col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + ( + col2 ) - - col1 col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 * - 41 FROM tab2 AS cor0
----
-1125
-1138
-1575

query I rowsort
SELECT DISTINCT col1 * col1 - tab1.col0 FROM tab1
----
36
673
89

query I rowsort
SELECT - cor0.col1 + + col1 * 34 + + col2 AS col1 FROM tab2 AS cor0
----
1050
1973
599

query I rowsort
SELECT DISTINCT + + col1 * ( + 38 + cor0.col2 ) * + col2 AS col2 FROM tab0 AS cor0
----
201498
3783
895440

query I rowsort
SELECT ALL - col0 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + cor0.col0 col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6392
SELECT + col1 * 58 + col1 * + col0 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6392
SELECT + col1 * 58 + col1 * + col0 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6393
SELECT col1 DIV col0 + - col0 * - col2 AS col0 FROM tab0
----
37
7299
795

skipif mysql # not compatible
query I rowsort label-6393
SELECT col1 / col0 + - col0 * - col2 AS col0 FROM tab0
----
37
7299
795

query I rowsort
SELECT DISTINCT - ( - 53 ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
53

query I rowsort
SELECT ALL 29 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT tab0.col0 + + col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT + col1 + col0 * + ( + col2 * + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT - cor0.col0 + 50 * + 90 FROM tab0 AS cor0
----
4411
4465
4476

query I rowsort
SELECT + - cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL - col1 + tab1.col1 * + col2 FROM tab1
----
1235
1378
560

query I rowsort
SELECT - col0 * - 40 * + col2 FROM tab2
----
120080
7560
81120

onlyif mysql # use DIV operator for integer division
query I rowsort label-6402
SELECT ALL - cor0.col2 + 77 * col1 DIV cor0.col1 FROM tab2 AS cor0
----
39
50
51

skipif mysql # not compatible
query I rowsort label-6402
SELECT ALL - cor0.col2 + 77 * col1 / cor0.col1 FROM tab2 AS cor0
----
39
50
51

query I rowsort
SELECT - cor0.col2 * 51 + col2 * col1 * - col1 + col0 FROM tab1 AS cor0
----
-21040
-39255
-8543

query I rowsort
SELECT col1 + 89 * + col0 AS col1 FROM tab2 AS cor0
----
654
7001
7048

query I rowsort
SELECT ALL - - col2 + + col1 * 1 AS col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT col1 + cor0.col1 + col0 * col2 AS col2 FROM tab0 AS cor0
----
229
7480
964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6407
SELECT DISTINCT + + col0 + + CAST( NULL AS SIGNED ) * + col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6407
SELECT DISTINCT + + col0 + + CAST ( NULL AS INTEGER ) * + col2 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - col1 + 9 AS col2 FROM tab2
----
-22
-50
-8

query I rowsort
SELECT - 20 + col2 * + col0 AS col1 FROM tab0
----
15
7278
772

query I rowsort
SELECT 92 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL - cor0.col1 * 24 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to be7fd63718193c99404bd1a3bf486181

query I rowsort
SELECT - 43 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT DISTINCT + 94 + + col2 + - 67 FROM tab2 AS cor0
----
53
54
65

query I rowsort
SELECT - 51 * - col1 + col1 * - col1 AS col1 FROM tab0
----
-3010
-3640
-4462

query I rowsort
SELECT ( + tab0.col2 ) FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - + col1 + - col2 * - ( - 37 * col2 ) FROM tab1 AS cor0
----
-107918
-120223
-341005

onlyif mysql # use DIV operator for integer division
query I rowsort label-6417
SELECT - - col0 DIV + cor0.col2 AS col1 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6417
SELECT - - col0 / + cor0.col2 AS col1 FROM tab0 cor0
----
0
1
35

query I rowsort
SELECT ALL + col1 + - col0 * col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + col2 + col2 + col0 AS col1 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) * - col1 - - col2 FROM tab2 cor0
----
-1508
-608
-810

query I rowsort
SELECT ( + col2 ) * col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT col1 * - 46 AS col2 FROM tab2 cor0
----
-1426
-2714
-782

query I rowsort
SELECT - ( - col2 ) AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - 61 + + col0 FROM tab2 AS cor0
----
-54
17
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-6425
SELECT col2 * col0 DIV + col1 AS col2 FROM tab2
----
176
34
6

skipif mysql # not compatible
query I rowsort label-6425
SELECT col2 * col0 / + col1 AS col2 FROM tab2
----
176
34
6

query I rowsort
SELECT - col1 + col0 * 34 AS col2 FROM tab0 AS cor0
----
1093
2935
730

query I rowsort
SELECT ALL col0 - 6 AS col2 FROM tab2 AS cor0
----
1
72
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT - - 19 + + cor0.col0 FROM tab2 AS cor0
----
26
97
98

query I rowsort
SELECT + 8 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 + col2 col2 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - col2 * ( - cor0.col1 ) AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col2 * 63 * + ( col1 + - col2 ) AS col1 FROM tab0
----
-110187
-46494
-6048

query I rowsort
SELECT ALL - 45 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 71160abf09589695379a70558726f0ba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6435
SELECT DISTINCT - - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6435
SELECT DISTINCT - - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT col0 + - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - - ( + ( col1 ) ) * - col2 + + cor0.col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL 82 * 83 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 0bbcd2c6e2b483986fd3022dd2032791

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6439
SELECT CAST( + 62 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
62
62
62

skipif mysql # not compatible
query I rowsort label-6439
SELECT CAST ( + 62 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
62
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9b0655947ad21e0b95a137a474fa6a1f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6441
SELECT ALL tab1.col0 DIV + tab1.col1 + ( col2 ) FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-6441
SELECT ALL tab1.col0 / + tab1.col1 + ( col2 ) FROM tab1
----
102
54
63

query I rowsort
SELECT - + 74 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 5a477330c946251f814fbbfd08e77c28

query I rowsort
SELECT ( - 65 ) FROM tab1, tab0, tab2 cor0
----
27 values hashing to 4ca93c42a91c7dff917e7b7090ba9e57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6444
SELECT DISTINCT + col2 DIV - ( - col0 ) FROM tab2
----
0
3

skipif mysql # not compatible
query I rowsort label-6444
SELECT DISTINCT + col2 / - ( - col0 ) FROM tab2
----
0
3

query I rowsort
SELECT DISTINCT - + col1 * + 3 + - 99 FROM tab1 AS cor0
----
-129
-138
-177

query I rowsort
SELECT ALL 0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL + + 32 + 92 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to f95a510ef7a720583a4639131b2cccc3

query I rowsort
SELECT - 59 AS col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

query I rowsort
SELECT + - col2 + - 80 AS col0 FROM tab0 AS cor0
----
-113
-162
-81

query I rowsort
SELECT - col2 * + col2 + - 60 * col2 AS col1 FROM tab1 AS cor0
----
-14976
-6156
-6669

query I rowsort
SELECT - - col2 + ( + 78 ) * col2 AS col0 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT ALL - col0 - cor0.col0 AS col2 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT ALL - col1 * col0 + + col1 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-16198
-4128
-6790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + ( col2 ) col1 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 18 * - col2 col2 FROM tab0 AS cor0
----
-1394
-17
-561

query I rowsort
SELECT cor0.col0 * - col2 * 54 + col1 * col1 AS col0 FROM tab1 AS cor0
----
-196892
-414551
-8072

query I rowsort
SELECT - cor0.col0 + + col0 * + col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT col1 * + col1 + + col1 + + col2 AS col0 FROM tab2 AS cor0
----
1019
344
3566

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col1 - col1 * col1 col2 FROM tab1
----
-167
-278
-756

query I rowsort
SELECT col0 + col0 + col0 FROM tab2
----
21
234
237

query I rowsort
SELECT - col2 + col0 + - cor0.col2 FROM tab2 AS cor0
----
-47
26
3

query I rowsort
SELECT ALL col2 + col0 + col0 FROM tab2 AS cor0
----
182
196
41

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT - col0 + + col1 NOT BETWEEN + col0 AND NULL
----

query I rowsort
SELECT ALL col2 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT - col2 + col2 * col0 * col0 AS col0 FROM tab1
----
233415
432
614304

query I rowsort
SELECT col0 + col1 * col0 AS col2 FROM tab1
----
1120
704
81

query I rowsort
SELECT DISTINCT + tab1.col1 * col2 AS col2 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
----
-10982
-25947
-90506

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL IN ( col0 * - col2 + col1 + col1 * - col2 * col2 )
----

query I rowsort
SELECT + col2 * - col0 + - col1 + col2 FROM tab1
----
-134
-3601
-7597

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) NOT IN ( + col1 - col0 * + col1 )
----

query I rowsort
SELECT DISTINCT col2 - + col0 * + col0 * + col2 AS col1 FROM tab2
----
-1296
-158158
-237120

query I rowsort
SELECT + col1 * - col1 - + tab0.col1 FROM tab0
----
-7482
-8372
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6474
SELECT - col0 + col1 + + col2 DIV col0 FROM tab1 AS cor0
----
-54
-66
41

skipif mysql # not compatible
query I rowsort label-6474
SELECT - col0 + col1 + + col2 / col0 FROM tab1 AS cor0
----
-54
-66
41

query I rowsort
SELECT DISTINCT + col1 * + col0 * col0 FROM tab2 AS cor0
----
106097
1519
358956

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT NULL NOT IN ( - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - cor0.col2 * col1 + - col0 col1 FROM tab1 AS cor0
----
-1232
-1353
-577

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col2 - cor0.col1 * - col0 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6480
SELECT DISTINCT + cor0.col1 DIV col0 + - col0 AS col0 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-6480
SELECT DISTINCT + cor0.col1 / col0 + - col0 AS col0 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT ALL - col1 + - col0 - col1 * cor0.col1 FROM tab0 AS cor0
----
-7506
-8461
-9541

onlyif mysql # use DIV operator for integer division
query I rowsort label-6482
SELECT DISTINCT + - col2 * col2 + - col2 DIV col1 AS col2 FROM tab2 AS cor0
----
-1446
-676
-729

skipif mysql # not compatible
query I rowsort label-6482
SELECT DISTINCT + - col2 * col2 + - col2 / col1 AS col2 FROM tab2 AS cor0
----
-1446
-676
-729

query I rowsort
SELECT ALL col1 + + col2 * - col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - + cor0.col1 + cor0.col0 * + col2 AS col0 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT cor0.col2 * ( 13 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 91b1dfe311d4f4c4761a814a67702ca2

query I rowsort
SELECT DISTINCT + + 90 * cor0.col1 FROM tab0 AS cor0
----
7740
8190
8730

query I rowsort
SELECT col1 * + col1 + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - ( + col0 ) * col0 - + 34 * + col0 AS col0 FROM tab2 AS cor0
----
-287
-8736
-8927

query I rowsort
SELECT ALL - 4 * cor0.col2 - + col2 FROM tab2 AS cor0
----
-130
-135
-190

onlyif mysql # use DIV operator for integer division
query I rowsort label-6490
SELECT tab0.col1 + - col2 DIV col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6490
SELECT tab0.col1 + - col2 / col1 FROM tab0
----
86
91
97

query I rowsort
SELECT col2 * + col1 * - col1 + col1 AS col0 FROM tab1
----
-16211
-36478
-5690

query I rowsort
SELECT col0 + - tab0.col0 * + tab0.col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + col1 * + col1 + tab1.col2 FROM tab1
----
157
265
730

query I rowsort
SELECT ALL col1 + + col2 * - col1 AS col0 FROM tab1
----
-1235
-1378
-560

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col2 NOT IN ( - col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT ALL * FROM tab1 WHERE ( + col2 * - col0 + + col1 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - tab2.col0 * - col0 AS col2 FROM tab2
----
49
6084
6241

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) IN ( - col2 + col0 / - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6499
SELECT DISTINCT col1 + + col2 DIV + col0 - - col1 AS col1 FROM tab2
----
118
34
65

skipif mysql # not compatible
query I rowsort label-6499
SELECT DISTINCT col1 + + col2 / + col0 - - col1 AS col1 FROM tab2
----
118
34
65

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col1 + col2 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT + tab2.col2 * col1 + + col1 + tab2.col0 * col2 FROM tab2
----
1057
3621
3665

query I rowsort
SELECT tab1.col1 * - col0 AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL col2 * + col1 * tab2.col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL - tab2.col1 * col1 + - tab2.col0 AS col2 FROM tab2
----
-3559
-368
-968

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 = NULL
----

query I rowsort
SELECT + tab0.col2 FROM tab0 WHERE ( NULL ) NOT BETWEEN + col0 + col2 * - col1 + col0 AND - col2 * col0
----

query I rowsort
SELECT ALL col0 FROM tab2 WHERE NULL BETWEEN NULL AND col1 * col0
----

query I rowsort
SELECT DISTINCT col2 - tab1.col2 * + col1 AS col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + col0 * col2 + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT + col0 AS col2 FROM tab2 WHERE ( + col0 * - col2 ) > col2
----

query I rowsort
SELECT DISTINCT - col0 + - ( col0 ) + + col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT tab1.col2 * col1 * + ( col0 * col2 ) AS col1 FROM tab1
----
2079360
227448
9584640

query I rowsort
SELECT col1 * col0 * ( + col2 ) AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + col1 * col2 + col2 * col1 FROM tab0
----
14924
194
5676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6515
SELECT DISTINCT - col1 * tab1.col2 DIV col0 col2 FROM tab1
----
-15
-468
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6515
SELECT DISTINCT - col1 * tab1.col2 / col0 col2 FROM tab1
----
-15
-468
-8

query I rowsort
SELECT DISTINCT col0 * 58 FROM tab2
----
406
4524
4582

query I rowsort
SELECT - col2 * 28 FROM tab2 cor0
----
-1064
-728
-756

query I rowsort
SELECT col2 * - ( 27 + cor0.col2 ) FROM tab0 AS cor0
----
-1980
-28
-8938

query I rowsort
SELECT - col0 * - 38 FROM tab2 cor0
----
266
2964
3002

query I rowsort
SELECT col2 * 87 AS col0 FROM tab2 cor0
----
2262
2349
3306

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 78 col1 FROM tab2
----
78

query I rowsort
SELECT + + ( cor0.col2 ) + cor0.col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + ( 9 ) + col1 AS col2 FROM tab1 AS cor0
----
19
22
35

query I rowsort
SELECT col2 * col2 + + col0 * + col2 * cor0.col2 FROM tab1 AS cor0
----
11664
211185
746496

query I rowsort
SELECT DISTINCT 29 + + col2 FROM tab2 AS cor0
----
55
56
67

query I rowsort
SELECT - ( - 46 ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
135
70
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6527
SELECT 52 + + col0 * + CAST( + 50 AS SIGNED ) * + col2 + + col2 FROM tab1 AS cor0
----
182509
384148
8206

skipif mysql # not compatible
query I rowsort label-6527
SELECT 52 + + col0 * + CAST ( + 50 AS INTEGER ) * + col2 + + col2 FROM tab1 AS cor0
----
182509
384148
8206

query I rowsort
SELECT - + 86 * cor0.col2 + + col1 AS col0 FROM tab1 AS cor0
----
-4618
-4892
-8243

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 54 * col0 + col2 col1 FROM tab1 AS cor0
----
-108
-3399
-4224

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 87 AS REAL ) AS col0 FROM tab1
----
-87
-87
-87

query I rowsort
SELECT 47 + + col0 * col0 FROM tab0 AS cor0
----
1272
623
7968

query I rowsort
SELECT DISTINCT + 81 * - col1 - + col1 FROM tab0 AS cor0
----
-7052
-7462
-7954

query I rowsort
SELECT col0 * col2 + cor0.col0 + - col1 AS col0 FROM tab0 AS cor0
----
-27
7296
730

query I rowsort
SELECT DISTINCT + 85 * - cor0.col2 FROM tab2 AS cor0
----
-2210
-2295
-3230

query I rowsort
SELECT + + 38 + col1 AS col2 FROM tab1 AS cor0
----
48
51
64

query I rowsort
SELECT ALL 25 * - col0 + + col2 FROM tab0 AS cor0
----
-2143
-567
-874

query I rowsort
SELECT DISTINCT cor0.col0 * col1 * + col2 + col0 - - col2 FROM tab0 AS cor0
----
3431
664289
68169

onlyif mysql # use DIV operator for integer division
query I rowsort label-6538
SELECT ALL 37 + col2 DIV col1 AS col0 FROM tab2 AS cor0
----
37
37
39

skipif mysql # not compatible
query I rowsort label-6538
SELECT ALL 37 + col2 / col1 AS col0 FROM tab2 AS cor0
----
37
37
39

query I rowsort
SELECT DISTINCT + col1 - + cor0.col1 * + col0 AS col2 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT - col0 * + col2 + - col0 AS col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT + + col1 * + col1 - col0 * col0 FROM tab0 AS cor0
----
360
6820
8184

query I rowsort
SELECT col0 + col2 * + col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 88 col0 FROM tab0 cor0
----
-88
-88
-88

query I rowsort
SELECT ALL - + cor0.col0 * - col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - - col2 + + cor0.col1 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL + col2 * + col2 - col2 AS col0 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-6547
SELECT ALL col1 - col1 DIV col0 AS col2 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-6547
SELECT ALL col1 - col1 / col0 AS col2 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT DISTINCT + - 95 + - cor0.col1 * col2 AS col1 FROM tab0 AS cor0
----
-192
-2933
-7557

query I rowsort
SELECT + - 92 * - col0 AS col1 FROM tab0 AS cor0
----
2208
3220
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-6550
SELECT ALL - 44 DIV + cor0.col0 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6550
SELECT ALL - 44 / + cor0.col0 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT + col2 * 75 AS col0 FROM tab2 AS cor0
----
1950
2025
2850

onlyif mysql # use DIV operator for integer division
query I rowsort label-6552
SELECT ALL - ( col1 ) - - col0 DIV col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6552
SELECT ALL - ( col1 ) - - col0 / col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL + ( tab0.col1 ) * + col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL tab0.col2 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT col1 * - col1 * col1 AS col0 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT + col2 + + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT + col1 * tab0.col1 - col2 AS col1 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT ALL - 37 - col1 * - col0 AS col2 FROM tab1
----
1003
41
603

query I rowsort
SELECT DISTINCT - + col2 + + col0 * - col1 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT cor0.col2 + - 80 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 557fb18adde188e3cfc3252b6fe67ae7

query I rowsort
SELECT DISTINCT cor0.col0 * 24 AS col2 FROM tab2 AS cor0
----
168
1872
1896

onlyif mysql # use DIV operator for integer division
query I rowsort label-6562
SELECT DISTINCT - 93 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1
-31

skipif mysql # not compatible
query I rowsort label-6562
SELECT DISTINCT - 93 / + col0 AS col2 FROM tab1 AS cor0
----
-1
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-6563
SELECT 42 + col0 DIV col1 FROM tab2 AS cor0
----
42
43
46

skipif mysql # not compatible
query I rowsort label-6563
SELECT 42 + col0 / col1 FROM tab2 AS cor0
----
42
43
46

query I rowsort
SELECT DISTINCT + 46 * col2 AS col1 FROM tab0 AS cor0
----
1518
3772
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col1 ) * - col2 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6566
SELECT - col2 DIV col0 + - col1 * - col2 AS col2 FROM tab1
----
1247
1386
570

skipif mysql # not compatible
query I rowsort label-6566
SELECT - col2 / col0 + - col1 * - col2 AS col2 FROM tab1
----
1247
1386
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6567
SELECT ALL CAST( ( + tab2.col1 ) AS SIGNED ) FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6567
SELECT ALL CAST ( ( + tab2.col1 ) AS INTEGER ) FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) * + cor0.col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + + col1 - - col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL tab2.col0 * + 45 - - tab2.col1 AS col0 FROM tab2
----
346
3569
3572

onlyif mysql # use DIV operator for integer division
query I rowsort label-6571
SELECT col0 * col2 DIV col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6571
SELECT col0 * col2 / col0 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * - col2 + col2 col0 FROM tab0 cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT + col0 * ( col0 ) FROM tab1
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6574
SELECT - col0 DIV - col0 + + col0 * + 9 col0 FROM tab0
----
217
316
802

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6574
SELECT - col0 / - col0 + + col0 * + 9 col0 FROM tab0
----
217
316
802

query I rowsort
SELECT ALL - - col0 + 23 FROM tab1 AS cor0
----
103
26
87

query I rowsort
SELECT col0 + + cor0.col2 * + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT - col1 + + tab2.col1 * - col2 * + col2 AS col2 FROM tab2
----
-22630
-24565
-39943

query I rowsort
SELECT 66 + col0 * ( - 16 * + col0 ) + 2 FROM tab1
----
-102332
-65468
-76

query I rowsort
SELECT + 33 + tab2.col2 AS col0 FROM tab2
----
59
60
71

query I rowsort
SELECT ALL + col1 * col1 + col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT - col2 + - col2 * + col0 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT - ( + col1 * 75 ) + + col2 * col1 FROM tab1
----
-180
-546
273

query I rowsort
SELECT + 92 - - tab1.col1 FROM tab1
----
102
105
118

query I rowsort
SELECT + cor0.col2 * + ( col2 + col0 ) FROM tab2 AS cor0
----
2704
4446
918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 col1 FROM tab1, tab0 AS cor0
----
10
13
26

query I rowsort
SELECT tab0.col1 * ( 18 ) + + col2 AS col0 FROM tab0
----
1581
1720
1747

onlyif mysql # use DIV operator for integer division
query I rowsort label-6587
SELECT col2 + col2 DIV col1 col0 FROM tab1 AS cor0
----
103
56
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6587
SELECT col2 + col2 / col1 col0 FROM tab1 AS cor0
----
103
56
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6588
SELECT ALL - col0 + CAST( NULL AS SIGNED ) + + cor0.col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6588
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) + + cor0.col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6589
SELECT col0 * - CAST( - col2 * - col2 AS SIGNED ) FROM tab2 cor0
----
-114076
-5103
-52728

skipif mysql # not compatible
query I rowsort label-6589
SELECT col0 * - CAST ( - col2 * - col2 AS INTEGER ) FROM tab2 cor0
----
-114076
-5103
-52728

query I rowsort
SELECT DISTINCT + col2 + ( + col0 ) * col1 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + col2 + ( + 5 ) AS col1 FROM tab2 AS cor0
----
31
32
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-6592
SELECT - col2 * + cor0.col2 + cor0.col1 DIV - col0 FROM tab2 cor0
----
-1444
-676
-733

skipif mysql # not compatible
query I rowsort label-6592
SELECT - col2 * + cor0.col2 + cor0.col1 / - col0 FROM tab2 cor0
----
-1444
-676
-733

onlyif mysql # use DIV operator for integer division
query I rowsort label-6593
SELECT - col2 + col0 DIV + 16 FROM tab1 AS cor0
----
-53
-54
-91

skipif mysql # not compatible
query I rowsort label-6593
SELECT - col2 + col0 / + 16 FROM tab1 AS cor0
----
-53
-54
-91

query I rowsort
SELECT - - col1 * + 70 AS col1 FROM tab2 AS cor0
----
1190
2170
4130

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6595
SELECT DISTINCT col0 * CAST( - col2 AS SIGNED ) AS col1 FROM tab1 cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-6595
SELECT DISTINCT col0 * CAST ( - col2 AS INTEGER ) AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col2 * - 84 + col1 FROM tab2 AS cor0
----
-2125
-2237
-3175

query I rowsort
SELECT - tab0.col1 * 80 * cor0.col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to fa3d7b8532ff2a0cc5276535ee96637b

query I rowsort
SELECT DISTINCT + col2 * ( + 97 ) + col2 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT DISTINCT col0 + 89 FROM tab1 cor0
----
153
169
92

query I rowsort
SELECT ALL col1 * 39 + 63 + cor0.col1 FROM tab1 AS cor0
----
1103
463
583

query I rowsort
SELECT - - col2 + cor0.col1 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col2 * + col0 + + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6603
SELECT ALL col0 + col0 DIV col1 col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6603
SELECT ALL col0 + col0 / col1 col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + ( col1 ) * 90 - - col0 AS col1 FROM tab2 AS cor0
----
1609
2797
5388

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6605
SELECT DISTINCT + + ( - col2 ) * CAST( - col0 AS SIGNED ) + col0 * - col0 FROM tab0 AS cor0
----
-1190
-623
216

skipif mysql # not compatible
query I rowsort label-6605
SELECT DISTINCT + + ( - col2 ) * CAST ( - col0 AS INTEGER ) + col0 * - col0 FROM tab0 AS cor0
----
-1190
-623
216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6606
SELECT + cor0.col1 DIV - col0 + ( col2 ) AS col2 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-6606
SELECT + cor0.col1 / - col0 + ( col2 ) AS col2 FROM tab2 AS cor0
----
23
26
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 15 * + col2 * 73 col1 FROM tab0 cor0
----
-1095
-36135
-89790

onlyif mysql # use DIV operator for integer division
query I rowsort label-6608
SELECT + col1 * col0 DIV cor0.col1 + + col0 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-6608
SELECT + col1 * col0 / cor0.col1 + + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL - col2 + col0 * - col0 * - ( col0 ) AS col0 FROM tab2 AS cor0
----
316
474526
493001

query I rowsort
SELECT DISTINCT - - 65 - col2 AS col1 FROM tab2 AS cor0
----
27
38
39

query I rowsort
SELECT DISTINCT - 89 + + col0 * col1 * - col2 FROM tab0 AS cor0
----
-3484
-664207
-68201

query I rowsort
SELECT ALL col2 + + cor0.col0 - + 15 AS col0 FROM tab0 AS cor0
----
156
21
42

query I rowsort
SELECT + 62 * col0 + 78 * col0 FROM tab2 AS cor0
----
10920
11060
980

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT ALL - 90 DIV - col2 col0 FROM tab0 AS cor0
----
1
2
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6614
SELECT ALL - 90 / - col2 col0 FROM tab0 AS cor0
----
1
2
90

query I rowsort
SELECT DISTINCT + 99 * + col0 - - 62 AS col0 FROM tab2 AS cor0
----
755
7784
7883

query I rowsort
SELECT 43 * col2 - - 94 FROM tab0 AS cor0
----
137
1513
3620

query I rowsort
SELECT + col1 * + 66 + cor0.col2 FROM tab1 AS cor0
----
1770
717
954

query I rowsort
SELECT ALL + - col1 * 1 + + col1 * col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + col0 * 77 - cor0.col2 FROM tab0 AS cor0
----
1815
2694
6771

query I rowsort
SELECT + - col2 * 40 + col0 AS col1 FROM tab0 AS cor0
----
-1296
-3191
-5

query I rowsort
SELECT ALL col2 * + 62 * col1 + + col0 FROM tab1 AS cor0
----
35404
77456
87051

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6622
SELECT - cor0.col0 + cor0.col2 / - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6622
SELECT - cor0.col0 + cor0.col2 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 69 + + cor0.col2 * 84 FROM tab1 AS cor0
----
4605
4857
8133

onlyif mysql # use DIV operator for integer division
query I rowsort label-6624
SELECT - - col2 + col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-6624
SELECT - - col2 + col2 / + col0 AS col0 FROM tab2 AS cor0
----
26
30
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 63 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT ALL + ( - ( tab1.col2 ) ) FROM tab1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6627
SELECT + CAST( + col0 + + col2 AS SIGNED ) col2 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6627
SELECT + CAST ( + col0 + + col2 AS INTEGER ) col2 FROM tab2
----
104
117
34

query I rowsort
SELECT + - col1 * - col0 * col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT 37 + - 16 AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT ALL - 29 + col0 AS col0 FROM tab1
----
-26
35
51

query I rowsort
SELECT ALL 78 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab1 AS cor2, tab1
----
13122 values hashing to d94743f8f1f710b9dfc9a965edd78750

query I rowsort
SELECT + + col0 * + 78 + col0 FROM tab1 AS cor0
----
237
5056
6320

query I rowsort
SELECT DISTINCT - - 56 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + 4 * 46 + + col1 col0 FROM tab1 AS cor0
----
213
258
277

onlyif mysql # use DIV operator for integer division
query I rowsort label-6636
SELECT DISTINCT col2 + col1 DIV - col2 + col1 AS col1 FROM tab0 AS cor0
----
1
117
172

skipif mysql # not compatible
query I rowsort label-6636
SELECT DISTINCT col2 + col1 / - col2 + col1 AS col1 FROM tab0 AS cor0
----
1
117
172

query I rowsort
SELECT ALL + + col1 + ( + cor0.col0 ) AS col2 FROM tab1 cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6638
SELECT ALL + - col0 + 15 * - col0 * col2 + col1 * - col1 DIV col1 FROM tab1 AS cor0
----
-115293
-2459
-54794

skipif mysql # not compatible
query I rowsort label-6638
SELECT ALL + - col0 + 15 * - col0 * col2 + col1 * - col1 / col1 FROM tab1 AS cor0
----
-115293
-2459
-54794

onlyif mysql # use DIV operator for integer division
query I rowsort label-6639
SELECT + 6 + - col2 * col2 DIV + 92 FROM tab1 AS cor0
----
-25
-29
-94

skipif mysql # not compatible
query I rowsort label-6639
SELECT + 6 + - col2 * col2 / + 92 FROM tab1 AS cor0
----
-25
-29
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col2 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT + ( - col0 ) * - col1 AS col1 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + 37 AS REAL ) * col0 + col2 FROM tab2 AS cor0
----
286
2912
2961

query I rowsort
SELECT + 37 + + col1 * cor0.col2 FROM tab1 AS cor0
----
1285
1441
607

query I rowsort
SELECT - - ( - 94 ) - + col1 AS col1 FROM tab1 AS cor0
----
-104
-107
-120

query I rowsort
SELECT + cor0.col0 * - col0 + - col2 AS col1 FROM tab2 AS cor0
----
-6110
-6279
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6646
SELECT ALL col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6646
SELECT ALL col0 / - col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL ( - col2 ) + col2 * - col0 FROM tab2 cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-6648
SELECT ALL + - col1 + col1 DIV col0 AS col1 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-6648
SELECT ALL + - col1 + col1 / col0 AS col1 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT DISTINCT - 18 + col2 AS col2 FROM tab1 AS cor0
----
36
39
78

query I rowsort
SELECT DISTINCT + cor0.col2 * + 4 + 14 FROM tab0, tab2 AS cor0
----
118
122
166

query I rowsort
SELECT - 85 + cor0.col2 AS col0 FROM tab2 AS cor0
----
-47
-58
-59

query I rowsort
SELECT ALL + col0 * col2 + + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT col1 * col2 * - col2 AS col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - col2 * 88 AS col1 FROM tab1 AS cor0
----
-4752
-5016
-8448

onlyif mysql # use DIV operator for integer division
query I rowsort label-6655
SELECT ALL - + col0 DIV 31 AS col1 FROM tab0 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6655
SELECT ALL - + col0 / 31 AS col1 FROM tab0 cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT + col2 * col0 * - col2 + + 83 FROM tab0 AS cor0
----
-26053
-598353
48

query I rowsort
SELECT DISTINCT + col1 * + cor0.col0 AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL cor0.col2 + 72 AS col0 FROM tab2 AS cor0
----
110
98
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6659
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + 70 + col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6659
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + 70 + col2 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + - col0 * - col2 FROM tab0 cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6661
SELECT DISTINCT + col0 + col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-6661
SELECT DISTINCT + col0 + col2 / - col0 AS col2 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT DISTINCT ( 35 ) FROM tab2 AS cor0
----
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6663
SELECT DISTINCT - 21 DIV 96 AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6663
SELECT DISTINCT - 21 / 96 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - col2 * - col0 - + col0 * ( + col0 ) FROM tab0 AS cor0
----
-1190
-623
216

query I rowsort
SELECT 74 * 34 * col0 FROM tab1 AS cor0
----
161024
201280
7548

onlyif mysql # use DIV operator for integer division
query I rowsort label-6666
SELECT ALL - cor0.col1 DIV col1 + cor0.col1 * + 45 AS col2 FROM tab0 AS cor0
----
3869
4094
4364

skipif mysql # not compatible
query I rowsort label-6666
SELECT ALL - cor0.col1 / col1 + cor0.col1 * + 45 AS col2 FROM tab0 AS cor0
----
3869
4094
4364

query I rowsort
SELECT - 83 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

onlyif mysql # use DIV operator for integer division
query I rowsort label-6668
SELECT col1 + + col1 * col0 DIV tab2.col0 FROM tab2
----
118
34
62

skipif mysql # not compatible
query I rowsort label-6668
SELECT col1 + + col1 * col0 / tab2.col0 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - ( + col1 ) * + 23 + + col2 AS col1 FROM tab1 AS cor0
----
-173
-203
-544

onlyif mysql # use DIV operator for integer division
query I rowsort label-6670
SELECT ALL + 65 DIV - cor0.col2 - + 43 FROM tab1 AS cor0
----
-43
-44
-44

skipif mysql # not compatible
query I rowsort label-6670
SELECT ALL + 65 / - cor0.col2 - + 43 FROM tab1 AS cor0
----
-43
-44
-44

query I rowsort
SELECT + - ( col2 ) + 14 FROM tab1 cor0
----
-40
-43
-82

query I rowsort
SELECT ALL + + 1 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + - ( - col2 ) + ( + col1 ) AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - - col1 + col1 * 87 AS col2 FROM tab0 AS cor0
----
7568
8008
8536

query I rowsort
SELECT ALL 20 + - col1 FROM tab2 AS cor0
----
-11
-39
3

query I rowsort
SELECT DISTINCT 94 + - col2 + + ( + col1 ) AS col1 FROM tab0 cor0
----
103
147
190

query I rowsort
SELECT col2 * - col0 + + 31 FROM tab1 AS cor0
----
-131
-3617
-7649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 11 col2 FROM tab2 AS cor0
----
11
11
11

query I rowsort
SELECT 93 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT DISTINCT - col2 * 1 * - col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + - col2 * - col1 + col1 - col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + ( col0 ) * - col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col2 + 87 FROM tab1 cor0
----
141
144
183

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6684
SELECT + CAST( NULL AS SIGNED ) * + col2 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6684
SELECT + CAST ( NULL AS INTEGER ) * + col2 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 98 + ( col1 ) AS col2 FROM tab2 cor0
----
-39
-67
-81

query I rowsort
SELECT ALL + ( - col0 ) + col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6687
SELECT ALL CAST( col1 AS SIGNED ) * + col1 + 69 * + tab1.col2 AS col0 FROM tab1
----
4033
4402
6793

skipif mysql # not compatible
query I rowsort label-6687
SELECT ALL CAST ( col1 AS INTEGER ) * + col1 + 69 * + tab1.col2 AS col0 FROM tab1
----
4033
4402
6793

query I rowsort
SELECT DISTINCT 6 * + col1 * + col2 AS col0 FROM tab0 cor0
----
17028
44772
582

query I rowsort
SELECT ALL + ( col0 ) * col2 + + cor0.col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT col0 * + 8 + col0 + col1 FROM tab2 AS cor0
----
728
761
94

query I rowsort
SELECT 55 + - cor0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e4e30d5c2dfade8b541004dcf33d5bef

query I rowsort
SELECT - col2 + - 91 - col2 * + col1 FROM tab0
----
-189
-2962
-7635

query I rowsort
SELECT 82 + col1 AS col2 FROM tab2 AS cor0
----
113
141
99

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 + - col1 * ( + col1 + col2 ) * col0 AS col2 FROM tab0 cor0
----
-1408589
-248454
-332807

query I rowsort
SELECT DISTINCT ( - 1 ) - col0 AS col1 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT col2 * + col1 + 6 * - 12 AS col2 FROM tab1 cor0
----
1176
1332
498

query I rowsort
SELECT col1 * 57 * - col0 AS col2 FROM tab0
----
-117648
-193515
-461643

query I rowsort
SELECT ALL + col0 * + col0 + - 12 + 30 AS col0 FROM tab1 AS cor0
----
27
4114
6418

onlyif mysql # use DIV operator for integer division
query I rowsort label-6699
SELECT ALL - ( cor0.col2 ) DIV + 74 - + col0 FROM tab0 AS cor0
----
-24
-35
-90

skipif mysql # not compatible
query I rowsort label-6699
SELECT ALL - ( cor0.col2 ) / + 74 - + col0 FROM tab0 AS cor0
----
-24
-35
-90

query I rowsort
SELECT ALL - col1 + - col2 AS col2 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT ALL col0 * 22 + tab0.col0 * col1 AS col0 FROM tab0
----
10057
2592
4165

query I rowsort
SELECT + 80 * - col1 + + col1 AS col1 FROM tab2
----
-1343
-2449
-4661

query I rowsort
SELECT DISTINCT ( col2 * col0 ) + 43 FROM tab2
----
2071
232
3045

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( tab1.col2 ) + col2 col2 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 3 col1 FROM tab2
----
-3
-3
-3

query I rowsort
SELECT + 66 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT - + col0 + col2 + + col1 AS col1 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT + cor0.col1 + - col2 * - 68 FROM tab0 AS cor0
----
165
2330
5667

query I rowsort
SELECT ALL col0 + + ( col2 ) + col0 * ( + col1 ) FROM tab0
----
2121
3431
8270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col2 FROM tab2, tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6711
SELECT - tab0.col0 * - CAST( NULL AS SIGNED ) / + 37 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6711
SELECT - tab0.col0 * - CAST ( NULL AS INTEGER ) / + 37 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6712
SELECT + + col1 DIV col1 + col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6712
SELECT + + col1 / col1 + col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + 95 * - tab2.col0 FROM tab2
----
-665
-7410
-7505

query I rowsort
SELECT 67 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT + 67 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6716
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab2, tab1, tab1 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6716
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab2, tab1, tab1 AS cor0, tab1 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6717
SELECT + 90 DIV - col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-90

skipif mysql # not compatible
query I rowsort label-6717
SELECT + 90 / - col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-90

query I rowsort
SELECT + - 90 + col0 AS col2 FROM tab2 cor0
----
-11
-12
-83

query I rowsort
SELECT ALL - col2 * ( + col0 ) + - col0 AS col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT - 12 FROM tab0, tab2 AS cor0
----
-12

query I rowsort
SELECT tab2.col0 + 92 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 6ca4b2cdfad956991591f91381792f68

onlyif mysql # use DIV operator for integer division
query I rowsort label-6722
SELECT ALL - col2 DIV + 29 AS col0 FROM tab1 AS cor0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-6722
SELECT ALL - col2 / + 29 AS col0 FROM tab1 AS cor0
----
-1
-1
-3

query I rowsort
SELECT ALL + 15 * col2 FROM tab0 cor0
----
1230
15
495

query I rowsort
SELECT 68 * col1 + - col0 FROM tab0 AS cor0
----
5824
6099
6561

query I rowsort
SELECT DISTINCT + 19 + - 70 FROM tab2 AS cor0
----
-51

query I rowsort
SELECT 54 - col2 AS col0 FROM tab2 AS cor0
----
16
27
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-6727
SELECT + ( + 43 ) * + col1 DIV - col1 col2 FROM tab0 AS cor0
----
-43
-43
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6727
SELECT + ( + 43 ) * + col1 / - col1 col2 FROM tab0 AS cor0
----
-43
-43
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - ( 86 ) * col1 - 70 AS col2 FROM tab2 cor0
----
-1532
-2736
-5144

query I rowsort
SELECT ALL col0 * 85 FROM tab1 AS cor0
----
255
5440
6800

query I rowsort
SELECT - + col0 - col1 * - col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT col0 * col1 + + col2 + col0 FROM tab1
----
1216
135
761

onlyif mysql # use DIV operator for integer division
query I rowsort label-6733
SELECT ALL col2 DIV - col0 - 92 AS col0 FROM tab0
----
-92
-92
-93

skipif mysql # not compatible
query I rowsort label-6733
SELECT ALL col2 / - col0 - 92 AS col0 FROM tab0
----
-92
-92
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6734
SELECT col1 * CAST( NULL AS SIGNED ) + + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6734
SELECT col1 * CAST ( NULL AS INTEGER ) + + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6735
SELECT - col1 + - CAST( NULL AS SIGNED ) * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6735
SELECT - col1 + - CAST ( NULL AS INTEGER ) * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - col2 + + 89 FROM tab1 AS cor0
----
-1159
-1315
-481

query I rowsort
SELECT ALL - cor0.col2 + 20 AS col0 FROM tab1 AS cor0
----
-34
-37
-76

query I rowsort
SELECT - col2 * col1 * - col2 + - col1 AS col0 FROM tab1 AS cor0
----
119795
32480
75790

query I rowsort
SELECT + + cor0.col0 * col1 * col1 + + col1 FROM tab1 cor0
----
13533
2054
6410

query I rowsort
SELECT DISTINCT - col0 + + 65 AS col2 FROM tab2 AS cor0
----
-13
-14
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6741
SELECT ALL + CAST( + 97 AS SIGNED ) FROM tab2 AS cor0
----
97
97
97

skipif mysql # not compatible
query I rowsort label-6741
SELECT ALL + CAST ( + 97 AS INTEGER ) FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT DISTINCT + col1 * col0 + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6743
SELECT - col2 * + cor0.col0 DIV col0 + col0 FROM tab2 AS cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-6743
SELECT - col2 * + cor0.col0 / col0 + col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - + cor0.col0 * 14 AS col0 FROM tab0 cor0
----
-1246
-336
-490

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col1 col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + col2 + col1 * + cor0.col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6747
SELECT - col2 + ( col1 ) * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6747
SELECT - col2 + ( col1 ) * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + - 20 AS col0 FROM tab1 AS cor0
----
-17
44
60

query I rowsort
SELECT ALL + + col1 * col0 * col1 AS col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT - col2 + ( + col1 ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + ( - col1 ) * ( col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col0 * col0 * ( col0 + - col2 ) FROM tab0 AS cor0
----
-41650
-55447
5184

query I rowsort
SELECT - col0 * + cor0.col1 * 91 AS col1 FROM tab1 AS cor0
----
-58240
-7098
-94640

query I rowsort
SELECT DISTINCT + 47 AS col2 FROM tab2, tab1 AS cor0
----
47

query I rowsort
SELECT ALL - col0 * + 95 + 29 FROM tab0 AS cor0
----
-2251
-3296
-8426

query I rowsort
SELECT - col0 - + ( col0 ) * - cor0.col0 AS col0 FROM tab0 AS cor0
----
1190
552
7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 - col1 col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT - col2 * - col1 * col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - + col2 + - ( col0 ) AS col0 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6760
SELECT + col0 DIV - col0 col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6760
SELECT + col0 / - col0 col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col0 * 70 FROM tab1 AS cor0
----
-210
-4480
-5600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6762
SELECT + col2 DIV - 63 AS col2 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6762
SELECT + col2 / - 63 AS col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT col1 * col0 + + ( cor0.col1 * col2 + - 9 ) AS col2 FROM tab2 cor0
----
1045
1980
6127

query I rowsort
SELECT ALL + col1 * col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
1381
244
4628

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab0 AS cor0 WHERE NULL < NULL
----

query I rowsort
SELECT 95 + col2 FROM tab2
----
121
122
133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - tab1.col1 - + col0 col0 FROM tab1
----
-1120
-704
-81

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 82e15d5967b272804e574774895a0222

query I rowsort
SELECT DISTINCT + cor1.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT + col2 + 57 - 9 FROM tab2
----
74
75
86

query I rowsort
SELECT DISTINCT + col0 + + ( - col1 ) FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT + - col1 + col2 * 42 FROM tab1 AS cor0
----
2242
2384
4019

query I rowsort
SELECT DISTINCT - col1 * + col0 + - 77 + tab0.col0 * 76 FROM tab0
----
-1412
-317
-812

query I rowsort
SELECT + col2 + - cor0.col1 * + 64 FROM tab0 AS cor0
----
-5471
-5742
-6207

query I rowsort
SELECT ALL + cor0.col0 * cor0.col1 + + ( + col0 ) FROM tab2 AS cor0
----
1422
224
4680

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0, tab0 cor1, tab2, tab1 AS cor2
----
3645 values hashing to 4c5172baaab682f997bd09d2b5cf0d22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 53 * - col1 * 23 col2 FROM tab2 cor0
----
20723
37789
71921

query I rowsort
SELECT cor0.col1 + + cor0.col2 * + ( 78 ) AS col2 FROM tab0 AS cor0
----
175
2660
6487

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL 14 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 10 + + col1 col0 FROM tab2 AS cor0
----
27
41
69

query I rowsort
SELECT ALL col0 * ( col2 * - col0 ) + + col1 FROM tab1
----
-233462
-460
-614387

query I rowsort
SELECT - 89 + + col2 AS col2 FROM tab1 AS cor0
----
-32
-35
7

query I rowsort
SELECT ALL col0 * 89 + col0 * col1 AS col0 FROM tab2
----
11544
8374
840

query I rowsort
SELECT ALL col1 + - ( - col0 + - col2 ) FROM tab1
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6786
SELECT DISTINCT + cor0.col0 * col0 + col0 DIV col2 + col1 DIV col2 FROM tab1 AS cor0
----
4097
6400
9

skipif mysql # not compatible
query I rowsort label-6786
SELECT DISTINCT + cor0.col0 * col0 + col0 / col2 + col1 / col2 FROM tab1 AS cor0
----
4097
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6787
SELECT - col0 + CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-6787
SELECT - col0 + CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - cor0.col1 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0 cor2
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - + col0 * ( col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ( + col1 ) + + col1 AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT - 67 * col2 AS col0 FROM tab2
----
-1742
-1809
-2546

query I rowsort
SELECT ALL ( + tab1.col1 ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL ( + 71 ) FROM tab2
----
71
71
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6795
SELECT DISTINCT CAST( - 7 AS SIGNED ) AS col1 FROM tab0
----
-7

skipif mysql # not compatible
query I rowsort label-6795
SELECT DISTINCT CAST ( - 7 AS INTEGER ) AS col1 FROM tab0
----
-7

query I rowsort
SELECT ALL + ( 11 ) + col0 FROM tab1 AS cor0
----
14
75
91

query I rowsort
SELECT ( col1 ) + + col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + - cor0.col2 + + 54 AS col2 FROM tab1 AS cor0
----
-3
-42
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6799
SELECT col2 * ( cor0.col1 ) + CAST( NULL AS SIGNED ) / col2 col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6799
SELECT col2 * ( cor0.col1 ) + CAST ( NULL AS INTEGER ) / col2 col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 21 + - col0 AS col2 FROM tab2 AS cor0
----
-57
-58
14

query I rowsort
SELECT 60 + + col0 FROM tab0
----
149
84
95

query I rowsort
SELECT DISTINCT + 94 FROM tab0
----
94

query I rowsort
SELECT DISTINCT + 37 + col2 FROM tab2
----
63
64
75

query I rowsort
SELECT ( col1 ) + col1 AS col2 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6805
SELECT ALL - ( - col0 ) DIV + cor0.col0 + col0 col0 FROM tab1 AS cor0
----
4
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6805
SELECT ALL - ( - col0 ) / + cor0.col0 + col0 col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT - - 6 + + col0 * 0 FROM tab0 AS cor0
----
6

query I rowsort
SELECT 95 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL + 91 * col0 - 55 AS col1 FROM tab1 AS cor0
----
218
5769
7225

query I rowsort
SELECT + 24 + - col2 AS col2 FROM tab1 AS cor0
----
-30
-33
-72

query I rowsort
SELECT DISTINCT + - col1 * + ( col2 ) + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6811
SELECT + col2 DIV 96 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6811
SELECT + col2 / 96 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6812
SELECT DISTINCT + col2 + CAST( NULL AS SIGNED ) col0 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6812
SELECT DISTINCT + col2 + CAST ( NULL AS INTEGER ) col0 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6813
SELECT ALL - - col2 + - 25 * col2 DIV col1 AS col0 FROM tab1 AS cor0
----
-85
-88
3

skipif mysql # not compatible
query I rowsort label-6813
SELECT ALL - - col2 + - 25 * col2 / col1 AS col0 FROM tab1 AS cor0
----
-85
-88
3

query I rowsort
SELECT DISTINCT + cor0.col2 + - ( + col1 ) * - col0 AS col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col2 * ( - 22 ) + cor0.col2 FROM tab1 AS cor0
----
-1134
-1197
-2016

query I rowsort
SELECT ALL + - col0 * 27 AS col2 FROM tab0 AS cor0
----
-2403
-648
-945

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 AS col0 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT col0 * ( + 41 ) - col0 AS col0 FROM tab1 AS cor0
----
120
2560
3200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + ( - cor0.col1 ) col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT cor0.col2 * 30 + - cor0.col1 FROM tab2 AS cor0
----
1123
721
779

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6821
SELECT DISTINCT + col0 * CAST( + col1 AS SIGNED ) AS col2 FROM tab0 cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6821
SELECT DISTINCT + col0 * CAST ( + col1 AS INTEGER ) AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - - col2 + 35 FROM tab1 AS cor0
----
131
89
92

query I rowsort
SELECT DISTINCT - - col0 + + col0 AS col2 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6824
SELECT - col0 DIV + 32 + + 15 FROM tab0 AS cor0
----
13
14
15

skipif mysql # not compatible
query I rowsort label-6824
SELECT - col0 / + 32 + + 15 FROM tab0 AS cor0
----
13
14
15

query I rowsort
SELECT ALL col0 + 23 - - col2 FROM tab0 cor0
----
194
59
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6826
SELECT ALL - col2 DIV col2 - + ( + col0 ) * - tab1.col2 AS col1 FROM tab1
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-6826
SELECT ALL - col2 / col2 - + ( + col0 ) * - tab1.col2 AS col1 FROM tab1
----
161
3647
7679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 66 + + tab0.col2 + + 2 * + col1 col2 FROM tab0
----
261
271
330

query I rowsort
SELECT ALL + tab1.col0 - - col0 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT + + col1 * + ( - 41 ) FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT - col2 * 65 FROM tab0 AS cor0
----
-2145
-5330
-65

query I rowsort
SELECT - 44 AS col0 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 38f05fdaaf15e64b62f27cd96f73fb79

query I rowsort
SELECT - col0 + - col2 + col0 * tab1.col1 * - col0 AS col1 FROM tab1
----
-291
-41081
-83376

onlyif mysql # use DIV operator for integer division
query I rowsort label-6833
SELECT + ( - col2 ) * col0 * + 9 - ( - cor0.col1 ) DIV col2 FROM tab0 AS cor0
----
-218
-65681
-7126

skipif mysql # not compatible
query I rowsort label-6833
SELECT + ( - col2 ) * col0 * + 9 - ( - cor0.col1 ) / col2 FROM tab0 AS cor0
----
-218
-65681
-7126

onlyif mysql # use DIV operator for integer division
query I rowsort label-6834
SELECT + ( col1 ) * + col1 - - ( + cor0.col1 ) DIV col1 FROM tab1 AS cor0
----
101
170
677

skipif mysql # not compatible
query I rowsort label-6834
SELECT + ( col1 ) * + col1 - - ( + cor0.col1 ) / col1 FROM tab1 AS cor0
----
101
170
677

query I rowsort
SELECT 31 + - col0 FROM tab1 AS cor0
----
-33
-49
28

query I rowsort
SELECT - 26 + - ( + col0 ) AS col1 FROM tab0 AS cor0
----
-115
-50
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-6837
SELECT - col2 DIV 87 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6837
SELECT - col2 / 87 FROM tab1
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6838
SELECT col2 + CAST( col0 AS SIGNED ) * col2 FROM tab0
----
36
7380
825

skipif mysql # not compatible
query I rowsort label-6838
SELECT col2 + CAST ( col0 AS INTEGER ) * col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT col2 * + 25 AS col1 FROM tab0
----
2050
25
825

query I rowsort
SELECT DISTINCT col1 + - col2 * col0 FROM tab1
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 * + col1 col2 FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT - - 79 * col1 AS col1 FROM tab2 AS cor0
----
1343
2449
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 col1 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT ( - col0 ) * + cor0.col0 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-6845
SELECT DISTINCT col2 DIV + 58 col1 FROM tab1
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6845
SELECT DISTINCT col2 / + 58 col1 FROM tab1
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 + col2 col0 FROM tab0
----
123
172
91

query I rowsort
SELECT ALL + 59 * - tab0.col2 * + col2 AS col0 FROM tab0
----
-396716
-59
-64251

query I rowsort
SELECT ALL - ( - col0 ) * 85 FROM tab2 AS cor0
----
595
6630
6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-6849
SELECT ALL + 58 DIV + col1 FROM tab1 AS cor0
----
2
4
5

skipif mysql # not compatible
query I rowsort label-6849
SELECT ALL + 58 / + col1 FROM tab1 AS cor0
----
2
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * col1 col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6851
SELECT - 61 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6851
SELECT - 61 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - ( + col1 + - col0 ) AS col0 FROM tab0
----
-2
-62

query I rowsort
SELECT - 0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - 55 * 44 * col0 AS col2 FROM tab2
----
-16940
-188760
-191180

query IIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 WHERE NOT NULL NOT IN ( cor0.col0 )
----

query I rowsort
SELECT ALL + cor1.col1 * 71 * cor0.col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4ad22b0cf78e2122adc4f1ab0060062d

query I rowsort
SELECT - + 43 * - col1 * - col0 + + 70 * + col0 + - col0 * + cor0.col1 FROM tab1 AS cor0
----
-23680
-3222
-40160

query I rowsort
SELECT - cor0.col2 * - col0 + - ( col2 * col0 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + col0 + cor0.col2 * 30 * col0 AS col2 FROM tab1 AS cor0
----
109504
230480
4863

query I rowsort
SELECT - - cor0.col1 + col0 * + 14 FROM tab2 AS cor0
----
1123
1151
129

onlyif mysql # use DIV operator for integer division
query I rowsort label-6862
SELECT + 20 + - col0 DIV - CAST( + col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
20
20
20

skipif mysql # not compatible
query I rowsort label-6862
SELECT + 20 + - col0 / - CAST ( + col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT + - 82 * + col2 * ( col1 ) - cor0.col1 AS col0 FROM tab1 AS cor0
----
-102349
-115154
-46750

onlyif mysql # use DIV operator for integer division
query I rowsort label-6864
SELECT ALL - col0 DIV - col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6864
SELECT ALL - col0 / - col1 AS col2 FROM tab2 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6865
SELECT col2 DIV - col0 + + 18 FROM tab2 cor0
----
15
18
18

skipif mysql # not compatible
query I rowsort label-6865
SELECT col2 / - col0 + + 18 FROM tab2 cor0
----
15
18
18

query I rowsort
SELECT DISTINCT ( 45 ) FROM tab0
----
45

query I rowsort
SELECT + + 56 * col1 AS col2 FROM tab2 AS cor0
----
1736
3304
952

query I rowsort
SELECT + col2 * - col2 - col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT + 57 * + col2 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT ALL + - col0 + + col2 + col1 * cor0.col0 AS col2 FROM tab1 cor0
----
1056
129
633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 + col0 * col0 * col0 col1 FROM tab1 AS cor0
----
104
262221
512077

query I rowsort
SELECT - col1 * ( cor0.col1 ) FROM tab1 AS cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6873
SELECT + col1 DIV col0 + - col2 FROM tab2 AS cor0
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-6873
SELECT + col1 / col0 + - col2 FROM tab2 AS cor0
----
-23
-26
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col1 + cor0.col1 * - col1 * ( + ( cor0.col1 ) ) col1 FROM tab2 AS cor0
----
-208860
-30752
-5202

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6875
SELECT - col1 + + CAST( + 99 AS SIGNED ) FROM tab2 AS cor0
----
40
68
82

skipif mysql # not compatible
query I rowsort label-6875
SELECT - col1 + + CAST ( + 99 AS INTEGER ) FROM tab2 AS cor0
----
40
68
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6876
SELECT - + col2 * - CAST( 62 AS SIGNED ) * - col0 AS col2 FROM tab1 AS cor0
----
-10044
-226176
-476160

skipif mysql # not compatible
query I rowsort label-6876
SELECT - + col2 * - CAST ( 62 AS INTEGER ) * - col0 AS col2 FROM tab1 AS cor0
----
-10044
-226176
-476160

query I rowsort
SELECT DISTINCT ( - 27 ) FROM tab1 AS cor0
----
-27

query I rowsort
SELECT + cor0.col0 * + cor0.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 8ec1e5b752a6eed5f6e85ed78b46af3c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6879
SELECT - ( + col1 ) * + cor0.col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6879
SELECT - ( + col1 ) * + cor0.col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 27 + cor0.col0 col0 FROM tab0 AS cor0
----
-3
62
8

query I rowsort
SELECT DISTINCT 44 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
44

query I rowsort
SELECT - tab2.col2 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1, tab1 cor2
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

query I rowsort
SELECT ALL - col2 + + col0 * cor0.col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + - ( - 39 ) AS col0 FROM tab2 AS cor0
----
39
39
39

query I rowsort
SELECT DISTINCT - + 49 - 26 FROM tab1 cor0
----
-75

query I rowsort
SELECT ALL col2 * - col0 * - col2 AS col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + - col0 * + col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT 76 * + cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
2541
6314
77

query I rowsort
SELECT ALL + cor0.col2 * 98 FROM tab0 cor0
----
3234
8036
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6891
SELECT DISTINCT - CAST( + col0 AS SIGNED ) * - cor0.col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6891
SELECT DISTINCT - CAST ( + col0 AS INTEGER ) * - cor0.col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 * - ( + col2 ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col2 - - col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + + 99 * - col2 FROM tab0 AS cor0
----
-3267
-8118
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6895
SELECT DISTINCT CAST( NULL AS SIGNED ) - - 66 col2 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6895
SELECT DISTINCT CAST ( NULL AS INTEGER ) - - 66 col2 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL - 49 + + col2 * col1 FROM tab1 AS cor0
----
1199
1355
521

query I rowsort
SELECT - - col2 + - col0 * col1 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL 8 * - 71 + - col1 * ( col1 ) AS col1 FROM tab0 cor0
----
-7964
-8849
-9977

query I rowsort
SELECT 69 * col1 AS col2 FROM tab1 AS cor0
----
1794
690
897

query I rowsort
SELECT ALL + col1 * - 83 * + col1 FROM tab0
----
-613868
-687323
-780947

query I rowsort
SELECT DISTINCT - + 37 FROM tab2, tab0 AS cor0, tab0, tab1 cor1
----
-37

query I rowsort
SELECT 71 + 26 AS col0 FROM tab2
----
97
97
97

query I rowsort
SELECT col1 + + 45 * cor0.col2 AS col2 FROM tab0 AS cor0
----
142
1571
3781

query I rowsort
SELECT ALL - col1 + col1 + col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6905
SELECT ALL + col0 * ( + col0 ) + + cor0.col1 * CAST( + 68 AS SIGNED ) FROM tab2 AS cor0
----
10096
2157
7397

skipif mysql # not compatible
query I rowsort label-6905
SELECT ALL + col0 * ( + col0 ) + + cor0.col1 * CAST ( + 68 AS INTEGER ) FROM tab2 AS cor0
----
10096
2157
7397

query I rowsort
SELECT ALL + cor1.col0 AS col0 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6907
SELECT ALL tab2.col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6907
SELECT ALL tab2.col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 - - 19 * col0 FROM tab0
----
1602
432
630

query I rowsort
SELECT col0 * + ( - col0 ) - - tab2.col0 * ( ( col0 ) ) AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL col2 * 17 + + 42 AS col2 FROM tab0
----
1436
59
603

onlyif mysql # use DIV operator for integer division
query I rowsort label-6911
SELECT DISTINCT col0 + + col2 DIV col1 + + col1 AS col0 FROM tab1
----
100
31
79

skipif mysql # not compatible
query I rowsort label-6911
SELECT DISTINCT col0 + + col2 / col1 + + col1 AS col0 FROM tab1
----
100
31
79

query I rowsort
SELECT + - cor0.col2 * - 70 + col0 + col2 AS col0 FROM tab2 AS cor0
----
1924
1924
2777

query I rowsort
SELECT DISTINCT - col0 * - ( col2 ) AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + - col0 - + col2 AS col1 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT - col1 + - ( col1 ) FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT - - col2 + + ( + col2 ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + col1 * 30 AS col1 FROM tab2 AS cor0
----
1770
510
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * ( cor0.col0 ) col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + - col1 * col1 - + 16 AS col2 FROM tab2 AS cor0
----
-305
-3497
-977

query I rowsort
SELECT col1 * col0 * 72 FROM tab1 cor0
----
46080
5616
74880

query I rowsort
SELECT ALL cor0.col2 * + ( + cor0.col2 * col0 ) FROM tab1 cor0
----
207936
737280
8748

query I rowsort
SELECT + col2 - + 64 AS col1 FROM tab2 AS cor0
----
-26
-37
-38

query I rowsort
SELECT - col1 * 6 + 94 * col1 FROM tab1 cor0
----
1144
2288
880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6924
SELECT col2 - - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6924
SELECT col2 - - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to d6a6e32c6adcc8525ed3eb7827781237

query I rowsort
SELECT cor0.col1 * + ( col1 ) + col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT cor0.col2 + + ( col1 ) * col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL - 63 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

query I rowsort
SELECT + 29 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 40739d223aa019bd2dfe2db99d596302

onlyif mysql # use DIV operator for integer division
query I rowsort label-6930
SELECT DISTINCT - 0 DIV - col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-6930
SELECT DISTINCT - 0 / - col1 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6931
SELECT col2 DIV col0 + - col1 AS col1 FROM tab0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-6931
SELECT col2 / col0 + - col1 AS col1 FROM tab0
----
-85
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + - cor0.col2 * - col2 * - col0 col2 FROM tab0 AS cor0
----
-26112
-598347
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6933
SELECT CAST( NULL AS SIGNED ) / + ( - cor0.col0 ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6933
SELECT CAST ( NULL AS INTEGER ) / + ( - cor0.col0 ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - - 36 AS col1 FROM tab0 AS cor0
----
36
36
36

query I rowsort
SELECT ALL - 18 * - col1 FROM tab1 AS cor0
----
180
234
468

query I rowsort
SELECT + col0 * + col1 * ( + col1 ) AS col2 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT DISTINCT col2 + col2 * 48 FROM tab0 AS cor0
----
1617
4018
49

query I rowsort
SELECT - - col0 * + cor0.col2 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6939
SELECT + col2 DIV 53 AS col1 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6939
SELECT + col2 / 53 AS col1 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT 17 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT - cor0.col0 + 33 * + col1 AS col1 FROM tab0 AS cor0
----
2814
2914
3166

query I rowsort
SELECT col1 * col1 * - col1 AS col1 FROM tab1
----
-1000
-17576
-2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-6943
SELECT DISTINCT + - 27 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6943
SELECT DISTINCT + - 27 / col1 AS col2 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT - - 33 + tab1.col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to 01ea81fff616ec45028da164594069d2

query I rowsort
SELECT ALL + cor0.col2 + col1 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
195
205
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6946
SELECT col1 * + col2 + + CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6946
SELECT col1 * + col2 + + CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( - cor0.col0 ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col1 + - cor0.col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT 95 * col1 AS col2 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT col1 + ( col1 ) * + 35 * + ( + col0 ) FROM tab2
----
161129
47022
7626

query I rowsort
SELECT - - 3 * col2 AS col1 FROM tab0 cor0
----
246
3
99

query I rowsort
SELECT DISTINCT - + 18 + cor0.col0 AS col0 FROM tab1 cor0
----
-15
46
62

query I rowsort
SELECT - 3 + + col2 FROM tab1 AS cor0
----
51
54
93

query I rowsort
SELECT + cor0.col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT - 38 AS col2 FROM tab0 AS cor0
----
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 91 col2 FROM tab1
----
91
91
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6957
SELECT ALL - CAST( + 60 * - col2 AS SIGNED ) FROM tab2
----
1560
1620
2280

skipif mysql # not compatible
query I rowsort label-6957
SELECT ALL - CAST ( + 60 * - col2 AS INTEGER ) FROM tab2
----
1560
1620
2280

query I rowsort
SELECT - 38 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT col2 * 44 FROM tab2 AS cor0
----
1144
1188
1672

query I rowsort
SELECT 81 * - col0 + col2 FROM tab1 AS cor0
----
-189
-5127
-6384

query I rowsort
SELECT ALL + ( + col0 + col1 ) FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6962
SELECT - + col0 * + 70 + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
-487
-5460
-5530

skipif mysql # not compatible
query I rowsort label-6962
SELECT - + col0 * + 70 + col2 / col0 AS col1 FROM tab2 AS cor0
----
-487
-5460
-5530

query I rowsort
SELECT ALL + 7 * tab2.col1 AS col2 FROM tab2
----
119
217
413

query I rowsort
SELECT ALL + ( col2 ) * - col1 - - col0 FROM tab0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-6965
SELECT - col1 DIV - ( col0 * - col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6965
SELECT - col1 / - ( col0 * - col1 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - col0 + ( col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - col0 * + 44 + col0 AS col1 FROM tab1 AS cor0
----
-129
-2752
-3440

query I rowsort
SELECT col2 * 68 * 97 + + col0 * ( col1 + - col2 ) FROM tab2 AS cor0
----
174070
178120
248989

query I rowsort
SELECT DISTINCT - col0 * 85 AS col0 FROM tab0 AS cor0
----
-2040
-2975
-7565

query I rowsort
SELECT DISTINCT - col2 * col1 * col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - col0 + - ( 83 ) * col0 AS col1 FROM tab1 AS cor0
----
-252
-5376
-6720

query I rowsort
SELECT - - col2 * 64 AS col2 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT DISTINCT col1 + + ( col1 ) * tab0.col0 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + col1 + 75 AS col2 FROM tab0
----
161
166
172

query I rowsort
SELECT DISTINCT col1 + + 19 AS col1 FROM tab1
----
29
32
45

query I rowsort
SELECT + col0 * + 74 FROM tab2
----
518
5772
5846

query I rowsort
SELECT + col0 - ( - 14 + + col1 ) FROM tab2
----
-10
33
76

query I rowsort
SELECT col2 + ( 88 ) FROM tab0
----
121
170
89

query I rowsort
SELECT - col1 * + 59 AS col1 FROM tab2
----
-1003
-1829
-3481

onlyif mysql # use DIV operator for integer division
query I rowsort label-6980
SELECT DISTINCT col2 DIV 9 AS col1 FROM tab0 AS cor0
----
0
3
9

skipif mysql # not compatible
query I rowsort label-6980
SELECT DISTINCT col2 / 9 AS col1 FROM tab0 AS cor0
----
0
3
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6981
SELECT - col1 + - CAST( NULL AS SIGNED ) * + cor0.col2 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6981
SELECT - col1 + - CAST ( NULL AS INTEGER ) * + cor0.col2 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * - ( col1 ) * + cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
-119728
-32426
-75813

query I rowsort
SELECT DISTINCT + + cor0.col2 + 32 FROM tab2 cor0
----
58
59
70

query I rowsort
SELECT + - col2 + + 60 FROM tab0 AS cor0
----
-22
27
59

query I rowsort
SELECT DISTINCT + 21 + col2 FROM tab1 AS cor0
----
117
75
78

query I rowsort
SELECT DISTINCT + col2 + col2 + cor0.col0 FROM tab0 AS cor0
----
253
37
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6987
SELECT ALL + CAST( - ( + col2 ) AS SIGNED ) * - cor0.col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6987
SELECT ALL + CAST ( - ( + col2 ) AS INTEGER ) * - cor0.col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - ( - col1 ) + + col2 * col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + col1 + col0 * cor0.col2 AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + 16 * - 81 FROM tab2 cor0
----
-1296
-1296
-1296

query I rowsort
SELECT DISTINCT - col1 + + col1 + + col2 AS col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col0 * col2 + - col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT 12 + - 95 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-653
-7398
-7493

query I rowsort
SELECT - col0 - 43 AS col0 FROM tab0
----
-132
-67
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6995
SELECT 95 DIV - 26 FROM tab0 AS cor0
----
-3
-3
-3

skipif mysql # not compatible
query I rowsort label-6995
SELECT 95 / - 26 FROM tab0 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT col1 * - 8 FROM tab0 AS cor0
----
-688
-728
-776

onlyif mysql # use DIV operator for integer division
query I rowsort label-6997
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-6997
SELECT + col1 / col0 col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT + 87 * col1 AS col2 FROM tab2 AS cor0
----
1479
2697
5133

query I rowsort
SELECT col1 * cor0.col2 + col2 FROM tab0 cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7000
SELECT + col1 DIV col2 + + col2 col1 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7000
SELECT + col1 / col2 + + col2 col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT + + col1 * col2 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT - col0 * + col2 - col0 AS col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7003
SELECT 69 + col1 * + CAST( - 38 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-311
-425
-919

skipif mysql # not compatible
query I rowsort label-7003
SELECT 69 + col1 * + CAST ( - 38 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-311
-425
-919

query I rowsort
SELECT ALL - 50 + col1 * col2 AS col2 FROM tab1 AS cor0
----
1198
1354
520

query I rowsort
SELECT ALL + + col2 + col0 * + col0 - - cor0.col1 FROM tab1 AS cor0
----
4163
6509
89

query I rowsort
SELECT DISTINCT - + tab1.col0 AS col2 FROM tab1, tab0, tab2 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + + 12 + - col0 FROM tab1 AS cor0
----
-52
-68
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - col2 ) + ( - 60 ) + + cor0.col1 col1 FROM tab2 AS cor0
----
-2
-5
25

query I rowsort
SELECT DISTINCT + col0 * + col1 + + 66 AS col1 FROM tab2 cor0
----
1409
283
4668

onlyif mysql # use DIV operator for integer division
query I rowsort label-7010
SELECT ALL - - col1 DIV + col2 - cor0.col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7010
SELECT ALL - - col1 / + col2 - cor0.col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT cor0.col1 + + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - col2 + 6 - - col2 * + col0 FROM tab0 AS cor0
----
40
7222
765

query I rowsort
SELECT + + cor0.col1 * 62 + + col2 AS col1 FROM tab2 AS cor0
----
1092
1949
3684

query I rowsort
SELECT ALL - cor0.col1 * + col0 + col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7016
SELECT + col0 - - CAST( NULL AS SIGNED ) * - col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7016
SELECT + col0 - - CAST ( NULL AS INTEGER ) * - col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * - col2 + - col2 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL - 27 * 24 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b8962c65d734d62028177f0ace3bf31b

query I rowsort
SELECT ALL tab1.col1 * - col0 + 47 AS col1 FROM tab1
----
-31
-593
-993

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7020
SELECT DISTINCT + - CAST( + 99 AS SIGNED ) FROM tab1 AS cor0
----
-99

skipif mysql # not compatible
query I rowsort label-7020
SELECT DISTINCT + - CAST ( + 99 AS INTEGER ) FROM tab1 AS cor0
----
-99

query I rowsort
SELECT DISTINCT + + 8 + col2 FROM tab1 AS cor0
----
104
62
65

query I rowsort
SELECT DISTINCT col2 * - cor0.col0 + col1 FROM tab0 cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7023
SELECT ALL + 34 DIV col2 + col2 AS col2 FROM tab0 AS cor0
----
34
35
82

skipif mysql # not compatible
query I rowsort label-7023
SELECT ALL + 34 / col2 + col2 AS col2 FROM tab0 AS cor0
----
34
35
82

query I rowsort
SELECT - tab1.col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT 69 * cor0.col2 AS col1 FROM tab1 AS cor0
----
3726
3933
6624

query I rowsort
SELECT - + col1 * 7 AS col1 FROM tab0 AS cor0
----
-602
-637
-679

onlyif mysql # use DIV operator for integer division
query I rowsort label-7027
SELECT col2 * - col1 + col0 DIV col0 FROM tab1
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-7027
SELECT col2 * - col1 + col0 / col0 FROM tab1
----
-1247
-1403
-569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + - col1 col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - + 18 * col1 AS col1 FROM tab1 cor0
----
-180
-234
-468

query I rowsort
SELECT DISTINCT ( - col1 ) + + col2 * + col0 + + col0 AS col2 FROM tab1 AS cor0
----
139
3702
7747

query I rowsort
SELECT + col0 * 1 + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - + col1 * ( - cor0.col1 ) + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT ( 88 ) + - col0 FROM tab0 cor0
----
-1
53
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT + + col1 * col2 + CAST( col2 AS SIGNED ) DIV cor0.col0 FROM tab1 AS cor0
----
1249
1422
570

skipif mysql # not compatible
query I rowsort label-7034
SELECT + + col1 * col2 + CAST ( col2 AS INTEGER ) / cor0.col0 FROM tab1 AS cor0
----
1249
1422
570

query I rowsort
SELECT - + 52 + - col0 AS col0 FROM tab2 AS cor0
----
-130
-131
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7036
SELECT DISTINCT - col2 * + CAST( NULL AS SIGNED ) + col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7036
SELECT DISTINCT - col2 * + CAST ( NULL AS INTEGER ) + col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL + - cor0.col0 * 92 FROM tab1 AS cor0
----
-276
-5888
-7360

query I rowsort
SELECT + cor0.col1 * + 85 + + col1 FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT ALL + col1 + ( cor0.col0 ) FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7040
SELECT ALL + CAST( NULL AS SIGNED ) * cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7040
SELECT ALL + CAST ( NULL AS INTEGER ) * cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT 74 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
74

query I rowsort
SELECT ALL - 44 + + tab1.col1 AS col1 FROM tab1
----
-18
-31
-34

query I rowsort
SELECT - 5 + + cor0.col0 FROM tab0, tab2, tab1 AS cor0, tab0 cor1
----
81 values hashing to e481e4728fbcf23b3103388bdaab8e4c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 51 col1 FROM tab2, tab0 cor0
----
51

query I rowsort
SELECT ALL + col0 * 97 FROM tab0 AS cor0
----
2328
3395
8633

onlyif mysql # use DIV operator for integer division
query I rowsort label-7046
SELECT - col1 DIV col1 + - col1 * col0 AS col0 FROM tab1 AS cor0
----
-1041
-641
-79

skipif mysql # not compatible
query I rowsort label-7046
SELECT - col1 / col1 + - col1 * col0 AS col0 FROM tab1 AS cor0
----
-1041
-641
-79

query I rowsort
SELECT ALL - cor1.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT + col1 + - col2 * - col0 AS col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT 59 FROM tab2, tab1 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + ( col0 ) col0 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT tab1.col0 * - 13 * col1 FROM tab1
----
-1014
-13520
-8320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7052
SELECT ALL CAST( - 76 AS SIGNED ) AS col0 FROM tab2, tab1 cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

skipif mysql # not compatible
query I rowsort label-7052
SELECT ALL CAST ( - 76 AS INTEGER ) AS col0 FROM tab2, tab1 cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

onlyif mysql # use DIV operator for integer division
query I rowsort label-7053
SELECT DISTINCT col1 DIV ( + col2 ) FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-7053
SELECT DISTINCT col1 / ( + col2 ) FROM tab1
----
0

query I rowsort
SELECT DISTINCT + 51 * + col0 FROM tab2
----
357
3978
4029

query I rowsort
SELECT ALL cor0.col2 + - 97 FROM tab1, tab0 cor0
----
9 values hashing to a2d11b2bd1bf2ad5eaaa249b4370d624

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( 29 AS REAL ) * + col0 FROM tab0 AS cor0
----
1015
2581
696

query I rowsort
SELECT - 4 * + cor0.col2 + col2 FROM tab1 cor0
----
-162
-171
-288

query I rowsort
SELECT ALL 11 * + 93 + - cor2.col0 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 217144d386984bcfffcfaecb33cef08f

query I rowsort
SELECT + + 70 + + cor0.col0 FROM tab0 AS cor0
----
105
159
94

query I rowsort
SELECT ALL + 42 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT DISTINCT 94 AS col2 FROM tab1
----
94

query I rowsort
SELECT ALL + col1 + col0 * + 3 FROM tab1 AS cor0
----
202
253
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + - col0 * + CAST ( col0 * + col0 AS REAL ) + + CAST ( - col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
-13857
-42876
-705051

query I rowsort
SELECT - - col1 + ( + cor0.col2 ) AS col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7066
SELECT ALL + - cor0.col1 + + col2 DIV 23 AS col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-7066
SELECT ALL + - cor0.col1 + + col2 / 23 AS col0 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT DISTINCT - col0 + ( - 41 + - col0 ) FROM tab2 cor0
----
-197
-199
-55

query I rowsort
SELECT cor0.col2 * - col1 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT 31 + col1 AS col1 FROM tab1
----
41
44
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7070
SELECT + - col1 DIV - 60 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7070
SELECT + - col1 / - 60 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7071
SELECT ALL - col1 / col1 + + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7071
SELECT ALL - col1 / col1 + + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 + + 37 FROM tab1 AS cor0
----
199
3685
7717

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7073
SELECT - cor0.col1 + + CAST( NULL AS SIGNED ) + 31 * + cor0.col0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7073
SELECT - cor0.col1 + + CAST ( NULL AS INTEGER ) + 31 * + cor0.col0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + - col2 + - col0 - 40 * col1 AS col2 FROM tab1 AS cor0
----
-1097
-521
-696

query I rowsort
SELECT ALL + cor0.col1 * - col1 * + col1 FROM tab2 AS cor0
----
-205379
-29791
-4913

onlyif mysql # use DIV operator for integer division
query I rowsort label-7076
SELECT DISTINCT + cor0.col1 + + 68 * col1 DIV cor0.col0 FROM tab0 AS cor0
----
160
285
329

skipif mysql # not compatible
query I rowsort label-7076
SELECT DISTINCT + cor0.col1 + + 68 * col1 / cor0.col0 FROM tab0 AS cor0
----
160
285
329

query I rowsort
SELECT ALL - - col2 - ( + 63 ) FROM tab1 AS cor0
----
-6
-9
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * + col2 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - cor0.col0 * 47 FROM tab0 AS cor0
----
-1128
-1645
-4183

query I rowsort
SELECT ALL - col0 + col0 * 61 FROM tab2 AS cor0
----
420
4680
4740

query I rowsort
SELECT DISTINCT + - cor0.col2 FROM tab2, tab1, tab1 cor0, tab0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT col0 * col2 + + col0 AS col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT DISTINCT + 44 + - col0 AS col1 FROM tab0
----
-45
20
9

query I rowsort
SELECT ALL col1 * - col0 + + ( ( col0 ) ) * + ( + col1 ) FROM tab1
----
0
0
0

query I rowsort
SELECT col2 * col2 + ( + 60 ) AS col1 FROM tab1
----
2976
3309
9276

query I rowsort
SELECT col0 - col2 * + col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT 71 + col0 FROM tab1
----
135
151
74

query I rowsort
SELECT ALL - + cor0.col0 * ( col1 + + ( col0 ) ) * col0 FROM tab1 AS cor0
----
-261
-303104
-595200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 - 48 col2 FROM tab0 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT + - 30 + - ( + col0 ) * ( 74 ) AS col2 FROM tab1 AS cor0
----
-252
-4766
-5950

query I rowsort
SELECT - 35 AS col1 FROM tab2, tab1 cor0, tab0 cor1
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

query I rowsort
SELECT ALL - 36 AS col1 FROM tab0 AS cor0
----
-36
-36
-36

query I rowsort
SELECT ( - col1 ) - - col0 AS col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT col1 * 72 * tab2.col0 FROM tab2
----
15624
331344
96696

query I rowsort
SELECT DISTINCT + tab2.col0 * ( col1 ) FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7096
SELECT col2 * + CAST( + col0 AS SIGNED ) FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-7096
SELECT col2 * + CAST ( + col0 AS INTEGER ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT 78 AS col2 FROM tab2
----
78

query I rowsort
SELECT - 70 FROM tab1, tab2 cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7099
SELECT CAST( cor0.col1 AS SIGNED ) * col2 + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

skipif mysql # not compatible
query I rowsort label-7099
SELECT CAST ( cor0.col1 AS INTEGER ) * col2 + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-7100
SELECT + 62 DIV 60 + + col2 + 23 AS col0 FROM tab1 AS cor0
----
120
78
81

skipif mysql # not compatible
query I rowsort label-7100
SELECT + 62 / 60 + + col2 + 23 AS col0 FROM tab1 AS cor0
----
120
78
81

query I rowsort
SELECT 22 * 82 AS col0 FROM tab0 AS cor0
----
1804
1804
1804

query I rowsort
SELECT - 82 + ( col1 ) * ( cor0.col1 ) * col0 + 1 AS col0 FROM tab1 AS cor0
----
13439
1947
6319

query I rowsort
SELECT ALL 4 * + 7 - col1 FROM tab2
----
-3
-31
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-7104
SELECT + col0 DIV col2 + col0 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
165
3713
7760

skipif mysql # not compatible
query I rowsort label-7104
SELECT + col0 / col2 + col0 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
165
3713
7760

query I rowsort
SELECT ALL + col1 + col0 * 53 AS col2 FROM tab0 AS cor0
----
1358
1952
4808

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 10 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # use DIV operator for integer division
query I rowsort label-7107
SELECT - 81 DIV cor0.col1 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7107
SELECT - 81 / cor0.col1 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT col2 * col0 * + col2 + col2 AS col0 FROM tab0
----
26169
36
598518

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + - col0 col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL + col1 + - col1 + - col2 AS col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT - 64 * col1 FROM tab0
----
-5504
-5824
-6208

query I rowsort
SELECT - col1 - - ( + col1 ) AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( 31 * + col2 AS REAL ) + + tab0.col0 FROM tab0
----
-2453
-999
4

query I rowsort
SELECT ALL + 62 + - col0 - col1 * + col0 * 39 FROM tab0
----
-132378
-315888
-80458

query I rowsort
SELECT ( tab0.col0 ) - - col0 FROM tab0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 0 col0 FROM tab2, tab2 AS cor0
----
0

query I rowsort
SELECT ALL ( col2 ) - - col1 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL - cor0.col2 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7119
SELECT ALL + - cor0.col1 + col1 DIV ( + col0 ) FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-7119
SELECT ALL + - cor0.col1 + col1 / ( + col0 ) FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT col2 * - col1 + 29 FROM tab0 AS cor0
----
-2809
-68
-7433

query I rowsort
SELECT - - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL + 59 AS col1 FROM tab2 AS cor0
----
59
59
59

query I rowsort
SELECT ALL - - 24 FROM tab1 AS cor0
----
24
24
24

query I rowsort
SELECT + - cor0.col2 * col2 + - 25 + - col1 FROM tab1 AS cor0
----
-2967
-3284
-9254

query I rowsort
SELECT DISTINCT - col1 + + cor0.col1 + - 58 FROM tab2 AS cor0
----
-58

query I rowsort
SELECT + col2 + col0 + - col2 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + col0 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + - col0 + cor0.col2 * 95 FROM tab0 cor0
----
3111
60
7701

onlyif mysql # use DIV operator for integer division
query I rowsort label-7129
SELECT DISTINCT + col1 + - cor0.col2 DIV 98 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-7129
SELECT DISTINCT + col1 + - cor0.col2 / 98 AS col0 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7130
SELECT DISTINCT - col2 DIV - 10 AS col0 FROM tab2
----
2
3

skipif mysql # not compatible
query I rowsort label-7130
SELECT DISTINCT - col2 / - 10 AS col0 FROM tab2
----
2
3

query I rowsort
SELECT DISTINCT cor0.col2 + ( col0 ) FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - col2 + + col0 * col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL - cor0.col2 - col2 * col1 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - ( - 60 ) AS col0 FROM tab1 AS cor0
----
60
60
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-7135
SELECT ALL col0 * + 66 + cor0.col1 DIV col1 FROM tab0 AS cor0
----
1585
2311
5875

skipif mysql # not compatible
query I rowsort label-7135
SELECT ALL col0 * + 66 + cor0.col1 / col1 FROM tab0 AS cor0
----
1585
2311
5875

query I rowsort
SELECT DISTINCT col0 * col1 + - col2 * + col1 FROM tab0 cor0
----
-774
3298
637

query I rowsort
SELECT + + col0 * + col2 * col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - - ( col2 ) * col1 + col1 * 32 FROM tab2 AS cor0
----
1190
1829
3422

query I rowsort
SELECT DISTINCT - 17 * + col2 AS col0 FROM tab0 AS cor0
----
-1394
-17
-561

query I rowsort
SELECT + 33 * cor0.col2 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 4fcc035ca0f30ddb72bcd54efe2440af

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0, tab2 cor1, tab2, tab2 AS cor2
----
3645 values hashing to c04c36412775e8805d6b3befa2f52917

query I rowsort
SELECT ALL + 7 FROM tab1, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7143
SELECT + CAST( + 21 AS SIGNED ) * + col2 FROM tab0 AS cor0
----
1722
21
693

skipif mysql # not compatible
query I rowsort label-7143
SELECT + CAST ( + 21 AS INTEGER ) * + col2 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT DISTINCT - ( col1 ) * + col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + ( + cor0.col2 ) + - col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL 94 AS col2 FROM tab0
----
94
94
94

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT cor0.col0 * 53 FROM tab1, tab1 AS cor0
----
159
3392
4240

query I rowsort
SELECT ALL col2 * col1 + + 76 FROM tab0 AS cor0
----
173
2914
7538

query I rowsort
SELECT col2 * - cor0.col2 + + col2 AS col1 FROM tab0 cor0
----
-1056
-6642
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7151
SELECT DISTINCT col1 * col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7151
SELECT DISTINCT col1 * col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT - + col1 + 10 AS col0 FROM tab0 AS cor0
----
-76
-81
-87

query I rowsort
SELECT + - col1 + - 30 * - col0 AS col0 FROM tab1 AS cor0
----
1910
2387
64

query I rowsort
SELECT col2 * - 10 AS col1 FROM tab2 AS cor0
----
-260
-270
-380

onlyif mysql # use DIV operator for integer division
query I rowsort label-7155
SELECT + col1 * 41 DIV col2 AS col1 FROM tab0 cor0
----
106
3977
45

skipif mysql # not compatible
query I rowsort label-7155
SELECT + col1 * 41 / col2 AS col1 FROM tab0 cor0
----
106
3977
45

query I rowsort
SELECT 32 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT DISTINCT - - col0 * 88 FROM tab1 AS cor0
----
264
5632
7040

skipif mysql # not compatible
query I rowsort
SELECT + col1 * - CAST ( - 19 AS REAL ) AS col2 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT + cor0.col0 + ( + col1 ) * - col2 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + 32 ) col1 FROM tab0
----
-32

query I rowsort
SELECT ALL + 87 + col1 AS col1 FROM tab0 AS cor0
----
173
178
184

query I rowsort
SELECT + col0 + + 23 * + col2 FROM tab2 AS cor0
----
628
676
953

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( + col0 AS REAL ) + + cor0.col1 / 24 AS col2 FROM tab0 AS cor0
----
27
39
92

query I rowsort
SELECT ALL + + 38 * 51 + + col0 FROM tab2 AS cor0
----
1945
2016
2017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 86 * - col2 + col1 col0 FROM tab2 cor0
----
-2177
-2291
-3251

query I rowsort
SELECT + ( cor0.col0 ) + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - 42 * - col0 + + col2 AS col1 FROM tab0 AS cor0
----
1041
1471
3820

onlyif mysql # use DIV operator for integer division
query I rowsort label-7168
SELECT ALL + + ( + 94 ) + - col0 DIV cor0.col2 AS col1 FROM tab0 AS cor0
----
59
93
94

skipif mysql # not compatible
query I rowsort label-7168
SELECT ALL + + ( + 94 ) + - col0 / cor0.col2 AS col1 FROM tab0 AS cor0
----
59
93
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-7169
SELECT + col1 DIV + cor0.col0 - - col1 * ( - col1 * col2 ) AS col1 FROM tab0 AS cor0
----
-244065
-679041
-9407

skipif mysql # not compatible
query I rowsort label-7169
SELECT + col1 / + cor0.col0 - - col1 * ( - col1 * col2 ) AS col1 FROM tab0 AS cor0
----
-244065
-679041
-9407

query I rowsort
SELECT - - 40 * col2 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT ALL - 67 * - col1 - + col2 FROM tab2 AS cor0
----
1101
2050
3927

query I rowsort
SELECT ALL + col0 * cor0.col0 + + col2 FROM tab2 cor0
----
6110
6279
76

query I rowsort
SELECT + ( - col1 ) * col0 * + col0 + - col1 AS col2 FROM tab0 AS cor0
----
-118922
-49622
-720902

onlyif mysql # use DIV operator for integer division
query I rowsort label-7174
SELECT DISTINCT 20 DIV col2 + + col0 FROM tab0 AS cor0
----
24
55
89

skipif mysql # not compatible
query I rowsort label-7174
SELECT DISTINCT 20 / col2 + + col0 FROM tab0 AS cor0
----
24
55
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7175
SELECT ALL CAST( col1 AS SIGNED ) * col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-7175
SELECT ALL CAST ( col1 AS INTEGER ) * col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col0 AS REAL ) * cor0.col1 + - col2 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL 55 * - col1 AS col0 FROM tab0 AS cor0
----
-4730
-5005
-5335

query I rowsort
SELECT DISTINCT ( col0 ) * 13 + - col0 AS col2 FROM tab0 AS cor0
----
1068
288
420

onlyif mysql # use DIV operator for integer division
query I rowsort label-7179
SELECT - - col1 + cor0.col1 DIV CAST( col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-7179
SELECT - - col1 + cor0.col1 / CAST ( col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ( - col1 ) + col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT - col2 + col1 * + col0 * - ( col1 ) AS col1 FROM tab1 AS cor0
----
-13616
-2082
-6457

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - cor0.col0 + 7 col0 FROM tab2 cor0
----
1350
224
4609

query I rowsort
SELECT - - cor0.col2 + + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT tab0.col0 + 23 AS col1 FROM tab0
----
112
47
58

query I rowsort
SELECT DISTINCT + 65 + - ( - col0 ) AS col1 FROM tab1
----
129
145
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7186
SELECT + CAST( NULL AS SIGNED ) + + ( + col1 ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7186
SELECT + CAST ( NULL AS INTEGER ) + + ( + col1 ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7187
SELECT + col0 DIV 50 FROM tab2
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7187
SELECT + col0 / 50 FROM tab2
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 92 col0 FROM tab1 AS cor0
----
92
92
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7189
SELECT col2 * - col0 + + col0 DIV + col0 AS col1 FROM tab2 AS cor0
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-7189
SELECT col2 * - col0 + + col0 / + col0 AS col1 FROM tab2 AS cor0
----
-188
-2027
-3001

query I rowsort
SELECT + + col0 + col0 * + col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT - cor0.col2 * col2 + col0 AS col1 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL ( + cor1.col0 ) AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 + cor0.col2 col2 FROM tab0, tab1 cor0
----
9 values hashing to 75f4e5519ac10737d00aae9a6c4534d1

query I rowsort
SELECT DISTINCT col1 + 44 FROM tab2 AS cor0
----
103
61
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7195
SELECT DISTINCT cor0.col1 - + CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-7195
SELECT DISTINCT cor0.col1 - + CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT cor0.col2 + - 17 FROM tab2, tab2 AS cor0
----
10
21
9

query I rowsort
SELECT - 30 FROM tab1, tab1 cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

query I rowsort
SELECT 54 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 95 col1 FROM tab1 AS cor0
----
-95
-95
-95

query I rowsort
SELECT ALL - 99 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 761f5f1a166a00db99360141565a85da

query I rowsort
SELECT col1 * - 99 + 15 FROM tab1
----
-1272
-2559
-975

query I rowsort
SELECT DISTINCT - 81 AS col1 FROM tab0, tab2 AS cor0
----
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7203
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * tab1.col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7203
SELECT DISTINCT - CAST ( NULL AS REAL ) * tab1.col1 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7204
SELECT 58 * col0 DIV tab2.col1 FROM tab2
----
13
269
76

skipif mysql # not compatible
query I rowsort label-7204
SELECT 58 * col0 / tab2.col1 FROM tab2
----
13
269
76

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + ( + cor0.col1 ) AS REAL ) * 68 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT ALL - cor0.col2 * - col2 - + col1 * + 46 AS col1 FROM tab2 cor0
----
-2038
-697
662

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 26 ) + - cor1.col2 col1 FROM tab0, tab1 AS cor0, tab1, tab0 AS cor1
----
-56
-7
25

query I rowsort
SELECT - col0 * 78 * - col0 + + cor0.col1 - - col2 * - col2 FROM tab1 AS cor0
----
-2188
316249
489997

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7209
SELECT col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7209
SELECT col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * - tab2.col0 + ( col2 ) FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col2 + cor0.col0 AS col1 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7212
SELECT CAST( col1 AS SIGNED ) * col2 * col1 + - col2 FROM tab1 cor0
----
16128
36450
5643

skipif mysql # not compatible
query I rowsort label-7212
SELECT CAST ( col1 AS INTEGER ) * col2 * col1 + - col2 FROM tab1 cor0
----
16128
36450
5643

query I rowsort
SELECT - 92 * - 93 FROM tab1 AS cor0
----
8556
8556
8556

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7214
SELECT + + CAST( col0 AS SIGNED ) + - col1 AS col0 FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-7214
SELECT + + CAST ( col0 AS INTEGER ) + - col1 AS col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT ( 70 ) AS col2 FROM tab1 AS cor0
----
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7216
SELECT col1 * - col0 + cor0.col2 - + CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-2117
-3491
-8108

skipif mysql # not compatible
query I rowsort label-7216
SELECT col1 * - col0 + cor0.col2 - + CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-2117
-3491
-8108

query I rowsort
SELECT - + 21 + - 59 FROM tab1 cor0
----
-80
-80
-80

query I rowsort
SELECT - ( cor0.col1 ) + 18 FROM tab0 AS cor0
----
-68
-73
-79

query I rowsort
SELECT DISTINCT + 44 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 92 + + col1 * + ( col0 ) col0 FROM tab1 AS cor0
----
1132
170
732

onlyif mysql # use DIV operator for integer division
query I rowsort label-7221
SELECT DISTINCT + col1 + - col1 DIV + 60 col2 FROM tab0 AS cor0
----
85
90
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7221
SELECT DISTINCT + col1 + - col1 / + 60 col2 FROM tab0 AS cor0
----
85
90
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + ( - cor0.col2 ) - + col2 col0 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7223
SELECT DISTINCT cor0.col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7223
SELECT DISTINCT cor0.col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7224
SELECT ALL - + col1 DIV + col0 + - col0 FROM tab2 AS cor0
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-7224
SELECT ALL - + col1 / + col0 + - col0 FROM tab2 AS cor0
----
-11
-78
-79

query I rowsort
SELECT col2 * ( - cor0.col0 * + col1 ) + col2 FROM tab1 AS cor0
----
-36423
-4158
-99744

onlyif mysql # use DIV operator for integer division
query I rowsort label-7226
SELECT DISTINCT - + col0 DIV col0 + + col2 * col1 FROM tab0 AS cor0
----
2837
7461
96

skipif mysql # not compatible
query I rowsort label-7226
SELECT DISTINCT - + col0 / col0 + + col2 * col1 FROM tab0 AS cor0
----
2837
7461
96

query I rowsort
SELECT DISTINCT + - col0 * 97 AS col2 FROM tab2 AS cor0
----
-679
-7566
-7663

query I rowsort
SELECT DISTINCT - col0 * 73 FROM tab0 AS cor0
----
-1752
-2555
-6497

query I rowsort
SELECT DISTINCT col1 + col0 * 31 + col2 FROM tab0 AS cor0
----
1183
2932
863

query I rowsort
SELECT + col1 * col1 + ( - col0 ) AS col0 FROM tab2 AS cor0
----
210
3403
954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - col2 col0 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL cor0.col0 + 87 * + col0 FROM tab0 cor0
----
2112
3080
7832

query I rowsort
SELECT DISTINCT + col0 - ( + col1 * + col2 ) FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - 14 FROM tab2, tab0 AS cor0
----
-14

query I rowsort
SELECT + col0 + + 93 FROM tab1 AS cor0
----
157
173
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 * + cor0.col0 - col2 col1 FROM tab0 AS cor0
----
231
384
897

onlyif mysql # use DIV operator for integer division
query I rowsort label-7237
SELECT ALL col0 DIV + col1 - tab2.col1 AS col1 FROM tab2
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-7237
SELECT ALL col0 / + col1 - tab2.col1 AS col1 FROM tab2
----
-13
-31
-58

query I rowsort
SELECT DISTINCT + - col1 + col0 - col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + col2 + col0 * col1 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT - 13 FROM tab0, tab0 AS cor0
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7241
SELECT tab1.col2 + ( col1 ) DIV - col2 AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7241
SELECT tab1.col2 + ( col1 ) / - col2 AS col1 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7242
SELECT - cor0.col1 DIV 21 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to a46f44f30b2183508f32c16a79479cd9

skipif mysql # not compatible
query I rowsort label-7242
SELECT - cor0.col1 / 21 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to a46f44f30b2183508f32c16a79479cd9

query I rowsort
SELECT DISTINCT 49 * col1 AS col1 FROM tab0
----
4214
4459
4753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col1 FROM tab2, tab1 cor0, tab2 AS cor1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7245
SELECT DISTINCT + ( ( - col2 ) ) DIV col0 AS col0 FROM tab0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7245
SELECT DISTINCT + ( ( - col2 ) ) / col0 AS col0 FROM tab0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7246
SELECT DISTINCT - + CAST( NULL AS SIGNED ) FROM tab2, tab0, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7246
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) FROM tab2, tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT - 93 + - col1 * + col0 AS col1 FROM tab1 AS cor0
----
-1133
-171
-733

query I rowsort
SELECT - ( 93 ) + - tab0.col0 FROM tab0
----
-117
-128
-182

query I rowsort
SELECT - 56 + - tab2.col2 FROM tab2
----
-82
-83
-94

query I rowsort
SELECT col2 - + tab1.col1 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT - 39 AS col2 FROM tab0, tab1, tab1 cor0
----
-39

query I rowsort
SELECT DISTINCT tab2.col2 + - 51 AS col1 FROM tab2
----
-13
-24
-25

query I rowsort
SELECT 87 * + col1 FROM tab2
----
1479
2697
5133

query I rowsort
SELECT - ( + ( tab1.col0 ) * + tab1.col0 ) - col2 FROM tab1
----
-4153
-63
-6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 39 * col1 + tab0.col0 col1 FROM tab0
----
3378
3638
3818

query I rowsort
SELECT DISTINCT + col2 + col1 * + col0 + - ( + col2 ) AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + col2 + - col1 * + col0 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT 21 * col0 AS col2 FROM tab2
----
147
1638
1659

query I rowsort
SELECT - - col0 * cor0.col2 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * cor0.col1 + 21 * col1 col0 FROM tab1 AS cor0
----
-130
104
110

query I rowsort
SELECT ALL - - col0 - + cor0.col2 AS col0 FROM tab2 AS cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * col1 col2 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - 22 * - col1 AS col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT ALL col0 * + col0 - cor0.col2 AS col2 FROM tab1 AS cor0
----
-45
4039
6304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col1 + - col2 * - col0 - col2 col0 FROM tab0 AS cor0
----
-2079
-246
-63

query I rowsort
SELECT + col1 + - col2 - + col1 AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - tab0.col1 * + col2 * - col1 AS col1 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7269
SELECT - col2 + col0 DIV + col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7269
SELECT - col2 + col0 / + col1 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7270
SELECT DISTINCT col2 * col2 DIV + col1 FROM tab2
----
11
23
84

skipif mysql # not compatible
query I rowsort label-7270
SELECT DISTINCT col2 * col2 / + col1 FROM tab2
----
11
23
84

query I rowsort
SELECT col1 * col0 * - col2 AS col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col1 * - tab2.col0 * col0 + col2 FROM tab2
----
-106059
-1492
-358930

query I rowsort
SELECT DISTINCT - tab0.col0 + - tab0.col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT ALL + col1 * - col0 + col2 * col0 FROM tab1
----
3008
6640
84

query I rowsort
SELECT col2 * - tab0.col0 + + col0 * - col2 AS col2 FROM tab0
----
-14596
-1584
-70

query I rowsort
SELECT ALL + col0 + - tab1.col1 AS col1 FROM tab1 WHERE NULL IN ( - col0 * - col0 )
----

query I rowsort
SELECT + cor0.col1 + - col0 AS col0 FROM tab1 cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 + col1 * cor0.col1 * + col1 col2 FROM tab0 cor0
----
636080
753660
912708

onlyif mysql # use DIV operator for integer division
query I rowsort label-7279
SELECT - + cor0.col2 * - col2 + cor0.col2 DIV cor0.col1 col0 FROM tab2 AS cor0
----
1446
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7279
SELECT - + cor0.col2 * - col2 + cor0.col2 / cor0.col1 col0 FROM tab2 AS cor0
----
1446
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-7280
SELECT ALL - col2 DIV + col0 + col2 * + col1 AS col1 FROM tab2 AS cor0
----
1534
646
834

skipif mysql # not compatible
query I rowsort label-7280
SELECT ALL - col2 / + col0 + col2 * + col1 AS col1 FROM tab2 AS cor0
----
1534
646
834

onlyif mysql # use DIV operator for integer division
query I rowsort label-7281
SELECT col1 + col1 + col0 DIV col1 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-7281
SELECT col1 + col1 + col0 / col1 FROM tab0
----
172
182
194

query I rowsort
SELECT - tab1.col0 + col0 + col0 AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + - 30 * + col1 AS col0 FROM tab0 AS cor0
----
-2580
-2730
-2910

query I rowsort
SELECT ALL 96 + col1 * + col0 FROM tab2 cor0
----
1439
313
4698

query I rowsort
SELECT DISTINCT col2 * - col2 + cor0.col0 * col2 FROM tab2 AS cor0
----
-540
1352
1558

query I rowsort
SELECT DISTINCT + + 40 + col0 FROM tab0 AS cor0
----
129
64
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7287
SELECT ALL - cor0.col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7287
SELECT ALL - cor0.col0 / - col2 AS col1 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - col1 + - col1 * - col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - - cor0.col0 + - col2 + cor0.col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT 51 + + col2 - tab2.col0 FROM tab2
----
-1
10
71

query I rowsort
SELECT DISTINCT + + col0 * - cor0.col2 + col2 * col1 AS col1 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + col2 - - col2 AS col0 FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT col1 * tab2.col0 * - col1 + col2 AS col0 FROM tab2
----
-22793
-271492
-6700

query I rowsort
SELECT ALL + col2 * col0 * col2 + col0 FROM tab2
----
114155
5110
52806

query I rowsort
SELECT DISTINCT col1 * col1 - + col1 AS col2 FROM tab0
----
7310
8190
9312

query I rowsort
SELECT ALL + col2 + col2 + col2 AS col1 FROM tab1 WHERE NOT + col0 BETWEEN ( NULL ) AND + col2
----
171

query I rowsort
SELECT col1 * col1 FROM tab2 WHERE NOT col2 BETWEEN + col1 + - col2 AND ( NULL )
----
3481

query I rowsort
SELECT - col0 * col0 * - col1 + + col2 + col1 FROM tab0
----
118923
49655
720984

query I rowsort
SELECT - col1 * col0 + col1 - - col1 AS col1 FROM tab0 AS cor0
----
-1892
-3201
-7917

query I rowsort
SELECT + col1 * - col1 + - col0 * + ( + col0 + - col0 ) * col1 AS col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - - 54 + + col1 * col2 * 60 FROM tab2 AS cor0
----
38814
50274
92094

query I rowsort
SELECT 5 + + col0 AS col1 FROM tab0 cor0
----
29
40
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 col2 FROM tab2 WHERE NOT col2 NOT BETWEEN ( - col1 ) AND NULL
----

query I rowsort
SELECT DISTINCT tab2.col0 * + col0 * col2 + col2 FROM tab2
----
1350
158210
237196

onlyif mysql # use DIV operator for integer division
query I rowsort label-7306
SELECT col2 * col2 + col1 DIV - col1 AS col2 FROM tab1
----
2915
3248
9215

skipif mysql # not compatible
query I rowsort label-7306
SELECT col2 * col2 + col1 / - col1 AS col2 FROM tab1
----
2915
3248
9215

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - tab1.col0 - + col0 col2 FROM tab1
----
576
75
960

query I rowsort
SELECT - 36 + + col2 FROM tab2 AS cor0
----
-10
-9
2

query I rowsort
SELECT - col2 * + col1 * tab0.col0 AS col2 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col0 * - col1 col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col2 FROM tab1 WHERE NOT NULL < ( NULL )
----

query III rowsort
SELECT * FROM tab2 WHERE NULL >= ( col0 + - col1 )
----

query I rowsort
SELECT col2 * col2 + col0 * - col1 FROM tab0
----
-1375
-3394
-975

query I rowsort
SELECT cor0.col2 + - cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 48730a4f3ae72ef34da4083404b84d99

query I rowsort
SELECT - cor0.col2 * col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT col2 + + col0 * - col0 * col2 FROM tab1
----
-233415
-432
-614304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 + col0 col0 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL + col1 * col2 * col2 - col0 FROM tab0
----
611795
62
93630

query I rowsort
SELECT DISTINCT + col0 FROM tab1 WHERE NOT col0 IN ( + col0 * + col2 )
----
3
64
80

query I rowsort
SELECT DISTINCT col0 FROM tab0 WHERE NULL < NULL
----

query III rowsort
SELECT * FROM tab1 WHERE + col0 < - col2
----

query I rowsort
SELECT - tab2.col0 + col0 * col0 FROM tab2
----
42
6006
6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-7323
SELECT col1 DIV + col2 + + tab0.col2 FROM tab0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-7323
SELECT col1 / + col2 + + tab0.col2 FROM tab0
----
35
83
98

query I rowsort
SELECT ALL - 35 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

onlyif mysql # use DIV operator for integer division
query I rowsort label-7325
SELECT + 60 DIV 66 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7325
SELECT + 60 / 66 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7326
SELECT 61 DIV col2 + col2 * + col1 * + col0 col1 FROM tab1
----
36481
4213
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7326
SELECT 61 / col2 + col2 * + col1 * + col0 col1 FROM tab1
----
36481
4213
99840

query I rowsort
SELECT ALL + 77 + + tab2.col2 * col2 - col1 AS col1 FROM tab2
----
1504
694
775

query I rowsort
SELECT ( - col0 ) + 97 AS col0 FROM tab1
----
17
33
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT - + cor0.col0 - col0 * + ( - col2 * col1 ) FROM tab2 AS cor0
----
119574
50955
5852

onlyif mysql # use DIV operator for integer division
query I rowsort label-7331
SELECT DISTINCT col0 DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7331
SELECT DISTINCT col0 / - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - 51 AS col0 FROM tab0 AS cor0
----
-51

query I rowsort
SELECT DISTINCT - col0 + - 8 AS col0 FROM tab2
----
-15
-86
-87

query I rowsort
SELECT + col2 - + col0 * + 53 AS col1 FROM tab2
----
-344
-4108
-4149

query I rowsort
SELECT + col2 * - col0 + + ( - col1 + col2 ) * col1 FROM tab0
----
-5350
-8117
-9347

query I rowsort
SELECT ALL - col1 + + ( + tab2.col1 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col0 * 93 * + col2 FROM tab2
----
17577
188604
279186

query I rowsort
SELECT - + col0 + col2 + + col1 AS col0 FROM tab0 cor0
----
63
84
95

query I rowsort
SELECT + - col1 + - col0 * + cor0.col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT - - cor0.col0 + col0 + col1 AS col0 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT + 77 AS col1 FROM tab0 AS cor0
----
77
77
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7342
SELECT ALL - - col1 DIV 7 FROM tab1 cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-7342
SELECT ALL - - col1 / 7 FROM tab1 cor0
----
1
1
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7343
SELECT CAST( 89 AS SIGNED ) FROM tab0 AS cor0
----
89
89
89

skipif mysql # not compatible
query I rowsort label-7343
SELECT CAST ( 89 AS INTEGER ) FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT DISTINCT - + col2 + + ( - col2 ) FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT + - 66 + - col2 FROM tab1 AS cor0
----
-120
-123
-162

onlyif mysql # use DIV operator for integer division
query I rowsort label-7346
SELECT + 10 DIV + 56 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7346
SELECT + 10 / + 56 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + 18 col2 FROM tab0 AS cor0
----
-68
-73
-79

query I rowsort
SELECT ALL + - 62 AS col2 FROM tab0 AS cor0
----
-62
-62
-62

query I rowsort
SELECT col0 * + 63 * - col2 FROM tab0 cor0
----
-2205
-459774
-49896

query I rowsort
SELECT DISTINCT + tab0.col2 * - 25 + cor0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 71fe470d2fd997f5778663c6afb6ebc9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7351
SELECT ALL cor0.col2 * + 33 + col1 * - col0 DIV - cor0.col0 AS col2 FROM tab2 AS cor0
----
1271
917
922

skipif mysql # not compatible
query I rowsort label-7351
SELECT ALL cor0.col2 * + 33 + col1 * - col0 / - cor0.col0 AS col2 FROM tab2 AS cor0
----
1271
917
922

query I rowsort
SELECT DISTINCT + 82 - col1 * col0 AS col0 FROM tab2 AS cor0
----
-1261
-135
-4520

onlyif mysql # use DIV operator for integer division
query I rowsort label-7353
SELECT DISTINCT - 39 * 58 DIV cor0.col1 FROM tab1 AS cor0
----
-174
-226
-87

skipif mysql # not compatible
query I rowsort label-7353
SELECT DISTINCT - 39 * 58 / cor0.col1 FROM tab1 AS cor0
----
-174
-226
-87

query I rowsort
SELECT + 18 * col0 FROM tab2 AS cor0
----
126
1404
1422

query I rowsort
SELECT DISTINCT cor0.col0 - - col2 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col1 ) col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - col1 + - 95 * - col1 AS col2 FROM tab2 cor0
----
1598
2914
5546

query I rowsort
SELECT cor0.col2 + col2 AS col1 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT + col1 * - 73 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-1320
-2270
-4385

query I rowsort
SELECT DISTINCT + 36 + col2 + col1 AS col2 FROM tab0 AS cor0
----
134
155
209

query I rowsort
SELECT ALL + 54 - col1 FROM tab2 AS cor0
----
-5
23
37

query I rowsort
SELECT DISTINCT - + 70 AS col1 FROM tab2 AS cor0
----
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col2 + - col1 + - col2 col0 FROM tab2 AS cor0
----
1389
591
671

query I rowsort
SELECT + ( - col2 ) * - col2 + cor0.col1 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + - 99 AS col0 FROM tab1 AS cor0
----
-99
-99
-99

query I rowsort
SELECT ALL 43 * + col2 + col2 FROM tab0 AS cor0
----
1452
3608
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7368
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 75 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7368
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 75 FROM tab1
----
NULL

query I rowsort
SELECT ALL - 26 * + col1 + col1 FROM tab0 AS cor0
----
-2150
-2275
-2425

query I rowsort
SELECT ALL - - ( - col2 ) + col2 * col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT col0 * + col0 + col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1226
14645
1665

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 + 91 col2 FROM tab0
----
115
126
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7373
SELECT - CAST( - col2 AS SIGNED ) * col0 + col0 AS col2 FROM tab0
----
70
7387
816

skipif mysql # not compatible
query I rowsort label-7373
SELECT - CAST ( - col2 AS INTEGER ) * col0 + col0 AS col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT ( + col0 ) - + col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT - + col1 * + 52 * 85 + - col2 + col1 AS col1 FROM tab1 AS cor0
----
-114948
-44247
-57543

query I rowsort
SELECT - col1 + - ( 65 ) FROM tab1 AS cor0
----
-75
-78
-91

query I rowsort
SELECT - col1 + 13 FROM tab0 cor0
----
-73
-78
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col0 * - 93 col2 FROM tab2 AS cor0
----
658
7332
7426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + + 86 + col1 * - col1 * col1 col1 FROM tab1 AS cor0
----
-17464
-2098
-904

query I rowsort
SELECT ALL + cor0.col2 + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7381
SELECT col2 * CAST( col1 AS SIGNED ) col0 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7381
SELECT col2 * CAST ( col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7382
SELECT DISTINCT - col2 + - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7382
SELECT DISTINCT - col2 + - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT + - cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL col1 + - ( col2 ) * - col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL + - cor0.col0 * - col2 + cor0.col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7386
SELECT + + col0 * + CAST( - col1 AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

skipif mysql # not compatible
query I rowsort label-7386
SELECT + + col0 * + CAST ( - col1 AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 cor1
----
-26
-27
-38

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab2 cor2
----
3645 values hashing to d6394df0309139ffe20e7d96c77e26ee

query I rowsort
SELECT ALL + ( cor0.col1 ) * + cor0.col2 * col2 AS col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL + 65 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT - col2 - cor0.col1 * col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + col1 * col2 + 10 AS col1 FROM tab0 cor0
----
107
2848
7472

query I rowsort
SELECT + - cor0.col2 * + col2 + col1 * cor0.col0 FROM tab1 AS cor0
----
-2609
-2838
-8176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7394
SELECT ALL - - col2 + + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7394
SELECT ALL - - col2 + + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + col2 FROM tab1 cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL + + cor0.col2 * - col0 + col0 * col2 - + col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - 95 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7398
SELECT - cor0.col0 * CAST( + col2 AS SIGNED ) + - col0 * col2 FROM tab1 cor0
----
-15360
-324
-7296

skipif mysql # not compatible
query I rowsort label-7398
SELECT - cor0.col0 * CAST ( + col2 AS INTEGER ) + - col0 * col2 FROM tab1 cor0
----
-15360
-324
-7296

query I rowsort
SELECT col0 * + ( cor0.col1 ) + - cor0.col1 AS col2 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7400
SELECT + CAST( cor0.col0 AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif mysql # not compatible
query I rowsort label-7400
SELECT + CAST ( cor0.col0 AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT - col2 * 84 + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2686
-6797
13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7402
SELECT + CAST( NULL AS SIGNED ) * 7 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7402
SELECT + CAST ( NULL AS INTEGER ) * 7 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 17 * + 72 + + cor0.col0 col0 FROM tab1 AS cor0
----
1227
1288
1304

query I rowsort
SELECT - tab1.col2 * - 41 AS col0 FROM tab1
----
2214
2337
3936

onlyif mysql # use DIV operator for integer division
query I rowsort label-7405
SELECT + col0 DIV - col1 AS col0 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-7405
SELECT + col0 / - col1 AS col0 FROM tab1
----
-6
-6
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7406
SELECT - col1 DIV - tab1.col0 AS col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-7406
SELECT - col1 / - tab1.col0 AS col0 FROM tab1
----
0
0
8

query I rowsort
SELECT col0 * - 42 AS col2 FROM tab0
----
-1008
-1470
-3738

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col1 + 15 col1 FROM tab2
----
-274
-3466
-946

query I rowsort
SELECT + 99 AS col1 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT + 90 + col2 * + col0 FROM tab0 AS cor0
----
125
7388
882

query I rowsort
SELECT + + 6 + - col1 * 23 * col0 FROM tab2 AS cor0
----
-105840
-30883
-4985

query I rowsort
SELECT + + cor0.col1 * + col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7413
SELECT DISTINCT col0 * cor0.col1 + - CAST( col1 AS SIGNED ) * col1 * col2 + col2 AS col2 FROM tab0 AS cor0
----
-241971
-6013
-670861

skipif mysql # not compatible
query I rowsort label-7413
SELECT DISTINCT col0 * cor0.col1 + - CAST ( col1 AS INTEGER ) * col1 * col2 + col2 AS col2 FROM tab0 AS cor0
----
-241971
-6013
-670861

query I rowsort
SELECT ( + col1 ) + col0 * + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + + 74 + - col0 * - cor0.col0 FROM tab0 AS cor0
----
1299
650
7995

query I rowsort
SELECT ALL + 66 * + col1 AS col2 FROM tab2
----
1122
2046
3894

query I rowsort
SELECT 89 AS col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT ALL - + 64 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT ALL + col0 * - col1 + - col2 AS col1 FROM tab0 cor0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 46 * + col1 * - ( col0 * col1 + cor0.col2 ) col2 FROM tab2 AS cor0
----
1079942
12560392
347944

query I rowsort
SELECT DISTINCT + col2 + cor0.col0 * + 41 + col0 FROM tab2 AS cor0
----
321
3302
3356

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - col2 col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL col1 + + col1 + col2 AS col2 FROM tab1 cor0
----
106
122
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7424
SELECT DISTINCT tab0.col2 DIV + tab0.col1 col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7424
SELECT DISTINCT tab0.col2 / + tab0.col1 col1 FROM tab0
----
0

query I rowsort
SELECT - 56 AS col1 FROM tab1
----
-56
-56
-56

query I rowsort
SELECT DISTINCT + cor0.col2 * + col2 * col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT - tab1.col1 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT + 87 * col1 + - 15 * col1 * + col0 AS col0 FROM tab0
----
-113568
-23478
-42486

query I rowsort
SELECT ALL + 21 * col1 * + tab2.col0 FROM tab2
----
28203
4557
96642

query I rowsort
SELECT col2 + ( col2 ) * col2 AS col0 FROM tab2
----
1482
702
756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7431
SELECT CAST( NULL AS SIGNED ) * - col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7431
SELECT CAST ( NULL AS INTEGER ) * - col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 89 + - 63 FROM tab1 AS cor0
----
26
26
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - cor0.col2 col1 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - col1 + col0 * cor0.col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT - col2 * + col1 + - 45 AS col1 FROM tab1 AS cor0
----
-1293
-1449
-615

query I rowsort
SELECT - 53 + - col1 * col2 FROM tab1 AS cor0
----
-1301
-1457
-623

query I rowsort
SELECT ALL - ( 27 ) * col0 + col2 FROM tab0 cor0
----
-2321
-615
-944

query I rowsort
SELECT ALL col2 * + col0 * cor0.col0 + col0 FROM tab1 AS cor0
----
233536
489
614480

query I rowsort
SELECT - + 58 + col1 * col2 * cor0.col0 FROM tab0 AS cor0
----
3337
664060
68054

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * col0 - col1 col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT 93 + - 93 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7442
SELECT ALL + CAST( NULL AS SIGNED ) / col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7442
SELECT ALL + CAST ( NULL AS INTEGER ) / col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( col2 ) + - col1 * - col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 42 col1 FROM tab1 AS cor0
----
-42
-42
-42

query I rowsort
SELECT DISTINCT + - 32 * 63 AS col2 FROM tab1 AS cor0
----
-2016

query I rowsort
SELECT ALL 93 * col2 + cor0.col1 FROM tab1 AS cor0
----
5048
5311
8941

query I rowsort
SELECT - ( col2 ) * - col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + 69 + 11 * col0 FROM tab2 AS cor0
----
146
927
938

query I rowsort
SELECT ALL + col0 + 1 FROM tab0 cor0
----
25
36
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7450
SELECT + + CAST( 43 AS SIGNED ) FROM tab1 AS cor0
----
43
43
43

skipif mysql # not compatible
query I rowsort label-7450
SELECT + + CAST ( 43 AS INTEGER ) FROM tab1 AS cor0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-7451
SELECT ALL + col2 DIV cor0.col2 + - col1 col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7451
SELECT ALL + col2 / cor0.col2 + - col1 col2 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT ( + 27 ) FROM tab0
----
27
27
27

query I rowsort
SELECT DISTINCT - - col2 + 83 AS col2 FROM tab2 AS cor0
----
109
110
121

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7455
SELECT ALL col2 + col0 DIV + cor0.col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-7455
SELECT ALL col2 + col0 / + cor0.col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT - 68 AS col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT DISTINCT ( + col0 ) - - ( col1 ) AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT - col2 + col0 * + col2 * col0 AS col2 FROM tab1
----
233415
432
614304

query I rowsort
SELECT DISTINCT + col1 + col1 * col2 * + tab0.col1 AS col1 FROM tab0
----
244154
679133
9506

query I rowsort
SELECT col2 - - ( tab2.col2 ) * - col1 AS col1 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT col0 * 26 + col2 FROM tab0
----
2396
657
911

query I rowsort
SELECT - col2 + + 97 * + col1 * + col2 FROM tab0 AS cor0
----
275253
723732
9408

query I rowsort
SELECT + col2 + ( col0 ) * - col2 AS col2 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT + cor0.col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT + col1 + 45 * col0 - - col2 FROM tab0 AS cor0
----
1199
1673
4178

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 + - CAST ( - col2 AS REAL ) * + col0 AS col0 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-7467
SELECT - col1 DIV - col2 + col1 * - cor0.col2 * + col1 + ( col1 ) AS col1 FROM tab1 AS cor0
----
-16211
-36478
-5690

skipif mysql # not compatible
query I rowsort label-7467
SELECT - col1 / - col2 + col1 * - cor0.col2 * + col1 + ( col1 ) AS col1 FROM tab1 AS cor0
----
-16211
-36478
-5690

query I rowsort
SELECT ALL + col0 * ( 36 ) FROM tab2 AS cor0
----
252
2808
2844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7469
SELECT DISTINCT cor0.col0 DIV ( + col2 ) AS col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7469
SELECT DISTINCT cor0.col0 / ( + col2 ) AS col2 FROM tab0 AS cor0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7470
SELECT - cor0.col2 * cor0.col0 DIV col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-7470
SELECT - cor0.col2 * cor0.col0 / col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - col1 + 95 AS col2 FROM tab1 AS cor0
----
69
82
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7472
SELECT + + CAST( NULL AS SIGNED ) + - 15 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7472
SELECT + + CAST ( NULL AS INTEGER ) + - 15 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 + - cor0.col1 * col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT + 96 + ( - col1 ) AS col1 FROM tab2 AS cor0
----
37
65
79

query I rowsort
SELECT ALL + 77 - 0 AS col2 FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT + ( col0 ) + - cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + 96 AS col1 FROM tab1 AS cor0
----
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7478
SELECT DISTINCT - 52 * - col2 + CAST( - col2 AS SIGNED ) FROM tab2
----
1326
1377
1938

skipif mysql # not compatible
query I rowsort label-7478
SELECT DISTINCT - 52 * - col2 + CAST ( - col2 AS INTEGER ) FROM tab2
----
1326
1377
1938

query I rowsort
SELECT DISTINCT 69 + col0 FROM tab2
----
147
148
76

query I rowsort
SELECT 89 + + col1 * + col0 AS col1 FROM tab1 AS cor0
----
1129
167
729

query I rowsort
SELECT ALL + - col2 + + col2 * col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT 5 * + 85 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4f3e6ce1283e4cbf694274473e222f7c

query I rowsort
SELECT ALL - 83 * col2 FROM tab1 AS cor0
----
-4482
-4731
-7968

query I rowsort
SELECT DISTINCT col1 + + cor0.col2 * cor0.col0 * + col0 FROM tab1 AS cor0
----
233482
512
614413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col1 * - 17 - + col0 FROM tab0 AS cor0
----
-1486
-1636
-1684

query I rowsort
SELECT DISTINCT cor0.col1 + 29 FROM tab1 cor0
----
39
42
55

query I rowsort
SELECT DISTINCT - col0 * 40 * + 91 AS col1 FROM tab0 AS cor0
----
-127400
-323960
-87360

onlyif mysql # use DIV operator for integer division
query I rowsort label-7489
SELECT col0 + - col1 + col2 DIV - col1 FROM tab1 AS cor0
----
-25
49
60

skipif mysql # not compatible
query I rowsort label-7489
SELECT col0 + - col1 + col2 / - col1 FROM tab1 AS cor0
----
-25
49
60

skipif mysql # not compatible
query I rowsort
SELECT + col0 * + ( - ( + col2 ) ) + + CAST ( + col0 AS REAL ) FROM tab2 cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-7491
SELECT ALL - col2 DIV ( - col1 * col2 ) + 18 * cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
1026
1083
1824

skipif mysql # not compatible
query I rowsort label-7491
SELECT ALL - col2 / ( - col1 * col2 ) + 18 * cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
1026
1083
1824

query I rowsort
SELECT ALL + col2 * + 87 + - col0 AS col1 FROM tab2 AS cor0
----
2184
2342
3227

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7493
SELECT - col0 + CAST( col1 AS SIGNED ) + - cor0.col1 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1107
-55
-694

skipif mysql # not compatible
query I rowsort label-7493
SELECT - col0 + CAST ( col1 AS INTEGER ) + - cor0.col1 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1107
-55
-694

query I rowsort
SELECT ALL tab0.col2 - col0 * 38 FROM tab0
----
-1329
-3300
-879

query I rowsort
SELECT ALL - 69 - + col0 * - 89 AS col1 FROM tab1
----
198
5627
7051

query I rowsort
SELECT + 29 * - col2 + 77 * col2 AS col1 FROM tab0
----
1584
3936
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-7497
SELECT - - col0 DIV + CAST( ( + col2 ) AS SIGNED ) + + 15 * - 33 FROM tab1 AS cor0
----
-494
-495
-495

skipif mysql # not compatible
query I rowsort label-7497
SELECT - - col0 / + CAST ( ( + col2 ) AS INTEGER ) + + 15 * - 33 FROM tab1 AS cor0
----
-494
-495
-495

query I rowsort
SELECT ALL - col1 * col1 - + col0 AS col2 FROM tab1
----
-164
-249
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + tab1.col0 - - col2 col1 FROM tab1
----
131
189
83

query I rowsort
SELECT ALL 1 + col1 - + 13 AS col2 FROM tab2
----
19
47
5

query I rowsort
SELECT DISTINCT - cor0.col0 - + col0 * col1 AS col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ( + tab2.col2 ) FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - cor0.col2 * cor0.col0 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to f7e57a354e4e5925116b9650d1011609

query I rowsort
SELECT ( + 88 ) FROM tab0 AS cor0
----
88
88
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-7505
SELECT + - col2 DIV - 3 AS col0 FROM tab2 AS cor0
----
12
8
9

skipif mysql # not compatible
query I rowsort label-7505
SELECT + - col2 / - 3 AS col0 FROM tab2 AS cor0
----
12
8
9

query I rowsort
SELECT - - 67 + - ( - col2 ) * col2 FROM tab1 AS cor0
----
2983
3316
9283

onlyif mysql # use DIV operator for integer division
query I rowsort label-7507
SELECT ALL - col1 DIV 79 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7507
SELECT ALL - col1 / 79 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + 22 AS col0 FROM tab1 AS cor0
----
22
22
22

query I rowsort
SELECT col0 + - col0 + col0 AS col2 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7510
SELECT - col0 DIV col1 + ( col0 ) DIV - col2 + 1 FROM tab0 cor0
----
-34
0
1

skipif mysql # not compatible
query I rowsort label-7510
SELECT - col0 / col1 + ( col0 ) / - col2 + 1 FROM tab0 cor0
----
-34
0
1

query I rowsort
SELECT + col1 * col1 + + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT 29 * 91 + + col0 FROM tab1
----
2642
2703
2719

query I rowsort
SELECT DISTINCT + col1 - - col1 * col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - col0 * - 24 + col0 AS col0 FROM tab2 AS cor0
----
175
1950
1975

query I rowsort
SELECT DISTINCT - + col1 * col2 - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 + col2 col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL col2 * ( + col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col1 * + 34 AS col0 FROM tab2 AS cor0
----
-1054
-2006
-578

query I rowsort
SELECT - cor0.col1 * + col2 * cor0.col2 + col2 FROM tab0 AS cor0
----
-611802
-93621
-96

query I rowsort
SELECT ALL col0 * col2 + + 28 * col0 FROM tab2 AS cor0
----
385
4212
5214

query I rowsort
SELECT DISTINCT - col2 + ( cor0.col2 * col0 ) - - cor0.col1 FROM tab1 AS cor0
----
134
3601
7597

query I rowsort
SELECT + col2 * col0 + col0 + col2 * + 55 * - col2 AS col0 FROM tab2 AS cor0
----
-35074
-39899
-76339

query I rowsort
SELECT + col1 + col1 * 56 AS col2 FROM tab2 AS cor0
----
1767
3363
969

query I rowsort
SELECT + cor0.col2 + - 99 FROM tab0 AS cor0
----
-17
-66
-98

query I rowsort
SELECT 89 + + col1 FROM tab1 AS cor0
----
102
115
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7526
SELECT CAST( - col0 AS SIGNED ) * col1 + col1 + - col2 * + col2 FROM tab2 AS cor0
----
-2770
-5219
-915

skipif mysql # not compatible
query I rowsort label-7526
SELECT CAST ( - col0 AS INTEGER ) * col1 + col1 + - col2 * + col2 FROM tab2 AS cor0
----
-2770
-5219
-915

query I rowsort
SELECT ( 29 ) + + col1 AS col0 FROM tab1 AS cor0
----
39
42
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7528
SELECT + CAST( NULL AS DECIMAL ) + col2 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7528
SELECT + CAST ( NULL AS REAL ) + col2 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 84 + col1 * col0 FROM tab2 cor0
----
1427
301
4686

query I rowsort
SELECT ALL col2 * - 33 AS col0 FROM tab0
----
-1089
-2706
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-7531
SELECT - 57 + + 23 DIV + col1 FROM tab0 AS cor0
----
-57
-57
-57

skipif mysql # not compatible
query I rowsort label-7531
SELECT - 57 + + 23 / + col1 FROM tab0 AS cor0
----
-57
-57
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col2 ) * col2 * + 62 col0 FROM tab2 AS cor0
----
-41912
-45198
-89528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( - col1 ) * col2 col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - - 54 AS col1 FROM tab2, tab2 AS cor0, tab1, tab1 cor1
----
54

query I rowsort
SELECT 79 * col1 + col2 FROM tab2 AS cor0
----
1381
2476
4687

query I rowsort
SELECT ALL col0 + + col2 * col1 FROM tab2
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7537
SELECT 79 DIV - tab2.col1 AS col1 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-7537
SELECT 79 / - tab2.col1 AS col1 FROM tab2
----
-1
-2
-4

query I rowsort
SELECT DISTINCT + tab0.col2 * 59 AS col1 FROM tab0, tab2 AS cor0
----
1947
4838
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7539
SELECT DISTINCT - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-7539
SELECT DISTINCT - CAST ( NULL AS REAL ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

query I rowsort
SELECT + 0 * + col2 * - ( col0 ) - + col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 87 * col2 AS col1 FROM tab1 cor0
----
-4698
-4959
-8352

query I rowsort
SELECT - 92 * col1 + - 87 + - 41 AS col0 FROM tab0 cor0
----
-8040
-8500
-9052

query I rowsort
SELECT + tab0.col2 * + 83 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 0580ac8d81088f9de59e529ff1505780

query I rowsort
SELECT + + 25 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT - col1 * ( col0 + + tab2.col1 ) AS col2 FROM tab2
----
-1178
-1632
-8083

query I rowsort
SELECT + col1 + + col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + col2 * + col0 - col2 col2 FROM tab0 cor0
----
69
7305
783

query I rowsort
SELECT col0 + col1 + - col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + + col2 + - col0 * + 86 FROM tab2 AS cor0
----
-575
-6682
-6756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * - col1 + col1 * + 8 * col0 col2 FROM tab0 AS cor0
----
18576
30555
72891

onlyif mysql # use DIV operator for integer division
query I rowsort label-7552
SELECT DISTINCT + + col2 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7552
SELECT DISTINCT + + col2 / - col0 AS col1 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT + 56 + + col2 FROM tab1 AS cor0
----
110
113
152

onlyif mysql # use DIV operator for integer division
query I rowsort label-7554
SELECT ALL col1 * + col1 + + 90 DIV col2 FROM tab1 AS cor0
----
101
169
677

skipif mysql # not compatible
query I rowsort label-7554
SELECT ALL col1 * + col1 + + 90 / col2 FROM tab1 AS cor0
----
101
169
677

query I rowsort
SELECT DISTINCT - - cor0.col0 + - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-7556
SELECT - col1 + + cor0.col0 DIV col0 col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7556
SELECT - col1 + + cor0.col0 / col0 col0 FROM tab2 AS cor0
----
-16
-30
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7557
SELECT ALL + 46 DIV col2 + 91 FROM tab0 cor0
----
137
91
92

skipif mysql # not compatible
query I rowsort label-7557
SELECT ALL + 46 / col2 + 91 FROM tab0 cor0
----
137
91
92

query I rowsort
SELECT col1 * + col1 + - 80 AS col1 FROM tab1 AS cor0
----
20
596
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7559
SELECT ALL 68 * + cor0.col1 * col1 + + col1 DIV cor0.col1 FROM tab0 AS cor0
----
502929
563109
639813

skipif mysql # not compatible
query I rowsort label-7559
SELECT ALL 68 * + cor0.col1 * col1 + + col1 / cor0.col1 FROM tab0 AS cor0
----
502929
563109
639813

onlyif mysql # use DIV operator for integer division
query I rowsort label-7560
SELECT + + 53 + + col0 * + cor0.col2 DIV - col2 FROM tab1 AS cor0
----
-11
-27
50

skipif mysql # not compatible
query I rowsort label-7560
SELECT + + 53 + + col0 * + cor0.col2 / - col2 FROM tab1 AS cor0
----
-11
-27
50

query I rowsort
SELECT + 45 * col2 + cor0.col2 * 9 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT DISTINCT + col0 + - col2 + - col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - col1 * col0 + - 93 * + col1 FROM tab1 AS cor0
----
-1570
-2249
-2496

onlyif mysql # use DIV operator for integer division
query I rowsort label-7564
SELECT 44 DIV - col1 + + 97 * cor0.col2 + col2 AS col2 FROM tab0 cor0
----
3234
8036
98

skipif mysql # not compatible
query I rowsort label-7564
SELECT 44 / - col1 + + 97 * cor0.col2 + col2 AS col2 FROM tab0 cor0
----
3234
8036
98

query I rowsort
SELECT ALL - + col1 + - ( - col1 ) * - col0 AS col1 FROM tab0 cor0
----
-2150
-3492
-8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7566
SELECT DISTINCT - col2 * - CAST( + col1 AS DECIMAL ) + - cor0.col0 + CAST( NULL AS DECIMAL ) / col1 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7566
SELECT DISTINCT - col2 * - CAST ( + col1 AS REAL ) + - cor0.col0 + CAST ( NULL AS REAL ) / col1 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 * 37 + col1 AS col2 FROM tab1 AS cor0
----
-2358
-2947
-85

query I rowsort
SELECT ALL 74 * - col2 + 61 FROM tab0
----
-13
-2381
-6007

query I rowsort
SELECT DISTINCT + col1 * 70 AS col2 FROM tab1 AS cor0
----
1820
700
910

query I rowsort
SELECT DISTINCT 8 FROM tab0 cor0
----
8

query I rowsort
SELECT 49 * 17 FROM tab2 AS cor0
----
833
833
833

query I rowsort
SELECT 16 + col0 * + col0 FROM tab2 cor0
----
6100
6257
65

query I rowsort
SELECT DISTINCT - - ( ( col1 ) ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + + col2 * - 30 + + col2 * col2 * col0 FROM tab0 AS cor0
----
25146
5
595976

query I rowsort
SELECT DISTINCT col2 * col2 * + col0 + 54 AS col1 FROM tab2 AS cor0
----
114130
5157
52782

query I rowsort
SELECT DISTINCT + 68 FROM tab2, tab0 AS cor0
----
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-7577
SELECT col2 DIV + 61 - col1 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-7577
SELECT col2 / + 61 - col1 FROM tab2
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7578
SELECT ALL + ( 82 ) DIV - col0 - ( ( + col0 ) + col1 ) * - col0 FROM tab1
----
4735
60
7439

skipif mysql # not compatible
query I rowsort label-7578
SELECT ALL + ( 82 ) / - col0 - ( ( + col0 ) + col1 ) * - col0 FROM tab1
----
4735
60
7439

query I rowsort
SELECT ALL 41 - + 39 FROM tab2
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7580
SELECT ALL - col0 * col1 + + col1 DIV - 37 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-7580
SELECT ALL - col0 * col1 + + col1 / - 37 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 29 * col2 + + col0 - - 53 AS col2 FROM tab0
----
1034
117
2520

query I rowsort
SELECT - col0 * - 5 AS col1 FROM tab2
----
35
390
395

query I rowsort
SELECT DISTINCT - ( + col0 * col0 ) + 97 - col1 * col0 AS col1 FROM tab0
----
-15923
-2543
-4523

query I rowsort
SELECT + + col0 + col0 * - col0 FROM tab2 cor0
----
-42
-6006
-6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7585
SELECT - CAST( NULL AS SIGNED ) + - tab2.col1 + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7585
SELECT - CAST ( NULL AS INTEGER ) + - tab2.col1 + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 42 + col2 + col1 * col0 FROM tab2
----
1423
286
4670

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7587
SELECT tab2.col0 * col0 + + CAST( - col1 AS SIGNED ) col2 FROM tab2
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7587
SELECT tab2.col0 * col0 + + CAST ( - col1 AS INTEGER ) col2 FROM tab2
----
18
6025
6224

query I rowsort
SELECT DISTINCT + ( - col0 ) * + 8 + 84 FROM tab1
----
-428
-556
60

query I rowsort
SELECT ALL - col0 * col1 + - 48 AS col0 FROM tab1
----
-1088
-126
-688

query I rowsort
SELECT DISTINCT + ( - col1 ) + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT DISTINCT + col2 * - col2 + 15 FROM tab0 AS cor0
----
-1074
-6709
14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7593
SELECT ALL - col0 * - col0 + + CAST( NULL AS SIGNED ) * 22 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7593
SELECT ALL - col0 * - col0 + + CAST ( NULL AS INTEGER ) * 22 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + + col0 * + col2 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT col1 * col0 * 82 FROM tab0 AS cor0
----
169248
278390
664118

query I rowsort
SELECT + 45 + - cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 5edc9d400e5d62cff9be601c3e75f68b

query I rowsort
SELECT DISTINCT - cor0.col2 * ( col0 ) + col2 * col0 AS col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT 99 + 2 AS col0 FROM tab1 AS cor0
----
101

onlyif mysql # use DIV operator for integer division
query I rowsort label-7600
SELECT ALL - - col0 * ( col0 ) + + cor0.col2 * + col1 DIV col1 FROM tab0 cor0
----
1226
609
8003

skipif mysql # not compatible
query I rowsort label-7600
SELECT ALL - - col0 * ( col0 ) + + cor0.col2 * + col1 / col1 FROM tab0 cor0
----
1226
609
8003

query I rowsort
SELECT - + ( + col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - col0 * + 71 FROM tab2 AS cor0
----
-497
-5538
-5609

query I rowsort
SELECT ALL - 28 FROM tab2, tab1 AS cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT cor0.col1 + + col1 * col1 AS col1 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 41 * col2 AS col1 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT ALL - 23 + + col1 FROM tab1 AS cor0
----
-10
-13
3

query I rowsort
SELECT ALL 45 * + ( col0 ) AS col1 FROM tab1 AS cor0
----
135
2880
3600

query I rowsort
SELECT - - col2 + 33 * + cor0.col0 FROM tab1 AS cor0
----
153
2169
2736

query I rowsort
SELECT DISTINCT + 78 * 87 FROM tab2 AS cor0
----
6786

query I rowsort
SELECT + - col0 + + col2 * col2 AS col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT - col2 * - tab1.col1 AS col0 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7613
SELECT col2 DIV col0 + - col1 * col2 col2 FROM tab2 AS cor0
----
-1534
-646
-834

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7613
SELECT col2 / col0 + - col1 * col2 col2 FROM tab2 AS cor0
----
-1534
-646
-834

onlyif mysql # use DIV operator for integer division
query I rowsort label-7614
SELECT DISTINCT + CAST( - col2 AS SIGNED ) * tab1.col1 DIV col0 AS col0 FROM tab1
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-7614
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) * tab1.col1 / col0 AS col0 FROM tab1
----
-15
-468
-8

query I rowsort
SELECT + col2 * - col1 * + col2 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT - 2 + col0 AS col0 FROM tab1
----
1
62
78

query I rowsort
SELECT DISTINCT col2 * col2 + col2 AS col2 FROM tab1
----
2970
3306
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7618
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + col0 * - col0 + col0 * col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-7618
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + col0 * - col0 + col0 * col1 FROM tab2
----
NULL

query I rowsort
SELECT + 88 * - col2 AS col2 FROM tab2
----
-2288
-2376
-3344

query I rowsort
SELECT - col0 * 94 FROM tab2
----
-658
-7332
-7426

query I rowsort
SELECT ALL col0 + - 73 FROM tab2 AS cor0
----
-66
5
6

query I rowsort
SELECT ALL - 46 * - col1 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT ALL ( cor0.col0 ) AS col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT - col1 + - col0 + col1 AS col0 FROM tab0 cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7625
SELECT 24 DIV col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-7625
SELECT 24 / col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT + col2 + + 66 + col2 AS col1 FROM tab1
----
174
180
258

query I rowsort
SELECT - col2 + 63 * + col0 AS col0 FROM tab2
----
414
4888
4939

query I rowsort
SELECT 51 + - col0 + - col0 FROM tab2 AS cor0
----
-105
-107
37

query I rowsort
SELECT - col1 * + col1 + cor0.col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT tab2.col0 * col2 AS col0 FROM tab2 WHERE NOT ( col0 + - col1 ) > col2 + + col2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7631
SELECT DISTINCT tab1.col1 DIV - col1 AS col2 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-7631
SELECT DISTINCT tab1.col1 / - col1 AS col2 FROM tab1
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7632
SELECT + col2 * col1 DIV + col0 AS col2 FROM tab1
----
15
468
8

skipif mysql # not compatible
query I rowsort label-7632
SELECT + col2 * col1 / + col0 AS col2 FROM tab1
----
15
468
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7633
SELECT ALL + col2 DIV + col1 AS col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7633
SELECT ALL + col2 / + col1 AS col0 FROM tab2
----
0
0
2

query I rowsort
SELECT col2 + col1 + tab0.col0 FROM tab0
----
133
143
262

query I rowsort
SELECT - tab1.col0 * + col0 + col0 AS col2 FROM tab1
----
-4032
-6
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col0 * col1 col1 FROM tab1
----
-1040
-640
-78

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NOT ( - col0 ) = ( + cor0.col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-7638
SELECT - cor0.col0 DIV - col2 + - col1 - - cor0.col2 FROM tab1 AS cor0
----
28
48
83

skipif mysql # not compatible
query I rowsort label-7638
SELECT - cor0.col0 / - col2 + - col1 - - cor0.col2 FROM tab1 AS cor0
----
28
48
83

query I rowsort
SELECT ALL + col2 - tab0.col0 FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 + + col1 * col1 col1 FROM tab0
----
15579
8188
9444

query I rowsort
SELECT ALL tab0.col2 + tab0.col2 AS col1 FROM tab0
----
164
2
66

query III rowsort
SELECT * FROM tab0 WHERE NULL BETWEEN NULL AND col0
----

query I rowsort
SELECT + col2 * col1 + - col2 * col1 AS col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 col2 FROM tab0 WHERE NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col2 * col2 - tab0.col1 * + col1 FROM tab0
----
-1557
-6307
-9408

query I rowsort
SELECT + tab1.col1 - + col2 * col2 * - col2 FROM tab1
----
157490
185203
884749

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT ( NULL ) IN ( col0 * + col2 + + cor0.col1 - col0 )
----

query I rowsort
SELECT ALL - tab1.col2 * - col1 * - col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT - col1 - ( - col1 ) AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + 98 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT - + 29 + col1 FROM tab0 AS cor0
----
57
62
68

query I rowsort
SELECT DISTINCT + 80 * - 36 FROM tab2 AS cor0
----
-2880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col2 * - col2 col1 FROM tab0 cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7654
SELECT ALL col1 DIV + cor0.col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7654
SELECT ALL col1 / + cor0.col1 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - tab0.col2 + + col2 * + col2 AS col0 FROM tab0
----
0
1056
6642

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 + col2 col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT ALL col2 + col0 + 87 AS col2 FROM tab0
----
123
144
258

onlyif mysql # use DIV operator for integer division
query I rowsort label-7658
SELECT ALL col2 * + col0 + col0 DIV col0 + tab2.col1 FROM tab2
----
2088
221
3020

skipif mysql # not compatible
query I rowsort label-7658
SELECT ALL col2 * + col0 + col0 / col0 + tab2.col1 FROM tab2
----
2088
221
3020

query I rowsort
SELECT ALL + col2 * - cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 + col1 + - col1 col0 FROM tab0 AS cor0
----
58
58
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 45 ) * + col1 col0 FROM tab2 cor0
----
1395
2655
765

query I rowsort
SELECT + - col0 * col1 + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7663
SELECT CAST( NULL AS SIGNED ) / col2 - - col0 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7663
SELECT CAST ( NULL AS INTEGER ) / col2 - - col0 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + + 70 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
1766
2547
6321

query I rowsort
SELECT DISTINCT - col2 + col2 + - cor0.col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL 58 + - col1 AS col2 FROM tab1 AS cor0
----
32
45
48

query I rowsort
SELECT - 23 + - 80 AS col1 FROM tab0 AS cor0
----
-103
-103
-103

query I rowsort
SELECT - col1 + 0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT col0 + 21 FROM tab2 cor0
----
100
28
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 20 * cor0.col2 * + col1 + - col2 * + 42 col2 FROM tab0 AS cor0
----
-152684
-1982
-58146

query I rowsort
SELECT ALL - 79 - - 36 * col1 FROM tab1 AS cor0
----
281
389
857

query I rowsort
SELECT ALL + col1 * 83 AS col2 FROM tab0 AS cor0
----
7138
7553
8051

query I rowsort
SELECT ALL - - 42 FROM tab2 cor0
----
42
42
42

query I rowsort
SELECT + col1 + - col0 * + col0 + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1163
-514
-7919

query I rowsort
SELECT ALL + + cor0.col1 * 35 AS col2 FROM tab0 AS cor0
----
3010
3185
3395

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7676
SELECT ALL - CAST( - col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7676
SELECT ALL - CAST ( - col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL ( + col2 ) * + 76 FROM tab1 AS cor0
----
4104
4332
7296

query I rowsort
SELECT ALL + col2 * col2 * cor0.col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT col2 + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL - + 53 * - col0 FROM tab1 AS cor0
----
159
3392
4240

query I rowsort
SELECT - col2 * + cor0.col2 + cor0.col0 AS col1 FROM tab0 cor0
----
-1065
-6635
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7682
SELECT DISTINCT + col2 / + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7682
SELECT DISTINCT + col2 / + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col0 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT ALL - col2 * + ( + 91 * - col2 ) FROM tab2 AS cor0
----
131404
61516
66339

query I rowsort
SELECT DISTINCT + - col2 * col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7686
SELECT - - col0 DIV + ( cor0.col1 ) FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7686
SELECT - - col0 / + ( cor0.col1 ) FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT - col2 * + 40 FROM tab2 AS cor0
----
-1040
-1080
-1520

query I rowsort
SELECT ALL col1 * - col0 + col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - col0 * - 87 * - col2 AS col1 FROM tab1 AS cor0
----
-14094
-317376
-668160

query I rowsort
SELECT col2 + - ( + 87 ) AS col0 FROM tab0 AS cor0
----
-5
-54
-86

query I rowsort
SELECT ALL + col2 * col0 + col2 * cor0.col2 * cor0.col0 FROM tab1 AS cor0
----
211584
744960
8910

onlyif mysql # use DIV operator for integer division
query I rowsort label-7692
SELECT DISTINCT - col2 * + 50 - - 39 DIV - col1 FROM tab1 AS cor0
----
-2701
-2853
-4803

skipif mysql # not compatible
query I rowsort label-7692
SELECT DISTINCT - col2 * + 50 - - 39 / - col1 FROM tab1 AS cor0
----
-2701
-2853
-4803

query I rowsort
SELECT DISTINCT + + col1 + - col0 AS col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL cor0.col2 - col2 * + col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + col0 * col0 * + 18 AS col0 FROM tab2 AS cor0
----
109512
112338
882

query I rowsort
SELECT col0 * ( col1 + + col2 ) AS col0 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT - col2 * col2 + 31 * col2 - - col0 FROM tab2
----
-187
115
208

query I rowsort
SELECT - col0 * + col0 + cor0.col1 * - col1 + col2 * + col1 FROM tab2 AS cor0
----
-173
-5884
-8031

query I rowsort
SELECT - col0 * col2 + + cor0.col1 + col2 * col0 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7700
SELECT - col1 DIV + 70 + col0 + - col2 FROM tab2 AS cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-7700
SELECT - col1 / + 70 + col0 + - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ( + col1 ) + 33 AS col0 FROM tab0 AS cor0
----
119
124
130

query I rowsort
SELECT ALL col2 + col2 - 29 AS col2 FROM tab1 AS cor0
----
163
79
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7703
SELECT DISTINCT + col0 - col2 DIV 48 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-7703
SELECT DISTINCT + col0 - col2 / 48 FROM tab0 AS cor0
----
24
35
88

query I rowsort
SELECT + 24 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to dfdfceb3acab6f866df9d676c07043ad

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * - 37 * col0 col0 FROM tab0 AS cor0
----
-125614
-299581
-76335

query I rowsort
SELECT ALL col2 * col2 + col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - + col0 * col2 + ( 70 ) AS col2 FROM tab2 AS cor0
----
-119
-1958
-2932

query I rowsort
SELECT - ( col2 ) + + ( col2 ) * + col2 AS col2 FROM tab2
----
1406
650
702

query I rowsort
SELECT ALL tab2.col2 AS col2 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ( - col0 * 86 ) FROM tab1
----
-258
-5504
-6880

query I rowsort
SELECT + col2 + col2 * - col1 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT 61 + + cor0.col1 FROM tab1 AS cor0
----
71
74
87

query I rowsort
SELECT ALL + - col1 * - col2 + - 40 + + col0 FROM tab0 cor0
----
2822
7511
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + tab1.col2 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 35de0b553e14f89ea44b7652e1ff642c

query I rowsort
SELECT + 57 + - col2 * col0 AS col2 FROM tab0 AS cor0
----
-7241
-735
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-7717
SELECT - - 28 DIV col2 + col1 DIV col0 AS col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-7717
SELECT - - 28 / col2 + col1 / col0 AS col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT - col1 * + col2 + - cor0.col0 * - cor0.col2 * col1 FROM tab1 cor0
----
2808
35910
98592

query I rowsort
SELECT ALL + - tab1.col0 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT - - 88 * - col2 + 15 * + col2 + - col1 FROM tab1 AS cor0
----
-3968
-4171
-7021

query I rowsort
SELECT DISTINCT + 28 AS col0 FROM tab2
----
28

query I rowsort
SELECT 37 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to c023509f63faa044d654943e6df55ca2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT DISTINCT ( + tab0.col0 ) AS col2 FROM tab0, tab1 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7725
SELECT ALL col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7725
SELECT ALL col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * 44 AS col0 FROM tab0 AS cor0
----
-1056
-1540
-3916

query I rowsort
SELECT + 4 * 94 FROM tab2 AS cor0
----
376
376
376

query I rowsort
SELECT - 74 * + 20 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to d9602d2c98ec2ad54304a574b635df3c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 col2 FROM tab0
----
95
95
95

query I rowsort
SELECT ALL - col0 * ( col0 ) AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT 81 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
112
140
98

query I rowsort
SELECT - - 34 + + 74 FROM tab2 AS cor0
----
108
108
108

query I rowsort
SELECT + + col1 - + col0 AS col2 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT - 23 + - 84 FROM tab0 AS cor0
----
-107
-107
-107

query I rowsort
SELECT ALL + ( col2 ) * col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - 88 + + col0 + - col2 * + col2 AS col1 FROM tab2 AS cor0
----
-1453
-686
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7737
SELECT - CAST( col1 AS SIGNED ) + col1 * 44 FROM tab0 cor0
----
3698
3913
4171

skipif mysql # not compatible
query I rowsort label-7737
SELECT - CAST ( col1 AS INTEGER ) + col1 * 44 FROM tab0 cor0
----
3698
3913
4171

query I rowsort
SELECT DISTINCT col2 * col2 * - tab0.col2 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT + col2 - + col1 * - col1 AS col2 FROM tab0
----
7429
8363
9410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7740
SELECT + CAST( - col1 AS SIGNED ) AS col0 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7740
SELECT + CAST ( - col1 AS INTEGER ) AS col0 FROM tab1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7741
SELECT CAST( NULL AS DECIMAL ) / ( tab2.col1 ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7741
SELECT CAST ( NULL AS REAL ) / ( tab2.col1 ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + col1 * col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT ALL + cor0.col0 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT ( - col0 ) + 61 FROM tab0
----
-28
26
37

query I rowsort
SELECT - + 45 + + col1 AS col0 FROM tab2 cor0
----
-14
-28
14

query I rowsort
SELECT + cor0.col2 * cor0.col2 + col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT + col0 + col1 + 93 FROM tab1 AS cor0
----
122
167
186

query I rowsort
SELECT ALL + col2 * col0 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT 87 + col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1621
733
924

query I rowsort
SELECT DISTINCT 71 * + col1 FROM tab0
----
6106
6461
6887

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col2 col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + + col0 + - col2 + - col2 AS col2 FROM tab1 cor0
----
-105
-112
-50

query I rowsort
SELECT + + 15 + col0 AS col0 FROM tab1 AS cor0
----
18
79
95

query I rowsort
SELECT + col2 * 45 FROM tab2 AS cor0
----
1170
1215
1710

query I rowsort
SELECT - + cor0.col2 + ( - col1 ) + col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - - ( - 46 ) AS col2 FROM tab0 AS cor0
----
-46
-46
-46

query I rowsort
SELECT ALL + - ( col0 ) * col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 4 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7759
SELECT - ( col2 ) DIV col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7759
SELECT - ( col2 ) / col2 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7760
SELECT - col0 DIV + 55 AS col0 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-7760
SELECT - col0 / + 55 AS col0 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT tab0.col0 * - 94 AS col0 FROM tab0
----
-2256
-3290
-8366

query I rowsort
SELECT - col0 * 0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col1 * + 76 AS col1 FROM tab0 AS cor0
----
6536
6916
7372

query I rowsort
SELECT ALL + + col2 * col1 * + col0 + col0 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT DISTINCT + - cor0.col2 + 73 - 62 * col0 AS col0 FROM tab0 AS cor0
----
-1448
-2098
-5527

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col2 + - CAST ( - 48 AS REAL ) AS col2 FROM tab2 AS cor0
----
10
21
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7767
SELECT DISTINCT + + col0 - + CAST( NULL AS SIGNED ) * cor0.col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7767
SELECT DISTINCT + + col0 - + CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 + + col0 * - 99 FROM tab0 AS cor0
----
-2290
-3368
-8720

query I rowsort
SELECT DISTINCT + col2 - 33 AS col2 FROM tab0 AS cor0
----
-32
0
49

query I rowsort
SELECT ALL + ( - 54 ) AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 25 col0 FROM tab2
----
25

query I rowsort
SELECT ALL + 77 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT DISTINCT + col1 + 11 FROM tab2
----
28
42
70

query I rowsort
SELECT ALL - col2 * + ( col1 ) * - col0 + + col2 FROM tab2
----
119678
51072
5886

query I rowsort
SELECT DISTINCT 8 AS col0 FROM tab0, tab0 AS cor0
----
8

query I rowsort
SELECT + col2 * + col1 * col2 + - col2 FROM tab2 cor0
----
22572
24510
39858

query I rowsort
SELECT ALL col0 + + ( + 44 ) AS col1 FROM tab1 AS cor0
----
108
124
47

query I rowsort
SELECT ALL + col1 + + 37 AS col2 FROM tab2 AS cor0
----
54
68
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 - col1 * col2 col2 FROM tab0 AS cor0
----
-132
-14760
-3630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7780
SELECT DISTINCT - col2 + + CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7780
SELECT DISTINCT - col2 + + CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT tab0.col2 + + tab0.col1 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT col2 + + tab0.col0 * col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT + col0 * + col0 AS col1 FROM tab2 WHERE NOT ( NULL ) > ( NULL )
----

query III rowsort
SELECT * FROM tab2 WHERE ( col0 + col2 + + col0 ) IN ( + col0 / + col1 - - col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE - col2 * + col1 NOT BETWEEN col0 * - col1 - col2 / - col2 AND - col1 + col1
----
3
26
54
80
13
96

query III rowsort
SELECT * FROM tab1 WHERE NULL IN ( col0 * col0 )
----

query I rowsort
SELECT ALL tab2.col0 - + tab2.col0 FROM tab2
----
0
0
0

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL NOT IN ( col0 / - col0 )
----

query I rowsort
SELECT ALL + tab1.col0 * + col2 - + col0 AS col1 FROM tab1
----
159
3584
7600

query III rowsort
SELECT * FROM tab2 WHERE NOT - col0 + col1 BETWEEN ( + col1 ) AND col0 + - col0 * + col0
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - - col2 + + col0 * + col1 AS col2 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT ALL - 40 * - col1 FROM tab0
----
3440
3640
3880

query I rowsort
SELECT DISTINCT - tab0.col2 * + col2 AS col0 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + + 41 * col0 FROM tab1 AS cor0
----
123
2624
3280

query I rowsort
SELECT DISTINCT col2 * - col0 + ( + cor0.col1 ) FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT + 36 * col0 + + ( col2 + - col1 ) * - col1 AS col0 FROM tab2
----
2487
376
4755

query I rowsort
SELECT + + 90 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT + col1 + col2 * - col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + 44 * col2 AS col1 FROM tab1 AS cor0
----
2376
2508
4224

query I rowsort
SELECT ALL + 84 - cor0.col0 * 63 FROM tab1 AS cor0
----
-105
-3948
-4956

query I rowsort
SELECT DISTINCT + - col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + - col1 * + col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col1 * - col1 AS col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + cor0.col1 * - col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - - col2 * ( - col0 * col2 ) AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + cor0.col0 ) * cor0.col0 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 4734c38591591662f77999e8d1e5daf1

query I rowsort
SELECT DISTINCT 21 * + cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
1134
1197
2016

query I rowsort
SELECT col2 * col1 + - col2 FROM tab1 cor0
----
1152
1350
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-7810
SELECT + 89 + cor0.col0 DIV cor0.col2 FROM tab0 AS cor0
----
124
89
90

skipif mysql # not compatible
query I rowsort label-7810
SELECT + 89 + cor0.col0 / cor0.col2 FROM tab0 AS cor0
----
124
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7811
SELECT DISTINCT + - ( - 98 ) DIV - col0 + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-7
77
78

skipif mysql # not compatible
query I rowsort label-7811
SELECT DISTINCT + - ( - 98 ) / - col0 + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-7
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7812
SELECT ALL + 41 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7812
SELECT ALL + 41 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 * + col0 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT 15 + + col2 FROM tab2 AS cor0
----
41
42
53

query I rowsort
SELECT ALL 23 * col0 - - col0 AS col0 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT ALL - + ( + col1 ) * - col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + + cor0.col2 + - col2 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT col1 * cor0.col0 + - col2 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT DISTINCT - 9 + col0 AS col1 FROM tab0
----
15
26
80

query I rowsort
SELECT ALL + col1 + - col1 * - col2 * - ( + col0 ) AS col2 FROM tab1 cor0
----
-36470
-4186
-99827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + col1 col2 FROM tab1 cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 52 col0 FROM tab0 AS cor0
----
52
52
52

query I rowsort
SELECT + ( - 13 ) FROM tab0
----
-13
-13
-13

query I rowsort
SELECT ( + col0 ) - + col0 AS col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7825
SELECT + col1 + - 15 DIV col1 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-7825
SELECT + col1 + - 15 / col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT - 57 * col2 * col1 FROM tab1
----
-32490
-71136
-80028

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 62 * + col2 + col1 col2 FROM tab1
----
3374
3544
5965

query I rowsort
SELECT - ( cor0.col2 ) FROM tab1, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT - cor0.col1 * 90 - - col2 AS col2 FROM tab2 AS cor0
----
-1492
-2763
-5284

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 80 col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7831
SELECT - - col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7831
SELECT - - col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7832
SELECT + ( 11 ) DIV col0 + + cor0.col0 + - 84 * + col1 FROM tab0 cor0
----
-7200
-7555
-8113

skipif mysql # not compatible
query I rowsort label-7832
SELECT + ( 11 ) / col0 + + cor0.col0 + - 84 * + col1 FROM tab0 cor0
----
-7200
-7555
-8113

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 4 + - col2 * - col1 col1 FROM tab2 AS cor0
----
1538
650
841

query I rowsort
SELECT 71 + col1 AS col0 FROM tab2 AS cor0
----
102
130
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-7835
SELECT DISTINCT - col2 * 4 + col2 + + col0 DIV col2 FROM tab0 AS cor0
----
-245
-99
32

skipif mysql # not compatible
query I rowsort label-7835
SELECT DISTINCT - col2 * 4 + col2 + + col0 / col2 FROM tab0 AS cor0
----
-245
-99
32

query I rowsort
SELECT col2 * - 57 + - col1 + - cor0.col0 FROM tab2 AS cor0
----
-1577
-1619
-2262

query I rowsort
SELECT - + col0 + + col1 - col0 FROM tab1 AS cor0
----
-118
-147
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7838
SELECT DISTINCT col0 DIV - 56 AS col0 FROM tab2 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7838
SELECT DISTINCT col0 / - 56 AS col0 FROM tab2 cor0
----
-1
0

query I rowsort
SELECT ALL col1 * cor0.col0 + col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + col1 * col1 + ( + col1 + - col2 * ( col2 ) ) FROM tab0 cor0
----
1648
6393
9505

query I rowsort
SELECT ALL + + col2 * + cor0.col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7842
SELECT - + cor0.col1 DIV col1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7842
SELECT - + cor0.col1 / col1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - + cor0.col1 * - 30 AS col2 FROM tab0 AS cor0
----
2580
2730
2910

query I rowsort
SELECT - - cor0.col0 * 30 FROM tab1 AS cor0
----
1920
2400
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col2 col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - col0 + - 26 * - col2 FROM tab1 AS cor0
----
1407
1546
2576

onlyif mysql # use DIV operator for integer division
query I rowsort label-7847
SELECT ALL + - col1 DIV 22 - - col0 AS col2 FROM tab0 AS cor0
----
21
31
85

skipif mysql # not compatible
query I rowsort label-7847
SELECT ALL + - col1 / 22 - - col0 AS col2 FROM tab0 AS cor0
----
21
31
85

query I rowsort
SELECT cor0.col2 * - cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 * CAST ( - col0 AS REAL ) AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 12 + 83 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 24 col0 FROM tab1
----
-24
-24
-24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7852
SELECT col1 + + CAST( col2 * - col1 + - col1 AS SIGNED ) FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-7852
SELECT col1 + + CAST ( col2 * - col1 + - col1 AS INTEGER ) FROM tab2
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7853
SELECT DISTINCT + + col1 DIV col0 + cor0.col2 FROM tab0 cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-7853
SELECT DISTINCT + + col1 / col0 + cor0.col2 FROM tab0 cor0
----
3
36
83

query I rowsort
SELECT ALL + - col2 - + col2 FROM tab0 AS cor0
----
-164
-2
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 73 col2 FROM tab2, tab0 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT + 2 * 38 FROM tab1
----
76
76
76

query I rowsort
SELECT 58 + + 53 AS col0 FROM tab0
----
111
111
111

skipif mysql # not compatible
query I rowsort
SELECT - 6 * ( col1 * + CAST ( - col2 AS REAL ) ) AS col0 FROM tab2
----
3876
5022
9204

query I rowsort
SELECT - col0 + 56 AS col0 FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT ALL col2 + tab0.col1 * col0 + col0 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT - 38 AS col0 FROM tab0 cor0
----
-38
-38
-38

query I rowsort
SELECT 12 * - col0 AS col1 FROM tab1 AS cor0
----
-36
-768
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-7863
SELECT ALL + col2 + tab0.col0 DIV + col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7863
SELECT ALL + col2 + tab0.col0 / + col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - 9 + - col1 AS col0 FROM tab0 AS cor0
----
-100
-106
-95

query I rowsort
SELECT - 96 * cor0.col2 + col0 FROM tab1 AS cor0
----
-5181
-5408
-9136

query I rowsort
SELECT + col1 * + col2 + + cor0.col0 AS col1 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT ALL 62 * + cor0.col0 + col0 FROM tab0 cor0
----
1512
2205
5607

query I rowsort
SELECT DISTINCT - + cor0.col1 + cor0.col1 - cor0.col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7869
SELECT - col0 + - col0 DIV ( 73 * + col1 ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-7869
SELECT - col0 + - col0 / ( 73 * + col1 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT col0 * col0 + col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-7871
SELECT - + 63 DIV + col0 + - ( - col1 ) * + col1 FROM tab1 AS cor0
----
100
169
655

skipif mysql # not compatible
query I rowsort label-7871
SELECT - + 63 / + col0 + - ( - col1 ) * + col1 FROM tab1 AS cor0
----
100
169
655

onlyif mysql # use DIV operator for integer division
query I rowsort label-7872
SELECT col1 + + col0 DIV 22 FROM tab0 AS cor0
----
87
95
98

skipif mysql # not compatible
query I rowsort label-7872
SELECT col1 + + col0 / 22 FROM tab0 AS cor0
----
87
95
98

query I rowsort
SELECT DISTINCT - col2 + + col0 + - col0 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + - col2 * col0 + - col1 FROM tab0 cor0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT 61 * 18 + col1 + ( - ( + col1 ) ) AS col0 FROM tab2 AS cor0
----
1098

query I rowsort
SELECT ALL - + 10 + col0 * + col1 AS col1 FROM tab2 AS cor0
----
1333
207
4592

query I rowsort
SELECT - cor0.col1 + - ( cor0.col1 ) FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT ALL ( 40 ) AS col0 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT - + ( cor0.col0 ) * + col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7880
SELECT DISTINCT - col0 DIV - 9 + + col1 AS col1 FROM tab0 AS cor0
----
100
88

skipif mysql # not compatible
query I rowsort label-7880
SELECT DISTINCT - col0 / - 9 + + col1 AS col1 FROM tab0 AS cor0
----
100
88

query I rowsort
SELECT ALL 45 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ALL ( 11 * - col0 + 32 ) AS col2 FROM tab2
----
-45
-826
-837

query I rowsort
SELECT DISTINCT + cor0.col0 + + col1 - - col2 * - ( col1 ) AS col2 FROM tab1 AS cor0
----
-1155
-1375
-496

query I rowsort
SELECT DISTINCT ( + ( - cor0.col2 ) ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - col1 * - col1 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + col0 * 61 FROM tab0 cor0
----
1464
2135
5429

query I rowsort
SELECT ALL - - col2 - + col0 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 48 + + col2 * 91 FROM tab2 cor0
----
2414
2505
3506

query I rowsort
SELECT - 26 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2812
71
7436

query I rowsort
SELECT DISTINCT + 45 * col0 FROM tab0 AS cor0
----
1080
1575
4005

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 ) + 59 col2 FROM tab0 AS cor0
----
145
150
156

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7893
SELECT CAST( NULL AS SIGNED ) * tab0.col2 + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7893
SELECT CAST ( NULL AS INTEGER ) * tab0.col2 + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 45 + col2 FROM tab0
----
127
46
78

query I rowsort
SELECT - 38 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT + 52 + - ( col1 ) FROM tab2
----
-7
21
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 17 + col2 col0 FROM tab2 AS cor0
----
1352
1381
146

query I rowsort
SELECT ALL col2 * - col0 + + col1 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - - cor0.col1 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col1 * col2 + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL col0 - - 69 AS col1 FROM tab1 AS cor0
----
133
149
72

query I rowsort
SELECT - col0 * col1 + - 72 FROM tab2 AS cor0
----
-1415
-289
-4674

query I rowsort
SELECT ALL col2 * cor0.col1 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col1 + col2 * - ( + col2 * ( col1 ) ) AS col0 FROM tab2 cor0
----
-22630
-24565
-39943

query I rowsort
SELECT col1 + - col2 * - ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - + col0 * 54 + 2 AS col0 FROM tab2 AS cor0
----
-376
-4210
-4264

onlyif mysql # use DIV operator for integer division
query I rowsort label-7907
SELECT ALL - - col1 DIV + CAST( + col0 * col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7907
SELECT ALL - - col1 / + CAST ( + col0 * col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * + ( 67 * - col0 ) + ( cor0.col0 * - col2 ) FROM tab1 AS cor0
----
-46528
-5388
-77360

query I rowsort
SELECT DISTINCT + col1 + + col2 * + ( col1 ) FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL col0 * col1 - col2 AS col0 FROM tab1
----
24
583
944

query I rowsort
SELECT ALL + 6 - - col1 FROM tab1
----
16
19
32

query I rowsort
SELECT ALL + col2 - ( - 13 ) FROM tab1 AS cor0
----
109
67
70

query I rowsort
SELECT DISTINCT 34 * col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT ALL col2 * 40 + + 90 FROM tab2 cor0
----
1130
1170
1610

query I rowsort
SELECT DISTINCT col0 * - col2 + + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-7916
SELECT DISTINCT + col0 * ( + 43 ) DIV col1 FROM tab2 AS cor0
----
199
56
9

skipif mysql # not compatible
query I rowsort label-7916
SELECT DISTINCT + col0 * ( + 43 ) / col1 FROM tab2 AS cor0
----
199
56
9

query I rowsort
SELECT - col0 * 68 AS col1 FROM tab2
----
-476
-5304
-5372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7918
SELECT CAST( NULL AS SIGNED ) - 2 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7918
SELECT CAST ( NULL AS INTEGER ) - 2 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT cor0.col2 AS col2 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT col0 * ( - col1 ) + + tab2.col0 * - col1 FROM tab2
----
-2686
-434
-9204

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2 cor1, tab1 cor2
----
3645 values hashing to 731e4a6549b312ba21c2e61ca9bede27

query I rowsort
SELECT - 13 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

query I rowsort
SELECT DISTINCT 35 + - col0 FROM tab1 cor0
----
-29
-45
32

query I rowsort
SELECT - + ( + 14 ) + - col2 AS col2 FROM tab2 AS cor0
----
-40
-41
-52

query I rowsort
SELECT - col0 + 96 AS col0 FROM tab0 cor0
----
61
7
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-7926
SELECT ALL - col0 DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-7926
SELECT ALL - col0 / cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT 8 * + col1 AS col1 FROM tab1 AS cor0
----
104
208
80

query I rowsort
SELECT ALL + 12 AS col1 FROM tab1 cor0
----
12
12
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 31 col0 FROM tab1 AS cor0
----
31

query I rowsort
SELECT ALL cor0.col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col2 col1 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT ALL col1 * col0 + - col1 AS col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + + 29 * col0 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT ALL + 0 * col1 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - + col1 * - col1 * col0 AS col2 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7936
SELECT ALL - + col2 + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7936
SELECT ALL - + col2 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 col1 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT ALL cor0.col1 * + 3 AS col2 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT ALL - - col1 + 16 * + col0 * - col0 FROM tab1 cor0
----
-102387
-118
-65526

query I rowsort
SELECT col1 * - tab0.col2 * col2 AS col1 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT ALL - cor1.col0 * 83 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d7947f3dff4b2e25e032725c9ac3510

query I rowsort
SELECT - col1 * 75 + 39 + col0 AS col2 FROM tab1 AS cor0
----
-1908
-647
-856

query I rowsort
SELECT - col0 * - ( - col1 ) * - col1 - col1 FROM tab1 AS cor0
----
13507
2002
6390

query I rowsort
SELECT - col2 + col1 * 63 * cor0.col0 + cor0.col2 * 48 FROM tab0 AS cor0
----
131583
213932
514091

query I rowsort
SELECT + 27 AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT DISTINCT + ( + 31 ) * + col2 * + 75 + 82 FROM tab0 AS cor0
----
190732
2407
76807

query I rowsort
SELECT DISTINCT 16 + ( col1 ) AS col2 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT ALL + ( + col0 ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT tab0.col0 * + tab0.col2 FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7950
SELECT - 76 DIV col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7950
SELECT - 76 / col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * col2 + col1 AS col0 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT col1 * 34 * cor0.col1 AS col1 FROM tab1 AS cor0
----
22984
3400
5746

query I rowsort
SELECT ALL + + col0 + col1 * 35 * - col1 AS col1 FROM tab2 cor0
----
-10036
-121757
-33628

query I rowsort
SELECT col1 + + 72 AS col0 FROM tab0 AS cor0
----
158
163
169

query I rowsort
SELECT + col0 * - ( col1 + col1 ) FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT col1 * + col0 * - 26 + - col1 FROM tab2 AS cor0
----
-119711
-34935
-5673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7957
SELECT CAST( NULL AS DECIMAL ) + - 2 / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7957
SELECT CAST ( NULL AS REAL ) + - 2 / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7958
SELECT cor0.col2 + + col0 * + col1 * CAST( + cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
118826
49569
720893

skipif mysql # not compatible
query I rowsort label-7958
SELECT cor0.col2 + + col0 * + col1 * CAST ( + cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
118826
49569
720893

query I rowsort
SELECT + 73 * cor0.col2 AS col1 FROM tab0 AS cor0
----
2409
5986
73

query I rowsort
SELECT - + 6 + col1 AS col1 FROM tab1 AS cor0
----
20
4
7

query I rowsort
SELECT DISTINCT col2 * - 34 * col1 FROM tab1
----
-19380
-42432
-47736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 50 col2 FROM tab2
----
-350
-3900
-3950

query I rowsort
SELECT + - col0 * 44 * - col2 + - col1 AS col0 FROM tab2 AS cor0
----
132071
8285
89173

query I rowsort
SELECT + + cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ( + 66 ) + cor0.col0 * + col0 AS col2 FROM tab1 AS cor0
----
4162
6466
75

query I rowsort
SELECT DISTINCT - 37 FROM tab1, tab2 AS cor0
----
-37

query I rowsort
SELECT + col2 + 18 * + col0 FROM tab2 AS cor0
----
1430
1460
153

query I rowsort
SELECT DISTINCT + ( - col2 ) * + col2 + ( col1 ) FROM tab0
----
-1003
-6633
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7969
SELECT + CAST( NULL AS SIGNED ) + - 79 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7969
SELECT + CAST ( NULL AS INTEGER ) + - 79 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 59 + 10 * col1 FROM tab2 AS cor0
----
229
369
649

query I rowsort
SELECT ALL - - 35 FROM tab2 cor0
----
35
35
35

query I rowsort
SELECT ALL + - 10 - + 90 * col1 AS col2 FROM tab1 cor0
----
-1180
-2350
-910

query I rowsort
SELECT ALL 6 FROM tab1, tab2 cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 + + 38 * col1 col0 FROM tab1 AS cor0
----
1011
403
517

query I rowsort
SELECT DISTINCT + + 69 * - col2 * ( - 99 ) + - col2 AS col1 FROM tab1 AS cor0
----
368820
389310
655680

query I rowsort
SELECT DISTINCT + - 63 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-1512
-2205
-5607

query I rowsort
SELECT 82 + col2 AS col1 FROM tab1
----
136
139
178

query I rowsort
SELECT + tab2.col1 + - 81 FROM tab2
----
-22
-50
-64

query I rowsort
SELECT - ( - 25 + col0 ) * col2 * 74 FROM tab1
----
-164502
-390720
87912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 58 + + col1 * ( col2 ) col2 FROM tab0
----
-2150
-5529
2184

query I rowsort
SELECT 54 - + 67 AS col0 FROM tab2
----
-13
-13
-13

query I rowsort
SELECT DISTINCT + ( + col2 ) + col0 * + 0 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - col0 + col2 + - col1 FROM tab2 AS cor0
----
-11
-111
-58

query I rowsort
SELECT - col0 - 76 AS col0 FROM tab2 AS cor0
----
-154
-155
-83

query I rowsort
SELECT + 31 * + col1 FROM tab0
----
2666
2821
3007

query I rowsort
SELECT - + col1 - ( - 73 * col1 + + col2 ) FROM tab2 cor0
----
1186
2205
4222

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + 42 + + 37 col0 FROM tab1 AS cor0
----
163
2725
3397

query I rowsort
SELECT col1 + 40 FROM tab0 AS cor0
----
126
131
137

onlyif mysql # use DIV operator for integer division
query I rowsort label-7989
SELECT ALL + - col2 DIV col1 + cor0.col2 + col2 * col2 FROM tab2 AS cor0
----
1480
702
756

skipif mysql # not compatible
query I rowsort label-7989
SELECT ALL + - col2 / col1 + cor0.col2 + col2 * col2 FROM tab2 AS cor0
----
1480
702
756

query I rowsort
SELECT DISTINCT - col0 * - col1 * 73 + cor0.col0 * col0 AS col0 FROM tab1 AS cor0
----
50816
5703
82320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT 44 * + col2 AS col0 FROM tab1
----
2376
2508
4224

onlyif mysql # use DIV operator for integer division
query I rowsort label-7993
SELECT + tab1.col2 DIV + col2 - 40 FROM tab1
----
-39
-39
-39

skipif mysql # not compatible
query I rowsort label-7993
SELECT + tab1.col2 / + col2 - 40 FROM tab1
----
-39
-39
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7994
SELECT ALL col0 * CAST( col1 AS SIGNED ) + + col0 * CAST( + col0 + + col0 AS SIGNED ) AS col0 FROM tab0
----
23941
3216
5845

skipif mysql # not compatible
query I rowsort label-7994
SELECT ALL col0 * CAST ( col1 AS INTEGER ) + + col0 * CAST ( + col0 + + col0 AS INTEGER ) AS col0 FROM tab0
----
23941
3216
5845

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7995
SELECT col1 * - CAST( - 10 AS SIGNED ) + + col0 * - ( col2 + col0 ) FROM tab1 cor0
----
-13950
-7644
89

skipif mysql # not compatible
query I rowsort label-7995
SELECT col1 * - CAST ( - 10 AS INTEGER ) + + col0 * - ( col2 + col0 ) FROM tab1 cor0
----
-13950
-7644
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7996
SELECT - + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7996
SELECT - + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col2 + 10 FROM tab1 AS cor0
----
-44
-47
-86

query I rowsort
SELECT DISTINCT 76 + col0 + + col0 * - 63 FROM tab0
----
-1412
-2094
-5442

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7999
SELECT ( + col0 ) * + CAST( - 44 AS SIGNED ) AS col1 FROM tab2
----
-308
-3432
-3476

skipif mysql # not compatible
query I rowsort label-7999
SELECT ( + col0 ) * + CAST ( - 44 AS INTEGER ) AS col1 FROM tab2
----
-308
-3432
-3476

query I rowsort
SELECT DISTINCT - 76 + col1 AS col2 FROM tab2
----
-17
-45
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 + + col0 col1 FROM tab2
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-8002
SELECT - 72 * cor0.col2 + + col1 DIV col0 FROM tab2 AS cor0
----
-1872
-1940
-2736

skipif mysql # not compatible
query I rowsort label-8002
SELECT - 72 * cor0.col2 + + col1 / col0 FROM tab2 AS cor0
----
-1872
-1940
-2736

query I rowsort
SELECT DISTINCT + + 8 * - col2 + + cor0.col2 FROM tab0 AS cor0
----
-231
-574
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8004
SELECT DISTINCT + col1 DIV - ( col1 ) AS col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8004
SELECT DISTINCT + col1 / - ( col1 ) AS col2 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col0 col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + - col1 + 74 * + col2 AS col1 FROM tab0 AS cor0
----
-23
2356
5977

query I rowsort
SELECT DISTINCT cor0.col1 + + ( + col2 ) AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col1 * + 96 AS col0 FROM tab0 AS cor0
----
8256
8736
9312

query I rowsort
SELECT col2 * - 14 + - col0 * - col0 AS col0 FROM tab2 AS cor0
----
-329
5709
5720

query I rowsort
SELECT col0 * cor0.col0 + 51 AS col2 FROM tab2 AS cor0
----
100
6135
6292

query I rowsort
SELECT + 12 AS col0 FROM tab2
----
12
12
12

query I rowsort
SELECT ALL col2 + + col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT + tab2.col2 + - tab2.col2 FROM tab2
----
0
0
0

query I rowsort
SELECT 19 + + col1 * 23 FROM tab0
----
1997
2112
2250

query I rowsort
SELECT DISTINCT - cor0.col2 * + 89 AS col2 FROM tab0 AS cor0
----
-2937
-7298
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8016
SELECT ALL - col1 DIV + ( - col1 ) FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8016
SELECT ALL - col1 / + ( - col1 ) FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - col2 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1152
1350
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-8018
SELECT DISTINCT - col2 * + ( - 75 * col0 ) + 77 DIV - col1 FROM tab2 AS cor0
----
14173
152099
225146

skipif mysql # not compatible
query I rowsort label-8018
SELECT DISTINCT - col2 * + ( - 75 * col0 ) + 77 / - col1 FROM tab2 AS cor0
----
14173
152099
225146

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8019
SELECT + col1 + CAST( - 42 + col0 AS SIGNED ) * - 17 * - col1 AS col2 FROM tab1 AS cor0
----
-17212
3750
8411

skipif mysql # not compatible
query I rowsort label-8019
SELECT + col1 + CAST ( - 42 + col0 AS INTEGER ) * - 17 * - col1 AS col2 FROM tab1 AS cor0
----
-17212
3750
8411

query I rowsort
SELECT + col1 + + col2 * col0 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - ( 17 ) AS col2 FROM tab0 cor0
----
-17
-17
-17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8022
SELECT ALL - ( - 18 ) * + cor0.col2 + CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8022
SELECT ALL - ( - 18 ) * + cor0.col2 + CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8023
SELECT ALL - 8 DIV 38 + col0 + + 34 FROM tab0 AS cor0
----
123
58
69

skipif mysql # not compatible
query I rowsort label-8023
SELECT ALL - 8 / 38 + col0 + + 34 FROM tab0 AS cor0
----
123
58
69

query I rowsort
SELECT ALL 86 + 84 FROM tab0 AS cor0
----
170
170
170

query I rowsort
SELECT DISTINCT - col1 + - ( tab0.col0 ) * + col2 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT ALL col2 * col1 * col0 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + - ( 80 ) * col1 + col1 FROM tab2 AS cor0
----
-1343
-2449
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + ( col2 ) col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - + ( cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 43 + + col1 * + col0 col0 FROM tab2 cor0
----
1386
260
4645

query I rowsort
SELECT + - 94 - + col1 AS col1 FROM tab1 AS cor0
----
-104
-107
-120

query I rowsort
SELECT ALL + 44 + - 64 FROM tab0 AS cor0
----
-20
-20
-20

query I rowsort
SELECT - ( col0 ) - - cor0.col0 * col0 FROM tab0 cor0
----
1190
552
7832

query I rowsort
SELECT ALL + 47 * - 90 AS col0 FROM tab1 AS cor0
----
-4230
-4230
-4230

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 85 * col0 + + cor0.col2 * + col0 col2 FROM tab0 AS cor0
----
14863
2832
3010

onlyif mysql # use DIV operator for integer division
query I rowsort label-8036
SELECT tab1.col0 DIV + 32 FROM tab1
----
0
2
2

skipif mysql # not compatible
query I rowsort label-8036
SELECT tab1.col0 / + 32 FROM tab1
----
0
2
2

query I rowsort
SELECT + + col1 * col0 + - 75 AS col0 FROM tab0 cor0
----
1989
3320
8024

onlyif mysql # use DIV operator for integer division
query I rowsort label-8038
SELECT ALL + ( 15 ) DIV - col1 - + 90 AS col1 FROM tab0
----
-90
-90
-90

skipif mysql # not compatible
query I rowsort label-8038
SELECT ALL + ( 15 ) / - col1 - + 90 AS col1 FROM tab0
----
-90
-90
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8039
SELECT - - 44 DIV col1 + ( + col1 ) AS col2 FROM tab1 AS cor0
----
14
16
27

skipif mysql # not compatible
query I rowsort label-8039
SELECT - - 44 / col1 + ( + col1 ) AS col2 FROM tab1 AS cor0
----
14
16
27

query I rowsort
SELECT - 26 * + col2 + + col0 AS col0 FROM tab1 AS cor0
----
-1401
-1418
-2416

query I rowsort
SELECT - - ( + col1 ) * - col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + col1 + col1 * + ( col0 ) AS col2 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + - 5 * cor0.col1 * 11 FROM tab1 AS cor0
----
-1430
-550
-715

query I rowsort
SELECT - + 62 + - col1 FROM tab2 AS cor0
----
-121
-79
-93

query I rowsort
SELECT DISTINCT + + cor0.col2 + - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - ( + col0 ) - + col0 * col2 FROM tab1 cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT - col0 + col0 * cor0.col0 * col0 FROM tab0 AS cor0
----
13800
42840
704880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 14 * col1 col2 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT - + cor0.col0 + col0 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 42 - col2 AS col1 FROM tab0 AS cor0
----
-40
41
9

query I rowsort
SELECT col0 * cor0.col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - ( col0 ) * + 68 FROM tab1
----
-204
-4352
-5440

onlyif mysql # use DIV operator for integer division
query I rowsort label-8053
SELECT ALL col0 + col0 DIV cor0.col0 AS col2 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-8053
SELECT ALL col0 + col0 / cor0.col0 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT cor0.col2 * - col0 - - 71 AS col1 FROM tab1 cor0
----
-3577
-7609
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-8055
SELECT ALL - - col2 * - col2 + - col0 * col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
-1365
-598
-722

skipif mysql # not compatible
query I rowsort label-8055
SELECT ALL - - col2 * - col2 + - col0 * col0 / - col0 AS col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT - + 37 + - col1 AS col2 FROM tab0 AS cor0
----
-123
-128
-134

query I rowsort
SELECT col1 + - 62 AS col0 FROM tab0
----
24
29
35

query I rowsort
SELECT 66 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT DISTINCT + col1 * 4 * - tab2.col2 AS col2 FROM tab2
----
-2584
-3348
-6136

query I rowsort
SELECT cor0.col0 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + 13 FROM tab1, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT + ( 9 * tab1.col2 ) FROM tab1
----
486
513
864

query I rowsort
SELECT - 82 AS col0 FROM tab1
----
-82
-82
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * 86 col1 FROM tab2 AS cor0
----
2236
2322
3268

onlyif mysql # use DIV operator for integer division
query I rowsort label-8065
SELECT ALL - ( col0 ) * + cor0.col2 + col1 DIV + col0 AS col2 FROM tab2 cor0
----
-185
-2028
-3002

skipif mysql # not compatible
query I rowsort label-8065
SELECT ALL - ( col0 ) * + cor0.col2 + col1 / + col0 AS col2 FROM tab2 cor0
----
-185
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 * + col1 col0 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT + col1 * - 68 FROM tab0 cor0
----
-5848
-6188
-6596

query I rowsort
SELECT + + 47 * 5 FROM tab2 AS cor0
----
235
235
235

query I rowsort
SELECT ALL + col1 + 71 FROM tab2 AS cor0
----
102
130
88

query I rowsort
SELECT DISTINCT + 0 + - 57 * col2 FROM tab2 AS cor0
----
-1482
-1539
-2166

query I rowsort
SELECT ALL col1 + - col0 - - col2 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT + - 82 AS col1 FROM tab2 AS cor0
----
-82
-82
-82

query I rowsort
SELECT col1 * - 85 FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT - col0 * ( - 20 ) * - tab2.col1 AS col0 FROM tab2
----
-26860
-4340
-92040

query I rowsort
SELECT ALL - tab2.col2 * 94 * + col0 FROM tab2
----
-17766
-190632
-282188

query I rowsort
SELECT DISTINCT - 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-8077
SELECT + CAST( NULL AS DECIMAL ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8077
SELECT + CAST ( NULL AS REAL ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 * + 30 + - col0 * col1 FROM tab2 AS cor0
----
-2832
-833
713

query I rowsort
SELECT ALL tab2.col0 + tab2.col1 AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT col2 * + col2 * - ( + 93 ) AS col0 FROM tab1
----
-271188
-302157
-857088

query I rowsort
SELECT DISTINCT - - ( col1 ) * ( + col1 ) * col0 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT + 24 + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1272
1428
594

query I rowsort
SELECT ALL + tab2.col2 + + 62 FROM tab2, tab2 AS cor0
----
9 values hashing to bff21414625c6b821505b8eb61865ab4

query I rowsort
SELECT col2 * - col2 + col2 * - col1 AS col0 FROM tab2 AS cor0
----
-1566
-2090
-2210

query I rowsort
SELECT - - col2 - - ( 9 + - cor0.col0 ) AS col1 FROM tab1 AS cor0
----
2
25
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-8086
SELECT cor0.col1 DIV - cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 52d7579cb9aa84ba8a466e09c3562381

skipif mysql # not compatible
query I rowsort label-8086
SELECT cor0.col1 / - cor0.col2 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 52d7579cb9aa84ba8a466e09c3562381

query I rowsort
SELECT - col2 + col2 * ( - col0 + + cor0.col1 ) AS col0 FROM tab2 cor0
----
-2394
-520
621

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8088
SELECT - col0 * - 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-8088
SELECT - col0 * - CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + col1 + cor0.col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1079
-470
-728

query I rowsort
SELECT ALL col1 * - col1 + 64 AS col1 FROM tab0
----
-7332
-8217
-9345

query I rowsort
SELECT ALL + + 58 + col2 AS col1 FROM tab1 cor0
----
112
115
154

query I rowsort
SELECT col0 * 45 + + col1 AS col2 FROM tab2
----
346
3569
3572

onlyif mysql # use DIV operator for integer division
query I rowsort label-8093
SELECT ALL + 84 DIV + cor0.col1 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-8093
SELECT ALL + 84 / + cor0.col1 FROM tab1 AS cor0
----
3
6
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8094
SELECT DISTINCT + CAST( 23 AS SIGNED ) DIV col2 AS col0 FROM tab0 AS cor0
----
0
23

skipif mysql # not compatible
query I rowsort label-8094
SELECT DISTINCT + CAST ( 23 AS INTEGER ) / col2 AS col0 FROM tab0 AS cor0
----
0
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8095
SELECT col2 * col1 + col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8095
SELECT col2 * col1 + col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8096
SELECT ALL - 30 * col2 + CAST( 90 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-1050
-690
-720

skipif mysql # not compatible
query I rowsort label-8096
SELECT ALL - 30 * col2 + CAST ( 90 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1050
-690
-720

query I rowsort
SELECT ALL - cor0.col0 * + col2 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8099
SELECT col1 * + CAST( NULL AS SIGNED ) - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8099
SELECT col1 * + CAST ( NULL AS INTEGER ) - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8100
SELECT ALL - - col2 + + col0 DIV cor0.col1 AS col2 FROM tab1 AS cor0
----
102
54
63

skipif mysql # not compatible
query I rowsort label-8100
SELECT ALL - - col2 + + col0 / cor0.col1 AS col2 FROM tab1 AS cor0
----
102
54
63

query I rowsort
SELECT ALL + col1 * + 14 FROM tab2 AS cor0
----
238
434
826

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 57 col0 FROM tab0 AS cor0
----
1881
4674
57

query I rowsort
SELECT - col0 * col1 + 1 * 32 AS col2 FROM tab0
----
-2032
-3363
-8067

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col0 col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
3
64
80

query I rowsort
SELECT - col2 * - cor0.col0 - col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-8106
SELECT DISTINCT + tab1.col2 DIV col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-8106
SELECT DISTINCT + tab1.col2 / col1 FROM tab1
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8107
SELECT - 82 * cor0.col2 DIV col1 + 14 FROM tab1 AS cor0
----
-156
-453
-591

skipif mysql # not compatible
query I rowsort label-8107
SELECT - 82 * cor0.col2 / col1 + 14 FROM tab1 AS cor0
----
-156
-453
-591

onlyif mysql # use DIV operator for integer division
query I rowsort label-8108
SELECT - col0 DIV col2 - - col1 * col2 AS col2 FROM tab1
----
1248
1404
569

skipif mysql # not compatible
query I rowsort label-8108
SELECT - col0 / col2 - - col1 * col2 AS col2 FROM tab1
----
1248
1404
569

query I rowsort
SELECT ALL + + 88 * col2 + col1 AS col0 FROM tab2 AS cor0
----
2347
2407
3361

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8110
SELECT ALL CAST( NULL AS SIGNED ) col1 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8110
SELECT ALL CAST ( NULL AS INTEGER ) col1 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + - 46 + col1 FROM tab1 cor0
----
-20
-33
-36

query I rowsort
SELECT ALL col0 FROM tab1 WHERE NULL = ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 + tab0.col2 - col1 col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT col0 * - col1 + col1 AS col2 FROM tab1
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-8115
SELECT ALL + col0 DIV + col2 + - col2 + col1 FROM tab1
----
-28
-46
-83

skipif mysql # not compatible
query I rowsort label-8115
SELECT ALL + col0 / + col2 + - col2 + col1 FROM tab1
----
-28
-46
-83

query I rowsort
SELECT DISTINCT col0 * + col1 * col1 AS col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT col1 + + col2 + + col1 AS col0 FROM tab2
----
144
72
89

query I rowsort
SELECT ALL col2 + - col2 + col0 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 * col1 col1 FROM tab0 WHERE NOT ( - col1 - col2 * + col0 ) NOT IN ( col0 )
----

query I rowsort
SELECT + col0 * - col0 * + col0 AS col1 FROM tab2
----
-343
-474552
-493039

onlyif mysql # use DIV operator for integer division
query I rowsort label-8121
SELECT ALL + tab1.col1 + + col0 + - col2 DIV tab1.col1 FROM tab1
----
27
69
86

skipif mysql # not compatible
query I rowsort label-8121
SELECT ALL + tab1.col1 + + col0 + - col2 / tab1.col1 FROM tab1
----
27
69
86

query I rowsort
SELECT DISTINCT col1 * + col2 + - tab2.col0 + - tab2.col2 AS col0 FROM tab2
----
1430
529
803

query I rowsort
SELECT 90 * + tab1.col2 * col0 + - col2 FROM tab1
----
14526
328263
691104

query I rowsort
SELECT - col1 + + tab2.col0 * + col0 * + col1 AS col2 FROM tab2
----
106080
1488
358897

query I rowsort
SELECT - tab2.col0 * tab2.col0 AS col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT - 8 + tab2.col0 AS col1 FROM tab2
----
-1
70
71

query I rowsort
SELECT - + 11 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

query I rowsort
SELECT ALL + 13 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-221
-403
-767

query I rowsort
SELECT ALL - - col0 * + col0 + cor0.col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT DISTINCT + 16 - - col0 AS col2 FROM tab0 AS cor0
----
105
40
51

query I rowsort
SELECT + 62 + + col0 FROM tab2 AS cor0
----
140
141
69

query I rowsort
SELECT 17 FROM tab0, tab1 AS cor0, tab1 cor1, tab0 AS cor2
----
81 values hashing to 71801088bb30ca6eac036729ebfbbace

query I rowsort
SELECT - 56 * col0 AS col2 FROM tab2
----
-392
-4368
-4424

query I rowsort
SELECT ALL - - 50 AS col1 FROM tab0, tab1 AS cor0, tab1 cor1, tab1, tab1 AS cor2
----
243 values hashing to b834e2084022ca341153dd05ef833c6b

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE - col1 NOT BETWEEN NULL AND ( + col1 + col0 + + col2 )
----

query I rowsort
SELECT DISTINCT col2 FROM tab1 WHERE NOT - col2 <= NULL
----

query I rowsort
SELECT DISTINCT tab2.col1 / + col2 AS col1 FROM tab2 WHERE col1 > ( NULL )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL IN ( + col1 + - col0 * col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col2 * col2 * + col1 <= - col0 + - col0
----

query I rowsort
SELECT ALL tab2.col1 / col2 + - tab2.col0 AS col0 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 * - tab1.col0 col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - col1 + col1 * + col1 * - col1 AS col2 FROM tab1 WHERE NOT - col2 * col1 >= NULL
----

query I rowsort
SELECT col2 + col2 AS col1 FROM tab0 WHERE NOT col1 * - col2 BETWEEN col0 AND NULL
----
164
2
66

query I rowsort
SELECT col0 * + col1 + - col0 * col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - tab0.col2 * - col2 AS col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + col1 / col2 AS col0 FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN - col2 * col0 AND col1
----

query I rowsort
SELECT ALL - tab1.col2 + + col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col0 - + tab0.col1 AS col0 FROM tab0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 col0 FROM tab0 WHERE ( NULL ) <> - col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - col0 col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - 79 FROM tab0, tab0 AS cor0
----
-79

query I rowsort
SELECT ALL + 51 + - 80 AS col1 FROM tab0 AS cor0
----
-29
-29
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-8153
SELECT - 25 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8153
SELECT - 25 / cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 55 - col2 AS col1 FROM tab1 AS cor0
----
-109
-112
-151

query I rowsort
SELECT + ( + col0 ) - 86 AS col0 FROM tab2 AS cor0
----
-7
-79
-8

query I rowsort
SELECT + + cor0.col0 - col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - 29 * - cor0.col0 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
18560
2262
30160

query I rowsort
SELECT ALL 50 * + col1 FROM tab0
----
4300
4550
4850

query I rowsort
SELECT ALL + 70 * cor0.col1 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to be00591f9886d7eb84584586c1406373

onlyif mysql # use DIV operator for integer division
query I rowsort label-8160
SELECT + col1 + col0 DIV - col2 FROM tab1 AS cor0
----
13
26
9

skipif mysql # not compatible
query I rowsort label-8160
SELECT + col1 + col0 / - col2 FROM tab1 AS cor0
----
13
26
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8161
SELECT col2 * col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8161
SELECT col2 * col1 / - col1 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8162
SELECT DISTINCT + col1 * - col2 + col2 DIV - col0 AS col2 FROM tab2 cor0
----
-1534
-646
-840

skipif mysql # not compatible
query I rowsort label-8162
SELECT DISTINCT + col1 * - col2 + col2 / - col0 AS col2 FROM tab2 cor0
----
-1534
-646
-840

query I rowsort
SELECT DISTINCT + col0 + + col2 + + cor0.col0 * col0 FROM tab0 AS cor0
----
1261
633
8092

query I rowsort
SELECT ALL + col1 * 68 AS col0 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT ALL - ( - col0 ) + ( - col1 ) * col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT 28 * 75 AS col2 FROM tab0, tab2 AS cor0
----
2100

query I rowsort
SELECT + col2 + ( col2 ) * - col2 AS col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-8168
SELECT - col1 DIV ( col2 * cor0.col1 + + col2 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8168
SELECT - col1 / ( col2 * cor0.col1 + + col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * ( col0 + + col0 ) * + 61 FROM tab1
----
19764
445056
936960

query I rowsort
SELECT + + cor0.col2 * + cor0.col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b2e5b025b1c725661248b0f29aaef908

query I rowsort
SELECT 57 FROM tab2, tab0 cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT col0 * - col0 + - cor0.col2 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT - - 67 + cor0.col0 * + ( col0 ) FROM tab0 AS cor0
----
1292
643
7988

query I rowsort
SELECT + col1 * + col1 * - col2 - + col1 AS col2 FROM tab2 AS cor0
----
-10999
-25978
-90565

query I rowsort
SELECT ALL - - col0 * col2 + - ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL + 42 * col1 AS col0 FROM tab2 AS cor0
----
1302
2478
714

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 92 + - col2 col2 FROM tab1 AS cor0
----
-4
35
38

query I rowsort
SELECT ALL - col1 + 75 * + 35 FROM tab1 AS cor0
----
2599
2612
2615

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + col2 + + col2 col1 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT - col2 * + col1 + col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT 43 * + 10 + + col0 FROM tab1 AS cor0
----
433
494
510

query I rowsort
SELECT + 63 * - col1 FROM tab2
----
-1071
-1953
-3717

query I rowsort
SELECT 10 * col2 FROM tab1
----
540
570
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8184
SELECT + ( tab1.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-8184
SELECT + ( tab1.col0 ) / + col1 col1 FROM tab1
----
0
6
6

query I rowsort
SELECT 20 * - col1 FROM tab2
----
-1180
-340
-620

query I rowsort
SELECT ALL + 73 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT + - col2 + + 81 FROM tab1 cor0
----
-15
24
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-8188
SELECT 28 DIV col0 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-8188
SELECT 28 / col0 FROM tab2
----
0
0
4

query I rowsort
SELECT ALL ( 33 ) * col1 AS col0 FROM tab1
----
330
429
858

query I rowsort
SELECT ALL + - col2 + - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT + 93 * cor0.col0 FROM tab1, tab0 AS cor0
----
2232
3255
8277

query I rowsort
SELECT tab0.col2 + + tab0.col1 * col2 AS col0 FROM tab0
----
2871
7544
98

query I rowsort
SELECT + + col1 + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8194
SELECT 80 DIV + col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8194
SELECT 80 / + col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL 26 * + col2 + + 24 FROM tab1
----
1428
1506
2520

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8196
SELECT - col1 * + col1 * + CAST( + 80 AS SIGNED ) col2 FROM tab1 AS cor0
----
-13520
-54080
-8000

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8196
SELECT - col1 * + col1 * + CAST ( + 80 AS INTEGER ) col2 FROM tab1 AS cor0
----
-13520
-54080
-8000

query I rowsort
SELECT ALL + col1 + + col1 * cor0.col1 FROM tab0 AS cor0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + + 74 * col0 + col1 AS col2 FROM tab1 AS cor0
----
248
4746
5933

query I rowsort
SELECT col2 * col2 * - col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT 54 + - col0 * 35 FROM tab1 AS cor0
----
-2186
-2746
-51

query I rowsort
SELECT ALL tab1.col0 * tab1.col0 + - col1 AS col1 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT col0 * - 5 + - 96 * - col2 AS col0 FROM tab0
----
-79
3048
7427

query I rowsort
SELECT + tab0.col1 * 19 AS col0 FROM tab0
----
1634
1729
1843

query I rowsort
SELECT 78 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT - col0 + + 1 AS col0 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT - col0 + ( + ( - col0 ) ) FROM tab2 AS cor0
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 50 + + col2 * col0 * - col1 col0 FROM tab2 AS cor0
----
-116702
-4309
-50184

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8209
SELECT - CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8209
SELECT - CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * - 60 FROM tab1 AS cor0
----
180
3840
4800

query I rowsort
SELECT DISTINCT + + 20 AS col0 FROM tab0 AS cor0
----
20

query I rowsort
SELECT ALL col2 * 51 AS col2 FROM tab1 cor0
----
2754
2907
4896

query I rowsort
SELECT - + col2 + - ( col2 ) AS col1 FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT - col0 + col2 * cor0.col2 AS col1 FROM tab1 cor0
----
2913
3185
9136

query I rowsort
SELECT + col0 + - col2 * + cor0.col1 * 56 AS col0 FROM tab0 cor0
----
-158904
-417783
-5397

query I rowsort
SELECT - - 11 * col1 FROM tab1 AS cor0
----
110
143
286

onlyif mysql # use DIV operator for integer division
query I rowsort label-8217
SELECT DISTINCT col0 DIV - ( ( - col0 ) ) AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-8217
SELECT DISTINCT col0 / - ( ( - col0 ) ) AS col2 FROM tab1
----
1

query I rowsort
SELECT DISTINCT + col2 * 65 AS col1 FROM tab0 AS cor0
----
2145
5330
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8219
SELECT - CAST( col2 AS SIGNED ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-8219
SELECT - CAST ( col2 AS INTEGER ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT 1 + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT - - 44 AS col1 FROM tab2 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT - 79 + ( col2 ) AS col2 FROM tab0 AS cor0
----
-46
-78
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8223
SELECT + - col1 * col0 DIV + col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-8223
SELECT + - col1 * col0 / + col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT col0 + col0 * + col1 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-8225
SELECT ALL - - col0 DIV cor0.col1 col0 FROM tab2 AS cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8225
SELECT ALL - - col0 / cor0.col1 col0 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL cor0.col0 + col2 * col2 AS col0 FROM tab0 AS cor0
----
1113
36
6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 60 col0 FROM tab2 cor0
----
-1020
-1860
-3540

query I rowsort
SELECT - 16 + - 29 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 71160abf09589695379a70558726f0ba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - ( col2 + + col1 ) * - col0 col0 FROM tab0
----
15486
2880
3465

query I rowsort
SELECT ALL col0 + - ( 80 ) AS col2 FROM tab0
----
-45
-56
9

query I rowsort
SELECT - col2 + col2 - col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - - ( ( + tab2.col0 ) ) FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 + col0 * ( - col0 ) * tab2.col0 col0 FROM tab2
----
-316
-474526
-493001

query I rowsort
SELECT - col2 + 46 FROM tab0
----
-36
13
45

query I rowsort
SELECT DISTINCT - tab1.col2 + + col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT col2 * + col1 + col1 + - col2 AS col1 FROM tab2
----
1567
625
841

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 79 + - col1 col1 FROM tab0
----
-165
-170
-176

query I rowsort
SELECT ALL col0 + col0 * + cor0.col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + col0 + - col0 * - 50 AS col0 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT DISTINCT - 77 * + col2 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
517748
77
83853

query I rowsort
SELECT DISTINCT col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + ( cor0.col0 ) + + ( 15 + col0 ) AS col1 FROM tab2 cor0
----
171
173
29

query I rowsort
SELECT - 20 + col2 AS col0 FROM tab1
----
34
37
76

query I rowsort
SELECT ALL col2 + col2 * - tab0.col1 * ( 46 ) AS col1 FROM tab0
----
-130515
-343170
-4461

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8246
SELECT DISTINCT CAST( col0 AS SIGNED ) * + col0 + + col2 AS col0 FROM tab2
----
6110
6279
76

skipif mysql # not compatible
query I rowsort label-8246
SELECT DISTINCT CAST ( col0 AS INTEGER ) * + col0 + + col2 AS col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT + ( col2 ) * + col1 - col2 AS col1 FROM tab1
----
1152
1350
513

query I rowsort
SELECT col1 * col1 + + col0 AS col1 FROM tab1
----
164
249
679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8249
SELECT CAST( NULL AS SIGNED ) + - ( - col0 ) * + ( 36 ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8249
SELECT CAST ( NULL AS INTEGER ) + - ( - col0 ) * + ( 36 ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 55 * + col2 * 75 FROM tab1 AS cor0
----
222750
235125
396000

query I rowsort
SELECT DISTINCT + + col1 * - cor0.col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + 1 AS col2 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - cor0.col2 * col2 * + col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT + - 35 FROM tab1 AS cor0
----
-35

query I rowsort
SELECT DISTINCT + 6 - - cor0.col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1337
-211
-4596

query I rowsort
SELECT ALL - col1 * col0 * - col0 FROM tab2 AS cor0
----
106097
1519
358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * cor0.col1 col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-8258
SELECT ALL cor0.col0 * col0 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8258
SELECT ALL cor0.col0 * col0 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8259
SELECT DISTINCT - - cor0.col1 + col0 DIV col1 FROM tab1 cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-8259
SELECT DISTINCT - - cor0.col1 + col0 / col1 FROM tab1 cor0
----
16
19
26

query I rowsort
SELECT + 60 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT + - col2 * + 85 AS col0 FROM tab1 AS cor0
----
-4590
-4845
-8160

query I rowsort
SELECT ( - col1 ) + - col1 * col1 FROM tab1
----
-110
-182
-702

query I rowsort
SELECT + 88 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT ALL + col1 * - cor0.col0 + 53 FROM tab2 cor0
----
-1290
-164
-4549

query I rowsort
SELECT DISTINCT - + 0 + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + + col0 * - col0 + + col1 AS col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL cor0.col0 + ( + col1 + - cor0.col0 ) FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 71 col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
71

query I rowsort
SELECT - - col2 * + 42 AS col1 FROM tab2 cor0
----
1092
1134
1596

query I rowsort
SELECT ALL col1 * 12 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
1056
1181
1199

onlyif mysql # use DIV operator for integer division
query I rowsort label-8271
SELECT - ( col1 ) + col0 DIV col2 AS col2 FROM tab0 AS cor0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-8271
SELECT - ( col1 ) + col0 / col2 AS col2 FROM tab0 AS cor0
----
-62
-86
-90

query I rowsort
SELECT ALL + ( col1 ) * col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + col2 * col2 + col1 + col2 AS col2 FROM tab0 AS cor0
----
1208
6897
99

query I rowsort
SELECT + 75 + + 52 AS col1 FROM tab2 AS cor0
----
127
127
127

query I rowsort
SELECT ALL 41 AS col0 FROM tab0 cor0
----
41
41
41

query I rowsort
SELECT DISTINCT - + 3 * + col2 + col1 FROM tab1 AS cor0
----
-136
-161
-275

query I rowsort
SELECT - 16 + 53 * col0 + + ( col2 ) * col2 * col1 AS col2 FROM tab0 AS cor0
----
1936
616585
94910

query I rowsort
SELECT ALL - ( - 27 ) * + col0 FROM tab2 AS cor0
----
189
2106
2133

query I rowsort
SELECT DISTINCT - - col2 + - cor0.col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8280
SELECT DISTINCT - - CAST( + col0 AS SIGNED ) * col0 * col0 + + 55 AS col1 FROM tab0 AS cor0
----
13879
42930
705024

skipif mysql # not compatible
query I rowsort label-8280
SELECT DISTINCT - - CAST ( + col0 AS INTEGER ) * col0 * col0 + + 55 AS col1 FROM tab0 AS cor0
----
13879
42930
705024

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 + col1 col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8282
SELECT DISTINCT - ( + col1 ) * col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8282
SELECT DISTINCT - ( + col1 ) * col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8283
SELECT col2 + - col2 DIV + col0 AS col2 FROM tab0 AS cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-8283
SELECT col2 + - col2 / + col0 AS col2 FROM tab0 AS cor0
----
1
32
82

query I rowsort
SELECT 61 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT - ( + col2 ) + ( col1 ) FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8286
SELECT CAST( col2 AS SIGNED ) DIV col2 + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-8286
SELECT CAST ( col2 AS INTEGER ) / col2 + col2 FROM tab1
----
55
58
97

query I rowsort
SELECT - 92 + 40 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

query I rowsort
SELECT + col2 * tab1.col2 + col0 * col0 AS col1 FROM tab1
----
15616
2925
7345

onlyif mysql # use DIV operator for integer division
query I rowsort label-8289
SELECT col2 DIV - ( - col0 ) + col0 + - col1 AS col2 FROM tab2
----
-21
19
62

skipif mysql # not compatible
query I rowsort label-8289
SELECT col2 / - ( - col0 ) + col0 + - col1 AS col2 FROM tab2
----
-21
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8290
SELECT ALL + col2 - CAST( NULL AS SIGNED ) col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8290
SELECT ALL + col2 - CAST ( NULL AS INTEGER ) col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8291
SELECT col1 DIV ( + tab1.col2 * col0 ) AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8291
SELECT col1 / ( + tab1.col2 * col0 ) AS col2 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8292
SELECT DISTINCT - CAST( NULL AS SIGNED ) * 44 FROM tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8292
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * 44 FROM tab0, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8293
SELECT col1 * + CAST( 10 AS SIGNED ) - - tab2.col2 DIV col1 FROM tab2
----
172
310
590

skipif mysql # not compatible
query I rowsort label-8293
SELECT col1 * + CAST ( 10 AS INTEGER ) - - tab2.col2 / col1 FROM tab2
----
172
310
590

query I rowsort
SELECT + cor0.col2 * col2 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT + col1 + + col2 * + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL tab1.col0 + ( - col2 * col0 ) FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT + 72 * 12 FROM tab1 AS cor0
----
864

query I rowsort
SELECT DISTINCT + - 4 AS col2 FROM tab2 cor0
----
-4

query I rowsort
SELECT ALL ( + col2 ) * - col0 + - 15 FROM tab1 AS cor0
----
-177
-3663
-7695

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8300
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + 46 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8300
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + 46 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT 78 - col2 FROM tab2 AS cor0
----
40
51
52

query I rowsort
SELECT + col2 * 45 + + col1 * ( cor0.col0 * col2 + 40 ) FROM tab2 AS cor0
----
123182
53424
8314

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 73 col0 FROM tab1 AS cor0
----
219
4672
5840

query I rowsort
SELECT + + 21 * 18 FROM tab2 AS cor0
----
378
378
378

query I rowsort
SELECT + col1 + - cor0.col2 * + ( + col0 ) AS col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL 94 * col1 * + tab1.col2 AS col0 FROM tab1
----
117312
131976
53580

query I rowsort
SELECT - ( + col1 ) * + col1 + cor0.col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT - + col0 * - cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT + cor0.col1 * ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL col1 + 11 AS col1 FROM tab1 AS cor0
----
21
24
37

query I rowsort
SELECT DISTINCT + col1 * 28 AS col2 FROM tab0 AS cor0
----
2408
2548
2716

query I rowsort
SELECT + col2 + - col0 * 1 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + + cor0.col0 * - 36 FROM tab0 cor0
----
-1260
-3204
-864

query I rowsort
SELECT 25 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT DISTINCT col1 * + tab2.col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT + cor0.col1 * + 42 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT - - col0 + - 11 * col2 AS col1 FROM tab1 AS cor0
----
-563
-591
-976

query I rowsort
SELECT DISTINCT - col2 + 26 AS col2 FROM tab0 cor0
----
-56
-7
25

query I rowsort
SELECT DISTINCT - - cor0.col2 * + 92 + 32 AS col2 FROM tab2 AS cor0
----
2424
2516
3528

onlyif mysql # use DIV operator for integer division
query I rowsort label-8320
SELECT - col1 + 47 DIV col1 AS col0 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8320
SELECT - col1 + 47 / col1 AS col0 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - - col1 * 37 FROM tab0 AS cor0
----
3182
3367
3589

onlyif mysql # use DIV operator for integer division
query I rowsort label-8322
SELECT col1 DIV ( - col0 + - col0 ) AS col1 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-8322
SELECT col1 / ( - col0 + - col0 ) AS col1 FROM tab0 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + ( + col1 ) col2 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8324
SELECT DISTINCT + col0 * - col2 + CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8324
SELECT DISTINCT + col0 * - col2 + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 * 22 AS col1 FROM tab0 cor0
----
119
1895
812

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8326
SELECT ALL - col0 * + CAST( - col2 AS SIGNED ) + - col0 col1 FROM tab2 AS cor0
----
182
1950
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8326
SELECT ALL - col0 * + CAST ( - col2 AS INTEGER ) + - col0 col1 FROM tab2 AS cor0
----
182
1950
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + col2 + col2 * + col0 col0 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT DISTINCT + col2 + + col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
327
3507
988

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 * col1 * - col2 + - cor0.col2 + + CAST ( col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
244121
679051
9505

query I rowsort
SELECT ALL + col0 * + ( cor0.col0 ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + 68 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
68

query I rowsort
SELECT 19 * 36 FROM tab2 AS cor0
----
684
684
684

query I rowsort
SELECT DISTINCT - 5 * + col1 AS col0 FROM tab1 cor0
----
-130
-50
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-8334
SELECT ALL - 62 + - col1 DIV ( + ( + cor0.col2 ) ) FROM tab0 AS cor0
----
-159
-63
-64

skipif mysql # not compatible
query I rowsort label-8334
SELECT ALL - 62 + - col1 / ( + ( + cor0.col2 ) ) FROM tab0 AS cor0
----
-159
-63
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 32 * col2 col0 FROM tab2
----
1216
832
864

query I rowsort
SELECT DISTINCT col0 - tab1.col0 * + col1 AS col2 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8337
SELECT DISTINCT 22 * col1 + col0 DIV 28 AS col1 FROM tab1
----
222
288
572

skipif mysql # not compatible
query I rowsort label-8337
SELECT DISTINCT 22 * col1 + col0 / 28 AS col1 FROM tab1
----
222
288
572

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab2, tab1, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col1 * col1 - ( - col2 ) AS col2 FROM tab0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 42 + col0 col1 FROM tab2
----
-35
36
37

query I rowsort
SELECT + col1 * col2 * 22 - + col1 * col1 FROM tab2
----
13923
17453
30267

query I rowsort
SELECT ALL col2 * col0 + + 62 * + ( - col1 ) FROM tab0
----
-4540
-5979
1656

query I rowsort
SELECT ALL - - col2 * + col1 * + col2 + - 43 FROM tab0 AS cor0
----
54
611841
93611

query I rowsort
SELECT ALL - col2 * + col1 - + col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT col1 * col0 * 31 + + tab2.col0 * - tab2.col0 FROM tab2
----
136578
35392
6678

query I rowsort
SELECT + ( 56 * col0 + - 17 * + 88 ) AS col0 FROM tab0
----
-152
3488
464

query I rowsort
SELECT DISTINCT + col0 * - ( col2 * col1 ) FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL 22 * 97 AS col0 FROM tab1 AS cor0
----
2134
2134
2134

query I rowsort
SELECT + + col1 * cor0.col2 + cor0.col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8350
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col0 col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8350
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col0 col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col0 * + col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8352
SELECT 23 DIV cor0.col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8352
SELECT 23 / cor0.col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8353
SELECT DISTINCT - ( 78 ) DIV col0 AS col1 FROM tab1 AS cor0
----
-1
-26
0

skipif mysql # not compatible
query I rowsort label-8353
SELECT DISTINCT - ( 78 ) / col0 AS col1 FROM tab1 AS cor0
----
-1
-26
0

query I rowsort
SELECT ALL - 37 * col1 AS col2 FROM tab2 AS cor0
----
-1147
-2183
-629

query I rowsort
SELECT DISTINCT + 44 AS col1 FROM tab1 AS cor0
----
44

query I rowsort
SELECT ALL + 31 * 87 * cor0.col1 FROM tab1 cor0
----
26970
35061
70122

query I rowsort
SELECT col2 * ( col2 ) AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - + 91 * col1 * cor0.col2 FROM tab2 cor0
----
-139594
-58786
-76167

query I rowsort
SELECT DISTINCT col1 - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - - col1 * col2 + + 58 FROM tab0 AS cor0
----
155
2896
7520

query I rowsort
SELECT ALL 18 * col0 * - col1 FROM tab0
----
-145782
-37152
-61110

query I rowsort
SELECT ALL col0 + col1 * 47 * col0 AS col1 FROM tab0 cor0
----
159600
380742
97032

query I rowsort
SELECT - col2 * + cor0.col1 * col0 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-3492
-664209
-68198

query I rowsort
SELECT col2 * + ( col1 * col1 ) + + 53 * - col2 * col1 FROM tab0 AS cor0
----
283556
4268
93654

onlyif mysql # use DIV operator for integer division
query I rowsort label-8365
SELECT col1 * + col2 + cor0.col0 DIV col2 FROM tab1 AS cor0
----
1248
1404
571

skipif mysql # not compatible
query I rowsort label-8365
SELECT col1 * + col2 + cor0.col0 / col2 FROM tab1 AS cor0
----
1248
1404
571

query I rowsort
SELECT DISTINCT - col0 + 64 * ( col2 ) AS col1 FROM tab1 AS cor0
----
3453
3584
6064

query I rowsort
SELECT ALL - col1 + ( - col2 * col2 ) AS col1 FROM tab1
----
-2942
-3259
-9229

query I rowsort
SELECT - tab0.col2 - col1 AS col1 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT ALL - col0 * - col0 + 50 AS col0 FROM tab2
----
6134
6291
99

query I rowsort
SELECT DISTINCT tab0.col2 + + col1 + ( tab0.col1 ) FROM tab0
----
195
205
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8371
SELECT + - CAST( - cor0.col2 AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8371
SELECT + - CAST ( - cor0.col2 AS INTEGER ) FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8372
SELECT DISTINCT - col1 * CAST( NULL AS DECIMAL ) + - 37 AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8372
SELECT DISTINCT - col1 * CAST ( NULL AS REAL ) + - 37 AS col2 FROM tab0
----
NULL

query I rowsort
SELECT - col2 * ( col0 * - col0 ) AS col2 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT 95 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8375
SELECT + col1 + - col1 DIV + col0 FROM tab1
----
10
13
18

skipif mysql # not compatible
query I rowsort label-8375
SELECT + col1 + - col1 / + col0 FROM tab1
----
10
13
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-8376
SELECT - col2 DIV + CAST( col0 AS SIGNED ) + col1 * - col0 FROM tab0
----
-2065
-3395
-8099

skipif mysql # not compatible
query I rowsort label-8376
SELECT - col2 / + CAST ( col0 AS INTEGER ) + col1 * - col0 FROM tab0
----
-2065
-3395
-8099

query I rowsort
SELECT ALL - col1 + + tab1.col1 + - col2 AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT - col2 + - col1 * + col1 FROM tab1
----
-157
-265
-730

query I rowsort
SELECT 0 + 90 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT - col2 * - 23 + col1 FROM tab1 AS cor0
----
1268
1321
2221

query I rowsort
SELECT - 58 * 75 + + col0 AS col0 FROM tab0 AS cor0
----
-4261
-4315
-4326

query I rowsort
SELECT ALL cor0.col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL tab0.col1 * - ( col0 ) + col2 AS col0 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT + 60 * 32 * + col2 FROM tab2
----
49920
51840
72960

query I rowsort
SELECT - col1 * - col2 + col0 * col2 AS col2 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT - - 56 * - 37 + + col0 * 47 FROM tab0 AS cor0
----
-427
-944
2111

query I rowsort
SELECT ALL - 45 AS col1 FROM tab0
----
-45
-45
-45

query I rowsort
SELECT - 69 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

onlyif mysql # use DIV operator for integer division
query I rowsort label-8389
SELECT - col1 * col2 DIV - col0 + - col0 FROM tab0 AS cor0
----
-33
-6
94

skipif mysql # not compatible
query I rowsort label-8389
SELECT - col1 * col2 / - col0 + - col0 FROM tab0 AS cor0
----
-33
-6
94

query I rowsort
SELECT - cor0.col2 - col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + col0 * + ( + cor0.col2 ) - col0 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT + 71 * col2 AS col0 FROM tab0 AS cor0
----
2343
5822
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8393
SELECT DISTINCT col0 * CAST( ( col2 ) AS SIGNED ) + col0 AS col0 FROM tab0 cor0
----
70
7387
816

skipif mysql # not compatible
query I rowsort label-8393
SELECT DISTINCT col0 * CAST ( ( col2 ) AS INTEGER ) + col0 AS col0 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT + + col0 * ( - col0 ) + + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - col0 + col2 * ( col1 ) * col2 AS col1 FROM tab2 AS cor0
----
22592
24469
39806

query I rowsort
SELECT col1 - 88 FROM tab0 AS cor0
----
-2
3
9

query I rowsort
SELECT + col1 + ( col2 ) AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col0 + + 81 FROM tab0 AS cor0
----
105
116
170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + - col2 * + ( + col1 ) - + col1 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8401
SELECT ALL - CAST( + col0 AS SIGNED ) AS col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-8401
SELECT ALL - CAST ( + col0 AS INTEGER ) AS col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT col0 + cor0.col0 + col0 AS col2 FROM tab2 AS cor0
----
21
234
237

onlyif mysql # use DIV operator for integer division
query I rowsort label-8403
SELECT DISTINCT - + 21 DIV + col0 + col0 * col1 FROM tab1 AS cor0
----
1040
640
71

skipif mysql # not compatible
query I rowsort label-8403
SELECT DISTINCT - + 21 / + col0 + col0 * col1 FROM tab1 AS cor0
----
1040
640
71

query I rowsort
SELECT ALL - 63 - + col2 FROM tab2 AS cor0
----
-101
-89
-90

query I rowsort
SELECT + tab2.col1 + - ( col2 ) AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT + ( ( col1 ) + col1 ) * col0 FROM tab2
----
2686
434
9204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - + col1 col0 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT + col0 + + cor0.col0 * col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT 0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 58 * col2 AS col0 FROM tab2 AS cor0
----
-1508
-1566
-2204

query I rowsort
SELECT ALL 53 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT ALL + 96 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT - ( + 17 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT DISTINCT + 86 + 20 AS col1 FROM tab2, tab1 cor0
----
106

query I rowsort
SELECT - - col0 + + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + + col0 * ( + col0 ) + - col2 * + cor0.col1 FROM tab1 AS cor0
----
-1395
3526
5152

query I rowsort
SELECT - cor0.col0 * col0 + col2 * col2 + + col1 * cor0.col1 AS col0 FROM tab0 AS cor0
----
7084
7909
8185

query I rowsort
SELECT ( + col1 ) * col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + + 88 FROM tab2 cor0
----
88
88
88

query I rowsort
SELECT - - 14 + - ( - col1 ) * col0 AS col1 FROM tab0 AS cor0
----
2078
3409
8113

query I rowsort
SELECT DISTINCT tab1.col0 + - cor0.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1
----
9 values hashing to 082e660fdb43b4559ee4c78f197723a3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - tab2.col1 + + tab2.col2 AS col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 546a494e1798cb1c65d1510d48d04dff

query I rowsort
SELECT DISTINCT + col1 * col0 * - col2 + col1 + - col2 FROM tab1
----
-36527
-4240
-99923

query I rowsort
SELECT DISTINCT + + col0 + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 * col1 * cor0.col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-8427
SELECT ALL col0 + + col1 DIV + col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-8427
SELECT ALL col0 + + col1 / + col0 FROM tab1 AS cor0
----
11
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8428
SELECT ALL - col1 DIV + col0 + - col0 AS col2 FROM tab0 cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-8428
SELECT ALL - col1 / + col0 + - col0 AS col2 FROM tab0 cor0
----
-27
-37
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col2 * col1 col2 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8430
SELECT - - col2 + - col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-8430
SELECT - - col2 + - col2 / + col2 AS col2 FROM tab0 AS cor0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8431
SELECT ALL - col1 + + col1 DIV col0 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-8431
SELECT ALL - col1 + + col1 / col0 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT ALL + + col0 + - col0 * col0 AS col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT + col0 * - col2 + col1 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8434
SELECT DISTINCT - col1 DIV + col1 + col0 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-8434
SELECT DISTINCT - col1 / + col1 + col0 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT ALL - - col0 * + col1 AS col1 FROM tab0 cor0
----
2064
3395
8099

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE col0 <= NULL
----

query I rowsort
SELECT DISTINCT cor0.col2 + cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8438
SELECT DISTINCT col0 * cor0.col0 DIV - col2 FROM tab0 AS cor0
----
-1225
-17
-96

skipif mysql # not compatible
query I rowsort label-8438
SELECT DISTINCT col0 * cor0.col0 / - col2 FROM tab0 AS cor0
----
-1225
-17
-96

query I rowsort
SELECT ALL tab0.col0 + - col0 AS col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8440
SELECT - - col2 * col0 + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
192
2028
3002

skipif mysql # not compatible
query I rowsort label-8440
SELECT - - col2 * col0 + col2 / col0 AS col0 FROM tab2 AS cor0
----
192
2028
3002

query I rowsort
SELECT + cor0.col0 + - cor0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d924577a04b3a692cbbd2348e6f8e88f

query I rowsort
SELECT col1 + - cor0.col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT col1 * col1 + col2 AS col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + cor0.col2 * col0 + col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-8445
SELECT ALL cor0.col2 DIV col0 + col1 col1 FROM tab1 AS cor0
----
10
14
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8445
SELECT ALL cor0.col2 / col0 + col1 col1 FROM tab1 AS cor0
----
10
14
44

query I rowsort
SELECT DISTINCT + - cor0.col1 * cor0.col0 + - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT + col1 * - col2 - col2 * + col1 AS col1 FROM tab1 cor0
----
-1140
-2496
-2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-8448
SELECT ALL col1 * cor0.col0 + col0 DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-8448
SELECT ALL col1 * cor0.col0 + col0 / cor0.col0 AS col0 FROM tab0 AS cor0
----
2065
3396
8100

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 * col0 col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL col0 + + col2 - - tab2.col2 * tab2.col2 AS col2 FROM tab2
----
1561
763
780

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0, tab1 cor0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT ALL col1 - tab1.col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT - col0 * col2 + - tab2.col2 * + col2 FROM tab2
----
-2704
-4446
-918

query I rowsort
SELECT + col2 * col0 + col0 * - col0 * + col1 AS col2 FROM tab0
----
-118790
-48744
-713513

query I rowsort
SELECT ALL - 42 + + col2 FROM tab1
----
12
15
54

query I rowsort
SELECT ALL 38 * col2 + + tab1.col1 FROM tab1
----
2078
2176
3661

query I rowsort
SELECT + - col2 * col1 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-8458
SELECT ALL col0 + col2 DIV + 85 col1 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8458
SELECT ALL col0 + col2 / + 85 col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col0 * col1 + - col1 * - col0 - col1 AS col1 FROM tab1 cor0
----
1270
130
2067

query I rowsort
SELECT - col0 + 65 * col1 FROM tab0 AS cor0
----
5566
5826
6270

query I rowsort
SELECT - col2 * 56 AS col1 FROM tab2 cor0
----
-1456
-1512
-2128

query I rowsort
SELECT DISTINCT + cor0.col0 - col2 AS col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT + - col0 + + ( + col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL col0 + + col0 * - col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT + col2 * + col0 + - col2 + tab0.col1 FROM tab0
----
131
7307
845

query I rowsort
SELECT ALL - 33 * + col2 AS col0 FROM tab1 cor0
----
-1782
-1881
-3168

query I rowsort
SELECT ALL - tab1.col1 * + tab1.col1 + tab1.col2 FROM tab1
----
-43
-622
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8468
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab0, tab1, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8468
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab0, tab1, tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8469
SELECT - CAST( - col1 AS SIGNED ) + col1 * - 3 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-8469
SELECT - CAST ( - col1 AS INTEGER ) + col1 * - 3 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + ( 20 ) AS col1 FROM tab1 AS cor0
----
20

query I rowsort
SELECT ALL 71 * 96 AS col2 FROM tab2 AS cor0
----
6816
6816
6816

query I rowsort
SELECT DISTINCT 90 FROM tab1, tab2 cor0
----
90

query I rowsort
SELECT - 25 * + ( col2 ) FROM tab2 AS cor0
----
-650
-675
-950

onlyif mysql # use DIV operator for integer division
query I rowsort label-8474
SELECT + col0 + + 15 DIV - col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8474
SELECT + col0 + + 15 / - col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL col2 + col1 * - ( - cor0.col2 ) FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8476
SELECT DISTINCT + + col1 DIV + col0 AS col2 FROM tab1 cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-8476
SELECT DISTINCT + + col1 / + col0 AS col2 FROM tab1 cor0
----
0
8

query I rowsort
SELECT + - col2 - col0 * + 79 FROM tab1 AS cor0
----
-291
-5113
-6416

query I rowsort
SELECT ALL col2 * col0 + 16 - col1 * + col0 FROM tab1 AS cor0
----
100
3024
6656

query I rowsort
SELECT DISTINCT - 33 + col1 * + ( + col2 ) FROM tab0 AS cor0
----
2805
64
7429

query I rowsort
SELECT ALL - - col1 + col0 - + col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + 61 * + col0 * - col1 + - 44 FROM tab1 AS cor0
----
-39084
-4802
-63484

onlyif mysql # use DIV operator for integer division
query I rowsort label-8482
SELECT ALL + + 45 * col1 DIV + col0 - + ( col2 * col0 + cor0.col0 ) AS col2 FROM tab1 cor0
----
-3705
-7753
225

skipif mysql # not compatible
query I rowsort label-8482
SELECT ALL + + 45 * col1 / + col0 - + ( col2 * col0 + cor0.col0 ) AS col2 FROM tab1 cor0
----
-3705
-7753
225

query I rowsort
SELECT DISTINCT + - cor0.col2 * col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - ( col0 ) * - cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8485
SELECT - 86 * 20 * - col0 + CAST( - 80 AS SIGNED ) + + col1 FROM tab2
----
11991
134139
135817

skipif mysql # not compatible
query I rowsort label-8485
SELECT - 86 * 20 * - col0 + CAST ( - 80 AS INTEGER ) + + col1 FROM tab2
----
11991
134139
135817

query I rowsort
SELECT ALL - col2 - col2 AS col2 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT - - ( col2 ) * - 27 + col2 + col2 AS col0 FROM tab2 AS cor0
----
-650
-675
-950

query I rowsort
SELECT + + col1 * - col1 + col0 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8489
SELECT + 94 DIV + col1 + col1 + - col0 AS col0 FROM tab1 AS cor0
----
-45
-60
26

skipif mysql # not compatible
query I rowsort label-8489
SELECT + 94 / + col1 + col1 + - col0 AS col0 FROM tab1 AS cor0
----
-45
-60
26

query I rowsort
SELECT ALL ( - tab2.col1 ) * + tab2.col0 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + - col2 col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - 7 + col2 AS col2 FROM tab0
----
-6
26
75

query I rowsort
SELECT + + 66 FROM tab1, tab2 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT + col2 + col2 * + col0 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + 49 * - col0 FROM tab0
----
-1176
-1715
-4361

query I rowsort
SELECT ALL col1 + tab1.col0 + + col2 FROM tab1
----
131
189
83

query I rowsort
SELECT DISTINCT - col0 * - tab2.col2 + + col2 * col0 FROM tab2
----
378
4056
6004

skipif mysql # not compatible
query I rowsort
SELECT col2 + - CAST ( ( col2 ) * - cor0.col0 AS REAL ) FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - tab1.col2 + cor0.col1 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to f9d0c27eccc053036cbf8c101ce0fcd7

query I rowsort
SELECT 93 AS col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8501
SELECT - 72 DIV col0 AS col2 FROM tab0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-8501
SELECT - 72 / col0 AS col2 FROM tab0
----
-2
-3
0

query I rowsort
SELECT DISTINCT ( col1 ) * col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT 76 + + col2 AS col2 FROM tab1
----
130
133
172

query I rowsort
SELECT col1 * + tab0.col2 * + col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT + 59 * ( - cor0.col1 ) AS col0 FROM tab0 cor0
----
-5074
-5369
-5723

query I rowsort
SELECT DISTINCT 33 AS col0 FROM tab2 cor0
----
33

query I rowsort
SELECT + col2 + tab2.col2 AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL col0 - - cor0.col2 AS col0 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - ( col2 ) * col2 AS col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 48 * col1 AS col0 FROM tab2 AS cor0
----
1488
2832
816

query I rowsort
SELECT ALL - 20 + + col0 AS col0 FROM tab2 AS cor0
----
-13
58
59

query I rowsort
SELECT + + 71 * + 72 AS col1 FROM tab0 AS cor0
----
5112
5112
5112

query I rowsort
SELECT ALL + 61 * - col1 - - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1020
-1860
-3540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT - 0 + 6 * col1 + 86 FROM tab1 AS cor0
----
146
164
242

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col0 + - col1 * + col1 col2 FROM tab2 AS cor0
----
-1150
-3291
-5509

query I rowsort
SELECT - - 33 + - col1 AS col1 FROM tab2 AS cor0
----
-26
16
2

query I rowsort
SELECT - col0 * - col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8519
SELECT ALL CAST( + ( cor0.col1 ) AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-8519
SELECT ALL CAST ( + ( cor0.col1 ) AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) * + col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ( 52 ) + + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1300
1456
622

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + col2 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + - 76 * 53 + - col0 FROM tab0 AS cor0
----
-4052
-4063
-4117

query I rowsort
SELECT ALL col1 * - 55 AS col1 FROM tab2
----
-1705
-3245
-935

query I rowsort
SELECT ALL - col2 * - 9 * + col2 AS col1 FROM tab1
----
26244
29241
82944

query I rowsort
SELECT ALL + 1 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 9 * - col2 AS col2 FROM tab2 AS cor0
----
-234
-243
-342

onlyif mysql # use DIV operator for integer division
query I rowsort label-8528
SELECT DISTINCT + col2 + - col0 + tab0.col0 DIV + col0 FROM tab0
----
-33
-6
10

skipif mysql # not compatible
query I rowsort label-8528
SELECT DISTINCT + col2 + - col0 + tab0.col0 / + col0 FROM tab0
----
-33
-6
10

query I rowsort
SELECT - ( col0 ) + col2 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT 87 - + col2 FROM tab0
----
5
54
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 * + 84 + + col1 col0 FROM tab2
----
4217
4231
4259

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col0 + col0 col2 FROM tab2
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 + + col2 col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL - col0 + ( col0 ) * - col2 AS col1 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT - cor0.col1 + - col0 * col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL + col0 * 50 + + col0 FROM tab0 AS cor0
----
1224
1785
4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-8537
SELECT - cor0.col2 DIV + ( - 93 ) + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8537
SELECT - cor0.col2 / + ( - 93 ) + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col1 + + 36 FROM tab0 AS cor0
----
-50
-55
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + col0 * col2 col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - col2 + 93 AS col2 FROM tab1 AS cor0
----
-3
36
39

query I rowsort
SELECT DISTINCT col2 + 68 * 82 FROM tab0 AS cor0
----
5577
5609
5658

query I rowsort
SELECT + 88 * + col2 AS col2 FROM tab2
----
2288
2376
3344

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 17 col1 FROM tab2
----
17

query I rowsort
SELECT - 47 * col1 AS col1 FROM tab0
----
-4042
-4277
-4559

query I rowsort
SELECT + col2 - cor0.col0 * - col1 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - col0 * - col0 + - col1 AS col2 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT + - col1 * 4 FROM tab2 AS cor0
----
-124
-236
-68

query I rowsort
SELECT DISTINCT + col2 + - 30 AS col2 FROM tab2
----
-3
-4
8

query I rowsort
SELECT DISTINCT + tab1.col2 - ( - tab1.col2 ) FROM tab1
----
108
114
192

query I rowsort
SELECT ALL 95 * - 44 FROM tab2, tab1 AS cor0
----
9 values hashing to e60cc21ca5dba0ded13fcc241c1e9539

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + ( col0 ) * col2 + ( + col1 ) col2 FROM tab0
----
-26050
-598345
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8552
SELECT - col1 DIV col1 - + col0 DIV 86 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-8552
SELECT - col1 / col1 - + col0 / 86 col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col1 * 98 FROM tab0 AS cor0
----
8428
8918
9506

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 ALL + col2 * tab0.col1 + tab0.col0 + col0 AS col0 FROM tab0
----
167
2886
7640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8556
SELECT - col0 * - CAST( NULL AS DECIMAL ) + 79 + col2 / col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8556
SELECT - col0 * - CAST ( NULL AS REAL ) + 79 + col2 / col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 68 * tab0.col0 AS col1 FROM tab0
----
1632
2380
6052

query I rowsort
SELECT + + col2 + + 35 FROM tab0 AS cor0
----
117
36
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8559
SELECT ALL + - CAST( - col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8559
SELECT ALL + - CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col0 * col0 * col1 + cor0.col2 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
118922
52374
728273

onlyif mysql # use DIV operator for integer division
query I rowsort label-8561
SELECT 26 DIV - col2 - - col1 AS col1 FROM tab0 AS cor0
----
71
86
91

skipif mysql # not compatible
query I rowsort label-8561
SELECT 26 / - col2 - - col1 AS col1 FROM tab0 AS cor0
----
71
86
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-8562
SELECT ALL + col2 DIV + col0 + + col2 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-8562
SELECT ALL + col2 / + col0 + + col2 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT ALL ( col1 ) + col1 + - col1 AS col0 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8564
SELECT DISTINCT - + ( 25 ) * col1 * CAST( NULL AS DECIMAL ) - + cor0.col1 * col2 col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8564
SELECT DISTINCT - + ( 25 ) * col1 * CAST ( NULL AS REAL ) - + cor0.col1 * col2 col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col0 * - col1 + col1 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + col2 + 36 * col2 AS col2 FROM tab2 AS cor0
----
1406
962
999

onlyif mysql # use DIV operator for integer division
query I rowsort label-8567
SELECT DISTINCT + col2 DIV 6 + col2 * col1 + + col2 FROM tab1 AS cor0
----
1360
1467
636

skipif mysql # not compatible
query I rowsort label-8567
SELECT DISTINCT + col2 / 6 + col2 * col1 + + col2 FROM tab1 AS cor0
----
1360
1467
636

query I rowsort
SELECT ALL + 39 * + col2 + col2 AS col1 FROM tab2 AS cor0
----
1040
1080
1520

query I rowsort
SELECT ALL + + col0 * + 91 - + cor0.col0 * 79 * ( + col2 ) AS col1 FROM tab0 AS cor0
----
-568443
-60384
420

query I rowsort
SELECT ALL + + col1 + ( + col0 ) AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + col2 + + 94 AS col0 FROM tab1 AS cor0
----
148
151
190

query I rowsort
SELECT DISTINCT - 28 AS col1 FROM tab0 AS cor0
----
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-8573
SELECT - 28 DIV - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8573
SELECT - 28 / - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * - col0 + + col1 + - col0 FROM tab1 AS cor0
----
-139
-3702
-7747

query I rowsort
SELECT ALL - col0 * + col2 + ( - 50 ) FROM tab1 AS cor0
----
-212
-3698
-7730

query I rowsort
SELECT - 97 * + cor0.col1 FROM tab1 AS cor0
----
-1261
-2522
-970

query I rowsort
SELECT DISTINCT + - col0 * + col1 + - ( - col2 ) FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - cor0.col1 + ( ( - cor0.col0 ) ) AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - col2 + + ( col1 ) FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL + - col2 * 97 + col0 FROM tab1 AS cor0
----
-5235
-5465
-9232

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab0, tab1 AS cor0, tab2, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT + col0 * - 65 FROM tab0 AS cor0
----
-1560
-2275
-5785

query I rowsort
SELECT - col1 + - col0 * 0 - - 55 * col0 AS col2 FROM tab0 AS cor0
----
1234
1828
4804

query I rowsort
SELECT DISTINCT + + 1 FROM tab1 cor0
----
1

query I rowsort
SELECT DISTINCT + col1 * + col0 * + col2 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - + 21 + - col0 * - ( 35 ) FROM tab1 AS cor0
----
2219
2779
84

query I rowsort
SELECT + col0 - + col2 * col0 AS col1 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-8588
SELECT - col1 * - cor0.col0 - - 25 DIV - col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8588
SELECT - col1 * - cor0.col0 - - 25 / - col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 61 * col1 + col0 FROM tab1
----
1589
674
873

query I rowsort
SELECT DISTINCT col2 * col2 + + col2 * - col2 AS col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8591
SELECT ALL + - col0 + + col2 + + ( + col2 ) DIV cor0.col0 col2 FROM tab2 AS cor0
----
-41
-52
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8591
SELECT ALL + - col0 + + col2 + + ( + col2 ) / cor0.col0 col2 FROM tab2 AS cor0
----
-41
-52
23

query I rowsort
SELECT - 56 + col2 * col2 FROM tab1 AS cor0
----
2860
3193
9160

query I rowsort
SELECT ALL cor0.col1 * + 37 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 6e2d8808bd4257c36cb5fc1462c54827

query I rowsort
SELECT ALL - 90 FROM tab0, tab0 cor0
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

query I rowsort
SELECT cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1, tab2 AS cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ( 53 ) * - cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 cor1
----
27 values hashing to 98a62cde9cb036e44071d6c8a6c7e298

query I rowsort
SELECT tab0.col1 + + ( - 45 ) FROM tab0
----
41
46
52

query I rowsort
SELECT + ( - 96 ) AS col1 FROM tab0
----
-96
-96
-96

query I rowsort
SELECT DISTINCT 38 * + 74 FROM tab1 AS cor0
----
2812

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-8601
SELECT ALL - - CAST( col2 AS SIGNED ) + + col2 AS col2 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-8601
SELECT ALL - - CAST ( col2 AS INTEGER ) + + col2 AS col2 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 35 + col0 * - col2 + col1 col2 FROM tab0 AS cor0
----
-7242
-741
27

query I rowsort
SELECT DISTINCT - + 97 AS col1 FROM tab2 AS cor0
----
-97

query I rowsort
SELECT ALL - + ( col0 ) * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL + 60 * - cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 79797e21724f4ae282860134cc7669df

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8606
SELECT + CAST( 32 AS SIGNED ) FROM tab0
----
32
32
32

skipif mysql # not compatible
query I rowsort label-8606
SELECT + CAST ( 32 AS INTEGER ) FROM tab0
----
32
32
32

query I rowsort
SELECT + 19 + - cor0.col1 FROM tab2 AS cor0
----
-12
-40
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * cor0.col2 col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 29 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

onlyif mysql # use DIV operator for integer division
query I rowsort label-8610
SELECT - col1 DIV tab0.col2 AS col1 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-8610
SELECT - col1 / tab0.col2 AS col1 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT + - col0 + col0 * + ( + 35 ) * col2 FROM tab2 AS cor0
----
104991
6608
70902

query I rowsort
SELECT col1 * - cor0.col1 * col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-8613
SELECT ALL col2 DIV col2 col2 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8613
SELECT ALL col2 / col2 col2 FROM tab1
----
1
1
1

query I rowsort
SELECT - col2 + ( col0 ) * col2 * col1 AS col2 FROM tab1 cor0
----
36423
4158
99744

query I rowsort
SELECT + col1 * - col0 * cor0.col2 + col1 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT - 57 * + cor0.col1 AS col0 FROM tab2 cor0
----
-1767
-3363
-969

query I rowsort
SELECT - - col2 * col2 * + col2 AS col1 FROM tab2 AS cor0
----
17576
19683
54872

query I rowsort
SELECT + 60 * col1 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT ALL - col1 * + ( 9 * + col2 ) AS col0 FROM tab2
----
-13806
-5814
-7533

query I rowsort
SELECT DISTINCT + 43 FROM tab1, tab2 cor0
----
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col1 col2 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - col2 * - ( + col1 ) * col0 FROM tab0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-8623
SELECT + 18 - - col1 DIV ( + col1 ) AS col2 FROM tab1
----
19
19
19

skipif mysql # not compatible
query I rowsort label-8623
SELECT + 18 - - col1 / ( + col1 ) AS col2 FROM tab1
----
19
19
19

query I rowsort
SELECT ALL col1 + col1 * col2 + - col0 AS col0 FROM tab1
----
1181
1427
516

query I rowsort
SELECT ALL - col2 * col1 + col1 + - col2 AS col2 FROM tab1
----
-1331
-1432
-617

query I rowsort
SELECT - ( col2 ) + col0 + col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - 27 + col2 * col1 FROM tab1 AS cor0
----
1221
1377
543

onlyif mysql # use DIV operator for integer division
query I rowsort label-8628
SELECT ALL - - 71 DIV + cor0.col1 + + ( + col1 ) + col1 FROM tab1 AS cor0
----
27
31
54

skipif mysql # not compatible
query I rowsort label-8628
SELECT ALL - - 71 / + cor0.col1 + + ( + col1 ) + col1 FROM tab1 AS cor0
----
27
31
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8629
SELECT - col1 * col1 + CAST( NULL AS SIGNED ) 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-8629
SELECT - col1 * col1 + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8630
SELECT DISTINCT - col1 + - col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-8630
SELECT DISTINCT - col1 + - col0 / col0 AS col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT + col0 * + ( col2 ) AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + cor0.col0 * col2 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + - col1 * - col0 + 20 * cor0.col2 AS col1 FROM tab2 cor0
----
2103
5122
757

query I rowsort
SELECT DISTINCT - cor0.col0 * + col2 + - col1 * - col1 AS col0 FROM tab0 AS cor0
----
6604
9374
983

query I rowsort
SELECT DISTINCT + col0 - + col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT ALL - col0 * 57 - col0 AS col1 FROM tab2 AS cor0
----
-406
-4524
-4582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 55 * col2 col0 FROM tab2
----
1430
1485
2090

onlyif mysql # use DIV operator for integer division
query I rowsort label-8638
SELECT ALL 55 DIV - col0 AS col0 FROM tab2
----
-7
0
0

skipif mysql # not compatible
query I rowsort label-8638
SELECT ALL 55 / - col0 AS col0 FROM tab2
----
-7
0
0

query I rowsort
SELECT - tab2.col2 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 49 col0 FROM tab1 AS cor0
----
113
129
52

query I rowsort
SELECT DISTINCT - col2 + col1 * 66 FROM tab0 AS cor0
----
5643
5924
6401

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8642
SELECT CAST( NULL AS SIGNED ) * ( - col2 ) + col0 * + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8642
SELECT CAST ( NULL AS INTEGER ) * ( - col2 ) + col0 * + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 29 * 68 AS col2 FROM tab1 AS cor0
----
-1972
-1972
-1972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 92 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ALL - ( 7 ) * col1 FROM tab2 AS cor0
----
-119
-217
-413

query I rowsort
SELECT DISTINCT + ( - 59 ) + - col2 FROM tab0 cor0
----
-141
-60
-92

query I rowsort
SELECT + 14 * - col2 + col1 * - col0 AS col0 FROM tab1 cor0
----
-1438
-2384
-834

query I rowsort
SELECT - 4 FROM tab0, tab2 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) * - 70 * + cor0.col0 + col2 + 93 * 88 * col2 col0 FROM tab0 AS cor0
----
-229465
104240
125625

query I rowsort
SELECT ALL - + col2 * col1 * - ( - col0 + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-29146
-40052
20088

onlyif mysql # use DIV operator for integer division
query I rowsort label-8651
SELECT ALL + + col1 DIV col0 + col0 AS col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-8651
SELECT ALL + + col1 / col0 + col0 AS col0 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT DISTINCT - + col0 * - col1 + col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-8653
SELECT ALL - col2 * col1 + + col0 + - col1 DIV - col0 FROM tab0 AS cor0
----
-2811
-60
-7372

skipif mysql # not compatible
query I rowsort label-8653
SELECT ALL - col2 * col1 + + col0 + - col1 / - col0 FROM tab0 AS cor0
----
-2811
-60
-7372

query I rowsort
SELECT - ( + col0 + col1 ) AS col1 FROM tab2
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col2 ) * - col0 * 14 + + cor0.col1 * - col2 * + 21 col2 FROM tab1 AS cor0
----
-133728
-31752
-63042

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 * - col2 + + cor0.col1 * + 2 col2 FROM tab0 AS cor0
----
-2039
-5312
127

query I rowsort
SELECT DISTINCT - + col2 + col0 + + col1 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT DISTINCT + cor0.col0 * - col2 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8659
SELECT DISTINCT CAST( + ( col1 ) AS SIGNED ) AS col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-8659
SELECT DISTINCT CAST ( + ( col1 ) AS INTEGER ) AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT 77 + - col1 FROM tab0
----
-14
-20
-9

query I rowsort
SELECT DISTINCT tab2.col2 - - col2 * tab2.col2 AS col1 FROM tab2
----
1482
702
756

query I rowsort
SELECT col0 + - col0 + + ( 23 ) FROM tab1
----
23
23
23

query I rowsort
SELECT DISTINCT - col2 + - col2 * ( col0 + col0 ) * 66 FROM tab0 AS cor0
----
-104577
-4621
-963418

onlyif mysql # use DIV operator for integer division
query I rowsort label-8664
SELECT ALL - - col0 DIV col1 + col1 * col2 * col2 - col0 AS col2 FROM tab0 cor0
----
611795
62
93630

skipif mysql # not compatible
query I rowsort label-8664
SELECT ALL - - col0 / col1 + col1 * col2 * col2 - col0 AS col2 FROM tab0 cor0
----
611795
62
93630

query I rowsort
SELECT ALL - - col0 * col0 - - col1 AS col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT col0 * col1 + 46 FROM tab2 AS cor0
----
1389
263
4648

query I rowsort
SELECT DISTINCT 93 AS col2 FROM tab0 AS cor0
----
93

query I rowsort
SELECT DISTINCT - col1 + col1 * + 16 FROM tab0 AS cor0
----
1290
1365
1455

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8669
SELECT DISTINCT - cor0.col2 * + col2 + - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8669
SELECT DISTINCT - cor0.col2 * + col2 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 92 col1 FROM tab1
----
102
105
118

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8671
SELECT DISTINCT + CAST( + 75 AS SIGNED ) + + col0 FROM tab2 cor0
----
153
154
82

skipif mysql # not compatible
query I rowsort label-8671
SELECT DISTINCT + CAST ( + 75 AS INTEGER ) + + col0 FROM tab2 cor0
----
153
154
82

query I rowsort
SELECT - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # use DIV operator for integer division
query I rowsort label-8673
SELECT col1 DIV 82 - + 85 AS col2 FROM tab2
----
-85
-85
-85

skipif mysql # not compatible
query I rowsort label-8673
SELECT col1 / 82 - + 85 AS col2 FROM tab2
----
-85
-85
-85

query I rowsort
SELECT ALL + + ( ( col0 ) ) - + col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 * + 70 FROM tab2 AS cor0
----
1190
2170
4130

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8676
SELECT DISTINCT + + CAST( cor0.col0 AS SIGNED ) * + col0 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-8676
SELECT DISTINCT + + CAST ( cor0.col0 AS INTEGER ) * + col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL + ( + 24 ) FROM tab0 AS cor0
----
24
24
24

query I rowsort
SELECT - ( - col1 ) * col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col1 * + ( cor0.col0 ) * + ( 7 + col1 ) FROM tab2 AS cor0
----
-303732
-32232
-8246

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 12 * col0 - - col0 * - col2 col2 FROM tab0 cor0
----
-504
-6230
385

query I rowsort
SELECT cor0.col1 * ( 89 ) FROM tab1 AS cor0
----
1157
2314
890

onlyif mysql # use DIV operator for integer division
query I rowsort label-8682
SELECT + col0 DIV 73 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8682
SELECT + col0 / 73 AS col2 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8683
SELECT ALL col1 DIV + cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-8683
SELECT ALL col1 / + cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT ALL - - cor0.col0 + - col2 + + cor0.col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + ( - col1 ) + col1 * - 34 AS col1 FROM tab1 AS cor0
----
-330
-429
-858

query I rowsort
SELECT DISTINCT 86 FROM tab2, tab0 AS cor0
----
86

query I rowsort
SELECT DISTINCT + col0 + + 85 * ( col2 ) + col1 FROM tab0
----
217
2915
7150

query I rowsort
SELECT 62 * 80 FROM tab0, tab1 cor0
----
9 values hashing to a849020558d2bbe86eaaa132859ff4ba

query I rowsort
SELECT col1 + + col1 + + col2 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT + 5 + col2 AS col0 FROM tab0 AS cor0
----
38
6
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 74 col2 FROM tab1 AS cor0
----
74

query I rowsort
SELECT - 43 FROM tab0, tab1 cor0 CROSS JOIN tab2
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT 33 + - tab1.col0 FROM tab1
----
-31
-47
30

query I rowsort
SELECT - col2 + - col0 * col1 FROM tab1
----
-1136
-132
-697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8695
SELECT 21 + col1 * + CAST( NULL AS SIGNED ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8695
SELECT 21 + col1 * + CAST ( NULL AS INTEGER ) col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8696
SELECT DISTINCT col2 * col2 DIV col2 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8696
SELECT DISTINCT col2 * col2 / col2 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL 45 * - col1 FROM tab1
----
-1170
-450
-585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 66 col0 FROM tab1 cor0
----
120
123
162

query I rowsort
SELECT col2 * + col0 + + 3 AS col1 FROM tab0
----
38
7301
795

query I rowsort
SELECT + col0 * col2 + + col1 * + col2 FROM tab1
----
1566
4218
8928

query I rowsort
SELECT + ( col0 + + tab1.col1 * + 45 ) FROM tab1
----
1173
514
665

query I rowsort
SELECT ALL 4 * - col1 FROM tab0
----
-344
-364
-388

query I rowsort
SELECT ALL + - col2 + col1 * - 49 + - col0 AS col0 FROM tab0 cor0
----
-4271
-4630
-4789

query I rowsort
SELECT DISTINCT + col0 + - col0 * + 91 * - cor0.col1 - col1 FROM tab0 AS cor0
----
187762
308883
737007

query I rowsort
SELECT ALL 8 - + tab2.col0 AS col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 577303a5f1a0c74430d40a46ff5be1f6

query I rowsort
SELECT cor0.col1 * + 14 AS col0 FROM tab0 AS cor0
----
1204
1274
1358

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8707
SELECT ALL - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8707
SELECT ALL - CAST ( NULL AS REAL ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col0 * + cor0.col2 * + col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + 11 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8710
SELECT ALL - CAST( NULL AS DECIMAL ) * 64 * cor0.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8710
SELECT ALL - CAST ( NULL AS REAL ) * 64 * cor0.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + 41 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT DISTINCT 28 + 72 FROM tab0, tab0 AS cor0
----
100

query I rowsort
SELECT ALL col1 * + col0 * col2 FROM tab0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 21 col1 FROM tab0
----
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8715
SELECT + col1 DIV + ( + col1 ) AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8715
SELECT + col1 / + ( + col1 ) AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT ALL 14 + - 20 FROM tab2
----
-6
-6
-6

query I rowsort
SELECT ALL 24 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

onlyif mysql # use DIV operator for integer division
query I rowsort label-8718
SELECT DISTINCT col0 * - col2 + - col0 DIV col0 + col0 DIV col0 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-8718
SELECT DISTINCT col0 * - col2 + - col0 / col0 + col0 / col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ( col0 ) * col2 * ( col0 ) AS col1 FROM tab1
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-8720
SELECT + col1 DIV 31 FROM tab0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-8720
SELECT + col1 / 31 FROM tab0
----
2
2
3

query I rowsort
SELECT - ( col1 + col1 ) * col0 * col1 FROM tab2
----
-13454
-45662
-543036

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col2 AS REAL ) * - col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT col2 + + 24 FROM tab1 AS cor0
----
120
78
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 col1 FROM tab0 cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-8725
SELECT 94 + col2 DIV col2 + col2 * cor0.col0 FROM tab0 AS cor0
----
130
7393
887

skipif mysql # not compatible
query I rowsort label-8725
SELECT 94 + col2 / col2 + col2 * cor0.col0 FROM tab0 AS cor0
----
130
7393
887

query I rowsort
SELECT + + col2 + col0 * 41 AS col0 FROM tab0 AS cor0
----
1017
1436
3731

query I rowsort
SELECT + 8 * + col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT - + 13 + + col1 AS col2 FROM tab2 AS cor0
----
18
4
46

query I rowsort
SELECT + ( + col0 ) + - col0 * col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - 90 * 78 + col1 FROM tab2 AS cor0
----
-6961
-6989
-7003

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8731
SELECT ALL + CAST( NULL AS SIGNED ) * col2 - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8731
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8732
SELECT 24 DIV cor0.col1 + col0 FROM tab1 AS cor0
----
3
66
81

skipif mysql # not compatible
query I rowsort label-8732
SELECT 24 / cor0.col1 + col0 FROM tab1 AS cor0
----
3
66
81

query I rowsort
SELECT ALL + 76 + 20 FROM tab1 cor0
----
96
96
96

query I rowsort
SELECT cor1.col1 * cor0.col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 5ea193ba73427313aa6d66d856b32bc7

query I rowsort
SELECT ALL - ( - 17 ) * + col2 - col0 AS col1 FROM tab0 AS cor0
----
-18
1305
537

query I rowsort
SELECT ALL + ( + 40 ) AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT col2 + col2 + col0 AS col1 FROM tab0
----
253
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8738
SELECT col1 DIV + col1 + col2 DIV - col1 + col1 * - col1 AS col0 FROM tab0
----
-7395
-8280
-9408

skipif mysql # not compatible
query I rowsort label-8738
SELECT col1 / + col1 + col2 / - col1 + col1 * - col1 AS col0 FROM tab0
----
-7395
-8280
-9408

query I rowsort
SELECT + - 4 * - 15 FROM tab1 AS cor0
----
60
60
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 93 + col1 col2 FROM tab1
----
103
106
119

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 + + 47 col1 FROM tab0
----
133
138
144

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8742
SELECT ALL CAST( NULL AS SIGNED ) * col0 * tab0.col2 + col1 + col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8742
SELECT ALL CAST ( NULL AS INTEGER ) * col0 * tab0.col2 + col1 + col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 60 + col0 FROM tab1
----
-57
20
4

query I rowsort
SELECT - + col0 + + 83 AS col2 FROM tab1 AS cor0
----
19
3
80

query I rowsort
SELECT ALL - + col1 * + col0 + + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-8746
SELECT DISTINCT - col0 + - 74 DIV + col0 AS col1 FROM tab2 AS cor0
----
-17
-78
-79

skipif mysql # not compatible
query I rowsort label-8746
SELECT DISTINCT - col0 + - 74 / + col0 AS col1 FROM tab2 AS cor0
----
-17
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8747
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + - col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8747
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + - col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + 46 ) + col0 col0 FROM tab0 AS cor0
----
-11
-22
43

query I rowsort
SELECT + col2 * - 72 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT ALL + cor0.col2 + cor0.col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col0 * col2 + - col2 AS col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT - col0 - - col2 AS col0 FROM tab2
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-8753
SELECT col1 * col0 + cor0.col0 DIV + 95 AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-8753
SELECT col1 * col0 + cor0.col0 / + 95 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - - col1 + ( - col1 ) * col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - col1 + - col0 * cor0.col1 - col1 FROM tab1 AS cor0
----
-1066
-130
-660

skipif mysql # not compatible
query I rowsort
SELECT + cor0.col1 + CAST ( col1 AS REAL ) * col2 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT col2 * + col1 * - col2 - - col1 AS col2 FROM tab0 AS cor0
----
-611793
-93568
0

query I rowsort
SELECT ALL - col2 + col0 * - 34 AS col1 FROM tab0 AS cor0
----
-1191
-3108
-849

query I rowsort
SELECT DISTINCT + col2 * 44 + + col2 FROM tab1 cor0
----
2430
2565
4320

query I rowsort
SELECT DISTINCT + col1 - - col0 AS col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-8761
SELECT DISTINCT - col2 DIV - 32 - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-77

skipif mysql # not compatible
query I rowsort label-8761
SELECT DISTINCT - col2 / - 32 - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-77

query I rowsort
SELECT - + cor0.col2 * - col1 AS col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8763
SELECT ALL + col0 + - ( cor0.col1 ) + cor0.col1 DIV - col2 col1 FROM tab0 AS cor0
----
-159
-3
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8763
SELECT ALL + col0 + - ( cor0.col1 ) + cor0.col1 / - col2 col1 FROM tab0 AS cor0
----
-159
-3
-64

query I rowsort
SELECT + col0 + - col2 * - cor0.col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
35961
36
551457

query I rowsort
SELECT + cor0.col1 * - col1 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-306
-3540
-992

onlyif mysql # use DIV operator for integer division
query I rowsort label-8766
SELECT ALL col0 * col1 + col1 DIV cor0.col0 FROM tab2 AS cor0
----
1343
221
4602

skipif mysql # not compatible
query I rowsort label-8766
SELECT ALL col0 * col1 + col1 / cor0.col0 FROM tab2 AS cor0
----
1343
221
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8767
SELECT ALL + cor0.col0 DIV - col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8767
SELECT ALL + cor0.col0 / - col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col0 * + col1 col2 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col1 + - col0 * cor0.col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - col2 * - tab2.col0 AS col2 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col1 * col1 * + col1 col2 FROM tab0
----
635970
753480
912576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col0 * col0 col0 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT col1 * - tab1.col0 * + col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT - col0 * + col2 * col2 + + col1 * + col1 AS col0 FROM tab0
----
-18740
-590155
9374

query I rowsort
SELECT DISTINCT - + col1 + - col1 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT - - ( cor0.col1 ) + - cor0.col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col0 * col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL + cor0.col1 * col0 + col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 + - cor0.col1 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT - col0 + col1 * col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT + ( + cor0.col1 ) AS col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL 62 + + col1 FROM tab1 AS cor0
----
72
75
88

query I rowsort
SELECT DISTINCT + col0 * + col2 - col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT ALL - ( - col1 ) + + col1 * col1 FROM tab2
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-8785
SELECT + col2 + col1 DIV col0 col1 FROM tab1 cor0
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8785
SELECT + col2 + col1 / col0 col1 FROM tab1 cor0
----
57
62
96

query I rowsort
SELECT + + col1 * + col0 * - col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL - - 72 + col0 AS col0 FROM tab2 AS cor0
----
150
151
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8788
SELECT - + 23 DIV col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-8788
SELECT - + 23 / col0 FROM tab2 AS cor0
----
-3
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8789
SELECT + CAST( NULL AS DECIMAL ) * col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8789
SELECT + CAST ( NULL AS REAL ) * col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8790
SELECT - col0 + + col2 DIV tab2.col1 AS col1 FROM tab2
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-8790
SELECT - col0 + + col2 / tab2.col1 AS col1 FROM tab2
----
-7
-77
-78

query I rowsort
SELECT ALL - 12 + + col2 AS col1 FROM tab1
----
42
45
84

query I rowsort
SELECT col1 - col2 * tab2.col0 * + col2 AS col2 FROM tab2
----
-114059
-5072
-52669

query I rowsort
SELECT ALL + tab1.col1 + - col2 * - col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL + 1 * - col0 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - ( - 8 + - col2 ) FROM tab1
----
104
62
65

query I rowsort
SELECT ALL - 37 * cor0.col0 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 18e1c16f34b065c346c709036657e3c1

query I rowsort
SELECT - 22 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

query I rowsort
SELECT + col1 * + col0 * col2 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-8799
SELECT DISTINCT cor0.col1 DIV - ( - col0 ) AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8799
SELECT DISTINCT cor0.col1 / - ( - col0 ) AS col1 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8800
SELECT ALL col1 * - CAST( + 64 AS SIGNED ) FROM tab0
----
-5504
-5824
-6208

skipif mysql # not compatible
query I rowsort label-8800
SELECT ALL col1 * - CAST ( + 64 AS INTEGER ) FROM tab0
----
-5504
-5824
-6208

query I rowsort
SELECT cor0.col1 + - col0 FROM tab0 cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 2 + col0 * col0 * - col2 col2 FROM tab2 AS cor0
----
-1337
-158340
-237316

query I rowsort
SELECT col1 + col0 * 17 FROM tab0 AS cor0
----
1604
494
692

query I rowsort
SELECT ALL + + col0 * ( + col0 ) FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT + col2 + - 3 AS col2 FROM tab2 cor0
----
23
24
35

query I rowsort
SELECT DISTINCT - col1 + col2 * + col2 AS col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT DISTINCT + col2 * col2 * + 11 FROM tab1 cor0
----
101376
32076
35739

query I rowsort
SELECT col1 * ( col1 * col2 ) + + cor0.col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
11140
25961
90662

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + + col2 * col0 col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL + 48 FROM tab2, tab2 AS cor0, tab0 cor1, tab2 AS cor2
----
81 values hashing to df6d12001a34fdcf5cfb2ca3a4a22108

query I rowsort
SELECT + col1 + cor0.col0 AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT col1 * + 3 * + col0 FROM tab0 AS cor0
----
10185
24297
6192

query I rowsort
SELECT DISTINCT + col0 + ( 38 ) FROM tab2
----
116
117
45

query I rowsort
SELECT DISTINCT + col0 * - 13 + + col2 AS col0 FROM tab1
----
-775
-944
15

query I rowsort
SELECT 26 * col0 AS col2 FROM tab1 AS cor0
----
1664
2080
78

query I rowsort
SELECT 18 + - cor0.col1 FROM tab0 cor0
----
-68
-73
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col0 AS REAL ) - - tab0.col1 * + col1 col2 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT - 68 + 96 + + col2 AS col2 FROM tab1 AS cor0
----
124
82
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 + + cor0.col2 col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT ( + ( col1 ) ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - cor0.col2 * + col1 * - col0 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 12 + col2 * 45 col0 FROM tab0 AS cor0
----
1209
2517
4782

query I rowsort
SELECT 32 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT 96 * col1 AS col1 FROM tab1 cor0
----
1248
2496
960

query I rowsort
SELECT - 50 * col0 + + col1 AS col0 FROM tab2 AS cor0
----
-319
-3841
-3933

query I rowsort
SELECT ALL - cor0.col2 - col1 * - col2 FROM tab0 AS cor0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 51 * - cor0.col0 col1 FROM tab0 AS cor0
----
-1224
-1785
-4539

query I rowsort
SELECT ALL + - 19 AS col2 FROM tab1, tab0 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 99bbabf7eff84050cf6c6974a01eb714

query I rowsort
SELECT + - 85 * + col0 AS col2 FROM tab0 AS cor0
----
-2040
-2975
-7565

query I rowsort
SELECT DISTINCT col2 + + tab0.col1 + col0 FROM tab0
----
133
143
262

query I rowsort
SELECT DISTINCT + 45 + + 27 * tab1.col2 * col0 FROM tab1
----
207405
4419
98541

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 6 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT ALL - + 62 * + cor1.col0 AS col2 FROM tab2, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 9cb63684244efb6cb337157003ce0e13

query I rowsort
SELECT cor0.col2 * cor0.col0 * - ( col1 ) AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - ( - 84 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) col1 FROM tab2, tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + + 90 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT + 61 + 8 AS col2 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT - col2 * + col0 + + col1 AS col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT tab0.col2 * + 12 AS col1 FROM tab0
----
12
396
984

onlyif mysql # use DIV operator for integer division
query I rowsort label-8841
SELECT - col0 * 14 DIV + col0 AS col0 FROM tab1
----
-14
-14
-14

skipif mysql # not compatible
query I rowsort label-8841
SELECT - col0 * 14 / + col0 AS col0 FROM tab1
----
-14
-14
-14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8842
SELECT col0 * CAST( NULL AS SIGNED ) * 26 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8842
SELECT col0 * CAST ( NULL AS INTEGER ) * 26 AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8843
SELECT - col2 * ( - ( - col0 ) ) DIV 89 AS col0 FROM tab2
----
-2
-22
-33

skipif mysql # not compatible
query I rowsort label-8843
SELECT - col2 * ( - ( - col0 ) ) / 89 AS col0 FROM tab2
----
-2
-22
-33

query I rowsort
SELECT col0 + 24 AS col1 FROM tab2 AS cor0
----
102
103
31

query I rowsort
SELECT - + cor0.col0 * + col0 + - col1 FROM tab0 cor0
----
-1322
-662
-8012

query I rowsort
SELECT - col2 * - col1 * 60 FROM tab2
----
38760
50220
92040

query I rowsort
SELECT col2 * col0 * 71 FROM tab0
----
2485
518158
56232

query I rowsort
SELECT col0 * - col2 * + cor0.col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL + + col1 + + ( - 80 ) AS col2 FROM tab1 AS cor0
----
-54
-67
-70

query I rowsort
SELECT DISTINCT cor0.col2 * + col1 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + 61 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

onlyif mysql # use DIV operator for integer division
query I rowsort label-8852
SELECT DISTINCT col2 DIV ( col1 ) AS col2 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-8852
SELECT DISTINCT col2 / ( col1 ) AS col2 FROM tab0 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8853
SELECT ALL - - CAST( - 82 AS SIGNED ) * cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31d673572b55f6f3951b4724c7fb93a0

skipif mysql # not compatible
query I rowsort label-8853
SELECT ALL - - CAST ( - 82 AS INTEGER ) * cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31d673572b55f6f3951b4724c7fb93a0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8854
SELECT col0 + - CAST( NULL AS SIGNED ) / - 2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8854
SELECT col0 + - CAST ( NULL AS INTEGER ) / - 2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8855
SELECT - col0 * 69 DIV 33 - + col2 FROM tab1
----
-190
-263
-60

skipif mysql # not compatible
query I rowsort label-8855
SELECT - col0 * 69 / 33 - + col2 FROM tab1
----
-190
-263
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 42 col2 FROM tab1, tab1 AS cor0
----
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-8857
SELECT ALL col1 DIV + 43 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-8857
SELECT ALL col1 / + 43 FROM tab0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 - - tab0.col2 col2 FROM tab0, tab2 AS cor0
----
113
162
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( - col2 ) col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 35 AS col1 FROM tab0 AS cor0
----
35

query I rowsort
SELECT - cor0.col2 * col2 + - 55 AS col0 FROM tab2 AS cor0
----
-1499
-731
-784

query I rowsort
SELECT + ( - ( + col1 ) ) * ( - col0 ) AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL ( col1 ) * col0 AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL + col0 * col0 + col1 * - ( col0 ) AS col0 FROM tab1
----
-69
3456
5360

query I rowsort
SELECT DISTINCT - col2 + - ( col2 + 84 * - col1 ) FROM tab0
----
7158
7480
8146

query I rowsort
SELECT + 60 + + col0 FROM tab1 cor0
----
124
140
63

query I rowsort
SELECT DISTINCT - 63 + cor0.col2 FROM tab2 cor0
----
-25
-36
-37

query I rowsort
SELECT ALL + 84 * col1 * col2 - + col1 FROM tab0 AS cor0
----
238306
626717
8051

onlyif mysql # use DIV operator for integer division
query I rowsort label-8869
SELECT DISTINCT - 69 DIV + col2 FROM tab1 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-8869
SELECT DISTINCT - 69 / + col2 FROM tab1 cor0
----
-1
0

query I rowsort
SELECT ALL + - ( + col0 ) + - cor0.col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + - col0 * + cor0.col1 + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT + 91 + cor0.col1 AS col2 FROM tab1 cor0
----
101
104
117

onlyif mysql # use DIV operator for integer division
query I rowsort label-8873
SELECT ALL - cor0.col0 DIV + col2 - ( cor0.col0 + col1 ) * + ( col0 ) FROM tab1 AS cor0
----
-4737
-7440
-87

skipif mysql # not compatible
query I rowsort label-8873
SELECT ALL - cor0.col0 / + col2 - ( cor0.col0 + col1 ) * + ( col0 ) FROM tab1 AS cor0
----
-4737
-7440
-87

query I rowsort
SELECT ALL col1 * + col0 * - col2 + + col0 AS col1 FROM tab0
----
-3360
-664029
-68088

query I rowsort
SELECT col0 + col1 * 78 FROM tab2
----
1405
2425
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8876
SELECT col2 DIV + col1 + + tab0.col2 AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8876
SELECT col2 / + col1 + + tab0.col2 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT + col1 * - col0 + - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL col2 + col2 * + col0 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT tab2.col0 + col1 * - col0 AS col0 FROM tab2
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-8880
SELECT - col1 + + col1 DIV col0 AS col0 FROM tab0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-8880
SELECT - col1 + + col1 / col0 AS col0 FROM tab0
----
-83
-90
-95

query I rowsort
SELECT ALL + col0 * 39 + col0 * - col1 FROM tab0 AS cor0
----
-1128
-2030
-4628

query I rowsort
SELECT DISTINCT - - col1 * 15 - - 17 * - col2 * 16 AS col1 FROM tab0 cor0
----
-20939
-7686
1183

query I rowsort
SELECT + col0 * - cor0.col0 + - col0 AS col0 FROM tab1 cor0
----
-12
-4160
-6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-8884
SELECT ALL - col1 DIV + 3 + 24 AS col1 FROM tab0 AS cor0
----
-4
-6
-8

skipif mysql # not compatible
query I rowsort label-8884
SELECT ALL - col1 / + 3 + 24 AS col1 FROM tab0 AS cor0
----
-4
-6
-8

query I rowsort
SELECT ALL + col2 * 24 + 20 FROM tab2 cor0
----
644
668
932

query I rowsort
SELECT DISTINCT col1 * 21 FROM tab1 AS cor0
----
210
273
546

query I rowsort
SELECT col1 + + col1 * + col2 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + col1 + 87 AS col0 FROM tab1 AS cor0
----
100
113
97

query I rowsort
SELECT ALL - col2 * - 2 - - 93 * - cor0.col0 FROM tab2 AS cor0
----
-597
-7202
-7271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 95 col0 FROM tab1 AS cor0
----
69
82
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * 68 col2 FROM tab2 AS cor0
----
1709
1805
2567

query I rowsort
SELECT DISTINCT col0 * ( - 55 * - col1 ) + + 93 * - col0 AS col0 FROM tab2 AS cor0
----
11284
245856
66518

query I rowsort
SELECT DISTINCT - - col2 * 53 - + cor0.col2 * + col0 AS col1 FROM tab0 AS cor0
----
-2952
18
957

query I rowsort
SELECT - col1 + - col2 * - col1 AS col0 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-8895
SELECT ALL - + col1 + - col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-8895
SELECT ALL - + col1 + - col0 / - col0 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8896
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col2 + col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8896
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col2 + col0 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 + - cor0.col0 + + col1 FROM tab1 AS cor0
----
-118
-147
20

query I rowsort
SELECT ALL - - col0 + col0 + col2 AS col1 FROM tab2 AS cor0
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-8899
SELECT DISTINCT - - col2 DIV 6 AS col0 FROM tab1 AS cor0
----
16
9

skipif mysql # not compatible
query I rowsort label-8899
SELECT DISTINCT - - col2 / 6 AS col0 FROM tab1 AS cor0
----
16
9

query I rowsort
SELECT col1 + 74 AS col2 FROM tab2 AS cor0
----
105
133
91

query I rowsort
SELECT ALL + + col0 + - 24 FROM tab1 AS cor0
----
-21
40
56

query I rowsort
SELECT DISTINCT col1 * - col0 + - col2 FROM tab1 AS cor0
----
-1136
-132
-697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8903
SELECT + CAST( 16 AS SIGNED ) FROM tab1 AS cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-8903
SELECT + CAST ( 16 AS INTEGER ) FROM tab1 AS cor0
----
16
16
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8904
SELECT - 46 + - ( - col2 ) - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8904
SELECT - 46 + - ( - col2 ) - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col2 ) * col2 * 31 FROM tab1 AS cor0
----
100719
285696
90396

query I rowsort
SELECT ALL - 96 AS col2 FROM tab2 cor0
----
-96
-96
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8907
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - col2 / - col0 AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8907
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - col2 / - col0 AS col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT + 25 - col1 FROM tab1 AS cor0
----
-1
12
15

query I rowsort
SELECT - - col0 * + col0 + - col1 + + col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
12109
12465
67

query I rowsort
SELECT - + ( - col2 ) * + 47 AS col0 FROM tab0 AS cor0
----
1551
3854
47

query I rowsort
SELECT + col0 + - ( - col2 ) * col2 - + 12 AS col1 FROM tab2
----
1511
724
742

query I rowsort
SELECT ALL 25 + cor0.col0 AS col0 FROM tab2 AS cor0
----
103
104
32

query I rowsort
SELECT cor0.col1 + - col2 + - col0 * + 99 FROM tab2 AS cor0
----
-689
-7689
-7842

query I rowsort
SELECT DISTINCT 1 * - cor0.col2 + - col1 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8915
SELECT ALL + + col1 - col0 DIV col2 AS col2 FROM tab0 cor0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-8915
SELECT ALL + + col1 - col0 / col2 AS col2 FROM tab0 cor0
----
62
86
90

query I rowsort
SELECT DISTINCT + col2 * + col2 AS col2 FROM tab2
----
1444
676
729

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL < ( - col2 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE - col0 + + col0 <> ( NULL )
----

query I rowsort
SELECT - col0 * - col2 + + col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-8920
SELECT - tab1.col0 + - col0 * col1 DIV + col1 col0 FROM tab1
----
-128
-160
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8920
SELECT - tab1.col0 + - col0 * col1 / + col1 col0 FROM tab1
----
-128
-160
-6

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL IN ( + col1 * col1 )
----

query I rowsort
SELECT DISTINCT tab0.col0 * - col0 - + col0 AS col0 FROM tab0
----
-1260
-600
-8010

query I rowsort
SELECT - tab0.col0 + col0 + - col1 AS col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ALL col1 * - tab2.col1 - - col2 AS col0 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT col0 AS col1 FROM tab0 WHERE NOT NULL NOT IN ( col2 )
----

query I rowsort
SELECT col0 AS col1 FROM tab1 WHERE NULL IN ( - col1 / + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8927
SELECT ALL - col1 DIV - col1 + - col2 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-8927
SELECT ALL - col1 / - col1 + - col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT col2 + - col2 * tab0.col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL tab1.col2 AS col1 FROM tab1 WHERE + col2 + - col2 NOT BETWEEN col2 AND + col0
----
54
57
96

query I rowsort
SELECT DISTINCT tab0.col0 * + col1 * tab0.col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL col1 * - col1 * col0 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT col0 + - col0 * col0 FROM tab2
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-8933
SELECT DISTINCT - col1 * col2 DIV col1 + col1 col1 FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8933
SELECT DISTINCT - col1 * col2 / col1 + col1 col1 FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8934
SELECT - col1 + - tab2.col2 DIV + col0 FROM tab2
----
-17
-34
-59

skipif mysql # not compatible
query I rowsort label-8934
SELECT - col1 + - tab2.col2 / + col0 FROM tab2
----
-17
-34
-59

query I rowsort
SELECT DISTINCT col2 - + tab0.col2 FROM tab0
----
0

query I rowsort
SELECT ALL + col1 + + col1 + - col2 AS col2 FROM tab2
----
-4
35
92

query I rowsort
SELECT ALL col1 FROM tab2 WHERE NOT NULL NOT BETWEEN ( col0 ) AND ( NULL )
----

query I rowsort
SELECT - tab1.col2 - col1 AS col1 FROM tab1
----
-109
-67
-80

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col2 BETWEEN - col0 / col0 AND ( NULL )
----

query I rowsort
SELECT - col1 + col2 + col1 * tab1.col1 AS col1 FROM tab1 WHERE NOT NULL NOT IN ( + col0 + + col1 + + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8941
SELECT col0 + - col1 + tab0.col1 DIV tab0.col1 AS col1 FROM tab0
----
-1
-61
-61

skipif mysql # not compatible
query I rowsort label-8941
SELECT col0 + - col1 + tab0.col1 / tab0.col1 AS col1 FROM tab0
----
-1
-61
-61

query I rowsort
SELECT DISTINCT col2 + col1 * + col0 AS col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT + col1 * col1 * tab1.col2 + col1 AS col2 FROM tab1
----
16237
36530
5710

query I rowsort
SELECT cor0.col2 * col0 * - col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - + cor0.col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT cor0.col2 + - cor0.col1 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 * + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT col2 AS col2 FROM tab1 AS cor0 WHERE NOT NULL > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 - + col2 col1 FROM tab2
----
1406
650
702

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 WHERE NOT ( tab1.col1 ) <= NULL
----

query IIIIII rowsort
SELECT * FROM tab2, tab0 cor0 WHERE NULL BETWEEN NULL AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col0 * - col1 col1 FROM tab1
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-8953
SELECT col1 + - col1 DIV - cor0.col0 AS col1 FROM tab1 cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-8953
SELECT col1 + - col1 / - cor0.col0 AS col1 FROM tab1 cor0
----
10
13
34

query I rowsort
SELECT DISTINCT 70 AS col0 FROM tab1, tab0 cor0
----
70

query I rowsort
SELECT - col1 * 83 AS col0 FROM tab0 AS cor0
----
-7138
-7553
-8051

query I rowsort
SELECT col2 * ( + col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - col2 + col2 * ( col2 ) AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - col1 * 42 + - col2 * - cor0.col0 * + col1 FROM tab2 AS cor0
----
117174
4557
50320

query I rowsort
SELECT - - col1 + - col0 + + col1 * col2 FROM tab2 AS cor0
----
1515
584
861

query I rowsort
SELECT + cor0.col2 + 80 * 32 AS col0 FROM tab2 AS cor0
----
2586
2587
2598

query I rowsort
SELECT - + 45 * 76 + col0 * - col1 FROM tab1 AS cor0
----
-3498
-4060
-4460

query I rowsort
SELECT + 34 * + col1 + col0 + cor0.col2 FROM tab0 cor0
----
2981
3265
3334

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col2 * + col2 + col0 col1 FROM tab2 AS cor0
----
1506
695
705

query I rowsort
SELECT DISTINCT + + col1 - - 66 AS col2 FROM tab2 AS cor0
----
125
83
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8965
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8965
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col1 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + - 30 AS col2 FROM tab1 AS cor0
----
24
27
66

query I rowsort
SELECT ALL ( - ( col2 ) ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col0 + col2 * ( - col0 ) FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT - ( cor0.col2 ) + + 99 FROM tab2 AS cor0
----
61
72
73

query III rowsort
SELECT * FROM tab2 WHERE NOT - col2 BETWEEN ( col2 ) AND + col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT ALL * FROM tab0 WHERE - tab0.col1 < NULL
----

query I rowsort
SELECT + col2 + tab2.col2 * + col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT ALL col1 + - tab0.col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * - col1 - + col2 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT - tab1.col2 AS col0 FROM tab1, tab1 AS cor0, tab2 cor1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - 90 * col1 AS col2 FROM tab2
----
-1530
-2790
-5310

onlyif mysql # use DIV operator for integer division
query I rowsort label-8977
SELECT ALL + ( - 44 ) DIV - col2 - 59 AS col2 FROM tab0 AS cor0
----
-15
-58
-59

skipif mysql # not compatible
query I rowsort label-8977
SELECT ALL + ( - 44 ) / - col2 - 59 AS col2 FROM tab0 AS cor0
----
-15
-58
-59

query I rowsort
SELECT ( col1 ) + col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + cor0.col1 * 72 FROM tab0 AS cor0
----
6192
6552
6984

query I rowsort
SELECT DISTINCT + 98 + + col1 AS col2 FROM tab0 AS cor0
----
184
189
195

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 33 col0 FROM tab0 AS cor0
----
1089
2706
33

query I rowsort
SELECT - + 1 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8983
SELECT DISTINCT col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8983
SELECT DISTINCT col1 / + col1 AS col2 FROM tab0 AS cor0
----
1

query I rowsort
SELECT - + 58 * - 86 * - col0 FROM tab0 AS cor0
----
-119712
-174580
-443932

query I rowsort
SELECT ALL - - 73 AS col1 FROM tab0 AS cor0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 31 ) col0 FROM tab2 AS cor0
----
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-8987
SELECT ALL - 65 + - col2 DIV col0 FROM tab1 AS cor0
----
-65
-66
-83

skipif mysql # not compatible
query I rowsort label-8987
SELECT ALL - 65 + - col2 / col0 FROM tab1 AS cor0
----
-65
-66
-83

query I rowsort
SELECT - - col1 + col2 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + + 33 AS col2 FROM tab1 AS cor0
----
33

query I rowsort
SELECT DISTINCT 91 * 0 + col2 * + tab0.col1 AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - col2 - 52 AS col0 FROM tab2 cor0
----
-78
-79
-90

query I rowsort
SELECT ALL - col1 * - ( + col1 ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + col0 * + 75 + 31 FROM tab2 AS cor0
----
556
5881
5956

query I rowsort
SELECT DISTINCT - col1 * - ( - col1 ) + - col0 + col0 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-8995
SELECT col1 * col1 DIV + 66 AS col1 FROM tab0
----
112
125
142

skipif mysql # not compatible
query I rowsort label-8995
SELECT col1 * col1 / + 66 AS col1 FROM tab0
----
112
125
142

query I rowsort
SELECT + col2 + - col1 + col0 AS col1 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT + cor0.col1 * - col0 + col0 - + col1 FROM tab0 AS cor0
----
-2126
-3457
-8101

onlyif mysql # use DIV operator for integer division
query I rowsort label-8998
SELECT DISTINCT + + cor0.col2 DIV 95 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8998
SELECT DISTINCT + + cor0.col2 / 95 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8999
SELECT ALL tab2.col1 + 87 DIV col1 FROM tab2
----
22
33
60

skipif mysql # not compatible
query I rowsort label-8999
SELECT ALL tab2.col1 + 87 / col1 FROM tab2
----
22
33
60

skipif mysql # not compatible
query I rowsort
SELECT ALL + col1 + CAST ( + ( - col1 ) AS REAL ) + + col0 * 96 FROM tab0
----
2304
3360
8544

query I rowsort
SELECT DISTINCT - 77 AS col0 FROM tab1 cor0
----
-77

onlyif mysql # use DIV operator for integer division
query I rowsort label-9002
SELECT - CAST( + col1 AS SIGNED ) DIV col0 AS col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-9002
SELECT - CAST ( + col1 AS INTEGER ) / col0 AS col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col0 + col0 + - col0 * col1 col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 + ( col1 + - col0 ) FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - col0 + col0 * 10 AS col2 FROM tab0
----
216
315
801

query I rowsort
SELECT - + 16 * col1 * - col2 + + cor0.col0 FROM tab2 AS cor0
----
10415
13399
24622

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2, tab0 cor2
----
3645 values hashing to 76de18c5bf2cf2620e1f411d7bde86e7

query I rowsort
SELECT ALL + 74 * col2 + col0 FROM tab0 AS cor0
----
109
2466
6157

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - - col2 * + col0 col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT 53 + + tab2.col1 AS col2 FROM tab2
----
112
70
84

query I rowsort
SELECT tab0.col0 * 42 FROM tab0
----
1008
1470
3738

onlyif mysql # use DIV operator for integer division
query I rowsort label-9012
SELECT ALL - 35 + 39 DIV col0 AS col2 FROM tab2 AS cor0
----
-30
-35
-35

skipif mysql # not compatible
query I rowsort label-9012
SELECT ALL - 35 + 39 / col0 AS col2 FROM tab2 AS cor0
----
-30
-35
-35

query I rowsort
SELECT DISTINCT 2 * - cor0.col1 + - col0 FROM tab2 AS cor0
----
-113
-196
-69

query I rowsort
SELECT ( col0 ) + - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - - 68 + col0 FROM tab1 cor0
----
132
148
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9016
SELECT + CAST( NULL AS SIGNED ) * col0 * col0 + - cor0.col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9016
SELECT + CAST ( NULL AS INTEGER ) * col0 * col0 + - cor0.col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( - cor0.col2 ) + + cor0.col2 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9018
SELECT DISTINCT + ( - col1 ) DIV col0 + col0 * col1 FROM tab2 AS cor0
----
1343
213
4602

skipif mysql # not compatible
query I rowsort label-9018
SELECT DISTINCT + ( - col1 ) / col0 + col0 * col1 FROM tab2 AS cor0
----
1343
213
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9019
SELECT ALL + col2 DIV 34 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9019
SELECT ALL + col2 / 34 FROM tab2
----
0
0
1

query I rowsort
SELECT + tab1.col1 + - col2 * col1 AS col0 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT col1 * + col1 * ( col0 ) FROM tab2
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 * + col2 + - 97 * 0 col0 FROM tab0
----
2211
5494
67

query I rowsort
SELECT ALL col1 * col0 + - 2 FROM tab2 AS cor0
----
1341
215
4600

query I rowsort
SELECT ALL col0 * - 72 + col2 + + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-10192
-694
-6993

query I rowsort
SELECT col2 + ( cor0.col0 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col1 * 2 AS col0 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + 74 col0 FROM tab1 AS cor0
----
100
84
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9028
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) * + ( - col2 ) * - ( - col1 ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-9028
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) * + ( - col2 ) * - ( - col1 ) AS col2 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9029
SELECT DISTINCT - col0 DIV - col2 AS col1 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9029
SELECT DISTINCT - col0 / - col2 AS col1 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL + col2 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL + - cor0.col1 * + 48 + - col2 FROM tab1 cor0
----
-1302
-537
-720

onlyif mysql # use DIV operator for integer division
query I rowsort label-9032
SELECT ALL + col1 + + col0 DIV col0 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-9032
SELECT ALL + col1 + + col0 / col0 FROM tab1 cor0
----
11
14
27

query I rowsort
SELECT DISTINCT - col1 - 93 * - col0 FROM tab2 AS cor0
----
620
7195
7330

query I rowsort
SELECT + col2 * - col1 + col2 + + cor0.col2 AS col1 FROM tab1 cor0
----
-1056
-1296
-456

query I rowsort
SELECT col0 + - col2 * col1 AS col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT ( - col0 ) * + col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT cor0.col0 * + col2 + col2 + + 29 AS col0 FROM tab1 AS cor0
----
245
3734
7805

query I rowsort
SELECT + - cor0.col1 + 96 + 50 FROM tab1 cor0
----
120
133
136

query I rowsort
SELECT - cor0.col0 + + 8 AS col1 FROM tab0 AS cor0
----
-16
-27
-81

query I rowsort
SELECT + - col1 + col2 + ( + col1 * col0 ) FROM tab2 AS cor0
----
1364
213
4569

query I rowsort
SELECT + 97 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT - - 39 + col0 AS col2 FROM tab0 AS cor0
----
128
63
74

query I rowsort
SELECT 66 + col1 FROM tab2 AS cor0
----
125
83
97

query I rowsort
SELECT - 4 * - col1 FROM tab2 AS cor0
----
124
236
68

query I rowsort
SELECT DISTINCT + 50 AS col0 FROM tab2, tab2 cor0
----
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-9046
SELECT + col1 DIV + col0 AS col1 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-9046
SELECT + col1 / + col0 AS col1 FROM tab0 cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9047
SELECT - col1 + + col2 DIV cor0.col1 FROM tab2 cor0
----
-15
-31
-59

skipif mysql # not compatible
query I rowsort label-9047
SELECT - col1 + + col2 / cor0.col1 FROM tab2 cor0
----
-15
-31
-59

query I rowsort
SELECT ALL + 0 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9049
SELECT ALL 39 * - col1 / + 66 + col2 + + col1 * CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9049
SELECT ALL 39 * - col1 / + 66 + col2 + + col1 * CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 * col1 + + 57 * col2 FROM tab1 AS cor0
----
2609
3000
4432

query I rowsort
SELECT DISTINCT 11 * + col1 AS col1 FROM tab2 AS cor0
----
187
341
649

query I rowsort
SELECT ALL + col0 * - cor0.col2 + - col0 + + cor0.col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 83 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT ( - col2 ) + tab1.col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ( + ( + col2 ) ) FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9058
SELECT ALL + CAST( NULL AS SIGNED ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9058
SELECT ALL + CAST ( NULL AS INTEGER ) col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 96 - col1 FROM tab1
----
70
83
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-9060
SELECT - col1 + col2 DIV + col1 FROM tab1 AS cor0
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-9060
SELECT - col1 + col2 / + col1 FROM tab1 AS cor0
----
-24
-5
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9061
SELECT + 48 + + 31 DIV + cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

skipif mysql # not compatible
query I rowsort label-9061
SELECT + 48 + + 31 / + cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9062
SELECT DISTINCT + col2 * CAST( col0 AS SIGNED ) AS col0 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-9062
SELECT DISTINCT + col2 * CAST ( col0 AS INTEGER ) AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT - + col1 * 73 + - 24 FROM tab0 AS cor0
----
-6302
-6667
-7105

query I rowsort
SELECT DISTINCT tab2.col2 * - col2 * 5 + col1 AS col1 FROM tab2
----
-3321
-3614
-7203

query I rowsort
SELECT - col0 + - 21 FROM tab1 AS cor0
----
-101
-24
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col1 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col1 * 71 FROM tab1 AS cor0
----
1846
710
923

query I rowsort
SELECT + 52 AS col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT col2 - 54 AS col2 FROM tab0
----
-21
-53
28

query I rowsort
SELECT + + 4 + + 10 AS col1 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT - 54 * col1 FROM tab2 cor0
----
-1674
-3186
-918

query I rowsort
SELECT + cor1.col1 * 23 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to d2d2cceaf3af38a9e0557b59f7cd6673

query I rowsort
SELECT DISTINCT 79 * - 30 FROM tab1, tab2 AS cor0
----
-2370

onlyif mysql # use DIV operator for integer division
query I rowsort label-9074
SELECT + 81 DIV 34 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif mysql # not compatible
query I rowsort label-9074
SELECT + 81 / 34 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

onlyif mysql # use DIV operator for integer division
query I rowsort label-9075
SELECT - col0 DIV cor0.col0 + - col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-9075
SELECT - col0 / cor0.col0 + - col1 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT + ( tab0.col2 ) - col1 * col0 AS col0 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT + 35 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 * + col1 col2 FROM tab1
----
110
182
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - - col1 col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9080
SELECT ALL + - cor0.col2 * col0 DIV - 13 AS col1 FROM tab0 AS cor0
----
2
561
60

skipif mysql # not compatible
query I rowsort label-9080
SELECT ALL + - cor0.col2 * col0 / - 13 AS col1 FROM tab0 AS cor0
----
2
561
60

query I rowsort
SELECT DISTINCT + + cor0.col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + cor0.col1 * - col0 * + col1 - col1 FROM tab0 cor0
----
-177590
-329412
-737100

query I rowsort
SELECT + 49 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL + col0 * - 99 + + col1 FROM tab1 AS cor0
----
-271
-6326
-7907

query I rowsort
SELECT - cor0.col2 + - cor0.col0 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT - col1 * + 13 + + col1 FROM tab2 AS cor0
----
-204
-372
-708

query I rowsort
SELECT + col1 * ( - 11 ) + col2 AS col2 FROM tab1 AS cor0
----
-232
-47
-53

query I rowsort
SELECT DISTINCT + col0 + - col1 * col1 * col1 AS col0 FROM tab0 AS cor0
----
-636032
-753482
-912638

query I rowsort
SELECT - - col2 + + 23 FROM tab2 AS cor0
----
49
50
61

query I rowsort
SELECT ALL + col0 - + 81 * - col0 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT + cor0.col2 + 27 FROM tab0 AS cor0
----
109
28
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-9092
SELECT col1 DIV col2 + 30 FROM tab1 cor0
----
30
30
30

skipif mysql # not compatible
query I rowsort label-9092
SELECT col1 / col2 + 30 FROM tab1 cor0
----
30
30
30

query I rowsort
SELECT ALL - col0 + col1 * 59 FROM tab1 cor0
----
1531
526
687

skipif mysql # not compatible
query I rowsort
SELECT + cor0.col1 * + CAST ( + col1 AS REAL ) + cor0.col1 FROM tab0 cor0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + + col0 col1 FROM tab0 AS cor0
----
-2
-62

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 1a92b418ae3c05ba566f88a890a407ae

query I rowsort
SELECT - col0 * + col0 - - col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + + ( col2 ) AS col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9099
SELECT - ( + col1 ) DIV - 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-9099
SELECT - ( + col1 ) / - col2 col1 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 * ( cor0.col2 ) col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to caa3e6469432624a16bd3084f5c6de58

query I rowsort
SELECT DISTINCT + + 72 AS col1 FROM tab0 AS cor0
----
72

query I rowsort
SELECT ALL + 97 + col2 + col0 FROM tab0 AS cor0
----
133
154
268

query I rowsort
SELECT DISTINCT + + 12 * + col2 * + col2 FROM tab0 AS cor0
----
12
13068
80688

query I rowsort
SELECT + ( col0 ) + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - ( col2 ) * + 66 - col2 FROM tab1 AS cor0
----
-3618
-3819
-6432

query I rowsort
SELECT col1 - col1 * - 8 FROM tab0 AS cor0
----
774
819
873

onlyif mysql # use DIV operator for integer division
query I rowsort label-9107
SELECT ALL - col2 + col0 DIV + 51 FROM tab1 AS cor0
----
-54
-56
-95

skipif mysql # not compatible
query I rowsort label-9107
SELECT ALL - col2 + col0 / + 51 FROM tab1 AS cor0
----
-54
-56
-95

query I rowsort
SELECT DISTINCT - ( + col1 ) * - col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - 37 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-111
-2368
-2960

query I rowsort
SELECT 31 - col2 AS col2 FROM tab0 AS cor0
----
-2
-51
30

query I rowsort
SELECT 90 + + col0 + col2 AS col1 FROM tab1 AS cor0
----
147
211
266

onlyif mysql # use DIV operator for integer division
query I rowsort label-9112
SELECT DISTINCT col0 DIV 43 + + col1 * + col2 * - 53 - - col2 AS col2 FROM tab1
----
-30152
-66047
-74358

skipif mysql # not compatible
query I rowsort label-9112
SELECT DISTINCT col0 / 43 + + col1 * + col2 * - 53 - - col2 AS col2 FROM tab1
----
-30152
-66047
-74358

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9113
SELECT ALL CAST( + 65 AS SIGNED ) * + col1 AS col1 FROM tab2
----
1105
2015
3835

skipif mysql # not compatible
query I rowsort label-9113
SELECT ALL CAST ( + 65 AS INTEGER ) * + col1 AS col1 FROM tab2
----
1105
2015
3835

query I rowsort
SELECT - 11 + 72 AS col1 FROM tab0
----
61
61
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9115
SELECT DISTINCT - CAST( + col1 AS SIGNED ) AS col2 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-9115
SELECT DISTINCT - CAST ( + col1 AS INTEGER ) AS col2 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT ( + 89 ) AS col2 FROM tab2
----
89
89
89

query I rowsort
SELECT + ( + 78 ) AS col0 FROM tab1
----
78
78
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9118
SELECT - col2 DIV col1 col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9118
SELECT - col2 / col1 col2 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9119
SELECT + CAST( NULL AS DECIMAL ) + cor1.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9119
SELECT + CAST ( NULL AS REAL ) + cor1.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + - col1 + - col2 + + col2 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - 46 * - col1 * + col1 FROM tab2
----
13294
160126
44206

query I rowsort
SELECT DISTINCT + ( col0 ) * - ( - col2 ) FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-9123
SELECT + col0 DIV + col1 AS col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9123
SELECT + col0 / + col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL ( + col1 ) * - 3 * 20 + + tab2.col2 FROM tab2
----
-1833
-3514
-982

query I rowsort
SELECT col1 + col2 * - 16 - 29 FROM tab0
----
-1250
-471
52

query I rowsort
SELECT tab2.col1 + + 75 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 78f7b3d0836f868c586d037c7088b87a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9127
SELECT - 6 + - col1 / CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9127
SELECT - 6 + - col1 / CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - col2 * 49 FROM tab2
----
-1215
-1292
-1845

query I rowsort
SELECT ALL + col2 * ( + col1 ) FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - - 32 * col1 + cor0.col2 FROM tab0 AS cor0
----
2785
2994
3105

query I rowsort
SELECT ALL - col0 + - col2 + tab2.col2 FROM tab2
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col0 ) * col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ( - 51 ) * cor0.col0 + cor0.col1 FROM tab1 AS cor0
----
-127
-3254
-4067

query I rowsort
SELECT ALL + col2 + 69 AS col0 FROM tab0 AS cor0
----
102
151
70

query I rowsort
SELECT DISTINCT + 80 + + ( - col1 + col0 ) AS col0 FROM tab2 AS cor0
----
142
56
99

query I rowsort
SELECT + tab2.col0 + - 54 FROM tab2
----
-47
24
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * tab0.col1 * tab0.col0 col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT col1 * 67 + 67 * + col0 FROM tab1
----
1943
4958
6231

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT - col0 * - 2 + - cor0.col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9141
SELECT ALL CAST( + col1 AS SIGNED ) + col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-9141
SELECT ALL CAST ( + col1 AS INTEGER ) + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + 64 AS col0 FROM tab0 AS cor0
----
64
64
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9143
SELECT ALL - CAST( col0 AS SIGNED ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9143
SELECT ALL - CAST ( col0 AS INTEGER ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * + col2 + cor0.col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL col0 * + 77 AS col2 FROM tab0 AS cor0
----
1848
2695
6853

onlyif mysql # use DIV operator for integer division
query I rowsort label-9146
SELECT DISTINCT + + col1 DIV - col2 + col1 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-9146
SELECT DISTINCT + + col1 / - col2 + col1 col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + ( + 67 ) + + col2 AS col2 FROM tab0 AS cor0
----
100
149
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 + col0 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL 46 * tab0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8865c30c645770e9d42e9fb72bb2f126

query I rowsort
SELECT DISTINCT - 76 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
-76

query I rowsort
SELECT ALL col1 * + 72 AS col2 FROM tab1
----
1872
720
936

query I rowsort
SELECT + col0 * ( + 89 ) * col2 FROM tab1 AS cor0
----
14418
324672
683520

query I rowsort
SELECT ALL + col1 * col1 - - 41 AS col0 FROM tab0 AS cor0
----
7437
8322
9450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col2 col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + 77 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 * - col2 col2 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT + + ( cor0.col1 ) * col2 - 55 FROM tab2 AS cor0
----
1479
591
782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) * col0 + - col1 col0 FROM tab2 cor0
----
18
6025
6224

query I rowsort
SELECT - col2 - cor0.col1 * + col0 AS col1 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-9160
SELECT - - 0 + col0 DIV - cor0.col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-9160
SELECT - - 0 + col0 / - cor0.col1 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT + col1 * 57 + col1 AS col2 FROM tab2 cor0
----
1798
3422
986

query I rowsort
SELECT ALL tab0.col0 * - 75 AS col0 FROM tab0
----
-1800
-2625
-6675

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9163
SELECT DISTINCT - CAST( NULL AS SIGNED ) + 56 AS col0 FROM tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9163
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 56 AS col0 FROM tab1, tab1 AS cor0
----
NULL

query I rowsort
SELECT 14 * ( + cor0.col2 ) FROM tab1 AS cor0
----
1344
756
798

query I rowsort
SELECT ALL 45 + col2 FROM tab2 AS cor0
----
71
72
83

query I rowsort
SELECT - col2 * + col0 + 64 FROM tab0 AS cor0
----
-7234
-728
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-9167
SELECT DISTINCT 30 DIV + col0 AS col1 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-9167
SELECT DISTINCT 30 / + col0 AS col1 FROM tab2 cor0
----
0
4

query I rowsort
SELECT - 31 + cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 30573a6680951e915281fad9a6afbea5

query I rowsort
SELECT 77 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT col2 + col0 * - ( cor0.col1 + col1 ) FROM tab0 cor0
----
-16116
-4095
-6789

query I rowsort
SELECT col2 * - col1 + col1 AS col1 FROM tab2
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-9172
SELECT - - cor1.col2 + cor0.col1 DIV cor0.col0 AS col0 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 294fa9ac8754bffeb99b33d864074cce

skipif mysql # not compatible
query I rowsort label-9172
SELECT - - cor1.col2 + cor0.col1 / cor0.col0 AS col0 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 294fa9ac8754bffeb99b33d864074cce

onlyif mysql # use DIV operator for integer division
query I rowsort label-9173
SELECT DISTINCT + 38 DIV + tab1.col1 col2 FROM tab1
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9173
SELECT DISTINCT + 38 / + tab1.col1 col2 FROM tab1
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9174
SELECT cor0.col1 * CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9174
SELECT cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col2 + + col1 * + col0 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT - + col1 + + ( col2 ) + + cor0.col0 AS col2 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT ALL - col0 + 34 FROM tab2 AS cor0
----
-44
-45
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * + col1 col2 FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - cor0.col2 * col2 col1 FROM tab2 AS cor0
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + ( + ( col0 ) + col2 * + col2 ) col0 FROM tab0
----
36
36729
558666

query I rowsort
SELECT ( + 63 ) * + cor0.col0 AS col0 FROM tab2 cor0
----
441
4914
4977

query I rowsort
SELECT ALL - col2 * + ( 30 ) FROM tab1
----
-1620
-1710
-2880

query I rowsort
SELECT ALL col0 - + cor0.col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - 1 * - col1 + col1 AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT cor0.col0 * col0 + + ( 57 * cor0.col2 + - col1 ) AS col2 FROM tab1 AS cor0
----
11859
3061
7335

query I rowsort
SELECT + 43 * tab2.col1 FROM tab2
----
1333
2537
731

query I rowsort
SELECT ALL + 43 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT - + col2 + - col2 * + col2 AS col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT + 43 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT + col1 + - cor0.col0 AS col0 FROM tab0 cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9191
SELECT + col1 DIV col1 + cor0.col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-9191
SELECT + col1 / col1 + cor0.col2 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9192
SELECT DISTINCT - + cor0.col1 DIV col0 + col2 + col1 * - col2 col1 FROM tab1 AS cor0
----
-1152
-1358
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9192
SELECT DISTINCT - + cor0.col1 / col0 + col2 + col1 * - col2 col1 FROM tab1 AS cor0
----
-1152
-1358
-513

query I rowsort
SELECT DISTINCT + col2 + + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9194
SELECT ( - col0 ) * CAST( 67 AS SIGNED ) + - col0 FROM tab0 AS cor0
----
-1632
-2380
-6052

skipif mysql # not compatible
query I rowsort label-9194
SELECT ( - col0 ) * CAST ( 67 AS INTEGER ) + - col0 FROM tab0 AS cor0
----
-1632
-2380
-6052

query I rowsort
SELECT ALL + - 97 * col1 AS col0 FROM tab1 AS cor0
----
-1261
-2522
-970

query I rowsort
SELECT DISTINCT + 78 + - col2 FROM tab0 cor0
----
-4
45
77

query I rowsort
SELECT ALL - cor0.col2 - - col1 AS col2 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT 23 + - col2 * CAST ( - col0 AS REAL ) FROM tab0 AS cor0
----
58
7321
815

query I rowsort
SELECT DISTINCT 53 + - col0 + col2 FROM tab0 cor0
----
19
46
62

query I rowsort
SELECT col0 * tab1.col1 + tab1.col1 * 12 FROM tab1
----
1196
390
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9201
SELECT 39 * col0 + col1 DIV 16 AS col2 FROM tab0
----
1371
3476
941

skipif mysql # not compatible
query I rowsort label-9201
SELECT 39 * col0 + col1 / 16 AS col2 FROM tab0
----
1371
3476
941

query I rowsort
SELECT DISTINCT 67 + - col0 FROM tab1
----
-13
3
64

query I rowsort
SELECT DISTINCT + col0 + col2 AS col1 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 40 col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT - - col2 + - col1 * col0 * - col1 FROM tab1 AS cor0
----
13616
2082
6457

query I rowsort
SELECT + col1 + + col1 + + col0 * ( col0 ) AS col1 FROM tab0 AS cor0
----
1419
748
8103

query I rowsort
SELECT ALL + + 50 + col2 AS col1 FROM tab0 cor0
----
132
51
83

query I rowsort
SELECT - col2 + - cor0.col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - col2 + - col0 + + 19 AS col0 FROM tab1 AS cor0
----
-102
-157
-38

query I rowsort
SELECT - col1 + col1 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL 67 + + col1 * + col0 AS col1 FROM tab2
----
1410
284
4669

query I rowsort
SELECT + col2 + col0 * - 3 FROM tab2
----
-199
-208
6

query I rowsort
SELECT + col0 * + ( + col0 ) + - col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT + ( col1 ) * col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9215
SELECT DISTINCT + 32 DIV - col0 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-9215
SELECT DISTINCT + 32 / - col0 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT + + 85 + cor0.col1 FROM tab2 AS cor0
----
102
116
144

onlyif mysql # use DIV operator for integer division
query I rowsort label-9217
SELECT DISTINCT + col1 + col1 DIV cor0.col0 FROM tab2 AS cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-9217
SELECT DISTINCT + col1 + col1 / cor0.col0 FROM tab2 AS cor0
----
17
35
59

query I rowsort
SELECT + 43 * - col1 AS col1 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT ALL col2 * - 85 * - col0 FROM tab0 AS cor0
----
2975
620330
67320

onlyif mysql # use DIV operator for integer division
query I rowsort label-9220
SELECT ALL col0 + 88 DIV col1 AS col1 FROM tab0 cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-9220
SELECT ALL col0 + 88 / col1 AS col1 FROM tab0 cor0
----
25
35
89

query I rowsort
SELECT 50 * + col0 + col0 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT DISTINCT + col0 * + 17 + col0 FROM tab2 AS cor0
----
126
1404
1422

query I rowsort
SELECT ALL + 1 - + 30 * col0 FROM tab0 AS cor0
----
-1049
-2669
-719

query I rowsort
SELECT 49 + col2 * - col2 FROM tab0 AS cor0
----
-1040
-6675
48

query I rowsort
SELECT 89 + col0 AS col0 FROM tab2 AS cor0
----
167
168
96

query I rowsort
SELECT DISTINCT - 3 * 47 AS col0 FROM tab1 AS cor0
----
-141

query I rowsort
SELECT col1 * 41 FROM tab0 AS cor0
----
3526
3731
3977

query I rowsort
SELECT ALL + 6 * 92 FROM tab2 AS cor0
----
552
552
552

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( + 78 AS REAL ) * + col0 FROM tab2 AS cor0
----
546
6084
6162

query I rowsort
SELECT DISTINCT - - col1 + + 37 FROM tab2 AS cor0
----
54
68
96

query I rowsort
SELECT DISTINCT + - 16 * col0 AS col1 FROM tab0 AS cor0
----
-1424
-384
-560

query I rowsort
SELECT ALL - ( + col1 ) + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col0 - col2 * - col1 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9234
SELECT + col2 + cor0.col0 * - CAST( NULL AS SIGNED ) col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9234
SELECT + col2 + cor0.col0 * - CAST ( NULL AS INTEGER ) col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9235
SELECT DISTINCT - col1 - col1 DIV + 4 FROM tab0 AS cor0
----
-107
-113
-121

skipif mysql # not compatible
query I rowsort label-9235
SELECT DISTINCT - col1 - col1 / + 4 FROM tab0 AS cor0
----
-107
-113
-121

query I rowsort
SELECT + ( - cor0.col1 ) + 66 AS col2 FROM tab1 cor0
----
40
53
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-9237
SELECT - col0 + - ( col0 ) DIV col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-9237
SELECT - col0 + - ( col0 ) / col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - 91 * col0 col1 FROM tab1 AS cor0
----
-14742
-331968
-698880

query I rowsort
SELECT ALL - cor0.col0 - cor0.col2 * col1 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL ( - 73 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

onlyif mysql # use DIV operator for integer division
query I rowsort label-9241
SELECT + + col0 + col1 DIV - col0 AS col2 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-9241
SELECT + + col0 + col1 / - col0 AS col2 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT ALL - col2 + - 40 FROM tab1 AS cor0
----
-136
-94
-97

query I rowsort
SELECT col0 + - 4 * - col1 FROM tab1 AS cor0
----
104
107
132

query I rowsort
SELECT + col0 - + 84 * + col0 FROM tab2 cor0
----
-581
-6474
-6557

query I rowsort
SELECT col2 * 99 + col2 AS col0 FROM tab0 AS cor0
----
100
3300
8200

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab0 cor2
----
3645 values hashing to 97b43fbe79eecd0bc6921392403b666d

onlyif mysql # use DIV operator for integer division
query I rowsort label-9247
SELECT DISTINCT - col1 + ( col0 ) DIV - col1 AS col0 FROM tab2
----
-21
-31
-60

skipif mysql # not compatible
query I rowsort label-9247
SELECT DISTINCT - col1 + ( col0 ) / - col1 AS col0 FROM tab2
----
-21
-31
-60

query I rowsort
SELECT + ( 29 ) * - col1 AS col1 FROM tab1 AS cor0
----
-290
-377
-754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 * - cor0.col1 col2 FROM tab1 cor0
----
-157
-265
-730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT + col2 + ( col2 ) AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL 58 FROM tab0, tab1 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9253
SELECT + col1 * ( + 53 ) / + col0 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9253
SELECT + col1 * ( + 53 ) / + col0 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * - col1 + 82 AS col0 FROM tab2
----
1616
728
919

query I rowsort
SELECT - col1 * + col2 + - col0 AS col0 FROM tab0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-9256
SELECT ALL cor0.col2 DIV + col1 col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9256
SELECT ALL cor0.col2 / + col1 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 * col2 + - col0 AS col1 FROM tab0 WHERE NULL IN ( + col2 )
----

query I rowsort
SELECT + col0 AS col2 FROM tab1 AS cor0 WHERE col2 >= NULL
----

query I rowsort
SELECT + col1 * col1 * col2 AS col0 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - col0 FROM tab2 WHERE NOT NULL < col2
----

query III rowsort
SELECT ALL * FROM tab1 WHERE ( col0 ) NOT IN ( col1 - tab1.col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT + col1 - + col2 * col0 * col0 FROM tab2
----
-1292
-158125
-237141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col2 FROM tab2 WHERE NULL > col0 * col1 * col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9264
SELECT col1 * col1 DIV - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9264
SELECT col1 * col1 / - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - tab0.col1 * col1 * col0 AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - - col2 * + col0 + col1 AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT col0 * + col2 + - col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-9268
SELECT ALL + col1 DIV cor0.col0 + col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-9268
SELECT ALL + col1 / cor0.col0 + col2 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT + - col1 + - col0 + col1 * - col2 FROM tab0 AS cor0
----
-229
-2948
-7642

query I rowsort
SELECT DISTINCT col1 + + col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - col2 * - col0 + col2 * - col2 FROM tab0 AS cor0
----
-297
34
574

query I rowsort
SELECT col0 + + col2 * + tab2.col0 AS col2 FROM tab2
----
196
2106
3081

query I rowsort
SELECT + col0 * - cor0.col0 AS col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL col0 * + col2 + 28 FROM tab2
----
2056
217
3030

query I rowsort
SELECT + + 25 + - cor0.col2 AS col0 FROM tab2 cor0
----
-1
-13
-2

query I rowsort
SELECT + 27 * 43 FROM tab0, tab0 AS cor0
----
9 values hashing to d494e767b2f0cd4ff8d13b2426715bdb

query I rowsort
SELECT ALL + - 98 * - col0 AS col2 FROM tab1 AS cor0
----
294
6272
7840

query I rowsort
SELECT ALL - 92 * col2 AS col1 FROM tab0 AS cor0
----
-3036
-7544
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + col2 col1 FROM tab1 cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-9280
SELECT col1 DIV + col1 + - col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-9280
SELECT col1 / + col1 + - col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT - + col2 + + col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT - col0 * col0 * + 88 + 44 FROM tab1 AS cor0
----
-360404
-563156
-748

onlyif mysql # use DIV operator for integer division
query I rowsort label-9283
SELECT ALL - - col1 DIV + cor0.col1 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9283
SELECT ALL - - col1 / + cor0.col1 AS col1 FROM tab2 cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9284
SELECT + - cor0.col1 + CAST( - 59 AS SIGNED ) FROM tab1 AS cor0
----
-69
-72
-85

skipif mysql # not compatible
query I rowsort label-9284
SELECT + - cor0.col1 + CAST ( - 59 AS INTEGER ) FROM tab1 AS cor0
----
-69
-72
-85

query I rowsort
SELECT DISTINCT - - col1 * - col1 + - col1 AS col2 FROM tab2 AS cor0
----
-306
-3540
-992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9286
SELECT DISTINCT + col1 + CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9286
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 * col1 + + 67 + col0 * - cor0.col0 FROM tab2 AS cor0
----
-2536
-5885
979

query I rowsort
SELECT cor0.col0 + 10 FROM tab1 AS cor0
----
13
74
90

query I rowsort
SELECT col1 * + 51 + + ( + col0 ) AS col0 FROM tab2 AS cor0
----
1588
3087
946

onlyif mysql # use DIV operator for integer division
query I rowsort label-9290
SELECT DISTINCT + + col1 DIV - ( + col1 ) FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9290
SELECT DISTINCT + + col1 / - ( + col1 ) FROM tab1 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9291
SELECT - col1 * CAST( NULL AS SIGNED ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9291
SELECT - col1 * CAST ( NULL AS INTEGER ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col1 + + 73 * col1 AS col2 FROM tab1 AS cor0
----
1924
740
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-9293
SELECT DISTINCT - col0 DIV + col1 + - col1 + - col0 AS col0 FROM tab0 cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-9293
SELECT DISTINCT - col0 / + col1 + - col1 + - col0 AS col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT - + col0 * col1 + - 47 * col1 AS col0 FROM tab2 cor0
----
-1674
-2142
-7375

query I rowsort
SELECT col2 * col1 + + 37 * col1 * + col1 FROM tab1 AS cor0
----
26416
4270
7501

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) NOT IN ( - col1 * col2 )
----

query I rowsort
SELECT tab2.col2 * col2 + + tab2.col1 FROM tab2
----
1461
735
760

query I rowsort
SELECT ALL - col2 + col1 + tab0.col2 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9299
SELECT ALL - tab2.col2 DIV col1 AS col1 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-9299
SELECT ALL - tab2.col2 / col1 AS col1 FROM tab2
----
-2
0
0

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( tab0.col1 * col2 - col0 )
----

query I rowsort
SELECT tab1.col0 + - col0 * - col0 * - tab1.col2 AS col2 FROM tab1
----
-233408
-483
-614320

query I rowsort
SELECT DISTINCT + tab1.col1 + + col2 * - col1 AS col0 FROM tab1
----
-1235
-1378
-560

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE + col1 NOT IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT 47 + col0 * 35 * 87 + + col0 FROM tab1 AS cor0
----
194991
243727
9185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 * col0 + - col1 * col0 * - col0 col1 FROM tab2
----
103095
1330
356928

query I rowsort
SELECT + 41 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-48
17
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 * col1 + col0 col2 FROM tab0
----
-2728
-7282
35

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9309
SELECT DISTINCT col0 DIV + tab0.col0 AS col1 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-9309
SELECT DISTINCT col0 / + tab0.col0 AS col1 FROM tab0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9310
SELECT DISTINCT col0 DIV - col2 AS col1 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-9310
SELECT DISTINCT col0 / - col2 AS col1 FROM tab1
----
-1
0

query I rowsort
SELECT col0 FROM tab0 WHERE NOT col2 * - col2 BETWEEN col2 AND NULL
----
24
35
89

query I rowsort
SELECT DISTINCT + col2 * + col2 * + col1 + + tab0.col0 AS col2 FROM tab0
----
132
611973
93678

onlyif mysql # use DIV operator for integer division
query I rowsort label-9313
SELECT - col1 * col0 DIV + col2 AS col1 FROM tab1
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-9313
SELECT - col1 * col0 / + col2 AS col1 FROM tab1
----
-1
-10
-11

query I rowsort
SELECT ALL - col1 + 42 AS col1 FROM tab0 AS cor0
----
-44
-49
-55

query I rowsort
SELECT - + col2 * + 5 FROM tab1 AS cor0
----
-270
-285
-480

query I rowsort
SELECT DISTINCT - col0 + ( + col2 ) + cor0.col1 AS col0 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT + col0 + 99 * col1 FROM tab0 cor0
----
8538
9098
9638

query I rowsort
SELECT + col2 * ( col2 ) AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col0 * 4 * + col1 AS col1 FROM tab0 AS cor0
----
13580
32396
8256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL col2 + 35 + col2 AS col0 FROM tab0 cor0
----
101
199
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 33 col0 FROM tab0 AS cor0
----
2838
3003
3201

query I rowsort
SELECT ALL col0 * + col2 + 63 AS col1 FROM tab2 AS cor0
----
2091
252
3065

query I rowsort
SELECT ALL - cor0.col2 * 76 AS col1 FROM tab1 cor0
----
-4104
-4332
-7296

query I rowsort
SELECT DISTINCT col1 * col2 + col1 * - tab0.col1 + - col1 FROM tab0
----
-4644
-910
-9409

query I rowsort
SELECT ALL col2 + - col2 * 21 FROM tab0 AS cor0
----
-1640
-20
-660

query I rowsort
SELECT + + col1 * - 32 AS col0 FROM tab0 cor0
----
-2752
-2912
-3104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col2 col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + ( + cor0.col1 ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + ( + 35 ) AS col2 FROM tab1 AS cor0
----
35
35
35

query I rowsort
SELECT ALL + col0 * 83 * + 67 FROM tab0
----
133464
194635
494929

query I rowsort
SELECT DISTINCT col0 * + 8 FROM tab1
----
24
512
640

query I rowsort
SELECT ALL + col1 * - col0 + + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-2686
-434
-9204

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9335
SELECT CAST( - 33 AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

skipif mysql # not compatible
query I rowsort label-9335
SELECT CAST ( - 33 AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

query I rowsort
SELECT DISTINCT 53 - col1 * col0 FROM tab0 cor0
----
-2011
-3342
-8046

query I rowsort
SELECT DISTINCT 72 * - col1 + ( col0 ) * + col1 FROM tab0 AS cor0
----
-3589
-4128
1547

query I rowsort
SELECT ALL + + col1 * + col2 AS col0 FROM tab0 cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col1 + col0 col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT + col1 + ( - col2 ) FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9341
SELECT col1 + col2 * col1 DIV - col0 FROM tab0
----
-32
8
95

skipif mysql # not compatible
query I rowsort label-9341
SELECT col1 + col2 * col1 / - col0 FROM tab0
----
-32
8
95

query I rowsort
SELECT col0 * col2 + ( + col2 ) * - col1 FROM tab0 AS cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9343
SELECT DISTINCT 6 * col0 + col0 * 73 DIV + col2 AS col0 FROM tab1 AS cor0
----
22
465
540

skipif mysql # not compatible
query I rowsort label-9343
SELECT DISTINCT 6 * col0 + col0 * 73 / + col2 AS col0 FROM tab1 AS cor0
----
22
465
540

query I rowsort
SELECT DISTINCT - 59 + + col1 FROM tab1 cor0
----
-33
-46
-49

query I rowsort
SELECT ALL col0 + - col2 * - tab1.col2 AS col1 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT DISTINCT - col1 * col1 + - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-157
-265
-730

onlyif mysql # use DIV operator for integer division
query I rowsort label-9347
SELECT - cor0.col0 DIV - cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-9347
SELECT - cor0.col0 / - cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT - col1 + - 10 * + col0 + + col0 FROM tab0 AS cor0
----
-302
-412
-892

query I rowsort
SELECT + col2 + - 17 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-1536
-864
-912

query I rowsort
SELECT ALL col2 * + 45 FROM tab1 AS cor0
----
2430
2565
4320

query I rowsort
SELECT col2 + - col0 * - col1 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9352
SELECT + cor0.col2 + CAST( - col0 AS SIGNED ) * - cor0.col0 FROM tab0 AS cor0
----
1226
609
8003

skipif mysql # not compatible
query I rowsort label-9352
SELECT + cor0.col2 + CAST ( - col0 AS INTEGER ) * - cor0.col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL + col1 * 34 + - 95 * - col1 FROM tab1 AS cor0
----
1290
1677
3354

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( 12 AS REAL ) + + col1 FROM tab0 AS cor0
----
74
79
85

query I rowsort
SELECT ALL 74 + col2 FROM tab1
----
128
131
170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 17 col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT DISTINCT - + 38 + col0 * cor0.col2 FROM tab0 AS cor0
----
-3
7260
754

query I rowsort
SELECT 79 * col0 FROM tab0 cor0
----
1896
2765
7031

query I rowsort
SELECT ALL + col1 * - 82 AS col2 FROM tab1 AS cor0
----
-1066
-2132
-820

query I rowsort
SELECT DISTINCT + - col1 + col2 * col0 * + col2 FROM tab0 AS cor0
----
-62
26050
598345

query I rowsort
SELECT + ( - col2 ) * + col0 + + col1 * + col2 FROM tab0 cor0
----
164
2046
62

query I rowsort
SELECT DISTINCT 49 * col0 FROM tab1 AS cor0
----
147
3136
3920

query I rowsort
SELECT 97 + col2 * col1 AS col2 FROM tab0 AS cor0
----
194
2935
7559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9364
SELECT ALL ( - col0 ) * CAST( + col2 AS SIGNED ) + + col2 FROM tab1 cor0
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-9364
SELECT ALL ( - col0 ) * CAST ( + col2 AS INTEGER ) + + col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT col1 - col0 AS col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT ALL - 8 * - col1 + - col2 * 81 AS col2 FROM tab1 AS cor0
----
-4166
-4537
-7672

query I rowsort
SELECT DISTINCT - + col2 * - col1 + + ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT 0 + col2 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + col0 * col1 + ( col0 ) FROM tab1 AS cor0
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9370
SELECT - + col2 + - col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-9370
SELECT - + col2 + - col1 / - col1 AS col0 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT ALL - col0 + col0 * 79 AS col1 FROM tab2 AS cor0
----
546
6084
6162

query I rowsort
SELECT ALL + + 51 + col0 FROM tab1 cor0
----
115
131
54

query I rowsort
SELECT DISTINCT + - col2 + cor0.col2 * + col1 AS col0 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL + 21 * - col2 * + col0 + col1 AS col0 FROM tab0
----
-153167
-16546
-638

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9375
SELECT + CAST( NULL AS SIGNED ) * ( - col0 ) + + 62 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9375
SELECT + CAST ( NULL AS INTEGER ) * ( - col0 ) + + 62 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + col0 * col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - ( 46 ) - - tab1.col2 AS col0 FROM tab1
----
11
50
8

query I rowsort
SELECT + col2 + + ( - col2 + col2 ) AS col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9379
SELECT - CAST( NULL AS SIGNED ) / cor0.col0 + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9379
SELECT - CAST ( NULL AS INTEGER ) / cor0.col0 + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9380
SELECT col0 + col2 DIV 41 FROM tab0 AS cor0
----
24
35
91

skipif mysql # not compatible
query I rowsort label-9380
SELECT col0 + col2 / 41 FROM tab0 AS cor0
----
24
35
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-9381
SELECT DISTINCT col2 * - col1 DIV + col1 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-9381
SELECT DISTINCT col2 * - col1 / + col1 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + + 45 AS col0 FROM tab1 AS cor0
----
45
45
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9383
SELECT - CAST( - 97 + col1 * + col0 AS SIGNED ) AS col2 FROM tab1
----
-543
-943
19

skipif mysql # not compatible
query I rowsort label-9383
SELECT - CAST ( - 97 + col1 * + col0 AS INTEGER ) AS col2 FROM tab1
----
-543
-943
19

query I rowsort
SELECT col1 * 5 + col1 * 44 AS col2 FROM tab0 AS cor0
----
4214
4459
4753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9385
SELECT CAST( col0 * - col1 AS SIGNED ) AS col1 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-9385
SELECT CAST ( col0 * - col1 AS INTEGER ) AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL - ( + 15 ) FROM tab0
----
-15
-15
-15

query I rowsort
SELECT ALL 83 * tab2.col2 FROM tab2
----
2158
2241
3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-9388
SELECT - col0 + + 26 DIV + col2 FROM tab0 AS cor0
----
-24
-89
-9

skipif mysql # not compatible
query I rowsort label-9388
SELECT - col0 + + 26 / + col2 FROM tab0 AS cor0
----
-24
-89
-9

query I rowsort
SELECT - 93 + + 17 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

query I rowsort
SELECT ALL 34 AS col1 FROM tab1
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9391
SELECT + cor0.col2 DIV + col1 col0 FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9391
SELECT + cor0.col2 / + col1 col0 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT - col1 - - col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT + col2 * 66 + + col0 * col2 FROM tab0 AS cor0
----
101
12710
2970

query I rowsort
SELECT - col1 * - col2 * col0 + col0 FROM tab2 cor0
----
119730
51113
5866

onlyif mysql # use DIV operator for integer division
query I rowsort label-9395
SELECT DISTINCT - + col1 DIV col0 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-9395
SELECT DISTINCT - + col1 / col0 FROM tab2 AS cor0
----
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9396
SELECT col2 DIV - 50 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9396
SELECT col2 / - 50 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - + col0 * + ( + cor0.col0 ) + col0 + + col0 AS col0 FROM tab0 AS cor0
----
-1155
-528
-7743

onlyif mysql # use DIV operator for integer division
query I rowsort label-9398
SELECT - cor0.col2 DIV - CAST( 74 + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9398
SELECT - cor0.col2 / - CAST ( 74 + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - tab2.col1 * + ( tab2.col0 ) AS col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col1 * tab0.col1 * - col0 AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL col0 - + col1 * - col2 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - col0 * + ( col1 ) * + col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + col0 + - tab1.col0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 - - 90 AS col1 FROM tab0
----
-1
-7
4

query I rowsort
SELECT ALL col0 - - ( + ( - col0 ) * + col1 ) FROM tab1
----
-576
-75
-960

query I rowsort
SELECT + - cor0.col0 * - col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT - col2 + 20 * + col1 AS col2 FROM tab2 AS cor0
----
1154
302
593

query I rowsort
SELECT - ( col0 ) * + col0 + - col1 FROM tab2 cor0
----
-6143
-6258
-80

query I rowsort
SELECT 4 * - col2 AS col1 FROM tab2
----
-104
-108
-152

query I rowsort
SELECT DISTINCT + - 25 + - col0 FROM tab1 AS cor0
----
-105
-28
-89

query I rowsort
SELECT - cor0.col1 - cor0.col1 * + col0 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT col1 * + ( 83 ) AS col0 FROM tab1
----
1079
2158
830

query I rowsort
SELECT ALL + - col2 * ( col1 ) AS col1 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9414
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9414
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL 77 + + col2 FROM tab2 AS cor0
----
103
104
115

query I rowsort
SELECT ALL + col2 * col2 + - col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT + cor1.col0 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
3
64
80

query I rowsort
SELECT ALL + 56 * col2 AS col2 FROM tab0
----
1848
4592
56

query I rowsort
SELECT DISTINCT + tab0.col2 * + col2 AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT 40 AS col2 FROM tab0
----
40
40
40

query I rowsort
SELECT col0 * tab0.col0 + - col2 * - tab0.col1 FROM tab0
----
1322
15383
3414

query I rowsort
SELECT ALL - col0 + 68 FROM tab0
----
-21
33
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-9423
SELECT DISTINCT ( col0 ) DIV col2 + + 34 FROM tab0
----
34
35
69

skipif mysql # not compatible
query I rowsort label-9423
SELECT DISTINCT ( col0 ) / col2 + + 34 FROM tab0
----
34
35
69

query I rowsort
SELECT DISTINCT - - ( - col2 ) + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - col1 * cor0.col1 + col1 - col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col2 * 82 AS col0 FROM tab1
----
4428
4674
7872

onlyif mysql # use DIV operator for integer division
query I rowsort label-9427
SELECT DISTINCT col0 + - cor0.col0 DIV col2 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-9427
SELECT DISTINCT col0 + - cor0.col0 / col2 FROM tab0 AS cor0
----
0
24
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9428
SELECT ALL + CAST( NULL AS SIGNED ) * cor0.col0 + col2 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-9428
SELECT ALL + CAST ( NULL AS INTEGER ) * cor0.col0 + col2 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 37 + col0 FROM tab1 cor0
----
-34
27
43

query I rowsort
SELECT + - 80 * cor0.col1 + 33 AS col1 FROM tab0 AS cor0
----
-6847
-7247
-7727

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-9432
SELECT ALL + 65 DIV cor0.col0 - col2 FROM tab0 AS cor0
----
-31
-82
0

skipif mysql # not compatible
query I rowsort label-9432
SELECT ALL + 65 / cor0.col0 - col2 FROM tab0 AS cor0
----
-31
-82
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9433
SELECT ALL + 87 * col0 + - ( cor0.col1 * col0 + + CAST( + col2 AS SIGNED ) ) FROM tab1 cor0
----
129
4871
5824

skipif mysql # not compatible
query I rowsort label-9433
SELECT ALL + 87 * col0 + - ( cor0.col1 * col0 + + CAST ( + col2 AS INTEGER ) ) FROM tab1 cor0
----
129
4871
5824

query I rowsort
SELECT + col2 * + cor0.col1 FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 + col0 * 6 col2 FROM tab0 AS cor0
----
-7252
-7747
-9199

query I rowsort
SELECT ALL + - col0 * col2 * + 90 FROM tab2 AS cor0
----
-17010
-182520
-270180

onlyif mysql # use DIV operator for integer division
query I rowsort label-9437
SELECT DISTINCT + col2 DIV col2 + col1 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-9437
SELECT DISTINCT + col2 / col2 + col1 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 59 col2 FROM tab0
----
141
60
92

query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - col1 * - col1 * 36 FROM tab1 AS cor0
----
24336
3600
6084

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 2 * - col0 col1 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + col0 + col2 + + col0 * col2 AS col1 FROM tab2 AS cor0
----
2132
223
3119

query I rowsort
SELECT DISTINCT - cor0.col1 * ( + col2 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - + col0 + 0 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT col1 * ( + 19 ) FROM tab2 AS cor0
----
1121
323
589

query I rowsort
SELECT + col0 + + ( col1 ) + col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT ALL col1 + 92 * 87 AS col0 FROM tab1
----
8014
8017
8030

query I rowsort
SELECT + col0 * - 11 + col0 AS col1 FROM tab0 AS cor0
----
-240
-350
-890

query I rowsort
SELECT + col0 + 96 FROM tab2 AS cor0
----
103
174
175

query I rowsort
SELECT DISTINCT - col2 * + ( cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - cor0.col1 + + ( + col1 ) AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - - col1 + + 64 FROM tab1 AS cor0
----
74
77
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 79 - + 45 col2 FROM tab2 AS cor0
----
1298
2404
4616

query I rowsort
SELECT - col2 * + 99 AS col1 FROM tab2 AS cor0
----
-2574
-2673
-3762

query I rowsort
SELECT DISTINCT - col1 + 39 FROM tab1 AS cor0
----
13
26
29

query I rowsort
SELECT + - col1 * 37 - + col1 FROM tab2 cor0
----
-1178
-2242
-646

onlyif mysql # use DIV operator for integer division
query I rowsort label-9457
SELECT DISTINCT + + col2 DIV col1 + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9457
SELECT DISTINCT + + col2 / col1 + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + col2 - + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * + ( - cor0.col1 ) + + col2 * - col0 FROM tab2 AS cor0
----
-1150
-3291
-5509

query I rowsort
SELECT DISTINCT - col1 + 2 + col0 AS col2 FROM tab0 cor0
----
-60
0

query I rowsort
SELECT 56 * + col0 + col1 FROM tab0 AS cor0
----
1430
2057
5075

query I rowsort
SELECT ALL - col1 * + col2 + + cor0.col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - + ( cor0.col0 ) + + col2 AS col1 FROM tab0 cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - 52 ) * - col1 + - cor0.col2 - col2 col0 FROM tab0 AS cor0
----
4406
4568
5042

query I rowsort
SELECT - col0 * 78 + ( tab2.col1 * - tab2.col1 ) AS col0 FROM tab2
----
-1507
-6451
-9565

query I rowsort
SELECT DISTINCT col0 + col2 * + col2 AS col2 FROM tab0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-9467
SELECT - - 80 + 17 * col1 DIV + col0 + - 92 FROM tab0 AS cor0
----
35
48
5

skipif mysql # not compatible
query I rowsort label-9467
SELECT - - 80 + 17 * col1 / + col0 + - 92 FROM tab0 AS cor0
----
35
48
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - 18 * - col1 col0 FROM tab0 AS cor0
----
1462
1547
1649

query I rowsort
SELECT ALL ( - col0 ) AS col2 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9470
SELECT DISTINCT - - CAST( - col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9470
SELECT DISTINCT - - CAST ( - col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT col2 + col0 - + col1 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT tab1.col1 + + 7 FROM tab1
----
17
20
33

query I rowsort
SELECT - 25 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

query I rowsort
SELECT - - ( + col0 ) - + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ( + col2 ) + + col2 * ( + col0 ) FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9476
SELECT + CAST( NULL AS DECIMAL ) * col1 + + col1 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9476
SELECT + CAST ( NULL AS REAL ) * col1 + + col1 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 94 AS col2 FROM tab1 AS cor0
----
-94
-94
-94

query I rowsort
SELECT + col0 + + col1 * ( + cor0.col2 ) * col0 + ( - 30 + - col0 ) * + col2 AS col0 FROM tab2 AS cor0
----
116922
46971
4867

query I rowsort
SELECT + col1 + + col2 - + col0 AS col1 FROM tab1 cor0
----
29
3
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-9480
SELECT - + cor0.col0 DIV - cor0.col0 AS col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9480
SELECT - + cor0.col0 / - cor0.col0 AS col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + ( - 92 ) FROM tab0, tab0 cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9482
SELECT - CAST( NULL AS SIGNED ) * - 66 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9482
SELECT - CAST ( NULL AS INTEGER ) * - 66 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9483
SELECT DISTINCT - - col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9483
SELECT DISTINCT - - col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col0 * - 4 * col0 FROM tab1 AS cor0
----
-16384
-25600
-36

query I rowsort
SELECT - 61 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c91d7b51e91f33d302e697913fb438b6

skipif mysql # not compatible
query I rowsort
SELECT + col1 * + CAST ( 12 AS REAL ) AS col1 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT - + col2 * + col1 - 16 AS col1 FROM tab0 AS cor0
----
-113
-2854
-7478

query I rowsort
SELECT col0 * col1 + + col0 AS col1 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT 67 - col2 AS col2 FROM tab2 AS cor0
----
29
40
41

query I rowsort
SELECT + + 87 AS col0 FROM tab1 cor0
----
87
87
87

query I rowsort
SELECT ALL + col1 - - 84 FROM tab2 cor0
----
101
115
143

query I rowsort
SELECT + col0 + - ( - cor0.col0 * col0 ) FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9494
SELECT cor0.col1 * CAST( NULL AS SIGNED ) * cor0.col1 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9494
SELECT cor0.col1 * CAST ( NULL AS INTEGER ) * cor0.col1 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * col1 + - col0 * col1 * col1 FROM tab1 AS cor0
----
-13689
-2704
-6500

query I rowsort
SELECT ALL col1 + 76 AS col2 FROM tab0 AS cor0
----
162
167
173

onlyif mysql # use DIV operator for integer division
query I rowsort label-9497
SELECT ALL - + cor0.col1 DIV - col1 + col1 * col2 FROM tab0 AS cor0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-9497
SELECT ALL - + cor0.col1 / - col1 + col1 * col2 FROM tab0 AS cor0
----
2839
7463
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9498
SELECT - - 29 DIV - 83 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9498
SELECT - - 29 / - 83 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - 28 * + 13 FROM tab2 AS cor0
----
364
364
364

query I rowsort
SELECT - + 26 + - 61 AS col0 FROM tab1 cor0
----
-87
-87
-87

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab2, tab2 cor0, tab2 AS cor1
----
-26
-27
-38

query I rowsort
SELECT + 43 * col1 AS col0 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT + ( - col2 ) * 2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL 66 + col2 * - col1 AS col2 FROM tab2 cor0
----
-1468
-580
-771

onlyif mysql # use DIV operator for integer division
query I rowsort label-9505
SELECT ALL + 63 DIV + col2 AS col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9505
SELECT ALL + 63 / + col2 AS col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT ALL 72 * col2 + + ( col2 * cor0.col0 + 7 ) FROM tab1 cor0
----
14599
4057
7759

query I rowsort
SELECT DISTINCT + 68 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1768
680
884

query I rowsort
SELECT DISTINCT + + 77 + col2 AS col2 FROM tab2 AS cor0
----
103
104
115

query I rowsort
SELECT ALL cor0.col2 + cor0.col2 * col1 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-9510
SELECT ALL ( 85 ) DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9510
SELECT ALL ( 85 ) / col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9511
SELECT col2 DIV col2 + ( col2 ) * + col0 FROM tab0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-9511
SELECT col2 / col2 + ( col2 ) * + col0 FROM tab0
----
36
7299
793

query I rowsort
SELECT 40 * + col2 + + col2 FROM tab2
----
1066
1107
1558

query I rowsort
SELECT + col1 * - tab1.col1 + + col0 * - 40 FROM tab1
----
-2660
-3369
-796

query I rowsort
SELECT - 34 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 5b88331e40da4796cc4826c442aa45f7

query I rowsort
SELECT 25 + col2 - col2 FROM tab1
----
25
25
25

query I rowsort
SELECT DISTINCT col1 * col1 - + col0 AS col1 FROM tab0
----
7372
8192
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT 27 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT 81 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT col0 * 15 FROM tab1
----
1200
45
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9521
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + col2 * col1 AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9521
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + col2 * col1 AS col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 + - col2 * col1 + col2 FROM tab0 AS cor0
----
-2772
-7298
-95

query I rowsort
SELECT cor0.col0 + 81 * + col0 * - 85 AS col2 FROM tab2 AS cor0
----
-48188
-536952
-543836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 19 col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT ALL col1 * 64 * + tab0.col1 + col2 + 27 FROM tab0
----
473404
530093
602204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 63 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT ALL - col1 + + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT ALL col0 + + col1 + - col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - ( col0 ) + col2 + - col0 * 63 AS col2 FROM tab0 AS cor0
----
-1503
-2239
-5614

query I rowsort
SELECT DISTINCT + - 40 * - col0 + cor0.col2 FROM tab0 AS cor0
----
1401
3642
993

query I rowsort
SELECT DISTINCT + col1 + - 86 FROM tab1 AS cor0
----
-60
-73
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9532
SELECT + CAST( + col2 AS SIGNED ) DIV - cor0.col0 + ( col2 ) * col1 AS col2 FROM tab0 AS cor0
----
2837
7462
97

skipif mysql # not compatible
query I rowsort label-9532
SELECT + CAST ( + col2 AS INTEGER ) / - cor0.col0 + ( col2 ) * col1 AS col2 FROM tab0 AS cor0
----
2837
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9533
SELECT CAST( + col1 AS SIGNED ) * + col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-9533
SELECT CAST ( + col1 AS INTEGER ) * + col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT 94 + - tab0.col1 FROM tab0
----
-3
3
8

query I rowsort
SELECT DISTINCT + 76 + + col2 AS col0 FROM tab2
----
102
103
114

query I rowsort
SELECT DISTINCT - col2 * - cor0.col2 + col0 FROM tab2 AS cor0
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-9537
SELECT ALL + col0 DIV + cor0.col1 + 65 AS col2 FROM tab2 AS cor0
----
65
66
69

skipif mysql # not compatible
query I rowsort label-9537
SELECT ALL + col0 / + cor0.col1 + 65 AS col2 FROM tab2 AS cor0
----
65
66
69

query I rowsort
SELECT col2 + - 90 * col2 * col1 AS col0 FROM tab0 AS cor0
----
-255387
-671498
-8729

query I rowsort
SELECT - col2 * + col2 + + 71 FROM tab1 AS cor0
----
-2845
-3178
-9145

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9540
SELECT 84 * col0 - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9540
SELECT 84 * col0 - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * tab0.col0 + col2 * col0 - col0 * - col2 AS col0 FROM tab0
----
22695
3465
3648

query I rowsort
SELECT ALL tab2.col1 + - col1 + - ( - tab2.col1 * tab2.col1 ) FROM tab2
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9543
SELECT ALL cor0.col0 + - CAST( - col1 * col0 AS SIGNED ) + + col0 FROM tab2 AS cor0
----
1501
231
4758

skipif mysql # not compatible
query I rowsort label-9543
SELECT ALL cor0.col0 + - CAST ( - col1 * col0 AS INTEGER ) + + col0 FROM tab2 AS cor0
----
1501
231
4758

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 DISTINCT - col0 * + cor0.col2 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-9547
SELECT - col2 + + 29 DIV cor0.col1 AS col0 FROM tab1 cor0
----
-53
-55
-94

skipif mysql # not compatible
query I rowsort label-9547
SELECT - col2 + + 29 / cor0.col1 AS col0 FROM tab1 cor0
----
-53
-55
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-9548
SELECT ALL + col2 DIV - col0 AS col1 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-9548
SELECT ALL + col2 / - col0 AS col1 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT col2 + - ( + col1 ) AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - cor0.col0 + col0 * - 16 AS col1 FROM tab0 AS cor0
----
-1513
-408
-595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9551
SELECT - + cor0.col0 * + CAST( NULL AS SIGNED ) + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9551
SELECT - + cor0.col0 * + CAST ( NULL AS INTEGER ) + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9552
SELECT + col1 DIV + col0 + col0 AS col0 FROM tab2 cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-9552
SELECT + col1 / + col0 + col0 AS col0 FROM tab2 cor0
----
11
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9553
SELECT ALL + col2 + - CAST( - 70 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
108
96
97

skipif mysql # not compatible
query I rowsort label-9553
SELECT ALL + col2 + - CAST ( - 70 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
108
96
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9554
SELECT - - col0 + - 63 DIV - 25 AS col1 FROM tab2 AS cor0
----
80
81
9

skipif mysql # not compatible
query I rowsort label-9554
SELECT - - col0 + - 63 / - 25 AS col1 FROM tab2 AS cor0
----
80
81
9

query I rowsort
SELECT - + col0 * + 70 FROM tab1 cor0
----
-210
-4480
-5600

query I rowsort
SELECT DISTINCT + + cor0.col2 + - ( + col1 ) AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT cor0.col1 * - ( cor0.col1 ) FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL 68 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9559
SELECT ALL - CAST( + ( + col0 ) AS SIGNED ) + 98 FROM tab0 AS cor0
----
63
74
9

skipif mysql # not compatible
query I rowsort label-9559
SELECT ALL - CAST ( + ( + col0 ) AS INTEGER ) + 98 FROM tab0 AS cor0
----
63
74
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9560
SELECT ALL CAST( col1 AS SIGNED ) + col2 FROM tab2 cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-9560
SELECT ALL CAST ( col1 AS INTEGER ) + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT + ( + col0 ) * - col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT 16 - + col2 FROM tab1 AS cor0
----
-38
-41
-80

query I rowsort
SELECT ALL + 78 * + cor0.col1 + - col2 * + 18 - col2 AS col0 FROM tab2 AS cor0
----
1905
4108
604

query I rowsort
SELECT DISTINCT + col0 * col0 + - col2 * + col1 + - col1 FROM tab2 AS cor0
----
-819
4491
5578

query I rowsort
SELECT ( - 77 ) + col1 FROM tab0 AS cor0
----
14
20
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9566
SELECT DISTINCT + - 46 * - cor0.col0 * col1 + 85 DIV col1 AS col1 FROM tab2 AS cor0
----
211693
61783
9984

skipif mysql # not compatible
query I rowsort label-9566
SELECT DISTINCT + - 46 * - cor0.col0 * col1 + 85 / col1 AS col1 FROM tab2 AS cor0
----
211693
61783
9984

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col0 * col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL col1 * col0 + + 86 * - col1 * + cor0.col0 FROM tab2 AS cor0
----
-114155
-18445
-391170

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9569
SELECT - - ( col1 ) * - CAST( - 61 AS SIGNED ) + col2 AS col0 FROM tab2 AS cor0
----
1075
1918
3625

skipif mysql # not compatible
query I rowsort label-9569
SELECT - - ( col1 ) * - CAST ( - 61 AS INTEGER ) + col2 AS col0 FROM tab2 AS cor0
----
1075
1918
3625

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + + col1 col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - - cor0.col0 + - col2 * col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT + cor0.col1 + - col0 * ( - col2 ) AS col2 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT 0 * col1 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9574
SELECT - tab0.col2 DIV 72 AS col1 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9574
SELECT - tab0.col2 / 72 AS col1 FROM tab0
----
-1
0
0

query I rowsort
SELECT ALL + col0 + - col2 * col1 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-9576
SELECT + 57 * col0 DIV - 86 + 58 FROM tab0 AS cor0
----
0
35
43

skipif mysql # not compatible
query I rowsort label-9576
SELECT + 57 * col0 / - 86 + 58 FROM tab0 AS cor0
----
0
35
43

query I rowsort
SELECT ALL + 96 AS col1 FROM tab0 cor0
----
96
96
96

query I rowsort
SELECT DISTINCT + + col2 + + col1 + 72 FROM tab0 AS cor0
----
170
191
245

query I rowsort
SELECT DISTINCT + - col2 + + col2 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL + - 2 * + col1 * - col1 AS col0 FROM tab2 AS cor0
----
1922
578
6962

onlyif mysql # use DIV operator for integer division
query I rowsort label-9581
SELECT DISTINCT 38 DIV col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9581
SELECT DISTINCT 38 / col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - col0 + + cor0.col0 * col0 AS col1 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT - + ( col0 ) * cor0.col2 AS col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT - cor0.col1 + col0 * col2 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + cor0.col2 + col2 * - col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + + cor0.col0 + col2 - col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1430
-529
-803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 * col2 col2 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-9588
SELECT - col0 + cor0.col1 DIV col0 AS col1 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-9588
SELECT - col0 + cor0.col1 / col0 AS col1 FROM tab1 AS cor0
----
-64
-80
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9589
SELECT col1 + - col0 DIV cor0.col1 col2 FROM tab2 AS cor0
----
13
31
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9589
SELECT col1 + - col0 / cor0.col1 col2 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT - col2 + col1 * + col0 + col2 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL 54 * tab1.col0 + col2 AS col0 FROM tab1
----
216
3513
4416

query I rowsort
SELECT + 60 * - col0 + + col0 + col0 FROM tab1
----
-174
-3712
-4640

query I rowsort
SELECT ALL - ( + 6 ) + col0 + col0 AS col1 FROM tab2 cor0
----
150
152
8

query I rowsort
SELECT + col0 * + 26 FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT + 44 * + col2 + + col0 AS col1 FROM tab0 AS cor0
----
1476
3697
79

query I rowsort
SELECT ALL - ( + col0 + + tab1.col0 ) FROM tab1
----
-128
-160
-6

query I rowsort
SELECT + col1 + + ( + col0 * + col1 ) AS col0 FROM tab2
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-9598
SELECT ALL col1 * + col1 DIV col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9598
SELECT ALL col1 * + col1 / col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + col1 * - col1 + col0 AS col0 FROM tab1 cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT ( + ( col1 ) ) * col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + cor0.col1 + + col0 * + col2 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL + 55 + 71 FROM tab0, tab1 AS cor0
----
9 values hashing to 19b1f1fcc466c23e5267b585248665fc

query I rowsort
SELECT ALL + - col1 + - 77 AS col0 FROM tab2 AS cor0
----
-108
-136
-94

query I rowsort
SELECT + ( + 76 ) + cor0.col2 FROM tab1 AS cor0
----
130
133
172

query I rowsort
SELECT 35 * 36 + - col0 - tab0.col2 FROM tab0
----
1089
1203
1224

query I rowsort
SELECT col2 + - 35 - - col2 AS col2 FROM tab1
----
157
73
79

query I rowsort
SELECT - 41 * + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 0c5286f9f9ae3e8e7d5b2c1cf69b5514

onlyif mysql # use DIV operator for integer division
query I rowsort label-9608
SELECT DISTINCT + + ( - col0 ) DIV col2 + CAST( col0 AS SIGNED ) + + col1 FROM tab0 AS cor0
----
110
179
97

skipif mysql # not compatible
query I rowsort label-9608
SELECT DISTINCT + + ( - col0 ) / col2 + CAST ( col0 AS INTEGER ) + + col1 FROM tab0 AS cor0
----
110
179
97

query I rowsort
SELECT col2 + col1 * + col1 FROM tab1 AS cor0
----
157
265
730

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + - col1 + + col1 * col1 AS col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT ( + col2 ) + + 11 * col1 FROM tab2 AS cor0
----
225
368
675

query I rowsort
SELECT + + col2 * + 8 FROM tab0 AS cor0
----
264
656
8

query I rowsort
SELECT DISTINCT - col2 * + 83 + col2 * col1 AS col1 FROM tab0 AS cor0
----
14
656
99

query I rowsort
SELECT + col0 * cor0.col1 + + 86 FROM tab1 AS cor0
----
1126
164
726

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 65 col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4ca93c42a91c7dff917e7b7090ba9e57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9617
SELECT ALL + col2 - + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9617
SELECT ALL + col2 - + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col1 - + col2 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT col2 * 15 * + cor0.col2 + + cor0.col1 AS col0 FROM tab1 cor0
----
138253
43766
48745

query I rowsort
SELECT + col0 * - 22 AS col0 FROM tab1 AS cor0
----
-1408
-1760
-66

query I rowsort
SELECT - ( 94 ) AS col1 FROM tab0 AS cor0
----
-94
-94
-94

query I rowsort
SELECT DISTINCT 87 AS col1 FROM tab1, tab0 cor0
----
87

query I rowsort
SELECT + col0 * col1 * col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + + 57 AS col0 FROM tab2 AS cor0
----
57

query I rowsort
SELECT DISTINCT + - 97 AS col2 FROM tab2 AS cor0
----
-97

query I rowsort
SELECT + 42 * + ( + cor0.col2 ) AS col0 FROM tab2 AS cor0
----
1092
1134
1596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( cor0.col0 ) * + col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 64 + - col2 * 16 AS col1 FROM tab0 cor0
----
-1248
-464
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + cor0.col1 * col1 col0 FROM tab0 AS cor0
----
7420
8370
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + col1 col1 FROM tab2 AS cor0
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * cor0.col0 - col2 * 2 col2 FROM tab0 AS cor0
----
1223
510
7757

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 8 * + col0 col1 FROM tab1 AS cor0
----
24
512
640

onlyif mysql # use DIV operator for integer division
query I rowsort label-9633
SELECT col2 * col0 DIV - tab1.col2 AS col0 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-9633
SELECT col2 * col0 / - tab1.col2 AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT col0 * col0 * col1 AS col0 FROM tab0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-9635
SELECT - tab0.col1 DIV 91 FROM tab0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9635
SELECT - tab0.col1 / 91 FROM tab0
----
-1
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9636
SELECT DISTINCT - 74 DIV col2 AS col1 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-9636
SELECT DISTINCT - 74 / col2 AS col1 FROM tab1
----
-1
0

query I rowsort
SELECT ALL 88 * - tab1.col2 AS col0 FROM tab1
----
-4752
-5016
-8448

query I rowsort
SELECT DISTINCT - 70 FROM tab2, tab1 cor0
----
-70

query I rowsort
SELECT 81 + col1 FROM tab1 cor0
----
107
91
94

query I rowsort
SELECT 49 + - col0 * 30 AS col1 FROM tab1 AS cor0
----
-1871
-2351
-41

query I rowsort
SELECT - col2 + col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - cor0.col2 + col2 * - 60 * + col1 FROM tab0 AS cor0
----
-170313
-447802
-5821

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 * col1 col1 FROM tab0 AS cor0
----
3612
3822
4074

onlyif mysql # use DIV operator for integer division
query I rowsort label-9644
SELECT DISTINCT 98 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-9644
SELECT DISTINCT 98 / - col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 74 + - col1 col0 FROM tab2 AS cor0
----
-105
-133
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-9646
SELECT ALL ( col2 ) DIV col0 AS col2 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-9646
SELECT ALL ( col2 ) / col0 AS col2 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT ALL - + 27 AS col0 FROM tab1 AS cor0
----
-27
-27
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col0 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT cor0.col0 * 48 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 6578d42c04016ce7b6b2efe85e72e9ca

query I rowsort
SELECT col0 + - 0 AS col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9651
SELECT + col0 - CAST( NULL AS SIGNED ) * 59 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9651
SELECT + col0 - CAST ( NULL AS INTEGER ) * 59 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9652
SELECT ALL CAST( NULL AS SIGNED ) FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9652
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - cor0.col0 * + ( + col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - - 79 * - 82 AS col0 FROM tab1 AS cor0
----
-6478

query I rowsort
SELECT ALL + + 40 * + col2 FROM tab1 cor0
----
2160
2280
3840

query I rowsort
SELECT + cor0.col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9657
SELECT ALL + col1 DIV - col0 + + cor0.col1 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-9657
SELECT ALL + col1 / - col0 + + cor0.col1 FROM tab2 AS cor0
----
17
27
59

query I rowsort
SELECT - 76 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT - tab2.col2 + 67 FROM tab2, tab1, tab1 cor0
----
27 values hashing to cba4fac109972066583930fe134f9b3d

query I rowsort
SELECT DISTINCT ( 53 ) AS col1 FROM tab0, tab2 AS cor0
----
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-9661
SELECT ALL ( - tab2.col2 ) DIV col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-9661
SELECT ALL ( - tab2.col2 ) / col0 FROM tab2
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 * + col1 col1 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT - - ( 50 ) AS col0 FROM tab2 AS cor0
----
50
50
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 3 * - col0 col1 FROM tab2 cor0
----
21
234
237

query I rowsort
SELECT + 33 * 61 * col0 AS col2 FROM tab1 AS cor0
----
128832
161040
6039

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 91 col0 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT ALL + + 30 * col0 AS col2 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 * col0 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-9669
SELECT DISTINCT 97 + - 63 + col2 DIV ( col2 * col2 + + ( 42 ) ) AS col0 FROM tab2 AS cor0
----
34

skipif mysql # not compatible
query I rowsort label-9669
SELECT DISTINCT 97 + - 63 + col2 / ( col2 * col2 + + ( 42 ) ) AS col0 FROM tab2 AS cor0
----
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9670
SELECT ALL + ( col2 ) DIV + cor0.col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9670
SELECT ALL + ( col2 ) / + cor0.col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL 82 + col2 FROM tab0 AS cor0
----
115
164
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + col0 * cor0.col2 col0 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-9673
SELECT ( - col0 ) + - col0 DIV + ( - 38 ) AS col2 FROM tab0
----
-24
-35
-87

skipif mysql # not compatible
query I rowsort label-9673
SELECT ( - col0 ) + - col0 / + ( - 38 ) AS col2 FROM tab0
----
-24
-35
-87

query I rowsort
SELECT ALL cor0.col1 + ( col2 + - ( col0 ) ) FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT ALL + - 56 + + col1 FROM tab1 AS cor0
----
-30
-43
-46

query I rowsort
SELECT 61 * - col2 * 52 AS col1 FROM tab0 AS cor0
----
-104676
-260104
-3172

query I rowsort
SELECT + - cor0.col1 + - cor0.col0 * + 8 AS col0 FROM tab1 AS cor0
----
-50
-522
-653

query I rowsort
SELECT ALL + col1 * + ( - ( col0 ) + cor0.col0 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9679
SELECT ALL - col2 + - CAST( + ( col2 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-164
-2
-66

skipif mysql # not compatible
query I rowsort label-9679
SELECT ALL - col2 + - CAST ( + ( col2 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT col0 - ( col1 + col0 * 26 ) FROM tab1 AS cor0
----
-101
-1610
-2013

query I rowsort
SELECT + col1 * col1 + 45 FROM tab0 cor0
----
7441
8326
9454

query I rowsort
SELECT + col0 * + ( 63 ) AS col2 FROM tab0 AS cor0
----
1512
2205
5607

query I rowsort
SELECT col1 * + col0 - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL col1 * 57 + + col2 * + col0 FROM tab0 AS cor0
----
12485
5564
5694

query I rowsort
SELECT - - col2 * col2 + + col2 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT ALL - cor1.col2 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col2 AS REAL ) + col1 * - cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
-244035
-678960
-9408

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9688
SELECT - + cor0.col1 + - cor1.col0 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9688
SELECT - + cor0.col1 + - cor1.col0 * CAST ( NULL AS REAL ) FROM tab1 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 cor0.col2 * - cor0.col2 col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9690
SELECT CAST( 6 AS SIGNED ) FROM tab0 AS cor0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-9690
SELECT CAST ( 6 AS INTEGER ) FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT + col0 * col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT - + col2 + 60 * + col2 AS col2 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT ALL - 14 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c2bf0e2420d22cd58d7ee3b30827afcc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 18 * - tab2.col1 * - 59 col2 FROM tab2
----
-18054
-32922
-62658

query I rowsort
SELECT - + col1 * 49 + 75 FROM tab0 AS cor0
----
-4139
-4384
-4678

query I rowsort
SELECT DISTINCT col1 * + ( 30 ) FROM tab1
----
300
390
780

query I rowsort
SELECT - 72 * col2 FROM tab1 AS cor0
----
-3888
-4104
-6912

query I rowsort
SELECT ALL - 59 + - 19 AS col2 FROM tab0 AS cor0
----
-78
-78
-78

query I rowsort
SELECT - cor0.col2 * cor0.col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col2 * - cor0.col0 * + col1 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + 98 FROM tab2, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL cor0.col1 * + col2 * col0 + col2 FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT 20 - - cor1.col0 FROM tab2, tab0 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to 13e44269c706f321325ea88ceeeb7441

query I rowsort
SELECT + 76 AS col2 FROM tab1, tab2 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to a8a6c4c5005303c62d4e50b6c96b584f

query I rowsort
SELECT - tab2.col1 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL - ( + col1 ) * 13 + + 16 FROM tab1
----
-114
-153
-322

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9707
SELECT - - ( col2 ) + CAST( + 41 AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
1298
2445
735

skipif mysql # not compatible
query I rowsort label-9707
SELECT - - ( col2 ) + CAST ( + 41 AS INTEGER ) * col1 AS col0 FROM tab2 AS cor0
----
1298
2445
735

query I rowsort
SELECT + - col2 * col1 * col0 + ( + col1 ) AS col0 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT + col0 + col1 * + 34 FROM tab1 AS cor0
----
404
522
887

query I rowsort
SELECT - 21 + cor0.col0 FROM tab2 cor0
----
-14
57
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9711
SELECT - col2 + col2 / - CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9711
SELECT - col2 + col2 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col2 ) * - 65 + col0 * + col1 AS col2 FROM tab0
----
-81
2769
3330

query I rowsort
SELECT DISTINCT - 79 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-9714
SELECT col1 * + col1 * ( col1 * + col2 ) - col1 DIV - tab0.col2 col1 FROM tab0
----
20989850
61792823
912770

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9714
SELECT col1 * + col1 * ( col1 * + col2 ) - col1 / - tab0.col2 col1 FROM tab0
----
20989850
61792823
912770

query I rowsort
SELECT + col0 * col2 + cor0.col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-9716
SELECT ALL col0 DIV - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9716
SELECT ALL col0 / - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT - 81 + - cor0.col1 FROM tab2 AS cor0
----
-112
-140
-98

query I rowsort
SELECT + 35 * + col1 * + 73 - cor0.col2 AS col1 FROM tab1 AS cor0
----
25493
33119
66376

query I rowsort
SELECT DISTINCT + + 88 + - col2 AS col2 FROM tab0 AS cor0
----
55
6
87

query I rowsort
SELECT - col1 * col2 * - col1 + col0 FROM tab0
----
244092
679131
9444

query I rowsort
SELECT - 15 + col0 * ( + 32 ) AS col2 FROM tab2
----
209
2481
2513

query I rowsort
SELECT ALL col1 * - col0 * col2 + - col1 * ( 3 ) FROM tab1 cor0
----
-36510
-4290
-99879

query I rowsort
SELECT ALL - - col1 * ( col2 ) + col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-9724
SELECT DISTINCT - col2 + cor0.col1 DIV + col1 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-9724
SELECT DISTINCT - col2 + cor0.col1 / + col1 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT 24 + + tab0.col0 AS col1 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to a9e482dece05f30620d3cc84c954d103

query I rowsort
SELECT DISTINCT - + cor0.col1 AS col2 FROM tab0, tab1, tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ( ( cor0.col1 ) ) FROM tab0, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - col1 * - ( col2 ) AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT tab1.col2 * ( - col2 ) FROM tab1
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + 39 * col0 col2 FROM tab2 AS cor0
----
300
3068
3119

query I rowsort
SELECT DISTINCT + + col2 * 26 + + col2 * + col0 FROM tab2 cor0
----
2704
3990
891

query I rowsort
SELECT + col0 + 76 AS col0 FROM tab0 AS cor0
----
100
111
165

query I rowsort
SELECT ALL - 62 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT col1 * + 25 + col1 FROM tab1 AS cor0
----
260
338
676

query I rowsort
SELECT ALL col2 * 79 + - cor0.col2 FROM tab2 AS cor0
----
2028
2106
2964

query I rowsort
SELECT - col2 * + cor0.col2 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9737
SELECT DISTINCT col0 + CAST( NULL AS DECIMAL ) * col2 * - cor0.col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9737
SELECT DISTINCT col0 + CAST ( NULL AS REAL ) * col2 * - cor0.col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9738
SELECT - + col2 DIV col0 + - col1 * + col2 * col2 FROM tab0 AS cor0
----
-611884
-93655
-97

skipif mysql # not compatible
query I rowsort label-9738
SELECT - + col2 / col0 + - col1 * + col2 * col2 FROM tab0 AS cor0
----
-611884
-93655
-97

query I rowsort
SELECT ALL col1 + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT 87 + - col1 * - col2 AS col0 FROM tab2 AS cor0
----
1621
733
924

query I rowsort
SELECT col2 + col2 * - cor0.col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL ( col1 ) * 79 - 56 * col0 * ( + 74 ) AS col0 FROM tab0 AS cor0
----
-137377
-361627
-92662

query I rowsort
SELECT DISTINCT - - 35 * - col0 FROM tab1 AS cor0
----
-105
-2240
-2800

query I rowsort
SELECT + - 53 - + col2 AS col2 FROM tab2 AS cor0
----
-79
-80
-91

query I rowsort
SELECT 92 + + col0 FROM tab0 cor0
----
116
127
181

query I rowsort
SELECT col0 * col1 + ( + col2 ) * col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT - ( col2 ) + + ( col1 ) * + cor0.col2 AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT 59 + + col0 * - col1 * + col1 + + col0 FROM tab0 AS cor0
----
-177421
-329221
-736861

query I rowsort
SELECT ALL - col2 - col0 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - col0 * - col2 + + ( - 40 * + col1 + - col1 ) AS col1 FROM tab0 AS cor0
----
-2734
-3942
3567

query I rowsort
SELECT DISTINCT - + col1 + col0 AS col2 FROM tab1 cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * + col2 * col0 col1 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT - ( - 7 ) + + col0 * col2 AS col2 FROM tab0
----
42
7305
799

query I rowsort
SELECT + + col1 * 78 FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT - 34 * + tab0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 81ff281b7c5bcd3dfae5965f0ddfe422

query I rowsort
SELECT ALL col1 * col2 * col0 FROM tab2
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9757
SELECT ALL + cor0.col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9757
SELECT ALL + cor0.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 - - col2 * cor0.col0 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col1 + + col2 * col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + ( col1 ) * + col1 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9761
SELECT - CAST( NULL AS SIGNED ) * - ( col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9761
SELECT - CAST ( NULL AS INTEGER ) * - ( col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col0 * + 44 + - cor0.col2 - + cor0.col2 AS col0 FROM tab2 AS cor0
----
-3484
-3552
-362

query I rowsort
SELECT DISTINCT + ( - col2 ) + col2 AS col2 FROM tab2 cor0
----
0

query I rowsort
SELECT + - ( 12 ) FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT ALL - col0 * + cor0.col2 - col1 AS col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT + col2 + ( 54 ) FROM tab0
----
136
55
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * cor0.col2 col1 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT ( col2 ) * + cor0.col2 + - col2 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-9769
SELECT DISTINCT + + 65 + + col0 DIV col0 AS col1 FROM tab2 AS cor0
----
66

skipif mysql # not compatible
query I rowsort label-9769
SELECT DISTINCT + + 65 + + col0 / col0 AS col1 FROM tab2 AS cor0
----
66

query I rowsort
SELECT + cor0.col2 * col2 + col1 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-9771
SELECT DISTINCT - 83 + + col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
-82

skipif mysql # not compatible
query I rowsort label-9771
SELECT DISTINCT - 83 + + col1 / + col1 AS col1 FROM tab2 AS cor0
----
-82

query I rowsort
SELECT + 81 * col1 AS col2 FROM tab1 AS cor0
----
1053
2106
810

query I rowsort
SELECT DISTINCT - ( + ( + col0 ) ) + - ( - 56 ) * col2 FROM tab0
----
1824
21
4503

onlyif mysql # use DIV operator for integer division
query I rowsort label-9774
SELECT ALL - col1 + col1 DIV col0 col2 FROM tab1 AS cor0
----
-10
-13
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9774
SELECT ALL - col1 + col1 / col0 col2 FROM tab1 AS cor0
----
-10
-13
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 + col1 col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + - 92 * - col1 FROM tab1 cor0
----
1196
2392
920

query I rowsort
SELECT cor0.col0 * - col1 + 36 * - col0 FROM tab2 AS cor0
----
-4187
-469
-7410

query I rowsort
SELECT col0 * + 17 AS col1 FROM tab1
----
1088
1360
51

query I rowsort
SELECT + 25 * tab1.col1 AS col2 FROM tab1
----
250
325
650

query I rowsort
SELECT 3 + col2 AS col2 FROM tab1
----
57
60
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9781
SELECT DISTINCT - - col2 DIV col1 AS col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-9781
SELECT DISTINCT - - col2 / col1 AS col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL - col1 * - cor0.col2 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col0 * 88 AS col2 FROM tab1 AS cor0
----
264
5632
7040

query I rowsort
SELECT col0 + + col1 * + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT + col2 * col2 * col0 + + col2 AS col1 FROM tab0
----
26169
36
598518

query I rowsort
SELECT 30 * col1 FROM tab1
----
300
390
780

query I rowsort
SELECT DISTINCT 37 * col1 AS col0 FROM tab1
----
370
481
962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9788
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9788
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT 97 * + tab2.col1 FROM tab2
----
1649
3007
5723

query I rowsort
SELECT ALL - col2 * + ( - col2 + + col0 ) AS col2 FROM tab1
----
-399
1536
2754

query I rowsort
SELECT - col0 + - 1 * ( - col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + + cor0.col0 + ( 1 ) AS col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT + - col1 + col2 + + 58 FROM tab2 AS cor0
----
25
54
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-9794
SELECT - + col1 DIV ( - col0 + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9794
SELECT - + col1 / ( - col0 + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 5 col1 FROM tab1
----
270
285
480

query I rowsort
SELECT ALL col2 + col1 * col0 AS col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-9797
SELECT - cor0.col2 + col2 DIV + 46 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-9797
SELECT - cor0.col2 + col2 / + 46 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + + cor0.col0 * col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 1 FROM tab2, tab2 cor0 CROSS JOIN tab1, tab1 AS cor1
----
81 values hashing to 2a004dce2d308bae163576f54ee1a3fc

query I rowsort
SELECT DISTINCT - 36 AS col0 FROM tab2, tab1 AS cor0
----
-36

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT + col2 * + 76 + cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
146
2556
6410

onlyif mysql # use DIV operator for integer division
query I rowsort label-9803
SELECT col1 + + 88 DIV + cor0.col1 FROM tab2 cor0
----
22
33
60

skipif mysql # not compatible
query I rowsort label-9803
SELECT col1 + + 88 / + cor0.col1 FROM tab2 cor0
----
22
33
60

query I rowsort
SELECT DISTINCT cor0.col1 + + col0 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - 65 * col1 - cor0.col2 FROM tab2 AS cor0
----
-1143
-2042
-3861

onlyif mysql # use DIV operator for integer division
query I rowsort label-9806
SELECT DISTINCT + CAST( col2 AS SIGNED ) + col0 DIV - ( col0 ) AS col1 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-9806
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + col0 / - ( col0 ) AS col1 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT ALL - + col0 * + col0 * - cor0.col2 + col0 FROM tab1 cor0
----
233536
489
614480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9808
SELECT ALL - col1 + - col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9808
SELECT ALL - col1 + - col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 9 * col2 AS col0 FROM tab0
----
297
738
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9810
SELECT 70 DIV col2 col2 FROM tab0
----
0
2
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9810
SELECT 70 / col2 col2 FROM tab0
----
0
2
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9811
SELECT + 36 DIV col1 + 65 FROM tab0 AS cor0
----
65
65
65

skipif mysql # not compatible
query I rowsort label-9811
SELECT + 36 / col1 + 65 FROM tab0 AS cor0
----
65
65
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - + col0 * cor0.col0 col1 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT - 63 + 69 FROM tab2 AS cor0
----
6
6
6

query I rowsort
SELECT 98 - + col0 AS col2 FROM tab2
----
19
20
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - ( + col1 ) * + 51 col0 FROM tab0
----
-4300
-4550
-4850

query I rowsort
SELECT + col1 * 98 + col2 * col1 * col0 FROM tab0 AS cor0
----
12901
673036
76540

query I rowsort
SELECT col2 * + ( + col2 ) * + 67 FROM tab2 AS cor0
----
45292
48843
96748

query I rowsort
SELECT ALL + col1 + 89 AS col2 FROM tab0 AS cor0
----
175
180
186

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + col1 * col0 col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT - col2 - - cor0.col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - col2 + col0 * 84 AS col1 FROM tab2 cor0
----
561
6526
6598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 + 77 col0 FROM tab2 AS cor0
----
115
173
214

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9823
SELECT col0 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9823
SELECT col0 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * 10 + col1 + - col0 FROM tab2 AS cor0
----
241
294
318

query I rowsort
SELECT cor0.col0 * 3 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 643559ac626975360fee96de89aa95ee

query I rowsort
SELECT + tab1.col0 * tab1.col0 * col0 AS col1 FROM tab1
----
262144
27
512000

query I rowsort
SELECT ALL - 96 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to c89b545346f99713888a7934e4caa539

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9828
SELECT + col0 * CAST( NULL AS SIGNED ) * ( - col0 * tab1.col0 ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9828
SELECT + col0 * CAST ( NULL AS INTEGER ) * ( - col0 * tab1.col0 ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 * + col1 AS col0 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9830
SELECT ALL col0 DIV - 72 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9830
SELECT ALL col0 / - 72 FROM tab1
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9831
SELECT + col2 + col0 DIV ( col0 * + 17 ) AS col0 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9831
SELECT + col2 + col0 / ( col0 * + 17 ) AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL 13 * ( - col0 ) FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT ALL col1 * col1 * + col0 + - col2 FROM tab1 AS cor0
----
13424
1974
6343

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9834
SELECT DISTINCT - CAST( 6 * - col2 AS SIGNED ) + ( 70 * tab2.col0 + - col0 ) AS col1 FROM tab2
----
5538
5679
645

skipif mysql # not compatible
query I rowsort label-9834
SELECT DISTINCT - CAST ( 6 * - col2 AS INTEGER ) + ( 70 * tab2.col0 + - col0 ) AS col1 FROM tab2
----
5538
5679
645

query I rowsort
SELECT ( + col2 * col2 ) + + col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT DISTINCT - col2 * col0 * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9837
SELECT col2 * ( - cor0.col2 ) + + CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9837
SELECT col2 * ( - cor0.col2 ) + + CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + - 47 + + col0 AS col2 FROM tab1 AS cor0
----
-41
113
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 74 * 15 + + col1 * col2 col0 FROM tab1 cor0
----
1680
2358
2514

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 + 34 col1 FROM tab1 cor0
----
21
24
8

query I rowsort
SELECT - + 33 + col2 FROM tab2 AS cor0
----
-6
-7
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9842
SELECT 75 + - col0 * ( col1 ) DIV col2 AS col1 FROM tab0
----
-23
-3320
13

skipif mysql # not compatible
query I rowsort label-9842
SELECT 75 + - col0 * ( col1 ) / col2 AS col1 FROM tab0
----
-23
-3320
13

query I rowsort
SELECT DISTINCT - col2 + - cor0.col1 + 51 FROM tab1 cor0
----
-16
-29
-58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9844
SELECT ALL + + col2 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9844
SELECT ALL + + col2 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col0 + - ( col2 ) AS col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9846
SELECT ALL + - col1 DIV ( + ( col1 ) ) - col0 * col0 FROM tab2 AS cor0
----
-50
-6085
-6242

skipif mysql # not compatible
query I rowsort label-9846
SELECT ALL + - col1 / ( + ( col1 ) ) - col0 * col0 FROM tab2 AS cor0
----
-50
-6085
-6242

query I rowsort
SELECT DISTINCT col1 + 85 AS col2 FROM tab1 cor0
----
111
95
98

query I rowsort
SELECT + col0 * + ( - cor0.col1 * + col0 ) AS col1 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT + cor0.col1 * col1 + col1 * - cor0.col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
4591
901
9313

query I rowsort
SELECT ALL + + col1 - - cor0.col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT cor0.col2 + - col2 * - 91 AS col0 FROM tab1 AS cor0
----
4968
5244
8832

query I rowsort
SELECT - ( - col0 ) + + col2 AS col1 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL 69 FROM tab0, tab0 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT ALL + tab1.col2 * + col1 AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL 72 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # use DIV operator for integer division
query I rowsort label-9856
SELECT ALL col2 * col0 DIV + 16 FROM tab2
----
11
126
187

skipif mysql # not compatible
query I rowsort label-9856
SELECT ALL col2 * col0 / + 16 FROM tab2
----
11
126
187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9857
SELECT CAST( NULL AS SIGNED ) + + 15 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9857
SELECT CAST ( NULL AS INTEGER ) + + 15 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT col2 + + col0 * + 17 + + 33 FROM tab0 cor0
----
1628
474
629

query I rowsort
SELECT 41 + col1 FROM tab2 AS cor0
----
100
58
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-9860
SELECT DISTINCT 37 DIV 28 col1 FROM tab0, tab0 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9860
SELECT DISTINCT 37 / 28 col1 FROM tab0, tab0 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9861
SELECT ALL col2 DIV col1 + col0 AS col1 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-9861
SELECT ALL col2 / col1 + col0 AS col1 FROM tab1
----
5
69
87

query I rowsort
SELECT ALL tab2.col0 + + col1 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT col0 + col2 * - col0 AS col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL col2 * + col0 + - col2 * col2 * + col2 FROM tab2 AS cor0
----
-15548
-19494
-51870

query I rowsort
SELECT DISTINCT col2 * ( cor0.col1 ) + cor0.col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT col0 * ( col2 ) * + col2 + - 10 AS col0 FROM tab0 AS cor0
----
25
26126
598426

query I rowsort
SELECT ALL col1 + col1 * + 82 FROM tab1 AS cor0
----
1079
2158
830

query I rowsort
SELECT DISTINCT - + col2 + cor0.col1 * col1 * + col0 FROM tab0 AS cor0
----
177471
329314
736927

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col0 + - 82 col1 FROM tab2 AS cor0
----
-3
-4
-75

query I rowsort
SELECT ALL - col0 + 24 * + col1 * + 93 FROM tab0 AS cor0
----
191928
203023
216469

onlyif mysql # use DIV operator for integer division
query I rowsort label-9871
SELECT DISTINCT + + 67 DIV + 16 FROM tab2 AS cor0
----
4

skipif mysql # not compatible
query I rowsort label-9871
SELECT DISTINCT + + 67 / + 16 FROM tab2 AS cor0
----
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-9872
SELECT ALL - col0 DIV + cor0.col0 + col1 * col2 * col1 col2 FROM tab1 cor0
----
16223
36503
5699

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9872
SELECT ALL - col0 / + cor0.col0 + col1 * col2 * col1 col2 FROM tab1 cor0
----
16223
36503
5699

query I rowsort
SELECT + + col0 - - 53 FROM tab1 AS cor0
----
117
133
56

query I rowsort
SELECT DISTINCT + ( col0 ) + - col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - ( 32 ) * - cor0.col0 + - col1 AS col2 FROM tab0 AS cor0
----
1023
2757
682

onlyif mysql # use DIV operator for integer division
query I rowsort label-9876
SELECT + col0 * cor0.col0 + col2 DIV + 43 FROM tab0 AS cor0
----
1225
576
7922

skipif mysql # not compatible
query I rowsort label-9876
SELECT + col0 * cor0.col0 + col2 / + 43 FROM tab0 AS cor0
----
1225
576
7922

query I rowsort
SELECT ALL + 95 + 17 AS col2 FROM tab0 cor0
----
112
112
112

query I rowsort
SELECT ALL + ( col1 ) * - col2 * col0 + cor0.col0 AS col1 FROM tab1 cor0
----
-36416
-4209
-99760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9879
SELECT ALL tab0.col2 DIV + col1 + col2 * col1 FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-9879
SELECT ALL tab0.col2 / + col1 + col2 * col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col2 + - tab0.col0 + col2 FROM tab0
----
-33
42
75

skipif mysql # not compatible
query I rowsort
SELECT - col2 * - ( + ( col0 ) * - CAST ( ( col0 ) AS REAL ) ) AS col2 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-9882
SELECT - - ( - col0 ) + col1 * 49 DIV - col0 AS col2 FROM tab2 AS cor0
----
-115
-224
-89

skipif mysql # not compatible
query I rowsort label-9882
SELECT - - ( - col0 ) + col1 * 49 / - col0 AS col2 FROM tab2 AS cor0
----
-115
-224
-89

query I rowsort
SELECT + 39 * + 48 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
1792
1808
1869

query I rowsort
SELECT col0 + - col0 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - col0 * + 15 + col1 AS col0 FROM tab2 AS cor0
----
-1111
-1168
-74

query I rowsort
SELECT DISTINCT + ( 24 ) FROM tab2
----
24

query I rowsort
SELECT tab0.col1 * ( col2 ) * - col1 AS col1 FROM tab0
----
-244068
-679042
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9888
SELECT - CAST( 4 AS SIGNED ) + col0 FROM tab2 AS cor0
----
3
74
75

skipif mysql # not compatible
query I rowsort label-9888
SELECT - CAST ( 4 AS INTEGER ) + col0 FROM tab2 AS cor0
----
3
74
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-9889
SELECT - 91 * col2 + + col2 DIV col0 FROM tab0 AS cor0
----
-3002
-7462
-91

skipif mysql # not compatible
query I rowsort label-9889
SELECT - 91 * col2 + + col2 / col0 FROM tab0 AS cor0
----
-3002
-7462
-91

query I rowsort
SELECT + - 35 - + col2 * + col0 FROM tab1 AS cor0
----
-197
-3683
-7715

onlyif mysql # use DIV operator for integer division
query I rowsort label-9891
SELECT ALL - cor0.col2 + col2 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-32
-82

skipif mysql # not compatible
query I rowsort label-9891
SELECT ALL - cor0.col2 + col2 / col0 AS col1 FROM tab0 AS cor0
----
-1
-32
-82

query I rowsort
SELECT 73 + ( col0 * col0 ) FROM tab0
----
1298
649
7994

query I rowsort
SELECT cor0.col2 + - col0 * + col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT col2 * + col1 + col0 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT 6 + cor0.col2 AS col0 FROM tab2, tab1 AS cor0
----
102
60
63

query I rowsort
SELECT ( + 8 ) * + tab0.col1 FROM tab0
----
688
728
776

query I rowsort
SELECT + ( ( col2 ) ) FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9898
SELECT + col0 DIV - ( cor0.col0 + - col2 ) AS col0 FROM tab0 cor0
----
-1
-12
2

skipif mysql # not compatible
query I rowsort label-9898
SELECT + col0 / - ( cor0.col0 + - col2 ) AS col0 FROM tab0 cor0
----
-1
-12
2

query I rowsort
SELECT + + col1 * + 60 FROM tab2 AS cor0
----
1020
1860
3540

query I rowsort
SELECT DISTINCT + col0 * col0 * + col2 AS col0 FROM tab0
----
1225
19008
649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-9901
SELECT - col1 + col1 DIV 73 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-9901
SELECT - col1 + col1 / 73 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9902
SELECT DISTINCT + 16 DIV + col0 AS col0 FROM tab1
----
0
5

skipif mysql # not compatible
query I rowsort label-9902
SELECT DISTINCT + 16 / + col0 AS col0 FROM tab1
----
0
5

query I rowsort
SELECT DISTINCT - col0 * - 9 AS col1 FROM tab2
----
63
702
711

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col0 + col1 col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - 48 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

query I rowsort
SELECT ALL + col2 + - 5 FROM tab0 AS cor0
----
-4
28
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 - + 13 col0 FROM tab1 cor0
----
-23
-26
-39

query I rowsort
SELECT DISTINCT col1 * 4 FROM tab2 AS cor0
----
124
236
68

query I rowsort
SELECT DISTINCT 61 - - col2 FROM tab0
----
143
62
94

query I rowsort
SELECT ( col1 ) + + ( + col1 ) + - col2 AS col1 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT + col1 * + col0 + 2 FROM tab0 AS cor0
----
2066
3397
8101

query I rowsort
SELECT ( + col0 ) AS col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT col2 - - col1 * ( + 8 ) * - tab0.col0 FROM tab0
----
-16479
-27159
-64710

query I rowsort
SELECT DISTINCT + col2 * + col2 - + ( + col2 ) * tab0.col2 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 * col1 - 14 col1 FROM tab2
----
-1548
-660
-851

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-9917
SELECT DISTINCT + + col2 * + col2 * + col0 + - col1 DIV - 81 AS col1 FROM tab2 AS cor0
----
114076
5103
52728

skipif mysql # not compatible
query I rowsort label-9917
SELECT DISTINCT + + col2 * + col2 * + col0 + - col1 / - 81 AS col1 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + - col1 * - 97 + col1 * col1 FROM tab1 AS cor0
----
1070
1430
3198

query I rowsort
SELECT ALL col1 + 92 AS col2 FROM tab2 AS cor0
----
109
123
151

query I rowsort
SELECT DISTINCT col1 + - 25 FROM tab0
----
61
66
72

query I rowsort
SELECT - col1 + col0 + 52 * col1 FROM tab2 AS cor0
----
1588
3087
946

query I rowsort
SELECT - col1 + 78 FROM tab2 AS cor0
----
19
47
61

query I rowsort
SELECT DISTINCT cor0.col2 * 11 FROM tab0 AS cor0
----
11
363
902

query I rowsort
SELECT - col2 - - col0 * - col1 AS col1 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT - 19 + col2 AS col0 FROM tab1
----
35
38
77

query I rowsort
SELECT ( - col2 * col1 + - ( ( col2 ) ) ) AS col1 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT + 12 + col0 FROM tab2
----
19
90
91

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
3645 values hashing to 5acb69cde71208fe580e10b8b669428e

query I rowsort
SELECT DISTINCT + - 26 * + col0 + col2 FROM tab0 AS cor0
----
-2232
-591
-909

query I rowsort
SELECT ALL ( + col0 ) - col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ( col2 ) * col2 + col1 AS col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT 36 + - 76 * col0 AS col1 FROM tab1 cor0
----
-192
-4828
-6044

onlyif mysql # use DIV operator for integer division
query I rowsort label-9933
SELECT DISTINCT - 98 + - col2 + 56 DIV 89 AS col2 FROM tab1 cor0
----
-152
-155
-194

skipif mysql # not compatible
query I rowsort label-9933
SELECT DISTINCT - 98 + - col2 + 56 / 89 AS col2 FROM tab1 cor0
----
-152
-155
-194

query I rowsort
SELECT DISTINCT - col0 * col0 + 3 * col0 AS col2 FROM tab2 AS cor0
----
-28
-5850
-6004

query I rowsort
SELECT DISTINCT cor1.col0 AS col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
3
64
80

query I rowsort
SELECT ALL - + 93 * - col1 + 63 FROM tab0 AS cor0
----
8061
8526
9084

query I rowsort
SELECT 91 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

query I rowsort
SELECT DISTINCT - + col2 * col2 + 98 FROM tab1 AS cor0
----
-2818
-3151
-9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-9939
SELECT DISTINCT + col1 DIV - cor0.col2 FROM tab0 cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-9939
SELECT DISTINCT + col1 / - cor0.col2 FROM tab0 cor0
----
-1
-2
-97

query I rowsort
SELECT ALL + 58 * - col2 FROM tab0 AS cor0
----
-1914
-4756
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + - col0 col1 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT + col0 * cor0.col0 AS col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL col1 * - col1 + + 40 - - col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1907
-84
397

query I rowsort
SELECT ALL col0 * + col2 - 35 FROM tab0 AS cor0
----
0
7263
757

query I rowsort
SELECT ALL + + cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT 59 * col2 + + ( ( col1 ) ) FROM tab0 AS cor0
----
156
2033
4929

query I rowsort
SELECT DISTINCT - 55 * col1 FROM tab1 AS cor0
----
-1430
-550
-715

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9948
SELECT - ( - col0 ) + CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-9948
SELECT - ( - col0 ) + CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9949
SELECT ALL + 25 + + col1 * col1 DIV - cor0.col0 FROM tab0 AS cor0
----
-243
-283
-68

skipif mysql # not compatible
query I rowsort label-9949
SELECT ALL + 25 + + col1 * col1 / - cor0.col0 FROM tab0 AS cor0
----
-243
-283
-68

query I rowsort
SELECT DISTINCT - col0 + + col1 + - col0 FROM tab0 AS cor0
----
-87
27
38

query I rowsort
SELECT DISTINCT 28 + + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2888
-3221
-9188

onlyif mysql # use DIV operator for integer division
query I rowsort label-9952
SELECT DISTINCT 0 DIV + col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9952
SELECT DISTINCT 0 / + col0 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9953
SELECT + 5 DIV col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9953
SELECT + 5 / col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 + + col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT 43 * col0 FROM tab2 cor0
----
301
3354
3397

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9956
SELECT - + col2 * CAST( - col1 AS SIGNED ) + + col1 * ( + 86 ) AS col2 FROM tab1 AS cor0
----
1430
2366
3640

skipif mysql # not compatible
query I rowsort label-9956
SELECT - + col2 * CAST ( - col1 AS INTEGER ) + + col1 * ( + 86 ) AS col2 FROM tab1 AS cor0
----
1430
2366
3640

onlyif mysql # use DIV operator for integer division
query I rowsort label-9957
SELECT + col2 DIV ( - 13 ) - - col1 DIV + cor0.col1 FROM tab1 AS cor0
----
-3
-3
-6

skipif mysql # not compatible
query I rowsort label-9957
SELECT + col2 / ( - 13 ) - - col1 / + cor0.col1 FROM tab1 AS cor0
----
-3
-3
-6

query I rowsort
SELECT DISTINCT + col2 * - 18 * 97 + - col1 AS col0 FROM tab1 cor0
----
-167629
-94310
-99532

query I rowsort
SELECT col0 + - cor0.col2 * - col1 AS col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL - 83 AS col0 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT ALL - 65 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

query I rowsort
SELECT ALL - - 66 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT ALL + col1 + ( col1 ) FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT - 91 * + 80 FROM tab2 AS cor0
----
-7280
-7280
-7280

query I rowsort
SELECT + col2 - col2 * 83 FROM tab1
----
-4428
-4674
-7872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9966
SELECT ALL - CAST( + 63 AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

skipif mysql # not compatible
query I rowsort label-9966
SELECT ALL - CAST ( + 63 AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

query I rowsort
SELECT - col1 * - 33 + + col0 * + ( col0 ) AS col1 FROM tab2
----
1072
6802
8031

onlyif mysql # use DIV operator for integer division
query I rowsort label-9968
SELECT ALL + 99 DIV col0 col1 FROM tab1
----
1
1
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9968
SELECT ALL + 99 / col0 col1 FROM tab1
----
1
1
33

query I rowsort
SELECT 12 - + col0 * - col0 AS col0 FROM tab0
----
1237
588
7933

query I rowsort
SELECT ALL 55 * col2 FROM tab0
----
1815
4510
55

query I rowsort
SELECT DISTINCT + ( - 51 ) FROM tab1 AS cor0
----
-51

query I rowsort
SELECT DISTINCT + col1 + - col2 AS col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ( + col1 ) * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9974
SELECT + col0 DIV col2 + - col1 AS col0 FROM tab1 cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-9974
SELECT + col0 / col2 + - col1 AS col0 FROM tab1 cor0
----
-13
-26
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9975
SELECT ALL - CAST( 8 AS SIGNED ) FROM tab0 AS cor0
----
-8
-8
-8

skipif mysql # not compatible
query I rowsort label-9975
SELECT ALL - CAST ( 8 AS INTEGER ) FROM tab0 AS cor0
----
-8
-8
-8

query I rowsort
SELECT - col2 + 36 * - col2 FROM tab2 AS cor0
----
-1406
-962
-999

query I rowsort
SELECT ALL - 12 FROM tab2 cor0
----
-12
-12
-12

query I rowsort
SELECT ALL - cor0.col0 * 98 + col2 FROM tab2 AS cor0
----
-659
-7618
-7704

query I rowsort
SELECT - cor0.col2 * + 99 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 29b3fa96d93d79314d1570c39f48afee

query I rowsort
SELECT - - 99 + col0 * - col0 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1127
-510
-7904

onlyif mysql # use DIV operator for integer division
query I rowsort label-9981
SELECT - ( col1 ) DIV - col0 + + col1 col0 FROM tab2
----
17
35
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9981
SELECT - ( col1 ) / - col0 + + col1 col0 FROM tab2
----
17
35
59

query I rowsort
SELECT col0 * + ( - tab2.col1 ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - 72 * cor0.col0 * - 64 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5de628144496911a48faa6ad0f5f42f9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9984
SELECT + col0 DIV ( col2 * - cor0.col2 ) + cor0.col0 FROM tab0 AS cor0
----
0
24
89

skipif mysql # not compatible
query I rowsort label-9984
SELECT + col0 / ( col2 * - cor0.col2 ) + cor0.col0 FROM tab0 AS cor0
----
0
24
89

query I rowsort
SELECT DISTINCT + 25 + col2 FROM tab2 AS cor0
----
51
52
63

query I rowsort
SELECT ( - 46 ) FROM tab1 AS cor0
----
-46
-46
-46

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) + col1 * + ( col0 ) FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9988
SELECT + CAST( NULL AS SIGNED ) + - 71 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9988
SELECT + CAST ( NULL AS INTEGER ) + - 71 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col1 * - tab1.col2 col1 FROM tab1
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-9990
SELECT ALL 94 DIV col1 FROM tab2
----
1
3
5

skipif mysql # not compatible
query I rowsort label-9990
SELECT ALL 94 / col1 FROM tab2
----
1
3
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9991
SELECT 97 + + col1 DIV 25 AS col2 FROM tab1
----
97
97
98

skipif mysql # not compatible
query I rowsort label-9991
SELECT 97 + + col1 / 25 AS col2 FROM tab1
----
97
97
98

query I rowsort
SELECT ALL - + col0 * - col1 + col0 * col0 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT ALL + 85 + col0 * + 15 AS col0 FROM tab0 AS cor0
----
1420
445
610

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9994
SELECT ALL CAST( NULL AS SIGNED ) + - 23 col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9994
SELECT ALL CAST ( NULL AS INTEGER ) + - 23 col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9995
SELECT + - cor0.col1 DIV - 67 + ( col0 ) * - col2 + cor0.col2 * col0 * col1 FROM tab2 AS cor0
----
117624
48032
5670

skipif mysql # not compatible
query I rowsort label-9995
SELECT + - cor0.col1 / - 67 + ( col0 ) * - col2 + cor0.col2 * col0 * col1 FROM tab2 AS cor0
----
117624
48032
5670

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9996
SELECT - cor0.col0 * + CAST( + col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-9996
SELECT - cor0.col0 * + CAST ( + col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT col2 * - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT + col2 - + col2 * ( + col1 ) FROM tab1 AS cor0
----
-1152
-1350
-513

