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 DISTINCT + cor0.col0 + - col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

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

query IIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0 WHERE NOT ( NULL ) < NULL
----

query I rowsort
SELECT ALL + col1 * col2 - col1 AS col0 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4
SELECT DISTINCT - col2 DIV + col0 FROM tab2 cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-4
SELECT DISTINCT - col2 / + col0 FROM tab2 cor0
----
-3
0

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-7
SELECT col2 DIV col2 + col2 * + col0 FROM tab0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-7
SELECT col2 / col2 + col2 * + col0 FROM tab0
----
36
7299
793

query I rowsort
SELECT - col2 * + col0 + col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

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

query I rowsort
SELECT DISTINCT 45 + 5 FROM tab0
----
50

query I rowsort
SELECT - 70 * col0 FROM tab2 AS cor0
----
-490
-5460
-5530

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

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

query I rowsort
SELECT DISTINCT + ( - 4 ) + col1 AS col1 FROM tab0 cor0
----
82
87
93

query I rowsort
SELECT + col2 * + col0 + - col2 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT + 58 * + 1 FROM tab0 cor0
----
58

query I rowsort
SELECT + - 42 + col2 * col2 AS col1 FROM tab1 AS cor0
----
2874
3207
9174

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

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

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

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

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

query I rowsort
SELECT - + 40 * - cor0.col1 FROM tab1 AS cor0
----
1040
400
520

query I rowsort
SELECT DISTINCT - 90 * col1 AS col0 FROM tab0 AS cor0
----
-7740
-8190
-8730

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 55 + col1 * + col2 * - col0 col1 FROM tab1
----
-36535
-4267
-99895

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

query I rowsort
SELECT + 52 * col0 + col1 FROM tab1
----
182
3338
4173

query I rowsort
SELECT col1 * + 91 * - col0 + col0 FROM tab0
----
-187800
-308910
-736920

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

query I rowsort
SELECT - + 14 * col0 AS col2 FROM tab0 AS cor0
----
-1246
-336
-490

query I rowsort
SELECT col0 * 1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - col0 * 37 AS col1 FROM tab0 AS cor0
----
-1295
-3293
-888

query I rowsort
SELECT - col1 + - 84 * - col1 FROM tab2 AS cor0
----
1411
2573
4897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col2 ) col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-37
SELECT - + col1 * col2 + - CAST( col1 AS SIGNED ) * col0 + cor0.col1 FROM tab0 AS cor0
----
-15470
-3395
-4816

skipif mysql # not compatible
query I rowsort label-37
SELECT - + col1 * col2 + - CAST ( col1 AS INTEGER ) * col0 + cor0.col1 FROM tab0 AS cor0
----
-15470
-3395
-4816

query I rowsort
SELECT - col0 * - col1 + + 39 FROM tab1 cor0
----
1079
117
679

query I rowsort
SELECT + 63 * + col0 + - 9 * col1 AS col1 FROM tab1 AS cor0
----
-45
3942
4923

query I rowsort
SELECT - + col1 * col2 + - col2 + col0 AS col0 FROM tab0 AS cor0
----
-2847
-63
-7455

query I rowsort
SELECT DISTINCT + col2 * col1 + col1 FROM tab0
----
194
2924
7553

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-43
SELECT DISTINCT col1 * CAST ( - col1 AS INTEGER ) col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL col1 + + 52 * col0 FROM tab0 AS cor0
----
1334
1917
4719

query I rowsort
SELECT cor0.col2 * 89 FROM tab0 AS cor0
----
2937
7298
89

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 + + cor0.col0 FROM tab2 AS cor0
----
-1365
-598
-722

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

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

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

skipif mysql # not compatible
query I rowsort label-48
SELECT ALL - cor0.col2 + col2 / cor0.col0 FROM tab0 AS cor0
----
-1
-32
-82

query I rowsort
SELECT ALL - + col0 * 98 + + col0 FROM tab2 AS cor0
----
-679
-7566
-7663

query I rowsort
SELECT ALL + col0 * 17 FROM tab2 AS cor0
----
119
1326
1343

query I rowsort
SELECT + + col1 + col2 * - 40 AS col1 FROM tab2 AS cor0
----
-1049
-1503
-981

query I rowsort
SELECT + - col2 * 81 FROM tab2 cor0
----
-2106
-2187
-3078

query I rowsort
SELECT col2 * 92 AS col0 FROM tab2 AS cor0
----
2392
2484
3496

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

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

query I rowsort
SELECT + - 6 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
-516
-546
-582

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

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

query I rowsort
SELECT + 92 * + 8 AS col1 FROM tab2 AS cor0
----
736
736
736

query I rowsort
SELECT 21 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

onlyif mysql # use DIV operator for integer division
query I rowsort label-60
SELECT DISTINCT col0 DIV 24 AS col1 FROM tab1
----
0
2
3

skipif mysql # not compatible
query I rowsort label-60
SELECT DISTINCT col0 / 24 AS col1 FROM tab1
----
0
2
3

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

query I rowsort
SELECT + - col1 + + ( + ( col1 ) ) * 90 AS col0 FROM tab0 AS cor0
----
7654
8099
8633

query I rowsort
SELECT col0 * - 30 AS col1 FROM tab2
----
-210
-2340
-2370

query I rowsort
SELECT ALL 74 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

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

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

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

skipif mysql # not compatible
query I rowsort label-67
SELECT + - col2 / + cor0.col0 FROM tab2 cor0
----
-3
0
0

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

query I rowsort
SELECT DISTINCT - 57 * col2 FROM tab0 cor0
----
-1881
-4674
-57

query I rowsort
SELECT ALL + 37 + col1 * + 72 AS col1 FROM tab0 AS cor0
----
6229
6589
7021

query I rowsort
SELECT DISTINCT - col2 * + 95 * 4 AS col2 FROM tab2 AS cor0
----
-10260
-14440
-9880

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

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

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

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

query I rowsort
SELECT ALL + - col0 * 38 AS col0 FROM tab1 AS cor0
----
-114
-2432
-3040

query I rowsort
SELECT ( 95 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ALL col1 * 28 AS col2 FROM tab0 AS cor0
----
2408
2548
2716

onlyif mysql # use DIV operator for integer division
query I rowsort label-77
SELECT + col0 + col0 DIV + 99 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-77
SELECT + col0 + col0 / + 99 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col0 * - col0 * - 9 + - 69 * + col2 FROM tab2
----
-1422
52962
53547

query I rowsort
SELECT DISTINCT 8 * col0 * - col1 AS col2 FROM tab2
----
-10744
-1736
-36816

query I rowsort
SELECT 38 * + cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5761c011b99f43354c9b5d8144389f2e

query I rowsort
SELECT DISTINCT - 57 + col2 FROM tab2 cor0
----
-19
-30
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-82
SELECT + col0 * col0 + col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
49
6084
6239

skipif mysql # not compatible
query I rowsort label-82
SELECT + col0 * col0 + col2 / - col1 AS col2 FROM tab2 AS cor0
----
49
6084
6239

query I rowsort
SELECT DISTINCT + + 4 * col2 + col1 AS col0 FROM tab0 AS cor0
----
101
218
419

query I rowsort
SELECT - - ( col2 ) + col2 AS col1 FROM tab2 AS cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - 17 FROM tab1, tab1 cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 60 col0 FROM tab1 AS cor0
----
-3240
-3420
-5760

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-90
SELECT col0 DIV tab2.col1 - col2 * - ( - 53 ) AS col2 FROM tab2
----
-1377
-1431
-2010

skipif mysql # not compatible
query I rowsort label-90
SELECT col0 / tab2.col1 - col2 * - ( - 53 ) AS col2 FROM tab2
----
-1377
-1431
-2010

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-91
SELECT DISTINCT col2 + col0 + col2 / CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + ( 45 ) AS col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
45

query I rowsort
SELECT + + 92 + col1 * 26 FROM tab1 cor0
----
352
430
768

query I rowsort
SELECT - - 9 * col2 + + ( col2 + col0 * ( 9 ) ) FROM tab1 AS cor0
----
1146
1680
567

query I rowsort
SELECT DISTINCT - - 40 + + cor0.col2 + col0 FROM tab2 AS cor0
----
144
157
74

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-99
SELECT ALL CAST ( NULL AS INTEGER ) + col2 col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 8 * - cor0.col2 FROM tab2, tab1 AS cor0
----
432
456
768

query I rowsort
SELECT 95 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 9896fbc7c98abe84cb585e6f5f25b58a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 37 + col2 col2 FROM tab2 AS cor0
----
63
64
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-103
SELECT + cor0.col2 DIV - col0 + 92 AS col2 FROM tab2 cor0
----
89
92
92

skipif mysql # not compatible
query I rowsort label-103
SELECT + cor0.col2 / - col0 + 92 AS col2 FROM tab2 cor0
----
89
92
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col1 + + 7 col0 FROM tab1 AS cor0
----
-1241
-1397
-563

query I rowsort
SELECT ALL - 19 * col2 FROM tab1 AS cor0
----
-1026
-1083
-1824

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

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

query I rowsort
SELECT - col2 - col0 * - col2 AS col1 FROM tab1
----
108
3591
7584

query I rowsort
SELECT ALL + tab0.col1 * + ( - col1 ) + col0 * - col1 - col2 * + col1 AS col2 FROM tab0
----
-12298
-12901
-23842

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - 65 col1 FROM tab1
----
-1
-62
15

query I rowsort
SELECT - 7 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT - col0 + - 51 * + ( + cor0.col1 ) FROM tab2 cor0
----
-1588
-3087
-946

query I rowsort
SELECT col2 * 90 AS col1 FROM tab1
----
4860
5130
8640

query I rowsort
SELECT ALL - cor0.col2 * col0 * + cor0.col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

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

query I rowsort
SELECT col2 * - ( + cor0.col1 * col0 + 63 ) FROM tab1 AS cor0
----
-105888
-40071
-7614

query I rowsort
SELECT ALL 7 * cor0.col0 FROM tab1 AS cor0
----
21
448
560

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

query I rowsort
SELECT ALL - - col2 * 87 FROM tab2 AS cor0
----
2262
2349
3306

onlyif mysql # use DIV operator for integer division
query I rowsort label-119
SELECT + col2 - col0 * cor0.col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-119
SELECT + col2 - col0 * cor0.col0 / col0 AS col2 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + 7 AS REAL ) + tab2.col1 FROM tab2
----
10
24
52

query I rowsort
SELECT DISTINCT + col0 + 58 * + col1 AS col2 FROM tab1 AS cor0
----
1511
644
834

onlyif mysql # use DIV operator for integer division
query I rowsort label-122
SELECT ALL + - 78 DIV + 50 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-122
SELECT ALL + - 78 / + 50 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT + + 41 + - col0 AS col0 FROM tab1 AS cor0
----
-23
-39
38

query I rowsort
SELECT DISTINCT - 92 - + cor0.col1 FROM tab0 AS cor0
----
-178
-183
-189

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

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

query I rowsort
SELECT ALL + ( 73 ) + + col1 * ( + 72 ) FROM tab1 cor0
----
1009
1945
793

query I rowsort
SELECT 95 - + 25 FROM tab2 AS cor0
----
70
70
70

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

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

query I rowsort
SELECT ALL + + ( - 13 ) FROM tab0 cor0
----
-13
-13
-13

query I rowsort
SELECT ALL + ( 77 ) + - col1 FROM tab2 AS cor0
----
18
46
60

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

query I rowsort
SELECT ALL - + 81 * col1 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-2103
-746
-973

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-135
SELECT + - col2 * col0 - - col1 DIV 61 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-135
SELECT + - col2 * col0 - - col1 / 61 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col2 + + col0 * + col0 FROM tab2 AS cor0
----
6110
6279
76

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

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col1 AS REAL ) FROM tab2
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * - ( col1 ) + - ( - col2 ) * col1 * col0 col0 FROM tab2 AS cor0
----
116171
4898
50745

query I rowsort
SELECT ALL + ( + col0 ) * cor0.col0 + col1 * - col1 * + col1 + 61 * + col2 AS col0 FROM tab1 AS cor0
----
-14273
10059
6573

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

query I rowsort
SELECT ALL + ( + col2 + - col2 ) * col2 * + ( + col2 ) AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT 13 + col0 * + col2 AS col2 FROM tab0 AS cor0
----
48
7311
805

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-145
SELECT - - col0 + col0 * - CAST( 8 AS SIGNED ) FROM tab1 AS cor0
----
-21
-448
-560

skipif mysql # not compatible
query I rowsort label-145
SELECT - - col0 + col0 * - CAST ( 8 AS INTEGER ) FROM tab1 AS cor0
----
-21
-448
-560

query I rowsort
SELECT DISTINCT + + col1 * - col0 - - col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + + col2 * - cor0.col2 - + col0 AS col1 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ALL + ( col2 ) * - col2 * + col1 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL + 60 * col1 + - 65 * col0 AS col2 FROM tab1 AS cor0
----
-3560
-4420
1365

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

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

query I rowsort
SELECT DISTINCT + + 95 * - col0 FROM tab2 cor0
----
-665
-7410
-7505

query I rowsort
SELECT + 84 * + cor0.col0 FROM tab0 cor0
----
2016
2940
7476

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

query I rowsort
SELECT DISTINCT col0 * col2 * col0 + col2 + col2 FROM tab1
----
233586
594
614592

query I rowsort
SELECT DISTINCT - col0 * - col0 + col1 * col1 FROM tab0
----
10634
16202
7972

query I rowsort
SELECT + tab2.col1 * - 42 FROM tab2, tab2 cor0
----
9 values hashing to b0dd598a332ff5c5f8ca6ee003e9edd5

query I rowsort
SELECT DISTINCT col1 + - col1 * 18 AS col2 FROM tab0
----
-1462
-1547
-1649

query I rowsort
SELECT col2 - col2 * + col0 AS col0 FROM tab2
----
-162
-2002
-2964

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

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

query I rowsort
SELECT ALL + col2 * + 53 AS col0 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL - col0 * - 94 FROM tab2 cor0
----
658
7332
7426

query I rowsort
SELECT ALL + col1 + col0 * 35 FROM tab0 cor0
----
1322
3206
926

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * 51 col1 FROM tab1 AS cor0
----
2754
2907
4896

query I rowsort
SELECT DISTINCT 85 * + col2 FROM tab0
----
2805
6970
85

query I rowsort
SELECT cor0.col1 + col1 + col0 AS col2 FROM tab1 AS cor0
----
106
55
84

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

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

skipif mysql # not compatible
query I rowsort label-169
SELECT + + 83 / + col2 AS col0 FROM tab0 AS cor0
----
1
2
83

query I rowsort
SELECT - - ( + col0 ) + col0 - col2 FROM tab0 cor0
----
15
69
96

query I rowsort
SELECT col2 * col1 * + 40 FROM tab0
----
113520
298480
3880

onlyif mysql # use DIV operator for integer division
query I rowsort label-172
SELECT col2 + - col2 DIV 36 + + tab0.col1 DIV col0 FROM tab0
----
3
36
81

skipif mysql # not compatible
query I rowsort label-172
SELECT col2 + - col2 / 36 + + tab0.col1 / col0 FROM tab0
----
3
36
81

query I rowsort
SELECT + + 4 + - 2 AS col2 FROM tab1 AS cor0
----
2
2
2

query I rowsort
SELECT - - 53 * 9 + col0 - - cor0.col1 AS col1 FROM tab1 AS cor0
----
506
551
570

query I rowsort
SELECT DISTINCT + + col2 * 60 AS col2 FROM tab0 AS cor0
----
1980
4920
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-176
SELECT DISTINCT - 35 DIV + col0 AS col0 FROM tab1
----
-11
0

skipif mysql # not compatible
query I rowsort label-176
SELECT DISTINCT - 35 / + col0 AS col0 FROM tab1
----
-11
0

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 * - col0 col1 FROM tab1 cor0
----
-233472
-486
-614400

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

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

skipif mysql # not compatible
query I rowsort label-180
SELECT DISTINCT - tab0.col1 / tab0.col2 FROM tab0, tab0 AS cor0
----
-1
-2
-97

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0 CROSS JOIN tab1 WHERE ( NULL ) = NULL
----

query I rowsort
SELECT ALL + col1 + 25 FROM tab1
----
35
38
51

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

query I rowsort
SELECT DISTINCT col2 + 56 AS col2 FROM tab1
----
110
113
152

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

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

query I rowsort
SELECT DISTINCT 18 + col2 + col0 FROM tab1 cor0
----
139
194
75

query I rowsort
SELECT col1 * + ( + col1 ) * col1 AS col0 FROM tab1
----
1000
17576
2197

query I rowsort
SELECT + tab1.col1 + ( 55 ) AS col1 FROM tab1
----
65
68
81

query I rowsort
SELECT 75 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT tab2.col1 + + ( - 89 ) * + col2 FROM tab2
----
-2255
-2372
-3365

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-193
SELECT ALL + CAST( NULL AS SIGNED ) * ( col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

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

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

skipif mysql # not compatible
query I rowsort label-194
SELECT DISTINCT + - col0 / 90 + col2 AS col0 FROM tab1 cor0
----
54
57
96

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

query I rowsort
SELECT - 41 + - col2 FROM tab2 AS cor0
----
-67
-68
-79

query I rowsort
SELECT ALL - + col2 * 62 + - cor0.col1 + col2 FROM tab0 cor0
----
-158
-2099
-5093

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

query I rowsort
SELECT ALL + col2 * 46 + cor0.col2 * ( col1 ) AS col0 FROM tab0 AS cor0
----
11234
143
4356

query I rowsort
SELECT DISTINCT + - col0 - 78 AS col2 FROM tab0 AS cor0
----
-102
-113
-167

query I rowsort
SELECT ALL - 26 + col2 FROM tab2 AS cor0
----
0
1
12

query I rowsort
SELECT - 86 * - cor0.col2 FROM tab0 cor0
----
2838
7052
86

query I rowsort
SELECT ALL + cor0.col2 * - col0 * col1 + + cor0.col2 * - ( col1 ) FROM tab0 AS cor0
----
-3492
-671580
-70950

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-205
SELECT - ( - col1 ) DIV 27 + col2 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-205
SELECT - ( - col1 ) / 27 + col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL - - col1 * cor0.col0 + + col0 * col2 + - col2 AS col2 FROM tab1 AS cor0
----
186
4231
8624

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

query I rowsort
SELECT DISTINCT + + cor0.col1 + + 26 + col2 * + col2 AS col1 FROM tab1 AS cor0
----
2968
3285
9255

query I rowsort
SELECT - col1 + ( col1 ) * - cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
-205438
-29822
-4930

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

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

query I rowsort
SELECT col0 + + col2 * 46 AS col2 FROM tab0 AS cor0
----
1542
3861
81

query I rowsort
SELECT ALL cor1.col1 + - cor1.col2 FROM tab2, tab2 cor0, tab1 cor1
----
27 values hashing to a94a44cb20b21603860a4a213701f42f

query I rowsort
SELECT DISTINCT - col0 * col2 + - ( col1 * - 66 ) AS col0 FROM tab2 AS cor0
----
-1880
1857
1866

query I rowsort
SELECT + col1 + 65 * + cor0.col1 FROM tab2 cor0
----
1122
2046
3894

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 + - col2 * col0 + - col0 col0 FROM tab1 AS cor0
----
-3072
-6720
-87

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

query I rowsort
SELECT - + col2 + 72 * col2 AS col2 FROM tab0 cor0
----
2343
5822
71

query I rowsort
SELECT + col1 * col2 + 16 * col2 + col1 FROM tab1 AS cor0
----
1492
2294
2797

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * ( - col0 + col2 ) col0 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT - col1 + - col2 * col1 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-193
-2891
-7471

query I rowsort
SELECT - + col2 * + cor0.col0 * + 12 AS col0 FROM tab1 AS cor0
----
-1944
-43776
-92160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * col0 + 42 col0 FROM tab2 AS cor0
----
-6042
-6199
-7

query I rowsort
SELECT - col1 * - ( + col0 * - col2 ) AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-226
SELECT + col1 - CAST( 9 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1
17
4

skipif mysql # not compatible
query I rowsort label-226
SELECT + col1 - CAST ( 9 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1
17
4

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 20 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT + 39 + + col1 AS col0 FROM tab2 AS cor0
----
56
70
98

query I rowsort
SELECT + col2 * + 64 + col1 FROM tab2 AS cor0
----
1723
1759
2449

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

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

query I rowsort
SELECT DISTINCT + col2 + - col1 * 69 AS col2 FROM tab0 AS cor0
----
-5901
-6197
-6692

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

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

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

query I rowsort
SELECT DISTINCT + ( - col1 + col2 ) * col0 FROM tab2
----
-2574
-28
1659

query I rowsort
SELECT ALL - cor1.col0 + - cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to f8529b710dc613df309e90c94e8a2770

onlyif mysql # use DIV operator for integer division
query I rowsort label-239
SELECT 8 + + ( - col1 ) * col0 DIV col0 FROM tab2
----
-23
-51
-9

skipif mysql # not compatible
query I rowsort label-239
SELECT 8 + + ( - col1 ) * col0 / col0 FROM tab2
----
-23
-51
-9

query I rowsort
SELECT + 95 * - col0 AS col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

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

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

skipif mysql # not compatible
query I rowsort label-242
SELECT - CAST ( + col2 AS INTEGER ) * col2 + 99 AS col1 FROM tab1 AS cor0
----
-2817
-3150
-9117

query I rowsort
SELECT 17 + + 40 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT 67 + + col1 FROM tab0 AS cor0
----
153
158
164

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

skipif mysql # not compatible
query I rowsort label-245
SELECT ALL - ( + col0 ) / + col0 AS col0 FROM tab0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-246
SELECT DISTINCT col2 DIV col0 + + col0 * col1 * - col1 + col2 * ( - 92 ) FROM tab0 AS cor0
----
-180539
-329407
-744553

skipif mysql # not compatible
query I rowsort label-246
SELECT DISTINCT col2 / col0 + + col0 * col1 * - col1 + col2 * ( - 92 ) FROM tab0 AS cor0
----
-180539
-329407
-744553

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

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

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

query I rowsort
SELECT - col1 + tab2.col2 * + 90 AS col0 FROM tab2
----
2281
2399
3403

query I rowsort
SELECT col2 * col0 + + col0 AS col2 FROM tab1
----
165
3712
7760

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + 72 * + col2 * - col1 col0 FROM tab2 AS cor0
----
-110422
-46474
-60237

query I rowsort
SELECT ALL - col0 + + cor0.col1 + + col2 * col0 AS col0 FROM tab0 AS cor0
----
7300
854
97

query I rowsort
SELECT ALL - cor0.col0 * - 16 + 46 FROM tab2 AS cor0
----
1294
1310
158

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

query I rowsort
SELECT ALL + - col1 * + ( - col2 ) + col0 * col0 FROM tab0 AS cor0
----
1322
15383
3414

query I rowsort
SELECT ALL + col2 * - 37 AS col2 FROM tab0 AS cor0
----
-1221
-3034
-37

query I rowsort
SELECT + col1 + cor0.col1 * - 44 AS col1 FROM tab0 AS cor0
----
-3698
-3913
-4171

query I rowsort
SELECT ALL + 53 FROM tab1, tab2, tab2 AS cor0, tab0
----
81 values hashing to 63949b5362442f48bd29195397a57dad

query I rowsort
SELECT ALL col0 * - 73 * col1 FROM tab1
----
-46720
-5694
-75920

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 25 col1 FROM tab0 AS cor0
----
2225
600
875

query I rowsort
SELECT col2 * 32 * + col0 AS col2 FROM tab0
----
1120
233536
25344

query I rowsort
SELECT col1 + + col0 * 10 AS col2 FROM tab1
----
56
650
813

query I rowsort
SELECT - col2 + 26 * col2 + + col2 * + col0 FROM tab1
----
10080
1512
5073

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

query I rowsort
SELECT ALL - col2 * ( tab1.col2 ) * tab1.col0 - col0 * col0 AS col2 FROM tab1
----
-212032
-743680
-8757

query I rowsort
SELECT + + cor0.col0 + + 24 FROM tab1 AS cor0
----
104
27
88

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

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

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

query I rowsort
SELECT ALL col2 + - 61 FROM tab1
----
-4
-7
35

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

skipif mysql # not compatible
query I rowsort label-275
SELECT CAST ( 36 AS INTEGER ) * + col0 + - col2 AS col0 FROM tab2 AS cor0
----
225
2782
2806

query I rowsort
SELECT ALL 44 + cor0.col1 * - col0 FROM tab1 AS cor0
----
-34
-596
-996

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

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 * col1 - - col2 FROM tab2 AS cor0
----
205405
29818
4951

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

query I rowsort
SELECT + 5 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

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

query I rowsort
SELECT - 2 * cor0.col0 + col1 FROM tab1 AS cor0
----
-118
-147
20

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

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

query I rowsort
SELECT DISTINCT - - ( - cor0.col0 ) * + col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + + ( col0 ) * 95 AS col1 FROM tab2 AS cor0
----
665
7410
7505

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-287
SELECT DISTINCT + 4 DIV tab2.col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-287
SELECT DISTINCT + 4 / tab2.col0 FROM tab2
----
0

query I rowsort
SELECT + 25 * + cor0.col0 FROM tab1 cor0
----
1600
2000
75

query I rowsort
SELECT + ( + cor0.col0 ) * ( - col2 * col2 ) FROM tab0 AS cor0
----
-26136
-35
-598436

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * 68 col0 FROM tab1 cor0
----
-3672
-3876
-6528

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

query I rowsort
SELECT DISTINCT - - cor0.col2 * - 86 AS col2 FROM tab0 cor0
----
-2838
-7052
-86

query I rowsort
SELECT - col1 + col2 + col1 * + col0 FROM tab2 AS cor0
----
1364
213
4569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + + col0 + + col0 * col0 col0 FROM tab1 AS cor0
----
-14
4150
6467

query I rowsort
SELECT DISTINCT col2 + - cor0.col0 * - cor0.col0 AS col2 FROM tab2 cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-297
SELECT ALL col1 * col0 DIV - 7 + - col0 FROM tab2 AS cor0
----
-270
-38
-735

skipif mysql # not compatible
query I rowsort label-297
SELECT ALL col1 * col0 / - 7 + - col0 FROM tab2 AS cor0
----
-270
-38
-735

query I rowsort
SELECT DISTINCT 10 - + col2 FROM tab0 AS cor0
----
-23
-72
9

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-300
SELECT ALL col2 * + col0 + CAST( col2 AS SIGNED ) DIV + col2 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-300
SELECT ALL col2 * + col0 + CAST ( col2 AS INTEGER ) / + col2 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT 79 + - col0 * col2 FROM tab1 AS cor0
----
-3569
-7601
-83

query I rowsort
SELECT DISTINCT + col1 + + col0 * 53 FROM tab0 cor0
----
1358
1952
4808

query I rowsort
SELECT ALL col2 + - col1 * - col1 AS col1 FROM tab1 AS cor0
----
157
265
730

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

query I rowsort
SELECT ( 62 ) + - col2 AS col0 FROM tab0
----
-20
29
61

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

query I rowsort
SELECT ( - tab1.col0 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT DISTINCT - ( 51 * + col0 ) + ( + col1 ) * tab0.col1 - - col2 AS col0 FROM tab0
----
3824
6205
7625

query I rowsort
SELECT DISTINCT col2 * - col0 + col2 * - col1 * col2 FROM tab2 AS cor0
----
-22788
-27550
-41912

query I rowsort
SELECT - 61 * col1 + + 66 * 13 FROM tab1 cor0
----
-728
248
65

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

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

query I rowsort
SELECT DISTINCT - 75 AS col1 FROM tab2 AS cor0
----
-75

query I rowsort
SELECT ALL col0 + + col0 * 36 * cor0.col2 FROM tab2 AS cor0
----
108151
6811
73086

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 15 * + col2 + + 36 * col0 col1 FROM tab1
----
3159
4320
918

query I rowsort
SELECT col1 + + col2 * 65 FROM tab1 cor0
----
3536
3715
6253

query I rowsort
SELECT 62 * + col2 FROM tab2 AS cor0
----
1612
1674
2356

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col1 - - 47 * col2 col1 FROM tab0
----
11953
3442
3615

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * - 14 - cor0.col1 col1 FROM tab0 cor0
----
-1337
-422
-587

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

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

skipif mysql # not compatible
query I rowsort label-323
SELECT + 32 / - col1 FROM tab2
----
-1
-1
0

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

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

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

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

query I rowsort
SELECT ALL 91 * - col1 FROM tab1
----
-1183
-2366
-910

query I rowsort
SELECT ALL 89 AS col2 FROM tab2 cor0
----
89
89
89

query I rowsort
SELECT + - col0 * - 5 FROM tab1 AS cor0
----
15
320
400

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

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

skipif mysql # not compatible
query I rowsort label-332
SELECT DISTINCT - col2 / - 92 AS col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT col0 * + 29 AS col2 FROM tab1 AS cor0
----
1856
2320
87

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

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-336
SELECT + CAST( NULL AS SIGNED ) * + ( col1 ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT ALL + cor0.col1 * 27 * + col0 AS col1 FROM tab2 cor0
----
124254
36261
5859

query I rowsort
SELECT + 26 * - 1 AS col0 FROM tab1 AS cor0
----
-26
-26
-26

query I rowsort
SELECT ALL ( + cor0.col0 ) + - col2 * col2 + col0 FROM tab0 cor0
----
-1041
-6546
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - 1 * cor0.col0 col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - - ( + 64 ) AS col0 FROM tab0 AS cor0
----
64
64
64

query I rowsort
SELECT DISTINCT - 4 + col1 * 27 AS col0 FROM tab1 AS cor0
----
266
347
698

query I rowsort
SELECT DISTINCT + col2 + + col2 * - 46 * col2 FROM tab2 cor0
----
-31070
-33507
-66386

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

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

query I rowsort
SELECT col1 * cor0.col1 * col0 + - col2 FROM tab1 AS cor0
----
13424
1974
6343

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

query I rowsort
SELECT - + cor0.col0 + + 83 * col1 AS col0 FROM tab1 AS cor0
----
2155
766
999

query I rowsort
SELECT DISTINCT + col1 + - col1 * 21 FROM tab0 AS cor0
----
-1720
-1820
-1940

query I rowsort
SELECT ALL cor0.col2 * + col0 + 81 FROM tab1 AS cor0
----
243
3729
7761

onlyif mysql # use DIV operator for integer division
query I rowsort label-351
SELECT ALL col2 DIV 21 AS col0 FROM tab0 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-351
SELECT ALL col2 / 21 AS col0 FROM tab0 AS cor0
----
0
1
3

query I rowsort
SELECT + col0 * 57 + - col0 * - cor0.col0 FROM tab0 AS cor0
----
12994
1944
3220

onlyif mysql # use DIV operator for integer division
query I rowsort label-353
SELECT DISTINCT + + col0 DIV - col1 + - col2 FROM tab1 AS cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-353
SELECT DISTINCT + + col0 / - col1 + - col2 FROM tab1 AS cor0
----
-102
-54
-63

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

query I rowsort
SELECT - col1 * col1 + 22 FROM tab0 AS cor0
----
-7374
-8259
-9387

query I rowsort
SELECT DISTINCT cor0.col2 + col1 + 84 FROM tab2 AS cor0
----
139
142
169

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-358
SELECT ALL + col1 * CAST( 17 AS SIGNED ) FROM tab1 AS cor0
----
170
221
442

skipif mysql # not compatible
query I rowsort label-358
SELECT ALL + col1 * CAST ( 17 AS INTEGER ) FROM tab1 AS cor0
----
170
221
442

onlyif mysql # use DIV operator for integer division
query I rowsort label-359
SELECT col0 * + col1 - + col2 DIV col2 AS col2 FROM tab1
----
1039
639
77

skipif mysql # not compatible
query I rowsort label-359
SELECT col0 * + col1 - + col2 / col2 AS col2 FROM tab1
----
1039
639
77

query I rowsort
SELECT ALL - ( 92 ) * cor0.col2 AS col2 FROM tab1 AS cor0
----
-4968
-5244
-8832

query I rowsort
SELECT - - col2 * + cor0.col0 + col1 * 63 FROM tab2 AS cor0
----
2142
4073
5745

query I rowsort
SELECT ALL - col2 * - 91 AS col0 FROM tab1 AS cor0
----
4914
5187
8736

onlyif mysql # use DIV operator for integer division
query I rowsort label-363
SELECT ALL + 66 DIV col0 FROM tab2 cor0
----
0
0
9

skipif mysql # not compatible
query I rowsort label-363
SELECT ALL + 66 / col0 FROM tab2 cor0
----
0
0
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 + col1 * col2 col2 FROM tab1 AS cor0
----
1261
1430
580

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

query I rowsort
SELECT - col2 - 27 * - col2 AS col0 FROM tab2
----
676
702
988

query I rowsort
SELECT - col2 * ( col2 ) + col1 AS col2 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT col0 * 76 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT col2 + - 24 + + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
31
34
61

query I rowsort
SELECT - - col1 + col2 + + col0 * + col0 FROM tab2 AS cor0
----
107
6169
6296

query I rowsort
SELECT - col2 + ( col0 ) * 74 FROM tab1 AS cor0
----
168
4679
5824

onlyif mysql # use DIV operator for integer division
query I rowsort label-372
SELECT ALL + CAST( - col1 AS SIGNED ) DIV + col0 AS col0 FROM tab1 cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-372
SELECT ALL + CAST ( - col1 AS INTEGER ) / + col0 AS col0 FROM tab1 cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-373
SELECT + + 85 DIV col0 FROM tab1 AS cor0
----
1
1
28

skipif mysql # not compatible
query I rowsort label-373
SELECT + + 85 / col0 FROM tab1 AS cor0
----
1
1
28

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

query I rowsort
SELECT + ( + col0 + + col1 ) * + 13 FROM tab2
----
1248
1781
494

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

skipif mysql # not compatible
query I rowsort label-376
SELECT DISTINCT + col0 + col0 / col0 FROM tab1
----
4
65
81

query I rowsort
SELECT col2 - col2 * col1 FROM tab2 AS cor0
----
-1508
-608
-810

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

query I rowsort
SELECT + col0 * col2 + ( col2 ) + + col1 AS col1 FROM tab2 AS cor0
----
2113
247
3057

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-381
SELECT - - col0 DIV + 78 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
3
64
81

skipif mysql # not compatible
query I rowsort label-381
SELECT - - col0 / + 78 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
3
64
81

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

query I rowsort
SELECT ALL - 73 AS col0 FROM tab1
----
-73
-73
-73

query I rowsort
SELECT col0 + + col0 * col1 - col1 AS col2 FROM tab0
----
2002
3333
8097

query I rowsort
SELECT ALL col0 * - 77 AS col2 FROM tab1
----
-231
-4928
-6160

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

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

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

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

query I rowsort
SELECT DISTINCT tab2.col1 * ( + 16 ) - - col2 FROM tab2
----
310
523
970

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

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

query I rowsort
SELECT ALL - ( col2 + + tab2.col2 * + 26 ) FROM tab2
----
-1026
-702
-729

query I rowsort
SELECT DISTINCT - tab2.col0 * - 5 AS col1 FROM tab2
----
35
390
395

query I rowsort
SELECT DISTINCT 80 + col1 FROM tab1
----
106
90
93

query I rowsort
SELECT 87 + col1 * col0 FROM tab2
----
1430
304
4689

query I rowsort
SELECT 43 + tab0.col2 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to fafbc46614d367b899ef6f883a96d398

query I rowsort
SELECT ALL ( col0 ) * - 46 + col1 AS col2 FROM tab2 cor0
----
-291
-3529
-3617

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

query I rowsort
SELECT + 66 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 89 * 32 col0 FROM tab1 cor0
----
-2848
-2848
-2848

query I rowsort
SELECT col1 * - 89 + - col0 FROM tab0
----
-7678
-8188
-8668

query I rowsort
SELECT DISTINCT + col0 * + 18 AS col1 FROM tab2 cor0
----
126
1404
1422

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

skipif mysql # not compatible
query I rowsort label-402
SELECT + CAST ( - col1 AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + + col1 + ( + col0 ) * col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT ALL - cor0.col2 + 10 AS col1 FROM tab1 AS cor0
----
-44
-47
-86

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

skipif mysql # not compatible
query I rowsort label-405
SELECT DISTINCT - col0 * col1 + CAST ( - col0 * col0 AS INTEGER ) FROM tab2 AS cor0
----
-10686
-266
-7584

query I rowsort
SELECT - + 14 * col2 AS col2 FROM tab2 cor0
----
-364
-378
-532

query I rowsort
SELECT DISTINCT - col1 * col1 * - 51 + + col1 FROM tab0 AS cor0
----
377282
422422
479956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 97 * - cor0.col2 col2 FROM tab1 AS cor0
----
-5238
-5529
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 - + col0 * - ( cor0.col1 ) * col0 col2 FROM tab0 AS cor0
----
117600
48960
712890

query I rowsort
SELECT DISTINCT - col0 * - col2 + cor0.col0 * 66 + + col0 FROM tab2 cor0
----
658
7254
8295

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-412
SELECT ALL - 36 - col0 DIV - tab2.col1 FROM tab2
----
-32
-35
-36

skipif mysql # not compatible
query I rowsort label-412
SELECT ALL - 36 - col0 / - tab2.col1 FROM tab2
----
-32
-35
-36

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

query I rowsort
SELECT ALL + col0 + 42 - col2 AS col0 FROM tab2
----
22
83
94

query I rowsort
SELECT DISTINCT - col0 * 23 + col1 FROM tab0 AS cor0
----
-1956
-466
-708

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

query I rowsort
SELECT - cor0.col0 + + 83 FROM tab2 AS cor0
----
4
5
76

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

query I rowsort
SELECT ALL col0 + ( - 71 ) AS col0 FROM tab1 AS cor0
----
-68
-7
9

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col0 col0 FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-425
SELECT col2 + - ( cor0.col0 ) DIV - 78 FROM tab0 AS cor0
----
1
33
83

skipif mysql # not compatible
query I rowsort label-425
SELECT col2 + - ( cor0.col0 ) / - 78 FROM tab0 AS cor0
----
1
33
83

query I rowsort
SELECT - 24 * 29 FROM tab0 AS cor0
----
-696
-696
-696

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

query I rowsort
SELECT 20 AS col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

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

skipif mysql # not compatible
query I rowsort label-429
SELECT ALL - CAST ( - 33 AS INTEGER ) FROM tab1
----
33
33
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-430
SELECT col0 * cor0.col1 DIV col2 AS col1 FROM tab0 AS cor0
----
3395
62
98

skipif mysql # not compatible
query I rowsort label-430
SELECT col0 * cor0.col1 / col2 AS col1 FROM tab0 AS cor0
----
3395
62
98

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-433
SELECT DISTINCT + col2 * ( - col0 ) + col1 DIV col1 AS col0 FROM tab0 AS cor0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-433
SELECT DISTINCT + col2 * ( - col0 ) + col1 / col1 AS col0 FROM tab0 AS cor0
----
-34
-7297
-791

query I rowsort
SELECT ( + ( - cor0.col1 ) ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT - - cor0.col2 - + col2 * col2 * 90 AS col1 FROM tab1 AS cor0
----
-262386
-292353
-829344

query I rowsort
SELECT ALL col0 * + col2 + + col2 * - col2 + + col1 FROM tab0 AS cor0
----
-211
131
665

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-439
SELECT - col0 DIV col2 - + col0 * col2 FROM tab0 AS cor0
----
-70
-7299
-792

skipif mysql # not compatible
query I rowsort label-439
SELECT - col0 / col2 - + col0 * col2 FROM tab0 AS cor0
----
-70
-7299
-792

query I rowsort
SELECT - col1 + + col1 * 29 AS col2 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT ALL - 7 * col1 * col1 AS col0 FROM tab0 AS cor0
----
-51772
-57967
-65863

query I rowsort
SELECT ALL - 91 + col2 FROM tab0 cor0
----
-58
-9
-90

query I rowsort
SELECT - col0 * - cor0.col2 * + ( col0 ) + + col2 * 19 * + col2 FROM tab2 cor0
----
15174
171028
264594

onlyif mysql # use DIV operator for integer division
query I rowsort label-444
SELECT ALL - col1 DIV col1 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-444
SELECT ALL - col1 / col1 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT DISTINCT + + cor0.col2 * - 82 + cor0.col2 * col2 * - cor0.col0 FROM tab2 cor0
----
-117192
-54860
-7317

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-448
SELECT DISTINCT - + cor0.col2 * - CAST( + col1 * - col0 AS SIGNED ) + - col2 + col1 col1 FROM tab2 AS cor0
----
-119619
-51055
-5855

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-448
SELECT DISTINCT - + cor0.col2 * - CAST ( + col1 * - col0 AS INTEGER ) + - col2 + col1 col1 FROM tab2 AS cor0
----
-119619
-51055
-5855

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

skipif mysql # not compatible
query I rowsort label-449
SELECT ALL - col1 / + cor0.col1 + - col2 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-450
SELECT col1 + ( + 57 ) DIV col0 FROM tab2 AS cor0
----
17
39
59

skipif mysql # not compatible
query I rowsort label-450
SELECT col1 + ( + 57 ) / col0 FROM tab2 AS cor0
----
17
39
59

query I rowsort
SELECT ALL + - cor0.col1 * 84 + 81 FROM tab0 cor0
----
-7143
-7563
-8067

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

query I rowsort
SELECT - - col0 * + ( col0 * col0 ) FROM tab0 AS cor0
----
13824
42875
704969

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-456
SELECT + ( 44 ) DIV col0 AS col0 FROM tab2
----
0
0
6

skipif mysql # not compatible
query I rowsort label-456
SELECT + ( 44 ) / col0 AS col0 FROM tab2
----
0
0
6

query I rowsort
SELECT 96 * - cor0.col2 FROM tab1 cor0
----
-5184
-5472
-9216

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - cor0.col1 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - ( 30 ) AS col1 FROM tab0 AS cor0
----
-30
-30
-30

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

query I rowsort
SELECT + ( - cor0.col1 ) FROM tab0, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT - col0 + col2 - + ( col2 + col1 ) * + col1 AS col2 FROM tab2
----
-1778
-5067
-976

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

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

query I rowsort
SELECT ALL + 54 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT DISTINCT + col2 * col2 * col0 FROM tab1
----
207936
737280
8748

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

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

query I rowsort
SELECT 76 * - col1 FROM tab2 AS cor0
----
-1292
-2356
-4484

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * + 92 col0 FROM tab0 cor0
----
3036
7544
92

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

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

skipif mysql # not compatible
query I rowsort label-473
SELECT + ( - 7 ) / col1 AS col2 FROM tab1 AS cor0
----
0
0
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-475
SELECT cor0.col2 DIV 40 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-475
SELECT cor0.col2 / 40 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-476
SELECT DISTINCT col0 DIV 85 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-476
SELECT DISTINCT col0 / 85 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + ( col1 ) + col2 + 52 * col1 AS col1 FROM tab0 AS cor0
----
4591
4905
5142

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-478
SELECT DISTINCT - + CAST( col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-478
SELECT DISTINCT - + CAST ( col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-26
-27
-38

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-481
SELECT - CAST ( NULL AS INTEGER ) + col1 * - col0 col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col0 * col0 + ( col0 ) * col1 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT - 80 * col0 AS col2 FROM tab0
----
-1920
-2800
-7120

query I rowsort
SELECT + col1 + - 42 FROM tab0 cor0
----
44
49
55

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

query I rowsort
SELECT ALL - 83 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT ALL 21 * + col2 AS col0 FROM tab1
----
1134
1197
2016

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-488
SELECT CAST( 0 AS SIGNED ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-488
SELECT CAST ( 0 AS INTEGER ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + + col1 * 92 * 43 + col1 * + col0 FROM tab2 AS cor0
----
122853
238006
68595

onlyif mysql # use DIV operator for integer division
query I rowsort label-490
SELECT - col0 + col1 DIV - 35 FROM tab0 cor0
----
-26
-37
-91

skipif mysql # not compatible
query I rowsort label-490
SELECT - col0 + col1 / - 35 FROM tab0 cor0
----
-26
-37
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-491
SELECT DISTINCT - tab1.col0 DIV 9 FROM tab1, tab2 AS cor0
----
-7
-8
0

skipif mysql # not compatible
query I rowsort label-491
SELECT DISTINCT - tab1.col0 / 9 FROM tab1, tab2 AS cor0
----
-7
-8
0

query I rowsort
SELECT - 73 + cor0.col1 AS col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to d94e17f6a84485a3ac1578f693f647c5

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

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

query I rowsort
SELECT DISTINCT - - col0 * + col0 + col2 + col2 FROM tab1 AS cor0
----
117
4210
6592

query I rowsort
SELECT ALL + 46 - col1 FROM tab2 cor0
----
-13
15
29

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

query I rowsort
SELECT + col0 * + col1 * ( + 86 * col0 ) AS col2 FROM tab2 cor0
----
130634
30870216
9124342

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

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

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

query I rowsort
SELECT ALL + col2 * + cor0.col0 * - col2 + col2 FROM tab0 AS cor0
----
-26103
-34
-598354

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

query I rowsort
SELECT col1 + - 72 FROM tab0 AS cor0
----
14
19
25

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

query I rowsort
SELECT ALL + col1 * - col0 * col0 + col0 * - col1 FROM tab2 AS cor0
----
-107440
-1736
-363558

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

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

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

query I rowsort
SELECT + - col1 * + 10 FROM tab2 cor0
----
-170
-310
-590

query I rowsort
SELECT DISTINCT - cor0.col0 + + ( col2 ) * col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + col2 * cor0.col1 + col0 + col1 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT col0 + col0 * - col0 * + 12 FROM tab1 AS cor0
----
-105
-49088
-76720

query I rowsort
SELECT ALL - col1 * + 54 + + col2 FROM tab2 AS cor0
----
-1647
-3160
-880

query I rowsort
SELECT ALL + col2 + - 41 AS col2 FROM tab2 AS cor0
----
-14
-15
-3

query I rowsort
SELECT ALL col0 * 82 AS col0 FROM tab1 cor0
----
246
5248
6560

query I rowsort
SELECT + ( ( - col2 ) ) + ( - col1 ) * + cor0.col1 FROM tab2 AS cor0
----
-327
-3507
-988

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

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

query I rowsort
SELECT - - 68 + - col0 * col2 AS col1 FROM tab2 AS cor0
----
-121
-1960
-2934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-519
SELECT ALL - 33 * 80 + col0 / CAST( NULL AS SIGNED ) + - col0 * + col1 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-519
SELECT ALL - 33 * 80 + col0 / CAST ( NULL AS INTEGER ) + - col0 * + col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

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

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

query I rowsort
SELECT col1 + + 53 AS col0 FROM tab2 AS cor0
----
112
70
84

query I rowsort
SELECT ( col0 ) * cor0.col0 - cor0.col0 * col2 AS col2 FROM tab0 AS cor0
----
-216
1190
623

query I rowsort
SELECT 8 AS col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

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

query I rowsort
SELECT ALL - 73 * + col2 + col0 FROM tab2
----
-1820
-1964
-2695

query I rowsort
SELECT - + 75 * - col0 + col0 * + 22 AS col2 FROM tab0 AS cor0
----
2328
3395
8633

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-529
SELECT - col2 + - col0 DIV col0 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-529
SELECT - col2 + - col0 / col0 FROM tab1 AS cor0
----
-55
-58
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 + + col2 * - 67 col2 FROM tab1 AS cor0
----
-3602
-3803
-6416

query I rowsort
SELECT ALL 72 + col0 AS col1 FROM tab0 AS cor0
----
107
161
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-532
SELECT ALL + tab1.col1 DIV col2 + col2 + + 86 FROM tab1
----
140
143
182

skipif mysql # not compatible
query I rowsort label-532
SELECT ALL + tab1.col1 / col2 + col2 + + 86 FROM tab1
----
140
143
182

onlyif mysql # use DIV operator for integer division
query I rowsort label-533
SELECT ( col2 ) DIV col1 + - col2 * col0 DIV - col2 AS col1 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-533
SELECT ( col2 ) / col1 + - col2 * col0 / - col2 AS col1 FROM tab1
----
5
69
87

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

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

query I rowsort
SELECT + 23 + 0 + col1 AS col0 FROM tab0
----
109
114
120

query I rowsort
SELECT col0 * + 11 FROM tab1
----
33
704
880

query I rowsort
SELECT col1 * - 19 FROM tab0
----
-1634
-1729
-1843

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

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

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

query I rowsort
SELECT + col1 * col1 * 55 FROM tab1 AS cor0
----
37180
5500
9295

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

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

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

query I rowsort
SELECT DISTINCT 57 * + 47 FROM tab0, tab1 AS cor0
----
2679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - 20 * + col1 - - col1 col0 FROM tab2
----
-1095
-285
-562

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-548
SELECT - + col1 DIV - col2 + col0 * - col0 FROM tab0 AS cor0
----
-1128
-574
-7920

skipif mysql # not compatible
query I rowsort label-548
SELECT - + col1 / - col2 + col0 * - col0 FROM tab0 AS cor0
----
-1128
-574
-7920

query I rowsort
SELECT DISTINCT + 3 AS col0 FROM tab0 cor0
----
3

query I rowsort
SELECT + col2 + + 13 * - col2 FROM tab2 AS cor0
----
-312
-324
-456

query I rowsort
SELECT DISTINCT - - 24 * + col1 AS col1 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT + 97 + - col2 FROM tab2 AS cor0
----
59
70
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 82 + col2 col0 FROM tab1 AS cor0
----
136
139
178

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

skipif mysql # not compatible
query I rowsort label-554
SELECT col1 / + ( 99 + col0 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + 12 * col1 AS col1 FROM tab1 AS cor0
----
110
143
286

query I rowsort
SELECT cor0.col2 * - 24 AS col1 FROM tab2 cor0
----
-624
-648
-912

onlyif mysql # use DIV operator for integer division
query I rowsort label-557
SELECT ALL col2 * - 28 + cor0.col2 DIV - cor0.col2 FROM tab1 AS cor0
----
-1513
-1597
-2689

skipif mysql # not compatible
query I rowsort label-557
SELECT ALL col2 * - 28 + cor0.col2 / - cor0.col2 FROM tab1 AS cor0
----
-1513
-1597
-2689

query I rowsort
SELECT ALL - cor0.col0 + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + tab2.col2 * + 72 AS col1 FROM tab2
----
1872
1944
2736

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab2 AS cor2, tab2 AS cor3
----
13122 values hashing to 0e4b812a39d9ff1d1907c378d5936c4a

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

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

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

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

query I rowsort
SELECT ALL + cor0.col0 FROM tab1, tab0 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + - col2 col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + 38 + col2 * + col1 FROM tab0 AS cor0
----
135
2876
7500

query I rowsort
SELECT - col1 + - col1 + 67 FROM tab1 cor0
----
15
41
47

query I rowsort
SELECT ALL col0 + col2 * - col0 * - col0 FROM tab1
----
233536
489
614480

query I rowsort
SELECT DISTINCT + + col0 * - 3 + col2 FROM tab1 cor0
----
-135
-144
45

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-577
SELECT ALL - col1 DIV cor0.col1 - 23 FROM tab1 AS cor0
----
-24
-24
-24

skipif mysql # not compatible
query I rowsort label-577
SELECT ALL - col1 / cor0.col1 - 23 FROM tab1 AS cor0
----
-24
-24
-24

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

query I rowsort
SELECT + col0 * 6 AS col0 FROM tab0 cor0
----
144
210
534

query I rowsort
SELECT col1 + - 67 * 59 FROM tab0 AS cor0
----
-3856
-3862
-3867

query I rowsort
SELECT DISTINCT + col1 * col0 - col1 AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT + + col1 * 10 AS col2 FROM tab2 AS cor0
----
170
310
590

query I rowsort
SELECT - col1 * - 65 AS col2 FROM tab1 cor0
----
1690
650
845

query I rowsort
SELECT DISTINCT col0 + col2 * + 66 - col2 AS col1 FROM tab0 AS cor0
----
100
2169
5419

query I rowsort
SELECT + col2 * - 8 AS col0 FROM tab1 AS cor0
----
-432
-456
-768

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

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

query I rowsort
SELECT col0 + col2 + col2 FROM tab0
----
253
37
90

query I rowsort
SELECT DISTINCT + col2 - - 76 AS col0 FROM tab1
----
130
133
172

query I rowsort
SELECT DISTINCT - col0 - 65 AS col2 FROM tab0
----
-100
-154
-89

query I rowsort
SELECT ALL 7 * + col2 FROM tab1 AS cor0
----
378
399
672

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

skipif mysql # not compatible
query I rowsort label-591
SELECT DISTINCT - CAST ( - col1 AS INTEGER ) / - col2 AS col0 FROM tab1 AS cor0
----
0

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

query I rowsort
SELECT + + 6 + 43 * col2 FROM tab2 AS cor0
----
1124
1167
1640

query I rowsort
SELECT ALL col2 - cor0.col1 * - 80 FROM tab0 AS cor0
----
6913
7362
7761

query I rowsort
SELECT - col1 * + col1 + + col0 * 33 AS col1 FROM tab0 AS cor0
----
-5344
-6604
-8254

query I rowsort
SELECT - col1 * col1 + ( cor0.col1 ) * col0 FROM tab0 AS cor0
----
-182
-5332
-6014

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

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

query I rowsort
SELECT - - 94 + - col1 AS col0 FROM tab2 AS cor0
----
35
63
77

query I rowsort
SELECT DISTINCT + - col2 * - col0 - + 40 FROM tab1 AS cor0
----
122
3608
7640

query I rowsort
SELECT + 41 + + col1 * 34 * 53 FROM tab0 AS cor0
----
155013
164023
174835

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

skipif mysql # not compatible
query I rowsort label-601
SELECT CAST ( NULL AS REAL ) * 24 * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * ( col2 ) - 27 * col2 AS col0 FROM tab1
----
-2109
-2862
-3840

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-604
SELECT - 32 DIV 13 + col0 * + 34 FROM tab2 AS cor0
----
236
2650
2684

skipif mysql # not compatible
query I rowsort label-604
SELECT - 32 / 13 + col0 * + 34 FROM tab2 AS cor0
----
236
2650
2684

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

skipif mysql # not compatible
query I rowsort label-605
SELECT ( - 25 ) / + cor0.col2 FROM tab0 AS cor0
----
-25
0
0

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-607
SELECT DISTINCT + CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2
----
NULL

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - ( col0 ) + - col2 * + col1 col2 FROM tab2
----
-788
4550
5595

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

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

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

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

query I rowsort
SELECT DISTINCT - 65 + 90 + - col1 FROM tab2 AS cor0
----
-34
-6
8

query I rowsort
SELECT ALL cor0.col0 * col1 * col1 + ( + col0 ) * col2 FROM tab1 AS cor0
----
10048
21200
2190

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

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

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

query I rowsort
SELECT - 56 * col2 AS col0 FROM tab2 AS cor0
----
-1456
-1512
-2128

onlyif mysql # use DIV operator for integer division
query I rowsort label-618
SELECT ALL 92 DIV + 74 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-618
SELECT ALL 92 / + 74 FROM tab2
----
1
1
1

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

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

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

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

query I rowsort
SELECT ALL 44 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

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

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

query I rowsort
SELECT - cor0.col0 + - col0 * 79 * col0 FROM tab0 AS cor0
----
-45528
-625848
-96810

query I rowsort
SELECT ALL - + col1 * - col0 * + ( col0 ) AS col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL - - col1 * col1 + col0 + col2 * col0 FROM tab0 AS cor0
----
15668
8212
9479

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

query I rowsort
SELECT col0 + col1 + col0 AS col2 FROM tab1
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-630
SELECT DISTINCT col2 * col1 + 5 DIV col0 AS col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-630
SELECT DISTINCT col2 * col1 + 5 / col0 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT + + col2 * 21 FROM tab0 AS cor0
----
1722
21
693

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

query I rowsort
SELECT DISTINCT + + col0 * col0 * + col1 AS col0 FROM tab2 AS cor0
----
106097
1519
358956

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

query I rowsort
SELECT - col0 * + ( 89 ) * col0 FROM tab2 AS cor0
----
-4361
-541476
-555449

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-637
SELECT ALL - - col0 DIV cor0.col0 - col2 FROM tab2 cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-637
SELECT ALL - - col0 / cor0.col0 - col2 FROM tab2 cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT col1 + 49 AS col2 FROM tab1 cor0
----
59
62
75

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-641
SELECT + col0 / col2 + cor0.col0 col0 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT DISTINCT - col0 * - 53 + col1 * col0 * - col0 FROM tab1 AS cor0
----
-37568
-75
-78960

query I rowsort
SELECT ALL + - cor0.col1 + - ( + 50 ) * col1 * - col2 AS col0 FROM tab1 AS cor0
----
28490
62387
70174

query I rowsort
SELECT DISTINCT - col2 * + col0 + - 37 * col1 AS col2 FROM tab1 AS cor0
----
-1124
-4018
-8161

query I rowsort
SELECT ALL + cor0.col2 * - col2 * + col0 - - col1 AS col2 FROM tab2 cor0
----
-114059
-5072
-52669

query I rowsort
SELECT + + col1 * 91 + col0 AS col2 FROM tab1 AS cor0
----
1263
2369
974

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-648
SELECT DISTINCT - col1 * + CAST( col2 AS SIGNED ) + col0 * - 88 * col0 AS col0 FROM tab0
----
-107897
-53526
-704510

skipif mysql # not compatible
query I rowsort label-648
SELECT DISTINCT - col1 * + CAST ( col2 AS INTEGER ) + col0 * - 88 * col0 AS col0 FROM tab0
----
-107897
-53526
-704510

onlyif mysql # use DIV operator for integer division
query I rowsort label-649
SELECT DISTINCT + col0 DIV - 78 + + col1 col2 FROM tab1
----
10
12
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-649
SELECT DISTINCT + col0 / - 78 + + col1 col2 FROM tab1
----
10
12
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-650
SELECT - - col1 + col0 DIV col0 AS col2 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-650
SELECT - - col1 + col0 / col0 AS col2 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT - col2 * + 33 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
-1056
-2624
-32

skipif mysql # not compatible
query I rowsort
SELECT - - col0 * CAST ( + col2 AS REAL ) - + col0 AS col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL + + col0 * + ( - 11 ) FROM tab0 cor0
----
-264
-385
-979

query I rowsort
SELECT ALL col0 * 29 FROM tab1 AS cor0
----
1856
2320
87

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

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

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

query I rowsort
SELECT + col0 * - 35 + col1 * col2 AS col2 FROM tab2 AS cor0
----
-1196
-2119
592

query I rowsort
SELECT - - col1 * - col2 + col2 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

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

query I rowsort
SELECT + - col0 * - col2 * col1 + col0 + + 33 FROM tab1 cor0
----
36577
4248
99953

onlyif mysql # use DIV operator for integer division
query I rowsort label-661
SELECT - col0 * + col1 DIV cor0.col1 - - 34 col0 FROM tab1 AS cor0
----
-30
-46
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-661
SELECT - col0 * + col1 / cor0.col1 - - 34 col0 FROM tab1 AS cor0
----
-30
-46
31

query I rowsort
SELECT 2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-663
SELECT - - col0 + cor0.col1 DIV + col2 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-663
SELECT - - col0 + cor0.col1 / + col2 FROM tab1 cor0
----
3
64
80

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

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

query I rowsort
SELECT 61 * + col2 FROM tab2 cor0
----
1586
1647
2318

query I rowsort
SELECT DISTINCT - + 84 FROM tab0 cor0
----
-84

query I rowsort
SELECT + 72 * - col0 * + 13 FROM tab2 cor0
----
-6552
-73008
-73944

onlyif mysql # use DIV operator for integer division
query I rowsort label-669
SELECT col2 DIV - col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-669
SELECT col2 / - col1 FROM tab1 cor0
----
-2
-5
-7

query I rowsort
SELECT 56 * col2 AS col0 FROM tab2 AS cor0
----
1456
1512
2128

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-671
SELECT - - cor0.col2 * CAST( 2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-671
SELECT - - cor0.col2 * CAST ( 2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
164
2
66

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

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

query I rowsort
SELECT ALL - 17 * col2 FROM tab0
----
-1394
-17
-561

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

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

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

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

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

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

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT - col0 + col1 <= NULL
----

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

query I rowsort
SELECT + + col2 * - col0 - - col1 * + col1 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT ALL 40 * col1 + col2 FROM tab2
----
1267
2386
718

query I rowsort
SELECT col1 + + col1 * + col2 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 - col0 col0 FROM tab0
----
-1113
-36
-6813

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE NOT + col1 * col2 - col0 / col0 >= NULL
----

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

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

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

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

query I rowsort
SELECT ALL tab2.col2 + - col1 + col2 AS col1 FROM tab2
----
-7
23
59

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-695
SELECT + col1 DIV col1 + col2 * col0 + col1 AS col0 FROM tab2
----
2088
221
3020

skipif mysql # not compatible
query I rowsort label-695
SELECT + col1 / col1 + col2 * col0 + col1 AS col0 FROM tab2
----
2088
221
3020

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 97 + - col2 col0 FROM tab1
----
-151
-154
-193

query I rowsort
SELECT - 56 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT DISTINCT - 30 + tab2.col1 + + col1 AS col0 FROM tab2
----
32
4
88

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

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

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

query I rowsort
SELECT DISTINCT - 78 + cor0.col2 * - col1 * - col1 AS col0 FROM tab1 cor0
----
16146
36426
5622

query I rowsort
SELECT DISTINCT 58 + col0 AS col0 FROM tab1 AS cor0
----
122
138
61

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

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

query I rowsort
SELECT ALL + + 60 * cor0.col1 + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b3926f1b919153b2a64e54012bd57068

query I rowsort
SELECT DISTINCT + col2 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT - col0 + col2 * + col0 AS col0 FROM tab2
----
182
1950
2923

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

query I rowsort
SELECT - col1 + + tab1.col1 * col1 * col1 AS col1 FROM tab1
----
17550
2184
990

query I rowsort
SELECT DISTINCT col1 + col1 * col0 * + col2 FROM tab1
----
36490
4238
99853

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

query III rowsort
SELECT DISTINCT * FROM tab1 cor0 WHERE + col0 IN ( + cor0.col0 + col1 * - col2 )
----

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-713
SELECT ALL - col0 DIV col1 + col2 * - col1 + col2 AS col0 FROM tab1
----
-1158
-1350
-519

skipif mysql # not compatible
query I rowsort label-713
SELECT ALL - col0 / col1 + col2 * - col1 + col2 AS col0 FROM tab1
----
-1158
-1350
-519

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

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

query III rowsort
SELECT * FROM tab1 WHERE NULL = ( - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-717
SELECT - col0 * tab2.col0 DIV - col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-717
SELECT - col0 * tab2.col0 / - col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT + col2 * col1 + col0 * + col2 * - col2 + - col1 FROM tab2
----
-113447
-4297
-51253

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE NULL = col0
----

query I rowsort
SELECT DISTINCT - col2 FROM tab1 WHERE NOT col0 BETWEEN ( + col1 + col2 ) AND NULL
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-723
SELECT tab1.col2 DIV + col2 - col1 AS col1 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-723
SELECT tab1.col2 / + col2 - col1 AS col1 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT + col1 * col1 * + col1 AS col2 FROM tab2
----
205379
29791
4913

onlyif mysql # use DIV operator for integer division
query I rowsort label-725
SELECT - col1 DIV tab0.col1 + tab0.col0 AS col2 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-725
SELECT - col1 / tab0.col1 + tab0.col0 AS col2 FROM tab0
----
23
34
88

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

skipif mysql # not compatible
query I rowsort label-726
SELECT - - col1 + col1 * CAST ( + col2 AS INTEGER ) + col1 FROM tab2 AS cor0
----
1652
680
899

query I rowsort
SELECT + col0 * cor0.col1 * 77 + col1 FROM tab0 AS cor0
----
159014
261512
623714

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

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

query I rowsort
SELECT ALL + 15 * col1 FROM tab2 cor0
----
255
465
885

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-730
SELECT DISTINCT + 1 + tab0.col1 * - col0 - CAST( - 6 AS SIGNED ) FROM tab0
----
-2057
-3388
-8092

skipif mysql # not compatible
query I rowsort label-730
SELECT DISTINCT + 1 + tab0.col1 * - col0 - CAST ( - 6 AS INTEGER ) FROM tab0
----
-2057
-3388
-8092

query I rowsort
SELECT cor0.col2 * + tab2.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 1fcf8ce9be0db19b3883c362d1041dbe

query I rowsort
SELECT - col0 + - tab2.col1 * tab2.col1 + col1 AS col1 FROM tab2
----
-3500
-351
-937

query I rowsort
SELECT cor0.col0 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT col2 + col0 * + col0 * col0 + col0 AS col2 FROM tab0
----
13881
42911
705140

onlyif mysql # use DIV operator for integer division
query I rowsort label-735
SELECT + 84 DIV col2 + col2 FROM tab1
----
55
58
96

skipif mysql # not compatible
query I rowsort label-735
SELECT + 84 / col2 + col2 FROM tab1
----
55
58
96

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

skipif mysql # not compatible
query I rowsort label-736
SELECT DISTINCT col2 + + tab1.col1 / 36 FROM tab1
----
54
57
96

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

query I rowsort
SELECT + col0 + + 27 AS col1 FROM tab2 AS cor0
----
105
106
34

query I rowsort
SELECT ALL ( col1 ) + col0 * col0 FROM tab2
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 37 col1 FROM tab2
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-741
SELECT col0 DIV col2 + ( - tab1.col1 ) AS col1 FROM tab1
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-741
SELECT col0 / col2 + ( - tab1.col1 ) AS col1 FROM tab1
----
-13
-26
-9

query I rowsort
SELECT ALL + col1 + + tab2.col1 * tab2.col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT DISTINCT 92 * - 77 FROM tab0, tab2 cor0, tab2 cor1
----
-7084

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 + ( + col1 ) col1 FROM tab0
----
132
7389
878

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 + - col2 col0 FROM tab1
----
108
3591
7584

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

query I rowsort
SELECT DISTINCT 80 + ( cor0.col0 ) FROM tab1 cor0
----
144
160
83

query I rowsort
SELECT - 51 * 7 * col2 FROM tab2 cor0
----
-13566
-9282
-9639

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - col1 AS REAL ) col1 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-751
SELECT CAST( col2 AS SIGNED ) + - col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-751
SELECT CAST ( col2 AS INTEGER ) + - col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

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

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

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

query I rowsort
SELECT - tab2.col2 * col2 + col2 * col2 * + col1 AS col2 FROM tab2
----
21870
23104
39208

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-756
SELECT DISTINCT col2 + col0 DIV col2 - col0 AS col2 FROM tab1
----
-6
16
51

skipif mysql # not compatible
query I rowsort label-756
SELECT DISTINCT col2 + col0 / col2 - col0 AS col2 FROM tab1
----
-6
16
51

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

query I rowsort
SELECT DISTINCT + - 80 + col2 + + col0 AS col0 FROM tab0 cor0
----
-23
-44
91

query I rowsort
SELECT DISTINCT + ( + col1 ) + col2 * ( + 34 ) FROM tab0 AS cor0
----
1208
131
2879

query I rowsort
SELECT - + 78 + - cor0.col0 * - col1 AS col2 FROM tab2 cor0
----
1265
139
4524

query I rowsort
SELECT DISTINCT - + ( col0 ) * cor0.col0 AS col1 FROM tab1 cor0
----
-4096
-6400
-9

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

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

query I rowsort
SELECT DISTINCT + 18 * - col1 FROM tab2 AS cor0
----
-1062
-306
-558

query I rowsort
SELECT + + 35 AS col0 FROM tab1 AS cor0
----
35
35
35

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col0 ) col2 FROM tab2
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col1 * + col0 * col0 col2 FROM tab0
----
-118922
-49622
-720902

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

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

query I rowsort
SELECT ALL + ( 63 ) + - cor0.col0 FROM tab1 AS cor0
----
-1
-17
60

query I rowsort
SELECT ALL - 51 + + cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-7349
-843
-86

query I rowsort
SELECT + 84 * col1 - col0 FROM tab1 AS cor0
----
1012
2181
776

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

query I rowsort
SELECT ALL - + col1 + col2 - col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col2 * + col1 + col1 * col0 FROM tab1 AS cor0
----
-1326
-208
70

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 97 + col2 * + col0 col0 FROM tab0 cor0
----
-62
695
7201

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

query I rowsort
SELECT DISTINCT - ( - col1 ) * + col1 + col0 * col2 AS col1 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT 49 * - col2 + - col1 FROM tab0 AS cor0
----
-146
-1703
-4109

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 + + col0 col2 FROM tab1 AS cor0
----
120
136
59

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

skipif mysql # not compatible
query I rowsort label-786
SELECT ALL - col0 + + 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-787
SELECT - col2 DIV col0 + col1 * + col2 AS col2 FROM tab0 AS cor0
----
2837
7462
97

skipif mysql # not compatible
query I rowsort label-787
SELECT - col2 / col0 + col1 * + col2 AS col2 FROM tab0 AS cor0
----
2837
7462
97

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

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

query I rowsort
SELECT ALL + + col2 * col0 * col2 AS col1 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT - cor0.col2 * + ( col2 ) + col1 * - col1 * + col2 AS col1 FROM tab2 AS cor0
----
-12426
-26676
-91182

query I rowsort
SELECT + - col1 * + 32 AS col2 FROM tab0 AS cor0
----
-2752
-2912
-3104

query I rowsort
SELECT DISTINCT + col1 * col1 + col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT col0 * + 86 AS col2 FROM tab0 AS cor0
----
2064
3010
7654

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-797
SELECT - col1 DIV + col1 + - 69 FROM tab2
----
-70
-70
-70

skipif mysql # not compatible
query I rowsort label-797
SELECT - col1 / + col1 + - 69 FROM tab2
----
-70
-70
-70

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 * 73 + + tab1.col2 col0 FROM tab1
----
-102438
-41553
-91008

query I rowsort
SELECT tab1.col0 AS col0 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

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

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

query I rowsort
SELECT - col0 * + col1 + - col1 * 96 AS col0 FROM tab0 AS cor0
----
-10320
-12707
-16835

query I rowsort
SELECT - - 12 * cor0.col0 FROM tab1 AS cor0
----
36
768
960

query I rowsort
SELECT DISTINCT + + 59 + 88 AS col1 FROM tab1 AS cor0
----
147

query I rowsort
SELECT DISTINCT - + ( ( col2 ) ) - - 44 FROM tab1 AS cor0
----
-10
-13
-52

query I rowsort
SELECT - - 35 + - col1 FROM tab0 AS cor0
----
-51
-56
-62

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-811
SELECT ALL col2 - - col0 DIV - col2 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-811
SELECT ALL col2 - - col0 / - col2 FROM tab0 AS cor0
----
-34
33
81

query I rowsort
SELECT DISTINCT col0 * 92 * col2 FROM tab1
----
14904
335616
706560

query I rowsort
SELECT + + 44 * + 60 + col0 FROM tab0 AS cor0
----
2664
2675
2729

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

skipif mysql # not compatible
query I rowsort label-814
SELECT - cor0.col1 / + 88 + cor0.col0 AS col1 FROM tab2 AS cor0
----
7
78
79

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

query I rowsort
SELECT DISTINCT - + col1 + - cor0.col0 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
-2009
-213
-2940

query I rowsort
SELECT + col1 + - 42 AS col2 FROM tab0 AS cor0
----
44
49
55

query I rowsort
SELECT ( 94 ) * col1 + 15 FROM tab2 AS cor0
----
1613
2929
5561

query I rowsort
SELECT ALL cor0.col0 + + 17 * - 10 FROM tab2, tab2 AS cor0
----
9 values hashing to 04c78da2e0e3fd00f6bf9d74cfe37184

query I rowsort
SELECT + + 5 * cor0.col0 * col1 AS col1 FROM tab1 AS cor0
----
3200
390
5200

query I rowsort
SELECT 49 * col0 AS col2 FROM tab0 AS cor0
----
1176
1715
4361

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + + ( + ( col1 ) ) * col1 col0 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT + - cor0.col2 * 37 * col2 AS col1 FROM tab2 AS cor0
----
-25012
-26973
-53428

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

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

query I rowsort
SELECT + col0 * ( - 92 ) AS col2 FROM tab0 AS cor0
----
-2208
-3220
-8188

query I rowsort
SELECT - + cor0.col2 * - 95 AS col0 FROM tab0 AS cor0
----
3135
7790
95

query I rowsort
SELECT col2 * col2 - col0 * col0 * col1 FROM tab0 AS cor0
----
-118824
-48447
-714087

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

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

query I rowsort
SELECT ALL col0 + + ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + col2 + 51 * - ( + col1 ) * 45 FROM tab2 AS cor0
----
-135379
-38977
-71118

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col1 FROM tab0, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + col1 * col2 * - 64 FROM tab0 AS cor0
----
-181632
-477568
-6208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 59 * 69 col2 FROM tab0 AS cor0
----
134343
333822
4071

query I rowsort
SELECT DISTINCT col0 * ( + col1 * col0 + cor0.col0 ) FROM tab1 AS cor0
----
243
45056
89600

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

query I rowsort
SELECT + - col0 * cor0.col2 + 49 FROM tab2 AS cor0
----
-140
-1979
-2953

query I rowsort
SELECT + - col1 * + ( col2 + col1 * + col2 ) AS col1 FROM tab2 AS cor0
----
-11628
-26784
-92040

onlyif mysql # use DIV operator for integer division
query I rowsort label-838
SELECT col0 * ( col0 ) + - col1 DIV 90 + + col2 FROM tab0
----
1225
609
8002

skipif mysql # not compatible
query I rowsort label-838
SELECT col0 * ( col0 ) + - col1 / 90 + + col2 FROM tab0
----
1225
609
8002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + 40 + + col1 col2 FROM tab0 cor0
----
138
159
213

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

skipif mysql # not compatible
query I rowsort label-840
SELECT CAST ( + col2 AS INTEGER ) * + col2 + - col2 FROM tab1 AS cor0
----
2862
3192
9120

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-842
SELECT DISTINCT col0 * 18 + col2 DIV col1 + + 48 AS col0 FROM tab1 AS cor0
----
104
1205
1495

skipif mysql # not compatible
query I rowsort label-842
SELECT DISTINCT col0 * 18 + col2 / col1 + + 48 AS col0 FROM tab1 AS cor0
----
104
1205
1495

query I rowsort
SELECT DISTINCT - + col1 - - col0 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - 10 col1 FROM tab0
----
-11
-43
-92

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

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

query I rowsort
SELECT ALL ( 35 ) * col1 + - col1 FROM tab0
----
2924
3094
3298

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col1 AS REAL ) + col2 * tab2.col2 * 10 AS col0 FROM tab2
----
14457
6819
7321

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

query I rowsort
SELECT - cor1.col1 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

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

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

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

query I rowsort
SELECT ALL 79 AS col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to da0116d31b8af0da9f685c090d378baf

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

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

query I rowsort
SELECT + col0 + 78 AS col1 FROM tab0 AS cor0
----
102
113
167

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

query I rowsort
SELECT ALL - + col2 * col1 + - ( + col2 ) * col1 FROM tab1 AS cor0
----
-1140
-2496
-2808

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-860
SELECT DISTINCT + + 52 DIV + col1 FROM tab1 AS cor0
----
2
4
5

skipif mysql # not compatible
query I rowsort label-860
SELECT DISTINCT + + 52 / + col1 FROM tab1 AS cor0
----
2
4
5

query I rowsort
SELECT ALL - cor0.col0 AS col1 FROM tab0, tab2 cor0, tab2, tab2 AS cor1
----
81 values hashing to adaea38eae032c1639715f21831dd376

query I rowsort
SELECT 52 * col2 AS col1 FROM tab0 AS cor0
----
1716
4264
52

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

query I rowsort
SELECT ALL + - col1 * cor0.col0 + col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1488
-178
-2170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * - 79 col2 FROM tab2 cor0
----
2054
2133
3002

query I rowsort
SELECT + col1 * ( - col2 * + col2 ) AS col0 FROM tab0 AS cor0
----
-611884
-93654
-97

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

query I rowsort
SELECT - + col2 * - 30 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT ALL + col1 * + 85 FROM tab0 AS cor0
----
7310
7735
8245

query I rowsort
SELECT ALL col2 + 22 * - col2 AS col2 FROM tab0 AS cor0
----
-1722
-21
-693

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

query I rowsort
SELECT ALL + col1 + col2 + cor0.col0 FROM tab1 AS cor0
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-873
SELECT ALL + tab0.col1 DIV col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-873
SELECT ALL + tab0.col1 / col2 FROM tab0
----
1
2
97

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

query I rowsort
SELECT ALL col1 * + ( - 47 ) AS col2 FROM tab1
----
-1222
-470
-611

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

query I rowsort
SELECT - 40 * col2 + col0 AS col2 FROM tab2 cor0
----
-1073
-1441
-962

query I rowsort
SELECT - col2 * 68 AS col2 FROM tab0 AS cor0
----
-2244
-5576
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 * - cor0.col2 + + cor0.col0 col1 FROM tab1, tab0 cor0
----
9 values hashing to 0fccdfcc1e4dd7d96d000629e9656f72

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

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

query I rowsort
SELECT DISTINCT 84 * col1 * col2 FROM tab1
----
104832
117936
47880

query I rowsort
SELECT ALL 40 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT 8 + col1 AS col2 FROM tab0 AS cor0
----
105
94
99

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 + - col0 * + cor0.col2 * col1 col1 FROM tab2 AS cor0
----
-119641
-51023
-5848

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-887
SELECT DISTINCT + CAST( 56 + col2 AS SIGNED ) * col0 * - 81 AS col2 FROM tab2
----
-47061
-518076
-601506

skipif mysql # not compatible
query I rowsort label-887
SELECT DISTINCT + CAST ( 56 + col2 AS INTEGER ) * col0 * - 81 AS col2 FROM tab2
----
-47061
-518076
-601506

query I rowsort
SELECT ALL col1 + col2 + + 93 * tab0.col0 FROM tab0
----
2351
3353
8450

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-890
SELECT - col2 + + col1 DIV col1 + - col1 * col0 AS col2 FROM tab1
----
-1135
-131
-696

skipif mysql # not compatible
query I rowsort label-890
SELECT - col2 + + col1 / col1 + - col1 * col0 AS col2 FROM tab1
----
-1135
-131
-696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 + col2 * 90 col1 FROM tab2
----
2366
2457
3458

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

query I rowsort
SELECT + 30 + + col1 * col0 * col0 AS col0 FROM tab2
----
106127
1549
358986

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

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

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

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

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

query I rowsort
SELECT ALL - col2 + col2 + - col0 * 15 FROM tab2
----
-105
-1170
-1185

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

query I rowsort
SELECT DISTINCT 7 + - col1 FROM tab0
----
-79
-84
-90

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 16 col1 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 23 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

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

query I rowsort
SELECT + col0 * 25 + + 80 * col0 AS col1 FROM tab2 AS cor0
----
735
8190
8295

query I rowsort
SELECT - col2 + ( 86 ) AS col2 FROM tab2 AS cor0
----
48
59
60

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-911
SELECT - - col0 + col0 / col1 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col1 col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - 41 + col2 + - 78 FROM tab2 AS cor0
----
-81
-92
-93

query I rowsort
SELECT - col0 + col1 * + 75 - - col1 * - col1 FROM tab1 AS cor0
----
1271
586
726

query I rowsort
SELECT 82 * 94 FROM tab1
----
7708
7708
7708

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

query I rowsort
SELECT ALL - - 52 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7f4ae30893ab330784829711032ae599

onlyif mysql # use DIV operator for integer division
query I rowsort label-918
SELECT DISTINCT 89 DIV + col0 - - col1 col2 FROM tab2
----
18
43
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-918
SELECT DISTINCT 89 / + col0 - - col1 col2 FROM tab2
----
18
43
60

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

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

skipif mysql # not compatible
query I rowsort label-920
SELECT + - col2 - - col2 / col1 AS col0 FROM tab2 AS cor0
----
-26
-27
-36

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

skipif mysql # not compatible
query I rowsort label-921
SELECT - col2 + + col1 / col0 AS col2 FROM tab2 AS cor0
----
-23
-26
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-922
SELECT + col0 DIV 94 + - col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-922
SELECT + col0 / 94 + - col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

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

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

query I rowsort
SELECT + col0 * 46 FROM tab1 AS cor0
----
138
2944
3680

query I rowsort
SELECT - col1 * + 13 FROM tab0 AS cor0
----
-1118
-1183
-1261

query I rowsort
SELECT col0 * 96 AS col1 FROM tab2 AS cor0
----
672
7488
7584

query I rowsort
SELECT ALL - + ( col2 ) + col1 * - 79 FROM tab1 AS cor0
----
-1123
-2108
-847

query I rowsort
SELECT DISTINCT + 83 * + cor0.col0 FROM tab1 AS cor0
----
249
5312
6640

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

query I rowsort
SELECT + ( + 53 ) AS col0 FROM tab0 AS cor0
----
53
53
53

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

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

query I rowsort
SELECT + - col0 * 47 AS col0 FROM tab0 cor0
----
-1128
-1645
-4183

query I rowsort
SELECT ALL ( col1 ) - - col2 AS col0 FROM tab2 AS cor0
----
55
58
85

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

query I rowsort
SELECT + col2 + + 24 * cor0.col2 FROM tab0 AS cor0
----
2050
25
825

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-941
SELECT ALL - + col2 + col0 * col0 DIV - col0 FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-941
SELECT ALL - + col2 + col0 * col0 / - col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + col0 * col0 * col0 + col2 AS col2 FROM tab2 AS cor0
----
370
474578
493077

query I rowsort
SELECT col2 * - col1 + - 66 AS col1 FROM tab1 AS cor0
----
-1314
-1470
-636

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + + 3 * + ( - col1 * cor0.col0 ) col2 FROM tab2 AS cor0
----
-13747
-4012
-620

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

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

query I rowsort
SELECT ALL - cor0.col1 * - ( 38 ) + - cor0.col1 * 89 AS col2 FROM tab2 AS cor0
----
-1581
-3009
-867

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + col1 + col0 + - tab0.col0 col0 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-949
SELECT 97 DIV 6 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

skipif mysql # not compatible
query I rowsort label-949
SELECT 97 / 6 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 78 * - col1 + - col2 col2 FROM tab0
----
-161025
-264811
-631804

query I rowsort
SELECT - col0 * 68 FROM tab0 AS cor0
----
-1632
-2380
-6052

query I rowsort
SELECT + col1 * 14 + 90 AS col1 FROM tab0 AS cor0
----
1294
1364
1448

query I rowsort
SELECT DISTINCT col2 * col2 + + tab1.col2 FROM tab1
----
2970
3306
9312

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

query I rowsort
SELECT + col1 * ( col0 ) + - col1 FROM tab0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 36 + col1 col0 FROM tab1 AS cor0
----
46
49
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-957
SELECT 0 + - col2 DIV ( 11 ) FROM tab1 AS cor0
----
-4
-5
-8

skipif mysql # not compatible
query I rowsort label-957
SELECT 0 + - col2 / ( 11 ) FROM tab1 AS cor0
----
-4
-5
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-958
SELECT ALL col2 * col2 + col2 DIV + col0 FROM tab0 AS cor0
----
1
1090
6724

skipif mysql # not compatible
query I rowsort label-958
SELECT ALL col2 * col2 + col2 / + col0 FROM tab0 AS cor0
----
1
1090
6724

query I rowsort
SELECT ALL - 95 FROM tab1, tab0 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT ALL + cor0.col0 + 70 AS col0 FROM tab1 AS cor0
----
134
150
73

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + + ( + ( col1 ) ) * - col1 col0 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT ALL + col1 * col2 + col2 * + col1 AS col2 FROM tab2 AS cor0
----
1292
1674
3068

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

query I rowsort
SELECT DISTINCT + col1 * 4 FROM tab1 AS cor0
----
104
40
52

query I rowsort
SELECT DISTINCT cor0.col2 - + 83 AS col0 FROM tab2 cor0
----
-45
-56
-57

query I rowsort
SELECT DISTINCT + + col0 + - 12 FROM tab2 AS cor0
----
-5
66
67

query I rowsort
SELECT col2 + 90 + col0 FROM tab1
----
147
211
266

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

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

query I rowsort
SELECT DISTINCT + ( - 33 ) + col2 FROM tab0
----
-32
0
49

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

query I rowsort
SELECT ALL - col0 + + 80 AS col2 FROM tab1 AS cor0
----
0
16
77

query I rowsort
SELECT ALL + 52 * col2 AS col0 FROM tab1 AS cor0
----
2808
2964
4992

query I rowsort
SELECT DISTINCT + 12 AS col2 FROM tab0, tab0 cor0, tab2 AS cor1, tab0 cor2
----
12

query I rowsort
SELECT + col0 * col2 + - col2 * - 79 + col0 * col2 AS col2 FROM tab0 AS cor0
----
149
21074
4191

query I rowsort
SELECT ALL - 53 * cor0.col2 FROM tab1 AS cor0
----
-2862
-3021
-5088

query I rowsort
SELECT DISTINCT + col2 + - col0 + col2 AS col1 FROM tab2 AS cor0
----
-26
-3
47

query I rowsort
SELECT ALL - + col2 * col1 + + col2 * 77 - - col0 AS col0 FROM tab2 AS cor0
----
1249
2359
546

query I rowsort
SELECT DISTINCT col1 + - col1 * col1 + + col1 AS col2 FROM tab1 AS cor0
----
-143
-624
-80

query I rowsort
SELECT DISTINCT + 3 AS col0 FROM tab1 cor0
----
3

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

query I rowsort
SELECT DISTINCT + ( col2 ) + + 25 AS col1 FROM tab0 AS cor0
----
107
26
58

query I rowsort
SELECT ALL - 35 * - col0 + - ( col1 * - col0 ) + col2 FROM tab1 AS cor0
----
237
2937
3936

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

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

query I rowsort
SELECT ALL + + col0 + col0 + + 5 * - 44 FROM tab1 AS cor0
----
-214
-60
-92

query I rowsort
SELECT DISTINCT + - ( cor0.col2 ) + ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT ALL - ( + col1 + tab1.col0 ) AS col0 FROM tab1
----
-29
-74
-93

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

query I rowsort
SELECT + col1 * col1 + + 27 + col0 * col0 FROM tab2 AS cor0
----
1037
6557
9592

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

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

query I rowsort
SELECT + + cor0.col2 + + 37 AS col1 FROM tab1 AS cor0
----
133
91
94

query I rowsort
SELECT - col0 + + 41 AS col2 FROM tab1 AS cor0
----
-23
-39
38

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

query I rowsort
SELECT + 99 * - col1 + - col0 * - ( - col1 ) + + col1 FROM tab1 AS cor0
----
-1620
-2314
-2626

query I rowsort
SELECT col1 * - 16 * + col0 AS col0 FROM tab2 cor0
----
-21488
-3472
-73632

query I rowsort
SELECT + col1 * + col1 - col2 * - col2 AS col0 FROM tab0 AS cor0
----
15005
8485
9410

query I rowsort
SELECT ALL 2 * + ( col2 ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT - - 14 * 10 AS col1 FROM tab2 AS cor0
----
140

query I rowsort
SELECT - + col0 * + col2 - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 col2 FROM tab1, tab0, tab0 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + + cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL - ( col1 ) * + col0 + 35 + 11 AS col2 FROM tab2
----
-1297
-171
-4556

query I rowsort
SELECT DISTINCT - 42 * 48 + + col2 * - ( - col2 * + col0 ) FROM tab2
----
112060
3087
50712

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

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

skipif mysql # not compatible
query I rowsort label-1007
SELECT DISTINCT + cor0.col0 / + col1 + cor0.col2 AS col0 FROM tab2 AS cor0
----
27
42

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

query I rowsort
SELECT DISTINCT + - col0 * col0 + + col1 FROM tab1 AS cor0
----
-4086
-6387
17

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

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

query I rowsort
SELECT ALL + 82 AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

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

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

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

skipif mysql # not compatible
query I rowsort label-1015
SELECT ALL - + col2 + - col1 / col0 AS col2 FROM tab1 AS cor0
----
-57
-62
-96

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

query I rowsort
SELECT DISTINCT - col0 * + col0 + + col0 * col2 FROM tab2 cor0
----
-3239
-4056
140

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

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

query I rowsort
SELECT col0 * col0 * - col0 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT DISTINCT - + col1 + col0 * - col0 * col0 AS col2 FROM tab0 cor0
----
-13910
-42972
-705060

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

query I rowsort
SELECT ALL - 5 * + col1 * + col1 FROM tab0 AS cor0
----
-36980
-41405
-47045

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 56 col2 FROM tab0
----
-1344
-1960
-4984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 10 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT DISTINCT + 53 * + col1 AS col1 FROM tab0
----
4558
4823
5141

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

query I rowsort
SELECT 38 * + col0 FROM tab2 AS cor0
----
266
2964
3002

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1031
SELECT 45 DIV col0 AS col0 FROM tab1 AS cor0
----
0
0
15

skipif mysql # not compatible
query I rowsort label-1031
SELECT 45 / col0 AS col0 FROM tab1 AS cor0
----
0
0
15

query I rowsort
SELECT + 42 * + col2 AS col0 FROM tab0 AS cor0
----
1386
3444
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-1033
SELECT col1 DIV - tab2.col1 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1033
SELECT col1 / - tab2.col1 AS col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col0 * - col2 + + col1 * - col0 AS col2 FROM tab0
----
-15397
-2856
-3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col0 + col2 col2 FROM tab0
----
260
71
81

query I rowsort
SELECT col1 + + col2 * + col1 AS col0 FROM tab1
----
1261
1430
580

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

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

query I rowsort
SELECT DISTINCT + col2 FROM tab1 WHERE NOT NULL <= ( NULL )
----

query I rowsort
SELECT DISTINCT tab0.col0 AS col0 FROM tab0 WHERE NULL <= ( - col2 * col1 )
----

query I rowsort
SELECT DISTINCT - col0 AS col2 FROM tab1 WHERE NOT NULL <> ( NULL )
----

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

query I rowsort
SELECT col0 * tab1.col1 * tab1.col1 - + col0 FROM tab1
----
13440
2025
6336

query I rowsort
SELECT - tab1.col0 + + col0 * + col0 FROM tab1
----
4032
6
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 col1 FROM tab0
----
-2064
-3395
-8099

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

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

query I rowsort
SELECT DISTINCT col2 - tab2.col0 * col0 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT ALL col2 - - tab1.col2 AS col1 FROM tab1
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + col0 col2 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT col0 - col2 * + tab2.col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL + col1 - col1 * - col1 FROM tab0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-1053
SELECT ALL col0 DIV tab0.col1 + + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1053
SELECT ALL col0 / tab0.col1 + + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT col2 * col0 + tab1.col0 FROM tab1
----
165
3712
7760

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

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

query I rowsort
SELECT col0 + + tab2.col1 * - col0 - col1 * - col1 * col0 FROM tab2
----
21567
266994
6517

onlyif mysql # use DIV operator for integer division
query I rowsort label-1058
SELECT + col0 * - col0 DIV + col0 + + col1 * + col1 FROM tab2 AS cor0
----
210
3403
954

skipif mysql # not compatible
query I rowsort label-1058
SELECT + col0 * - col0 / + col0 + + col1 * + col1 FROM tab2 AS cor0
----
210
3403
954

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1062
SELECT + cor0.col2 * + col1 DIV cor0.col1 - - cor0.col1 * - col0 FROM tab1 AS cor0
----
-24
-583
-944

skipif mysql # not compatible
query I rowsort label-1062
SELECT + cor0.col2 * + col1 / cor0.col1 - - cor0.col1 * - col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT col2 + + col2 * cor0.col2 FROM tab2 AS cor0
----
1482
702
756

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT col2 + col2 * col1 + col1 BETWEEN col0 AND NULL
----

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

query I rowsort
SELECT - col1 AS col1 FROM tab2 AS cor0 WHERE NULL NOT IN ( cor0.col0 )
----

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

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

query I rowsort
SELECT ALL col0 + + col1 + col1 AS col2 FROM tab0 AS cor0
----
196
229
271

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

query I rowsort
SELECT - col1 + + col0 AS col1 FROM tab0 AS cor0 WHERE NOT NULL >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1073
SELECT + cor0.col2 DIV cor0.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-1073
SELECT + cor0.col2 / cor0.col0 col2 FROM tab2 AS cor0
----
0
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1074
SELECT col1 + - col2 DIV col0 FROM tab0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-1074
SELECT col1 + - col2 / col0 FROM tab0
----
85
91
97

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

query I rowsort
SELECT + col1 + 84 FROM tab1 AS cor0
----
110
94
97

query I rowsort
SELECT DISTINCT + 27 * col2 AS col1 FROM tab1 AS cor0
----
1458
1539
2592

query I rowsort
SELECT 39 + 11 * col2 FROM tab0 AS cor0
----
402
50
941

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

query I rowsort
SELECT DISTINCT 60 * col0 - col0 AS col2 FROM tab2 AS cor0
----
413
4602
4661

query I rowsort
SELECT ALL - tab0.col0 * tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 4734c38591591662f77999e8d1e5daf1

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

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

query I rowsort
SELECT DISTINCT + col1 + - ( - 81 ) + - col2 AS col0 FROM tab1
----
-2
34
53

query IIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab2 AS cor0 WHERE NOT NULL > cor0.col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 33 ) col1 FROM tab2
----
33

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

query I rowsort
SELECT - - 75 * col2 AS col1 FROM tab1 AS cor0
----
4050
4275
7200

query I rowsort
SELECT DISTINCT - col1 * 93 AS col1 FROM tab2
----
-1581
-2883
-5487

query I rowsort
SELECT col0 + + col2 * 72 + + 25 * tab0.col2 AS col0 FROM tab0
----
132
3225
8043

query I rowsort
SELECT - - col1 + + 3 - 2 * col0 FROM tab1 cor0
----
-115
-144
23

query I rowsort
SELECT 32 * col1 + - col1 + ( + col0 ) FROM tab0
----
2690
2910
3042

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

skipif mysql # not compatible
query I rowsort label-1092
SELECT DISTINCT + col1 + col2 / ( col1 ) FROM tab2
----
19
31
59

query I rowsort
SELECT - col1 * 74 FROM tab1
----
-1924
-740
-962

onlyif mysql # use DIV operator for integer division
query I rowsort label-1094
SELECT - tab1.col1 DIV + 77 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1094
SELECT - tab1.col1 / + 77 FROM tab1
----
0
0
0

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

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

query I rowsort
SELECT DISTINCT 49 * + 8 * + tab2.col0 + - 53 FROM tab2, tab0 AS cor0
----
2691
30523
30915

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1098
SELECT ALL col1 * + 14 + - col0 DIV - col0 FROM tab2
----
239
435
827

skipif mysql # not compatible
query I rowsort label-1098
SELECT ALL col1 * + 14 + - col0 / - col0 FROM tab2
----
239
435
827

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

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

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

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

query I rowsort
SELECT ( col2 * col0 ) - col0 FROM tab0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 64 * ( col2 ) + col0 * tab1.col1 col0 FROM tab1
----
-3008
-3378
-5104

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1104
SELECT ALL - 33 DIV 47 + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1104
SELECT ALL - 33 / 47 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - col2 * + col2 + - col0 AS col1 FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1106
SELECT DISTINCT col0 + + col0 * - CAST( 21 * col2 AS SIGNED ) FROM tab1 AS cor0
----
-161200
-3399
-76544

skipif mysql # not compatible
query I rowsort label-1106
SELECT DISTINCT col0 + + col0 * - CAST ( 21 * col2 AS INTEGER ) FROM tab1 AS cor0
----
-161200
-3399
-76544

query I rowsort
SELECT ALL + col2 * + col1 - ( 28 ) * + cor0.col2 FROM tab2 AS cor0
----
-418
806
81

query I rowsort
SELECT ALL - ( 87 ) FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to c0011cd00aa3e86f06bebc13678997f9

query I rowsort
SELECT + 86 * col0 * - 17 FROM tab2 AS cor0
----
-10234
-114036
-115498

query I rowsort
SELECT col2 + + ( - col2 ) * - col0 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - col0 * + col2 * + 95 AS col0 FROM tab2 AS cor0
----
-17955
-192660
-285190

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

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

query I rowsort
SELECT ALL - 72 * + cor0.col1 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 31d3ddcf60e3c8205de69314baba4dc5

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

query I rowsort
SELECT ALL - 7 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

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

query I rowsort
SELECT - tab2.col0 - col1 * + 88 AS col2 FROM tab2
----
-1575
-2735
-5270

query I rowsort
SELECT col2 * col1 * 94 + - 25 * col0 * col0 AS col0 FROM tab0
----
-21507
252372
503403

query I rowsort
SELECT DISTINCT 0 * col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 51 * - cor0.col2 AS col1 FROM tab1 cor0
----
2754
2907
4896

query I rowsort
SELECT 93 * - cor1.col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 22cd9eecfbc12939b87837885b66c696

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col2 * + cor0.col2 col2 FROM tab2 cor0
----
1406
650
702

query I rowsort
SELECT DISTINCT + col1 + 71 AS col0 FROM tab0 cor0
----
157
162
168

query I rowsort
SELECT ALL - - col2 + 30 AS col2 FROM tab1 AS cor0
----
126
84
87

query I rowsort
SELECT DISTINCT + + col0 + 17 AS col1 FROM tab2 AS cor0
----
24
95
96

query I rowsort
SELECT ALL - col0 * + 68 * + col2 FROM tab1 AS cor0
----
-11016
-248064
-522240

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

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

query I rowsort
SELECT ALL - col1 * cor0.col1 + + ( + col2 ) * ( col0 ) FROM tab2 AS cor0
----
-1453
-772
2713

query I rowsort
SELECT DISTINCT - col1 * - 80 + - 42 FROM tab1 AS cor0
----
2038
758
998

query I rowsort
SELECT ALL col0 - + ( - col2 + col1 ) FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT - - col2 + col2 * - col2 + col0 * - col0 * col0 AS col0 FROM tab2 AS cor0
----
-1045
-475202
-494445

query I rowsort
SELECT ( - col2 ) * - col1 + ( + cor0.col0 * + col2 ) AS col2 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT DISTINCT ( 65 ) AS col0 FROM tab0, tab0 AS cor0
----
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-1137
SELECT DISTINCT - col2 DIV - 71 AS col1 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-1137
SELECT DISTINCT - col2 / - 71 AS col1 FROM tab0
----
0
1

query I rowsort
SELECT ALL - cor0.col0 + tab2.col2 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 346ecce5023d3440fcfb161aa071fa19

query I rowsort
SELECT + ( 80 ) * - col1 AS col0 FROM tab0 AS cor0
----
-6880
-7280
-7760

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

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

skipif mysql # not compatible
query I rowsort label-1141
SELECT + - CAST ( - col1 AS INTEGER ) + col2 FROM tab1 AS cor0
----
109
67
80

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

query I rowsort
SELECT - 71 + col1 FROM tab2 AS cor0
----
-12
-40
-54

query I rowsort
SELECT ALL - col1 * - col0 + 31 FROM tab1 AS cor0
----
1071
109
671

query I rowsort
SELECT DISTINCT - - cor0.col1 + col0 * - col0 FROM tab1 AS cor0
----
-4086
-6387
17

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

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

query I rowsort
SELECT DISTINCT - + 6 + col1 * col1 FROM tab1 AS cor0
----
163
670
94

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

skipif mysql # not compatible
query I rowsort label-1149
SELECT ALL + + 15 * col0 / - col0 FROM tab0 AS cor0
----
-15
-15
-15

query I rowsort
SELECT DISTINCT + + col0 + cor0.col2 * ( 77 ) FROM tab0 cor0
----
112
2565
6403

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

skipif mysql # not compatible
query I rowsort label-1151
SELECT DISTINCT col0 / - cor0.col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT - 55 + + col0 FROM tab2
----
-48
23
24

query I rowsort
SELECT DISTINCT 58 - col1 FROM tab1
----
32
45
48

query I rowsort
SELECT ALL tab0.col0 * col2 * 10 + 78 FROM tab0
----
428
73058
7998

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

query I rowsort
SELECT DISTINCT - 20 * + col2 AS col0 FROM tab2 AS cor0
----
-520
-540
-760

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

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

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

query I rowsort
SELECT ALL 12 + + col0 * - col2 FROM tab2
----
-177
-2016
-2990

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

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

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

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

query I rowsort
SELECT + - col2 + + 91 FROM tab2 AS cor0
----
53
64
65

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

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

query I rowsort
SELECT DISTINCT - ( - col2 ) + col2 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - 64 FROM tab1, tab0 AS cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT DISTINCT ( - cor0.col2 ) + 61 AS col2 FROM tab2, tab0 AS cor0
----
-21
28
60

query I rowsort
SELECT col1 * ( col2 ) + + 36 FROM tab2 AS cor0
----
1570
682
873

query I rowsort
SELECT ALL + cor0.col1 * - cor0.col2 - ( - col2 ) AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

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

query I rowsort
SELECT DISTINCT + col0 + col1 * + cor0.col2 * col0 FROM tab1 AS cor0
----
36544
4215
99920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 * cor0.col0 - + col0 col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT DISTINCT - + col1 + 26 FROM tab1 AS cor0
----
0
13
16

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

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

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

query I rowsort
SELECT ALL - - col2 * - 8 * 98 FROM tab1 AS cor0
----
-42336
-44688
-75264

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 + 2 AS col1 FROM tab1 AS cor0
----
111
69
82

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

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

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

query I rowsort
SELECT + col1 + - 24 * - 70 AS col2 FROM tab2 AS cor0
----
1697
1711
1739

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1182
SELECT - - col2 * CAST( - col2 * - col2 AS SIGNED ) FROM tab1 AS cor0
----
157464
185193
884736

skipif mysql # not compatible
query I rowsort label-1182
SELECT - - col2 * CAST ( - col2 * - col2 AS INTEGER ) FROM tab1 AS cor0
----
157464
185193
884736

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

query I rowsort
SELECT + col1 - + 71 * + col2 AS col0 FROM tab0 AS cor0
----
-2257
-5731
26

query I rowsort
SELECT + - col2 + + ( col1 ) * - col1 FROM tab1 AS cor0
----
-157
-265
-730

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

query I rowsort
SELECT - - ( 79 ) + + col0 FROM tab1 AS cor0
----
143
159
82

query I rowsort
SELECT col0 * col2 * col0 + + cor0.col1 * col2 * + cor0.col0 FROM tab2 AS cor0
----
277836
288192
7182

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

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

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

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

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

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

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

query I rowsort
SELECT ALL col1 - tab1.col2 * tab1.col1 AS col0 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT ALL + col1 + - col2 * - col1 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + - col0 * col0 col2 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-1197
SELECT + cor0.col2 DIV 23 + 55 * + tab1.col0 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 840c638fe1ca6630f77dee531188e6ed

skipif mysql # not compatible
query I rowsort label-1197
SELECT + cor0.col2 / 23 + 55 * + tab1.col0 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 840c638fe1ca6630f77dee531188e6ed

query I rowsort
SELECT 16 * col0 + - 91 * col0 FROM tab1
----
-225
-4800
-6000

onlyif mysql # use DIV operator for integer division
query I rowsort label-1199
SELECT + col1 + ( 40 ) DIV col0 FROM tab0 AS cor0
----
87
91
98

skipif mysql # not compatible
query I rowsort label-1199
SELECT + col1 + ( 40 ) / col0 FROM tab0 AS cor0
----
87
91
98

query I rowsort
SELECT 75 + - col2 AS col1 FROM tab2
----
37
48
49

query I rowsort
SELECT DISTINCT - 79 * + col0 FROM tab2
----
-553
-6162
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-1202
SELECT cor1.col1 DIV 7 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 14abe0a65ffde3428a361c66e935c2aa

skipif mysql # not compatible
query I rowsort label-1202
SELECT cor1.col1 / 7 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 14abe0a65ffde3428a361c66e935c2aa

query I rowsort
SELECT ALL + col2 * + 12 * col1 AS col1 FROM tab0
----
1164
34056
89544

query I rowsort
SELECT tab1.col2 * + ( + 30 + + tab1.col1 * ( + col2 ) ) FROM tab1
----
122688
34200
77436

onlyif mysql # use DIV operator for integer division
query I rowsort label-1205
SELECT col1 DIV CAST( - 16 + - col0 AS SIGNED ) AS col2 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1205
SELECT col1 / CAST ( - 16 + - col0 AS INTEGER ) AS col2 FROM tab1
----
-1
0
0

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1208
SELECT + + col0 + - CAST( 87 AS SIGNED ) * + col2 FROM tab1 AS cor0
----
-4695
-4895
-8272

skipif mysql # not compatible
query I rowsort label-1208
SELECT + + col0 + - CAST ( 87 AS INTEGER ) * + col2 FROM tab1 AS cor0
----
-4695
-4895
-8272

query I rowsort
SELECT DISTINCT ( 36 ) FROM tab2
----
36

query I rowsort
SELECT ALL cor0.col1 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to c6425afc100dd55de8d45dec18c469ea

query I rowsort
SELECT DISTINCT - 58 + col2 FROM tab0 AS cor0
----
-25
-57
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-1212
SELECT DISTINCT - 63 DIV + col0 FROM tab2 AS cor0
----
-9
0

skipif mysql # not compatible
query I rowsort label-1212
SELECT DISTINCT - 63 / + col0 FROM tab2 AS cor0
----
-9
0

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

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

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

query I rowsort
SELECT + 25 + col1 AS col0 FROM tab0 AS cor0
----
111
116
122

query I rowsort
SELECT + - cor0.col2 + col2 * 38 FROM tab2 AS cor0
----
1406
962
999

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + - col1 col1 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT + - col2 + 89 FROM tab0 AS cor0
----
56
7
88

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

skipif mysql # not compatible
query I rowsort label-1221
SELECT DISTINCT CAST ( - col2 AS INTEGER ) + - cor0.col1 * ( col2 ) FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT - + ( 53 ) * + col0 AS col0 FROM tab2 AS cor0
----
-371
-4134
-4187

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1, tab1 AS cor2, tab2
----
13122 values hashing to 2a23a2efbd7482492eade70ce0528c27

query I rowsort
SELECT DISTINCT col1 + col0 * + 42 AS col1 FROM tab0
----
1094
1567
3829

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

query I rowsort
SELECT + col0 - 89 FROM tab1 AS cor0
----
-25
-86
-9

query I rowsort
SELECT ALL 29 + + 30 FROM tab1
----
59
59
59

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

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

query I rowsort
SELECT DISTINCT col1 * + col1 * col1 + - tab0.col0 FROM tab0
----
636032
753482
912638

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1231
SELECT DISTINCT + col1 + 43 DIV - tab2.col1 FROM tab2
----
15
30
59

skipif mysql # not compatible
query I rowsort label-1231
SELECT DISTINCT + col1 + 43 / - tab2.col1 FROM tab2
----
15
30
59

query I rowsort
SELECT + ( - 96 ) + col1 FROM tab1 AS cor0
----
-70
-83
-86

query I rowsort
SELECT DISTINCT + 73 + + col1 FROM tab2 AS cor0
----
104
132
90

query I rowsort
SELECT col0 * col2 - - ( + col1 + col0 ) * + tab1.col1 FROM tab1
----
4388
8889
916

query I rowsort
SELECT - - col1 * cor0.col1 + col1 + col1 AS col1 FROM tab0 AS cor0
----
7568
8463
9603

query I rowsort
SELECT DISTINCT - col1 * col0 + col1 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1892
-3201
-7917

query I rowsort
SELECT + + col1 + + col1 * + col0 - + col0 FROM tab2 AS cor0
----
1281
241
4583

query I rowsort
SELECT DISTINCT - - col2 * - 98 AS col0 FROM tab0 AS cor0
----
-3234
-8036
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1239
SELECT col1 * col2 DIV + tab0.col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1239
SELECT col1 * col2 / + tab0.col2 FROM tab0
----
86
91
97

query I rowsort
SELECT 14 * col2 FROM tab2
----
364
378
532

query I rowsort
SELECT - col1 * + col0 + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

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

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

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

skipif mysql # not compatible
query I rowsort label-1243
SELECT ALL - - col2 + + CAST ( col0 AS INTEGER ) + col1 AS col2 FROM tab1 cor0
----
131
189
83

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT col0 / + CAST ( + col0 AS REAL ) col0 FROM tab1
----
1
1
1

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

query I rowsort
SELECT ALL 97 + + cor1.col2 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 6593798057d90420ec9fb6b5fc1b0a65

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

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

query I rowsort
SELECT - 75 * + ( + col0 ) AS col1 FROM tab0 AS cor0
----
-1800
-2625
-6675

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

query I rowsort
SELECT - ( + 82 ) - col1 AS col1 FROM tab0 AS cor0
----
-168
-173
-179

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

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

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

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

query I rowsort
SELECT DISTINCT - + 55 * + ( col0 ) FROM tab2 AS cor0
----
-385
-4290
-4345

onlyif mysql # use DIV operator for integer division
query I rowsort label-1258
SELECT ALL col2 DIV col1 + col2 AS col0 FROM tab2 cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-1258
SELECT ALL col2 / col1 + col2 AS col0 FROM tab2 cor0
----
26
27
40

query I rowsort
SELECT DISTINCT col1 - + col1 * + col0 FROM tab0 cor0
----
-1978
-3298
-8008

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

skipif mysql # not compatible
query I rowsort label-1260
SELECT DISTINCT + 13 / + col1 FROM tab0 AS cor0
----
0

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

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

query I rowsort
SELECT ALL ( + 15 ) + - col1 AS col1 FROM tab0 AS cor0
----
-71
-76
-82

query I rowsort
SELECT ALL - col1 + - cor0.col1 * - col0 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

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

query I rowsort
SELECT ALL + 24 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

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

skipif mysql # not compatible
query I rowsort label-1266
SELECT DISTINCT + col2 / CAST ( NULL AS REAL ) + + col1 FROM tab1
----
NULL

query I rowsort
SELECT ALL tab2.col0 - ( + col0 * col1 + + tab2.col2 ) AS col1 FROM tab2
----
-1302
-237
-4550

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

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

query I rowsort
SELECT DISTINCT + 73 - + col1 FROM tab1 AS cor0
----
47
60
63

query I rowsort
SELECT DISTINCT - col0 + col0 * 10 AS col1 FROM tab1 cor0
----
27
576
720

query I rowsort
SELECT ALL - 73 + col1 FROM tab1 AS cor0
----
-47
-60
-63

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

skipif mysql # not compatible
query I rowsort label-1272
SELECT ALL + 76 / - col1 AS col1 FROM tab2 AS cor0
----
-1
-2
-4

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

query I rowsort
SELECT DISTINCT + 70 + cor0.col1 FROM tab2 AS cor0
----
101
129
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col0 * - cor0.col0 col0 FROM tab0 AS cor0
----
1260
600
8010

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

query I rowsort
SELECT ALL 6 - + col2 AS col1 FROM tab2 AS cor0
----
-20
-21
-32

query I rowsort
SELECT ALL 78 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1279
SELECT ALL col0 + + tab1.col0 * col0 DIV ( 35 ) AS col2 FROM tab1
----
181
262
3

skipif mysql # not compatible
query I rowsort label-1279
SELECT ALL col0 + + tab1.col0 * col0 / ( 35 ) AS col2 FROM tab1
----
181
262
3

query I rowsort
SELECT ALL - 33 + + col0 * col1 FROM tab1 AS cor0
----
1007
45
607

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col1 * + 60 col1 FROM tab1 AS cor0
----
1506
543
684

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

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

query I rowsort
SELECT DISTINCT - - ( + 75 ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
75

query I rowsort
SELECT col1 * - col1 * tab2.col0 + + col1 AS col1 FROM tab2
----
-22814
-271459
-6696

query I rowsort
SELECT DISTINCT ( + col2 ) * + col2 * + 6 AS col0 FROM tab1
----
17496
19494
55296

query I rowsort
SELECT DISTINCT + 53 * - cor0.col1 + col2 FROM tab1 AS cor0
----
-1324
-473
-593

query I rowsort
SELECT DISTINCT 33 * + col1 - - col0 AS col2 FROM tab2 AS cor0
----
1030
2025
640

query I rowsort
SELECT DISTINCT - 99 * + 34 + - col0 FROM tab0 cor0
----
-3390
-3401
-3455

query I rowsort
SELECT 65 + 99 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to a1509e33d3aaa01839fa4f2fb69edf25

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1292
SELECT DISTINCT - 46 DIV col2 FROM tab0 AS cor0
----
-1
-46
0

skipif mysql # not compatible
query I rowsort label-1292
SELECT DISTINCT - 46 / col2 FROM tab0 AS cor0
----
-1
-46
0

query I rowsort
SELECT 99 + - col1 AS col1 FROM tab1 AS cor0
----
73
86
89

query I rowsort
SELECT ALL - - 86 * col1 FROM tab1 AS cor0
----
1118
2236
860

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

query I rowsort
SELECT - col1 + col0 * col1 + col0 FROM tab0 AS cor0
----
2002
3333
8097

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

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

query I rowsort
SELECT + col1 + col0 + + 60 * - col0 FROM tab0 cor0
----
-1330
-1968
-5160

query I rowsort
SELECT + col0 * + col1 - 32 * col0 * col2 AS col1 FROM tab0 AS cor0
----
-225437
-23280
2275

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

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

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

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

query I rowsort
SELECT DISTINCT - - col1 * col0 + - col0 FROM tab0 cor0
----
2040
3360
8010

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

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

query I rowsort
SELECT DISTINCT - col0 + col1 * + cor0.col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + - col0 + col1 * col0 * + cor0.col0 FROM tab0 AS cor0
----
118790
49512
720722

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

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

query I rowsort
SELECT DISTINCT - col1 + 7 - + col1 FROM tab2 AS cor0
----
-111
-27
-55

query I rowsort
SELECT ALL col0 * col0 + col1 + + col2 AS col1 FROM tab0 AS cor0
----
1323
695
8094

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

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

query I rowsort
SELECT 61 + col2 * col2 * ( + col0 ) AS col0 FROM tab0 AS cor0
----
26197
598497
96

query I rowsort
SELECT - 7 * + col2 FROM tab0 cor0
----
-231
-574
-7

query I rowsort
SELECT ALL + + cor0.col0 * + 71 - + col2 AS col1 FROM tab2 AS cor0
----
470
5512
5571

query I rowsort
SELECT ALL + ( + 15 ) * col1 * col2 AS col1 FROM tab1 AS cor0
----
18720
21060
8550

query I rowsort
SELECT ALL + ( col1 ) * col1 - 80 AS col1 FROM tab0 AS cor0
----
7316
8201
9329

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

query I rowsort
SELECT ALL cor0.col0 * + 30 * cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 204e8294355f381917e9b9386e550626

onlyif mysql # use DIV operator for integer division
query I rowsort label-1318
SELECT + - 30 DIV ( - col2 ) + - 40 FROM tab1 AS cor0
----
-40
-40
-40

skipif mysql # not compatible
query I rowsort label-1318
SELECT + - 30 / ( - col2 ) + - 40 FROM tab1 AS cor0
----
-40
-40
-40

query I rowsort
SELECT 36 + + col2 AS col1 FROM tab1 AS cor0
----
132
90
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 * - col0 col0 FROM tab1 AS cor0
----
-1027
-52
-630

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

query I rowsort
SELECT - 84 * - col1 FROM tab2 AS cor0
----
1428
2604
4956

query I rowsort
SELECT ALL - col1 + + col1 * - 26 FROM tab2 AS cor0
----
-1593
-459
-837

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2, tab0 AS cor1
----
243 values hashing to 39c7e653e7a493eb9c9e3dad9ba3b8c2

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1326
SELECT - + col0 + + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-1326
SELECT - + col0 + + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + col1 + col0 * cor0.col0 * + col2 AS col1 FROM tab2 AS cor0
----
1354
158243
237175

query I rowsort
SELECT col0 * 39 + + col2 AS col1 FROM tab0 AS cor0
----
1366
3553
969

query I rowsort
SELECT - + cor0.col1 + col1 + - 71 AS col2 FROM tab1 AS cor0
----
-71
-71
-71

query I rowsort
SELECT - col2 * + col0 + col1 * + col0 FROM tab2 AS cor0
----
-1659
2574
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-1331
SELECT ALL - col1 + tab1.col2 + 66 DIV + col1 AS col0 FROM tab1
----
30
53
88

skipif mysql # not compatible
query I rowsort label-1331
SELECT ALL - col1 + tab1.col2 + 66 / + col1 AS col0 FROM tab1
----
30
53
88

query I rowsort
SELECT DISTINCT + 54 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
54

query I rowsort
SELECT 22 * col1 + 77 AS col0 FROM tab2 AS cor0
----
1375
451
759

query I rowsort
SELECT DISTINCT + - 92 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-276
-5888
-7360

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

query I rowsort
SELECT - col2 * + col0 + + col1 + 31 FROM tab1 AS cor0
----
-105
-3607
-7636

query I rowsort
SELECT DISTINCT - ( col1 ) + - ( 18 ) * col0 FROM tab0 AS cor0
----
-1693
-518
-727

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1339
SELECT + col1 DIV col0 + 52 + - col2 FROM tab0 cor0
----
-29
22
53

skipif mysql # not compatible
query I rowsort label-1339
SELECT + col1 / col0 + 52 + - col2 FROM tab0 cor0
----
-29
22
53

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 96 col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1344
SELECT + 63 DIV col0 - + col1 AS col0 FROM tab2 cor0
----
-17
-22
-59

skipif mysql # not compatible
query I rowsort label-1344
SELECT + 63 / col0 - + col1 AS col0 FROM tab2 cor0
----
-17
-22
-59

query I rowsort
SELECT - + 2 + col2 + ( col1 ) * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1154
-1352
-515

query I rowsort
SELECT + ( + 78 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * tab0.col0 + + col0 col2 FROM tab0
----
70
7387
816

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

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

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

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

query I rowsort
SELECT - 75 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

query I rowsort
SELECT + col0 * col2 * + 43 + col0 AS col0 FROM tab0
----
1540
313903
34080

query I rowsort
SELECT ( 27 ) FROM tab1 AS cor0
----
27
27
27

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

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

query I rowsort
SELECT DISTINCT - 85 * + col0 FROM tab2
----
-595
-6630
-6715

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1356
SELECT ALL - - ( + 42 ) * - col1 + + col1 + - col2 * col2 DIV col2 AS col1 FROM tab0 AS cor0
----
-3559
-3813
-3978

skipif mysql # not compatible
query I rowsort label-1356
SELECT ALL - - ( + 42 ) * - col1 + + col1 + - col2 * col2 / col2 AS col1 FROM tab0 AS cor0
----
-3559
-3813
-3978

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

skipif mysql # not compatible
query I rowsort label-1357
SELECT DISTINCT + + CAST ( - col1 AS INTEGER ) + - col1 AS col2 FROM tab1 AS cor0
----
-20
-26
-52

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

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

skipif mysql # not compatible
query I rowsort label-1359
SELECT + ( + col1 ) / + col1 AS col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 67 * col0 * - col0 - col1 FROM tab1 AS cor0
----
-274442
-428813
-629

query I rowsort
SELECT ALL 98 * col0 + + col2 * col2 FROM tab0 AS cor0
----
15446
3431
3441

query I rowsort
SELECT DISTINCT - col0 - 64 * col2 AS col2 FROM tab1 AS cor0
----
-3459
-3712
-6224

query I rowsort
SELECT DISTINCT - 85 + col0 * ( - cor0.col0 * - col0 ) AS col2 FROM tab0 AS cor0
----
13739
42790
704884

query I rowsort
SELECT ALL + 37 * - col2 AS col1 FROM tab0 AS cor0
----
-1221
-3034
-37

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

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

skipif mysql # not compatible
query I rowsort label-1366
SELECT CAST ( - col2 * col2 AS INTEGER ) - - col1 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT 36 + tab0.col0 * col1 * col0 AS col2 FROM tab0
----
118861
49572
720847

query I rowsort
SELECT ALL - + col1 * col0 + + 20 FROM tab1 AS cor0
----
-1020
-58
-620

query I rowsort
SELECT - + 91 AS col1 FROM tab0 cor0
----
-91
-91
-91

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 56 * col2 col1 FROM tab0 AS cor0
----
-1848
-4592
-56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + - cor0.col0 col1 FROM tab2 AS cor0
----
-41
-52
20

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

query I rowsort
SELECT + col0 * col0 + - 79 FROM tab1 AS cor0
----
-70
4017
6321

query I rowsort
SELECT ALL + col0 * - 67 - col1 AS col1 FROM tab1 AS cor0
----
-227
-4298
-5373

onlyif mysql # use DIV operator for integer division
query I rowsort label-1376
SELECT col2 DIV CAST( - 58 AS SIGNED ) + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1376
SELECT col2 / CAST ( - 58 AS INTEGER ) + col1 FROM tab2 AS cor0
----
17
31
59

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1379
SELECT ALL - col2 DIV ( 63 ) AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1379
SELECT ALL - col2 / ( 63 ) AS col0 FROM tab2 AS cor0
----
0
0
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1381
SELECT DISTINCT - - col0 * 19 DIV - 37 AS col2 FROM tab2 AS cor0
----
-3
-40

skipif mysql # not compatible
query I rowsort label-1381
SELECT DISTINCT - - col0 * 19 / - 37 AS col2 FROM tab2 AS cor0
----
-3
-40

query I rowsort
SELECT - col0 * + 93 + - col0 FROM tab0 AS cor0
----
-2256
-3290
-8366

query I rowsort
SELECT + - col0 * - 44 + 83 + - col0 AS col1 FROM tab2 AS cor0
----
3437
3480
384

query I rowsort
SELECT ALL - - col2 + - 34 - col1 * col2 AS col2 FROM tab1 AS cor0
----
-1186
-1384
-547

query I rowsort
SELECT DISTINCT + col2 + 91 AS col2 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT DISTINCT + col1 + + 81 AS col0 FROM tab2 AS cor0
----
112
140
98

query I rowsort
SELECT DISTINCT + col2 * 41 AS col1 FROM tab0 AS cor0
----
1353
3362
41

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

query I rowsort
SELECT - 43 + + col2 FROM tab1 AS cor0
----
11
14
53

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

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

query I rowsort
SELECT + col0 + + 70 FROM tab2 AS cor0
----
148
149
77

query I rowsort
SELECT + 36 + 71 FROM tab0, tab0 cor0
----
9 values hashing to 6f26a03989006af44e1b70d584e50047

query I rowsort
SELECT col2 + 59 * + col0 AS col2 FROM tab0
----
1449
2066
5333

query I rowsort
SELECT 40 * - col0 + - 87 AS col0 FROM tab0
----
-1047
-1487
-3647

query I rowsort
SELECT col2 * - col0 + 90 FROM tab1 cor0
----
-3558
-72
-7590

query I rowsort
SELECT 20 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT + 68 + - col2 * + col2 AS col1 FROM tab1
----
-2848
-3181
-9148

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * 75 col1 FROM tab1 AS cor0
----
4050
4275
7200

query I rowsort
SELECT col1 * 88 AS col2 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT col1 * - 59 AS col0 FROM tab0 AS cor0
----
-5074
-5369
-5723

query I rowsort
SELECT DISTINCT + col0 * - 18 FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT ALL - - 18 * + 12 AS col0 FROM tab0 AS cor0
----
216
216
216

query I rowsort
SELECT DISTINCT - col2 + 38 AS col2 FROM tab0 cor0
----
-44
37
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1406
SELECT DISTINCT + + 33 DIV + col1 + - col1 * + col2 FROM tab1 AS cor0
----
-1246
-1403
-567

skipif mysql # not compatible
query I rowsort label-1406
SELECT DISTINCT + + 33 / + col1 + - col1 * + col2 FROM tab1 AS cor0
----
-1246
-1403
-567

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 43 * - 65 + col2 * col1 col1 FROM tab0 AS cor0
----
-2698
43
4667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1410
SELECT DISTINCT - CAST( 80 AS SIGNED ) * col1 AS col1 FROM tab0 cor0
----
-6880
-7280
-7760

skipif mysql # not compatible
query I rowsort label-1410
SELECT DISTINCT - CAST ( 80 AS INTEGER ) * col1 AS col1 FROM tab0 cor0
----
-6880
-7280
-7760

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

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

query I rowsort
SELECT ALL + 43 + cor1.col1 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab0 cor2
----
81 values hashing to 85cfaddd1ac7876efdd6b711aaa55939

query I rowsort
SELECT - col0 * col0 + 11 FROM tab0 AS cor0
----
-1214
-565
-7910

query I rowsort
SELECT + - col2 * col2 * col1 + col2 FROM tab0 cor0
----
-611802
-93621
-96

query I rowsort
SELECT ALL + - 42 * + cor0.col0 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 52b3afe7f8d7b0abe00afd4ac7bc7bb2

query I rowsort
SELECT 21 * + col1 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT + - 81 + + col2 AS col1 FROM tab2 AS cor0
----
-43
-54
-55

query I rowsort
SELECT DISTINCT col1 + - 14 * col0 AS col2 FROM tab2 AS cor0
----
-1033
-1089
-67

query I rowsort
SELECT DISTINCT + col2 * - 64 + col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-48
2851
3331

query I rowsort
SELECT DISTINCT + 24 * cor1.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
1296
1368
2304

query I rowsort
SELECT - - 79 * + col0 AS col0 FROM tab2 cor0
----
553
6162
6241

query I rowsort
SELECT ALL + 49 * - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8c52dc06e3be29deb4b8ff99017a5caf

query I rowsort
SELECT + col2 * - 58 FROM tab1
----
-3132
-3306
-5568

query I rowsort
SELECT - 40 + + tab0.col1 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to a2572cd18586107a2929385a7509d918

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( + 27 * + col2 + + col2 AS REAL ) FROM tab0
----
2296
28
924

onlyif mysql # use DIV operator for integer division
query I rowsort label-1426
SELECT col1 * + col2 + ( col2 ) DIV col0 AS col2 FROM tab0 AS cor0
----
2839
7462
97

skipif mysql # not compatible
query I rowsort label-1426
SELECT col1 * + col2 + ( col2 ) / col0 AS col2 FROM tab0 AS cor0
----
2839
7462
97

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1428
SELECT DISTINCT tab0.col0 DIV + col2 + + col1 * tab0.col1 FROM tab0
----
7396
8282
9444

skipif mysql # not compatible
query I rowsort label-1428
SELECT DISTINCT tab0.col0 / + col2 + + col1 * tab0.col1 FROM tab0
----
7396
8282
9444

query I rowsort
SELECT - - 48 + col1 AS col0 FROM tab2 AS cor0
----
107
65
79

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 22 col2 FROM tab2
----
-1298
-374
-682

query I rowsort
SELECT DISTINCT + 24 * - ( col1 ) AS col0 FROM tab0
----
-2064
-2184
-2328

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

skipif mysql # not compatible
query I rowsort label-1433
SELECT - CAST ( NULL AS REAL ) * col0 AS col1 FROM tab2
----
NULL
NULL
NULL

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

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

query I rowsort
SELECT ALL cor0.col2 * col0 * col1 + col2 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
117624
48032
5670

query I rowsort
SELECT DISTINCT 62 - col0 FROM tab1 AS cor0
----
-18
-2
59

query I rowsort
SELECT DISTINCT + 16 - col2 FROM tab0 AS cor0
----
-17
-66
15

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

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

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL col2 * col2 + cor0.col0 * cor0.col1 * 17 FROM tab2 AS cor0
----
24275
4418
78910

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

query I rowsort
SELECT - col0 * 71 + 49 AS col0 FROM tab2 cor0
----
-448
-5489
-5560

query I rowsort
SELECT ALL - col2 * ( col1 ) + col0 * + col0 AS col0 FROM tab2 AS cor0
----
-788
4550
5595

query I rowsort
SELECT ALL col2 + - 56 * col2 FROM tab1
----
-2970
-3135
-5280

query I rowsort
SELECT col1 - - ( + 84 * col2 ) AS col2 FROM tab0
----
181
2858
6979

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

query I rowsort
SELECT ALL + 47 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

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

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

query I rowsort
SELECT ALL col1 + 35 AS col1 FROM tab0
----
121
126
132

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - col2 + col1 col1 FROM tab1
----
1261
1430
580

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + col1 * ( tab2.col1 ) AS col1 FROM tab2
----
289
3481
961

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

query I rowsort
SELECT DISTINCT - ( col1 ) + + col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL - 42 * col1 AS col2 FROM tab0 AS cor0
----
-3612
-3822
-4074

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 + 99 + - 15 col1 FROM tab1
----
-556
-956
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 29 + + col0 col1 FROM tab1
----
109
32
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1478
SELECT DISTINCT + - col1 DIV - cor0.col1 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-1478
SELECT DISTINCT + - col1 / - cor0.col1 FROM tab1 cor0
----
1

query I rowsort
SELECT + col2 + ( col2 + col0 ) AS col0 FROM tab2 cor0
----
130
155
61

query I rowsort
SELECT + cor0.col1 * + 47 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1040
1859
2626

query I rowsort
SELECT + cor0.col2 + - 15 * + col0 AS col1 FROM tab1 AS cor0
----
-1104
-903
9

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

skipif mysql # not compatible
query I rowsort
SELECT col1 + - 58 * cor0.col2 - col0 * CAST ( col1 AS REAL ) AS col1 FROM tab1 AS cor0
----
-3184
-3936
-6595

query I rowsort
SELECT ALL - + col2 * col0 + - col0 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1659
2574
28

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1486
SELECT DISTINCT + + col2 + cor0.col2 DIV col0 AS col1 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-1486
SELECT DISTINCT + + col2 + cor0.col2 / col0 AS col1 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT ALL + col2 + + col1 * - ( col2 * col1 ) AS col2 FROM tab1 AS cor0
----
-16128
-36450
-5643

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

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

query I rowsort
SELECT + col1 * col2 + 90 * + ( - col0 ) AS col1 FROM tab1 AS cor0
----
-5190
-5952
1134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 94 * - col0 col2 FROM tab0
----
2256
3290
8366

query I rowsort
SELECT DISTINCT col2 * + col0 * + tab1.col2 AS col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT + col1 + - col0 * - 36 FROM tab1 AS cor0
----
134
2314
2893

query I rowsort
SELECT + ( col2 ) + col0 * + col0 * cor0.col1 FROM tab2 AS cor0
----
106135
1546
358982

query I rowsort
SELECT 75 + col2 AS col2 FROM tab0 AS cor0
----
108
157
76

query I rowsort
SELECT - col0 * col2 + + 52 * - col0 AS col1 FROM tab2 AS cor0
----
-553
-6084
-7110

query I rowsort
SELECT - col0 * 22 + + col1 FROM tab2 AS cor0
----
-123
-1657
-1721

query I rowsort
SELECT col2 + - col0 * + col0 AS col1 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT col2 * - 42 FROM tab1 AS cor0
----
-2268
-2394
-4032

onlyif mysql # use DIV operator for integer division
query I rowsort label-1500
SELECT tab1.col1 DIV + 35 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1500
SELECT tab1.col1 / + 35 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - tab1.col1 + 4 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to e91eb2fc5d50bb7c86f996f34cd0bf28

query I rowsort
SELECT 98 + col2 AS col1 FROM tab0
----
131
180
99

query I rowsort
SELECT + 40 * + col2 + col2 * + 88 FROM tab0
----
10496
128
4224

query I rowsort
SELECT col1 * col2 - + col2 AS col1 FROM tab1
----
1152
1350
513

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

skipif mysql # not compatible
query I rowsort label-1505
SELECT DISTINCT + col2 / - tab2.col0 FROM tab2
----
-3
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 col1 FROM tab2 WHERE - col1 - col0 < NULL
----

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

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

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

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

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

query I rowsort
SELECT ALL col1 * + col0 + - tab1.col2 * - col1 + col0 AS col2 FROM tab1
----
1274
1485
2368

onlyif mysql # use DIV operator for integer division
query I rowsort label-1513
SELECT - col1 DIV + tab1.col1 + col2 DIV col2 + - col0 * + col2 FROM tab1
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-1513
SELECT - col1 / + tab1.col1 + col2 / col2 + - col0 * + col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1514
SELECT ALL tab1.col2 - - col0 DIV - col1 AS col1 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-1514
SELECT ALL tab1.col2 - - col0 / - col1 AS col1 FROM tab1
----
51
54
90

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1517
SELECT DISTINCT col0 DIV col0 col1 FROM tab1
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1517
SELECT DISTINCT col0 / col0 col1 FROM tab1
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1518
SELECT DISTINCT col0 + col2 + + col2 DIV + col1 FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-1518
SELECT DISTINCT col0 + col2 + + col2 / + col1 FROM tab0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 - col1 col1 FROM tab2
----
18
6025
6224

query I rowsort
SELECT - col2 * col0 AS col0 FROM tab0 WHERE - col2 * col1 <= ( NULL )
----

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1523
SELECT DISTINCT col2 + tab1.col0 DIV col1 col2 FROM tab1
----
102
54
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1523
SELECT DISTINCT col2 + tab1.col0 / col1 col2 FROM tab1
----
102
54
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-1524
SELECT - col1 DIV + col1 + - col2 * col0 AS col1 FROM tab0
----
-36
-7299
-793

skipif mysql # not compatible
query I rowsort label-1524
SELECT - col1 / + col1 + - col2 * col0 AS col1 FROM tab0
----
-36
-7299
-793

query I rowsort
SELECT tab2.col1 + col1 FROM tab2 WHERE NOT - col0 * + col0 IN ( - col2 * + col0 )
----
118
34
62

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

query I rowsort
SELECT - tab0.col2 * - col0 * tab0.col1 + + col1 FROM tab0
----
3492
664209
68198

query III rowsort
SELECT * FROM tab2 WHERE NOT - col1 NOT IN ( col0 + + col2 )
----

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1531
SELECT ALL - ( col0 ) * col2 + col2 DIV + col2 FROM tab1 AS cor0
----
-161
-3647
-7679

skipif mysql # not compatible
query I rowsort label-1531
SELECT ALL - ( col0 ) * col2 + col2 / + col2 FROM tab1 AS cor0
----
-161
-3647
-7679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1532
SELECT + col1 * - col1 * - CAST( col0 * col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
175760
52728
64000

skipif mysql # not compatible
query I rowsort label-1532
SELECT + col1 * - col1 * - CAST ( col0 * col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
175760
52728
64000

query I rowsort
SELECT ALL + 56 * col2 * + 87 + + cor0.col1 FROM tab0 AS cor0
----
160862
399595
4969

query I rowsort
SELECT - col0 + - col0 + col1 * col0 AS col1 FROM tab0 AS cor0
----
2016
3325
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-1535
SELECT - ( col2 ) DIV tab1.col1 AS col2 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-1535
SELECT - ( col2 ) / tab1.col1 AS col2 FROM tab1
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1536
SELECT DISTINCT tab0.col1 DIV 31 AS col2 FROM tab0
----
2
3

skipif mysql # not compatible
query I rowsort label-1536
SELECT DISTINCT tab0.col1 / 31 AS col2 FROM tab0
----
2
3

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

query I rowsort
SELECT DISTINCT 58 + - col0 AS col0 FROM tab1
----
-22
-6
55

query I rowsort
SELECT - col0 + col0 * - ( col1 ) - col0 * - 24 FROM tab0 AS cor0
----
-1512
-2590
-6052

query I rowsort
SELECT + col1 * + col0 + 49 AS col1 FROM tab1 AS cor0
----
1089
127
689

query I rowsort
SELECT - 20 * - col0 * + 16 - 86 FROM tab0 AS cor0
----
11114
28394
7594

query I rowsort
SELECT ALL + 20 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT - col1 + 64 AS col1 FROM tab0 AS cor0
----
-22
-27
-33

query I rowsort
SELECT ALL col1 * + 18 AS col0 FROM tab1
----
180
234
468

query I rowsort
SELECT - - 73 * ( cor0.col1 ) FROM tab1 AS cor0
----
1898
730
949

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

query I rowsort
SELECT ALL + 17 * + ( + col2 + + 35 ) * - col2 FROM tab1 AS cor0
----
-213792
-81702
-89148

query I rowsort
SELECT cor0.col2 * col2 * - col2 AS col0 FROM tab1 AS cor0
----
-157464
-185193
-884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-1549
SELECT - 69 + col0 DIV ( - col0 ) FROM tab0 AS cor0
----
-70
-70
-70

skipif mysql # not compatible
query I rowsort label-1549
SELECT - 69 + col0 / ( - col0 ) FROM tab0 AS cor0
----
-70
-70
-70

query I rowsort
SELECT ALL - col2 + 94 AS col2 FROM tab0 AS cor0
----
12
61
93

query I rowsort
SELECT ALL - col1 * 39 + + 69 + col2 FROM tab1 AS cor0
----
-264
-342
-891

query I rowsort
SELECT DISTINCT col2 + 38 FROM tab2 AS cor0
----
64
65
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1553
SELECT + col1 * CAST( - 96 AS SIGNED ) DIV col0 FROM tab0 cor0
----
-266
-344
-98

skipif mysql # not compatible
query I rowsort label-1553
SELECT + col1 * CAST ( - 96 AS INTEGER ) / col0 FROM tab0 cor0
----
-266
-344
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1554
SELECT ALL col1 DIV 90 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1554
SELECT ALL col1 / 90 FROM tab1 AS cor0
----
0
0
0

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

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

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

query I rowsort
SELECT + col0 + - 54 * col2 AS col0 FROM tab1 AS cor0
----
-2913
-3014
-5104

query I rowsort
SELECT + + 60 + + 80 FROM tab2 AS cor0
----
140
140
140

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

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

skipif mysql # not compatible
query I rowsort label-1560
SELECT DISTINCT + CAST ( - 65 AS INTEGER ) FROM tab2 AS cor0
----
-65

query I rowsort
SELECT 4 + col1 AS col1 FROM tab2 AS cor0
----
21
35
63

query I rowsort
SELECT DISTINCT col0 + + 29 * + cor0.col2 FROM tab2 AS cor0
----
1181
790
832

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

skipif mysql # not compatible
query I rowsort label-1563
SELECT DISTINCT 10 / col2 AS col2 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL - - col0 + col0 * + 63 AS col0 FROM tab2 AS cor0
----
448
4992
5056

onlyif mysql # use DIV operator for integer division
query I rowsort label-1565
SELECT col2 * col0 + col0 DIV + 21 col0 FROM tab0 cor0
----
36
7302
793

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1565
SELECT col2 * col0 + col0 / + 21 col0 FROM tab0 cor0
----
36
7302
793

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

query I rowsort
SELECT ALL + - col2 * - col2 + cor0.col2 FROM tab2 AS cor0
----
1482
702
756

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1569
SELECT ALL - - col2 + col1 - + 62 DIV col0 AS col2 FROM tab0 cor0
----
117
173
97

skipif mysql # not compatible
query I rowsort label-1569
SELECT ALL - - col2 + col1 - + 62 / col0 AS col2 FROM tab0 cor0
----
117
173
97

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

skipif mysql # not compatible
query I rowsort label-1570
SELECT DISTINCT - col2 + col1 / + col1 AS col0 FROM tab0 AS cor0
----
-32
-81
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1572
SELECT col0 + col1 * ( col0 ) DIV - cor0.col0 col2 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1572
SELECT col0 + col1 * ( col0 ) / - cor0.col0 col2 FROM tab0 AS cor0
----
-2
-62
-62

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

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

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

skipif mysql # not compatible
query I rowsort label-1574
SELECT - 34 / tab0.col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT 30 + col2 FROM tab2 AS cor0
----
56
57
68

query I rowsort
SELECT ALL + + 56 * col2 + - 27 AS col2 FROM tab1 AS cor0
----
2997
3165
5349

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

skipif mysql # not compatible
query I rowsort label-1577
SELECT ALL + 78 + + col0 * + CAST ( + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
2106
267
3080

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 + - 78 * col2 FROM tab1 AS cor0
----
-4290
-5086
-8528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 84 + + col1 * tab1.col1 - col2 col1 FROM tab1
----
127
157
706

onlyif mysql # use DIV operator for integer division
query I rowsort label-1580
SELECT - + col0 + + col2 + col0 * col2 DIV col0 FROM tab1 AS cor0
----
105
112
50

skipif mysql # not compatible
query I rowsort label-1580
SELECT - + col0 + + col2 + col0 * col2 / col0 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT col2 + col1 * + ( tab2.col2 ) FROM tab2
----
1560
684
864

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

query I rowsort
SELECT - 38 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT col1 + + col1 + col0 FROM tab0
----
196
229
271

onlyif mysql # use DIV operator for integer division
query I rowsort label-1585
SELECT - ( - ( - col0 ) ) DIV CAST( 32 AS SIGNED ) FROM tab1 AS cor0
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-1585
SELECT - ( - ( - col0 ) ) / CAST ( 32 AS INTEGER ) FROM tab1 AS cor0
----
-2
-2
0

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1588
SELECT ALL CAST( - 57 AS SIGNED ) + + col2 col2 FROM tab1 AS cor0
----
-3
0
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1588
SELECT ALL CAST ( - 57 AS INTEGER ) + + col2 col2 FROM tab1 AS cor0
----
-3
0
39

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

query I rowsort
SELECT DISTINCT + ( + col2 ) + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT tab0.col0 * 18 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 6eb4db65594b193ce9925754ca28baa0

query I rowsort
SELECT DISTINCT col2 * - 81 FROM tab2
----
-2106
-2187
-3078

query I rowsort
SELECT ALL 53 FROM tab2, tab2 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

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

skipif mysql # not compatible
query I rowsort label-1594
SELECT ( + col1 ) / + col2 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1595
SELECT - ( - col1 ) DIV col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1595
SELECT - ( - col1 ) / col1 FROM tab0
----
1
1
1

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

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

query I rowsort
SELECT DISTINCT - + 54 * - col0 AS col2 FROM tab1 AS cor0
----
162
3456
4320

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

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

query I rowsort
SELECT DISTINCT - + col1 * col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

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

skipif mysql # not compatible
query I rowsort label-1601
SELECT DISTINCT - + ( + col0 ) * col0 + CAST ( + 60 AS INTEGER ) FROM tab2 AS cor0
----
-6024
-6181
11

query I rowsort
SELECT ALL + ( + 18 ) * col1 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT col0 * 54 FROM tab1
----
162
3456
4320

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 col1 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT col2 * ( col1 ) * col0 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col0 * + 82 FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT ALL - - cor0.col2 + + ( col0 ) + + col1 FROM tab1 AS cor0
----
131
189
83

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

query I rowsort
SELECT - - 61 * - 58 + cor0.col0 FROM tab0 AS cor0
----
-3449
-3503
-3514

query I rowsort
SELECT - ( 74 ) * col1 FROM tab2 AS cor0
----
-1258
-2294
-4366

onlyif mysql # use DIV operator for integer division
query I rowsort label-1612
SELECT + col2 * 31 + cor0.col0 DIV + cor0.col2 AS col0 FROM tab1 cor0
----
1674
1768
2976

skipif mysql # not compatible
query I rowsort label-1612
SELECT + col2 * 31 + cor0.col0 / + cor0.col2 AS col0 FROM tab1 cor0
----
1674
1768
2976

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

query I rowsort
SELECT ALL + tab0.col2 + - col1 * + 25 * col2 AS col0 FROM tab0
----
-186468
-2424
-70917

onlyif mysql # use DIV operator for integer division
query I rowsort label-1615
SELECT col0 * - col0 + col0 DIV + col1 FROM tab0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-1615
SELECT col0 * - col0 + col0 / + col1 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-1616
SELECT + tab1.col1 DIV 84 + 87 + tab1.col0 * ( + 20 ) AS col0 FROM tab1
----
1367
147
1687

skipif mysql # not compatible
query I rowsort label-1616
SELECT + tab1.col1 / 84 + 87 + tab1.col0 * ( + 20 ) AS col0 FROM tab1
----
1367
147
1687

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1618
SELECT ALL - - cor0.col1 DIV cor0.col2 + 0 + col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-1618
SELECT ALL - - cor0.col1 / cor0.col2 + 0 + col2 FROM tab0 AS cor0
----
35
83
98

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 * + 96 * col0 FROM tab1
----
-61440
-7488
-99840

query I rowsort
SELECT col1 + + col0 * cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

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

query I rowsort
SELECT DISTINCT + + col2 * - 48 AS col1 FROM tab2 AS cor0
----
-1248
-1296
-1824

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1627
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-1627
SELECT col1 / col2 col1 FROM tab0 AS cor0
----
1
2
97

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

query I rowsort
SELECT + col2 + 35 FROM tab2 cor0
----
61
62
73

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

skipif mysql # not compatible
query I rowsort label-1630
SELECT - col0 * - col0 + + CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
42
6006
6162

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

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

skipif mysql # not compatible
query I rowsort label-1632
SELECT + col1 * + col2 + cor0.col0 / cor0.col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

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

query I rowsort
SELECT ALL + cor0.col2 * + 71 AS col2 FROM tab0 AS cor0
----
2343
5822
71

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 * - col2 col2 FROM tab1 AS cor0
----
-1235
-1378
-560

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

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

query I rowsort
SELECT DISTINCT + 84 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
84

query I rowsort
SELECT + col0 + + cor0.col2 * + 4 AS col0 FROM tab1 AS cor0
----
219
292
464

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

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

query I rowsort
SELECT DISTINCT 27 FROM tab2 cor0
----
27

query I rowsort
SELECT 69 + - 93 FROM tab0 AS cor0
----
-24
-24
-24

query I rowsort
SELECT DISTINCT - col0 + col0 * col1 * - col1 AS col2 FROM tab1 AS cor0
----
-13600
-2031
-6464

query I rowsort
SELECT ALL + 41 - - col1 FROM tab2 AS cor0
----
100
58
72

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

query I rowsort
SELECT ALL - ( 7 ) * - col1 FROM tab0 AS cor0
----
602
637
679

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

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

query I rowsort
SELECT ALL + - col1 * - 67 FROM tab2 AS cor0
----
1139
2077
3953

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

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

query I rowsort
SELECT + 57 * col0 AS col0 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT DISTINCT col1 * col1 + col1 + - col1 FROM tab1
----
100
169
676

query I rowsort
SELECT - 61 * + cor0.col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 561b2740e321e63ca416c8b5bff25fe5

query I rowsort
SELECT ALL + col2 * col2 - + 87 AS col1 FROM tab2
----
1357
589
642

query I rowsort
SELECT ALL + tab0.col1 - - ( 29 ) * col2 FROM tab0
----
1043
126
2469

query I rowsort
SELECT ALL ( 6 ) + col1 AS col2 FROM tab0
----
103
92
97

query I rowsort
SELECT col0 + 57 * col2 FROM tab0 AS cor0
----
1905
4763
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1658
SELECT DISTINCT + CAST( col0 AS SIGNED ) * cor0.col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

skipif mysql # not compatible
query I rowsort label-1658
SELECT DISTINCT + CAST ( col0 AS INTEGER ) * cor0.col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 57 col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-57

query I rowsort
SELECT - cor0.col0 + cor0.col1 * + col1 * col2 FROM tab0 AS cor0
----
244044
678953
9374

query I rowsort
SELECT + + col1 - + 14 * 16 AS col2 FROM tab0 AS cor0
----
-127
-133
-138

query I rowsort
SELECT col0 * + 80 AS col0 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT DISTINCT col2 + - col1 * ( col1 ) FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT + 89 * + 2 * cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to deefb0094d152193b621c917d037cb50

query I rowsort
SELECT ALL + col1 * - 60 FROM tab0 AS cor0
----
-5160
-5460
-5820

onlyif mysql # use DIV operator for integer division
query I rowsort label-1667
SELECT - + col1 * col1 DIV + col0 FROM tab2 AS cor0
----
-137
-3
-44

skipif mysql # not compatible
query I rowsort label-1667
SELECT - + col1 * col1 / + col0 FROM tab2 AS cor0
----
-137
-3
-44

query I rowsort
SELECT DISTINCT - + col0 * - 39 AS col1 FROM tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT col2 + col2 * 87 * + cor0.col1 FROM tab2 AS cor0
----
133484
56240
72846

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + ( col2 ) col2 FROM tab0 AS cor0
----
164
2
66

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1672
SELECT ALL + col2 + - ( col0 ) DIV - col2 + 89 FROM tab0 AS cor0
----
122
125
172

skipif mysql # not compatible
query I rowsort label-1672
SELECT ALL + col2 + - ( col0 ) / - col2 + 89 FROM tab0 AS cor0
----
122
125
172

query I rowsort
SELECT DISTINCT + - col2 * col0 + col2 * col1 FROM tab1 AS cor0
----
-3078
-6432
1242

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

skipif mysql # not compatible
query I rowsort label-1674
SELECT DISTINCT + - col0 * col2 + - col1 / - col0 FROM tab1 AS cor0
----
-154
-3648
-7680

query I rowsort
SELECT ALL + - cor0.col0 * 44 FROM tab1 AS cor0
----
-132
-2816
-3520

query I rowsort
SELECT ALL - - col0 + ( + 14 ) * + col2 * - col0 FROM tab2 AS cor0
----
-2639
-28314
-41949

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

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

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

query I rowsort
SELECT ALL + col0 * - col0 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - + col2 + - 58 * col0 FROM tab2 AS cor0
----
-433
-4550
-4620

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

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

query I rowsort
SELECT - + ( - col0 ) + - cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - 36 + col2 AS col1 FROM tab1 AS cor0
----
132
90
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + tab0.col0 ) col1 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1686
SELECT ALL + col2 DIV + col0 - - ( + cor0.col0 ) FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-1686
SELECT ALL + col2 / + col0 - - ( + cor0.col0 ) FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT + ( cor0.col1 ) + - 10 FROM tab0 AS cor0
----
76
81
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1688
SELECT ALL col0 DIV col2 + 27 * col2 AS col0 FROM tab0 cor0
----
2215
62
891

skipif mysql # not compatible
query I rowsort label-1688
SELECT ALL col0 / col2 + 27 * col2 AS col0 FROM tab0 cor0
----
2215
62
891

query I rowsort
SELECT DISTINCT + 33 * col0 - + ( - cor0.col2 ) FROM tab2 AS cor0
----
258
2600
2645

query I rowsort
SELECT - col2 + col0 * - cor0.col0 * + col0 FROM tab0 AS cor0
----
-13857
-42876
-705051

query I rowsort
SELECT ALL - + 18 * col0 + ( col1 * + col0 ) FROM tab0 cor0
----
1632
2765
6497

query I rowsort
SELECT - col1 * + 99 FROM tab1 cor0
----
-1287
-2574
-990

query I rowsort
SELECT DISTINCT col0 + - col0 * 76 FROM tab0 AS cor0
----
-1800
-2625
-6675

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

query I rowsort
SELECT DISTINCT col2 + - 23 + col1 FROM tab1 AS cor0
----
44
57
86

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

query I rowsort
SELECT col0 * tab1.col0 + 55 * + col0 FROM tab1
----
10800
174
7616

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

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

query I rowsort
SELECT DISTINCT + 19 * + col1 FROM tab2
----
1121
323
589

query I rowsort
SELECT DISTINCT 30 * col1 FROM tab1
----
300
390
780

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

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

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

query I rowsort
SELECT DISTINCT - 25 * - tab2.col1 FROM tab2, tab0 AS cor0
----
1475
425
775

query I rowsort
SELECT ALL - col2 * + 51 AS col0 FROM tab1
----
-2754
-2907
-4896

query I rowsort
SELECT ALL tab1.col1 + + 48 FROM tab1, tab1 AS cor0
----
9 values hashing to 861e0798f5d0dd29725f9b058878df24

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

query I rowsort
SELECT ALL + ( - tab0.col2 ) FROM tab0, tab2 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT DISTINCT - - cor0.col0 * - 85 AS col2 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT + - ( - col2 ) + col1 * - ( + cor0.col2 * + col1 ) FROM tab0 AS cor0
----
-244035
-678960
-9408

query I rowsort
SELECT 37 * - 99 FROM tab0 AS cor0
----
-3663
-3663
-3663

query I rowsort
SELECT - 42 * - cor0.col1 FROM tab1 AS cor0
----
1092
420
546

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

query I rowsort
SELECT + col1 * 64 * col0 FROM tab1 cor0
----
40960
4992
66560

query I rowsort
SELECT + 46 + + 48 * + col2 FROM tab0 AS cor0
----
1630
3982
94

query I rowsort
SELECT DISTINCT + col0 * 87 + - col0 AS col1 FROM tab0
----
2064
3010
7654

query I rowsort
SELECT + 3 + - 46 FROM tab1
----
-43
-43
-43

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

skipif mysql # not compatible
query I rowsort label-1717
SELECT - CAST ( + 20 AS INTEGER ) AS col0 FROM tab0
----
-20
-20
-20

query I rowsort
SELECT DISTINCT 45 * col2 + col0 FROM tab0
----
1509
3779
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + 65 * + cor0.col2 col1 FROM tab1 AS cor0
----
3507
3641
6160

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

query I rowsort
SELECT ALL col2 + + ( col0 * + ( 82 ) ) + col0 FROM tab2 AS cor0
----
608
6500
6595

query I rowsort
SELECT ALL + 79 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT ALL 42 * cor0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to b76f97c104003b91b34e723ae5e818ca

query I rowsort
SELECT - col0 * + col1 + col0 * - col1 FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT ALL - 44 + col1 FROM tab1 AS cor0
----
-18
-31
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + - cor0.col2 col1 FROM tab2 AS cor0
----
-55
-58
-85

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

query I rowsort
SELECT - 22 * - col2 AS col0 FROM tab2 AS cor0
----
572
594
836

onlyif mysql # use DIV operator for integer division
query I rowsort label-1729
SELECT ALL + 90 * col2 + col1 DIV + 31 AS col2 FROM tab2 cor0
----
2341
2431
3420

skipif mysql # not compatible
query I rowsort label-1729
SELECT ALL + 90 * col2 + col1 / + 31 AS col2 FROM tab2 cor0
----
2341
2431
3420

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

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

query I rowsort
SELECT ALL - col2 * - col2 + ( 55 * col2 + - col1 ) FROM tab0 cor0
----
-41
11143
2818

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

query I rowsort
SELECT col2 * col2 * 27 FROM tab2
----
18252
19683
38988

query I rowsort
SELECT - - col1 * + 16 + cor0.col0 AS col2 FROM tab0 AS cor0
----
1400
1545
1587

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

query I rowsort
SELECT DISTINCT + col1 * col1 * + col0 - col2 FROM tab0 cor0
----
177471
329314
736927

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 85 col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2, tab1 AS cor3
----
243 values hashing to 7611f7ec93c4325d64b2249d23f38791

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

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

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

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

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

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

query I rowsort
SELECT ALL - 14 * col1 + cor0.col0 FROM tab2 AS cor0
----
-159
-427
-748

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

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

query I rowsort
SELECT - 94 - col1 AS col2 FROM tab0 AS cor0
----
-180
-185
-191

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1753
SELECT DISTINCT - 81 + col1 / - col1 FROM tab0 AS cor0
----
-82

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab1, tab2 cor0
----
-7
-78
-79

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

query I rowsort
SELECT ALL + col1 * col0 + - cor0.col1 FROM tab0 AS cor0
----
1978
3298
8008

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

query I rowsort
SELECT - 3 + - tab1.col1 * - col2 - tab1.col0 AS col2 FROM tab1
----
1165
1398
503

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

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

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

skipif mysql # not compatible
query I rowsort label-1761
SELECT + 65 / + col1 AS col2 FROM tab0
----
0
0
0

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

query I rowsort
SELECT ALL - 34 * - col0 + + col0 AS col2 FROM tab2 cor0
----
245
2730
2765

query I rowsort
SELECT col0 * + 90 FROM tab1 AS cor0
----
270
5760
7200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1765
SELECT DISTINCT - - CAST( col0 AS SIGNED ) + col1 col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1765
SELECT DISTINCT - - CAST ( col0 AS INTEGER ) + col1 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col0 + - 49 AS col1 FROM tab2
----
-42
29
30

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

skipif mysql # not compatible
query I rowsort label-1767
SELECT + col2 / - col0 + - col2 FROM tab0
----
-1
-34
-82

query I rowsort
SELECT - ( tab2.col0 ) - + col0 * tab2.col0 AS col1 FROM tab2
----
-56
-6162
-6320

query I rowsort
SELECT ALL - + ( 78 ) * col2 FROM tab0 AS cor0
----
-2574
-6396
-78

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

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT - col1 * col0 IN ( col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT col0 + col0 AS col0 FROM tab1 WHERE NOT ( NULL ) BETWEEN NULL AND + col0 * col0
----

query I rowsort
SELECT ALL - col2 + + col1 * cor0.col1 * - col0 + + col1 FROM tab1 AS cor0
----
-13603
-2056
-6447

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 * + tab1.col2 col2 FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col0 - + col2 * + col1 col0 FROM tab1
----
-1413
-4666
-7648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 * col1 col0 FROM tab0
----
2097
3396
8181

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

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

skipif mysql # not compatible
query I rowsort label-1779
SELECT col1 * - cor0.col1 / - col1 AS col0 FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1780
SELECT - col0 DIV - col1 + - tab1.col0 AS col1 FROM tab1
----
-3
-58
-74

skipif mysql # not compatible
query I rowsort label-1780
SELECT - col0 / - col1 + - tab1.col0 AS col1 FROM tab1
----
-3
-58
-74

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1782
SELECT col0 * - col2 + col2 + col1 DIV - col1 AS col1 FROM tab1
----
-109
-3592
-7585

skipif mysql # not compatible
query I rowsort label-1782
SELECT col0 * - col2 + col2 + col1 / - col1 AS col1 FROM tab1
----
-109
-3592
-7585

query I rowsort
SELECT DISTINCT + col2 * col2 + + col0 AS col0 FROM tab2
----
1523
736
754

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col0 + - cor0.col0 * + col1 * + col0 col1 FROM tab0 AS cor0
----
-118790
-48744
-713513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + + col2 + + col2 * - col0 * + cor0.col0 col2 FROM tab1 AS cor0
----
-233351
-429
-614224

query I rowsort
SELECT DISTINCT - + col1 * col2 + - col0 + cor0.col2 FROM tab2 AS cor0
----
-1586
-687
-817

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 + + col0 + - col2 * cor0.col2 FROM tab0 AS cor0
----
-14734
-3129
-3361

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

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

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT col2 * + col1 NOT IN ( col2 ) OR NOT - col0 <= NULL
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT NULL = + cor0.col2 OR NOT col0 BETWEEN + col0 AND ( NULL )
----

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

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

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

query III rowsort
SELECT * FROM tab2 cor0 WHERE NULL <= ( NULL ) OR NOT NULL IN ( + cor0.col2 )
----

query I rowsort
SELECT ALL + col2 + + col2 * + col2 FROM tab2
----
1482
702
756

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

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

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

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

query I rowsort
SELECT + + col1 * ( - col0 + - col2 * 36 ) AS col1 FROM tab0 AS cor0
----
-104232
-276731
-6887

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 * cor0.col2 col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + ( col0 ) + - col1 * + col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

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

query I rowsort
SELECT DISTINCT + col0 + - 50 FROM tab0
----
-15
-26
39

query I rowsort
SELECT + col1 + + ( tab1.col2 + - col0 ) * - col1 * - col0 FROM tab1
----
-4470
16653
4004

query I rowsort
SELECT - + ( + col1 ) + - 98 AS col1 FROM tab2 AS cor0
----
-115
-129
-157

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

query I rowsort
SELECT - col2 * + col2 + ( col0 ) AS col1 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT + col2 * - 21 AS col2 FROM tab0
----
-1722
-21
-693

query I rowsort
SELECT 85 * - col2 FROM tab2
----
-2210
-2295
-3230

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

skipif mysql # not compatible
query I rowsort label-1813
SELECT DISTINCT col0 * tab1.col1 / + col0 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - 61 * tab0.col2 AS col0 FROM tab0
----
-2013
-5002
-61

query I rowsort
SELECT - ( + col1 ) * - col1 * + ( 76 + + col2 * - tab1.col1 ) FROM tab1
----
-198068
-49400
-897728

query I rowsort
SELECT - col1 * 33 FROM tab2
----
-1023
-1947
-561

query I rowsort
SELECT + + cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + cor0.col1 + - col2 * col2 FROM tab2 AS cor0
----
-1427
-617
-698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 88 ) col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 53 * col0 col2 FROM tab0 AS cor0
----
1272
1855
4717

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

query I rowsort
SELECT ALL + 90 * col0 * col1 + + tab2.col2 FROM tab2
----
120908
19557
414206

query I rowsort
SELECT + 45 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT ALL - col1 + - col0 * ( + col2 ) + + col0 FROM tab1
----
-185
-3594
-7613

query I rowsort
SELECT cor0.col2 * + col0 + 83 FROM tab2 cor0
----
2111
272
3085

query I rowsort
SELECT ALL - col0 + tab1.col1 + - col2 FROM tab1
----
-111
-163
-31

query I rowsort
SELECT - + col2 + + col0 * col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-1830
SELECT - - col0 + + col0 DIV 65 AS col2 FROM tab2 AS cor0
----
7
79
80

skipif mysql # not compatible
query I rowsort label-1830
SELECT - - col0 + + col0 / 65 AS col2 FROM tab2 AS cor0
----
7
79
80

query I rowsort
SELECT DISTINCT + col2 * + 7 AS col0 FROM tab1 cor0
----
378
399
672

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1833
SELECT DISTINCT col0 DIV 85 AS col2 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-1833
SELECT DISTINCT col0 / 85 AS col2 FROM tab2 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + 30 col2 FROM tab1 cor0
----
-4066
-6370
21

query I rowsort
SELECT + - col1 * + col1 + + col1 AS col1 FROM tab1 AS cor0
----
-156
-650
-90

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1837
SELECT ALL col2 DIV 40 FROM tab1 cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-1837
SELECT ALL col2 / 40 FROM tab1 cor0
----
1
1
2

query I rowsort
SELECT - + cor0.col0 * 79 FROM tab2 AS cor0
----
-553
-6162
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1839
SELECT DISTINCT + col2 + + CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-1839
SELECT DISTINCT + col2 + + CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
104
117
34

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

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

query I rowsort
SELECT + + col0 * + 59 FROM tab1 AS cor0
----
177
3776
4720

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

query I rowsort
SELECT col1 + + 35 FROM tab0 AS cor0
----
121
126
132

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

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

query I rowsort
SELECT ALL + + 13 * - cor0.col1 FROM tab2 AS cor0
----
-221
-403
-767

query I rowsort
SELECT + + col0 * + cor0.col1 * + ( - col1 ) + col0 AS col1 FROM tab2 AS cor0
----
-22752
-271440
-6720

query I rowsort
SELECT ALL + ( + 33 + col0 ) AS col2 FROM tab0
----
122
57
68

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ALL - 39 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query I rowsort
SELECT ALL - - cor1.col1 * - 27 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d43cb5ec49d07ed28abf45a3dad5bd4d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 15 col0 FROM tab1
----
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-1853
SELECT DISTINCT ( 74 ) DIV + col0 AS col0 FROM tab1
----
0
1
24

skipif mysql # not compatible
query I rowsort label-1853
SELECT DISTINCT ( 74 ) / + col0 AS col0 FROM tab1
----
0
1
24

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 + - col2 col1 FROM tab0
----
-12
37
69

query I rowsort
SELECT + col0 + - ( + col1 + - col1 ) FROM tab2
----
7
78
79

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

query I rowsort
SELECT - + 50 * 21 FROM tab0 AS cor0
----
-1050
-1050
-1050

query I rowsort
SELECT + 56 FROM tab0, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

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

query I rowsort
SELECT DISTINCT + 47 * + col1 + cor0.col0 * + 83 FROM tab0 AS cor0
----
11664
6034
7464

query I rowsort
SELECT + 54 FROM tab1, tab2 AS cor0, tab1 cor1, tab0 AS cor2
----
81 values hashing to c12c2f39593b3ce157086f29d8391c32

query I rowsort
SELECT ALL + 49 * col1 AS col1 FROM tab1 AS cor0
----
1274
490
637

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

query I rowsort
SELECT 9 * col0 - + tab0.col2 AS col0 FROM tab0
----
183
314
719

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

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

query I rowsort
SELECT - - 60 + col1 * col0 FROM tab0 AS cor0
----
2124
3455
8159

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * - col0 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

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

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

skipif mysql # not compatible
query I rowsort label-1871
SELECT DISTINCT col0 + + CAST ( - col1 AS INTEGER ) - + col0 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1872
SELECT col2 * col2 + 68 DIV col1 FROM tab2 AS cor0
----
1448
677
731

skipif mysql # not compatible
query I rowsort label-1872
SELECT col2 * col2 + 68 / col1 FROM tab2 AS cor0
----
1448
677
731

onlyif mysql # use DIV operator for integer division
query I rowsort label-1873
SELECT - - col2 * - col0 DIV col0 + col0 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-1873
SELECT - - col2 * - col0 / col0 + col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + col2 - col0 * 62 FROM tab0 AS cor0
----
-1455
-2169
-5436

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

query I rowsort
SELECT tab1.col1 * - tab1.col1 * 61 AS col2 FROM tab1
----
-10309
-41236
-6100

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1879
SELECT - col2 * col2 DIV 74 + col1 FROM tab1 AS cor0
----
-111
-13
-33

skipif mysql # not compatible
query I rowsort label-1879
SELECT - col2 * col2 / 74 + col1 FROM tab1 AS cor0
----
-111
-13
-33

query I rowsort
SELECT DISTINCT col0 + + col2 * - 96 AS col1 FROM tab2 AS cor0
----
-2418
-2585
-3569

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

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

skipif mysql # not compatible
query I rowsort label-1882
SELECT - col0 + - CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT + + col1 * - ( + col2 ) * + col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1884
SELECT DISTINCT + col0 * ( - col0 ) + col0 + col1 * col2 DIV col0 FROM tab1 AS cor0
----
-4024
-6305
462

skipif mysql # not compatible
query I rowsort label-1884
SELECT DISTINCT + col0 * ( - col0 ) + col0 + col1 * col2 / col0 FROM tab1 AS cor0
----
-4024
-6305
462

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

query I rowsort
SELECT DISTINCT col1 + ( + 59 ) AS col2 FROM tab1 AS cor0
----
69
72
85

query I rowsort
SELECT col0 + ( col0 * col1 ) AS col1 FROM tab1 AS cor0
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-1888
SELECT DISTINCT + - col0 DIV + 67 + - col2 + col2 FROM tab2 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-1888
SELECT DISTINCT + - col0 / + 67 + - col2 + col2 FROM tab2 cor0
----
-1
0

query I rowsort
SELECT + ( 32 ) * col2 FROM tab1 AS cor0
----
1728
1824
3072

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

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

skipif mysql # not compatible
query I rowsort label-1891
SELECT ALL + ( + col1 ) / cor0.col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT ALL col0 * 46 + - col1 AS col1 FROM tab1 AS cor0
----
112
2934
3667

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1894
SELECT ALL + cor0.col1 * - 16 + - col1 DIV - col1 FROM tab0 AS cor0
----
-1375
-1455
-1551

skipif mysql # not compatible
query I rowsort label-1894
SELECT ALL + cor0.col1 * - 16 + - col1 / - col1 FROM tab0 AS cor0
----
-1375
-1455
-1551

query I rowsort
SELECT - 12 + + cor0.col1 * - col1 FROM tab2 AS cor0
----
-301
-3493
-973

onlyif mysql # use DIV operator for integer division
query I rowsort label-1896
SELECT DISTINCT + - 97 DIV cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-1
-3
-5

skipif mysql # not compatible
query I rowsort label-1896
SELECT DISTINCT + - 97 / cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-1
-3
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 43 * + 36 col0 FROM tab1 AS cor0
----
1548
1548
1548

query I rowsort
SELECT DISTINCT cor0.col2 + 38 FROM tab2 cor0
----
64
65
76

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

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + + col1 * 70 FROM tab1 AS cor0
----
-3396
-5490
1811

query I rowsort
SELECT ALL + col0 * col1 + col2 - 87 AS col1 FROM tab1 cor0
----
1049
45
610

query I rowsort
SELECT col2 * + 66 + col1 FROM tab0 AS cor0
----
163
2264
5503

query I rowsort
SELECT DISTINCT + + 64 AS col1 FROM tab2 AS cor0
----
64

query I rowsort
SELECT DISTINCT cor0.col1 * + 53 FROM tab2 AS cor0
----
1643
3127
901

onlyif mysql # use DIV operator for integer division
query I rowsort label-1905
SELECT ALL col2 DIV - col1 + - col2 * + tab2.col1 AS col1 FROM tab2
----
-1534
-648
-837

skipif mysql # not compatible
query I rowsort label-1905
SELECT ALL col2 / - col1 + - col2 * + tab2.col1 AS col1 FROM tab2
----
-1534
-648
-837

query I rowsort
SELECT DISTINCT + col0 + col2 * tab2.col2 AS col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT col0 * - 49 * - col0 + + ( + col0 ) FROM tab2 AS cor0
----
2408
298194
305888

query I rowsort
SELECT DISTINCT + cor0.col1 - - 84 FROM tab1 AS cor0
----
110
94
97

query I rowsort
SELECT col0 + - 15 FROM tab0
----
20
74
9

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

query I rowsort
SELECT col2 * ( tab0.col2 ) + col1 + 11 FROM tab0
----
109
1186
6826

onlyif mysql # use DIV operator for integer division
query I rowsort label-1912
SELECT col0 * col0 DIV + 29 AS col1 FROM tab0
----
19
273
42

skipif mysql # not compatible
query I rowsort label-1912
SELECT col0 * col0 / + 29 AS col1 FROM tab0
----
19
273
42

query I rowsort
SELECT col2 + + 69 AS col2 FROM tab2
----
107
95
96

query I rowsort
SELECT DISTINCT + - col0 + 98 FROM tab0 AS cor0
----
63
74
9

query I rowsort
SELECT + ( col2 ) + + 5 FROM tab2 AS cor0
----
31
32
43

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1917
SELECT col2 + 10 DIV - col2 AS col0 FROM tab0 cor0
----
-9
33
82

skipif mysql # not compatible
query I rowsort label-1917
SELECT col2 + 10 / - col2 AS col0 FROM tab0 cor0
----
-9
33
82

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1924
SELECT DISTINCT 20 DIV + cor0.col2 AS col1 FROM tab1, tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1924
SELECT DISTINCT 20 / + cor0.col2 AS col1 FROM tab1, tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col0 col1 FROM tab2 cor0
----
-14
-156
-158

onlyif mysql # use DIV operator for integer division
query I rowsort label-1926
SELECT + + col0 DIV col0 + ( col2 ) FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1926
SELECT + + col0 / col0 + ( col2 ) FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL 55 AS col0 FROM tab1 AS cor0
----
55
55
55

query I rowsort
SELECT ALL + cor0.col1 * col1 + + 96 FROM tab1 AS cor0
----
196
265
772

query I rowsort
SELECT ALL tab2.col2 + col2 * + 43 - col0 AS col0 FROM tab2
----
1066
1181
1593

query I rowsort
SELECT ALL col0 + - col2 + + 92 * col1 FROM tab2
----
1605
2832
5480

query I rowsort
SELECT ALL 41 - col1 AS col0 FROM tab1
----
15
28
31

query I rowsort
SELECT ALL col1 + - tab2.col1 * - col1 AS col2 FROM tab2
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-1933
SELECT ALL col0 * - col2 + - tab2.col1 DIV col0 FROM tab2
----
-193
-2028
-3002

skipif mysql # not compatible
query I rowsort label-1933
SELECT ALL col0 * - col2 + - tab2.col1 / col0 FROM tab2
----
-193
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1934
SELECT CAST( col1 AS SIGNED ) FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1934
SELECT CAST ( col1 AS INTEGER ) FROM tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1935
SELECT DISTINCT - 38 DIV + 56 AS col1 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1935
SELECT DISTINCT - 38 / + 56 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT 20 * col2 AS col0 FROM tab0 AS cor0
----
1640
20
660

query I rowsort
SELECT + tab0.col0 + + 77 * + col2 FROM tab0
----
112
2565
6403

query I rowsort
SELECT DISTINCT + 17 FROM tab1, tab1 cor0
----
17

query I rowsort
SELECT - 37 * 5 FROM tab0 AS cor0
----
-185
-185
-185

query I rowsort
SELECT + ( + col0 * col0 ) - + col1 AS col2 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT cor0.col1 + - cor0.col1 * col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL - + ( + 29 ) AS col1 FROM tab0 AS cor0
----
-29
-29
-29

query I rowsort
SELECT + 24 + - col0 * + cor0.col1 FROM tab1 AS cor0
----
-1016
-54
-616

onlyif mysql # use DIV operator for integer division
query I rowsort label-1944
SELECT - 75 DIV + col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-1944
SELECT - 75 / + col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT + ( col0 ) * + cor0.col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL col0 + - col0 + col2 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT ( col0 ) + + ( 84 + col2 ) * - col1 AS col2 FROM tab0
----
-10038
-15017
-8210

query I rowsort
SELECT col2 - col0 * + col0 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT + col2 * - col0 + - 58 AS col2 FROM tab0
----
-7356
-850
-93

query I rowsort
SELECT ALL - col0 * tab0.col0 * + 54 + - 49 AS col2 FROM tab0
----
-31153
-427783
-66199

query I rowsort
SELECT ALL + col1 + 64 * - col0 * + col1 FROM tab2 AS cor0
----
-13857
-294469
-85935

onlyif mysql # use DIV operator for integer division
query I rowsort label-1952
SELECT ALL - - cor0.col1 DIV - 19 FROM tab2 cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-1952
SELECT ALL - - cor0.col1 / - 19 FROM tab2 cor0
----
-1
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1953
SELECT + col0 * cor0.col0 DIV col1 FROM tab2 AS cor0
----
1
103
367

skipif mysql # not compatible
query I rowsort label-1953
SELECT + col0 * cor0.col0 / col1 FROM tab2 AS cor0
----
1
103
367

query I rowsort
SELECT + col0 * col0 - - tab0.col1 FROM tab0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - col0 * + col1 + + 30 + 41 AS col0 FROM tab2
----
-1272
-146
-4531

query I rowsort
SELECT 70 + - col2 AS col0 FROM tab1
----
-26
13
16

query I rowsort
SELECT col1 * tab0.col1 + - tab0.col1 FROM tab0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT col2 + col2 * + 71 FROM tab0
----
2376
5904
72

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to d95cefa45985203e212af5af5dd9be5b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1960
SELECT ALL - cor0.col2 DIV 17 + + ( col2 ) * - 61 FROM tab0 AS cor0
----
-2014
-5006
-61

skipif mysql # not compatible
query I rowsort label-1960
SELECT ALL - cor0.col2 / 17 + + ( col2 ) * - 61 FROM tab0 AS cor0
----
-2014
-5006
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1961
SELECT DISTINCT + col0 * + 30 - 3 DIV col1 FROM tab0 AS cor0
----
1050
2670
720

skipif mysql # not compatible
query I rowsort label-1961
SELECT DISTINCT + col0 * + 30 - 3 / col1 FROM tab0 AS cor0
----
1050
2670
720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col0 * + col1 col0 FROM tab1
----
234
40960
83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1963
SELECT DISTINCT + - col1 * - CAST( NULL AS SIGNED ) * + 18 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1963
SELECT DISTINCT + - col1 * - CAST ( NULL AS INTEGER ) * + 18 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1964
SELECT ALL + + col0 DIV 30 AS col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1964
SELECT ALL + + col0 / 30 AS col0 FROM tab0 AS cor0
----
0
1
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1965
SELECT DISTINCT col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1965
SELECT DISTINCT col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + + 97 FROM tab2 AS cor0
----
123
124
135

query I rowsort
SELECT + col0 * + ( 24 * col1 ) FROM tab0 AS cor0
----
194376
49536
81480

query I rowsort
SELECT - col2 + + 75 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
171
4743
5904

query I rowsort
SELECT ALL col0 + col0 * + 98 FROM tab1 AS cor0
----
297
6336
7920

query I rowsort
SELECT DISTINCT - col0 * 4 AS col0 FROM tab2 AS cor0
----
-28
-312
-316

query I rowsort
SELECT DISTINCT - col2 + - col1 * col1 AS col2 FROM tab1
----
-157
-265
-730

onlyif mysql # use DIV operator for integer division
query I rowsort label-1972
SELECT ALL - 94 * + col0 DIV col0 + + cor0.col0 FROM tab2 AS cor0
----
-15
-16
-87

skipif mysql # not compatible
query I rowsort label-1972
SELECT ALL - 94 * + col0 / col0 + + cor0.col0 FROM tab2 AS cor0
----
-15
-16
-87

query I rowsort
SELECT ALL - - ( + col2 ) + col1 + 83 AS col2 FROM tab1 AS cor0
----
150
163
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + ( + col0 ) col0 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 44 * - col0 - col1 col0 FROM tab0 cor0
----
1443
3825
970

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1976
SELECT + CAST( 61 AS SIGNED ) + col0 * ( - col1 ) AS col2 FROM tab2 AS cor0
----
-1282
-156
-4541

skipif mysql # not compatible
query I rowsort label-1976
SELECT + CAST ( 61 AS INTEGER ) + col0 * ( - col1 ) AS col2 FROM tab2 AS cor0
----
-1282
-156
-4541

query I rowsort
SELECT + + ( - 15 ) * - cor0.col2 FROM tab2 AS cor0
----
390
405
570

query I rowsort
SELECT DISTINCT - ( col2 ) * + col2 + + ( col0 ) AS col0 FROM tab2 cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT col1 * + col2 + col0 * 86 AS col1 FROM tab1 AS cor0
----
1662
6074
8128

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1980
SELECT cor0.col0 + CAST( NULL AS SIGNED ) FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1980
SELECT cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 52 FROM tab2 AS cor0
----
-52
-52
-52

query I rowsort
SELECT + + col0 * col2 + ( + col1 * - col2 ) AS col1 FROM tab0 AS cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1983
SELECT DISTINCT + - col0 * col0 + 91 DIV + col1 FROM tab2 AS cor0
----
-47
-6083
-6236

skipif mysql # not compatible
query I rowsort label-1983
SELECT DISTINCT + - col0 * col0 + 91 / + col1 FROM tab2 AS cor0
----
-47
-6083
-6236

onlyif mysql # use DIV operator for integer division
query I rowsort label-1984
SELECT DISTINCT - - ( + col0 ) DIV - ( col0 ) - col0 * - col1 AS col1 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-1984
SELECT DISTINCT - - ( + col0 ) / - ( col0 ) - col0 * - col1 AS col1 FROM tab0 AS cor0
----
2063
3394
8098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col1 + cor0.col0 * cor0.col2 * col1 col2 FROM tab1 AS cor0
----
100880
37120
4290

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 33 - - col0 col0 FROM tab1 AS cor0
----
113
36
97

query I rowsort
SELECT - col0 * + col2 * - ( - col0 ) AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT + cor0.col2 * - col0 + col1 * col2 * + col2 FROM tab0 AS cor0
----
604586
62
92862

query I rowsort
SELECT - - col2 * col0 + ( 99 ) FROM tab0 AS cor0
----
134
7397
891

query I rowsort
SELECT + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # use DIV operator for integer division
query I rowsort label-1991
SELECT 36 DIV + col1 + + col0 col1 FROM tab2 AS cor0
----
78
8
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1991
SELECT 36 / + col1 + + col0 col1 FROM tab2 AS cor0
----
78
8
81

query I rowsort
SELECT - ( - cor0.col0 ) * ( col2 ) FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT col1 * col0 + + col2 * + col0 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT DISTINCT + col0 + + cor0.col0 * + 86 FROM tab2 cor0
----
609
6786
6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-1995
SELECT col1 * col1 DIV CAST( 4 AS SIGNED ) - col1 AS col1 FROM tab1 cor0
----
143
15
29

skipif mysql # not compatible
query I rowsort label-1995
SELECT col1 * col1 / CAST ( 4 AS INTEGER ) - col1 AS col1 FROM tab1 cor0
----
143
15
29

query I rowsort
SELECT DISTINCT - + 28 * col0 + 4 FROM tab0 AS cor0
----
-2488
-668
-976

onlyif mysql # use DIV operator for integer division
query I rowsort label-1997
SELECT ALL - col2 DIV col2 col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1997
SELECT ALL - col2 / col2 col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * + col0 - 10 * - col1 col0 FROM tab1 AS cor0
----
-540
-910
182

query I rowsort
SELECT + col1 + ( - col2 ) AS col2 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2000
SELECT + cor0.col2 * + 99 + + col0 * - cor0.col0 DIV col0 AS col1 FROM tab1 AS cor0
----
5343
5579
9424

skipif mysql # not compatible
query I rowsort label-2000
SELECT + cor0.col2 * + 99 + + col0 * - cor0.col0 / col0 AS col1 FROM tab1 AS cor0
----
5343
5579
9424

query I rowsort
SELECT + cor0.col0 * ( + ( + col1 ) ) + + col0 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT ( col1 ) * - ( 31 ) * - col1 + - ( - col0 ) * - col2 FROM tab1
----
-2441
-548
20794

query I rowsort
SELECT ALL + 71 + col0 * - col2 AS col1 FROM tab0
----
-721
-7227
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2004
SELECT ALL - ( + col0 ) + + col0 DIV col2 col0 FROM tab0 AS cor0
----
-24
-88
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2004
SELECT ALL - ( + col0 ) + + col0 / col2 col0 FROM tab0 AS cor0
----
-24
-88
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 54 * col0 col1 FROM tab0 cor0
----
-1296
-1890
-4806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2006
SELECT ALL CAST( col2 AS SIGNED ) * col2 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-2006
SELECT ALL CAST ( col2 AS INTEGER ) * col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col1 * + 42 AS col0 FROM tab2 AS cor0
----
-1302
-2478
-714

onlyif mysql # use DIV operator for integer division
query I rowsort label-2008
SELECT DISTINCT - col1 DIV - col1 AS col2 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2008
SELECT DISTINCT - col1 / - col1 AS col2 FROM tab1 cor0
----
1

query I rowsort
SELECT ( - 13 ) * col2 AS col2 FROM tab0 cor0
----
-1066
-13
-429

query I rowsort
SELECT ALL - 4 + - col0 * + col1 FROM tab1
----
-1044
-644
-82

query I rowsort
SELECT ALL ( + col0 ) * col2 + 89 * col1 FROM tab2
----
2948
4515
7279

onlyif mysql # use DIV operator for integer division
query I rowsort label-2012
SELECT DISTINCT + col1 DIV col1 - col2 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-2012
SELECT DISTINCT + col1 / col1 - col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT DISTINCT + cor0.col1 * - col1 FROM tab0 cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2014
SELECT ALL - + ( col1 ) DIV + col1 - col1 AS col2 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-2014
SELECT ALL - + ( col1 ) / + col1 - col1 AS col2 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT ALL + ( col0 ) + col1 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT - 55 + + col1 * - col2 FROM tab1
----
-1303
-1459
-625

query I rowsort
SELECT - col0 * tab0.col1 * col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - - cor0.col1 - + col0 FROM tab0 cor0
----
2
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2019
SELECT - + col0 + CAST( NULL AS SIGNED ) - 38 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2019
SELECT - + col0 + CAST ( NULL AS INTEGER ) - 38 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col1 + col0 * col1 - col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT ( 60 ) AS col2 FROM tab0, tab1 AS cor0
----
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-2022
SELECT 78 DIV + 45 - + tab2.col1 FROM tab2
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-2022
SELECT 78 / + 45 - + tab2.col1 FROM tab2
----
-16
-30
-58

query I rowsort
SELECT 81 + col0 + col0 * col2 FROM tab0 cor0
----
151
7468
897

query I rowsort
SELECT + 12 + - col2 AS col2 FROM tab0 cor0
----
-21
-70
11

query I rowsort
SELECT ALL - - col0 - - col1 FROM tab1 cor0
----
29
74
93

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0, tab2 cor1, tab2 AS cor2
----
972 values hashing to f94a4a64ac54a61fc21f78e2b831ebee

onlyif mysql # use DIV operator for integer division
query I rowsort label-2027
SELECT - col0 DIV 21 AS col2 FROM tab2 AS cor0
----
-3
-3
0

skipif mysql # not compatible
query I rowsort label-2027
SELECT - col0 / 21 AS col2 FROM tab2 AS cor0
----
-3
-3
0

query I rowsort
SELECT - col1 * + col1 - col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT - col2 + col0 * col0 * - col0 FROM tab2 AS cor0
----
-370
-474578
-493077

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 84 col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2031
SELECT col0 + + CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-2031
SELECT col0 + + CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( - 97 ) * col2 + + col0 col2 FROM tab2 AS cor0
----
2600
2626
3765

onlyif mysql # use DIV operator for integer division
query I rowsort label-2033
SELECT col2 * col1 DIV - col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2033
SELECT col2 * col1 / - col1 FROM tab0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2034
SELECT - col1 * 21 DIV col2 AS col2 FROM tab1
----
-10
-2
-3

skipif mysql # not compatible
query I rowsort label-2034
SELECT - col1 * 21 / col2 AS col2 FROM tab1
----
-10
-2
-3

query I rowsort
SELECT - col0 + - 86 FROM tab0 AS cor0
----
-110
-121
-175

query I rowsort
SELECT DISTINCT - col0 * 63 + col0 * + 44 + cor0.col1 FROM tab2 AS cor0
----
-102
-1423
-1484

query I rowsort
SELECT ALL - + cor0.col2 + - col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2038
SELECT ALL + CAST( NULL AS SIGNED ) + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2038
SELECT ALL + CAST ( NULL AS INTEGER ) + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 11 + col0 AS col0 FROM tab0 cor0
----
100
35
46

query I rowsort
SELECT cor0.col2 * col0 - col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT col0 + 67 FROM tab1 AS cor0
----
131
147
70

query I rowsort
SELECT ALL - col1 - 1 FROM tab1 cor0
----
-11
-14
-27

query I rowsort
SELECT ALL - col0 * + col1 + - cor0.col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + 77 * cor0.col1 AS col2 FROM tab0 AS cor0
----
6622
7007
7469

query I rowsort
SELECT - col2 * col1 * - col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL + + 73 AS col2 FROM tab1 cor0
----
73
73
73

query I rowsort
SELECT - ( col2 ) + - col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT - ( + col2 ) + 27 * 73 FROM tab0 AS cor0
----
1889
1938
1970

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2049
SELECT ALL CAST( NULL AS SIGNED ) * - 95 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2049
SELECT ALL CAST ( NULL AS INTEGER ) * - 95 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 14 * + tab2.col1 FROM tab2
----
238
434
826

query I rowsort
SELECT 58 * 37 AS col2 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 4739a739df32b7c22892df2a075095e8

query I rowsort
SELECT 9 * col0 + + col0 AS col0 FROM tab1 AS cor0
----
30
640
800

query I rowsort
SELECT - + 5 * + col2 AS col0 FROM tab0 AS cor0
----
-165
-410
-5

query I rowsort
SELECT ALL ( - 97 ) * + col1 * - col1 AS col2 FROM tab2 AS cor0
----
28033
337657
93217

query I rowsort
SELECT DISTINCT cor0.col1 - + col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + 63 * + col0 + col1 AS col0 FROM tab2 AS cor0
----
472
4973
4994

onlyif mysql # use DIV operator for integer division
query I rowsort label-2057
SELECT col0 DIV - cor0.col1 + + cor0.col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2057
SELECT col0 / - cor0.col1 + + cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT 87 * cor0.col1 FROM tab2 AS cor0
----
1479
2697
5133

onlyif mysql # use DIV operator for integer division
query I rowsort label-2059
SELECT ALL + cor0.col1 DIV + col2 + + col2 * col1 FROM tab0 cor0
----
194
2840
7463

skipif mysql # not compatible
query I rowsort label-2059
SELECT ALL + cor0.col1 / + col2 + + col2 * col1 FROM tab0 cor0
----
194
2840
7463

query I rowsort
SELECT DISTINCT col2 - ( + tab2.col0 + col0 ) * col1 FROM tab2
----
-2648
-407
-9178

query I rowsort
SELECT + col2 + cor0.col2 + + col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
2080
243
3078

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col1 + col2 * - col2 * + col1 col1 FROM tab1
----
-119977
-32590
-76492

onlyif mysql # use DIV operator for integer division
query I rowsort label-2063
SELECT ALL 30 DIV col1 + + col0 FROM tab2
----
7
78
80

skipif mysql # not compatible
query I rowsort label-2063
SELECT ALL 30 / col1 + + col0 FROM tab2
----
7
78
80

query I rowsort
SELECT DISTINCT + 12 + + 45 AS col2 FROM tab0
----
57

query I rowsort
SELECT col0 + tab1.col1 * col1 * col0 AS col2 FROM tab1
----
13600
2031
6464

onlyif mysql # use DIV operator for integer division
query I rowsort label-2066
SELECT ALL ( - tab2.col2 ) * - col0 + col2 DIV - tab2.col1 FROM tab2
----
189
2028
3000

skipif mysql # not compatible
query I rowsort label-2066
SELECT ALL ( - tab2.col2 ) * - col0 + col2 / - tab2.col1 FROM tab2
----
189
2028
3000

query I rowsort
SELECT + col0 * 42 + - col1 + - col1 FROM tab2
----
232
3158
3284

onlyif mysql # use DIV operator for integer division
query I rowsort label-2068
SELECT ( + col2 ) DIV col1 + col2 * col0 FROM tab1
----
164
3653
7687

skipif mysql # not compatible
query I rowsort label-2068
SELECT ( + col2 ) / col1 + col2 * col0 FROM tab1
----
164
3653
7687

query I rowsort
SELECT + + ( col2 ) + - col0 * col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT + ( - tab1.col1 ) - - col2 FROM tab1
----
28
47
83

query I rowsort
SELECT tab0.col2 + ( col0 * col1 ) FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col0 * ( col0 * tab0.col1 ) AS col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT ( col0 + + col2 * - col1 ) AS col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT - 82 * - tab2.col1 * + col2 AS col1 FROM tab2
----
125788
52972
68634

query I rowsort
SELECT DISTINCT - 78 + col1 FROM tab0
----
13
19
8

query I rowsort
SELECT DISTINCT - ( col0 ) * - col2 + col1 * col2 * + col0 AS col0 FROM tab0
----
3430
671416
68904

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2077
SELECT - CAST( - col1 AS SIGNED ) * col0 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-2077
SELECT - CAST ( - col1 AS INTEGER ) * col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT col0 * + 85 FROM tab2 cor0
----
595
6630
6715

query I rowsort
SELECT DISTINCT + 3 * - col0 AS col1 FROM tab0
----
-105
-267
-72

query I rowsort
SELECT DISTINCT - cor0.col2 + 10 * col1 FROM tab1 AS cor0
----
206
34
43

query I rowsort
SELECT ALL col0 * + col2 * ( - col0 ) AS col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT - col1 * + col1 + col1 AS col0 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT - tab1.col2 - col2 * tab1.col1 * col0 AS col1 FROM tab1
----
-36537
-4266
-99936

query I rowsort
SELECT ALL col1 + 22 FROM tab1
----
32
35
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col0 + col1 col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT col1 + 34 + 63 FROM tab1
----
107
110
123

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * 50 col2 FROM tab2 AS cor0
----
-1300
-1350
-1900

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 35 col0 FROM tab0 AS cor0
----
124
59
70

query I rowsort
SELECT col1 + ( + col1 ) * - col1 AS col2 FROM tab2 cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL + col2 - + col2 AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2091
SELECT - col2 * ( + cor0.col2 ) * + cor0.col1 + - col0 DIV + col1 + + col1 * + col2 * - col1 FROM tab2 AS cor0
----
-130391
-35534
-48546

skipif mysql # not compatible
query I rowsort label-2091
SELECT - col2 * ( + cor0.col2 ) * + cor0.col1 + - col0 / + col1 + + col1 * + col2 * - col1 FROM tab2 AS cor0
----
-130391
-35534
-48546

query I rowsort
SELECT ALL col2 + - 78 * + 84 FROM tab1 cor0
----
-6456
-6495
-6498

query I rowsort
SELECT DISTINCT col0 * - col0 + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2094
SELECT DISTINCT - col2 - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2094
SELECT DISTINCT - col2 - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col1 + + 36 FROM tab1 AS cor0
----
10
23
26

query I rowsort
SELECT ALL + col0 + - 7 AS col2 FROM tab2 AS cor0
----
0
71
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2097
SELECT ALL + col0 DIV tab1.col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2097
SELECT ALL + col0 / tab1.col0 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT + col1 + - col1 + + col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2099
SELECT ALL + col0 + col1 DIV col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-2099
SELECT ALL + col0 + col1 / col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT - cor0.col1 + col2 * cor0.col0 AS col0 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT - + cor0.col1 * col1 * col0 + + col0 * col0 + - cor0.col1 FROM tab1 AS cor0
----
-2045
-2314
-7133

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - cor0.col1 - + col1 AS col1 FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT - - cor0.col1 * + col2 + col0 + + col1 FROM tab1 AS cor0
----
1341
1433
644

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col1 - col0 * col0 * + col0 col2 FROM tab1 AS cor0
----
-261504
-510960
51

query I rowsort
SELECT - - col1 * + col2 + + col0 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT col2 * - col2 - col2 AS col1 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT DISTINCT - col0 + col2 * - cor0.col2 + col1 * col0 FROM tab2 AS cor0
----
-180
-519
3848

query I rowsort
SELECT DISTINCT - col0 + + col1 * + col0 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + col0 + col2 col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT 65 * + col0 FROM tab2 AS cor0
----
455
5070
5135

query I rowsort
SELECT DISTINCT - - col1 + col0 * + col2 AS col0 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT ALL + - 31 * - col1 - + col2 * + col2 * col2 AS col2 FROM tab1 AS cor0
----
-156658
-184883
-884333

onlyif mysql # use DIV operator for integer division
query I rowsort label-2114
SELECT DISTINCT 84 DIV + col0 AS col2 FROM tab0 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-2114
SELECT DISTINCT 84 / + col0 AS col2 FROM tab0 AS cor0
----
0
2
3

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 + + col2 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + col0 + + col1 * col0 + - col2 FROM tab1 AS cor0
----
1024
27
647

query I rowsort
SELECT - col0 + + cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2118
SELECT - - col0 DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2118
SELECT - - col0 / cor0.col0 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT col2 * col1 * - col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT 21 * - col2 * + col2 FROM tab0 AS cor0
----
-141204
-21
-22869

query I rowsort
SELECT + cor0.col0 * + col2 * + col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ( - ( - col0 ) ) FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - + 66 AS col0 FROM tab0 cor0
----
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 96 ) col0 FROM tab0
----
-96
-96
-96

query I rowsort
SELECT DISTINCT + 51 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
51

query I rowsort
SELECT ALL cor0.col2 + - cor0.col2 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL 17 * + col0 - col2 AS col1 FROM tab2
----
1300
1305
92

query I rowsort
SELECT - 39 * col1 + col0 FROM tab2 AS cor0
----
-1202
-2223
-584

query I rowsort
SELECT DISTINCT - tab0.col0 * ( col1 ) FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + + col2 + 89 * + col1 * + col2 AS col0 FROM tab1 AS cor0
----
111168
125010
50787

query I rowsort
SELECT ALL + tab1.col2 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT - tab1.col0 * + col2 AS col1 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + 88 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT - 40 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT - + cor0.col1 + - ( + col0 + col0 ) AS col2 FROM tab2 AS cor0
----
-175
-215
-45

query I rowsort
SELECT ALL - col1 + - col2 * col1 * + ( - 69 ) + col2 AS col0 FROM tab1
----
39377
86195
96904

query I rowsort
SELECT - - 92 + col2 * col0 FROM tab0 AS cor0
----
127
7390
884

query I rowsort
SELECT 10 * - 49 FROM tab0 AS cor0
----
-490
-490
-490

query I rowsort
SELECT - 13 + - 38 AS col2 FROM tab2 AS cor0
----
-51
-51
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 25 + col0 * col2 col2 FROM tab0 AS cor0
----
60
7323
817

onlyif mysql # use DIV operator for integer division
query I rowsort label-2141
SELECT - + col0 * col1 DIV - col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2141
SELECT - + col0 * col1 / - col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL 62 * col1 FROM tab1 AS cor0
----
1612
620
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2143
SELECT ALL col2 + col1 DIV col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2143
SELECT ALL col2 + col1 / col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL col1 * col1 * + col1 FROM tab1
----
1000
17576
2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-2145
SELECT + + 85 DIV col0 AS col0 FROM tab1 AS cor0
----
1
1
28

skipif mysql # not compatible
query I rowsort label-2145
SELECT + + 85 / col0 AS col0 FROM tab1 AS cor0
----
1
1
28

skipif mysql # not compatible
query I rowsort
SELECT col2 * + col2 + - CAST ( 5 AS REAL ) FROM tab1 AS cor0
----
2911
3244
9211

onlyif mysql # use DIV operator for integer division
query I rowsort label-2147
SELECT ALL + + cor0.col0 DIV col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2147
SELECT ALL + + cor0.col0 / col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - col1 * - 43 + + cor0.col0 FROM tab0 AS cor0
----
3722
4002
4206

query I rowsort
SELECT ALL + tab0.col0 * - tab0.col1 + - ( - col2 * + col0 ) AS col0 FROM tab0
----
-1272
-3360
-801

query I rowsort
SELECT ALL col0 * col2 + - col1 AS col2 FROM tab2
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - 59 col1 FROM tab1
----
-123
-139
-62

query I rowsort
SELECT DISTINCT col0 + 3 * col0 FROM tab1
----
12
256
320

query I rowsort
SELECT ALL cor0.col2 + + cor0.col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + + col2 * 54 + cor0.col0 * col2 * - 73 FROM tab1 AS cor0
----
-263226
-555456
-8910

query I rowsort
SELECT ALL col1 + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + col0 + + 94 FROM tab1 AS cor0
----
158
174
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2157
SELECT ALL - col1 DIV cor0.col0 + - col2 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-2157
SELECT ALL - col1 / cor0.col0 + - col2 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT 59 * col2 + col0 * + ( 13 ) FROM tab2 AS cor0
----
1684
2548
3269

query I rowsort
SELECT ALL - + col1 * - cor0.col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + 12 + 98 AS col2 FROM tab1 AS cor0
----
110

query I rowsort
SELECT + + ( 76 ) FROM tab0 AS cor0
----
76
76
76

query I rowsort
SELECT ALL col1 * + col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 31 * cor0.col1 + + col1 col0 FROM tab2 AS cor0
----
1888
544
992

query I rowsort
SELECT DISTINCT + - 61 + + col1 * col0 AS col0 FROM tab2 AS cor0
----
1282
156
4541

onlyif mysql # use DIV operator for integer division
query I rowsort label-2165
SELECT DISTINCT - col1 * 34 + col0 DIV col2 FROM tab1 AS cor0
----
-339
-442
-884

skipif mysql # not compatible
query I rowsort label-2165
SELECT DISTINCT - col1 * 34 + col0 / col2 FROM tab1 AS cor0
----
-339
-442
-884

query I rowsort
SELECT col2 * ( + 7 + col1 ) FROM tab0
----
104
3069
8036

query I rowsort
SELECT ALL col0 - ( cor0.col0 * - col1 ) FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT + col1 * + col1 + col0 * col1 AS col1 FROM tab2 AS cor0
----
1178
1632
8083

query I rowsort
SELECT - col1 * 70 AS col1 FROM tab1
----
-1820
-700
-910

onlyif mysql # use DIV operator for integer division
query I rowsort label-2170
SELECT ALL + col0 * 63 + col1 * col1 DIV + 21 FROM tab2 AS cor0
----
486
4990
5079

skipif mysql # not compatible
query I rowsort label-2170
SELECT ALL + col0 * 63 + col1 * col1 / + 21 FROM tab2 AS cor0
----
486
4990
5079

query I rowsort
SELECT + 94 + - ( col0 ) AS col2 FROM tab0 AS cor0
----
5
59
70

query I rowsort
SELECT + ( - cor0.col0 ) * col1 + col2 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-2173
SELECT + 52 DIV - col0 FROM tab1 AS cor0
----
-17
0
0

skipif mysql # not compatible
query I rowsort label-2173
SELECT + 52 / - col0 FROM tab1 AS cor0
----
-17
0
0

query I rowsort
SELECT DISTINCT + col2 + - col1 * cor0.col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2175
SELECT DISTINCT + 11 DIV cor0.col2 FROM tab0 AS cor0
----
0
11

skipif mysql # not compatible
query I rowsort label-2175
SELECT DISTINCT + 11 / cor0.col2 FROM tab0 AS cor0
----
0
11

query I rowsort
SELECT - ( 51 ) * - col2 + 75 FROM tab0 AS cor0
----
126
1758
4257

query I rowsort
SELECT ALL col2 * ( col2 ) AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT col1 + col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT ALL - - col0 * + col2 + - col0 * cor0.col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + col2 * col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT + 62 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT ALL - col0 + - 57 FROM tab0
----
-146
-81
-92

query I rowsort
SELECT ALL + tab0.col2 + - col2 - col2 * - col2 FROM tab0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2184
SELECT ALL - col0 DIV 13 - + col1 FROM tab1
----
-14
-19
-26

skipif mysql # not compatible
query I rowsort label-2184
SELECT ALL - col0 / 13 - + col1 FROM tab1
----
-14
-19
-26

query I rowsort
SELECT DISTINCT - ( col1 ) * - ( + 61 ) AS col2 FROM tab2 AS cor0
----
1037
1891
3599

query I rowsort
SELECT DISTINCT + col0 + - col1 + + col2 AS col2 FROM tab1 cor0
----
111
163
31

query I rowsort
SELECT DISTINCT - 70 - + col0 FROM tab1 cor0
----
-134
-150
-73

query I rowsort
SELECT DISTINCT 29 * - col2 + + col2 FROM tab0 AS cor0
----
-2296
-28
-924

query I rowsort
SELECT ALL - cor0.col2 - + col1 * 33 FROM tab1 cor0
----
-387
-525
-912

query I rowsort
SELECT - - col1 + - col2 * cor0.col0 AS col0 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL - 11 + + col1 FROM tab2
----
20
48
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2192
SELECT DISTINCT col1 * col1 * CAST( + 30 AS SIGNED ) + col1 * cor0.col0 * col2 FROM tab2 AS cor0
----
224082
34689
59704

skipif mysql # not compatible
query I rowsort label-2192
SELECT DISTINCT col1 * col1 * CAST ( + 30 AS INTEGER ) + col1 * cor0.col0 * col2 FROM tab2 AS cor0
----
224082
34689
59704

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + + col1 col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT 63 - + cor0.col1 FROM tab2 cor0
----
32
4
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2195
SELECT - 31 * - col2 * CAST( col0 AS SIGNED ) + + col0 FROM tab1
----
113152
238160
5025

skipif mysql # not compatible
query I rowsort label-2195
SELECT - 31 * - col2 * CAST ( col0 AS INTEGER ) + + col0 FROM tab1
----
113152
238160
5025

query I rowsort
SELECT + - col1 * - col0 * - col0 AS col2 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL - 27 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0259a67676b131a4843853be4811b775

query I rowsort
SELECT ALL tab0.col2 * + tab0.col2 * col1 FROM tab0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2199
SELECT ALL col1 * ( - 2 ) DIV col2 FROM tab0
----
-194
-2
-5

skipif mysql # not compatible
query I rowsort label-2199
SELECT ALL col1 * ( - 2 ) / col2 FROM tab0
----
-194
-2
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2200
SELECT DISTINCT - col1 * CAST( col1 AS SIGNED ) * - cor0.col0 + - 73 AS col0 FROM tab2 cor0
----
22758
271445
6654

skipif mysql # not compatible
query I rowsort label-2200
SELECT DISTINCT - col1 * CAST ( col1 AS INTEGER ) * - cor0.col0 + - 73 AS col0 FROM tab2 cor0
----
22758
271445
6654

onlyif mysql # use DIV operator for integer division
query I rowsort label-2201
SELECT DISTINCT col0 + 3 + + col0 DIV col0 FROM tab1 AS cor0
----
68
7
84

skipif mysql # not compatible
query I rowsort label-2201
SELECT DISTINCT col0 + 3 + + col0 / col0 FROM tab1 AS cor0
----
68
7
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 15 * 9 + col1 col0 FROM tab1
----
145
148
161

query I rowsort
SELECT ALL cor0.col1 + + cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 1a063bfb694f348122cd0739295ca641

query I rowsort
SELECT ALL cor0.col0 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-2205
SELECT 4 DIV 59 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2205
SELECT 4 / 59 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 4 + - 1 FROM tab0 AS cor0
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2207
SELECT 57 + ( - col0 ) DIV col0 - 19 FROM tab0 AS cor0
----
37
37
37

skipif mysql # not compatible
query I rowsort label-2207
SELECT 57 + ( - col0 ) / col0 - 19 FROM tab0 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT cor0.col2 + + cor0.col2 * col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-2209
SELECT + col1 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2209
SELECT + col1 / cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT ALL 62 + + col1 * + ( + col1 ) AS col1 FROM tab2 AS cor0
----
1023
351
3543

onlyif mysql # use DIV operator for integer division
query I rowsort label-2211
SELECT col0 DIV col0 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2211
SELECT col0 / col0 AS col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + col1 + col1 AS col2 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT + col1 + col2 * col2 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT col2 + 35 * + col2 * - col1 + col2 FROM tab2
----
-22534
-29241
-53638

onlyif mysql # use DIV operator for integer division
query I rowsort label-2215
SELECT ( col1 ) DIV CAST( + col2 AS SIGNED ) + - cor0.col1 AS col0 FROM tab0 cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-2215
SELECT ( col1 ) / CAST ( + col2 AS INTEGER ) + - cor0.col1 AS col0 FROM tab0 cor0
----
-84
-90
0

query I rowsort
SELECT DISTINCT + - col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - - tab0.col0 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT col1 + + tab2.col0 * - col0 * col2 AS col1 FROM tab2
----
-1292
-158125
-237141

query I rowsort
SELECT + tab0.col2 + - col0 * col2 AS col0 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT ALL - col1 * + col0 + + col2 FROM tab1
----
-24
-583
-944

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) > col0 + col0 * - col0
----

query I rowsort
SELECT + col0 * - col0 + + col1 AS col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - col1 * col0 + col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT ALL col2 AS col0 FROM tab2 WHERE ( NULL ) IN ( col1 * - col1 * col0 + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 + col0 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + + 80 FROM tab2 cor0
----
80
80
80

query I rowsort
SELECT DISTINCT col2 * col0 FROM tab1 WHERE NOT + col0 NOT BETWEEN col0 AND ( col0 )
----
162
3648
7680

query I rowsort
SELECT col0 * - col2 - + tab0.col1 FROM tab0 WHERE NOT NULL BETWEEN NULL AND + col0 / col2
----

query I rowsort
SELECT DISTINCT + tab2.col0 + col2 * col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT DISTINCT + col2 + col0 * + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT ALL + col0 FROM tab2 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT + col0 * cor0.col2 + - cor0.col0 + col1 * + col0 FROM tab0 AS cor0
----
15308
2832
3395

onlyif mysql # use DIV operator for integer division
query I rowsort label-2233
SELECT DISTINCT col2 + col1 + + col0 DIV col2 FROM tab1
----
109
68
80

skipif mysql # not compatible
query I rowsort label-2233
SELECT DISTINCT col2 + col1 + + col0 / col2 FROM tab1
----
109
68
80

query I rowsort
SELECT DISTINCT col2 AS col1 FROM tab1 cor0 WHERE ( NULL ) BETWEEN col1 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2235
SELECT DISTINCT col2 DIV - tab1.col1 - col1 FROM tab1
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-2235
SELECT DISTINCT col2 / - tab1.col1 - col1 FROM tab1
----
-15
-20
-28

query I rowsort
SELECT col0 * col1 * col1 + + col0 AS col1 FROM tab0
----
177528
329350
737098

query I rowsort
SELECT - col0 * - col0 + + col1 * + col1 FROM tab1 AS cor0
----
4196
6569
685

query I rowsort
SELECT DISTINCT + tab2.col1 - + col2 * + col2 FROM tab2
----
-1427
-617
-698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - ( col2 ) * col2 col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT + col1 * ( + col2 ) AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - ( + cor0.col2 ) * col0 + 24 AS col2 FROM tab1 AS cor0
----
-138
-3624
-7656

query I rowsort
SELECT ALL + - 75 * - col1 FROM tab1 AS cor0
----
1950
750
975

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col2 * + col2 col1 FROM tab2
----
1427
617
698

query I rowsort
SELECT DISTINCT - col0 + ( col1 * col2 ) AS col1 FROM tab1
----
1168
1401
506

query I rowsort
SELECT + col0 * + tab1.col2 + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT 84 - - col1 * tab0.col0 FROM tab0
----
2148
3479
8183

onlyif mysql # use DIV operator for integer division
query I rowsort label-2247
SELECT - 63 + + col1 DIV - col1 AS col2 FROM tab1
----
-64
-64
-64

skipif mysql # not compatible
query I rowsort label-2247
SELECT - 63 + + col1 / - col1 AS col2 FROM tab1
----
-64
-64
-64

query I rowsort
SELECT DISTINCT 60 + + col1 AS col0 FROM tab2
----
119
77
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-2249
SELECT ALL + CAST( + 35 AS SIGNED ) DIV - tab2.col1 + col1 AS col0 FROM tab2
----
15
30
59

skipif mysql # not compatible
query I rowsort label-2249
SELECT ALL + CAST ( + 35 AS INTEGER ) / - tab2.col1 + col1 AS col0 FROM tab2
----
15
30
59

query I rowsort
SELECT 73 + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 4721c071bcaf513fe282787bcb4da2a8

query I rowsort
SELECT + 93 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to bed80270d2bd273301f8ff63d7ef9f43

query I rowsort
SELECT DISTINCT 79 + - col0 AS col2 FROM tab1 AS cor0
----
-1
15
76

query I rowsort
SELECT ALL - - col0 * - 77 + col0 FROM tab0 AS cor0
----
-1824
-2660
-6764

query I rowsort
SELECT + 99 * + col1 * tab0.col0 + col2 * col0 - - ( tab0.col1 + col1 ) FROM tab0
----
205300
336334
809281

query I rowsort
SELECT 0 * col0 + - ( col2 ) FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT cor1.col1 AS col2 FROM tab1, tab0, tab1 cor0, tab0 AS cor1
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2257
SELECT DISTINCT + 8 DIV col0 AS col1 FROM tab1
----
0
2

skipif mysql # not compatible
query I rowsort label-2257
SELECT DISTINCT + 8 / col0 AS col1 FROM tab1
----
0
2

query I rowsort
SELECT DISTINCT tab2.col0 AS col0 FROM tab2, tab2 cor0
----
7
78
79

query I rowsort
SELECT 65 + col0 FROM tab0
----
100
154
89

query I rowsort
SELECT ALL col1 * + col0 + 18 * + col0 + + col1 FROM tab0 cor0
----
2582
4122
9792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - - ( 22 ) * col0 col1 FROM tab0 AS cor0
----
2049
614
867

query I rowsort
SELECT cor0.col1 * - ( col2 ) + - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT col1 * cor0.col0 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + + col1 * + col1 * col1 FROM tab1 cor0
----
1000
17576
2197

query I rowsort
SELECT col1 + + col2 * col1 * cor0.col1 AS col1 FROM tab2 AS cor0
----
10999
25978
90565

query I rowsort
SELECT 3 + col1 FROM tab1 AS cor0
----
13
16
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-2267
SELECT ALL 10 DIV + 82 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2267
SELECT ALL 10 / + 82 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( - col0 + col0 ) * 68 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * col2 * col0 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col0 col0 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to adaea38eae032c1639715f21831dd376

query I rowsort
SELECT DISTINCT 44 + + col0 FROM tab2 AS cor0
----
122
123
51

query I rowsort
SELECT DISTINCT + - 85 AS col0 FROM tab1 AS cor0
----
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col1 - - 55 col0 FROM tab0 cor0
----
153
174
228

query I rowsort
SELECT - col1 * + 5 FROM tab1
----
-130
-50
-65

query I rowsort
SELECT - col1 * ( 92 ) * col1 + col0 * tab1.col0 * col0 AS col2 FROM tab1
----
-62165
252944
496452

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 87 col2 FROM tab1
----
141
144
183

query I rowsort
SELECT DISTINCT + col0 + 45 AS col0 FROM tab2
----
123
124
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2278
SELECT - col0 + 57 DIV + 65 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2278
SELECT - col0 + 57 / + 65 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + - cor2.col1 * - cor0.col2 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 809af30f4c33611dc6028f1dfeee2879

query I rowsort
SELECT 27 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT DISTINCT - col2 * - 33 AS col2 FROM tab1 AS cor0
----
1782
1881
3168

query I rowsort
SELECT + col2 * - cor0.col2 * 99 FROM tab1 AS cor0
----
-288684
-321651
-912384

onlyif mysql # use DIV operator for integer division
query I rowsort label-2283
SELECT + col1 + col2 DIV - cor0.col2 FROM tab1 cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-2283
SELECT + col1 + col2 / - cor0.col2 FROM tab1 cor0
----
12
25
9

query I rowsort
SELECT 64 * + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-13888
-294528
-85952

query I rowsort
SELECT ALL + 15 * col0 AS col0 FROM tab1 AS cor0
----
1200
45
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-2286
SELECT + - 68 DIV - 89 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2286
SELECT + - 68 / - 89 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + + 33 FROM tab1 cor0
----
43
46
59

query I rowsort
SELECT ALL - col0 * - 48 AS col2 FROM tab0 AS cor0
----
1152
1680
4272

onlyif mysql # use DIV operator for integer division
query I rowsort label-2289
SELECT DISTINCT - cor0.col2 * 96 DIV + col1 FROM tab1 AS cor0
----
-199
-547
-708

skipif mysql # not compatible
query I rowsort label-2289
SELECT DISTINCT - cor0.col2 * 96 / + col1 FROM tab1 AS cor0
----
-199
-547
-708

query I rowsort
SELECT DISTINCT - + col0 + 71 FROM tab1 AS cor0
----
-9
68
7

query I rowsort
SELECT + - col2 * 95 FROM tab2 AS cor0
----
-2470
-2565
-3610

query I rowsort
SELECT ALL - - col1 * 89 FROM tab1 AS cor0
----
1157
2314
890

query I rowsort
SELECT tab0.col1 * + 78 AS col2 FROM tab0
----
6708
7098
7566

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2294
SELECT - CAST( 9 AS SIGNED ) + - col2 * - col2 AS col0 FROM tab2 AS cor0
----
1435
667
720

skipif mysql # not compatible
query I rowsort label-2294
SELECT - CAST ( 9 AS INTEGER ) + - col2 * - col2 AS col0 FROM tab2 AS cor0
----
1435
667
720

query I rowsort
SELECT ALL - col0 + + col2 * + 7 + - col1 AS col0 FROM tab1
----
325
349
579

query I rowsort
SELECT col0 * + col0 + col2 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT ALL + 21 AS col2 FROM tab2
----
21
21
21

query I rowsort
SELECT ALL - ( col1 ) + - col1 * + ( - col2 ) + + cor0.col1 * + 7 AS col0 FROM tab0 AS cor0
----
3354
679
8008

query I rowsort
SELECT ( 56 ) + - cor0.col1 + - col0 * col1 FROM tab0 AS cor0
----
-2094
-3436
-8134

onlyif mysql # use DIV operator for integer division
query I rowsort label-2300
SELECT col0 + 7 DIV + cor0.col1 AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2300
SELECT col0 + 7 / + cor0.col1 AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col0 * + 96 + cor0.col0 FROM tab2 AS cor0
----
679
7566
7663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 col1 FROM tab1 AS cor0
----
58
58
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2303
SELECT - col2 * col2 + + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2303
SELECT - col2 * col2 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2304
SELECT col2 + + col0 * col2 DIV - cor0.col1 AS col0 FROM tab0 AS cor0
----
1
2
24

skipif mysql # not compatible
query I rowsort label-2304
SELECT col2 + + col0 * col2 / - cor0.col1 AS col0 FROM tab0 AS cor0
----
1
2
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-2305
SELECT ALL 12 * tab0.col1 DIV col1 FROM tab0
----
12
12
12

skipif mysql # not compatible
query I rowsort label-2305
SELECT ALL 12 * tab0.col1 / col1 FROM tab0
----
12
12
12

query I rowsort
SELECT ALL ( + col2 * col2 ) AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - col0 - + ( 40 ) FROM tab2 AS cor0
----
-118
-119
-47

onlyif mysql # use DIV operator for integer division
query I rowsort label-2308
SELECT col1 * col0 DIV col0 - col0 * 33 AS col0 FROM tab1 AS cor0
----
-2102
-2627
-73

skipif mysql # not compatible
query I rowsort label-2308
SELECT col1 * col0 / col0 - col0 * 33 AS col0 FROM tab1 AS cor0
----
-2102
-2627
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + 49 * - col1 col1 FROM tab2 AS cor0
----
-1526
-2969
-912

query I rowsort
SELECT col0 + + ( 6 ) AS col2 FROM tab0 AS cor0
----
30
41
95

query I rowsort
SELECT col0 * + col1 - + col2 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT col1 * col1 + col0 AS col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ( tab2.col2 + + col2 ) FROM tab2
----
52
54
76

query I rowsort
SELECT + + col0 + - 13 AS col1 FROM tab2 AS cor0
----
-6
65
66

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - 25 * 77 FROM tab1, tab0 AS cor0
----
9 values hashing to 5fedd640e1c0a9ea3fae9fb61fc59c31

query I rowsort
SELECT ALL col2 * + 82 FROM tab0
----
2706
6724
82

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 + col1 * + col0 + + 30 AS col2 FROM tab0 AS cor0
----
2094
3425
8129

query I rowsort
SELECT ALL - - col1 - cor0.col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT 17 * cor0.col0 FROM tab1 AS cor0
----
1088
1360
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + tab1.col1 col2 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL + + col1 * + 27 + col1 AS col0 FROM tab2 AS cor0
----
1652
476
868

query I rowsort
SELECT - col0 * 82 AS col1 FROM tab1 AS cor0
----
-246
-5248
-6560

query I rowsort
SELECT ALL + + col0 - + 60 FROM tab2 AS cor0
----
-53
18
19

query I rowsort
SELECT DISTINCT - + col0 * + 57 FROM tab2 AS cor0
----
-399
-4446
-4503

query I rowsort
SELECT ALL - col1 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + 56 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT DISTINCT - - col1 + cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - col2 + 91 * col1 * + col2 AS col0 FROM tab0 AS cor0
----
258225
678960
8826

onlyif mysql # use DIV operator for integer division
query I rowsort label-2331
SELECT + 91 DIV 12 AS col1 FROM tab0 cor0
----
7
7
7

skipif mysql # not compatible
query I rowsort label-2331
SELECT + 91 / 12 AS col1 FROM tab0 cor0
----
7
7
7

query I rowsort
SELECT + ( col2 ) * - col2 - - col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT - col0 + col0 * 27 AS col2 FROM tab1 AS cor0
----
1664
2080
78

query I rowsort
SELECT DISTINCT + cor0.col1 * - col2 * - 77 AS col2 FROM tab0 AS cor0
----
218526
574574
7469

query I rowsort
SELECT ALL 63 * - col1 * col1 + - col1 FROM tab2 cor0
----
-18224
-219362
-60574

query I rowsort
SELECT - cor0.col0 * - col0 + col2 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT - cor0.col1 * col1 + 88 + + col1 AS col0 FROM tab0 AS cor0
----
-7222
-8102
-9224

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col2 AS REAL ) * col0 * col2 FROM tab2
----
114076
5103
52728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2339
SELECT DISTINCT + - col1 + - col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2339
SELECT DISTINCT + - col1 + - col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 + + col2 + - col1 AS col0 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT + col1 + - col0 * - col0 AS col0 FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-2342
SELECT ALL - ( col1 ) DIV + CAST( + col1 + - col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2342
SELECT ALL - ( col1 ) / + CAST ( + col1 + - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 67 col0 FROM tab0 AS cor0
----
67

query I rowsort
SELECT DISTINCT ( - cor0.col0 ) * col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2345
SELECT + - col2 DIV - cor0.col0 + 84 FROM tab0 AS cor0
----
84
84
85

skipif mysql # not compatible
query I rowsort label-2345
SELECT + - col2 / - cor0.col0 + 84 FROM tab0 AS cor0
----
84
84
85

query I rowsort
SELECT ALL + cor0.col0 + + col1 * + 80 FROM tab1 AS cor0
----
1120
2083
864

query I rowsort
SELECT DISTINCT - col1 + col1 * ( col2 + - col0 ) * - 18 FROM tab2 AS cor0
----
-11191
12529
55165

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 21 - col0 col2 FROM tab0 AS cor0
----
-14
-3
-68

query I rowsort
SELECT col2 * col0 + col0 * + col1 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT ALL + col1 * - col2 * col1 AS col1 FROM tab0 cor0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2351
SELECT ALL - col1 * - col2 + 80 DIV 25 col1 FROM tab0 AS cor0
----
100
2841
7465

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2351
SELECT ALL - col1 * - col2 + 80 / 25 col1 FROM tab0 AS cor0
----
100
2841
7465

query I rowsort
SELECT ALL 39 * + col0 * - 84 + col0 * - col0 - - col0 FROM tab0 AS cor0
----
-115850
-299396
-79176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 8 + col0 * - col2 col2 FROM tab2 AS cor0
----
-181
-2020
-2994

query I rowsort
SELECT + + 31 AS col0 FROM tab0 AS cor0
----
31
31
31

query I rowsort
SELECT DISTINCT - col1 - col1 * + 74 AS col2 FROM tab2 AS cor0
----
-1275
-2325
-4425

query I rowsort
SELECT DISTINCT - col1 * col2 - col2 AS col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT 92 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT DISTINCT - 87 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-87

query I rowsort
SELECT col2 + - col1 + col0 * + col1 * - col0 FROM tab2
----
-106076
-1523
-358989

query I rowsort
SELECT DISTINCT col1 + - ( + col2 ) FROM tab0 cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 + col0 col0 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2362
SELECT - - col0 + - ( + col1 ) DIV col1 FROM tab1 cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2362
SELECT - - col0 + - ( + col1 ) / col1 FROM tab1 cor0
----
2
63
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2363
SELECT CAST( + 89 AS SIGNED ) + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ac1e8fdf9d96b42a43490dceb2539808

skipif mysql # not compatible
query I rowsort label-2363
SELECT CAST ( + 89 AS INTEGER ) + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ac1e8fdf9d96b42a43490dceb2539808

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2364
SELECT DISTINCT - col2 + col2 * + CAST( NULL AS SIGNED ) * col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2364
SELECT DISTINCT - col2 + col2 * + CAST ( NULL AS INTEGER ) * col2 FROM tab2
----
NULL

query I rowsort
SELECT - 10 * + col2 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT DISTINCT 67 * + 86 - col2 FROM tab0 AS cor0
----
5680
5729
5761

query I rowsort
SELECT DISTINCT 33 * + 89 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 cor1, tab2, tab2 cor2, tab0
----
2937

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2368
SELECT + CAST( NULL AS DECIMAL ) * - tab2.col0 + + col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2368
SELECT + CAST ( NULL AS REAL ) * - tab2.col0 + + col0 AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2369
SELECT + 1 - 96 DIV - col1 col0 FROM tab0
----
1
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2369
SELECT + 1 - 96 / - col1 col0 FROM tab0
----
1
2
2

query I rowsort
SELECT col0 - + tab2.col0 * col0 * + ( tab2.col1 + - col1 ) FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - - cor0.col0 * + col2 - - col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT + col2 * + 34 AS col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT + - col2 + - col0 * + col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT + - col2 - + 34 FROM tab1 cor0
----
-130
-88
-91

query I rowsort
SELECT ALL + 7 FROM tab0, tab2 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2376
SELECT ALL - col0 + + CAST( + col0 AS SIGNED ) * + col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

skipif mysql # not compatible
query I rowsort label-2376
SELECT ALL - col0 + + CAST ( + col0 AS INTEGER ) * + col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT col2 + cor0.col0 * - col0 AS col1 FROM tab2 cor0
----
-22
-6058
-6203

query I rowsort
SELECT + 33 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2379
SELECT DISTINCT 73 DIV - col2 + - ( col1 ) FROM tab1
----
-11
-13
-27

skipif mysql # not compatible
query I rowsort label-2379
SELECT DISTINCT 73 / - col2 + - ( col1 ) FROM tab1
----
-11
-13
-27

query I rowsort
SELECT ALL - col0 + - col0 * - 93 AS col0 FROM tab1 AS cor0
----
276
5888
7360

query I rowsort
SELECT DISTINCT + col2 * col1 + col1 * col2 AS col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT ALL + 31 * cor0.col2 * tab0.col1 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 31317ffefdf437585b11a666784fc38b

query I rowsort
SELECT DISTINCT + 49 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
49

query I rowsort
SELECT ALL col1 + ( col2 ) + - col2 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT col2 + + 93 * col1 AS col1 FROM tab1
----
1305
2472
987

query I rowsort
SELECT DISTINCT 63 + + col1 * - col0 - col0 FROM tab1
----
-1057
-18
-641

query I rowsort
SELECT ALL tab0.col0 * + tab0.col1 * + tab0.col2 - + ( + col2 ) FROM tab0
----
3394
664036
68079

query I rowsort
SELECT 32 - col2 * + col1 AS col2 FROM tab2
----
-1502
-614
-805

query I rowsort
SELECT ALL col0 - col0 * col0 FROM tab1
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2390
SELECT - ( col2 ) - + col0 DIV 85 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2390
SELECT - ( col2 ) - + col0 / 85 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ( col0 ) - - col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + ( 11 ) AS col1 FROM tab0 AS cor0
----
11
11
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-2393
SELECT DISTINCT - - col1 + col2 DIV - 30 AS col2 FROM tab0 AS cor0
----
85
89
97

skipif mysql # not compatible
query I rowsort label-2393
SELECT DISTINCT - - col1 + col2 / - 30 AS col2 FROM tab0 AS cor0
----
85
89
97

query I rowsort
SELECT + ( - col1 ) * cor0.col1 + - cor0.col0 + - col2 AS col2 FROM tab2 AS cor0
----
-3585
-406
-995

query I rowsort
SELECT ALL - 6 * - col1 FROM tab2 AS cor0
----
102
186
354

query I rowsort
SELECT + + 57 - - col0 AS col1 FROM tab1 AS cor0
----
121
137
60

query I rowsort
SELECT - col0 * col1 + ( col0 ) FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - 79 + col0 * col1 * col1 + col2 * + col0 AS col2 FROM tab1 AS cor0
----
2111
21121
9969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + col0 + col2 * col0 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - 8 * col1 * col0 AS col1 FROM tab0 AS cor0
----
-16512
-27160
-64792

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + + col1 AS col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL - + col2 - col0 * - col0 FROM tab2 AS cor0
----
22
6058
6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-2403
SELECT ALL col2 + col0 DIV col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-2403
SELECT ALL col2 + col0 / col2 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT DISTINCT - col2 * col2 + - col2 - - col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - 74 + col1 AS col0 FROM tab2 cor0
----
-15
-43
-57

query I rowsort
SELECT DISTINCT ( + col2 ) * tab1.col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 * - ( + 63 ) col0 FROM tab2
----
40698
52731
96642

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2408
SELECT ALL col1 * + tab0.col0 / - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2408
SELECT ALL col1 * + tab0.col0 / - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 15 * - col1 - - 81 FROM tab0 AS cor0
----
-1209
-1284
-1374

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2410
SELECT cor0.col1 / - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2410
SELECT cor0.col1 / - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2411
SELECT - + col0 + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2411
SELECT - + col0 + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab0.col0 + + 89 AS col0 FROM tab0, tab2 AS cor0
----
113
124
178

query I rowsort
SELECT tab2.col2 + - 62 FROM tab2, tab2 AS cor0
----
9 values hashing to fd187422d0f3eae78b683be2a90b4e6c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col2 col2 FROM tab2
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2415
SELECT - + col1 * CAST( NULL AS SIGNED ) + + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2415
SELECT - + col1 * CAST ( NULL AS INTEGER ) + + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 20 + + 82 + col0 AS col0 FROM tab1 AS cor0
----
126
142
65

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( col0 AS REAL ) - col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2418
SELECT ALL + CAST( + col2 AS SIGNED ) DIV - cor0.col2 + col0 DIV 2 AS col2 FROM tab0 AS cor0
----
11
16
43

skipif mysql # not compatible
query I rowsort label-2418
SELECT ALL + CAST ( + col2 AS INTEGER ) / - cor0.col2 + col0 / 2 AS col2 FROM tab0 AS cor0
----
11
16
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2419
SELECT DISTINCT + 73 DIV + col1 + + col2 FROM tab1 AS cor0
----
101
56
64

skipif mysql # not compatible
query I rowsort label-2419
SELECT DISTINCT + 73 / + col1 + + col2 FROM tab1 AS cor0
----
101
56
64

query I rowsort
SELECT ALL + + ( - col0 ) * - col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL col2 * col0 + - col0 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-2422
SELECT DISTINCT - col1 * col0 * tab1.col0 + col2 DIV + 40 AS col0 FROM tab1
----
-233
-40959
-83198

skipif mysql # not compatible
query I rowsort label-2422
SELECT DISTINCT - col1 * col0 * tab1.col0 + col2 / + 40 AS col0 FROM tab1
----
-233
-40959
-83198

query I rowsort
SELECT col1 * - col0 + col1 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2424
SELECT col1 * col2 DIV + col1 AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2424
SELECT col1 * col2 / + col1 AS col1 FROM tab1
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2425
SELECT ALL - col0 * CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2425
SELECT ALL - col0 * CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col2 * cor1.col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6ed0b6feb543f25f03c87c0bfe584717

onlyif mysql # use DIV operator for integer division
query I rowsort label-2427
SELECT col1 DIV + 18 col0 FROM tab2
----
0
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2427
SELECT col1 / + 18 col0 FROM tab2
----
0
1
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2428
SELECT - col1 * CAST( + col2 AS SIGNED ) FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-2428
SELECT - col1 * CAST ( + col2 AS INTEGER ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + - col0 * - col2 + - cor0.col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL - 80 * col2 - cor0.col2 AS col1 FROM tab2 AS cor0
----
-2106
-2187
-3078

query I rowsort
SELECT + cor0.col0 + 61 AS col1 FROM tab2 AS cor0
----
139
140
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + + 70 * col2 col1 FROM tab1 AS cor0
----
3834
4047
6816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2433
SELECT ALL - CAST( NULL AS SIGNED ) * - 61 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2433
SELECT ALL - CAST ( NULL AS INTEGER ) * - 61 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * - col0 col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + 4 FROM tab2, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2
----
3645 values hashing to 44545a6297aa29bb730ffb907c13bc58

query I rowsort
SELECT + col1 + cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - cor0.col0 - + 88 * - col2 AS col2 FROM tab1 AS cor0
----
4749
4952
8368

query I rowsort
SELECT + ( 59 ) + col0 * + ( ( + col1 ) + 5 ) AS col2 FROM tab0 AS cor0
----
2243
3629
8603

query I rowsort
SELECT + col1 * - cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + ( - cor0.col2 ) + cor0.col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT col2 + + col0 + cor0.col0 * + col2 AS col2 FROM tab1 cor0
----
219
3769
7856

query I rowsort
SELECT + - 81 FROM tab1 AS cor0
----
-81
-81
-81

query I rowsort
SELECT 33 * col1 AS col1 FROM tab1 AS cor0
----
330
429
858

query I rowsort
SELECT - col1 + + col1 * col0 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT - col1 * 74 FROM tab1 AS cor0
----
-1924
-740
-962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2447
SELECT + col1 + CAST( + col1 AS SIGNED ) * + col1 - + col0 AS col2 FROM tab2
----
227
3462
985

skipif mysql # not compatible
query I rowsort label-2447
SELECT + col1 + CAST ( + col1 AS INTEGER ) * + col1 - + col0 AS col2 FROM tab2
----
227
3462
985

query I rowsort
SELECT ALL col1 * 40 * - 20 AS col0 FROM tab0 AS cor0
----
-68800
-72800
-77600

onlyif mysql # use DIV operator for integer division
query I rowsort label-2449
SELECT ALL cor0.col2 DIV col1 AS col2 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2449
SELECT ALL cor0.col2 / col1 AS col2 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT 23 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 cor2
----
81 values hashing to d3b0357ceadb3a70da7f1649b1ef2a30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2451
SELECT DISTINCT - col1 * + CAST( - 90 AS SIGNED ) FROM tab1 cor0
----
1170
2340
900

skipif mysql # not compatible
query I rowsort label-2451
SELECT DISTINCT - col1 * + CAST ( - 90 AS INTEGER ) FROM tab1 cor0
----
1170
2340
900

query I rowsort
SELECT DISTINCT + - col2 + + 46 AS col0 FROM tab0 AS cor0
----
-36
13
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2453
SELECT ALL - + col2 DIV + col0 col1 FROM tab0 cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2453
SELECT ALL - + col2 / + col0 col1 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT + col0 + + 71 * - 74 AS col2 FROM tab2 cor0
----
-5175
-5176
-5247

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 * cor0.col0 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-2456
SELECT DISTINCT col1 + + col1 DIV - col2 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2456
SELECT DISTINCT col1 + + col1 / - col2 AS col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2457
SELECT - col0 + CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-2457
SELECT - col0 + CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL col2 * col0 * + cor0.col2 - col2 AS col2 FROM tab0 AS cor0
----
26103
34
598354

query I rowsort
SELECT col0 + - 85 * col2 * + col0 AS col0 FROM tab2 AS cor0
----
-16058
-172302
-255091

query I rowsort
SELECT - cor0.col2 + col1 + - col2 * cor0.col0 * + col2 AS col1 FROM tab1 AS cor0
----
-207983
-737363
-8776

query I rowsort
SELECT 81 FROM tab0, tab0 cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ALL + - 47 * 67 * + col0 AS col0 FROM tab0 cor0
----
-110215
-280261
-75576

query I rowsort
SELECT ALL + col0 * - 42 * col1 FROM tab2 AS cor0
----
-193284
-56406
-9114

onlyif mysql # use DIV operator for integer division
query I rowsort label-2464
SELECT - + 0 DIV ( + cor0.col1 ) + ( - col2 * col0 ) + + ( 13 ) * col0 DIV col2 FROM tab0 AS cor0
----
-7284
-783
420

skipif mysql # not compatible
query I rowsort label-2464
SELECT - + 0 / ( + cor0.col1 ) + ( - col2 * col0 ) + + ( 13 ) * col0 / col2 FROM tab0 AS cor0
----
-7284
-783
420

query I rowsort
SELECT DISTINCT - + ( + 39 ) AS col2 FROM tab2 AS cor0
----
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-2466
SELECT ( col0 ) + col2 + col2 DIV 49 FROM tab1 AS cor0
----
122
177
58

skipif mysql # not compatible
query I rowsort label-2466
SELECT ( col0 ) + col2 + col2 / 49 FROM tab1 AS cor0
----
122
177
58

query I rowsort
SELECT DISTINCT + col2 * - 94 FROM tab0 cor0
----
-3102
-7708
-94

query I rowsort
SELECT col1 * cor0.col0 + - col2 * col2 FROM tab2 AS cor0
----
-101
-512
3926

query I rowsort
SELECT ALL - + col0 * col1 + - 62 AS col2 FROM tab2 AS cor0
----
-1405
-279
-4664

query I rowsort
SELECT ALL col0 * col1 + - col0 * col0 AS col0 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT DISTINCT + - col0 * + cor0.col1 + + 20 - col0 AS col1 FROM tab0 AS cor0
----
-2068
-3410
-8168

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 * ( 64 ) FROM tab2 AS cor0
----
1009
1977
3698

query I rowsort
SELECT 53 * col1 FROM tab2 cor0
----
1643
3127
901

query I rowsort
SELECT DISTINCT + - ( - col0 ) * 45 FROM tab0 AS cor0
----
1080
1575
4005

query I rowsort
SELECT - col2 * col1 + col2 AS col1 FROM tab2
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col0 * + col1 col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - cor0.col2 * - ( + 70 * col1 ) FROM tab0 cor0
----
198660
522340
6790

query I rowsort
SELECT + - 72 AS col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT ALL - + cor0.col0 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT - ( - col0 ) * tab2.col1 + + col2 * col1 FROM tab2
----
1054
1989
6136

query I rowsort
SELECT DISTINCT 23 + col2 * - col0 AS col1 FROM tab1
----
-139
-3625
-7657

onlyif mysql # use DIV operator for integer division
query I rowsort label-2482
SELECT ALL + 1 DIV - col2 + 62 * + col2 FROM tab1
----
3348
3534
5952

skipif mysql # not compatible
query I rowsort label-2482
SELECT ALL + 1 / - col2 + 62 * + col2 FROM tab1
----
3348
3534
5952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + - col1 col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + + ( - col2 ) * + ( col0 + cor0.col1 ) FROM tab2 AS cor0
----
-1026
-3562
-3648

query I rowsort
SELECT ALL col1 * - cor0.col2 + + col2 * + 8 AS col0 FROM tab1 AS cor0
----
-114
-480
-972

query I rowsort
SELECT 27 * + col0 + 13 * col0 AS col1 FROM tab0 AS cor0
----
1400
3560
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-2487
SELECT + ( col2 ) * 9 DIV ( col1 + ( 17 ) ) AS col0 FROM tab1 cor0
----
11
19
28

skipif mysql # not compatible
query I rowsort label-2487
SELECT + ( col2 ) * 9 / ( col1 + ( 17 ) ) AS col0 FROM tab1 cor0
----
11
19
28

query I rowsort
SELECT ALL - 80 + - col1 AS col0 FROM tab0 AS cor0
----
-166
-171
-177

onlyif mysql # use DIV operator for integer division
query I rowsort label-2489
SELECT DISTINCT - - col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2489
SELECT DISTINCT - - col0 / + col0 AS col0 FROM tab2 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2490
SELECT ALL - col2 * + col1 * CAST( - col2 * - col0 AS SIGNED ) + - col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-158410
-1940635
-3115554

skipif mysql # not compatible
query I rowsort label-2490
SELECT ALL - col2 * + col1 * CAST ( - col2 * - col0 AS INTEGER ) + - col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-158410
-1940635
-3115554

query I rowsort
SELECT ALL - + 10 + col2 * - col1 FROM tab1 AS cor0
----
-1258
-1414
-580

query I rowsort
SELECT DISTINCT + 83 * - col1 AS col0 FROM tab1 AS cor0
----
-1079
-2158
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - cor0.col1 ) col2 FROM tab1, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT ALL + col1 * - col0 + 20 AS col1 FROM tab0
----
-2044
-3375
-8079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col1 col1 FROM tab2, tab0 AS cor0, tab1, tab0 AS cor1
----
-86
-91
-97

query I rowsort
SELECT ALL + col2 * 16 FROM tab0 AS cor0
----
1312
16
528

onlyif mysql # use DIV operator for integer division
query I rowsort label-2497
SELECT DISTINCT - col2 + + cor0.col1 + + col1 * 5 DIV + cor0.col0 FROM tab1 AS cor0
----
-47
-83
15

skipif mysql # not compatible
query I rowsort label-2497
SELECT DISTINCT - col2 + + cor0.col1 + + col1 * 5 / + cor0.col0 FROM tab1 AS cor0
----
-47
-83
15

query I rowsort
SELECT ALL - 33 * + col2 AS col0 FROM tab1 AS cor0
----
-1782
-1881
-3168

query I rowsort
SELECT ALL 26 * col0 AS col0 FROM tab0 cor0
----
2314
624
910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 col2 FROM tab2, tab1 AS cor0
----
80

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 cor1, tab0 AS cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT - 41 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 47b9ef972839428f4f71d9f5b0944edf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 74 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

onlyif mysql # use DIV operator for integer division
query I rowsort label-2504
SELECT ALL ( - 60 ) DIV + col2 + - 15 AS col2 FROM tab1
----
-15
-16
-16

skipif mysql # not compatible
query I rowsort label-2504
SELECT ALL ( - 60 ) / + col2 + - 15 AS col2 FROM tab1
----
-15
-16
-16

onlyif mysql # use DIV operator for integer division
query I rowsort label-2505
SELECT - 57 * col2 DIV - 68 AS col2 FROM tab2 AS cor0
----
21
22
31

skipif mysql # not compatible
query I rowsort label-2505
SELECT - 57 * col2 / - 68 AS col2 FROM tab2 AS cor0
----
21
22
31

query I rowsort
SELECT ALL ( + ( col2 ) ) + 75 FROM tab0
----
108
157
76

query I rowsort
SELECT - 0 * cor0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT 65 + col1 FROM tab0 AS cor0
----
151
156
162

query I rowsort
SELECT + - 79 * col2 AS col0 FROM tab1 AS cor0
----
-4266
-4503
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-2510
SELECT DISTINCT + col1 * - col1 + 12 DIV 87 AS col2 FROM tab2 cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-2510
SELECT DISTINCT + col1 * - col1 + 12 / 87 AS col2 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + cor1.col0 AS col0 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2512
SELECT ( col2 ) / CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2512
SELECT ( col2 ) / CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2513
SELECT ( col2 + ( tab0.col2 ) ) DIV col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2513
SELECT ( col2 + ( tab0.col2 ) ) / col0 FROM tab0
----
0
1
2

query I rowsort
SELECT ( tab0.col2 ) * + ( 28 ) AS col2 FROM tab0
----
2296
28
924

query I rowsort
SELECT + 47 AS col1 FROM tab1
----
47
47
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-2516
SELECT cor0.col1 * - cor0.col0 + + cor0.col1 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-2516
SELECT cor0.col1 * - cor0.col0 + + cor0.col1 / cor0.col1 AS col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

query I rowsort
SELECT - - cor0.col1 * - col1 * ( + col1 * - col0 ) FROM tab1 AS cor0
----
175760
52728
64000

query I rowsort
SELECT ( col1 ) + - ( - col1 ) * col0 AS col0 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + cor0.col2 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - cor1.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT - - 19 * ( cor0.col0 ) + - 37 AS col1 FROM tab0 cor0
----
1654
419
628

query I rowsort
SELECT ALL - 5 * col0 AS col1 FROM tab0
----
-120
-175
-445

query I rowsort
SELECT - 53 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1481
593
784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * col0 + - ( col2 * + tab1.col0 ) col2 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT ALL + col2 * + col0 - - col0 * + cor0.col2 FROM tab0 cor0 WHERE NOT col0 * col1 NOT IN ( col1 * - col1 )
----

query I rowsort
SELECT ALL - col1 * + col2 * - col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT + col2 * - col0 + col2 * + tab2.col1 + col2 FROM tab2
----
-2318
-468
675

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col1 NOT IN ( col0 * col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - cor0.col0 * col1 AS col2 FROM tab0 AS cor0 WHERE NOT + col1 <> - col0
----

query I rowsort
SELECT + col2 * col2 + + tab2.col2 * col2 AS col1 FROM tab2
----
1352
1458
2888

query I rowsort
SELECT ALL tab0.col1 - tab0.col2 AS col0 FROM tab0
----
53
9
96

query III rowsort
SELECT * FROM tab0 WHERE col2 NOT IN ( col1 * + tab0.col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2533
SELECT - col1 * - col0 + col2 DIV - tab0.col2 FROM tab0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-2533
SELECT - col1 * - col0 + col2 / - tab0.col2 FROM tab0
----
2063
3394
8098

query III rowsort
SELECT ALL * FROM tab1 WHERE col1 NOT IN ( col1 )
----

query I rowsort
SELECT tab2.col0 FROM tab2 WHERE NOT ( - col1 * + col0 ) IN ( col1 )
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col1 col0 FROM tab0 WHERE NOT NULL NOT IN ( + col0 )
----

query I rowsort
SELECT DISTINCT col1 * tab2.col0 + + col0 - + col1 AS col0 FROM tab2 WHERE NULL <> NULL
----

query I rowsort
SELECT ALL - col0 * col1 + col2 * col1 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT DISTINCT - col1 * - col1 - col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT DISTINCT col1 AS col0 FROM tab1 WHERE NULL > NULL
----

query I rowsort
SELECT + col0 + + col2 + col1 FROM tab0
----
133
143
262

query I rowsort
SELECT - tab1.col0 - col2 * + col1 AS col0 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + - col2 * cor0.col1 + cor0.col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - col1 - - cor0.col2 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT + col0 * col1 * + cor0.col2 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT col1 * col0 + + col1 - - col1 * + col2 AS col2 FROM tab0 AS cor0
----
15652
3589
4988

onlyif mysql # use DIV operator for integer division
query I rowsort label-2547
SELECT DISTINCT + col2 DIV col1 AS col1 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-2547
SELECT DISTINCT + col2 / col1 AS col1 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1, tab2, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col2 * tab1.col2 AS col1 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - col2 + col2 AS col1 FROM tab1 WHERE col0 < ( NULL )
----

query I rowsort
SELECT tab2.col0 FROM tab0 AS cor0 CROSS JOIN tab2
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL - + 28 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to eac00a95d734c7071360ed392c3f39bc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2553
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2553
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + + col1 + - col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col2 - 50 FROM tab0 AS cor0
----
-17
-49
32

query I rowsort
SELECT + + col1 + - 97 * 46 FROM tab2 cor0
----
-4403
-4431
-4445

query I rowsort
SELECT + col1 * + tab1.col0 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT 17 + cor0.col1 FROM tab2 AS cor0
----
34
48
76

query I rowsort
SELECT ALL + 89 * + col2 FROM tab0 AS cor0
----
2937
7298
89

query I rowsort
SELECT DISTINCT + cor0.col0 * - col1 - 23 * col0 AS col1 FROM tab1 AS cor0
----
-147
-2112
-2880

query I rowsort
SELECT col2 + - col2 * + col1 AS col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL 15 * - col1 + - col0 * 18 AS col1 FROM tab0
----
-1722
-2085
-2967

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 * col0 col2 FROM tab0
----
1190
552
7832

query I rowsort
SELECT - col0 + - ( ( col0 ) ) FROM tab0
----
-178
-48
-70

query I rowsort
SELECT + - col1 * ( - 99 ) FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT DISTINCT col0 * - tab1.col2 AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col2 - 61 FROM tab0 AS cor0
----
-28
-60
21

query I rowsort
SELECT ALL - col0 + cor0.col2 * + col2 * col0 AS col0 FROM tab1 AS cor0
----
207872
737200
8745

onlyif mysql # use DIV operator for integer division
query I rowsort label-2569
SELECT + col0 DIV 26 FROM tab2 AS cor0
----
0
3
3

skipif mysql # not compatible
query I rowsort label-2569
SELECT + col0 / 26 FROM tab2 AS cor0
----
0
3
3

query I rowsort
SELECT ALL + col0 * ( - col0 * col2 ) AS col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - cor0.col1 + + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT + col1 + + col1 * col0 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - col1 * + 13 * + col1 FROM tab0 AS cor0
----
-107653
-122317
-96148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col0 - col2 col0 FROM tab0
----
-63
-84
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2576
SELECT - col2 DIV col2 - - tab1.col2 * + col1 AS col2 FROM tab1
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-2576
SELECT - col2 / col2 - - tab1.col2 * + col1 AS col2 FROM tab1
----
1247
1403
569

query I rowsort
SELECT ALL + col1 + col0 - col1 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT + col1 * + col1 * - col2 AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL col0 * + col0 + + col0 * + col1 + col1 FROM tab2
----
10745
297
7601

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL = ( + col1 )
----

query I rowsort
SELECT ALL - col1 * col0 + col1 + col0 AS col1 FROM tab1
----
-49
-566
-947

onlyif mysql # use DIV operator for integer division
query I rowsort label-2582
SELECT + col1 * col1 DIV - col1 AS col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-2582
SELECT + col1 * col1 / - col1 AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL + col1 * col1 * col0 AS col1 FROM tab1
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-2584
SELECT + col2 DIV col1 + - col2 AS col1 FROM tab2
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-2584
SELECT + col2 / col1 + - col2 AS col1 FROM tab2
----
-26
-27
-36

query I rowsort
SELECT DISTINCT tab2.col2 + - tab2.col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT col1 * - col2 + + col1 AS col2 FROM tab2
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * tab0.col0 * col1 + col1 col1 FROM tab0 WHERE NULL IN ( tab0.col1 )
----

query I rowsort
SELECT ALL - col2 * - col1 * + col1 + - col1 * - col0 AS col1 FROM tab0
----
12804
246132
687141

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL IN ( - tab2.col2 * col1 )
----

query I rowsort
SELECT DISTINCT - - 52 AS col2 FROM tab1 AS cor0
----
52

query I rowsort
SELECT 64 + - col2 FROM tab0 cor0
----
-18
31
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2592
SELECT ALL col1 DIV col2 + + col1 * tab1.col2 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2592
SELECT ALL col1 / col2 + + col1 * tab1.col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col0 AS col2 FROM tab0 WHERE NOT ( col2 / - col1 + - col1 ) NOT BETWEEN - col1 + + col1 AND NULL
----

query I rowsort
SELECT DISTINCT col2 + + col0 + tab1.col0 AS col0 FROM tab1
----
185
256
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-2595
SELECT col2 DIV - col0 + + col1 FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-2595
SELECT col2 / - col0 + + col1 FROM tab1 AS cor0
----
10
12
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + ( + tab1.col0 ) + col0 col2 FROM tab1
----
-48
64
71

query I rowsort
SELECT + tab1.col0 * 22 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 17e006acb77603357388efe2c1f6557d

onlyif mysql # use DIV operator for integer division
query I rowsort label-2598
SELECT ALL - col0 DIV ( - col2 * cor0.col2 + + cor0.col0 ) col1 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2598
SELECT ALL - col0 / ( - col2 * cor0.col2 + + cor0.col0 ) col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + - col1 + ( col2 ) AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col2 + - 44 AS col2 FROM tab1 AS cor0
----
-101
-140
-98

query I rowsort
SELECT DISTINCT col2 * 36 + col1 + - col0 FROM tab2 AS cor0
----
1306
917
996

onlyif mysql # use DIV operator for integer division
query I rowsort label-2602
SELECT ALL - col2 + cor0.col1 * col0 DIV + col0 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-2602
SELECT ALL - col2 + cor0.col1 * col0 / + col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 + col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - col2 + col0 * + 56 FROM tab0 AS cor0
----
1311
1959
4902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + cor0.col1 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + + col1 + + ( col2 ) FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2607
SELECT - col0 * ( + col1 + col1 ) DIV - CAST( col0 AS SIGNED ) FROM tab2
----
118
34
62

skipif mysql # not compatible
query I rowsort label-2607
SELECT - col0 * ( + col1 + col1 ) / - CAST ( col0 AS INTEGER ) FROM tab2
----
118
34
62

query I rowsort
SELECT + 65 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT DISTINCT col0 + - col1 + col2 FROM tab2
----
100
3
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2610
SELECT - CAST( NULL AS SIGNED ) + col1 + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2610
SELECT - CAST ( NULL AS INTEGER ) + col1 + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2611
SELECT - - CAST( NULL AS DECIMAL ) * 13 + - col0 + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2611
SELECT - - CAST ( NULL AS REAL ) * 13 + - col0 + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( + col1 ) + + ( - 68 ) AS col2 FROM tab2 AS cor0
----
-127
-85
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2613
SELECT ALL + - col2 DIV col1 + col2 + col0 AS col1 FROM tab1 AS cor0
----
116
169
55

skipif mysql # not compatible
query I rowsort label-2613
SELECT ALL + - col2 / col1 + col2 + col0 AS col1 FROM tab1 AS cor0
----
116
169
55

query I rowsort
SELECT - + col2 * col0 + 85 FROM tab2 AS cor0
----
-104
-1943
-2917

query I rowsort
SELECT DISTINCT - col1 * col2 + - col2 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT - 75 * - col2 FROM tab1 AS cor0
----
4050
4275
7200

query I rowsort
SELECT ALL + tab0.col2 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT cor0.col1 + col0 + ( cor0.col2 ) FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) + col0 + col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL - 95 * cor0.col1 - + cor0.col2 * + 61 FROM tab1 AS cor0
----
-4427
-5764
-7091

query I rowsort
SELECT 18 - - col2 AS col0 FROM tab1
----
114
72
75

query I rowsort
SELECT + + col1 * 54 AS col1 FROM tab1 cor0
----
1404
540
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-2623
SELECT - cor0.col2 * col2 DIV 53 AS col1 FROM tab1 cor0
----
-173
-55
-61

skipif mysql # not compatible
query I rowsort label-2623
SELECT - cor0.col2 * col2 / 53 AS col1 FROM tab1 cor0
----
-173
-55
-61

query I rowsort
SELECT + 85 + - tab2.col2 * - 77 FROM tab2
----
2087
2164
3011

query I rowsort
SELECT col2 * col1 + + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT - 67 * cor0.col2 + - cor0.col2 AS col0 FROM tab1, tab2 AS cor0, tab0 cor1, tab2, tab2 AS cor2
----
243 values hashing to 39a67b0dbd85428f4fdbb7e73db6c369

query I rowsort
SELECT + - 1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 96 + 99 col0 FROM tab2, tab1 cor0
----
195

query I rowsort
SELECT ALL + ( + tab2.col2 * - col0 ) AS col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + - ( ( col1 ) ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - 60 + + 63 * + cor0.col1 AS col0 FROM tab0 cor0
----
5358
5673
6051

query I rowsort
SELECT ALL + cor0.col0 * - ( + col0 * - 84 ) AS col2 FROM tab1 AS cor0
----
344064
537600
756

query I rowsort
SELECT - tab2.col1 + + tab2.col1 * + col2 AS col1 FROM tab2
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2634
SELECT ALL + col0 * - col2 DIV + tab0.col2 + ( col0 ) col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2634
SELECT ALL + col0 * - col2 / + tab0.col2 + ( col0 ) col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL 26 * - 24 + col2 + - col2 AS col1 FROM tab2
----
-624
-624
-624

query I rowsort
SELECT DISTINCT + tab2.col1 * + 78 AS col0 FROM tab2, tab1 cor0, tab1 AS cor1
----
1326
2418
4602

query I rowsort
SELECT tab0.col0 * - col0 * tab0.col0 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT ( - 85 ) * col0 AS col1 FROM tab1
----
-255
-5440
-6800

onlyif mysql # use DIV operator for integer division
query I rowsort label-2639
SELECT col2 * col1 DIV - col0 FROM tab2
----
-119
-19
-8

skipif mysql # not compatible
query I rowsort label-2639
SELECT col2 * col1 / - col0 FROM tab2
----
-119
-19
-8

query I rowsort
SELECT - + col2 * col1 + col2 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT + 38 * col0 + 34 FROM tab1 AS cor0
----
148
2466
3074

query I rowsort
SELECT + 41 + + col2 AS col0 FROM tab0 cor0
----
123
42
74

query I rowsort
SELECT ALL + ( - cor0.col2 ) AS col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 36 * - col2 col2 FROM tab2 cor0
----
-1368
-936
-972

query I rowsort
SELECT - col1 * + col1 * + col2 + cor0.col2 FROM tab2 AS cor0
----
-10944
-25920
-90480

query I rowsort
SELECT + col1 - 35 FROM tab2
----
-18
-4
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2647
SELECT CAST( NULL AS SIGNED ) + 50 col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2647
SELECT CAST ( NULL AS INTEGER ) + 50 col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 89 * 75 FROM tab0
----
6675

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab1 cor1, tab1, tab0 AS cor2
----
3645 values hashing to 0cc433e09ad9e61562b7840dd1db6f57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 - col0 * col1 col1 FROM tab1
----
-576
-75
-960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2652
SELECT ALL - + CAST( + 5 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-5
-5
-5

skipif mysql # not compatible
query I rowsort label-2652
SELECT ALL - + CAST ( + 5 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-5
-5
-5

query I rowsort
SELECT ALL cor1.col0 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT col0 * col2 + - col2 * ( - col2 ) * + col1 FROM tab1 AS cor0
----
127488
36138
75978

query I rowsort
SELECT 92 * + col1 AS col1 FROM tab2 AS cor0
----
1564
2852
5428

query I rowsort
SELECT + cor0.col0 + col0 * + ( + col1 + col0 ) FROM tab0 cor0
----
16109
2664
4655

query I rowsort
SELECT + 97 * - col2 FROM tab1 cor0
----
-5238
-5529
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2658
SELECT ALL - 64 + - col2 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2658
SELECT ALL - 64 + - col2 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2659
SELECT DISTINCT + col0 + col0 / + CAST( NULL AS SIGNED ) col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2659
SELECT DISTINCT + col0 + col0 / + CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT 91 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT + + 58 * + col2 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT DISTINCT + 7 * - col0 FROM tab1 AS cor0
----
-21
-448
-560

query I rowsort
SELECT 72 * + col0 AS col1 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT col2 * + cor0.col0 + 54 AS col2 FROM tab1 AS cor0
----
216
3702
7734

onlyif mysql # use DIV operator for integer division
query I rowsort label-2665
SELECT - - col0 DIV - col2 + + col1 AS col0 FROM tab0 AS cor0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-2665
SELECT - - col0 / - col2 + + col1 AS col0 FROM tab0 AS cor0
----
62
86
90

query I rowsort
SELECT cor0.col2 * 76 FROM tab1 AS cor0
----
4104
4332
7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2667
SELECT - + col1 * - col1 + col2 DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
100
168
658

skipif mysql # not compatible
query I rowsort label-2667
SELECT - + col1 * - col1 + col2 / - cor0.col0 AS col0 FROM tab1 AS cor0
----
100
168
658

query I rowsort
SELECT DISTINCT - 95 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-95

query I rowsort
SELECT col2 * - ( + col2 ) + + col2 FROM tab0 AS cor0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2670
SELECT ALL + + col1 DIV col1 - - cor0.col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-2670
SELECT ALL + + col1 / col1 - - cor0.col2 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT + + col2 * - col1 + - col1 AS col0 FROM tab0 cor0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-2672
SELECT ALL + - cor0.col2 + - ( + cor0.col0 + + col2 ) DIV col2 FROM tab1 cor0
----
-55
-59
-97

skipif mysql # not compatible
query I rowsort label-2672
SELECT ALL + - cor0.col2 + - ( + cor0.col0 + + col2 ) / col2 FROM tab1 cor0
----
-55
-59
-97

query I rowsort
SELECT DISTINCT + 53 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
53

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - cor0.col1 ) + - col1 col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT col2 + + col0 + - col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col2 - + col2 * tab1.col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL col2 + 66 AS col1 FROM tab0 AS cor0
----
148
67
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + - ( + col0 ) * - cor0.col2 col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - col0 - ( - col2 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - ( - col2 ) + + col0 * col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + 55 + - col0 + col0 FROM tab2 AS cor0
----
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-2684
SELECT DISTINCT + col1 * + cor0.col1 * col1 - - col0 DIV - 62 FROM tab0 AS cor0
----
636056
753570
912673

skipif mysql # not compatible
query I rowsort label-2684
SELECT DISTINCT + col1 * + cor0.col1 * col1 - - col0 / - 62 FROM tab0 AS cor0
----
636056
753570
912673

query I rowsort
SELECT + + 97 + + col0 FROM tab2 AS cor0
----
104
175
176

query I rowsort
SELECT ALL - ( + 36 ) + col2 FROM tab0 AS cor0
----
-3
-35
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + cor0.col2 + + col1 * - col0 * + cor0.col2 col0 FROM tab2 AS cor0
----
-119685
-51013
-5863

query I rowsort
SELECT DISTINCT 15 + + col0 AS col2 FROM tab2 AS cor0
----
22
93
94

query I rowsort
SELECT - cor0.col1 * 74 AS col1 FROM tab0 AS cor0
----
-6364
-6734
-7178

query I rowsort
SELECT ALL + col1 * + col1 + - col1 * 54 + + col0 AS col0 FROM tab0 AS cor0
----
2776
3456
4206

onlyif mysql # use DIV operator for integer division
query I rowsort label-2691
SELECT ALL + 91 * - cor0.col1 - col0 DIV col0 FROM tab0 AS cor0
----
-7827
-8282
-8828

skipif mysql # not compatible
query I rowsort label-2691
SELECT ALL + 91 * - cor0.col1 - col0 / col0 FROM tab0 AS cor0
----
-7827
-8282
-8828

query I rowsort
SELECT - 10 + col2 FROM tab0 AS cor0
----
-9
23
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2693
SELECT ALL - CAST( NULL AS DECIMAL ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2693
SELECT ALL - CAST ( NULL AS REAL ) + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + - 71 AS col0 FROM tab0
----
-38
-70
11

query I rowsort
SELECT ALL + tab0.col2 + col0 * + ( col2 ) * tab0.col0 AS col1 FROM tab0
----
1226
19041
649604

query I rowsort
SELECT DISTINCT col2 - 2 FROM tab1
----
52
55
94

query I rowsort
SELECT ALL col0 * col0 + 60 FROM tab0
----
1285
636
7981

query I rowsort
SELECT DISTINCT - 73 * - col1 + - col1 FROM tab2
----
1224
2232
4248

query I rowsort
SELECT 7 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col2 + + 74 + - col0 AS col1 FROM tab0 cor0
----
40
67
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2702
SELECT DISTINCT + - 89 + 57 DIV - cor0.col0 + col2 * + 97 FROM tab2 AS cor0
----
2433
2522
3597

skipif mysql # not compatible
query I rowsort label-2702
SELECT DISTINCT + - 89 + 57 / - cor0.col0 + col2 * + 97 FROM tab2 AS cor0
----
2433
2522
3597

query I rowsort
SELECT - - 75 + - col1 * - cor0.col1 * - col0 FROM tab0 AS cor0
----
-177429
-329240
-736934

query I rowsort
SELECT DISTINCT + - col2 + - col1 * - col0 AS col1 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT + 29 + col0 * col2 AS col0 FROM tab2 AS cor0
----
2057
218
3031

query I rowsort
SELECT - col2 * col0 + - col1 AS col1 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT - 73 + + ( + col2 ) FROM tab0 cor0
----
-40
-72
9

query I rowsort
SELECT - 83 * 29 + + col1 FROM tab1 AS cor0
----
-2381
-2394
-2397

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2709
SELECT DISTINCT col0 * + CAST( col2 AS SIGNED ) * col0 + col0 FROM tab0 AS cor0
----
1260
19032
649611

skipif mysql # not compatible
query I rowsort label-2709
SELECT DISTINCT col0 * + CAST ( col2 AS INTEGER ) * col0 + col0 FROM tab0 AS cor0
----
1260
19032
649611

query I rowsort
SELECT + - 97 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT + col2 + cor0.col1 * ( + col1 * col2 ) AS col1 FROM tab2 AS cor0
----
11020
25974
90532

query I rowsort
SELECT ALL - 7 * - col2 FROM tab2
----
182
189
266

query I rowsort
SELECT + col1 * col2 + col0 * 81 FROM tab2
----
1404
7045
7852

query I rowsort
SELECT ALL col0 * col0 * col0 + col1 FROM tab0
----
13910
42972
705060

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2715
SELECT col2 / - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2715
SELECT col2 / - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab2.col1 + col1 * + col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT col0 * - col1 * col2 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + col1 + col2 AS col1 FROM tab2 AS cor0
----
107
6169
6296

query I rowsort
SELECT col1 + - ( - ( col1 ) ) FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2720
SELECT DISTINCT - col0 * + CAST( + cor0.col0 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

skipif mysql # not compatible
query I rowsort label-2720
SELECT DISTINCT - col0 * + CAST ( + cor0.col0 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2721
SELECT DISTINCT - - col2 + cor0.col1 + 3 * col1 * CAST( col2 * + col1 + col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
276205
34939
80410

skipif mysql # not compatible
query I rowsort label-2721
SELECT DISTINCT - - col2 + cor0.col1 + 3 * col1 * CAST ( col2 * + col1 + col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
276205
34939
80410

query I rowsort
SELECT DISTINCT - - col1 * - col0 * - col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT + + col1 + + col0 * + col2 * col2 + - col2 FROM tab0 AS cor0
----
131
26189
598445

query I rowsort
SELECT DISTINCT + col1 * 14 AS col0 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT ALL - tab2.col2 * tab2.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 309d8ba6d1ea89e6795c82dda466e1ce

query I rowsort
SELECT DISTINCT 75 + tab1.col0 AS col2 FROM tab1, tab0 AS cor0
----
139
155
78

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2728
SELECT DISTINCT - 87 - - 47 DIV tab2.col1 col2 FROM tab2, tab1, tab1 cor0
----
-85
-86
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2728
SELECT DISTINCT - 87 - - 47 / tab2.col1 col2 FROM tab2, tab1, tab1 cor0
----
-85
-86
-87

query I rowsort
SELECT ALL col2 + - col2 * 29 + - 76 * - col2 FROM tab0 AS cor0
----
1584
3936
48

query I rowsort
SELECT - 60 + - col2 AS col1 FROM tab1 cor0
----
-114
-117
-156

query I rowsort
SELECT - 94 + + col0 * - col0 AS col0 FROM tab0 cor0
----
-1319
-670
-8015

query I rowsort
SELECT DISTINCT + 60 + - col1 + + col1 FROM tab2 AS cor0
----
60

query I rowsort
SELECT + col2 + tab1.col2 * + col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT col1 * 94 AS col2 FROM tab0
----
8084
8554
9118

query I rowsort
SELECT col1 + ( col0 ) AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col0 * 62 + + cor0.col1 - + col0 FROM tab0 AS cor0
----
1550
2232
5520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + ( col0 ) * col0 - col2 col0 FROM tab2 AS cor0
----
-9
5999
6186

query I rowsort
SELECT col0 + col1 * 16 AS col1 FROM tab0 AS cor0
----
1400
1545
1587

query I rowsort
SELECT + 50 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2740
SELECT DISTINCT + col1 + + col0 DIV col1 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2740
SELECT DISTINCT + col1 + + col0 / col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL col1 + 47 FROM tab2 AS cor0
----
106
64
78

query I rowsort
SELECT ALL - 7 - + ( cor0.col0 ) FROM tab1 cor0
----
-10
-71
-87

query I rowsort
SELECT ALL - 2 + col0 FROM tab2 AS cor0
----
5
76
77

query I rowsort
SELECT 5 + 40 * - col0 FROM tab0 cor0
----
-1395
-3555
-955

query I rowsort
SELECT - ( 64 ) FROM tab2
----
-64
-64
-64

query I rowsort
SELECT + 38 + - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1496
-608
-799

query I rowsort
SELECT 26 + col0 * col2 * + col0 AS col2 FROM tab0 AS cor0
----
1251
19034
649548

query I rowsort
SELECT ( - ( col2 ) ) + 25 * - 67 FROM tab1 AS cor0
----
-1729
-1732
-1771

query I rowsort
SELECT + + col1 * ( col1 ) AS col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-2750
SELECT - 83 + - col0 DIV + col2 AS col1 FROM tab0 AS cor0
----
-118
-83
-84

skipif mysql # not compatible
query I rowsort label-2750
SELECT - 83 + - col0 / + col2 AS col1 FROM tab0 AS cor0
----
-118
-83
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col2 col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + - 44 AS col0 FROM tab0 AS cor0
----
-44
-44
-44

query I rowsort
SELECT + + col2 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT ( col1 ) * - 11 FROM tab1 cor0
----
-110
-143
-286

query I rowsort
SELECT col2 * col0 + + cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT col2 * ( + col0 ) + col1 AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - col2 * - col2 + + col2 AS col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT ( 88 ) - - col0 FROM tab0 AS cor0
----
112
123
177

query I rowsort
SELECT + + col0 * cor0.col2 + - col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + cor0.col0 * 3 + + col1 FROM tab2 AS cor0
----
254
293
52

query I rowsort
SELECT ALL - 28 * - 37 * col1 FROM tab1 AS cor0
----
10360
13468
26936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + tab0.col1 col2 FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2763
SELECT col0 DIV + 29 AS col0 FROM tab2
----
0
2
2

skipif mysql # not compatible
query I rowsort label-2763
SELECT col0 / + 29 AS col0 FROM tab2
----
0
2
2

query I rowsort
SELECT ALL + cor0.col2 * + col2 + col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT 98 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

onlyif mysql # use DIV operator for integer division
query I rowsort label-2766
SELECT ( - 61 ) DIV cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f1310b55a8f0f5f4bfaa836db69ac1d1

skipif mysql # not compatible
query I rowsort label-2766
SELECT ( - 61 ) / cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f1310b55a8f0f5f4bfaa836db69ac1d1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2767
SELECT ALL cor0.col2 * - col2 + col0 + - col2 DIV ( col0 + col0 ) AS col2 FROM tab1 AS cor0
----
-2922
-3185
-9136

skipif mysql # not compatible
query I rowsort label-2767
SELECT ALL cor0.col2 * - col2 + col0 + - col2 / ( col0 + col0 ) AS col2 FROM tab1 AS cor0
----
-2922
-3185
-9136

query I rowsort
SELECT DISTINCT - 81 + tab1.col0 AS col2 FROM tab1
----
-1
-17
-78

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

onlyif mysql # use DIV operator for integer division
query I rowsort label-2770
SELECT - col0 - + col2 DIV + col2 FROM tab0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-2770
SELECT - col0 - + col2 / + col2 FROM tab0
----
-25
-36
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2771
SELECT ALL + - col2 DIV + 34 col1 FROM tab1 AS cor0
----
-1
-1
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2771
SELECT ALL + - col2 / + 34 col1 FROM tab1 AS cor0
----
-1
-1
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2772
SELECT DISTINCT - + col1 * CAST( 50 AS SIGNED ) FROM tab1 AS cor0
----
-1300
-500
-650

skipif mysql # not compatible
query I rowsort label-2772
SELECT DISTINCT - + col1 * CAST ( 50 AS INTEGER ) FROM tab1 AS cor0
----
-1300
-500
-650

query I rowsort
SELECT ALL - col2 * - 41 AS col0 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT - cor0.col1 * - col1 * 25 + - col2 FROM tab1 cor0
----
16846
2443
4129

query I rowsort
SELECT + col1 + 14 AS col0 FROM tab1 AS cor0
----
24
27
40

query I rowsort
SELECT DISTINCT col1 * 1 + - 62 FROM tab1 AS cor0
----
-36
-49
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2777
SELECT DISTINCT + col2 + CAST( NULL AS SIGNED ) * cor0.col0 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2777
SELECT DISTINCT + col2 + CAST ( NULL AS INTEGER ) * cor0.col0 col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2778
SELECT + col2 * CAST( - col1 AS SIGNED ) + col1 * - 44 col1 FROM tab0 AS cor0
----
-11466
-4365
-6622

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2778
SELECT + col2 * CAST ( - col1 AS INTEGER ) + col1 * - 44 col1 FROM tab0 AS cor0
----
-11466
-4365
-6622

query I rowsort
SELECT ALL col2 - ( - 67 + col2 ) AS col1 FROM tab0 AS cor0
----
67
67
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2780
SELECT - col0 + - CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2780
SELECT - col0 + - CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 70 - col0 AS col1 FROM tab0
----
-105
-159
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2782
SELECT CAST( NULL AS SIGNED ) * - col2 - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2782
SELECT CAST ( NULL AS INTEGER ) * - col2 - col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - ( col0 ) AS col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT 82 - col0 * - tab2.col2 FROM tab2
----
2110
271
3084

query I rowsort
SELECT + ( + 61 * col1 ) AS col0 FROM tab0
----
5246
5551
5917

query I rowsort
SELECT + ( col2 + col0 * col0 ) AS col2 FROM tab0
----
1226
609
8003

query I rowsort
SELECT + ( - 74 ) + + col0 FROM tab0
----
-39
-50
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-2788
SELECT col2 DIV col0 + tab1.col1 FROM tab1
----
10
14
44

skipif mysql # not compatible
query I rowsort label-2788
SELECT col2 / col0 + tab1.col1 FROM tab1
----
10
14
44

query I rowsort
SELECT ( ( col2 ) + - tab0.col1 ) AS col0 FROM tab0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2790
SELECT + - 42 DIV + col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-2790
SELECT + - 42 / + col1 FROM tab1 AS cor0
----
-1
-3
-4

query I rowsort
SELECT - + 40 - col1 AS col2 FROM tab2 AS cor0
----
-57
-71
-99

query I rowsort
SELECT DISTINCT + + 47 * col0 FROM tab1 cor0
----
141
3008
3760

query I rowsort
SELECT + col0 * + col2 + - col0 FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT - - col0 + - cor0.col0 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - col0 * col1 * 65 AS col0 FROM tab1 AS cor0
----
-41600
-5070
-67600

query I rowsort
SELECT cor0.col1 + + col2 * + 44 + cor0.col0 AS col2 FROM tab1 AS cor0
----
2405
2582
4317

query I rowsort
SELECT ( - col1 + col2 * tab2.col1 ) AS col1 FROM tab2
----
1475
629
806

query I rowsort
SELECT + + col1 + - cor0.col0 + cor0.col2 * + col0 FROM tab0 AS cor0
----
7300
854
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2799
SELECT DISTINCT + 20 + + col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2799
SELECT DISTINCT + 20 + + col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - ( - col1 ) * ( - col2 ) FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - cor0.col1 * cor0.col1 + 61 + - cor0.col1 FROM tab0 AS cor0
----
7371
8251
9373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + col0 * + col1 col2 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT ALL - col2 * col2 + - 58 AS col2 FROM tab2
----
-1502
-734
-787

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL cor0.col1 * cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to f2938bee011b8d49dd931b1f9235e7f5

query I rowsort
SELECT + + ( col2 ) * 9 * col0 FROM tab1 cor0
----
1458
32832
69120

query I rowsort
SELECT cor0.col0 + - col2 AS col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT - 10 + + 67 AS col2 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT + col0 * col0 + col0 - - col0 AS col0 FROM tab2 AS cor0
----
6240
63
6399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * 18 col0 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT - - col2 * cor0.col1 + cor0.col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + + col1 * + ( col1 ) AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - col1 * col2 * col0 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-2814
SELECT ALL col2 + - tab2.col2 DIV col0 FROM tab2
----
24
26
38

skipif mysql # not compatible
query I rowsort label-2814
SELECT ALL col2 + - tab2.col2 / col0 FROM tab2
----
24
26
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 + - tab1.col2 col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL + tab0.col1 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT col2 + - col0 * ( + ( + col1 ) ) + col2 * col0 FROM tab1
----
138
3065
6736

query I rowsort
SELECT + cor0.col0 * ( - col0 ) FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + col1 * col0 + - col1 AS col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2820
SELECT DISTINCT 68 DIV col0 FROM tab1 cor0
----
0
1
22

skipif mysql # not compatible
query I rowsort label-2820
SELECT DISTINCT 68 / col0 FROM tab1 cor0
----
0
1
22

query I rowsort
SELECT ALL + 37 + + col1 FROM tab0 AS cor0
----
123
128
134

query I rowsort
SELECT ALL + 35 + col1 FROM tab2 AS cor0
----
52
66
94

query I rowsort
SELECT + 53 + - col2 * + col0 FROM tab1 AS cor0
----
-109
-3595
-7627

query I rowsort
SELECT DISTINCT - 39 + + col0 * - col2 FROM tab1 cor0
----
-201
-3687
-7719

query I rowsort
SELECT DISTINCT 99 * 52 FROM tab1 AS cor0
----
5148

query I rowsort
SELECT ALL - col1 + col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ALL + 63 * 79 + col2 FROM tab2 AS cor0
----
5003
5004
5015

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2828
SELECT ALL col1 / - ( + col1 * + CAST( NULL AS SIGNED ) ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2828
SELECT ALL col1 / - ( + col1 * + CAST ( NULL AS INTEGER ) ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2829
SELECT col2 + cor0.col1 * col1 / ( - 9 * + cor0.col0 + CAST( NULL AS DECIMAL ) ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2829
SELECT col2 + cor0.col1 * col1 / ( - 9 * + cor0.col0 + CAST ( NULL AS REAL ) ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col0 + ( - col2 ) FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2831
SELECT - + CAST( - col1 AS SIGNED ) * + col2 + ( col0 ) col0 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2831
SELECT - + CAST ( - col1 AS INTEGER ) * + col2 + ( col0 ) col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL 58 + col0 AS col1 FROM tab2 AS cor0
----
136
137
65

query I rowsort
SELECT + tab0.col0 * - 55 * - tab0.col1 FROM tab0
----
113520
186725
445445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col1 + - 39 col0 FROM tab1
----
130
61
637

query I rowsort
SELECT 35 * + col1 AS col1 FROM tab0 AS cor0
----
3010
3185
3395

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2836
SELECT ALL + ( + 49 ) * - col0 + CAST( + col1 * col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-2288
-3225
494

skipif mysql # not compatible
query I rowsort label-2836
SELECT ALL + ( + 49 ) * - col0 + CAST ( + col1 * col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-2288
-3225
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-2837
SELECT ALL + col0 DIV + 13 AS col0 FROM tab0 AS cor0
----
1
2
6

skipif mysql # not compatible
query I rowsort label-2837
SELECT ALL + col0 / + 13 AS col0 FROM tab0 AS cor0
----
1
2
6

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + 16 * col0 + col1 FROM tab1 cor0
----
1034
1293
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * 84 col2 FROM tab1 AS cor0
----
252
5376
6720

onlyif mysql # use DIV operator for integer division
query I rowsort label-2841
SELECT - cor0.col2 + col1 DIV 15 FROM tab1 cor0
----
-53
-57
-96

skipif mysql # not compatible
query I rowsort label-2841
SELECT - cor0.col2 + col1 / 15 FROM tab1 cor0
----
-53
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2842
SELECT cor0.col1 * - cor0.col2 DIV + col2 + + col0 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-2842
SELECT cor0.col1 * - cor0.col2 / + col2 + + col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2843
SELECT ALL col0 + 48 DIV col1 + + col0 FROM tab1 AS cor0
----
132
163
7

skipif mysql # not compatible
query I rowsort label-2843
SELECT ALL col0 + 48 / col1 + + col0 FROM tab1 AS cor0
----
132
163
7

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 * CAST ( col2 * col2 AS REAL ) + - col2 FROM tab0 AS cor0
----
-611966
-93687
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 + ( col0 ) col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT 31 + + col1 AS col0 FROM tab1
----
41
44
57

query I rowsort
SELECT DISTINCT 31 AS col2 FROM tab0, tab1, tab1 cor0
----
31

query I rowsort
SELECT - 80 * + col2 FROM tab0
----
-2640
-6560
-80

query I rowsort
SELECT - + col0 * + col2 + ( col1 ) FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 64 col0 FROM tab2, tab0 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

onlyif mysql # use DIV operator for integer division
query I rowsort label-2851
SELECT + col2 DIV ( - col0 ) FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-2851
SELECT + col2 / ( - col0 ) FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT col2 * - ( 24 ) AS col2 FROM tab2 AS cor0
----
-624
-648
-912

query I rowsort
SELECT + col0 - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + + col0 * col0 AS col1 FROM tab1
----
35
4106
6413

query I rowsort
SELECT DISTINCT + col1 + - tab2.col1 + col1 AS col1 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 5 * + col0 col0 FROM tab0
----
120
175
445

query I rowsort
SELECT + ( - col2 ) * ( tab1.col1 ) * + col0 AS col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT tab1.col1 * tab1.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT - + col2 + cor0.col2 * 51 FROM tab0 AS cor0
----
1650
4100
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 44 * + col1 col2 FROM tab1 AS cor0
----
1144
440
572

query I rowsort
SELECT cor0.col0 * col2 + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - 46 * - col0 FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT col1 * - tab1.col1 * tab1.col1 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT + tab2.col2 - + col2 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2865
SELECT - col2 + col2 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-32
-82

skipif mysql # not compatible
query I rowsort label-2865
SELECT - col2 + col2 / col0 AS col1 FROM tab0 AS cor0
----
-1
-32
-82

query I rowsort
SELECT ALL tab0.col2 * col0 + + col2 FROM tab0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col1 col1 FROM tab2
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2868
SELECT + cor0.col2 + col2 DIV + col0 AS col2 FROM tab0 AS cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-2868
SELECT + cor0.col2 + col2 / + col0 AS col2 FROM tab0 AS cor0
----
1
34
82

query I rowsort
SELECT DISTINCT - col0 + + col1 * + col0 AS col2 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT + col2 * + col1 + - col0 FROM tab0 AS cor0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-2871
SELECT - + col2 - col2 DIV col0 FROM tab0 AS cor0
----
-1
-34
-82

skipif mysql # not compatible
query I rowsort label-2871
SELECT - + col2 - col2 / col0 FROM tab0 AS cor0
----
-1
-34
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2872
SELECT cor0.col2 + col0 DIV - col1 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-2872
SELECT cor0.col2 + col0 / - col1 FROM tab2 AS cor0
----
25
27
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2873
SELECT DISTINCT + col2 * col2 DIV col2 + + col0 DIV col2 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-2873
SELECT DISTINCT + col2 * col2 / col2 + + col0 / col2 FROM tab0 AS cor0
----
33
36
83

query I rowsort
SELECT + col2 + + cor0.col0 AS col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT - + cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2876
SELECT DISTINCT CAST( cor0.col0 AS SIGNED ) + col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-2876
SELECT DISTINCT CAST ( cor0.col0 AS INTEGER ) + col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2877
SELECT - - CAST( NULL AS SIGNED ) * + 65 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-2877
SELECT - - CAST ( NULL AS INTEGER ) * + 65 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( - cor0.col1 ) * + col1 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 - col0 col0 FROM tab1 AS cor0
----
18
34
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col0 * col1 col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - - col1 + - col1 * - col0 * - col2 AS col0 FROM tab0 AS cor0
----
-3298
-664027
-68026

onlyif mysql # use DIV operator for integer division
query I rowsort label-2882
SELECT + col0 * col2 DIV - col1 AS col0 FROM tab0 AS cor0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-2882
SELECT + col0 * col2 / - col1 AS col0 FROM tab0 AS cor0
----
-80
-9
0

query I rowsort
SELECT DISTINCT + 32 + 53 FROM tab1 AS cor0
----
85

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 5 AS REAL ) + col2 FROM tab1 AS cor0
----
49
52
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2885
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-2885
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT ALL - ( col2 ) + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - + 2 * cor0.col1 * + cor0.col2 + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1780
-2886
-3536

query I rowsort
SELECT ALL - col2 * + tab0.col0 * col0 - - tab0.col0 AS col0 FROM tab0
----
-1190
-18984
-649433

query I rowsort
SELECT ALL - - 32 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL ( col2 ) + tab1.col0 AS col1 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col2 + + col0 col0 FROM tab1
----
2919
3313
9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2892
SELECT DISTINCT + CAST( + 73 AS SIGNED ) AS col0 FROM tab0
----
73

skipif mysql # not compatible
query I rowsort label-2892
SELECT DISTINCT + CAST ( + 73 AS INTEGER ) AS col0 FROM tab0
----
73

query I rowsort
SELECT - ( + 3 ) * + col1 + col1 - col0 AS col1 FROM tab1
----
-106
-55
-84

query I rowsort
SELECT ALL - col2 * ( - tab0.col2 ) + tab0.col1 * col2 AS col0 FROM tab0
----
14186
3927
98

query I rowsort
SELECT ALL 31 + col2 * col1 AS col1 FROM tab2
----
1565
677
868

query I rowsort
SELECT ALL - 52 + col1 FROM tab2
----
-21
-35
7

query I rowsort
SELECT ALL cor0.col0 + + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2898
SELECT + col0 * tab0.col2 + - 36 DIV - col0 FROM tab0
----
36
7298
793

skipif mysql # not compatible
query I rowsort label-2898
SELECT + col0 * tab0.col2 + - 36 / - col0 FROM tab0
----
36
7298
793

query I rowsort
SELECT + cor0.col2 + tab1.col0 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 8bd72de8d7a75bcbd2619bca60945947

query I rowsort
SELECT DISTINCT 82 FROM tab1, tab2, tab2 cor0
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2901
SELECT + 38 DIV - col0 + + tab2.col1 * + col0 AS col1 FROM tab2
----
1343
212
4602

skipif mysql # not compatible
query I rowsort label-2901
SELECT + 38 / - col0 + + tab2.col1 * + col0 AS col1 FROM tab2
----
1343
212
4602

query I rowsort
SELECT + col2 + + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - - col1 * 30 * + col0 FROM tab2 AS cor0
----
138060
40290
6510

query I rowsort
SELECT DISTINCT - col1 * + 30 AS col0 FROM tab1 AS cor0
----
-300
-390
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2905
SELECT ALL - col1 + 39 DIV + col1 FROM tab1 AS cor0
----
-10
-25
-7

skipif mysql # not compatible
query I rowsort label-2905
SELECT ALL - col1 + 39 / + col1 FROM tab1 AS cor0
----
-10
-25
-7

query I rowsort
SELECT ALL + col0 * 22 + col0 - col0 * + 4 FROM tab2 AS cor0
----
133
1482
1501

query I rowsort
SELECT ALL - col2 * + 51 + - col2 + - cor0.col2 * 98 AS col1 FROM tab0 AS cor0
----
-12300
-150
-4950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2908
SELECT col2 * + CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-2908
SELECT col2 * + CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col1 * 44 + col2 FROM tab1 AS cor0
----
1198
497
668

query I rowsort
SELECT - + col2 * - 2 AS col1 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2911
SELECT - col1 + + CAST( - 77 AS SIGNED ) AS col1 FROM tab0
----
-163
-168
-174

skipif mysql # not compatible
query I rowsort label-2911
SELECT - col1 + + CAST ( - 77 AS INTEGER ) AS col1 FROM tab0
----
-163
-168
-174

query I rowsort
SELECT tab2.col2 - + 82 FROM tab2, tab2 AS cor0
----
9 values hashing to d0044f71dfef85c929b9152b9a0ffe57

query I rowsort
SELECT ALL - col0 * col1 * col1 AS col2 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT - col0 + - 13 * tab0.col2 FROM tab0
----
-1155
-453
-48

query I rowsort
SELECT + col1 + 96 AS col2 FROM tab2
----
113
127
155

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * 58 * + 69 col2 FROM tab2 AS cor0
----
-104052
-108054
-152076

query I rowsort
SELECT DISTINCT - - col2 + + col1 * + col0 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2918
SELECT DISTINCT + + col1 * - col1 - col1 DIV col0 AS col1 FROM tab0 AS cor0
----
-7399
-8282
-9411

skipif mysql # not compatible
query I rowsort label-2918
SELECT DISTINCT + + col1 * - col1 - col1 / col0 AS col1 FROM tab0 AS cor0
----
-7399
-8282
-9411

query I rowsort
SELECT ALL - - col2 - + 8 AS col2 FROM tab1 cor0
----
46
49
88

query I rowsort
SELECT + ( col0 ) * - col0 * col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - col0 - - 88 FROM tab2
----
10
81
9

query I rowsort
SELECT tab1.col1 + 76 FROM tab1
----
102
86
89

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( col2 AS REAL ) * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - 26 AS col0 FROM tab2 AS cor0
----
-26
-26
-26

query I rowsort
SELECT DISTINCT + + 65 FROM tab1 AS cor0
----
65

query I rowsort
SELECT ALL - + 60 AS col2 FROM tab2 AS cor0
----
-60
-60
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + col1 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 60 * col1 AS col0 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT ALL + - 38 * col1 AS col2 FROM tab2 AS cor0
----
-1178
-2242
-646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + tab2.col2 * + 55 col2 FROM tab2
----
-10395
-111540
-165110

onlyif mysql # use DIV operator for integer division
query I rowsort label-2931
SELECT ALL - 38 DIV col1 FROM tab2
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2931
SELECT ALL - 38 / col1 FROM tab2
----
-1
-2
0

query I rowsort
SELECT + 87 * col0 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT ALL col0 * - col1 * + col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT - 78 + + col0 * - cor0.col0 FROM tab2 AS cor0
----
-127
-6162
-6319

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2935
SELECT - col0 / col1 + - CAST( NULL AS SIGNED ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2935
SELECT - col0 / col1 + - CAST ( NULL AS INTEGER ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 71 * + col2 AS col0 FROM tab1 AS cor0
----
3834
4047
6816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2937
SELECT + 0 * + col1 DIV - ( - col2 ) + col0 + + 29 FROM tab1 AS cor0
----
109
32
93

skipif mysql # not compatible
query I rowsort label-2937
SELECT + 0 * + col1 / - ( - col2 ) + col0 + + 29 FROM tab1 AS cor0
----
109
32
93

query I rowsort
SELECT ALL col1 + col0 * ( - col0 ) FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT + + 85 FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT ALL - col2 * col1 + col1 * - cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
203845
28954
4267

onlyif mysql # use DIV operator for integer division
query I rowsort label-2941
SELECT ALL + col1 + + col1 + col0 DIV + col0 FROM tab1 AS cor0
----
21
27
53

skipif mysql # not compatible
query I rowsort label-2941
SELECT ALL + col1 + + col1 + col0 / + col0 FROM tab1 AS cor0
----
21
27
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col2 col2 FROM tab0 AS cor0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * - col2 col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - col1 + ( - col0 ) * col2 AS col2 FROM tab1 cor0
----
-188
-3658
-7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-2945
SELECT DISTINCT + col2 DIV col0 col1 FROM tab0 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2945
SELECT DISTINCT + col2 / col0 col1 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT - 18 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT ALL col2 * col0 + + 24 AS col2 FROM tab1
----
186
3672
7704

query I rowsort
SELECT DISTINCT col2 * - col0 * ( + col0 ) AS col1 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT + 37 * - col0 AS col2 FROM tab0
----
-1295
-3293
-888

query I rowsort
SELECT col0 + + cor0.col2 * 73 FROM tab2 cor0
----
1976
1978
2853

query I rowsort
SELECT col0 * + ( 90 ) AS col0 FROM tab0 cor0
----
2160
3150
8010

query I rowsort
SELECT + col0 * - 10 + ( col1 ) AS col2 FROM tab1 AS cor0
----
-4
-630
-787

query I rowsort
SELECT - col0 * - cor0.col1 * - cor0.col2 + + col1 AS col0 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT col1 + + 50 FROM tab1 AS cor0
----
60
63
76

query I rowsort
SELECT ALL 91 AS col1 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT + + 76 * cor0.col2 * + col2 AS col1 FROM tab0 AS cor0
----
511024
76
82764

query I rowsort
SELECT DISTINCT 51 + - col2 FROM tab2 AS cor0
----
13
24
25

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 37 AS REAL ) + + cor0.col1 * col2 * + ( cor0.col2 ) FROM tab2 AS cor0
----
22636
24585
39921

query I rowsort
SELECT - - cor0.col0 * + 81 AS col2 FROM tab0 AS cor0
----
1944
2835
7209

onlyif mysql # use DIV operator for integer division
query I rowsort label-2960
SELECT + col0 DIV col2 AS col0 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2960
SELECT + col0 / col2 AS col0 FROM tab0 cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 27 + + col1 col2 FROM tab2 AS cor0
----
-10
32
4

query I rowsort
SELECT + + 23 AS col1 FROM tab0 AS cor0
----
23
23
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2963
SELECT CAST( col0 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-2963
SELECT CAST ( col0 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 + - 98 AS col0 FROM tab0 AS cor0
----
-16
-65
-97

query I rowsort
SELECT 5 * 54 + col1 FROM tab2
----
287
301
329

query I rowsort
SELECT col0 * col1 + 7 * - col2 FROM tab0 AS cor0
----
1833
3388
7525

onlyif mysql # use DIV operator for integer division
query I rowsort label-2967
SELECT + CAST( + col1 AS SIGNED ) DIV + col0 col2 FROM tab1
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2967
SELECT + CAST ( + col1 AS INTEGER ) / + col0 col2 FROM tab1
----
0
0
8

query I rowsort
SELECT ALL + col0 * + col1 + - col0 AS col1 FROM tab0 cor0
----
2040
3360
8010

query I rowsort
SELECT ALL col2 * - col1 + ( col1 ) FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT - - col2 * + col2 * col0 AS col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT ALL + col1 * - ( - col1 ) AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL - 28 * - col1 FROM tab2 AS cor0
----
1652
476
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + cor0.col2 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + 32 + + cor0.col2 FROM tab1 cor0
----
128
86
89

query I rowsort
SELECT DISTINCT col1 + + col1 + col0 FROM tab0 cor0
----
196
229
271

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 86 * col2 col1 FROM tab2
----
2236
2322
3268

query I rowsort
SELECT DISTINCT tab1.col0 * - tab1.col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2978
SELECT ALL + col0 * col1 DIV - ( - 63 * tab0.col2 ) FROM tab0
----
0
1
53

skipif mysql # not compatible
query I rowsort label-2978
SELECT ALL + col0 * col1 / - ( - 63 * tab0.col2 ) FROM tab0
----
0
1
53

query I rowsort
SELECT - col2 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT 91 - 46 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT DISTINCT - 50 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-50

query I rowsort
SELECT ALL - + 58 * - 51 FROM tab1 AS cor0
----
2958
2958
2958

onlyif mysql # use DIV operator for integer division
query I rowsort label-2983
SELECT - tab0.col0 + 98 * tab0.col2 DIV col1 AS col0 FROM tab0
----
-1
-34
13

skipif mysql # not compatible
query I rowsort label-2983
SELECT - tab0.col0 + 98 * tab0.col2 / col1 AS col0 FROM tab0
----
-1
-34
13

query I rowsort
SELECT - - 31 + + 92 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 8b257741ae85b3094e99cd0033791abd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2985
SELECT DISTINCT CAST( 87 * - tab2.col2 AS SIGNED ) FROM tab2
----
-2262
-2349
-3306

skipif mysql # not compatible
query I rowsort label-2985
SELECT DISTINCT CAST ( 87 * - tab2.col2 AS INTEGER ) FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT + col1 + + 4 * col0 FROM tab2
----
333
371
59

query I rowsort
SELECT DISTINCT + ( - 49 ) FROM tab0
----
-49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2988
SELECT CAST( 70 AS SIGNED ) AS col2 FROM tab1
----
70
70
70

skipif mysql # not compatible
query I rowsort label-2988
SELECT CAST ( 70 AS INTEGER ) AS col2 FROM tab1
----
70
70
70

query I rowsort
SELECT ( col0 * col2 ) + 2 FROM tab2
----
191
2030
3004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col2 - + tab1.col2 col1 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT + col2 + + col2 * + col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT + + 93 AS col1 FROM tab2 AS cor0
----
93
93
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 9 col0 FROM tab1 AS cor0
----
9
9
9

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

onlyif mysql # use DIV operator for integer division
query I rowsort label-2995
SELECT col2 * ( cor0.col1 ) DIV + col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2995
SELECT col2 * ( cor0.col1 ) / + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col1 * 66 FROM tab0 AS cor0
----
5676
6006
6402

query I rowsort
SELECT ALL - col1 + + col2 * + col2 * cor0.col1 FROM tab2 AS cor0
----
22568
24531
39825

query I rowsort
SELECT ALL + col2 * 12 AS col0 FROM tab2 AS cor0
----
312
324
456

onlyif mysql # use DIV operator for integer division
query I rowsort label-2999
SELECT DISTINCT - col1 + col0 DIV + cor0.col0 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2999
SELECT DISTINCT - col1 + col0 / + cor0.col0 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT ALL - + ( - col0 ) + - col2 AS col1 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3001
SELECT DISTINCT + col1 + 77 DIV + col2 FROM tab1 AS cor0
----
11
13
27

skipif mysql # not compatible
query I rowsort label-3001
SELECT DISTINCT + col1 + 77 / + col2 FROM tab1 AS cor0
----
11
13
27

query I rowsort
SELECT DISTINCT + 4 + col2 * + col0 AS col0 FROM tab1 AS cor0
----
166
3652
7684

query I rowsort
SELECT - 78 + cor0.col2 FROM tab1 AS cor0
----
-21
-24
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3004
SELECT - col0 + cor0.col1 * - cor0.col2 * CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3004
SELECT - col0 + cor0.col1 * - cor0.col2 * CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3005
SELECT DISTINCT + + cor0.col1 * - 51 + - col1 DIV col2 AS col2 FROM tab1 AS cor0
----
-1326
-510
-663

skipif mysql # not compatible
query I rowsort label-3005
SELECT DISTINCT + + cor0.col1 * - 51 + - col1 / col2 AS col2 FROM tab1 AS cor0
----
-1326
-510
-663

query I rowsort
SELECT DISTINCT - col2 * - 97 FROM tab2 AS cor0
----
2522
2619
3686

query I rowsort
SELECT ALL - ( 57 ) + col2 + + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-110
-153
-66

query I rowsort
SELECT 22 * + col0 + - col2 FROM tab1 AS cor0
----
12
1351
1664

query I rowsort
SELECT - col1 * col1 + - 5 * + col0 * col0 AS col0 FROM tab1 AS cor0
----
-20580
-32169
-721

query I rowsort
SELECT + - col2 * + col2 + col0 + col1 FROM tab0 cor0
----
-6544
-979
131

query I rowsort
SELECT - ( 95 ) FROM tab1
----
-95
-95
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3012
SELECT DISTINCT + 69 * col0 + + CAST( - col0 * col1 AS SIGNED ) + ( col2 + + col1 ) DIV 19 AS col2 FROM tab2 AS cor0
----
269
4110
784

skipif mysql # not compatible
query I rowsort label-3012
SELECT DISTINCT + 69 * col0 + + CAST ( - col0 * col1 AS INTEGER ) + ( col2 + + col1 ) / 19 AS col2 FROM tab2 AS cor0
----
269
4110
784

query I rowsort
SELECT + cor0.col1 + - col0 * 95 * + col2 AS col1 FROM tab1 AS cor0
----
-15364
-346550
-729587

query I rowsort
SELECT ALL - 33 + - col0 FROM tab0 AS cor0
----
-122
-57
-68

query I rowsort
SELECT 6 * - col2 + + col0 AS col2 FROM tab2
----
-149
-155
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3016
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab1, tab0 cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3016
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab1, tab0 cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT ALL col2 * 13 FROM tab2 AS cor0
----
338
351
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - tab0.col1 col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3019
SELECT ALL - col1 DIV + tab1.col0 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-3019
SELECT ALL - col1 / + tab1.col0 FROM tab1
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3020
SELECT 28 + col1 DIV - 36 FROM tab2
----
27
28
28

skipif mysql # not compatible
query I rowsort label-3020
SELECT 28 + col1 / - 36 FROM tab2
----
27
28
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + cor0.col2 col0 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * ( col0 ) col1 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3023
SELECT ALL - 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-3023
SELECT ALL - col2 / - ( - col1 ) col0 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT 47 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 15 col2 FROM tab0
----
15

query I rowsort
SELECT cor0.col2 + tab1.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to b8b62762005dc0d7237145d0538edb34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3027
SELECT DISTINCT + + cor0.col2 DIV - 24 FROM tab2, tab1, tab0 AS cor0, tab0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-3027
SELECT DISTINCT + + cor0.col2 / - 24 FROM tab2, tab1, tab0 AS cor0, tab0
----
-1
-3
0

query I rowsort
SELECT - col1 * + 66 + col0 FROM tab1
----
-1713
-596
-778

query I rowsort
SELECT DISTINCT col2 * - ( col2 + col1 ) * + col1 AS col2 FROM tab1
----
-112320
-136032
-38190

query I rowsort
SELECT DISTINCT + col2 + - col2 AS col0 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL + col1 * 5 + + 25 FROM tab2 AS cor0
----
110
180
320

query I rowsort
SELECT DISTINCT col2 * col2 * - col0 + - col1 AS col0 FROM tab0
----
-132
-26222
-598527

onlyif mysql # use DIV operator for integer division
query I rowsort label-3033
SELECT DISTINCT col1 * col2 + col0 DIV col2 AS col0 FROM tab1
----
1248
1404
571

skipif mysql # not compatible
query I rowsort label-3033
SELECT DISTINCT col1 * col2 + col0 / col2 AS col0 FROM tab1
----
1248
1404
571

query I rowsort
SELECT + 57 * - col1 + col0 FROM tab1
----
-1479
-506
-661

query I rowsort
SELECT - 98 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT 95 + cor0.col0 * + 92 FROM tab1, tab0 cor0
----
9 values hashing to 307c026b2d0ec24c2eb0ad7b1211b986

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3037
SELECT DISTINCT CAST( NULL AS SIGNED ) + - col0 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3037
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - col0 AS col1 FROM tab1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3038
SELECT ALL - + col0 + - col0 + + CAST( 70 AS SIGNED ) * - col2 FROM tab0 AS cor0
----
-140
-2358
-5918

skipif mysql # not compatible
query I rowsort label-3038
SELECT ALL - + col0 + - col0 + + CAST ( 70 AS INTEGER ) * - col2 FROM tab0 AS cor0
----
-140
-2358
-5918

query I rowsort
SELECT 6 + cor0.col2 FROM tab2 cor0
----
32
33
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-3040
SELECT ALL col1 DIV - col2 + ( ( col1 ) ) * ( 64 ) FROM tab1 AS cor0
----
1664
640
832

skipif mysql # not compatible
query I rowsort label-3040
SELECT ALL col1 / - col2 + ( ( col1 ) ) * ( 64 ) FROM tab1 AS cor0
----
1664
640
832

query I rowsort
SELECT DISTINCT - - 89 - + col0 AS col1 FROM tab2 AS cor0
----
10
11
82

query I rowsort
SELECT ALL - 78 AS col2 FROM tab2 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3043
SELECT - col1 DIV + cor0.col0 + ( col1 ) AS col2 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-3043
SELECT - col1 / + cor0.col0 + ( col1 ) AS col2 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT ALL - col2 * + col0 * + col2 + - col1 FROM tab0 AS cor0
----
-132
-26222
-598527

query I rowsort
SELECT + 60 * + col2 + 61 + + col0 FROM tab1 cor0
----
3304
3545
5901

query I rowsort
SELECT DISTINCT - - 56 + col2 + + 75 AS col0 FROM tab1 AS cor0
----
185
188
227

query I rowsort
SELECT + 52 * col0 + - ( + 6 ) FROM tab1 AS cor0
----
150
3322
4154

query I rowsort
SELECT DISTINCT col2 + col0 * ( col0 * - col2 ) AS col0 FROM tab0 AS cor0
----
-1224
-18975
-649440

query I rowsort
SELECT ALL + col2 * col1 - col0 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + + 18 FROM tab1 AS cor0
----
18

query I rowsort
SELECT - col2 * + 84 AS col0 FROM tab2
----
-2184
-2268
-3192

query I rowsort
SELECT ALL + tab0.col2 * ( col1 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT 57 FROM tab2, tab1, tab1 AS cor0, tab0 AS cor1
----
81 values hashing to 23b62d6905061dab566f3a9e15667302

query I rowsort
SELECT ALL col1 * - tab1.col0 + col2 * tab1.col2 FROM tab1
----
2609
2838
8176

query I rowsort
SELECT ALL cor0.col2 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL 0 * 86 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT 64 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL + 6 * col0 AS col1 FROM tab0 AS cor0
----
144
210
534

query I rowsort
SELECT - col2 * col1 - + col0 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT col0 * - col0 + + col2 + ( col2 ) AS col0 FROM tab0 AS cor0
----
-1223
-510
-7757

onlyif mysql # use DIV operator for integer division
query I rowsort label-3061
SELECT - col1 - - cor0.col2 DIV + col1 FROM tab2 AS cor0
----
-15
-31
-59

skipif mysql # not compatible
query I rowsort label-3061
SELECT - col1 - - cor0.col2 / + col1 FROM tab2 AS cor0
----
-15
-31
-59

query I rowsort
SELECT - 42 + - col1 AS col0 FROM tab1 AS cor0
----
-52
-55
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3063
SELECT CAST( - col0 AS SIGNED ) * + col1 + - ( + col2 ) AS col1 FROM tab0 cor0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-3063
SELECT CAST ( - col0 AS INTEGER ) * + col1 + - ( + col2 ) AS col1 FROM tab0 cor0
----
-2097
-3396
-8181

query I rowsort
SELECT col0 + + 77 * col2 AS col1 FROM tab1 AS cor0
----
4161
4453
7472

query I rowsort
SELECT + col2 + - col0 * + 1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL col2 + + col1 * - ( - col0 ) FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col0 * col2 + col2 * - 42 AS col1 FROM tab2 AS cor0
----
-945
1406
936

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + ( col2 ) * ( + col0 * + col1 ) FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL ( col1 ) * 5 AS col0 FROM tab1 cor0
----
130
50
65

query I rowsort
SELECT ALL + + col0 * col1 + - col0 AS col2 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3072
SELECT ALL + 68 * + cor0.col0 + + CAST( 40 * + col1 AS SIGNED ) AS col1 FROM tab0 cor0
----
5072
6260
9692

skipif mysql # not compatible
query I rowsort label-3072
SELECT ALL + 68 * + cor0.col0 + + CAST ( 40 * + col1 AS INTEGER ) AS col1 FROM tab0 cor0
----
5072
6260
9692

query I rowsort
SELECT col0 * 17 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT col1 * + cor0.col0 * - col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-3075
SELECT + - col1 + col1 DIV + 39 AS col0 FROM tab0 AS cor0
----
-84
-89
-95

skipif mysql # not compatible
query I rowsort label-3075
SELECT + - col1 + col1 / + 39 AS col0 FROM tab0 AS cor0
----
-84
-89
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3076
SELECT ALL + col2 * CAST( ( - col1 ) AS SIGNED ) + + ( col2 + + col0 ) * + ( col0 ) * col0 FROM tab2 AS cor0
----
631202
729551
829

skipif mysql # not compatible
query I rowsort label-3076
SELECT ALL + col2 * CAST ( ( - col1 ) AS INTEGER ) + + ( col2 + + col0 ) * + ( col0 ) * col0 FROM tab2 AS cor0
----
631202
729551
829

onlyif mysql # use DIV operator for integer division
query I rowsort label-3077
SELECT DISTINCT + col0 * col1 DIV 73 AS col1 FROM tab0
----
110
28
46

skipif mysql # not compatible
query I rowsort label-3077
SELECT DISTINCT + col0 * col1 / 73 AS col1 FROM tab0
----
110
28
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-3078
SELECT DISTINCT + + col0 * col0 DIV col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3078
SELECT DISTINCT + + col0 * col0 / col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT cor0.col1 FROM tab2, tab0 cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT + cor1.col1 FROM tab2, tab1 AS cor0, tab1, tab2 cor1
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT - 76 * 84 AS col1 FROM tab2 AS cor0
----
-6384
-6384
-6384

query I rowsort
SELECT ( + 3 ) AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT + - col2 * col0 + - 27 AS col1 FROM tab2 AS cor0
----
-2055
-216
-3029

query I rowsort
SELECT cor0.col1 * cor0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to f2938bee011b8d49dd931b1f9235e7f5

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab2, tab0 AS cor1
----
3645 values hashing to 5acb69cde71208fe580e10b8b669428e

query I rowsort
SELECT + col1 * 33 + - tab2.col2 AS col0 FROM tab2
----
1921
523
996

query I rowsort
SELECT - 62 + - col1 * - cor0.col0 FROM tab1 cor0
----
16
578
978

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3089
SELECT col1 DIV - 9 AS col1 FROM tab0 AS cor0
----
-10
-10
-9

skipif mysql # not compatible
query I rowsort label-3089
SELECT col1 / - 9 AS col1 FROM tab0 AS cor0
----
-10
-10
-9

query I rowsort
SELECT ALL + 52 + col1 AS col2 FROM tab0 AS cor0
----
138
143
149

query I rowsort
SELECT ALL + col0 + + col1 * col2 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) FROM tab2, tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - 22 * + tab2.col0 FROM tab2
----
-154
-1716
-1738

onlyif mysql # use DIV operator for integer division
query I rowsort label-3094
SELECT ALL - + col2 DIV + col1 + - col0 DIV col1 - + col1 AS col0 FROM tab1 AS cor0
----
-21
-26
-28

skipif mysql # not compatible
query I rowsort label-3094
SELECT ALL - + col2 / + col1 + - col0 / col1 - + col1 AS col0 FROM tab1 AS cor0
----
-21
-26
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-3095
SELECT - 38 DIV 36 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-3095
SELECT - 38 / 36 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT + ( + 66 + + col1 ) FROM tab2
----
125
83
97

query I rowsort
SELECT DISTINCT - col2 * ( - col2 + col1 ) AS col0 FROM tab1
----
1512
2679
7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-3098
SELECT + - col1 DIV - 84 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3098
SELECT + - col1 / - 84 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL tab0.col1 + - col0 + ( tab0.col1 ) AS col1 FROM tab0
----
148
159
93

query I rowsort
SELECT ALL - col1 + - ( 32 ) AS col1 FROM tab1
----
-42
-45
-58

query I rowsort
SELECT - col1 * ( + col0 ) + - col1 AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT + - col0 + + ( col2 ) FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3104
SELECT col1 DIV CAST( - col1 AS SIGNED ) + col2 AS col0 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3104
SELECT col1 / CAST ( - col1 AS INTEGER ) + col2 AS col0 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT - col1 * + cor0.col2 + + ( cor0.col1 + col0 ) AS col0 FROM tab2 AS cor0
----
-1397
-550
-799

query I rowsort
SELECT ALL - col2 + col1 + col0 AS col1 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT - ( 47 ) + + col2 FROM tab0 cor0
----
-14
-46
35

query I rowsort
SELECT DISTINCT 22 + 90 AS col0 FROM tab2 AS cor0
----
112

query I rowsort
SELECT - col2 * 88 * cor0.col0 FROM tab1 AS cor0
----
-14256
-321024
-675840

query I rowsort
SELECT ALL 43 AS col1 FROM tab0 AS cor0
----
43
43
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3111
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + + col1 AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3111
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + + col1 AS col2 FROM tab1 cor0
----
NULL

query I rowsort
SELECT - 58 * 70 AS col0 FROM tab0 AS cor0
----
-4060
-4060
-4060

query I rowsort
SELECT DISTINCT ( - ( + col2 ) ) * 75 AS col2 FROM tab2 AS cor0
----
-1950
-2025
-2850

query I rowsort
SELECT + col2 * - cor0.col1 + - col1 FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL - + 95 + col1 * col0 FROM tab2 AS cor0
----
122
1248
4507

query I rowsort
SELECT DISTINCT - 55 FROM tab1 cor0
----
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + col1 * + col2 col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + tab0.col2 + col0 + tab0.col2 AS col2 FROM tab0
----
253
37
90

query I rowsort
SELECT + col1 * tab1.col2 + + col0 - - col2 AS col2 FROM tab1
----
1424
1461
691

onlyif mysql # use DIV operator for integer division
query I rowsort label-3120
SELECT ALL col2 DIV col0 + + 96 FROM tab2
----
96
96
99

skipif mysql # not compatible
query I rowsort label-3120
SELECT ALL col2 / col0 + + 96 FROM tab2
----
96
96
99

query I rowsort
SELECT - col2 * 46 AS col1 FROM tab2
----
-1196
-1242
-1748

onlyif mysql # use DIV operator for integer division
query I rowsort label-3122
SELECT DISTINCT - tab2.col2 DIV - 27 AS col2 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-3122
SELECT DISTINCT - tab2.col2 / - 27 AS col2 FROM tab2
----
0
1

query I rowsort
SELECT + ( + col2 ) * - col2 * 7 + - col0 AS col0 FROM tab2 AS cor0
----
-10187
-4810
-5110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col2 ) * col1 + 69 * col1 col0 FROM tab0 AS cor0
----
-1183
3096
6596

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3125
SELECT DISTINCT CAST( 84 AS SIGNED ) col0 FROM tab2 AS cor0
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3125
SELECT DISTINCT CAST ( 84 AS INTEGER ) col0 FROM tab2 AS cor0
----
84

query I rowsort
SELECT - 23 * + col0 FROM tab1 AS cor0
----
-1472
-1840
-69

query I rowsort
SELECT ALL + ( 12 ) * col0 AS col2 FROM tab2 AS cor0
----
84
936
948

onlyif mysql # use DIV operator for integer division
query I rowsort label-3128
SELECT ALL + + col0 + ( col2 + cor0.col2 ) DIV ( + col2 + + col1 * + 36 ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3128
SELECT ALL + + col0 + ( col2 + cor0.col2 ) / ( + col2 + + col1 * + 36 ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3129
SELECT ALL - CAST( NULL AS SIGNED ) + + col2 * - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3129
SELECT ALL - CAST ( NULL AS INTEGER ) + + col2 * - col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 70 + ( - col1 + + 25 ) * col1 AS col2 FROM tab0
----
-5176
-5936
-6914

query I rowsort
SELECT + ( + col2 ) * + col1 + 65 AS col1 FROM tab0 AS cor0
----
162
2903
7527

query I rowsort
SELECT col2 * col1 + col2 * + col0 AS col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT ALL - 43 * 74 FROM tab2
----
-3182
-3182
-3182

query I rowsort
SELECT + 60 + tab0.col0 * col2 FROM tab0
----
7358
852
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 85 col1 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

query I rowsort
SELECT ALL + tab2.col0 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + col2 * cor0.col1 + col0 * col1 FROM tab2 AS cor0
----
1054
1989
6136

onlyif mysql # use DIV operator for integer division
query I rowsort label-3138
SELECT DISTINCT + col2 + cor0.col2 DIV col1 FROM tab1 AS cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-3138
SELECT DISTINCT + col2 + cor0.col2 / col1 FROM tab1 AS cor0
----
103
56
62

query I rowsort
SELECT - col2 * cor0.col2 - + col1 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT col2 * 47 * col0 + + col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
10530
174705
370176

query I rowsort
SELECT - 5 AS col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 85 + - col2 col1 FROM tab1
----
-11
28
31

query I rowsort
SELECT DISTINCT - col1 + + 69 FROM tab2
----
10
38
52

query I rowsort
SELECT - - cor0.col0 * cor0.col2 - + 20 * col0 * + 64 AS col2 FROM tab2 AS cor0
----
-8771
-97812
-98118

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col2 * + col2 + - col2 col1 FROM tab1 AS cor0
----
-2970
-3306
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3146
SELECT DISTINCT - cor0.col2 + + CAST( + 18 AS SIGNED ) * + col1 - ( 87 ) col0 FROM tab0 cor0
----
1428
1469
1658

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3146
SELECT DISTINCT - cor0.col2 + + CAST ( + 18 AS INTEGER ) * + col1 - ( 87 ) col0 FROM tab0 cor0
----
1428
1469
1658

onlyif mysql # use DIV operator for integer division
query I rowsort label-3147
SELECT + col2 DIV 48 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
4
65
82

skipif mysql # not compatible
query I rowsort label-3147
SELECT + col2 / 48 - - cor0.col0 AS col2 FROM tab1 AS cor0
----
4
65
82

query I rowsort
SELECT DISTINCT col1 + ( + col0 ) * col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT col2 * + 91 FROM tab2 AS cor0
----
2366
2457
3458

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3150
SELECT + col2 * CAST( col1 AS SIGNED ) - + col1 AS col0 FROM tab1 AS cor0
----
1235
1378
560

skipif mysql # not compatible
query I rowsort label-3150
SELECT + col2 * CAST ( col1 AS INTEGER ) - + col1 AS col0 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - cor0.col1 * + 66 FROM tab1 AS cor0
----
-1716
-660
-858

query I rowsort
SELECT DISTINCT - col0 + col0 - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + - col1 * - col0 * + ( cor0.col2 + - col2 * + cor0.col2 ) FROM tab0 AS cor0
----
-2179584
-53793558
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 23 col2 FROM tab0 AS cor0
----
-23
-23
-23

query I rowsort
SELECT ALL - ( col2 * + col2 ) AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL + col0 * + col0 + + col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab1, tab0, tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3158
SELECT ALL col0 DIV tab0.col0 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3158
SELECT ALL col0 / tab0.col0 col0 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL col2 + - col0 * + col0 AS col1 FROM tab2
----
-22
-6058
-6203

skipif mysql # not compatible
query I rowsort
SELECT + tab1.col0 + CAST ( + col0 + col0 AS REAL ) AS col0 FROM tab1
----
192
240
9

query I rowsort
SELECT - col0 * 69 FROM tab2 AS cor0
----
-483
-5382
-5451

query I rowsort
SELECT col1 * - ( ( - col0 ) ) * 17 FROM tab1
----
10880
1326
17680

query I rowsort
SELECT + col2 * - ( - 18 ) AS col0 FROM tab0
----
1476
18
594

onlyif mysql # use DIV operator for integer division
query I rowsort label-3164
SELECT + col0 + col0 DIV - col2 + col1 FROM tab1
----
29
73
93

skipif mysql # not compatible
query I rowsort label-3164
SELECT + col0 + col0 / - col2 + col1 FROM tab1
----
29
73
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * tab2.col2 * - col1 col2 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-3166
SELECT ALL - col1 DIV col2 col0 FROM tab0 cor0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3166
SELECT ALL - col1 / col2 col0 FROM tab0 cor0
----
-1
-2
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3167
SELECT ALL + CAST( col0 AS SIGNED ) * tab1.col0 FROM tab1
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-3167
SELECT ALL + CAST ( col0 AS INTEGER ) * tab1.col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - 24 + col2 AS col2 FROM tab2 AS cor0
----
14
2
3

query I rowsort
SELECT DISTINCT - cor0.col1 * + col0 + - col0 FROM tab1 AS cor0
----
-1120
-704
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 + + col0 col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - ( col2 ) * - col1 + - tab1.col2 * col0 AS col1 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT ALL - col2 * + col1 + - col2 * tab1.col0 AS col0 FROM tab1
----
-1566
-4218
-8928

query I rowsort
SELECT ALL col1 + - col0 * - tab1.col0 * - col2 AS col1 FROM tab1
----
-233462
-460
-614387

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT ( NOT NULL BETWEEN NULL AND ( NULL ) ) AND NULL NOT IN ( col0 + + col2 / col0 ) OR NOT NULL > ( NULL )
----

query I rowsort
SELECT + col2 + - col1 * - col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3176
SELECT ALL - + col1 DIV + col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3176
SELECT ALL - + col1 / + col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - ( - col0 ) * col2 + + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) * - cor0.col0 + col0 col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + 59 * - col2 - cor0.col2 * col2 FROM tab2 AS cor0
----
-2210
-2322
-3686

query I rowsort
SELECT col2 - + col1 AS col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + col1 * + col0 * ( - col0 ) AS col2 FROM tab1 AS cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 32 col1 FROM tab0 AS cor0
----
1120
2848
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-3183
SELECT col0 DIV ( col0 ) AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3183
SELECT col0 / ( col0 ) AS col2 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3184
SELECT ALL - col1 + + CAST( cor0.col2 AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
-62
706
7207

skipif mysql # not compatible
query I rowsort label-3184
SELECT ALL - col1 + + CAST ( cor0.col2 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + col1 + + col2 + col0 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3186
SELECT col1 + CAST( NULL AS SIGNED ) * col0 + col2 / col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3186
SELECT col1 + CAST ( NULL AS INTEGER ) * col0 + col2 / col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 + col0 + 2 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-18
14
68

query I rowsort
SELECT ALL + + 51 * col2 FROM tab1 AS cor0
----
2754
2907
4896

query I rowsort
SELECT + + 0 + col2 AS col1 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3190
SELECT - - col0 + col2 - + col1 DIV - col0 AS col0 FROM tab2 cor0
----
104
117
38

skipif mysql # not compatible
query I rowsort label-3190
SELECT - - col0 + col2 - + col1 / - col0 AS col0 FROM tab2 cor0
----
104
117
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3191
SELECT col1 DIV 47 + col2 * col2 + + col1 * col0 FROM tab1 AS cor0
----
10256
2994
3889

skipif mysql # not compatible
query I rowsort label-3191
SELECT col1 / 47 + col2 * col2 + + col1 * col0 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT ALL - + col1 * 44 AS col2 FROM tab2 AS cor0
----
-1364
-2596
-748

query I rowsort
SELECT DISTINCT - col0 * + ( + col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + + col2 + ( + 93 ) + + col2 FROM tab2 AS cor0
----
145
147
169

query I rowsort
SELECT ALL cor0.col2 * 32 AS col0 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT + col1 * col2 + col2 AS col1 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3197
SELECT col1 DIV 95 + + col0 FROM tab0 AS cor0
----
24
36
89

skipif mysql # not compatible
query I rowsort label-3197
SELECT col1 / 95 + + col0 FROM tab0 AS cor0
----
24
36
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 + col2 col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3199
SELECT DISTINCT + col0 + + CAST( col0 * col1 AS SIGNED ) FROM tab0 AS cor0
----
2088
3430
8188

skipif mysql # not compatible
query I rowsort label-3199
SELECT DISTINCT + col0 + + CAST ( col0 * col1 AS INTEGER ) FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + col1 * - cor0.col1 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT + col1 * ( cor0.col1 ) FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3202
SELECT col1 + CAST( col0 AS SIGNED ) * - cor0.col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-3202
SELECT col1 + CAST ( col0 AS INTEGER ) * - cor0.col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - tab0.col1 + col0 * - ( - col2 ) FROM tab0
----
-62
706
7207

query I rowsort
SELECT + cor1.col1 FROM tab0, tab2, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT DISTINCT + col1 + 80 AS col0 FROM tab0
----
166
171
177

query I rowsort
SELECT col1 + 30 FROM tab0
----
116
121
127

query I rowsort
SELECT col0 * - 97 + - ( - col0 ) FROM tab0 AS cor0
----
-2304
-3360
-8544

query I rowsort
SELECT ALL - - col2 * cor0.col1 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - - col0 + + ( + col2 ) AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + col0 * - col1 + + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL + 82 * col0 - col0 * + 81 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL + 28 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT DISTINCT + ( - col1 + - tab0.col2 ) FROM tab0
----
-119
-173
-98

query I rowsort
SELECT + 0 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT - 85 * + col2 FROM tab2 AS cor0
----
-2210
-2295
-3230

query I rowsort
SELECT ALL cor0.col0 * + col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + ( + cor0.col1 ) * - col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL col0 + cor0.col2 * col1 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-3219
SELECT + cor0.col1 + col2 DIV - col0 FROM tab1 cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-3219
SELECT + cor0.col1 + col2 / - col0 FROM tab1 cor0
----
10
12
8

query I rowsort
SELECT DISTINCT + col1 - - cor0.col2 * + ( + col2 ) FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT 88 + col2 AS col1 FROM tab2 AS cor0
----
114
115
126

query I rowsort
SELECT - col1 * - col1 + 68 AS col0 FROM tab0 AS cor0
----
7464
8349
9477

query I rowsort
SELECT + col1 * - col1 + + cor0.col2 FROM tab2 AS cor0
----
-251
-3455
-934

onlyif mysql # use DIV operator for integer division
query I rowsort label-3224
SELECT DISTINCT + - 30 + - col2 DIV - col0 AS col1 FROM tab1 AS cor0
----
-12
-29
-30

skipif mysql # not compatible
query I rowsort label-3224
SELECT DISTINCT + - 30 + - col2 / - col0 AS col1 FROM tab1 AS cor0
----
-12
-29
-30

query I rowsort
SELECT DISTINCT + ( + col0 ) * col0 FROM tab2 cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 11 + - tab1.col1 * tab1.col1 col0 FROM tab1
----
-158
-665
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3227
SELECT 17 DIV col1 AS col2 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3227
SELECT 17 / col1 AS col2 FROM tab2
----
0
0
1

query I rowsort
SELECT DISTINCT - 73 * - col1 FROM tab0 cor0
----
6278
6643
7081

onlyif mysql # use DIV operator for integer division
query I rowsort label-3229
SELECT DISTINCT + 72 DIV + col1 AS col0 FROM tab2 cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-3229
SELECT DISTINCT + 72 / + col1 AS col0 FROM tab2 cor0
----
1
2
4

query I rowsort
SELECT - - 22 * col1 AS col1 FROM tab1 AS cor0
----
220
286
572

query I rowsort
SELECT + - col1 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT - 96 * - col0 FROM tab0
----
2304
3360
8544

query I rowsort
SELECT ALL + col0 * - col1 + - col2 * col1 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT - col1 + col1 * + 4 AS col0 FROM tab1 cor0
----
30
39
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3235
SELECT - - col1 * - col0 - - col1 DIV 33 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3235
SELECT - - col1 * - col0 - - col1 / 33 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + - 82 + col0 FROM tab2 cor0
----
-3
-4
-75

query I rowsort
SELECT - col1 + col2 * + ( col1 ) FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT cor0.col1 + + 6 * 31 FROM tab2 AS cor0
----
203
217
245

query I rowsort
SELECT DISTINCT - - col0 * 33 AS col1 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT ALL - + cor0.col2 + + 3 * - ( + col0 ) FROM tab2 cor0
----
-260
-275
-48

query I rowsort
SELECT + col1 + 63 FROM tab1 AS cor0
----
73
76
89

query I rowsort
SELECT + + col2 * - 9 + + col1 AS col2 FROM tab0 AS cor0
----
-211
-647
88

query I rowsort
SELECT ALL ( 14 ) FROM tab1 AS cor0
----
14
14
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-3244
SELECT ALL cor0.col2 * col1 DIV - cor0.col2 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3244
SELECT ALL cor0.col2 * col1 / - cor0.col2 FROM tab0 cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - col1 col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + - cor0.col2 * + 25 AS col2 FROM tab2 AS cor0
----
-650
-675
-950

onlyif mysql # use DIV operator for integer division
query I rowsort label-3247
SELECT 25 + + cor0.col1 DIV - col0 FROM tab1 AS cor0
----
17
25
25

skipif mysql # not compatible
query I rowsort label-3247
SELECT 25 + + cor0.col1 / - col0 FROM tab1 AS cor0
----
17
25
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-3248
SELECT ALL + ( + col1 ) DIV - col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-3248
SELECT ALL + ( + col1 ) / - col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT - 61 + col0 * - ( col2 * - col1 ) FROM tab1 AS cor0
----
36419
4151
99779

query I rowsort
SELECT ALL col0 * + 69 AS col0 FROM tab1
----
207
4416
5520

query I rowsort
SELECT - 8 - - col1 * col1 FROM tab2
----
281
3473
953

query I rowsort
SELECT ( ( + col0 ) ) * col0 + - 48 * col0 FROM tab1
----
-135
1024
2560

query I rowsort
SELECT DISTINCT col2 * - 20 FROM tab2
----
-520
-540
-760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3254
SELECT DISTINCT + col0 * - tab0.col2 DIV col2 col2 FROM tab0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3254
SELECT DISTINCT + col0 * - tab0.col2 / col2 col2 FROM tab0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 44 * - col0 col0 FROM tab0
----
-1056
-1540
-3916

onlyif mysql # use DIV operator for integer division
query I rowsort label-3256
SELECT 96 DIV ( - col1 ) FROM tab1 AS cor0
----
-3
-7
-9

skipif mysql # not compatible
query I rowsort label-3256
SELECT 96 / ( - col1 ) FROM tab1 AS cor0
----
-3
-7
-9

query I rowsort
SELECT + 47 * - col1 FROM tab0 AS cor0
----
-4042
-4277
-4559

query I rowsort
SELECT - col1 * col2 + - col1 * - col0 AS col2 FROM tab2 AS cor0
----
-620
3068
697

query I rowsort
SELECT + + col2 + - col0 * col0 * col2 FROM tab0 AS cor0
----
-1224
-18975
-649440

query I rowsort
SELECT col0 * + col0 + - cor0.col1 * col2 FROM tab0 AS cor0
----
-2262
1128
459

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col2 * - col1 col2 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT DISTINCT col1 + col2 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 74 * + tab0.col0 AS col2 FROM tab0
----
1776
2590
6586

onlyif mysql # use DIV operator for integer division
query I rowsort label-3264
SELECT DISTINCT - col2 * + col0 DIV + col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3264
SELECT DISTINCT - col2 * + col0 / + col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL + col0 * col0 * col2 AS col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT - 70 * col0 FROM tab2
----
-490
-5460
-5530

query I rowsort
SELECT ( - col1 ) + + col2 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT + col0 * - ( col0 ) + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT cor0.col2 * 53 + col2 * + col2 FROM tab0 AS cor0
----
11070
2838
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-3270
SELECT - - col2 * - cor0.col1 + + col1 DIV cor0.col1 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-3270
SELECT - - col2 * - cor0.col1 + + col1 / cor0.col1 FROM tab1 AS cor0
----
-1247
-1403
-569

query I rowsort
SELECT ALL 65 AS col1 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT DISTINCT 90 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3273
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-3273
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3274
SELECT DISTINCT - col0 DIV + ( + col0 + - col2 ) AS col2 FROM tab2
----
-1
0

skipif mysql # not compatible
query I rowsort label-3274
SELECT DISTINCT - col0 / + ( + col0 + - col2 ) AS col2 FROM tab2
----
-1
0

query I rowsort
SELECT DISTINCT - - ( - cor1.col0 ) - 98 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-101
-162
-178

query I rowsort
SELECT - cor0.col2 * col1 - + cor0.col1 * - col2 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + - cor0.col1 * + col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT - cor0.col0 * + 5 FROM tab0, tab2 AS cor0
----
-35
-390
-395

onlyif mysql # use DIV operator for integer division
query I rowsort label-3279
SELECT DISTINCT cor0.col1 DIV 99 FROM tab2, tab0, tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3279
SELECT DISTINCT cor0.col1 / 99 FROM tab2, tab0, tab2 AS cor0
----
0

query I rowsort
SELECT ALL + + col1 * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3281
SELECT ALL + + col1 DIV - 52 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-60

skipif mysql # not compatible
query I rowsort label-3281
SELECT ALL + + col1 / - 52 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-60

query I rowsort
SELECT DISTINCT - + col1 * col0 + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - 99 * col1 - + col1 FROM tab2 AS cor0
----
-1700
-3100
-5900

query I rowsort
SELECT col2 + - col1 - col2 * col0 FROM tab1
----
-134
-3601
-7597

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col0 + - col2 - col2 col1 FROM tab1
----
3534
54
7488

query I rowsort
SELECT DISTINCT 65 + - tab2.col1 * cor1.col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
9 values hashing to 0f700395f32715adc97a882d36106428

onlyif mysql # use DIV operator for integer division
query I rowsort label-3287
SELECT + col2 DIV ( - 13 ) FROM tab0
----
-2
-6
0

skipif mysql # not compatible
query I rowsort label-3287
SELECT + col2 / ( - 13 ) FROM tab0
----
-2
-6
0

query I rowsort
SELECT - 22 - 57 * + col0 AS col1 FROM tab0
----
-1390
-2017
-5095

query I rowsort
SELECT - ( - ( col1 ) ) + + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3290
SELECT ( col1 ) DIV cor0.col0 - col2 * col0 AS col1 FROM tab2 AS cor0
----
-185
-2028
-3002

skipif mysql # not compatible
query I rowsort label-3290
SELECT ( col1 ) / cor0.col0 - col2 * col0 AS col1 FROM tab2 AS cor0
----
-185
-2028
-3002

query I rowsort
SELECT - col2 * - col1 + - cor0.col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL - cor0.col0 * col2 + col2 * col1 + cor0.col2 * col0 * - ( col0 ) AS col2 FROM tab2 AS cor0
----
-158678
-239514
-675

query I rowsort
SELECT DISTINCT - 43 * 54 - cor0.col2 FROM tab2 cor0
----
-2348
-2349
-2360

query I rowsort
SELECT cor0.col0 * col2 + col2 * + 28 FROM tab2 AS cor0
----
2756
4066
945

query I rowsort
SELECT ALL - - 85 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-3296
SELECT DISTINCT + col0 + col2 DIV + col2 AS col2 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3296
SELECT DISTINCT + col0 + col2 / + col2 AS col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT col1 * - 14 FROM tab1 AS cor0
----
-140
-182
-364

query I rowsort
SELECT col2 * - col0 + cor0.col2 * + col2 FROM tab0 AS cor0
----
-34
-574
297

onlyif mysql # use DIV operator for integer division
query I rowsort label-3299
SELECT - cor0.col1 DIV + cor0.col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3299
SELECT - cor0.col1 / + cor0.col1 FROM tab2 AS cor0
----
-1
-1
-1

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NULL IN ( - col2 ) OR NOT NULL NOT IN ( col2 * - col0 + col1 )
----

query I rowsort
SELECT ALL - col1 + col0 + col0 * - col2 FROM tab0 AS cor0
----
-7300
-854
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * col0 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col2 * + col0 * col2 AS col1 FROM tab0 AS cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-3304
SELECT ALL tab1.col0 - - tab1.col0 DIV col2 FROM tab1
----
3
65
80

skipif mysql # not compatible
query I rowsort label-3304
SELECT ALL tab1.col0 - - tab1.col0 / col2 FROM tab1
----
3
65
80

query I rowsort
SELECT - col2 + + col0 - col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT col1 + - col0 * cor0.col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-4022
-6307
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + col2 col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 + cor0.col0 col2 FROM tab1 AS cor0 WHERE - col1 NOT IN ( cor0.col0 ) OR ( NULL ) NOT BETWEEN NULL AND NULL
----
165
3712
7760

query I rowsort
SELECT ALL - tab2.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT DISTINCT col1 + col0 + - col2 AS col2 FROM tab1
----
-25
-3
17

query I rowsort
SELECT ALL col1 + cor0.col2 * col0 AS col2 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3312
SELECT - col2 * col2 * col1 + - cor0.col0 DIV - col2 AS col0 FROM tab1 AS cor0
----
-119808
-32489
-75816

skipif mysql # not compatible
query I rowsort label-3312
SELECT - col2 * col2 * col1 + - cor0.col0 / - col2 AS col0 FROM tab1 AS cor0
----
-119808
-32489
-75816

query I rowsort
SELECT DISTINCT + col2 + col2 * col0 AS col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT ALL - - col0 + - col2 AS col1 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT + 80 + col0 * col2 * - col1 FROM tab2
----
-119572
-50954
-5779

onlyif mysql # use DIV operator for integer division
query I rowsort label-3316
SELECT 68 - col0 DIV - col0 FROM tab1
----
69
69
69

skipif mysql # not compatible
query I rowsort label-3316
SELECT 68 - col0 / - col0 FROM tab1
----
69
69
69

query I rowsort
SELECT DISTINCT + col2 * + col2 * + col1 AS col0 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT + col1 + col2 * - col0 * + col2 FROM tab0
----
-26050
-598345
62

query I rowsort
SELECT col2 * col1 + col0 AS col1 FROM tab2
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-3320
SELECT ALL + col0 DIV col0 - col1 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3320
SELECT ALL + col0 / col0 - col1 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT DISTINCT + col0 * tab1.col0 + col0 FROM tab1
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-3322
SELECT DISTINCT tab2.col1 * col0 * + col2 + col0 DIV col1 col0 FROM tab2
----
119653
51038
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3322
SELECT DISTINCT tab2.col1 * col0 * + col2 + col0 / col1 col0 FROM tab2
----
119653
51038
5859

query I rowsort
SELECT DISTINCT + tab1.col0 - + col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT - col0 + - col0 * col0 FROM tab1
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT + - 6 AS col1 FROM tab1, tab0, tab0 AS cor0
----
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3326
SELECT DISTINCT col1 + col2 DIV col2 - 95 AS col2 FROM tab1 AS cor0
----
-68
-81
-84

skipif mysql # not compatible
query I rowsort label-3326
SELECT DISTINCT col1 + col2 / col2 - 95 AS col2 FROM tab1 AS cor0
----
-68
-81
-84

query I rowsort
SELECT DISTINCT + col2 + col0 + + tab2.col1 * - col2 FROM tab2 WHERE ( NULL ) IN ( - tab2.col1 - col2 * + col0 )
----

query III rowsort
SELECT * FROM tab2 WHERE ( col2 * - col1 ) > ( + col0 * + col2 + col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT - col0 * + col2 IN ( - col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col1 / - tab0.col0 FROM tab0 WHERE ( NULL ) <> + col1 * col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3331
SELECT + col0 DIV col0 + col1 * + col1 + col2 FROM tab0
----
7430
8364
9411

skipif mysql # not compatible
query I rowsort label-3331
SELECT + col0 / col0 + col1 * + col1 + col2 FROM tab0
----
7430
8364
9411

query I rowsort
SELECT col0 + col2 * - col0 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query III rowsort
SELECT * FROM tab0 WHERE NOT ( col0 ) NOT IN ( - tab0.col2 + + col0 * col0 )
----

query I rowsort
SELECT ALL col2 * col1 * + col2 + - col0 AS col1 FROM tab2
----
22592
24469
39806

query III rowsort
SELECT * FROM tab1 WHERE ( + col0 ) BETWEEN col1 AND col2 * col1 - col0
----
64
10
57
80
13
96

query I rowsort
SELECT - col2 + + col0 * col1 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT tab2.col2 FROM tab2 WHERE NOT NULL <= ( col0 + + col0 )
----

query I rowsort
SELECT + col1 * tab0.col2 - col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT DISTINCT col2 * - col0 * - tab1.col2 AS col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT - col1 + + col1 + col1 * + col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col2 + col0 * tab0.col0 AS col2 FROM tab0
----
1226
609
8003

query I rowsort
SELECT ALL tab2.col0 - tab2.col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL col1 FROM tab2 WHERE NOT NULL NOT IN ( col2 * - col1 )
----

query I rowsort
SELECT DISTINCT col1 + + col0 * tab0.col2 * col0 FROM tab0
----
1322
19094
649613

onlyif mysql # use DIV operator for integer division
query I rowsort label-3345
SELECT DISTINCT - col0 DIV - col0 - cor0.col2 col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3345
SELECT DISTINCT - col0 / - col0 - cor0.col2 col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT - 35 * 33 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a6d6bf1a6a024b08cc1a7df15770b2c8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3347
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3347
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL 93 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT 49 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL + col1 + ( ( - col2 ) + - ( - col0 ) ) AS col0 FROM tab1
----
-25
-3
17

query I rowsort
SELECT + col0 * 95 AS col0 FROM tab2 AS cor0
----
665
7410
7505

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col2 col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col0 - - col2 col2 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT - col0 * - 31 - - col0 * col1 AS col2 FROM tab2 AS cor0
----
3792
434
7020

query I rowsort
SELECT + col1 * col1 * 92 + cor0.col1 FROM tab2 AS cor0
----
26605
320311
88443

query I rowsort
SELECT - col2 * - ( 42 ) + + col0 AS col2 FROM tab0 AS cor0
----
1410
3533
77

query I rowsort
SELECT DISTINCT 8 FROM tab0, tab1 cor0
----
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col2 col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT - 71 * + col2 AS col2 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT + 30 - + cor0.col0 AS col0 FROM tab1 AS cor0
----
-34
-50
27

query I rowsort
SELECT - 1 * + col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - cor0.col0 - + col2 * - col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - col1 * col1 - + 17 AS col2 FROM tab2 AS cor0
----
-306
-3498
-978

onlyif mysql # use DIV operator for integer division
query I rowsort label-3364
SELECT + 69 DIV col1 + 93 + + col0 * - col1 FROM tab1 AS cor0
----
-541
-942
17

skipif mysql # not compatible
query I rowsort label-3364
SELECT + 69 / col1 + 93 + + col0 * - col1 FROM tab1 AS cor0
----
-541
-942
17

query I rowsort
SELECT + + col2 * col1 + + ( - col0 ) AS col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT - 28 AS col0 FROM tab1, tab0 cor0
----
-28

query I rowsort
SELECT ( - col0 ) - - col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - col1 * col0 + 0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 2 * col1 col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT ALL + - col1 - cor0.col0 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT - cor0.col2 * cor0.col0 + col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT - - 70 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
32
43
44

query I rowsort
SELECT ALL + 29 * + tab1.col2 - + tab1.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8e43a5f83dd7cbab90cb34cfd13c4c15

query I rowsort
SELECT + + ( col0 ) * - cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + + 49 + cor0.col1 * - 50 FROM tab1 cor0
----
-1251
-451
-601

query I rowsort
SELECT cor0.col1 * + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to f5605ce6cbd6ecc79a4a887488bb6947

query I rowsort
SELECT + 79 + - col1 * col1 AS col0 FROM tab1 AS cor0
----
-21
-597
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 - col2 col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT + + col1 - cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + - cor0.col2 + ( ( col1 ) ) * col2 + col0 * cor0.col2 AS col1 FROM tab2 cor0
----
3536
3610
999

query I rowsort
SELECT ALL col1 * 55 - cor0.col1 FROM tab2 AS cor0
----
1674
3186
918

query I rowsort
SELECT DISTINCT col0 * + col1 - - col0 FROM tab2
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3383
SELECT col1 + col1 DIV ( - 68 ) - - col0 AS col2 FROM tab0
----
109
131
179

skipif mysql # not compatible
query I rowsort label-3383
SELECT col1 + col1 / ( - 68 ) - - col0 AS col2 FROM tab0
----
109
131
179

query I rowsort
SELECT col2 + col0 * tab2.col0 + - col0 AS col0 FROM tab2
----
6032
6200
69

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col0 AS REAL ) * + col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3386
SELECT - - col0 DIV - cor0.col2 col1 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3386
SELECT - - col0 / - cor0.col2 col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - 54 * - col0 + + col0 + col0 AS col2 FROM tab0 AS cor0
----
1344
1960
4984

query I rowsort
SELECT ALL + - 75 + 69 FROM tab1 AS cor0
----
-6
-6
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3389
SELECT DISTINCT - + CAST( NULL AS SIGNED ) + col1 * col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3389
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) + col1 * col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col1 * - 34 + col1 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT - + cor0.col0 + col1 + - col1 * - cor0.col0 FROM tab1 AS cor0
----
101
586
973

query I rowsort
SELECT + - cor0.col2 * 97 FROM tab2 AS cor0
----
-2522
-2619
-3686

query I rowsort
SELECT ALL cor0.col0 * - ( + 58 ) AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to aeee03ac1b8375c74edfaf6ee8e04466

query I rowsort
SELECT - ( 3 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT 18 - + col1 FROM tab1
----
-8
5
8

query I rowsort
SELECT col1 + - col2 * col0 * - col0 FROM tab2
----
1354
158243
237175

query I rowsort
SELECT + col1 + - ( + ( tab1.col0 ) ) * - 23 * 82 AS col1 FROM tab1
----
120714
150893
5684

onlyif mysql # use DIV operator for integer division
query I rowsort label-3398
SELECT DISTINCT cor0.col0 DIV + ( 98 ) FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3398
SELECT DISTINCT cor0.col0 / + ( 98 ) FROM tab2 cor0
----
0

query I rowsort
SELECT - col0 * + ( + col1 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 87 + 82 FROM tab2, tab0 AS cor0
----
9 values hashing to 010aef9ddbf6b21f5528b641346836e6

query I rowsort
SELECT tab2.col0 + + ( + 31 ) * + col0 FROM tab2
----
224
2496
2528

query I rowsort
SELECT ALL - col0 * - col2 - 36 AS col0 FROM tab0 AS cor0
----
-1
7262
756

query I rowsort
SELECT DISTINCT + + col1 * - cor0.col2 + - col2 * + col1 AS col0 FROM tab2 AS cor0
----
-1292
-1674
-3068

query I rowsort
SELECT - + ( col1 ) - - col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - - ( 99 ) * col2 AS col0 FROM tab0 AS cor0
----
3267
8118
99

query I rowsort
SELECT + + col1 * col1 - cor0.col0 AS col0 FROM tab1 AS cor0
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3407
SELECT - col1 DIV col0 + col2 AS col0 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-3407
SELECT - col1 / col0 + col2 AS col0 FROM tab2 AS cor0
----
23
26
38

query I rowsort
SELECT ALL + ( col1 ) * col0 - col1 AS col0 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-3409
SELECT - col0 DIV 43 + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
7396
8279
9409

skipif mysql # not compatible
query I rowsort label-3409
SELECT - col0 / 43 + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
7396
8279
9409

query I rowsort
SELECT DISTINCT - 62 + ( col0 * ( col0 ) ) FROM tab2 cor0
----
-13
6022
6179

query I rowsort
SELECT - ( col2 ) + col0 * ( 14 ) FROM tab1 AS cor0
----
-12
1024
839

query I rowsort
SELECT ALL - col2 * ( + cor0.col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col1 * 83 + + col1 FROM tab0 AS cor0
----
7224
7644
8148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3414
SELECT DISTINCT CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3414
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col0 * 11 AS col0 FROM tab1 cor0
----
33
704
880

query I rowsort
SELECT DISTINCT 17 * - 31 FROM tab0 AS cor0
----
-527

onlyif mysql # use DIV operator for integer division
query I rowsort label-3417
SELECT - tab1.col2 DIV + ( col2 ) + col0 AS col1 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3417
SELECT - tab1.col2 / + ( col2 ) + col0 AS col1 FROM tab1
----
2
63
79

query I rowsort
SELECT ( + 99 ) + + col0 FROM tab2 AS cor0
----
106
177
178

onlyif mysql # use DIV operator for integer division
query I rowsort label-3419
SELECT + - 84 DIV cor0.col1 + col0 FROM tab2 AS cor0
----
5
75
77

skipif mysql # not compatible
query I rowsort label-3419
SELECT + - 84 / cor0.col1 + col0 FROM tab2 AS cor0
----
5
75
77

query I rowsort
SELECT cor0.col0 + col2 * + 43 AS col0 FROM tab1 AS cor0
----
2325
2515
4208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3421
SELECT DISTINCT + col0 * - col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3421
SELECT DISTINCT + col0 * - col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 35 + col0 FROM tab1 AS cor0
----
115
38
99

query I rowsort
SELECT ALL - - col1 * col1 + - col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT - 20 + - cor0.col0 FROM tab0 AS cor0
----
-109
-44
-55

query I rowsort
SELECT DISTINCT col0 + - col2 * col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL cor0.col0 * + col0 * - ( + col2 ) FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - - col2 * col2 * 29 + - 38 AS col1 FROM tab1 AS cor0
----
267226
84526
94183

query I rowsort
SELECT - 26 * + col0 + + ( col1 + col2 ) AS col1 FROM tab0 AS cor0
----
-2141
-505
-812

query I rowsort
SELECT + 58 + + col1 * + col1 AS col0 FROM tab1 AS cor0
----
158
227
734

query I rowsort
SELECT ALL 74 * col1 AS col0 FROM tab1 AS cor0
----
1924
740
962

query I rowsort
SELECT DISTINCT 42 + - col1 * - 99 * col2 AS col1 FROM tab1 AS cor0
----
123594
139038
56472

query I rowsort
SELECT ALL cor0.col1 + 70 FROM tab2 AS cor0
----
101
129
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3433
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab0, tab2 cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3433
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab0, tab2 cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT col1 * col2 * - col2 FROM tab1 cor0
----
-119808
-32490
-75816

query I rowsort
SELECT col1 * - col0 * + 65 + - col0 + col1 AS col1 FROM tab0 AS cor0
----
-134098
-220613
-526433

query I rowsort
SELECT DISTINCT - col0 * col2 * + col1 + col2 * col2 + + 1 FROM tab2 AS cor0
----
-118975
-49589
-5129

query I rowsort
SELECT DISTINCT col0 + ( + 7 ) FROM tab1 cor0
----
10
71
87

query I rowsort
SELECT DISTINCT + ( - tab2.col0 ) AS col2 FROM tab2, tab0, tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT + 67 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT col0 + - 98 * 80 * - col2 AS col2 FROM tab2 AS cor0
----
203918
211687
297999

query I rowsort
SELECT - col1 + 42 AS col0 FROM tab1 AS cor0
----
16
29
32

query I rowsort
SELECT + + col2 + 60 * + col0 FROM tab1 AS cor0
----
234
3897
4896

query I rowsort
SELECT ALL - 23 FROM tab0, tab2 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT - 32 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT ALL + col0 * - 75 AS col2 FROM tab2
----
-525
-5850
-5925

query I rowsort
SELECT + - col2 + - cor0.col2 * - col0 * col0 AS col0 FROM tab0 AS cor0
----
1224
18975
649440

query I rowsort
SELECT 7 + + col0 + col1 FROM tab0
----
117
139
187

query I rowsort
SELECT ALL - col2 * col2 + + col2 FROM tab0
----
-1056
-6642
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 23 - + col2 col1 FROM tab1 AS cor0
----
-119
-77
-80

query I rowsort
SELECT + col2 * + ( + col2 ) + 41 FROM tab0
----
1130
42
6765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3451
SELECT col1 * + col2 * + CAST( - col0 AS SIGNED ) AS col1 FROM tab1
----
-36480
-4212
-99840

skipif mysql # not compatible
query I rowsort label-3451
SELECT col1 * + col2 * + CAST ( - col0 AS INTEGER ) AS col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col2 * col0 + - col1 + ( - col2 ) * 66 AS col0 FROM tab2 cor0
----
-1624
253
477

query I rowsort
SELECT ALL - - ( col0 ) * col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3454
SELECT col1 + - col1 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3454
SELECT col1 + - col1 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + 80 ) * cor0.col1 AS col0 FROM tab1, tab1 AS cor0
----
1040
2080
800

query I rowsort
SELECT - col1 + + col1 + col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3457
SELECT + col1 + + col0 DIV + col0 - - col1 AS col2 FROM tab0
----
173
183
195

skipif mysql # not compatible
query I rowsort label-3457
SELECT + col1 + + col0 / + col0 - - col1 AS col2 FROM tab0
----
173
183
195

query I rowsort
SELECT + col1 * + 10 FROM tab1
----
100
130
260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 - - col2 * col1 col1 FROM tab1 AS cor0
----
1304
1460
626

query I rowsort
SELECT DISTINCT col1 * + 86 AS col0 FROM tab1
----
1118
2236
860

onlyif mysql # use DIV operator for integer division
query I rowsort label-3461
SELECT - col0 DIV - col1 + + col1 * col1 * - col2 col2 FROM tab2
----
-10978
-25947
-90505

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3461
SELECT - col0 / - col1 + + col1 * col1 * - col2 col2 FROM tab2
----
-10978
-25947
-90505

query I rowsort
SELECT ALL col0 * ( ( - col2 ) ) * + col1 AS col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col2 * 32 * col0 AS col1 FROM tab2
----
6048
64896
96064

query I rowsort
SELECT DISTINCT + cor0.col2 + + ( col0 ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col1 + col0 * col0 * + col1 AS col1 FROM tab1 AS cor0
----
208
40950
83187

query I rowsort
SELECT DISTINCT 65 AS col1 FROM tab0, tab1 cor0
----
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3467
SELECT - CAST( NULL AS SIGNED ) * + col0 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3467
SELECT - CAST ( NULL AS INTEGER ) * + col0 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col0 * col1 * - col0 + col2 FROM tab2 AS cor0
----
-106059
-1492
-358930

query I rowsort
SELECT ALL - 61 AS col2 FROM tab0 cor0
----
-61
-61
-61

query I rowsort
SELECT ALL - + 56 * col0 AS col1 FROM tab0 cor0
----
-1344
-1960
-4984

query I rowsort
SELECT DISTINCT - 57 + 21 FROM tab1 AS cor0
----
-36

query I rowsort
SELECT DISTINCT - 28 + - col0 * col1 * col0 - - col0 FROM tab1 AS cor0
----
-259
-40924
-83148

query I rowsort
SELECT ALL - + 46 * + col0 - col0 * 77 AS col2 FROM tab0 cor0
----
-10947
-2952
-4305

query I rowsort
SELECT - - ( 27 ) FROM tab0 AS cor0
----
27
27
27

query I rowsort
SELECT - col0 * col1 * + col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - + 81 AS col2 FROM tab2 AS cor0
----
-81
-81
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3477
SELECT CAST( NULL AS SIGNED ) + 31 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3477
SELECT CAST ( NULL AS INTEGER ) + 31 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3478
SELECT DISTINCT + 77 * col0 * - col2 - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3478
SELECT DISTINCT + 77 * col0 * - col2 - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3479
SELECT ALL - + col1 DIV + col2 + - col2 * - col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-3479
SELECT ALL - + col1 / + col2 + - col2 * - col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - cor1.col2 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL cor0.col1 - cor0.col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3482
SELECT DISTINCT - + CAST( NULL AS SIGNED ) + + col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3482
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) + + col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3483
SELECT cor0.col0 + + col2 DIV - col0 AS col0 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-3483
SELECT cor0.col0 + + col2 / - col0 AS col0 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT - col0 * col1 + col2 AS col1 FROM tab1 cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-3485
SELECT + + 91 + + col1 DIV - col2 FROM tab0 AS cor0
----
-6
89
90

skipif mysql # not compatible
query I rowsort label-3485
SELECT + + 91 + + col1 / - col2 FROM tab0 AS cor0
----
-6
89
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + cor0.col0 ) + col2 col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT 16 * 96 FROM tab0
----
1536
1536
1536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + - col0 col1 FROM tab0 cor0
----
-132
-2862
-7551

query I rowsort
SELECT - - 13 * cor0.col1 * ( ( col2 ) ) AS col1 FROM tab1 cor0
----
16224
18252
7410

query I rowsort
SELECT ALL - col2 * - 23 * + ( - col1 ) + cor0.col0 AS col1 FROM tab1 AS cor0
----
-13046
-28624
-32289

query I rowsort
SELECT + col0 + col0 * col2 * - col2 FROM tab1 AS cor0
----
-207872
-737200
-8745

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3492
SELECT - + 96 * col2 * CAST( NULL AS SIGNED ) col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3492
SELECT - + 96 * col2 * CAST ( NULL AS INTEGER ) col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 29 * + col2 * col0 col1 FROM tab2
----
5481
58812
87058

query I rowsort
SELECT 6 * - 80 * - col1 + col2 FROM tab0
----
41313
43762
46561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + col2 col0 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-3496
SELECT DISTINCT - col2 + - cor0.col2 DIV 20 FROM tab0 AS cor0
----
-1
-34
-86

skipif mysql # not compatible
query I rowsort label-3496
SELECT DISTINCT - col2 + - cor0.col2 / 20 FROM tab0 AS cor0
----
-1
-34
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-3497
SELECT DISTINCT + ( - col2 ) + + col2 DIV col0 FROM tab0 AS cor0
----
-1
-32
-82

skipif mysql # not compatible
query I rowsort label-3497
SELECT DISTINCT + ( - col2 ) + + col2 / col0 FROM tab0 AS cor0
----
-1
-32
-82

query I rowsort
SELECT - - col2 + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - col2 + cor0.col1 * - 8 AS col2 FROM tab0 AS cor0
----
-721
-777
-810

query I rowsort
SELECT DISTINCT col2 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - 5 + + col1 * ( col1 ) FROM tab2 cor0
----
284
3476
956

onlyif mysql # use DIV operator for integer division
query I rowsort label-3502
SELECT ALL col1 + col0 DIV - ( cor0.col1 ) col1 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3502
SELECT ALL col1 + col0 / - ( cor0.col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + 7 * + col1 AS col2 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT DISTINCT 70 + col0 * cor0.col2 FROM tab1 AS cor0
----
232
3718
7750

query I rowsort
SELECT ALL ( cor0.col1 ) * col1 * ( - col0 ) FROM tab0 AS cor0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-3506
SELECT ALL col2 + + col1 * CAST( + col1 AS SIGNED ) DIV col0 AS col2 FROM tab2 cor0
----
164
41
70

skipif mysql # not compatible
query I rowsort label-3506
SELECT ALL col2 + + col1 * CAST ( + col1 AS INTEGER ) / col0 AS col2 FROM tab2 cor0
----
164
41
70

query I rowsort
SELECT col0 * + cor0.col2 + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col2 + col0 * col0 * 77 AS col1 FROM tab1 AS cor0
----
315449
492896
747

query I rowsort
SELECT 90 * + 61 FROM tab1, tab2 AS cor0
----
9 values hashing to cc40ec79000e7c4e3bf32bb9bd935319

query I rowsort
SELECT DISTINCT + + col0 * - 61 * col1 FROM tab0 AS cor0
----
-125904
-207095
-494039

query I rowsort
SELECT + col1 + ( col0 * + col1 ) FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - col2 + ( + 26 ) * + col2 FROM tab1 AS cor0
----
1350
1425
2400

query I rowsort
SELECT - col1 * 79 AS col1 FROM tab1 AS cor0
----
-1027
-2054
-790

query I rowsort
SELECT + col1 * col1 + - col2 * cor0.col2 FROM tab1 cor0
----
-2240
-3149
-9047

query I rowsort
SELECT col0 + + col1 * 31 * + col1 - - col1 FROM tab1 AS cor0
----
20985
3174
5332

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 + cor0.col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL col0 * + 79 + col1 * - col0 AS col2 FROM tab2 AS cor0
----
1560
336
4898

onlyif mysql # use DIV operator for integer division
query I rowsort label-3518
SELECT ALL - + ( 88 ) + + cor0.col2 DIV 75 + - 82 AS col0 FROM tab0 cor0
----
-169
-170
-170

skipif mysql # not compatible
query I rowsort label-3518
SELECT ALL - + ( 88 ) + + cor0.col2 / 75 + - 82 AS col0 FROM tab0 cor0
----
-169
-170
-170

query I rowsort
SELECT ALL + 59 + 29 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT ALL - + 93 + - col2 FROM tab2 AS cor0
----
-119
-120
-131

query I rowsort
SELECT cor0.col0 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT + + col0 * - 71 - - col0 FROM tab2 AS cor0
----
-490
-5460
-5530

query I rowsort
SELECT DISTINCT 11 FROM tab2 cor0
----
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3524
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab0, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3524
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab0, tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
7
78
79

query I rowsort
SELECT DISTINCT + col0 + 41 FROM tab0 AS cor0
----
130
65
76

query I rowsort
SELECT + col1 * cor0.col0 + + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - col2 * ( + col0 ) + + col1 - col2 AS col0 FROM tab2 cor0
----
-185
-1995
-3023

query I rowsort
SELECT ALL - + ( 58 ) - + col0 FROM tab0 AS cor0
----
-147
-82
-93

query I rowsort
SELECT + col1 + 24 AS col0 FROM tab2 AS cor0
----
41
55
83

query I rowsort
SELECT DISTINCT + - 96 * + ( col0 ) FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT ALL - col1 * + ( - col0 + - 7 ) AS col2 FROM tab0 AS cor0
----
2666
4074
8736

onlyif mysql # use DIV operator for integer division
query I rowsort label-3533
SELECT DISTINCT 33 DIV col0 AS col1 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-3533
SELECT DISTINCT 33 / col0 AS col1 FROM tab2 AS cor0
----
0
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3534
SELECT CAST( 82 AS SIGNED ) * col0 FROM tab1 cor0
----
246
5248
6560

skipif mysql # not compatible
query I rowsort label-3534
SELECT CAST ( 82 AS INTEGER ) * col0 FROM tab1 cor0
----
246
5248
6560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3535
SELECT + CAST( NULL AS SIGNED ) + col1 * + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3535
SELECT + CAST ( NULL AS INTEGER ) + col1 * + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3536
SELECT - 6 + + 34 + col1 DIV col0 AS col1 FROM tab1 AS cor0
----
28
28
36

skipif mysql # not compatible
query I rowsort label-3536
SELECT - 6 + + 34 + col1 / col0 AS col1 FROM tab1 AS cor0
----
28
28
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-3537
SELECT + col2 * + 89 * + col1 + + col2 DIV - 94 AS col1 FROM tab2 AS cor0
----
136526
57494
74493

skipif mysql # not compatible
query I rowsort label-3537
SELECT + col2 * + 89 * + col1 + + col2 / - 94 AS col1 FROM tab2 AS cor0
----
136526
57494
74493

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) * - col1 * - 9 AS col1 FROM tab2 cor0
----
-12087
-1953
-41418

query I rowsort
SELECT - ( col0 ) + - col0 - col2 AS col0 FROM tab1 AS cor0
----
-185
-256
-60

query I rowsort
SELECT ALL + col0 + col0 * col1 FROM tab0 cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-3541
SELECT - 39 DIV - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3541
SELECT - 39 / - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT cor0.col2 * - cor0.col1 + - col0 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ( col1 ) + + col0 + - col1 AS col2 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + cor0.col0 * + col2 col0 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT + col2 + 11 * col0 FROM tab2 AS cor0
----
104
884
907

query I rowsort
SELECT + col1 * - ( col2 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col0 * - cor0.col2 + col1 AS col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL col1 * + cor0.col0 * col2 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 6 col0 FROM tab0, tab1 AS cor0
----
6

query I rowsort
SELECT ALL + col2 + + 25 FROM tab0
----
107
26
58

query I rowsort
SELECT ALL col0 + ( + 51 ) * col2 AS col1 FROM tab0
----
1707
4271
86

query I rowsort
SELECT + col1 + tab2.col1 * col2 AS col1 FROM tab2
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-3553
SELECT + col2 DIV ( col0 * col1 ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3553
SELECT + col2 / ( col0 * col1 ) FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3554
SELECT ALL + col1 + CAST( col0 AS SIGNED ) FROM tab1
----
29
74
93

skipif mysql # not compatible
query I rowsort label-3554
SELECT ALL + col1 + CAST ( col0 AS INTEGER ) FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3555
SELECT col1 DIV 50 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3555
SELECT col1 / 50 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 col0 FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3557
SELECT + - col2 DIV + 88 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3557
SELECT + - col2 / + 88 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 * + 7 col2 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT cor0.col2 + col2 * + col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3560
SELECT + col2 * CAST( col2 + + col2 AS SIGNED ) DIV - col0 AS col1 FROM tab2 AS cor0
----
-17
-208
-36

skipif mysql # not compatible
query I rowsort label-3560
SELECT + col2 * CAST ( col2 + + col2 AS INTEGER ) / - col0 AS col1 FROM tab2 AS cor0
----
-17
-208
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-3561
SELECT DISTINCT - col1 + - col0 DIV - cor0.col1 AS col0 FROM tab2 AS cor0
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-3561
SELECT DISTINCT - col1 + - col0 / - cor0.col1 AS col0 FROM tab2 AS cor0
----
-13
-31
-58

query I rowsort
SELECT ALL cor1.col2 - - 35 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1577300a25402a11d4d2e788a38accf9

query I rowsort
SELECT DISTINCT col2 * - tab1.col1 AS col2 FROM tab1
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3564
SELECT - cor0.col2 * + col1 + + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-1152
-1350
-513

skipif mysql # not compatible
query I rowsort label-3564
SELECT - cor0.col2 * + col1 + + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 + + col1 col1 FROM tab0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3566
SELECT + col0 * tab0.col2 * col2 + - col0 DIV col0 AS col2 FROM tab0
----
26135
34
598435

skipif mysql # not compatible
query I rowsort label-3566
SELECT + col0 * tab0.col2 * col2 + - col0 / col0 AS col2 FROM tab0
----
26135
34
598435

query I rowsort
SELECT DISTINCT + tab2.col1 + + col2 * - col1 FROM tab2
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col2 + col2 * col1 col0 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT - col2 * + col0 * 84 AS col0 FROM tab1
----
-13608
-306432
-645120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3570
SELECT + - col0 * + col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3570
SELECT + - col0 * + col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + col2 + col2 + - col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT - 11 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-11

query I rowsort
SELECT - col0 * + 13 + + 97 * - col0 FROM tab2 AS cor0
----
-770
-8580
-8690

onlyif mysql # use DIV operator for integer division
query I rowsort label-3574
SELECT col2 DIV 97 + + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3574
SELECT col2 / 97 + + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + col2 - - 74 AS col0 FROM tab0 AS cor0
----
107
156
75

query I rowsort
SELECT DISTINCT - col0 * col0 + 29 * cor0.col2 + - 52 FROM tab1 AS cor0
----
-2495
-3668
1505

query I rowsort
SELECT DISTINCT 98 + - col0 FROM tab1
----
18
34
95

query I rowsort
SELECT DISTINCT - tab0.col1 * 25 AS col2 FROM tab0
----
-2150
-2275
-2425

query I rowsort
SELECT col1 * - col0 * + tab2.col0 AS col1 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT + col0 + + 11 * col2 FROM tab1
----
1136
597
691

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 39 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query I rowsort
SELECT ALL col0 * - col1 + 73 FROM tab0 AS cor0
----
-1991
-3322
-8026

onlyif mysql # use DIV operator for integer division
query I rowsort label-3583
SELECT + col0 DIV - col1 + col1 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-3583
SELECT + col0 / - col1 + col1 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT ALL + + col1 * col1 + + 11 FROM tab1 cor0
----
111
180
687

onlyif mysql # use DIV operator for integer division
query I rowsort label-3585
SELECT ALL col0 + col2 DIV + col1 + + col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-3585
SELECT ALL col0 + col2 / + col1 + + col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + 19 AS col0 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT ALL + col0 + col0 + - col1 FROM tab1 cor0
----
-20
118
147

query I rowsort
SELECT ALL 92 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT - col0 - 79 AS col1 FROM tab1
----
-143
-159
-82

query I rowsort
SELECT DISTINCT - + cor0.col1 FROM tab1, tab2, tab2 cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3591
SELECT DISTINCT - col1 DIV col0 - + col2 AS col0 FROM tab1
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-3591
SELECT DISTINCT - col1 / col0 - + col2 AS col0 FROM tab1
----
-57
-62
-96

query I rowsort
SELECT ALL 31 - + 72 AS col0 FROM tab2
----
-41
-41
-41

query I rowsort
SELECT DISTINCT 74 - - col0 AS col0 FROM tab2
----
152
153
81

query I rowsort
SELECT 28 * 84 AS col1 FROM tab2
----
2352
2352
2352

onlyif mysql # use DIV operator for integer division
query I rowsort label-3595
SELECT DISTINCT cor0.col1 - - tab1.col0 DIV tab1.col2 FROM tab1, tab0, tab1 cor0
----
10
11
13
14
26
27

skipif mysql # not compatible
query I rowsort label-3595
SELECT DISTINCT cor0.col1 - - tab1.col0 / tab1.col2 FROM tab1, tab0, tab1 cor0
----
10
11
13
14
26
27

query I rowsort
SELECT + 89 + cor0.col2 * col1 * 19 AS col2 FROM tab0 AS cor0
----
141867
1932
54011

onlyif mysql # use DIV operator for integer division
query I rowsort label-3597
SELECT 15 + col1 + + tab1.col1 DIV 30 AS col0 FROM tab1
----
25
28
41

skipif mysql # not compatible
query I rowsort label-3597
SELECT 15 + col1 + + tab1.col1 / 30 AS col0 FROM tab1
----
25
28
41

query I rowsort
SELECT ALL - col1 - - 81 FROM tab0
----
-10
-16
-5

query I rowsort
SELECT - cor0.col2 - - 82 FROM tab1 AS cor0
----
-14
25
28

query I rowsort
SELECT DISTINCT - col1 + col2 * col2 + col0 FROM tab0 cor0
----
-61
1027
6722

query I rowsort
SELECT - - 14 * - col1 + col2 FROM tab1 AS cor0
----
-310
-83
-86

query I rowsort
SELECT DISTINCT - - col1 * col1 + 91 AS col1 FROM tab1 AS cor0
----
191
260
767

query I rowsort
SELECT ALL + ( - col0 ) + col0 * - col0 AS col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT - - col2 * + col0 + + col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL 39 * col0 - + cor0.col1 AS col1 FROM tab1 AS cor0
----
2486
3107
91

query I rowsort
SELECT DISTINCT - 20 + col2 * + col1 * 94 FROM tab2 cor0
----
144176
60704
78658

query I rowsort
SELECT + col0 - col0 * + ( col1 ) FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - col0 + cor0.col0 * + 39 AS col2 FROM tab1 AS cor0
----
114
2432
3040

query I rowsort
SELECT ALL + 45 * - col2 * col2 AS col1 FROM tab0 AS cor0
----
-302580
-45
-49005

query I rowsort
SELECT ALL - 55 - + col2 * 89 AS col1 FROM tab1 AS cor0
----
-4861
-5128
-8599

onlyif mysql # use DIV operator for integer division
query I rowsort label-3611
SELECT - col2 + - col0 DIV - col1 FROM tab2 cor0
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-3611
SELECT - col2 + - col0 / - col1 FROM tab2 cor0
----
-25
-27
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - col0 + + col0 col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT - col1 + - col0 * - tab2.col1 AS col2 FROM tab2
----
1326
186
4543

query I rowsort
SELECT + - cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE ( cor0.col1 ) <> col2 OR ( col1 * + col2 ) NOT IN ( cor0.col0 * col2 + - col2 * + col1 + + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT ( NULL ) <= + col1 OR NOT NULL <= NULL
----

query I rowsort
SELECT DISTINCT tab0.col1 * tab0.col2 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + col1 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 12 + + cor0.col2 * col1 + col0 FROM tab1 cor0
----
1340
1419
646

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3621
SELECT ALL + - col0 DIV col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-3621
SELECT ALL + - col0 / col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT ALL - col2 + col2 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - - col1 + + col1 + - col0 AS col1 FROM tab1 cor0
----
-44
-54
49

query I rowsort
SELECT 10 * tab1.col2 + - col1 FROM tab1
----
514
560
947

query I rowsort
SELECT col0 * col2 + col0 AS col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT DISTINCT ( col0 + col0 ) AS col1 FROM tab1
----
128
160
6

query I rowsort
SELECT col2 * + col0 - - col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT col0 + + col0 - col2 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT ALL - + col1 * col1 * col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT + col0 * - col2 + cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
-131
-1943
-2947

query I rowsort
SELECT col1 + col2 * col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-3632
SELECT DISTINCT - col0 + col2 DIV - col0 + + cor0.col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-3632
SELECT DISTINCT - col0 + col2 / - col0 + + cor0.col0 FROM tab2 AS cor0
----
-3
0

query I rowsort
SELECT DISTINCT col0 + - col1 * col2 * - col0 AS col1 FROM tab0
----
3430
664207
68136

query I rowsort
SELECT + ( + col0 ) * col2 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - cor0.col0 + col2 * col2 - - col0 AS col0 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - col2 * col0 * col2 + + col1 * col1 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
-206936
-735083
8828

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL BETWEEN ( + col0 ) AND NULL
----

query I rowsort
SELECT - col2 * - tab1.col1 + - col1 FROM tab1
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3639
SELECT + col0 DIV - col0 + - tab0.col2 AS col2 FROM tab0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3639
SELECT + col0 / - col0 + - tab0.col2 AS col2 FROM tab0
----
-2
-34
-83

query III rowsort
SELECT * FROM tab0 WHERE + col0 + col1 <> col1
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3641
SELECT DISTINCT - col0 + col1 - col1 DIV col1 AS col1 FROM tab0
----
1
61

skipif mysql # not compatible
query I rowsort label-3641
SELECT DISTINCT - col0 + col1 - col1 / col1 AS col1 FROM tab0
----
1
61

query I rowsort
SELECT ALL col2 * tab2.col0 + - col0 + + col1 FROM tab2
----
2009
213
2940

query I rowsort
SELECT + col0 * col1 * + col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT + col2 - + col1 * + tab0.col1 * col2 FROM tab0
----
-244035
-678960
-9408

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( col1 / + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3646
SELECT col0 * col0 DIV col0 + - col0 * tab2.col2 FROM tab2
----
-182
-1950
-2923

skipif mysql # not compatible
query I rowsort label-3646
SELECT col0 * col0 / col0 + - col0 * tab2.col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT tab0.col1 * col1 + + col2 * + col1 AS col0 FROM tab0
----
10234
15743
9506

query III rowsort
SELECT * FROM tab2 WHERE col1 < tab2.col1 + - col1
----

query I rowsort
SELECT - col1 + + tab1.col2 * - col1 FROM tab1
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-3650
SELECT - col2 DIV - col1 - col1 AS col2 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3650
SELECT - col2 / - col1 - col1 AS col2 FROM tab0
----
-86
-91
-97

query III rowsort
SELECT * FROM tab0 WHERE + col1 NOT IN ( col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT tab2.col0 + col2 + - col2 FROM tab2
----
7
78
79

query I rowsort
SELECT + col2 * col1 * col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT col1 + tab1.col0 * - col2 AS col1 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-3655
SELECT DISTINCT + col2 * + col2 + + col2 DIV - col1 FROM tab2
----
1442
676
729

skipif mysql # not compatible
query I rowsort label-3655
SELECT DISTINCT + col2 * + col2 + + col2 / - col1 FROM tab2
----
1442
676
729

query I rowsort
SELECT DISTINCT col2 * col0 FROM tab2 WHERE NULL <> NULL
----

query I rowsort
SELECT ALL + col0 * col0 + col2 * col1 FROM tab2
----
6887
7618
886

query I rowsort
SELECT col1 * - tab0.col2 * + col2 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT - col1 + - col2 * + col2 + col2 FROM tab1
----
-2888
-3202
-9133

onlyif mysql # use DIV operator for integer division
query I rowsort label-3660
SELECT - col0 DIV + tab1.col0 + + col1 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3660
SELECT - col0 / + tab1.col0 + + col1 FROM tab1
----
12
25
9

query I rowsort
SELECT ALL col1 + + tab0.col1 + col0 * col1 AS col1 FROM tab0
----
2236
3589
8281

query I rowsort
SELECT - col2 * col0 * + col0 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3663
SELECT col2 * + col0 DIV col0 AS col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3663
SELECT col2 * + col0 / col0 AS col2 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3664
SELECT ALL - tab1.col1 DIV - col1 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3664
SELECT ALL - tab1.col1 / - col1 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT - - col0 + + cor0.col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - tab1.col1 - col1 AS col2 FROM tab1 WHERE NULL IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3667
SELECT ALL + - col0 - - col0 DIV - col1 AS col0 FROM tab2 AS cor0
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-3667
SELECT ALL + - col0 - - col0 / - col1 AS col0 FROM tab2 AS cor0
----
-7
-79
-83

query I rowsort
SELECT DISTINCT - + col1 * cor0.col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - col1 * col2 - + col0 * col0 FROM tab0 AS cor0
----
-1322
-15383
-3414

query I rowsort
SELECT ALL - col0 + col0 + + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL col0 * - col2 - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE + col0 <= col1
----
3
26
54

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT col2 IN ( - col2 - + col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col1 AS col2 FROM tab2 cor0 WHERE NULL NOT IN ( col2 )
----

query I rowsort
SELECT ALL + cor1.col2 AS col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + 3 + + 8 FROM tab2 AS cor0
----
11
11
11

query I rowsort
SELECT + col0 + 28 AS col0 FROM tab2 AS cor0
----
106
107
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3678
SELECT - 22 + + col1 * col2 DIV col2 FROM tab0 AS cor0
----
64
69
75

skipif mysql # not compatible
query I rowsort label-3678
SELECT - 22 + + col1 * col2 / col2 FROM tab0 AS cor0
----
64
69
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + + col1 * + col2 * - 69 col2 FROM tab2 cor0
----
-105872
-44612
-57780

query I rowsort
SELECT DISTINCT 96 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
96

query I rowsort
SELECT DISTINCT + col1 * col0 - - col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT col1 + 51 FROM tab1 cor0
----
61
64
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3683
SELECT - cor0.col0 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3683
SELECT - cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + + 24 - tab1.col1 AS col2 FROM tab1
----
-43
-56
-85

query I rowsort
SELECT col2 * - ( col1 ) + col0 + ( col2 ) * + col0 FROM tab0 cor0
----
-2022
-27
-75

query I rowsort
SELECT tab1.col0 * - 68 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 28fcdf35d3ccbfa5d8b94ab94827a753

query I rowsort
SELECT - + cor0.col0 + 13 * + col1 + - col0 AS col0 FROM tab0 AS cor0
----
1005
1070
1191

query I rowsort
SELECT ALL + cor0.col1 * + col0 + col2 - - 91 FROM tab1 AS cor0
----
1227
223
788

query I rowsort
SELECT + col0 * + 36 FROM tab1
----
108
2304
2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3690
SELECT ALL col2 * - CAST( col1 AS SIGNED ) AS col2 FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-3690
SELECT ALL col2 * - CAST ( col1 AS INTEGER ) AS col2 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - 48 * - 8 col0 FROM tab0
----
12672
31488
384

query I rowsort
SELECT - tab2.col0 * + 29 AS col2 FROM tab2
----
-203
-2262
-2291

query I rowsort
SELECT ( - col1 ) + col0 AS col1 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3694
SELECT + - CAST( - col1 AS SIGNED ) * col2 + CAST( - col1 + - col1 AS SIGNED ) FROM tab1 AS cor0
----
1222
1352
550

skipif mysql # not compatible
query I rowsort label-3694
SELECT + - CAST ( - col1 AS INTEGER ) * col2 + CAST ( - col1 + - col1 AS INTEGER ) FROM tab1 AS cor0
----
1222
1352
550

onlyif mysql # use DIV operator for integer division
query I rowsort label-3695
SELECT DISTINCT - - col1 DIV - col0 + + col1 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-3695
SELECT DISTINCT - - col1 / - col0 + + col1 col2 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT ALL + ( - col0 ) * col0 * col0 + 39 FROM tab0 AS cor0
----
-13785
-42836
-704930

query I rowsort
SELECT ALL 23 AS col1 FROM tab1 cor0
----
23
23
23

query I rowsort
SELECT ALL - + col2 * - col0 * - col0 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - 60 AS REAL ) + col1 col0 FROM tab0
----
26
31
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-3700
SELECT ALL - col2 + - col0 DIV - tab1.col2 AS col2 FROM tab1
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-3700
SELECT ALL - col2 + - col0 / - tab1.col2 AS col2 FROM tab1
----
-54
-56
-96

query I rowsort
SELECT + 67 AS col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT + col1 * col1 + - col2 AS col1 FROM tab2
----
251
3455
934

query I rowsort
SELECT ALL + cor0.col2 + + ( - 94 ) FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to be5d6f82996cc0399048fec420095c30

query I rowsort
SELECT cor0.col1 + 63 FROM tab0, tab1 AS cor0
----
9 values hashing to 74dfe1da4bd9c7556b74acd85d98eb6c

query I rowsort
SELECT DISTINCT - + 3 + 73 + cor0.col1 FROM tab0, tab2, tab0 cor0
----
156
161
167

query I rowsort
SELECT ALL - 19 * + ( col0 ) + + col0 AS col2 FROM tab1
----
-1152
-1440
-54

onlyif mysql # use DIV operator for integer division
query I rowsort label-3707
SELECT DISTINCT + + cor0.col1 DIV - ( col1 ) + col2 + col1 AS col0 FROM tab2 AS cor0
----
54
57
84

skipif mysql # not compatible
query I rowsort label-3707
SELECT DISTINCT + + cor0.col1 / - ( col1 ) + col2 + col1 AS col0 FROM tab2 AS cor0
----
54
57
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 78 + - col0 - cor0.col2 col1 FROM tab1 AS cor0
----
4155
4325
7312

query I rowsort
SELECT col2 * col1 + col1 AS col1 FROM tab0 cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3710
SELECT ALL - col1 + - col2 DIV col0 AS col2 FROM tab0 AS cor0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-3710
SELECT ALL - col1 + - col2 / col0 AS col2 FROM tab0 AS cor0
----
-87
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3711
SELECT - tab0.col2 DIV + col2 + + ( - col1 ) FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-3711
SELECT - tab0.col2 / + col2 + + ( - col1 ) FROM tab0
----
-87
-92
-98

query I rowsort
SELECT + + col1 + + col2 * 31 AS col2 FROM tab0 AS cor0
----
1109
128
2633

query I rowsort
SELECT - - col0 * + ( col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + ( 20 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + - 42 col1 FROM tab0 AS cor0
----
-131
-66
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + 77 col0 FROM tab2 AS cor0
----
-1
-2
70

query I rowsort
SELECT ALL + cor0.col0 - + col2 AS col2 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3718
SELECT DISTINCT col2 + cor0.col1 DIV col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-3718
SELECT DISTINCT col2 + cor0.col1 / col2 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT DISTINCT - col0 * 59 + + col0 + cor0.col2 FROM tab0 AS cor0
----
-1359
-2029
-5080

onlyif mysql # use DIV operator for integer division
query I rowsort label-3720
SELECT ALL - col0 DIV col0 + + col2 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-3720
SELECT ALL - col0 / col0 + + col2 FROM tab0
----
0
32
81

query I rowsort
SELECT DISTINCT 93 FROM tab2, tab0, tab2 cor0
----
93

query I rowsort
SELECT DISTINCT + - col1 + + col2 * - col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT + col1 + - cor0.col0 * 61 AS col1 FROM tab2 AS cor0
----
-396
-4699
-4802

query I rowsort
SELECT col2 * col2 * col1 + - 86 + - col1 AS col1 FROM tab2 AS cor0
----
22482
24445
39739

query I rowsort
SELECT + 2 * + col0 AS col1 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3726
SELECT ALL col1 + - col2 DIV + ( - col1 ) AS col1 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-3726
SELECT ALL col1 + - col2 / + ( - col1 ) AS col1 FROM tab2 AS cor0
----
19
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3727
SELECT col2 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3727
SELECT col2 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 - - col2 * - col2 * + col2 FROM tab2 AS cor0
----
-17550
-19656
-54834

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3729
SELECT - col0 + CAST( - 56 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
-1031
-1743
-3382

skipif mysql # not compatible
query I rowsort label-3729
SELECT - col0 + CAST ( - 56 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
-1031
-1743
-3382

query I rowsort
SELECT ALL + col0 * - 91 FROM tab2 AS cor0
----
-637
-7098
-7189

onlyif mysql # use DIV operator for integer division
query I rowsort label-3731
SELECT col2 DIV + col0 + + 59 + + col2 FROM tab1 AS cor0
----
116
131
156

skipif mysql # not compatible
query I rowsort label-3731
SELECT col2 / + col0 + + 59 + + col2 FROM tab1 AS cor0
----
116
131
156

query I rowsort
SELECT DISTINCT + col1 * - col0 * col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3733
SELECT + + col1 + - col1 * + ( - cor0.col2 ) * CAST( NULL AS SIGNED ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3733
SELECT + + col1 + - col1 * + ( - cor0.col2 ) * CAST ( NULL AS INTEGER ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 24 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

onlyif mysql # use DIV operator for integer division
query I rowsort label-3735
SELECT ALL + col2 DIV - col0 + 50 * 91 AS col2 FROM tab2
----
4547
4550
4550

skipif mysql # not compatible
query I rowsort label-3735
SELECT ALL + col2 / - col0 + 50 * 91 AS col2 FROM tab2
----
4547
4550
4550

query I rowsort
SELECT + col0 * col2 * cor0.col2 + col0 AS col0 FROM tab0 cor0
----
26160
598525
70

query I rowsort
SELECT ALL col2 * + ( col2 ) AS col1 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col0 FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT - - 88 * - col1 * + col1 FROM tab2 AS cor0
----
-25432
-306328
-84568

query I rowsort
SELECT ALL + 21 * - col1 * + col0 FROM tab0 cor0
----
-170079
-43344
-71295

query I rowsort
SELECT col2 * - 73 AS col2 FROM tab1 AS cor0
----
-3942
-4161
-7008

query I rowsort
SELECT DISTINCT 56 + col0 AS col1 FROM tab1 cor0
----
120
136
59

query I rowsort
SELECT - col2 + 44 FROM tab2 cor0
----
17
18
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3744
SELECT ALL - cor0.col1 + col2 DIV col1 FROM tab1 AS cor0
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-3744
SELECT ALL - cor0.col1 + col2 / col1 FROM tab1 AS cor0
----
-24
-5
-6

query I rowsort
SELECT - - 83 * 83 FROM tab1 AS cor0
----
6889
6889
6889

query I rowsort
SELECT DISTINCT - col1 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3747
SELECT DISTINCT + CAST( col2 AS SIGNED ) * cor0.col2 * 58 + - col2 FROM tab0 AS cor0
----
389910
57
63129

skipif mysql # not compatible
query I rowsort label-3747
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * cor0.col2 * 58 + - col2 FROM tab0 AS cor0
----
389910
57
63129

onlyif mysql # use DIV operator for integer division
query I rowsort label-3748
SELECT DISTINCT 3 - + 76 DIV + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
-73
1
3

skipif mysql # not compatible
query I rowsort label-3748
SELECT DISTINCT 3 - + 76 / + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
-73
1
3

query I rowsort
SELECT DISTINCT + col1 * + 82 AS col0 FROM tab1 AS cor0
----
1066
2132
820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 72 col1 FROM tab2 AS cor0
----
-72
-72
-72

query I rowsort
SELECT 44 * + col2 AS col0 FROM tab2 AS cor0
----
1144
1188
1672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3752
SELECT DISTINCT + CAST( NULL AS SIGNED ) / tab0.col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3752
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / tab0.col2 FROM tab0
----
NULL

query I rowsort
SELECT ( col2 ) + - tab0.col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + 60 * col2 * + col0 FROM tab2
----
11340
121680
180120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3755
SELECT ALL CAST( - col1 AS SIGNED ) col1 FROM tab2
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3755
SELECT ALL CAST ( - col1 AS INTEGER ) col1 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT ( 90 ) FROM tab1
----
90
90
90

query I rowsort
SELECT + ( col0 ) + col2 * + ( tab2.col2 ) FROM tab2
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-3758
SELECT 62 + + col2 DIV col1 FROM tab1
----
64
67
69

skipif mysql # not compatible
query I rowsort label-3758
SELECT 62 + + col2 / col1 FROM tab1
----
64
67
69

query I rowsort
SELECT DISTINCT col2 + ( col0 * col0 ) AS col1 FROM tab1
----
4153
63
6496

query I rowsort
SELECT - 2 FROM tab0, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT ALL + + col1 - - 0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + - col2 + col0 * - col0 * col0 FROM tab1 cor0
----
-262201
-512096
-81

query I rowsort
SELECT DISTINCT + col2 * + col1 + - col2 AS col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL + + ( col2 ) + col0 * + ( col2 ) FROM tab1 AS cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 23 col2 FROM tab2 AS cor0
----
101
102
30

query I rowsort
SELECT + cor0.col2 * + cor0.col2 + - col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT ALL + cor0.col2 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

onlyif mysql # use DIV operator for integer division
query I rowsort label-3769
SELECT ALL col0 * + col1 DIV ( + col1 ) AS col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3769
SELECT ALL col0 * + col1 / ( + col1 ) AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT + + col2 * col0 + col2 * + col0 * col2 AS col0 FROM tab0 AS cor0
----
26928
605734
70

query I rowsort
SELECT ALL + col1 + + col2 * cor0.col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3772
SELECT DISTINCT + col2 + - CAST( NULL AS SIGNED ) * - cor0.col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3772
SELECT DISTINCT + col2 + - CAST ( NULL AS INTEGER ) * - cor0.col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3773
SELECT col0 * col2 DIV 90 + - col2 FROM tab1 AS cor0
----
-11
-17
-53

skipif mysql # not compatible
query I rowsort label-3773
SELECT col0 * col2 / 90 + - col2 FROM tab1 AS cor0
----
-11
-17
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-3774
SELECT DISTINCT col1 * ( col2 ) + + col2 DIV - ( col0 ) FROM tab1 AS cor0
----
1247
1386
570

skipif mysql # not compatible
query I rowsort label-3774
SELECT DISTINCT col1 * ( col2 ) + + col2 / - ( col0 ) FROM tab1 AS cor0
----
1247
1386
570

query I rowsort
SELECT ALL + cor0.col1 * 37 AS col2 FROM tab2 AS cor0
----
1147
2183
629

query I rowsort
SELECT DISTINCT ( col1 ) - - 10 AS col1 FROM tab0
----
101
107
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 72 + - col2 - + col1 * - 77 col1 FROM tab2
----
1199
2288
4445

query I rowsort
SELECT 17 + col2 * + col1 AS col0 FROM tab1
----
1265
1421
587

query I rowsort
SELECT ALL + + cor0.col1 AS col2 FROM tab2, tab0, tab2 AS cor0, tab1
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT DISTINCT col2 DIV col1 - + 61 AS col2 FROM tab0
----
-61

skipif mysql # not compatible
query I rowsort label-3780
SELECT DISTINCT col2 / col1 - + 61 AS col2 FROM tab0
----
-61

query I rowsort
SELECT col1 + 32 AS col0 FROM tab0
----
118
123
129

query I rowsort
SELECT ALL tab0.col0 + - 14 FROM tab0, tab2 AS cor0
----
9 values hashing to 7bde97be6f2f8313ff5b845188555177

query I rowsort
SELECT + col1 + col1 * + col2 AS col1 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT - col1 * + ( - 71 ) + col0 * 54 FROM tab2 AS cor0
----
2579
5473
8401

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3785
SELECT + col1 + + CAST( + col2 AS SIGNED ) * + col0 * - col0 FROM tab0 AS cor0
----
-1128
-18922
-649431

skipif mysql # not compatible
query I rowsort label-3785
SELECT + col1 + + CAST ( + col2 AS INTEGER ) * + col0 * - col0 FROM tab0 AS cor0
----
-1128
-18922
-649431

query I rowsort
SELECT + + col0 + - col0 * + col0 AS col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT col0 * + ( - ( col2 ) * - col2 ) AS col1 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + - col0 * 90 FROM tab0 AS cor0
----
-2160
-3150
-8010

query I rowsort
SELECT + + 90 * col2 FROM tab0 AS cor0
----
2970
7380
90

query I rowsort
SELECT - - 89 + + col1 FROM tab1 AS cor0
----
102
115
99

query I rowsort
SELECT ALL 93 - col0 AS col1 FROM tab1
----
13
29
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3792
SELECT col1 * - col1 + - CAST( col1 AS SIGNED ) + - col2 FROM tab1
----
-167
-278
-756

skipif mysql # not compatible
query I rowsort label-3792
SELECT col1 * - col1 + - CAST ( col1 AS INTEGER ) + - col2 FROM tab1
----
-167
-278
-756

query I rowsort
SELECT + - 57 FROM tab1 AS cor0
----
-57
-57
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3794
SELECT DISTINCT + + ( col2 ) * col2 + - 9 DIV col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-3794
SELECT DISTINCT + + ( col2 ) * col2 + - 9 / col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + 72 * + cor1.col2 AS col0 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7d4ec77d4c9012b9f428488f271ccb63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3796
SELECT DISTINCT + cor0.col0 * col2 / - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3796
SELECT DISTINCT + cor0.col0 * col2 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3797
SELECT DISTINCT - - col1 * col1 + CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
7310
8190
9312

skipif mysql # not compatible
query I rowsort label-3797
SELECT DISTINCT - - col1 * col1 + CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
7310
8190
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * cor0.col2 col0 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - 29 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-290
-377
-754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3800
SELECT DISTINCT + - col2 * col1 + CAST( + cor0.col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-3800
SELECT DISTINCT + - col2 * col1 + CAST ( + cor0.col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col2 * + 6 * + 43 col1 FROM tab2 AS cor0
----
6734
6993
9842

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col0 ) + - col0 * + col2 col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL + + col2 - + col2 * col0 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-3804
SELECT DISTINCT col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3804
SELECT DISTINCT col1 / - col1 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT cor0.col2 * col0 * col2 + col2 + + 81 FROM tab1 AS cor0
----
208074
737457
8883

query I rowsort
SELECT - - col1 * - ( + 79 ) + - col1 * + cor0.col1 FROM tab1 AS cor0
----
-1196
-2730
-890

query I rowsort
SELECT col2 + + col1 * col1 AS col1 FROM tab0 cor0
----
7429
8363
9410

query I rowsort
SELECT ALL col0 + 88 FROM tab1 AS cor0
----
152
168
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3809
SELECT + col1 + + CAST( + ( - col2 ) AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-3809
SELECT + col1 + + CAST ( + ( - col2 ) AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col1 * 32 + - col0 * - col1 FROM tab0 AS cor0
----
-688
291
5187

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3811
SELECT DISTINCT - col0 * CAST( NULL AS SIGNED ) + + col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3811
SELECT DISTINCT - col0 * CAST ( NULL AS INTEGER ) + + col2 FROM tab1 cor0
----
NULL

query I rowsort
SELECT - - cor0.col0 + ( col1 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - col1 + col1 * + col1 + ( + col1 ) * col2 * cor0.col0 FROM tab1 AS cor0
----
36570
4862
99996

query I rowsort
SELECT cor0.col2 FROM tab1, tab0 cor0, tab0 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-3815
SELECT - - col1 + col0 DIV col1 AS col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-3815
SELECT - - col1 + col0 / col1 AS col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT - cor0.col0 * - 40 FROM tab1 cor0
----
120
2560
3200

query I rowsort
SELECT 94 * + col2 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT cor0.col1 AS col2 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 86 + col1 * + col0 col2 FROM tab2 AS cor0
----
1429
303
4688

query I rowsort
SELECT DISTINCT ( + 16 ) AS col2 FROM tab0 AS cor0
----
16

query I rowsort
SELECT ( + col0 + col2 ) FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT - + cor0.col0 + col0 * + 53 * + col0 FROM tab0 AS cor0
----
30504
419724
64890

query I rowsort
SELECT - 72 + - cor0.col0 * col0 FROM tab0 AS cor0
----
-1297
-648
-7993

query I rowsort
SELECT ALL col1 * - 0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - 59 * col1 AS col2 FROM tab0
----
-5074
-5369
-5723

query I rowsort
SELECT 21 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 93ed44f621cc970f32b0cc9543b45262

query I rowsort
SELECT DISTINCT + col2 * 77 AS col2 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT - col2 - - col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL 29 + ( col1 ) FROM tab0
----
115
120
126

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0 WHERE NULL > NULL
----

query I rowsort
SELECT 52 + + col2 AS col0 FROM tab0 AS cor0
----
134
53
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 42 col1 FROM tab2 AS cor0
----
42
42
42

query I rowsort
SELECT ALL - 16 * + col0 FROM tab2
----
-112
-1248
-1264

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 - - ( col2 + + col2 ) col0 FROM tab1 AS cor0
----
181
188
301

onlyif mysql # use DIV operator for integer division
query I rowsort label-3836
SELECT - col2 DIV + col2 + + ( - col2 ) FROM tab1 cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-3836
SELECT - col2 / + col2 + + ( - col2 ) FROM tab1 cor0
----
-55
-58
-97

query I rowsort
SELECT ALL 9 + col1 FROM tab1 AS cor0
----
19
22
35

query I rowsort
SELECT DISTINCT - col0 * - col0 + + 75 * - col2 FROM tab1 AS cor0
----
-179
-4041
-800

query I rowsort
SELECT - - cor0.col0 * - col1 + ( + col2 * + col0 + + ( + col1 ) ) FROM tab0 AS cor0
----
-1186
-3263
-710

query I rowsort
SELECT DISTINCT - - col0 * - col0 + 54 AS col1 FROM tab0 AS cor0
----
-1171
-522
-7867

query I rowsort
SELECT ALL + col2 * + cor0.col2 * col0 + col0 FROM tab2 AS cor0
----
114155
5110
52806

query I rowsort
SELECT DISTINCT - col2 - ( - col1 * - col0 + + 70 * + 74 ) AS col1 FROM tab0 AS cor0
----
-13361
-7277
-8576

onlyif mysql # use DIV operator for integer division
query I rowsort label-3843
SELECT + - cor0.col0 + + 48 DIV col0 AS col2 FROM tab2 AS cor0
----
-1
-78
-79

skipif mysql # not compatible
query I rowsort label-3843
SELECT + - cor0.col0 + + 48 / col0 AS col2 FROM tab2 AS cor0
----
-1
-78
-79

query I rowsort
SELECT ALL col0 * col1 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + cor0.col0 - col0 col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT - - col1 - ( cor0.col1 ) FROM tab0 cor0
----
0

query I rowsort
SELECT col0 * col1 + + 19 AS col2 FROM tab1 cor0
----
1059
659
97

query I rowsort
SELECT ALL + - cor0.col2 + + 77 AS col0 FROM tab2 AS cor0
----
39
50
51

query I rowsort
SELECT DISTINCT col2 + - 31 * - col1 AS col0 FROM tab1 AS cor0
----
367
499
860

query I rowsort
SELECT + col0 * + col1 + cor0.col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + 46 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-3852
SELECT - - cor0.col0 + ( cor0.col2 + col1 ) DIV + col1 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-3852
SELECT - - cor0.col0 + ( cor0.col2 + col1 ) / + col1 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 34 * tab1.col2 col1 FROM tab1, tab0 cor0
----
9 values hashing to 23fedc40049c1ea7a6d41a9b8d3ad5ae

query I rowsort
SELECT ALL col1 * + ( - ( + col2 ) ) + + 28 AS col1 FROM tab1
----
-1220
-1376
-542

query I rowsort
SELECT - col1 + 44 FROM tab0 AS cor0
----
-42
-47
-53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3856
SELECT + cor0.col1 + + CAST( NULL AS SIGNED ) / - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3856
SELECT + cor0.col1 + + CAST ( NULL AS INTEGER ) / - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3857
SELECT + col2 + CAST( NULL AS DECIMAL ) * + col0 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-3857
SELECT + col2 + CAST ( NULL AS REAL ) * + col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col1 * 62 + - col0 * - col0 + + col2 FROM tab1 cor0
----
1675
4773
7302

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3859
SELECT DISTINCT - 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-3859
SELECT DISTINCT - CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - col2 + + cor0.col1 * col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT - 6 * 56 AS col0 FROM tab0 AS cor0
----
-336
-336
-336

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab1, tab0, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - 61 * + cor0.col0 - + col1 FROM tab1 AS cor0
----
-209
-3914
-4893

onlyif mysql # use DIV operator for integer division
query I rowsort label-3864
SELECT + ( col2 ) DIV col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-3864
SELECT + ( col2 ) / col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL 37 + + col2 * col0 FROM tab1
----
199
3685
7717

query I rowsort
SELECT - col1 * col2 * col2 + 67 * col2 - + cor0.col1 FROM tab0 AS cor0
----
-127
-606481
-91529

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col0 col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3868
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col1 * col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3868
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col1 * col0 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT col1 + 28 FROM tab1
----
38
41
54

query I rowsort
SELECT + + 65 + cor0.col1 + + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 42b5b7d29d30748e1977ecbc17f9e19d

query I rowsort
SELECT + col2 * - 98 * col0 FROM tab1 cor0
----
-15876
-357504
-752640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 74 col1 FROM tab1 AS cor0
----
74
74
74

query I rowsort
SELECT col1 + cor0.col0 * + col2 AS col1 FROM tab2 cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 64 col2 FROM tab2
----
64
64
64

query I rowsort
SELECT ALL - 32 * cor0.col2 * col2 AS col2 FROM tab2 AS cor0
----
-21632
-23328
-46208

query I rowsort
SELECT ALL + 64 AS col2 FROM tab2 AS cor0
----
64
64
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3877
SELECT DISTINCT + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3877
SELECT DISTINCT + CAST ( NULL AS REAL ) AS col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL - + 22 * col0 * col2 FROM tab1 cor0
----
-168960
-3564
-80256

query I rowsort
SELECT + ( 62 ) AS col1 FROM tab2 AS cor0
----
62
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3880
SELECT + + CAST( col0 AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3880
SELECT + + CAST ( col0 AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - ( ( col0 ) ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - col0 * ( col1 ) FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3883
SELECT tab2.col1 + + cor0.col0 * ( cor0.col1 ) DIV - tab2.col0 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to d0235c18f825ac4150bb86bdce161d20

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3883
SELECT tab2.col1 + + cor0.col0 * ( cor0.col1 ) / - tab2.col0 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to d0235c18f825ac4150bb86bdce161d20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3884
SELECT - + col0 DIV cor0.col0 + + col0 + col2 * col0 AS col0 FROM tab2 AS cor0
----
195
2105
3080

skipif mysql # not compatible
query I rowsort label-3884
SELECT - + col0 / cor0.col0 + + col0 + col2 * col0 AS col0 FROM tab2 AS cor0
----
195
2105
3080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * - col2 + col0 + - col1 col0 FROM tab1 AS cor0
----
-2939
-3195
-9149

query I rowsort
SELECT ALL + tab2.col1 - - tab2.col1 FROM tab2
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3887
SELECT + col1 + - CAST( NULL AS SIGNED ) / col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3887
SELECT + col1 + - CAST ( NULL AS INTEGER ) / col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - col1 + - 94 AS col2 FROM tab1
----
-194
-263
-770

query I rowsort
SELECT ALL 65 FROM tab1, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

onlyif mysql # use DIV operator for integer division
query I rowsort label-3890
SELECT - col0 DIV + 25 + + col2 AS col1 FROM tab0
----
0
33
79

skipif mysql # not compatible
query I rowsort label-3890
SELECT - col0 / + 25 + + col2 AS col1 FROM tab0
----
0
33
79

query I rowsort
SELECT col0 * tab1.col1 + - 10 FROM tab1
----
1030
630
68

query I rowsort
SELECT DISTINCT col0 * 36 + 91 AS col0 FROM tab1 cor0
----
199
2395
2971

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3893
SELECT DISTINCT col0 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3893
SELECT DISTINCT col0 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 * - col0 col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT col2 * + 40 FROM tab2 AS cor0
----
1040
1080
1520

query I rowsort
SELECT ALL + 68 FROM tab1, tab1 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT DISTINCT - + 84 - 57 FROM tab2 AS cor0
----
-141

query I rowsort
SELECT DISTINCT + + ( + col0 ) * - col0 + - col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-4196
-6569
-685

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3899
SELECT ALL CAST( - ( col0 ) AS SIGNED ) AS col1 FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3899
SELECT ALL CAST ( - ( col0 ) AS INTEGER ) AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + - 42 FROM tab0 cor0
----
-42
-42
-42

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
17
31
59

query I rowsort
SELECT col0 - col0 * + ( 6 ) AS col0 FROM tab1
----
-15
-320
-400

query I rowsort
SELECT ALL + col2 + - col1 * - col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT - 92 + + col0 AS col0 FROM tab2 AS cor0
----
-13
-14
-85

query I rowsort
SELECT DISTINCT - - col1 * col0 * col1 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3906
SELECT DISTINCT + - 52 * col0 + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3906
SELECT DISTINCT + - 52 * col0 + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col1 + col1 * 63 AS col2 FROM tab2 AS cor0
----
1088
1984
3776

query I rowsort
SELECT DISTINCT + - col0 * 20 FROM tab2 cor0
----
-140
-1560
-1580

query I rowsort
SELECT ALL - col2 + 12 AS col2 FROM tab0 AS cor0
----
-21
-70
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-3910
SELECT - - col0 * col2 * - col1 + cor0.col0 DIV col0 FROM tab0 cor0
----
-3394
-664117
-68111

skipif mysql # not compatible
query I rowsort label-3910
SELECT - - col0 * col2 * - col1 + cor0.col0 / col0 FROM tab0 cor0
----
-3394
-664117
-68111

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - - col2 + 84 * col0 FROM tab2 cor0
----
615
6578
6674

query I rowsort
SELECT + col0 * + col0 + col1 AS col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT - - col2 * 8 FROM tab1 AS cor0
----
432
456
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3915
SELECT + col2 + CAST( - 18 AS SIGNED ) FROM tab0 AS cor0
----
-17
15
64

skipif mysql # not compatible
query I rowsort label-3915
SELECT + col2 + CAST ( - 18 AS INTEGER ) FROM tab0 AS cor0
----
-17
15
64

query I rowsort
SELECT DISTINCT col2 * - col2 + - col2 AS col2 FROM tab2
----
-1482
-702
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 * - col0 col0 FROM tab1
----
249
5312
6640

query I rowsort
SELECT ALL + 66 + col2 AS col1 FROM tab0
----
148
67
99

query I rowsort
SELECT ALL col1 + + col2 * + 18 FROM tab2
----
517
527
701

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + - 25 * - col1 col2 FROM tab0 AS cor0
----
2126
2186
2390

query I rowsort
SELECT DISTINCT + col1 - col0 AS col1 FROM tab2 cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col2 + cor0.col0 * - cor0.col1 col0 FROM tab2 AS cor0
----
-2787
-5278
-946

query I rowsort
SELECT DISTINCT + 94 * - col0 AS col2 FROM tab1
----
-282
-6016
-7520

query I rowsort
SELECT + col0 * col0 + 50 AS col1 FROM tab0
----
1275
626
7971

query I rowsort
SELECT - tab2.col1 + tab2.col1 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * + cor0.col1 + + ( - col1 ) AS col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-3927
SELECT col1 DIV col0 AS col0 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-3927
SELECT col1 / col0 AS col0 FROM tab2 cor0
----
0
0
4

query I rowsort
SELECT DISTINCT cor0.col0 * 1 FROM tab2, tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - ( - col2 ) * col1 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL 15 * - col1 FROM tab2
----
-255
-465
-885

onlyif mysql # use DIV operator for integer division
query I rowsort label-3931
SELECT col2 + + col2 DIV - 84 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3931
SELECT col2 + + col2 / - 84 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL tab0.col2 + 9 AS col0 FROM tab0
----
10
42
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + 53 col1 FROM tab1
----
117
133
56

query I rowsort
SELECT ALL - + col1 + 88 * 73 FROM tab1 cor0
----
6398
6411
6414

query I rowsort
SELECT ALL + 0 - - 33 * + cor0.col0 FROM tab0, tab0 cor0
----
9 values hashing to a5cffa32f627ede3eeafdc956e0a2eea

query I rowsort
SELECT ALL col0 * - ( col1 ) + - col1 AS col0 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT ALL tab0.col2 + + col2 * - 67 FROM tab0
----
-2178
-5412
-66

query I rowsort
SELECT DISTINCT + col0 + col1 * col0 * + 70 FROM tab1 AS cor0
----
44864
5463
72880

query I rowsort
SELECT - - 1 + col0 * col0 * - 5 FROM tab0 AS cor0
----
-2879
-39604
-6124

query I rowsort
SELECT DISTINCT ( + col1 ) + + col0 * col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + col0 * + 28 FROM tab2 AS cor0
----
196
2184
2212

query I rowsort
SELECT ALL - + 60 AS col2 FROM tab1 cor0
----
-60
-60
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3943
SELECT ALL - 58 DIV + 4 + + col2 col2 FROM tab2 AS cor0
----
12
13
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3943
SELECT ALL - 58 / + 4 + + col2 col2 FROM tab2 AS cor0
----
12
13
24

query I rowsort
SELECT - col2 + + 27 + - col2 * + 28 FROM tab1 AS cor0
----
-1539
-1626
-2757

query I rowsort
SELECT ALL + 54 * ( + col2 ) FROM tab2 AS cor0
----
1404
1458
2052

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT ( ( col1 ) ) + CAST ( + col1 AS REAL ) * - col1 FROM tab2 AS cor0
----
-272
-3422
-930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + 0 + + cor1.col0 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 179f1c4ecae3615ed02c294cbc435c7b

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) * col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL + ( + cor0.col0 ) * - col2 + 30 FROM tab2 AS cor0
----
-159
-1998
-2972

query I rowsort
SELECT + + 19 * 99 FROM tab2 AS cor0
----
1881
1881
1881

query I rowsort
SELECT DISTINCT + col2 + col1 * - col1 * - col2 FROM tab1 AS cor0
----
16320
36558
5757

query I rowsort
SELECT 57 + 35 FROM tab1 AS cor0
----
92
92
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3953
SELECT DISTINCT - + ( - cor0.col1 ) + col0 * CAST( 44 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
339
3491
3493

skipif mysql # not compatible
query I rowsort label-3953
SELECT DISTINCT - + ( - cor0.col1 ) + col0 * CAST ( 44 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
339
3491
3493

query I rowsort
SELECT ALL - - 10 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
27
41
69

query I rowsort
SELECT ALL - + col0 + col0 + col1 * + ( col0 * col1 + + col0 ) AS col2 FROM tab1 AS cor0
----
14560
2106
7040

query I rowsort
SELECT ALL - ( col2 ) * col0 + + col2 * col0 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 11 * + col0 * col2 FROM tab1
----
1782
40128
84480

query I rowsort
SELECT DISTINCT + col2 * + 12 AS col1 FROM tab1
----
1152
648
684

query I rowsort
SELECT - 17 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT + - col1 * - col2 + ( col1 + col1 ) AS col2 FROM tab0 AS cor0
----
291
3010
7644

query I rowsort
SELECT + cor0.col1 + col2 * + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT col2 + + col2 * - col2 * col1 AS col2 FROM tab1 AS cor0
----
-119712
-32433
-75762

query I rowsort
SELECT - col0 * + col0 + ( ( col2 ) * cor0.col1 ) FROM tab1 cor0
----
-3526
-5152
1395

query I rowsort
SELECT - - col1 * col0 + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-3965
SELECT - cor0.col0 + - cor0.col0 DIV ( col1 * CAST( col0 AS SIGNED ) ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3965
SELECT - cor0.col0 + - cor0.col0 / ( col1 * CAST ( col0 AS INTEGER ) ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL col0 + + 96 FROM tab1 AS cor0
----
160
176
99

query I rowsort
SELECT ALL + col2 * - 95 FROM tab0 AS cor0
----
-3135
-7790
-95

query I rowsort
SELECT ALL col0 * 61 AS col1 FROM tab0 cor0
----
1464
2135
5429

query I rowsort
SELECT + + col0 * 50 FROM tab2 cor0
----
350
3900
3950

query I rowsort
SELECT ALL - col0 + - 73 FROM tab1
----
-137
-153
-76

query I rowsort
SELECT + col1 * col1 + + cor0.col2 + + 75 FROM tab1 cor0
----
232
340
805

query I rowsort
SELECT + 16 AS col0 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

onlyif mysql # use DIV operator for integer division
query I rowsort label-3973
SELECT tab2.col0 DIV 90 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3973
SELECT tab2.col0 / 90 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col0 + + col0 + + col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT - tab1.col2 + - 68 AS col1 FROM tab1
----
-122
-125
-164

query I rowsort
SELECT DISTINCT + 48 AS col2 FROM tab2, tab2 AS cor0, tab2 cor1
----
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3977
SELECT + col0 * - CAST( NULL AS SIGNED ) / ( tab0.col0 ) + 99 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3977
SELECT + col0 * - CAST ( NULL AS INTEGER ) / ( tab0.col0 ) + 99 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 - 64 FROM tab1 AS cor0
----
-38
-51
-54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3979
SELECT ALL - col1 + CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-3979
SELECT ALL - col1 + CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - col1 AS REAL ) + + col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - ( - cor0.col0 ) * col1 * + ( - col1 ) - - col2 * - ( - col0 ) FROM tab2 AS cor0
----
-19829
-269490
-6538

query I rowsort
SELECT ALL col1 - 59 * + col2 FROM tab1 AS cor0
----
-3160
-3353
-5651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3983
SELECT + + CAST( NULL AS SIGNED ) * + 27 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-3983
SELECT + + CAST ( NULL AS INTEGER ) * + 27 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3984
SELECT ALL - CAST( + 72 AS SIGNED ) + col2 * 18 AS col2 FROM tab0 AS cor0
----
-54
1404
522

skipif mysql # not compatible
query I rowsort label-3984
SELECT ALL - CAST ( + 72 AS INTEGER ) + col2 * 18 AS col2 FROM tab0 AS cor0
----
-54
1404
522

onlyif mysql # use DIV operator for integer division
query I rowsort label-3985
SELECT ALL + + col1 DIV col0 + col2 FROM tab2 cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-3985
SELECT ALL + + col1 / col0 + col2 FROM tab2 cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - 78 * col1 + col0 - + CAST ( + 27 + col1 AS REAL ) FROM tab2 AS cor0
----
-1291
-2469
-4610

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3987
SELECT ALL - + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3987
SELECT ALL - + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + 25 FROM tab2 AS cor0
----
103
104
32

query I rowsort
SELECT DISTINCT 43 + - col2 FROM tab0 AS cor0
----
-39
10
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-3990
SELECT ALL + + col2 + 2 DIV - col0 - 43 FROM tab1 AS cor0
----
11
14
53

skipif mysql # not compatible
query I rowsort label-3990
SELECT ALL + + col2 + 2 / - col0 - 43 FROM tab1 AS cor0
----
11
14
53

query I rowsort
SELECT + col1 + col0 * cor0.col0 AS col1 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT - 34 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 5b88331e40da4796cc4826c442aa45f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3993
SELECT ALL + col0 + cor0.col1 DIV col0 + + col2 col0 FROM tab2 AS cor0
----
104
117
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3993
SELECT ALL + col0 + cor0.col1 / col0 + + col2 col0 FROM tab2 AS cor0
----
104
117
38

query I rowsort
SELECT ALL - + cor0.col1 + ( col2 + ( + col1 ) ) AS col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3995
SELECT ALL col2 + col0 DIV cor0.col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-3995
SELECT ALL col2 + col0 / cor0.col2 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT + cor0.col1 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + + col2 * + col2 + + col1 * - 50 AS col0 FROM tab0 AS cor0
----
-3211
-4849
2174

query I rowsort
SELECT + col1 + + col1 + 51 FROM tab0 cor0
----
223
233
245

query I rowsort
SELECT + col1 * col0 + 19 AS col0 FROM tab1 cor0
----
1059
659
97

query I rowsort
SELECT ALL - 76 AS col0 FROM tab0 cor0
----
-76
-76
-76

query I rowsort
SELECT + + col2 - col0 * 80 AS col1 FROM tab1 AS cor0
----
-186
-5063
-6304

query I rowsort
SELECT ALL 69 * ( - col0 ) FROM tab1
----
-207
-4416
-5520

query I rowsort
SELECT + cor0.col0 + col0 * 26 AS col2 FROM tab1 AS cor0
----
1728
2160
81

query I rowsort
SELECT DISTINCT + - 40 - + col1 * + ( + ( - col2 ) ) AS col0 FROM tab0 cor0
----
2798
57
7422

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + col2 col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col0 * - col2 * 4 + + ( - col0 + cor0.col0 ) FROM tab1 cor0
----
-14592
-30720
-648

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - CAST ( cor1.col2 AS REAL ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
1
33
82

query I rowsort
SELECT col2 * + 34 FROM tab1 AS cor0
----
1836
1938
3264

query I rowsort
SELECT DISTINCT col2 + col2 * + 83 * ( - col1 + 4 ) FROM tab2
----
-118664
-40964
-60480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4010
SELECT DISTINCT + - cor0.col0 + col2 DIV col0 AS col0 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-4010
SELECT DISTINCT + - cor0.col0 + col2 / col0 AS col0 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT DISTINCT col2 * 20 AS col2 FROM tab0 cor0
----
1640
20
660

query I rowsort
SELECT ALL col2 + - ( col0 ) FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-4013
SELECT - - col1 DIV + 38 + + col2 col1 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4013
SELECT - - col1 / + 38 + + col2 col1 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4014
SELECT - cor0.col0 DIV col1 + col2 + + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-4014
SELECT - cor0.col0 / col1 + col2 + + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + col0 * ( col1 + - col0 ) AS col1 FROM tab1 AS cor0
----
-3456
-5360
69

query I rowsort
SELECT DISTINCT - - col1 * + ( col1 ) AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - col2 + - ( + 96 ) FROM tab1 cor0
----
-150
-153
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-4018
SELECT DISTINCT - cor0.col1 DIV ( + 17 ) AS col2 FROM tab0 AS cor0
----
-5

skipif mysql # not compatible
query I rowsort label-4018
SELECT DISTINCT - cor0.col1 / ( + 17 ) AS col2 FROM tab0 AS cor0
----
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4019
SELECT cor0.col1 DIV col0 AS col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4019
SELECT cor0.col1 / col0 AS col0 FROM tab0 cor0
----
1
2
3

query I rowsort
SELECT - + cor0.col1 * - 72 * - col0 FROM tab0 AS cor0
----
-148608
-244440
-583128

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4021
SELECT ALL + col1 * + CAST( NULL AS SIGNED ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4021
SELECT ALL + col1 * + CAST ( NULL AS INTEGER ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4022
SELECT col0 + + col2 DIV 28 + 35 * col2 AS col1 FROM tab2
----
1410
952
988

skipif mysql # not compatible
query I rowsort label-4022
SELECT col0 + + col2 / 28 + 35 * col2 AS col1 FROM tab2
----
1410
952
988

query I rowsort
SELECT col1 * - 40 * cor0.col1 FROM tab1 cor0
----
-27040
-4000
-6760

query I rowsort
SELECT DISTINCT 17 + - col1 AS col0 FROM tab2
----
-14
-42
0

query I rowsort
SELECT DISTINCT ( - col1 ) + - 34 + + 31 FROM tab1
----
-13
-16
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-4026
SELECT + 81 DIV col0 - + 39 FROM tab2
----
-28
-38
-38

skipif mysql # not compatible
query I rowsort label-4026
SELECT + 81 / col0 - + 39 FROM tab2
----
-28
-38
-38

query I rowsort
SELECT 21 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query I rowsort
SELECT ALL col1 + + 9 * cor0.col2 FROM tab1 AS cor0
----
512
523
877

query I rowsort
SELECT + - col1 + 43 FROM tab1 cor0
----
17
30
33

query I rowsort
SELECT - - col2 * + col2 + 74 AS col1 FROM tab2 AS cor0
----
1518
750
803

query I rowsort
SELECT ALL - col1 * - col1 + tab1.col2 - col0 AS col2 FROM tab1
----
185
727
93

query I rowsort
SELECT - + col0 * col0 + - col0 FROM tab0 cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT + + ( - col1 ) * + ( + 65 ) FROM tab0 AS cor0
----
-5590
-5915
-6305

query I rowsort
SELECT ALL + col2 + - tab1.col2 * - col0 + col1 FROM tab1
----
242
3715
7789

query I rowsort
SELECT ALL 30 + - col0 AS col1 FROM tab1
----
-34
-50
27

query I rowsort
SELECT - col1 * - col0 - - ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - 29 + col1 AS col0 FROM tab0 AS cor0
----
57
62
68

query I rowsort
SELECT DISTINCT 37 AS col1 FROM tab0 AS cor0
----
37

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 cor2, tab1 AS cor3
----
13122 values hashing to eea184561fc1c7fbca6cc2e71ea8c9e9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4040
SELECT ALL 31 DIV cor0.col0 FROM tab1, tab0 cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-4040
SELECT ALL 31 / cor0.col0 FROM tab1, tab0 cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

query I rowsort
SELECT DISTINCT + - col1 + ( - col1 ) * - 46 AS col1 FROM tab2 AS cor0
----
1395
2655
765

query I rowsort
SELECT 75 + 58 * col0 FROM tab1 AS cor0
----
249
3787
4715

query I rowsort
SELECT ALL - ( col2 ) + + col0 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4044
SELECT - CAST( NULL AS SIGNED ) + - col1 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-4044
SELECT - CAST ( NULL AS INTEGER ) + - col1 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4045
SELECT DISTINCT + CAST( col1 AS SIGNED ) * col1 + col1 * 5 AS col0 FROM tab1 AS cor0
----
150
234
806

skipif mysql # not compatible
query I rowsort label-4045
SELECT DISTINCT + CAST ( col1 AS INTEGER ) * col1 + col1 * 5 AS col0 FROM tab1 AS cor0
----
150
234
806

query I rowsort
SELECT + col1 + + ( col2 * ( + col2 ) ) FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT - 19 * - col0 + col0 AS col0 FROM tab0 AS cor0
----
1780
480
700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4048
SELECT - 38 + cor0.col0 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4048
SELECT - 38 + cor0.col0 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 47 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT + col2 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4051
SELECT ALL + - col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4051
SELECT ALL + - col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor1.col2 AS col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

skipif mysql # not compatible
query I rowsort
SELECT - cor0.col0 * + CAST ( + col0 AS REAL ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-4054
SELECT col1 - + 41 DIV - 85 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4054
SELECT col1 - + 41 / - 85 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - ( 34 ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 80 * - col0 col2 FROM tab1
----
-240
-5120
-6400

query I rowsort
SELECT DISTINCT + ( 96 ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
96

query I rowsort
SELECT ALL - col0 + + 5 + - 64 FROM tab1
----
-123
-139
-62

query I rowsort
SELECT + + col0 + col2 - + col2 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + col2 * + col2 + 86 + - col2 FROM tab0
----
1142
6728
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4061
SELECT ALL tab0.col1 * col2 + col2 DIV col2 FROM tab0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-4061
SELECT ALL tab0.col1 * col2 + col2 / col2 FROM tab0
----
2839
7463
98

query I rowsort
SELECT ALL - ( col1 ) * - col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT 35 + 16 AS col0 FROM tab1 AS cor0
----
51
51
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col2 * - col2 col2 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT DISTINCT col1 * - col0 + 38 * - 90 FROM tab0 AS cor0
----
-11519
-5484
-6815

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 cor2
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT - cor0.col0 + ( 8 ) AS col2 FROM tab2 cor0
----
-70
-71
1

query I rowsort
SELECT col2 * - col1 + - col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT + cor0.col1 + + 65 AS col0 FROM tab1 AS cor0
----
75
78
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-4070
SELECT ALL + col0 DIV col1 + - col0 AS col1 FROM tab2
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-4070
SELECT ALL + col0 / col1 + - col0 AS col1 FROM tab2
----
-7
-75
-77

query I rowsort
SELECT - ( col2 + col1 ) * col1 AS col1 FROM tab1
----
-1417
-2080
-670

query I rowsort
SELECT ALL 38 + tab1.col1 FROM tab1
----
48
51
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4073
SELECT DISTINCT - CAST( 82 AS SIGNED ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-82

skipif mysql # not compatible
query I rowsort label-4073
SELECT DISTINCT - CAST ( 82 AS INTEGER ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-82

query I rowsort
SELECT DISTINCT 32 * - cor0.col1 FROM tab2 AS cor0
----
-1888
-544
-992

query I rowsort
SELECT + 37 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1295
3293
888

query I rowsort
SELECT ALL - col1 * + col1 + col2 * col1 FROM tab1 AS cor0
----
1079
470
728

query I rowsort
SELECT ALL 93 + col0 * col0 AS col0 FROM tab0 AS cor0
----
1318
669
8014

query I rowsort
SELECT DISTINCT + col1 * col1 * 44 AS col1 FROM tab2 AS cor0
----
12716
153164
42284

query I rowsort
SELECT DISTINCT 51 + col0 FROM tab1 cor0
----
115
131
54

query I rowsort
SELECT - + 53 + - col2 + col0 * + col1 FROM tab2 cor0
----
1252
137
4523

query I rowsort
SELECT + cor0.col1 * col2 * 19 FROM tab0 AS cor0
----
141778
1843
53922

query I rowsort
SELECT ALL - 46 + + col0 FROM tab2 AS cor0
----
-39
32
33

query I rowsort
SELECT ALL + col0 + + col0 AS col2 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL col2 - + ( + 78 ) FROM tab1
----
-21
-24
18

query I rowsort
SELECT + cor0.col2 * - ( + 67 ) FROM tab1 cor0
----
-3618
-3819
-6432

query I rowsort
SELECT col2 * col0 + cor0.col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + cor0.col1 + ( - 6 + - col1 ) AS col1 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT - col0 + - col0 * + col2 AS col0 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4089
SELECT ALL - CAST( 41 AS SIGNED ) - - col2 FROM tab2 cor0
----
-14
-15
-3

skipif mysql # not compatible
query I rowsort label-4089
SELECT ALL - CAST ( 41 AS INTEGER ) - - col2 FROM tab2 cor0
----
-14
-15
-3

query I rowsort
SELECT 12 + - col0 AS col2 FROM tab1 AS cor0
----
-52
-68
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4091
SELECT col2 DIV + 58 + + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4091
SELECT col2 / + 58 + + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT ( + cor0.col0 ) FROM tab2, tab0 cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4093
SELECT CAST( - col1 AS SIGNED ) + + col1 * col0 AS col2 FROM tab1 AS cor0
----
1027
52
630

skipif mysql # not compatible
query I rowsort label-4093
SELECT CAST ( - col1 AS INTEGER ) + + col1 * col0 AS col2 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT + 91 + cor0.col0 * + col0 - + cor0.col0 AS col2 FROM tab1 AS cor0
----
4123
6411
97

query I rowsort
SELECT DISTINCT - - ( 99 ) * cor0.col1 + col0 FROM tab0 AS cor0
----
8538
9098
9638

query I rowsort
SELECT + + col1 + + col1 * - col0 + - col2 FROM tab0 AS cor0
----
-2011
-3299
-8090

query I rowsort
SELECT - cor0.col2 + cor0.col0 - col1 FROM tab0 AS cor0
----
-63
-84
-95

query I rowsort
SELECT ALL + - col1 * 45 * col0 AS col2 FROM tab1 AS cor0
----
-28800
-3510
-46800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4099
SELECT DISTINCT - - CAST( + 20 AS SIGNED ) col1 FROM tab0 AS cor0
----
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4099
SELECT DISTINCT - - CAST ( + 20 AS INTEGER ) col1 FROM tab0 AS cor0
----
20

query I rowsort
SELECT ALL + + 40 + - col0 AS col2 FROM tab0 AS cor0
----
-49
16
5

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-4102
SELECT ALL CAST( NULL AS SIGNED ) - - 17 * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4102
SELECT ALL CAST ( NULL AS INTEGER ) - - 17 * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + ( col0 ) * + col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - - col2 * - 96 + + col0 AS col1 FROM tab2 AS cor0
----
-2418
-2585
-3569

query I rowsort
SELECT + - col0 - col0 * + col2 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4106
SELECT DISTINCT + CAST( col2 AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-4106
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col2 - 92 AS col2 FROM tab0
----
-10
-59
-91

query I rowsort
SELECT DISTINCT + col1 + 49 * + col0 * - col2 - + col1 * + col1 FROM tab1
----
-178842
-376476
-8588

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - ( - cor0.col2 ) * col1 - col1 * - col2 col2 FROM tab0 AS cor0
----
194
619346
96492

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 87 * col1 col2 FROM tab2 AS cor0
----
1479
2697
5133

query I rowsort
SELECT + + 40 + col1 FROM tab2 cor0
----
57
71
99

query I rowsort
SELECT ALL - col1 * 24 FROM tab0 AS cor0
----
-2064
-2184
-2328

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4113
SELECT ALL + - CAST( - col2 AS SIGNED ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4113
SELECT ALL + - CAST ( - col2 AS INTEGER ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - ( ( col1 ) ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + 11 * col0 FROM tab0 cor0
----
264
385
979

query I rowsort
SELECT ALL col2 * tab0.col2 + col2 * tab0.col2 * + 87 AS col2 FROM tab0
----
591712
88
95832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4117
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col2 * - col0 + tab1.col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4117
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col2 * - col0 + tab1.col0 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 34 * + col0 col0 FROM tab0 AS cor0
----
-1190
-3026
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 53 * - col0 + col1 col0 FROM tab2 AS cor0
----
402
4193
4204

query I rowsort
SELECT - + col0 + col1 + + 77 FROM tab1 AS cor0
----
10
100
23

query I rowsort
SELECT DISTINCT 94 + col1 AS col0 FROM tab1
----
104
107
120

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col1 AS REAL ) + col2 / + col0 AS col2 FROM tab0
----
-85
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4123
SELECT ALL col1 + col1 DIV - col2 AS col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4123
SELECT ALL col1 + col1 / - col2 AS col2 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 88 * + cor0.col1 col2 FROM tab1 AS cor0
----
56320
6864
91520

onlyif mysql # use DIV operator for integer division
query I rowsort label-4125
SELECT DISTINCT col0 DIV + col1 col0 FROM tab2 cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4125
SELECT DISTINCT col0 / + col1 col0 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT ALL - - col2 * + col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - + col2 * col1 + - 54 * + cor0.col1 FROM tab2 AS cor0
----
-1564
-2511
-4720

query I rowsort
SELECT + + ( + 91 ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT DISTINCT col0 * + 23 AS col2 FROM tab1
----
1472
1840
69

query I rowsort
SELECT DISTINCT col1 * col0 - 51 FROM tab2
----
1292
166
4551

query I rowsort
SELECT col2 + - 6 AS col2 FROM tab2
----
20
21
32

query I rowsort
SELECT col2 + - ( + col0 * col2 ) + - 12 FROM tab0
----
-46
-7228
-771

query I rowsort
SELECT - col2 * 58 - col2 FROM tab1
----
-3186
-3363
-5664

query I rowsort
SELECT DISTINCT 11 + 32 FROM tab1, tab2 cor0
----
43

query I rowsort
SELECT + col0 + - ( col0 ) - tab1.col2 AS col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT - 66 + + 3 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * + cor0.col2 - ( 52 + col0 ) * + col1 col2 FROM tab2 AS cor0
----
-1100
-6994
-783

query I rowsort
SELECT DISTINCT - col1 - - col1 * 88 FROM tab2 AS cor0
----
1479
2697
5133

query I rowsort
SELECT DISTINCT + - col0 * + col0 + - col0 FROM tab0 cor0
----
-1260
-600
-8010

query I rowsort
SELECT ALL + col2 * col2 + 85 AS col0 FROM tab1 AS cor0
----
3001
3334
9301

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4141
SELECT ALL - - 87 * col1 + CAST( cor0.col0 AS SIGNED ) AS col2 FROM tab0 cor0
----
7506
8006
8474

skipif mysql # not compatible
query I rowsort label-4141
SELECT ALL - - 87 * col1 + CAST ( cor0.col0 AS INTEGER ) AS col2 FROM tab0 cor0
----
7506
8006
8474

query I rowsort
SELECT DISTINCT + - cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col2 + ( cor0.col2 ) AS col1 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + col0 + col1 + col0 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + 21 + col0 FROM tab1 AS cor0
----
-4011
-6299
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4146
SELECT ALL - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4146
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4147
SELECT + - col0 + + ( + cor0.col0 ) DIV col0 + col0 * col0 * col0 AS col1 FROM tab0 AS cor0
----
13801
42841
704881

skipif mysql # not compatible
query I rowsort label-4147
SELECT + - col0 + + ( + cor0.col0 ) / col0 + col0 * col0 * col0 AS col1 FROM tab0 AS cor0
----
13801
42841
704881

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + col0 col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4149
SELECT ALL - CAST( NULL AS SIGNED ) + - cor0.col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4149
SELECT ALL - CAST ( NULL AS INTEGER ) + - cor0.col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - 49 ) FROM tab0 AS cor0
----
49
49
49

query I rowsort
SELECT + ( tab1.col2 * - col2 ) FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT - 87 * col2 + col2 * + 62 AS col0 FROM tab1
----
-1350
-1425
-2400

query I rowsort
SELECT DISTINCT + col1 * - ( tab0.col2 ) FROM tab0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4154
SELECT ALL - CAST( NULL AS SIGNED ) / col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4154
SELECT ALL - CAST ( NULL AS INTEGER ) / col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 28 AS col1 FROM tab1 cor0
----
28
28
28

query I rowsort
SELECT col2 * + 40 * + col1 + col2 AS col2 FROM tab2
----
25878
33507
61386

query I rowsort
SELECT DISTINCT ( - ( + col0 ) ) + - ( + col1 ) AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - + 48 FROM tab0 AS cor0
----
-48
-48
-48

query I rowsort
SELECT - + 26 FROM tab1 cor0
----
-26
-26
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 14 col1 FROM tab1
----
14

query I rowsort
SELECT - ( col2 * col2 ) FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + - cor0.col0 * + ( + 79 ) * col0 FROM tab2 AS cor0
----
-3871
-480636
-493039

onlyif mysql # use DIV operator for integer division
query I rowsort label-4163
SELECT ALL - col1 DIV + 24 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4163
SELECT ALL - col1 / + 24 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT col1 + - 49 * col0 FROM tab1
----
-121
-3126
-3907

query I rowsort
SELECT ALL col2 * - col2 * + 55 FROM tab2
----
-37180
-40095
-79420

query I rowsort
SELECT tab2.col2 * 98 FROM tab2
----
2548
2646
3724

onlyif mysql # use DIV operator for integer division
query I rowsort label-4167
SELECT DISTINCT - tab0.col1 DIV - tab0.col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4167
SELECT DISTINCT - tab0.col1 / - tab0.col2 FROM tab0
----
1
2
97

query I rowsort
SELECT ALL 23 * + col0 FROM tab0
----
2047
552
805

query I rowsort
SELECT DISTINCT - 97 AS col1 FROM tab2, tab2 AS cor0
----
-97

query I rowsort
SELECT - ( 11 ) + + col2 * 67 AS col2 FROM tab2 AS cor0
----
1731
1798
2535

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col1 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 * cor0.col1 col0 FROM tab0 AS cor0
----
3268
3458
3686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4173
SELECT + - CAST( NULL AS SIGNED ) * - col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4173
SELECT + - CAST ( NULL AS INTEGER ) * - col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4174
SELECT + cor0.col0 * CAST( + col2 AS SIGNED ) * cor0.col1 + + col1 col2 FROM tab1 AS cor0
----
36490
4238
99853

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4174
SELECT + cor0.col0 * CAST ( + col2 AS INTEGER ) * cor0.col1 + + col1 col2 FROM tab1 AS cor0
----
36490
4238
99853

query I rowsort
SELECT - col0 + + 67 + 12 AS col0 FROM tab2 cor0
----
0
1
72

query I rowsort
SELECT col2 + + 94 * 20 + - col0 AS col2 FROM tab1 AS cor0
----
1873
1896
1931

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * 13 col1 FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT DISTINCT col2 + tab2.col1 * tab2.col0 - - tab2.col2 FROM tab2
----
1419
271
4654

query I rowsort
SELECT ALL cor0.col2 + + cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e5ee086d16e1b2450d3f7ac8d26a0f7b

query I rowsort
SELECT DISTINCT + - col0 + cor0.col0 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4181
SELECT col0 DIV col2 - + ( col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
-2064
-3360
-8098

skipif mysql # not compatible
query I rowsort label-4181
SELECT col0 / col2 - + ( col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
-2064
-3360
-8098

query I rowsort
SELECT DISTINCT - col2 + + col2 * + col2 AS col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT - + col2 * - ( cor0.col0 * + ( 79 ) ) + - col1 FROM tab1 AS cor0
----
12772
288182
606707

query I rowsort
SELECT ALL + + 85 + col1 * + col0 FROM tab1 AS cor0
----
1125
163
725

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4185
SELECT 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-4185
SELECT col2 - CAST ( NULL AS INTEGER ) col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 19 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

onlyif mysql # use DIV operator for integer division
query I rowsort label-4187
SELECT + + col0 * + 70 + + col0 * cor0.col1 DIV ( col2 ) FROM tab0 AS cor0
----
1742
5845
6328

skipif mysql # not compatible
query I rowsort label-4187
SELECT + + col0 * + 70 + + col0 * cor0.col1 / ( col2 ) FROM tab0 AS cor0
----
1742
5845
6328

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col0 * col1 + col2 col1 FROM tab0
----
2130
3397
8263

query I rowsort
SELECT ALL col1 * - col2 + - 90 FROM tab2
----
-1624
-736
-927

onlyif mysql # use DIV operator for integer division
query I rowsort label-4190
SELECT ALL col0 + col1 DIV - tab0.col0 AS col1 FROM tab0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-4190
SELECT ALL col0 + col1 / - tab0.col0 AS col1 FROM tab0
----
21
33
88

query I rowsort
SELECT ALL - ( - ( col0 ) ) FROM tab0
----
24
35
89

query I rowsort
SELECT - 52 + col2 * 53 * + col0 FROM tab0 AS cor0
----
1803
386742
41924

query I rowsort
SELECT ALL - + col0 * col0 + cor0.col1 * col2 * - col0 FROM tab1 cor0
----
-106240
-40576
-4221

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + cor0.col1 col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - 63 * + col0 + + col1 FROM tab0 AS cor0
----
-1426
-2108
-5516

query I rowsort
SELECT col0 + - col0 * + 65 AS col2 FROM tab1 AS cor0
----
-192
-4096
-5120

query I rowsort
SELECT - 15 * 4 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4198
SELECT DISTINCT col1 DIV 14 AS col2 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4198
SELECT DISTINCT col1 / 14 AS col2 FROM tab2
----
1
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 56 col0 FROM tab1
----
56
56
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4200
SELECT - + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4200
SELECT - + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - - 31 - col0 FROM tab0 cor0
----
-4
-58
7

query I rowsort
SELECT ALL + 76 - - col1 FROM tab1
----
102
86
89

query I rowsort
SELECT - - col2 * col1 * 82 AS col1 FROM tab1 AS cor0
----
102336
115128
46740

query I rowsort
SELECT ALL + col1 * col0 + - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT + - ( - col1 ) + - 20 * col0 AS col1 FROM tab2 cor0
----
-109
-1501
-1563

onlyif mysql # use DIV operator for integer division
query I rowsort label-4206
SELECT DISTINCT - 47 DIV - col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4206
SELECT DISTINCT - 47 / - col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + col1 + cor0.col1 * - col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT + ( + col0 ) + 8 * col1 AS col1 FROM tab1 AS cor0
----
144
184
211

query I rowsort
SELECT - - col2 + + col1 * col1 * - col2 FROM tab0 AS cor0
----
-244035
-678960
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 23 col1 FROM tab0 AS cor0
----
-23
-23
-23

query I rowsort
SELECT col2 * + col0 + - ( + 3 ) FROM tab1
----
159
3645
7677

query I rowsort
SELECT DISTINCT - + col0 + + col2 * ( - 77 ) FROM tab1 AS cor0
----
-4161
-4453
-7472

query I rowsort
SELECT + 56 * - col1 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT ALL - + cor0.col1 + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4215
SELECT 46 DIV 46 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif mysql # not compatible
query I rowsort label-4215
SELECT 46 / 46 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4216
SELECT DISTINCT + cor0.col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4216
SELECT DISTINCT + cor0.col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - col2 * - col2 + col2 * col1 + - col0 FROM tab0 AS cor0
----
1725
61
649

onlyif mysql # use DIV operator for integer division
query I rowsort label-4218
SELECT ALL col1 * 89 + - 6 DIV - col0 FROM tab0 AS cor0
----
7654
8099
8633

skipif mysql # not compatible
query I rowsort label-4218
SELECT ALL col1 * 89 + - 6 / - col0 FROM tab0 AS cor0
----
7654
8099
8633

query I rowsort
SELECT ALL - col2 + 9 * - cor0.col1 FROM tab1 AS cor0
----
-147
-213
-288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 col0 FROM tab0 cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - ( col1 ) * - col1 col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + + col1 * + col2 + 96 FROM tab0 AS cor0
----
193
2934
7558

query I rowsort
SELECT ALL - col1 + - col0 * + 40 * col2 AS col0 FROM tab0 AS cor0
----
-1497
-292011
-31766

query I rowsort
SELECT DISTINCT - 18 + col1 FROM tab2 AS cor0
----
-1
13
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-4225
SELECT - ( - cor0.col0 ) DIV col1 + - 24 FROM tab1 AS cor0
----
-18
-18
-24

skipif mysql # not compatible
query I rowsort label-4225
SELECT - ( - cor0.col0 ) / col1 + - 24 FROM tab1 AS cor0
----
-18
-18
-24

query I rowsort
SELECT DISTINCT + col0 * - 47 + cor0.col2 FROM tab2 AS cor0
----
-302
-3640
-3675

query I rowsort
SELECT 47 + - col0 * col1 AS col0 FROM tab0
----
-2017
-3348
-8052

query I rowsort
SELECT + ( cor0.col0 ) AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - ( - ( - cor0.col1 ) ) * cor0.col1 + + col1 AS col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL ( col2 ) * + col1 FROM tab0 cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 88 - + 28 col1 FROM tab1 AS cor0
----
60

query I rowsort
SELECT DISTINCT cor0.col2 + 15 * col1 AS col1 FROM tab1 AS cor0
----
207
291
444

query I rowsort
SELECT DISTINCT + 91 + - 69 FROM tab2 AS cor0
----
22

query I rowsort
SELECT - col2 + - cor0.col0 * col1 FROM tab1 AS cor0
----
-1136
-132
-697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 - - col0 * + col1 col0 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4236
SELECT ALL + CAST( NULL AS SIGNED ) / col2 + col1 / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4236
SELECT ALL + CAST ( NULL AS INTEGER ) / col2 + col1 / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 55 * + col0 - + col2 FROM tab1 AS cor0
----
111
3463
4304

query I rowsort
SELECT - ( 25 ) * col0 * col0 + - cor0.col1 * col0 AS col1 FROM tab0 AS cor0
----
-16464
-206124
-34020

onlyif mysql # use DIV operator for integer division
query I rowsort label-4239
SELECT ALL + - col1 DIV cor0.col0 - + cor0.col1 DIV - col0 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4239
SELECT ALL + - col1 / cor0.col0 - + cor0.col1 / - col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT col2 * - col1 + tab1.col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ( 36 ) FROM tab0
----
36
36
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4242
SELECT - - CAST( NULL AS SIGNED ) / - 98 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4242
SELECT - - CAST ( NULL AS INTEGER ) / - 98 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

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-4244
SELECT + CAST( - ( cor0.col0 ) AS SIGNED ) * ( col1 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-4244
SELECT + CAST ( - ( cor0.col0 ) AS INTEGER ) * ( col1 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + 90 * + 74 FROM tab1, tab0 AS cor0
----
9 values hashing to 938e6f535e9ca924e44e3adebd0c5d1c

onlyif mysql # use DIV operator for integer division
query I rowsort label-4246
SELECT + col0 * + ( - col0 ) + col0 DIV 17 FROM tab1
----
-4093
-6396
-9

skipif mysql # not compatible
query I rowsort label-4246
SELECT + col0 * + ( - col0 ) + col0 / 17 FROM tab1
----
-4093
-6396
-9

query I rowsort
SELECT 1 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT + tab2.col0 + - tab2.col2 AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT - + ( - col2 ) * col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + + 52 AS col0 FROM tab2 AS cor0
----
52
52
52

query I rowsort
SELECT + ( + 9 ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
117
234
90

query I rowsort
SELECT DISTINCT + 7 AS col1 FROM tab2 cor0
----
7

query I rowsort
SELECT ALL col1 * col1 * col2 AS col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT + 8 + + col1 FROM tab1 cor0
----
18
21
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4255
SELECT ALL + col0 * - col1 + CAST( NULL AS SIGNED ) + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4255
SELECT ALL + col0 * - col1 + CAST ( NULL AS INTEGER ) + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 73 * - cor0.col2 AS col1 FROM tab0 cor0
----
2409
5986
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 71 col1 FROM tab2, tab1 AS cor0
----
71

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to e5255b2277726ba4514ff55622dec830

query I rowsort
SELECT - col1 * col1 * ( - col1 * - col2 ) + 88 + + col2 FROM tab1 AS cor0
----
-210728
-56855
-948962

query I rowsort
SELECT - col0 + 63 * + 24 AS col0 FROM tab1 AS cor0
----
1432
1448
1509

query I rowsort
SELECT + 74 + - tab1.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8465baa6dab8afefbcaf9188952c73c5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4262
SELECT - + col1 * CAST( NULL AS SIGNED ) + col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4262
SELECT - + col1 * CAST ( NULL AS INTEGER ) + col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 30 * col0 * cor0.col1 FROM tab2 AS cor0
----
138060
40290
6510

query I rowsort
SELECT + - ( - col2 ) + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - + col1 * 19 AS col2 FROM tab0 AS cor0
----
-1634
-1729
-1843

query I rowsort
SELECT ALL - col2 - col0 AS col1 FROM tab2 cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4267
SELECT 92 DIV + col1 + CAST( - 81 AS SIGNED ) + + col0 AS col1 FROM tab1 AS cor0
----
-75
-8
6

skipif mysql # not compatible
query I rowsort label-4267
SELECT 92 / + col1 + CAST ( - 81 AS INTEGER ) + + col0 AS col1 FROM tab1 AS cor0
----
-75
-8
6

query I rowsort
SELECT ALL + ( + 39 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

onlyif mysql # use DIV operator for integer division
query I rowsort label-4269
SELECT col2 + + col2 + 80 * col0 DIV tab2.col1 FROM tab2
----
157
447
72

skipif mysql # not compatible
query I rowsort label-4269
SELECT col2 + + col2 + 80 * col0 / tab2.col1 FROM tab2
----
157
447
72

query I rowsort
SELECT - tab2.col0 + - col2 - - 1 FROM tab2
----
-103
-116
-33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4271
SELECT col0 + + col0 * CAST( col2 + + col1 AS SIGNED ) col2 FROM tab2 AS cor0
----
413
4424
6708

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4271
SELECT col0 + + col0 * CAST ( col2 + + col1 AS INTEGER ) col2 FROM tab2 AS cor0
----
413
4424
6708

onlyif mysql # use DIV operator for integer division
query I rowsort label-4272
SELECT - tab1.col0 DIV - tab1.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-4272
SELECT - tab1.col0 / - tab1.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

query I rowsort
SELECT - + 63 * - cor0.col0 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT col1 + cor0.col0 + ( col0 ) FROM tab1 AS cor0
----
138
173
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * cor0.col1 + ( col2 ) - 95 col1 FROM tab2 cor0
----
-1400
-285
-4671

query I rowsort
SELECT cor0.col1 + - 91 * col1 FROM tab2 AS cor0
----
-1530
-2790
-5310

query I rowsort
SELECT ALL + col0 + + ( + col2 + + col2 ) * - col1 AS col0 FROM tab1 AS cor0
----
-1076
-2416
-2805

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4278
SELECT DISTINCT + col1 - + CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-4278
SELECT DISTINCT + col1 - + CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT col1 * - tab2.col2 * - col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab0, tab1, tab2 AS cor0, tab0 cor1
----
26
27
38

query I rowsort
SELECT 73 * tab1.col2 AS col1 FROM tab1
----
3942
4161
7008

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab1 cor1, tab0 cor2
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT ALL col1 + col2 * + col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL col1 * + 28 FROM tab0 AS cor0
----
2408
2548
2716

onlyif mysql # use DIV operator for integer division
query I rowsort label-4285
SELECT ALL - col2 * col0 + - col2 DIV - col1 col1 FROM tab2 AS cor0
----
-189
-2028
-3000

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4285
SELECT ALL - col2 * col0 + - col2 / - col1 col1 FROM tab2 AS cor0
----
-189
-2028
-3000

query I rowsort
SELECT ALL - - cor0.col0 + 44 FROM tab0 AS cor0
----
133
68
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4287
SELECT DISTINCT - - col0 - CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-4287
SELECT DISTINCT - - col0 - CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort
SELECT col2 + CAST ( col1 + + col1 AS REAL ) FROM tab1 AS cor0
----
106
122
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4289
SELECT 95 DIV col0 FROM tab2
----
1
1
13

skipif mysql # not compatible
query I rowsort label-4289
SELECT 95 / col0 FROM tab2
----
1
1
13

query I rowsort
SELECT 11 + - col1 + + col2 FROM tab0
----
-42
-85
2

query I rowsort
SELECT - 43 * + col1 + + col0 FROM tab1
----
-1115
-366
-479

query I rowsort
SELECT ALL 53 - - col1 FROM tab0
----
139
144
150

query I rowsort
SELECT + col2 * col0 - col1 * col1 * - col2 FROM tab0
----
244860
686340
9444

query I rowsort
SELECT 33 * col1 FROM tab2
----
1023
1947
561

query I rowsort
SELECT ALL col0 + col2 * - col0 * - col2 FROM tab0
----
26160
598525
70

query I rowsort
SELECT DISTINCT + col0 - col0 * tab0.col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT + col0 FROM tab1 WHERE NOT + col1 NOT BETWEEN ( col2 ) AND NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 NOT IN ( tab0.col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT + col2 + - col1 + + col2 AS col2 FROM tab2
----
-7
23
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col0 * col1 col0 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT ALL col0 + + col1 * + col1 FROM tab2
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col0 col0 FROM tab1 WHERE NOT NULL BETWEEN + col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4303
SELECT col1 - col1 DIV col1 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-4303
SELECT col1 - col1 / col1 FROM tab2
----
16
30
58

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) IN ( col0 * col0 + - col2 * tab1.col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) < col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col2 col2 FROM tab2
----
0

query I rowsort
SELECT DISTINCT col2 + tab2.col0 * + col1 AS col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT - col2 / - col0 FROM tab1 WHERE NOT NULL NOT IN ( + col0 )
----

query I rowsort
SELECT - tab2.col1 AS col1 FROM tab2 WHERE NOT NULL BETWEEN NULL AND + col2 + col1
----

query I rowsort
SELECT ALL - col0 FROM tab2 WHERE NOT col1 NOT BETWEEN NULL AND NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND + col2 * + col0
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT IN ( + tab2.col2 )
----

query I rowsort
SELECT + col0 * + col1 * - cor0.col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT ( col1 ) * col0 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT - ( col2 ) * - tab0.col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT + 75 * + 40 FROM tab0
----
3000
3000
3000

query I rowsort
SELECT ALL 52 * col0 AS col1 FROM tab0
----
1248
1820
4628

query I rowsort
SELECT ALL cor0.col1 + col2 * cor0.col2 * - 34 FROM tab1 cor0
----
-110456
-313331
-99118

query I rowsort
SELECT DISTINCT - - 17 * + col0 AS col0 FROM tab0 AS cor0
----
1513
408
595

onlyif mysql # use DIV operator for integer division
query I rowsort label-4320
SELECT + - col2 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4320
SELECT + - col2 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4321
SELECT DISTINCT + + col1 + col1 DIV 96 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4321
SELECT DISTINCT + + col1 + col1 / 96 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4322
SELECT ALL + 51 DIV col0 col2 FROM tab0 AS cor0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4322
SELECT ALL + 51 / col0 col2 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT + 58 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

onlyif mysql # use DIV operator for integer division
query I rowsort label-4324
SELECT - col1 + col0 DIV + ( col1 + ( + col0 ) ) FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4324
SELECT - col1 + col0 / + ( col1 + ( + col0 ) ) FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - 47 AS col0 FROM tab2, tab1 cor0, tab1, tab0 AS cor1
----
81 values hashing to 905cbd63e2561d7f32ce36091d5b526a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4326
SELECT DISTINCT + + col2 + CAST( ( col1 ) AS SIGNED ) FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-4326
SELECT DISTINCT + + col2 + CAST ( ( col1 ) AS INTEGER ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - - col2 * - ( + col2 ) + + col0 AS col0 FROM tab2 cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT + + col0 - col1 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + 50 - col0 col1 FROM tab2 AS cor0
----
343
3822
3871

query I rowsort
SELECT ALL - col1 * - 89 AS col2 FROM tab2 cor0
----
1513
2759
5251

query I rowsort
SELECT DISTINCT - - col0 * + ( + col1 + col1 ) FROM tab1 AS cor0
----
1280
156
2080

query I rowsort
SELECT ALL - - col1 * - 89 + cor0.col0 * col1 * cor0.col1 FROM tab2 AS cor0
----
21318
266267
3968

query I rowsort
SELECT + col1 + + 47 AS col0 FROM tab1 AS cor0
----
57
60
73

query I rowsort
SELECT DISTINCT + - cor0.col0 + 6 AS col2 FROM tab2 AS cor0
----
-1
-72
-73

query I rowsort
SELECT ALL + col2 + col2 * col2 + + col1 FROM tab1 AS cor0
----
2996
3316
9325

query I rowsort
SELECT DISTINCT - cor0.col2 + + cor0.col0 * col2 * + 22 FROM tab2 AS cor0
----
4131
44590
66006

query I rowsort
SELECT ALL ( col1 ) + + col1 + col2 AS col2 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT 74 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to 22fe261d6995563c0767a5087aea05b1

query I rowsort
SELECT DISTINCT - ( 68 ) * - col0 + 56 * - col0 * + col2 + + col2 FROM tab2 cor0
----
-10081
-108238
-162702

query I rowsort
SELECT - col1 + col1 * + col0 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + ( - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - 39 + col2 FROM tab2 AS cor0
----
-1
-12
-13

query I rowsort
SELECT + col1 * + col0 + col1 * 42 FROM tab2 AS cor0
----
1519
2057
7080

query I rowsort
SELECT col1 * 56 + col0 FROM tab0 cor0
----
4840
5185
5467

query I rowsort
SELECT DISTINCT - ( col2 ) * + col1 + - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL - - 13 - + col0 FROM tab0 AS cor0
----
-11
-22
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4347
SELECT + - col0 + col2 * - col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4347
SELECT + - col0 + col2 * - col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * 1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - - col0 * + col0 + col2 + cor0.col0 FROM tab2 AS cor0
----
6188
6358
83

query I rowsort
SELECT ALL + + cor0.col2 + - 61 AS col2 FROM tab2 AS cor0
----
-23
-34
-35

query I rowsort
SELECT + 97 + cor0.col0 * - col2 FROM tab1 AS cor0
----
-3551
-65
-7583

query I rowsort
SELECT + col1 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT 62 + + cor0.col1 * + cor0.col1 FROM tab1 AS cor0
----
162
231
738

query I rowsort
SELECT - 22 * + col0 * + col0 FROM tab0 AS cor0
----
-12672
-174262
-26950

query I rowsort
SELECT + 56 + + col1 * col1 FROM tab2 cor0
----
1017
345
3537

onlyif mysql # use DIV operator for integer division
query I rowsort label-4356
SELECT - col0 * + col0 + col1 DIV col0 FROM tab1 AS cor0
----
-1
-4096
-6400

skipif mysql # not compatible
query I rowsort label-4356
SELECT - col0 * + col0 + col1 / col0 FROM tab1 AS cor0
----
-1
-4096
-6400

query I rowsort
SELECT ALL + tab1.col0 * + col1 * - col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4358
SELECT - 12 DIV - col0 + cor0.col0 - + col2 * - col1 * + col1 FROM tab0 AS cor0
----
244092
679131
9444

skipif mysql # not compatible
query I rowsort label-4358
SELECT - 12 / - col0 + cor0.col0 - + col2 * - col1 * + col1 FROM tab0 AS cor0
----
244092
679131
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-4359
SELECT - col1 * + 66 + col0 DIV col2 AS col1 FROM tab1 cor0
----
-1716
-659
-858

skipif mysql # not compatible
query I rowsort label-4359
SELECT - col1 * + 66 + col0 / col2 AS col1 FROM tab1 cor0
----
-1716
-659
-858

query I rowsort
SELECT ALL + col0 + ( - ( col2 ) ) AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL + col0 * tab1.col2 + + col1 * - col0 FROM tab1
----
3008
6640
84

query I rowsort
SELECT DISTINCT - col0 * col2 * col2 FROM tab2
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-4363
SELECT ALL col1 DIV 51 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4363
SELECT ALL col1 / 51 FROM tab2
----
0
0
1

query I rowsort
SELECT + col0 * 67 AS col1 FROM tab1
----
201
4288
5360

query I rowsort
SELECT 99 + - col2 * col0 AS col0 FROM tab0
----
-693
-7199
64

query I rowsort
SELECT 6 * + col1 + + col1 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT ALL ( - ( col1 ) ) + col1 * + col0 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT DISTINCT col2 + ( + col1 ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - col0 * - col2 + col1 * col0 AS col1 FROM tab0 AS cor0
----
15397
2856
3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) col2 FROM tab0
----
24
35
89

query I rowsort
SELECT + 74 * + col0 AS col0 FROM tab1
----
222
4736
5920

query I rowsort
SELECT ALL ( 83 ) FROM tab1 AS cor0
----
83
83
83

query III rowsort
SELECT * FROM tab2 WHERE ( - col0 * + col1 * col1 ) BETWEEN col0 AND col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col2 + - col2 col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT - col2 FROM tab2 WHERE NOT + col0 * col1 NOT IN ( + col1 )
----

query I rowsort
SELECT + col0 + col2 * + col1 * col2 FROM tab0 AS cor0
----
132
611973
93678

query I rowsort
SELECT col1 * - col0 * - col1 - + col1 AS col2 FROM tab2 AS cor0
----
22814
271459
6696

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 + - col0 col2 FROM tab2 AS cor0 WHERE NOT ( NULL ) = ( col0 + cor0.col1 )
----

query I rowsort
SELECT DISTINCT cor0.col1 * col1 FROM tab1 AS cor0 WHERE ( NULL ) NOT IN ( col2 + + col0 / col0 )
----

query I rowsort
SELECT DISTINCT + col2 - - tab0.col2 AS col0 FROM tab0
----
164
2
66

query III rowsort
SELECT * FROM tab0 WHERE + col0 * col0 + col0 NOT BETWEEN ( NULL ) AND tab0.col2 + col2 * col2
----
35
97
1
89
91
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col0 col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - col2 * tab1.col2 - - col0 * col2 AS col2 FROM tab1
----
-1536
-2754
399

onlyif mysql # use DIV operator for integer division
query I rowsort label-4384
SELECT DISTINCT col0 + cor0.col0 DIV col2 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-4384
SELECT DISTINCT col0 + cor0.col0 / col2 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT + - cor0.col1 * col0 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query III rowsort
SELECT * FROM tab1 WHERE - col0 > col0 AND NOT ( col0 ) > col1 * col2
----

query I rowsort
SELECT - col1 * - cor0.col1 * col0 AS col2 FROM tab1 cor0
----
13520
2028
6400

query I rowsort
SELECT + col1 + + col1 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT + col1 * - col1 * - col0 + + col2 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT - col0 * - col2 + col0 * + col1 AS col0 FROM tab2 AS cor0
----
406
4345
6630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4391
SELECT + col1 DIV tab0.col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4391
SELECT + col1 / tab0.col2 FROM tab0
----
1
2
97

query I rowsort
SELECT 5 + + 88 FROM tab2, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4393
SELECT col2 - + CAST( + 69 AS SIGNED ) * - col0 FROM tab0
----
1689
2416
6223

skipif mysql # not compatible
query I rowsort label-4393
SELECT col2 - + CAST ( + 69 AS INTEGER ) * - col0 FROM tab0
----
1689
2416
6223

onlyif mysql # use DIV operator for integer division
query I rowsort label-4394
SELECT + cor0.col1 DIV - cor0.col0 AS col2 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4394
SELECT + cor0.col1 / - cor0.col0 AS col2 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT + col0 + 51 AS col1 FROM tab1 AS cor0
----
115
131
54

query I rowsort
SELECT ALL + - col2 + col0 + 42 FROM tab1 cor0
----
-9
26
49

query I rowsort
SELECT ALL - col0 * - col1 + - col1 * + 95 FROM tab0 AS cor0
----
-546
-5820
-6106

onlyif mysql # use DIV operator for integer division
query I rowsort label-4398
SELECT 2 * col0 DIV + col2 + - col1 * - col0 AS col2 FROM tab1
----
1041
642
78

skipif mysql # not compatible
query I rowsort label-4398
SELECT 2 * col0 / + col2 + - col1 * - col0 AS col2 FROM tab1
----
1041
642
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4399
SELECT + - col1 DIV - 96 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4399
SELECT + - col1 / - 96 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + + 58 * col0 FROM tab0 AS cor0
----
1368
1995
5073

query I rowsort
SELECT + - 12 AS col2 FROM tab1 AS cor0
----
-12
-12
-12

query I rowsort
SELECT ALL + - col0 * + 48 * col1 FROM tab0 AS cor0
----
-162960
-388752
-99072

query I rowsort
SELECT DISTINCT + 46 + + col1 FROM tab1
----
56
59
72

query I rowsort
SELECT 9 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 84 col1 FROM tab1, tab2, tab1 cor0
----
-84

query I rowsort
SELECT ALL - ( col2 ) + col2 * + 39 + + col0 FROM tab0 AS cor0
----
1278
3205
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 + col0 col0 FROM tab1 AS cor0
----
143
159
82

query I rowsort
SELECT DISTINCT cor0.col0 + - col2 * + col0 AS col0 FROM tab2 cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + + col0 * col1 - + col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT - 98 * - col1 * 34 - - col2 * col2 FROM tab2 AS cor0
----
104021
197264
58088

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4411
SELECT ALL - + 7 * col1 + - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4411
SELECT ALL - + 7 * col1 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 19 * + col2 col0 FROM tab2 AS cor0
----
494
513
722

query I rowsort
SELECT - col2 + + ( + col1 ) AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + cor0.col1 + col1 * + 39 FROM tab2 AS cor0
----
1240
2360
680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4415
SELECT DISTINCT + col0 * CAST( NULL AS SIGNED ) + + cor0.col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4415
SELECT DISTINCT + col0 * CAST ( NULL AS INTEGER ) + + cor0.col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 * + 34 AS col2 FROM tab2 cor0
----
-1054
-2006
-578

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * 72 + col2 col2 FROM tab2 AS cor0
----
-1186
-2205
-4222

query I rowsort
SELECT ALL col1 + - 59 - - 50 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-2733
-2899
-4846

query I rowsort
SELECT ALL - col2 + col1 * + cor0.col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT - - col0 * - 38 + col0 FROM tab1 cor0
----
-111
-2368
-2960

query I rowsort
SELECT cor0.col0 + + 45 AS col0 FROM tab0 cor0
----
134
69
80

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + 31 FROM tab0 AS cor0
----
1256
607
7952

query I rowsort
SELECT DISTINCT + col1 + - col0 + col2 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT - + cor0.col1 * - ( - 73 ) + + col0 * ( col2 ) FROM tab2 AS cor0
----
-2074
-2279
1761

query I rowsort
SELECT DISTINCT 6 + + col1 FROM tab2
----
23
37
65

query I rowsort
SELECT ALL + col2 * ( + col1 * - col0 ) + - 38 AS col0 FROM tab0 AS cor0
----
-3433
-664156
-68150

query I rowsort
SELECT - col2 - col0 AS col1 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT + + col2 + ( col2 * col2 ) FROM tab0 AS cor0
----
1122
2
6806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4429
SELECT DISTINCT + - cor0.col0 + CAST( NULL AS DECIMAL ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4429
SELECT DISTINCT + - cor0.col0 + CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + + cor0.col2 * - 95 + + col1 * col2 FROM tab0 AS cor0
----
-297
-328
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * col0 - - 59 col2 FROM tab0 AS cor0
----
-1166
-517
-7862

query I rowsort
SELECT 43 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4433
SELECT + + col0 + + col0 DIV col1 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4433
SELECT + + col0 + + col0 / col1 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 23 + + col2 col2 FROM tab2 AS cor0
----
1820
1855
188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4435
SELECT - CAST( NULL AS SIGNED ) * + 54 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4435
SELECT - CAST ( NULL AS INTEGER ) * + 54 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * col2 + - col1 * col2 AS col1 FROM tab2 AS cor0
----
-108
-858
798

query I rowsort
SELECT ALL 34 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT + col2 * col1 + + col0 + - col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col1 * + 12 * - col2 + + col2 - col1 FROM tab1
----
15059
16876
6887

query I rowsort
SELECT DISTINCT - tab0.col2 * col2 - col0 FROM tab0
----
-1113
-36
-6813

query I rowsort
SELECT DISTINCT - 56 + + col0 AS col0 FROM tab1 AS cor0
----
-53
24
8

query I rowsort
SELECT DISTINCT col2 * col0 * + cor0.col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - 53 + + col1 FROM tab2 cor0
----
-22
-36
6

query I rowsort
SELECT ALL - 61 * + col2 FROM tab1 cor0
----
-3294
-3477
-5856

query I rowsort
SELECT 94 + + 77 * col1 * - 98 FROM tab1
----
-196102
-75366
-98004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 62 col0 FROM tab1
----
62
62
62

query I rowsort
SELECT DISTINCT - 76 * 0 FROM tab2
----
0

query I rowsort
SELECT DISTINCT + 44 AS col0 FROM tab2, tab0, tab2 AS cor0
----
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-4449
SELECT + col1 DIV - 10 AS col2 FROM tab1
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-4449
SELECT + col1 / - 10 AS col2 FROM tab1
----
-1
-1
-2

query I rowsort
SELECT - cor1.col2 FROM tab2, tab2 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to c569638e8a09ff819458d62ddbde994c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col2 ) + - col1 col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT + 42 + + col0 * - col1 FROM tab1 cor0
----
-36
-598
-998

query I rowsort
SELECT + - ( col1 ) + + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( + col1 ) * ( 10 ) AS col1 FROM tab2 cor0
----
170
310
590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * - tab0.col2 col0 FROM tab0, tab2 cor0
----
9 values hashing to 86c8e75d83d283b29460c020ab5988af

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4456
SELECT ALL + col1 * col2 + CAST( col0 AS SIGNED ) + + col1 AS col1 FROM tab1 AS cor0
----
1341
1433
644

skipif mysql # not compatible
query I rowsort label-4456
SELECT ALL + col1 * col2 + CAST ( col0 AS INTEGER ) + + col1 AS col1 FROM tab1 AS cor0
----
1341
1433
644

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4457
SELECT col2 * + col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4457
SELECT col2 * + col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 44 * col0 - col2 FROM tab1 AS cor0
----
-186
-2873
-3616

query I rowsort
SELECT + 74 * + col0 + 60 FROM tab2 AS cor0
----
578
5832
5906

onlyif mysql # use DIV operator for integer division
query I rowsort label-4460
SELECT tab2.col2 DIV + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to d38b0634e14aec1019f26e61932e2843

skipif mysql # not compatible
query I rowsort label-4460
SELECT tab2.col2 / + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to d38b0634e14aec1019f26e61932e2843

query I rowsort
SELECT - col1 * col1 * + col2 AS col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL 19 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT + col0 * - col0 + ( col0 ) FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-4464
SELECT 91 * + col1 * 78 + - col1 DIV + cor0.col0 + ( - col1 ) AS col1 FROM tab0 AS cor0
----
610339
645826
688407

skipif mysql # not compatible
query I rowsort label-4464
SELECT 91 * + col1 * 78 + - col1 / + cor0.col0 + ( - col1 ) AS col1 FROM tab0 AS cor0
----
610339
645826
688407

query I rowsort
SELECT - 92 + col0 * col2 FROM tab0 AS cor0
----
-57
700
7206

query I rowsort
SELECT DISTINCT + 4 * - cor0.col0 FROM tab1 cor0
----
-12
-256
-320

query I rowsort
SELECT ALL - 16 * ( tab1.col1 ) AS col0 FROM tab1
----
-160
-208
-416

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - cor0.col0 ) * + 50 + 92 col0 FROM tab1 AS cor0
----
-3108
-3908
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-4469
SELECT ALL col1 DIV - cor0.col2 col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4469
SELECT ALL col1 / - cor0.col2 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 - + col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT - col1 * + 14 AS col1 FROM tab1 AS cor0
----
-140
-182
-364

query I rowsort
SELECT ALL col2 + 67 - - col1 * cor0.col1 FROM tab1 AS cor0
----
224
332
797

query I rowsort
SELECT ALL + + cor0.col1 + - ( - col2 ) AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col1 * 79 FROM tab1 AS cor0
----
1027
2054
790

query I rowsort
SELECT + + col0 + - col1 * col2 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4476
SELECT + col0 * - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4476
SELECT + col0 * - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 50 + - col1 AS col1 FROM tab0 AS cor0
----
-36
-41
-47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4478
SELECT ALL + col1 + + CAST( NULL AS DECIMAL ) + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4478
SELECT ALL + col1 + + CAST ( NULL AS REAL ) + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + cor0.col2 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
1478
791
794

query I rowsort
SELECT - 55 - - cor0.col2 FROM tab2 AS cor0
----
-17
-28
-29

query I rowsort
SELECT ALL ( 40 ) AS col2 FROM tab2 AS cor0
----
40
40
40

query I rowsort
SELECT col0 + col0 + + col1 AS col2 FROM tab0 AS cor0
----
134
167
269

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + 65 AS REAL ) + - col0 AS col1 FROM tab2 AS cor0
----
-13
-14
58

query I rowsort
SELECT cor0.col0 + - col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( - col2 ) + + col1 * 86 AS col0 FROM tab0 AS cor0
----
7363
7744
8341

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4486
SELECT ALL + + CAST( col1 AS SIGNED ) * + col2 AS col0 FROM tab1 cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-4486
SELECT ALL + + CAST ( col1 AS INTEGER ) * + col2 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col1 - 6 FROM tab2 AS cor0
----
11
25
53

query I rowsort
SELECT col0 - ( col0 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col0 * 53 FROM tab0
----
1272
1855
4717

query I rowsort
SELECT 14 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 col1 FROM tab0, tab2 cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT - 96 * col1 FROM tab1 AS cor0
----
-1248
-2496
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 61 col2 FROM tab2 AS cor0
----
61
61
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4494
SELECT DISTINCT - cor0.col1 DIV + 83 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4494
SELECT DISTINCT - cor0.col1 / + 83 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 82 + - col1 col2 FROM tab0 AS cor0
----
-15
-4
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + - cor0.col0 col1 FROM tab1 cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( ( - col2 ) ) col0 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4498
SELECT ALL - col1 DIV + 44 col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4498
SELECT ALL - col1 / + 44 col2 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4499
SELECT + col1 DIV 40 AS col2 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-4499
SELECT + col1 / 40 AS col2 FROM tab0
----
2
2
2

query I rowsort
SELECT ALL 33 + + col2 + cor0.col2 AS col0 FROM tab2 AS cor0
----
109
85
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4501
SELECT - CAST( col0 AS SIGNED ) DIV - col2 col1 FROM tab0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4501
SELECT - CAST ( col0 AS INTEGER ) / - col2 col1 FROM tab0
----
0
1
35

query I rowsort
SELECT DISTINCT col2 * + tab2.col2 + - ( col0 ) + + col1 FROM tab2
----
1382
657
753

onlyif mysql # use DIV operator for integer division
query I rowsort label-4503
SELECT - col2 DIV + ( - col2 ) AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4503
SELECT - col2 / + ( - col2 ) AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + cor0.col1 * + ( col1 ) AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + - cor0.col2 * col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + - col0 * - ( ( col2 ) ) FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + cor0.col2 col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col2 * + col2 - col0 AS col1 FROM tab1
----
2913
3185
9136

query I rowsort
SELECT DISTINCT 4 * col2 + + tab2.col1 * col0 FROM tab2
----
1495
325
4706

query I rowsort
SELECT DISTINCT tab2.col2 * col2 * tab2.col1 + 12 FROM tab2
----
22611
24560
39896

query I rowsort
SELECT + ( + cor0.col0 ) FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL - - 21 * + cor0.col2 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT DISTINCT + 10 AS col1 FROM tab0, tab0 AS cor0
----
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-4514
SELECT DISTINCT col0 - + col2 DIV + col0 FROM tab0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-4514
SELECT DISTINCT col0 - + col2 / + col0 FROM tab0
----
23
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4515
SELECT col2 DIV 76 + col1 + col2 FROM tab1
----
110
67
80

skipif mysql # not compatible
query I rowsort label-4515
SELECT col2 / 76 + col1 + col2 FROM tab1
----
110
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - ( col2 + + col2 ) col0 FROM tab2
----
114
78
81

query I rowsort
SELECT ALL + + tab2.col0 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4518
SELECT DISTINCT tab0.col2 - + CAST( 64 * + tab0.col0 AS SIGNED ) AS col1 FROM tab0
----
-1503
-2239
-5614

skipif mysql # not compatible
query I rowsort label-4518
SELECT DISTINCT tab0.col2 - + CAST ( 64 * + tab0.col0 AS INTEGER ) AS col1 FROM tab0
----
-1503
-2239
-5614

onlyif mysql # use DIV operator for integer division
query I rowsort label-4519
SELECT + col0 DIV ( col1 + col2 ) FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4519
SELECT + col0 / ( col1 + col2 ) FROM tab2
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4520
SELECT col2 + CAST( col1 AS SIGNED ) FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-4520
SELECT col2 + CAST ( col1 AS INTEGER ) FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - 10 * 31 + col0 AS col1 FROM tab0 AS cor0
----
-221
-275
-286

query I rowsort
SELECT ALL col2 * + col1 + + col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4524
SELECT + CAST( - col1 AS SIGNED ) * + col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-4524
SELECT + CAST ( - col1 AS INTEGER ) * + col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 AS col0 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4526
SELECT ALL col1 DIV - ( col1 + - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4526
SELECT ALL col1 / - ( col1 + - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4527
SELECT ALL - col1 DIV - col1 + cor0.col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-4527
SELECT ALL - col1 / - col1 + cor0.col2 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 * 26 + + col0 col2 FROM tab0 cor0
----
2338
2349
2403

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4529
SELECT + + CAST( col2 AS SIGNED ) * cor0.col0 col1 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4529
SELECT + + CAST ( col2 AS INTEGER ) * cor0.col0 col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - - cor0.col2 - + col0 * col2 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - cor0.col2 col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 57 - + col1 AS col2 FROM tab1 cor0
----
-67
-70
-83

query I rowsort
SELECT ALL + + col0 * + col0 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT col0 - 71 FROM tab0 AS cor0
----
-36
-47
18

query I rowsort
SELECT DISTINCT + ( + col2 ) * - cor0.col2 + ( + col1 + col1 ) AS col1 FROM tab2 AS cor0
----
-1410
-558
-667

query I rowsort
SELECT ALL + col2 * + 3 AS col0 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT - 4 * 57 * - col0 + 75 AS col1 FROM tab1 AS cor0
----
14667
18315
759

query I rowsort
SELECT ALL 61 * col2 FROM tab0
----
2013
5002
61

query I rowsort
SELECT + ( 51 ) * - col1 AS col1 FROM tab2 AS cor0
----
-1581
-3009
-867

query I rowsort
SELECT DISTINCT - col2 * col1 * + col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - ( + col2 ) + col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL 83 * + tab2.col0 + + col0 * 33 FROM tab2
----
812
9048
9164

query I rowsort
SELECT ALL - - 63 + - 33 AS col0 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT DISTINCT + - col2 + + 34 FROM tab1 AS cor0
----
-20
-23
-62

query I rowsort
SELECT ALL col1 + cor0.col1 * - col1 * - col2 AS col2 FROM tab2 cor0
----
10999
25978
90565

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( cor0.col0 AS REAL ) * - col0 FROM tab2 cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + + ( col1 + col0 ) col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT - 10 + - col1 * ( + cor0.col2 ) AS col2 FROM tab0 AS cor0
----
-107
-2848
-7472

onlyif mysql # use DIV operator for integer division
query I rowsort label-4549
SELECT - - 58 DIV - cor0.col1 + - cor0.col0 FROM tab1 AS cor0
----
-5
-69
-84

skipif mysql # not compatible
query I rowsort label-4549
SELECT - - 58 / - cor0.col1 + - cor0.col0 FROM tab1 AS cor0
----
-5
-69
-84

query I rowsort
SELECT DISTINCT - 23 * - col0 AS col2 FROM tab2 cor0
----
161
1794
1817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4551
SELECT - + col2 * + col0 / CAST( NULL AS SIGNED ) + + col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4551
SELECT - + col2 * + col0 / CAST ( NULL AS INTEGER ) + + col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 12 + - cor0.col1 + 59 * col2 AS col0 FROM tab2 cor0
----
1463
1550
2213

query I rowsort
SELECT - 68 * - col2 + + col0 AS col1 FROM tab0 cor0
----
103
2268
5665

query I rowsort
SELECT + ( - col1 ) + - 70 AS col2 FROM tab0 cor0
----
-156
-161
-167

query I rowsort
SELECT DISTINCT - - 40 AS col0 FROM tab0, tab2, tab2 AS cor0
----
40

query I rowsort
SELECT ALL - 98 + 82 * + col1 FROM tab2
----
1296
2444
4740

query I rowsort
SELECT ALL + ( col1 ) + col2 AS col0 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4558
SELECT DISTINCT - 11 DIV - col2 + + col2 FROM tab0
----
12
33
82

skipif mysql # not compatible
query I rowsort label-4558
SELECT DISTINCT - 11 / - col2 + + col2 FROM tab0
----
12
33
82

query I rowsort
SELECT - 5 * + col0 FROM tab2
----
-35
-390
-395

query I rowsort
SELECT ALL col2 + col0 * - cor0.col0 AS col2 FROM tab2 cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4561
SELECT - - col1 DIV + ( + ( col0 ) ) AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-4561
SELECT - - col1 / + ( + ( col0 ) ) AS col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT col0 * 86 * col0 FROM tab1 AS cor0
----
352256
550400
774

query I rowsort
SELECT ALL + cor0.col0 * ( + 72 ) FROM tab1 AS cor0
----
216
4608
5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4564
SELECT ALL - + col0 DIV + 18 FROM tab2 AS cor0
----
-4
-4
0

skipif mysql # not compatible
query I rowsort label-4564
SELECT ALL - + col0 / + 18 FROM tab2 AS cor0
----
-4
-4
0

query I rowsort
SELECT ALL + - col2 * + ( + col0 ) AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - 20 * + col0 FROM tab2
----
-140
-1560
-1580

query I rowsort
SELECT DISTINCT - 63 AS col1 FROM tab2, tab0, tab1 AS cor0
----
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4568
SELECT col0 DIV + col1 - 55 FROM tab1
----
-49
-49
-55

skipif mysql # not compatible
query I rowsort label-4568
SELECT col0 / + col1 - 55 FROM tab1
----
-49
-49
-55

query I rowsort
SELECT ALL col0 * - 87 AS col0 FROM tab2
----
-609
-6786
-6873

query I rowsort
SELECT + - 45 - - col0 AS col1 FROM tab2 AS cor0
----
-38
33
34

query I rowsort
SELECT 60 + col2 AS col0 FROM tab0 AS cor0
----
142
61
93

query I rowsort
SELECT cor0.col1 * - 45 AS col0 FROM tab2 AS cor0
----
-1395
-2655
-765

query I rowsort
SELECT ALL - + col2 * col0 + cor0.col2 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-4574
SELECT ALL + col0 DIV - col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4574
SELECT ALL + col0 / - col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + - col1 + + 31 * + col1 FROM tab2 AS cor0
----
1770
510
930

query I rowsort
SELECT ALL 98 + - col0 FROM tab1
----
18
34
95

query I rowsort
SELECT 2 + + col1 + - 6 FROM tab0
----
82
87
93

skipif mysql # not compatible
query I rowsort
SELECT + - cor0.col1 * CAST ( - col2 * + col2 AS REAL ) + - ( cor0.col2 ) FROM tab0 cor0
----
611802
93621
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + 11 col0 FROM tab2
----
-77
-858
-869

onlyif mysql # use DIV operator for integer division
query I rowsort label-4580
SELECT col2 + - col1 DIV col1 - - col1 AS col2 FROM tab0 AS cor0
----
118
172
97

skipif mysql # not compatible
query I rowsort label-4580
SELECT col2 + - col1 / col1 - - col1 AS col2 FROM tab0 AS cor0
----
118
172
97

query I rowsort
SELECT + col2 + ( 20 ) AS col2 FROM tab1 AS cor0
----
116
74
77

query I rowsort
SELECT col1 * + ( col0 ) + - col2 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4583
SELECT ALL CAST( col1 + - col0 AS SIGNED ) col1 FROM tab2
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4583
SELECT ALL CAST ( col1 + - col0 AS INTEGER ) col1 FROM tab2
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4584
SELECT ALL CAST( col1 AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-4584
SELECT ALL CAST ( col1 AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + 58 AS col0 FROM tab2 AS cor0
----
-58
-58
-58

query I rowsort
SELECT - 27 AS col2 FROM tab0 cor0
----
-27
-27
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4587
SELECT ALL col1 * col2 DIV cor0.col2 - - 34 AS col1 FROM tab0 AS cor0
----
120
125
131

skipif mysql # not compatible
query I rowsort label-4587
SELECT ALL col1 * col2 / cor0.col2 - - 34 AS col1 FROM tab0 AS cor0
----
120
125
131

query I rowsort
SELECT ALL - - cor0.col2 * 40 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT DISTINCT + - 45 + col0 AS col1 FROM tab0 cor0
----
-10
-21
44

query I rowsort
SELECT - 58 + - 4 * + col2 FROM tab0 AS cor0
----
-190
-386
-62

query I rowsort
SELECT ALL - col0 * - 90 FROM tab1 AS cor0
----
270
5760
7200

query I rowsort
SELECT DISTINCT col1 * 53 FROM tab2 AS cor0
----
1643
3127
901

onlyif mysql # use DIV operator for integer division
query I rowsort label-4593
SELECT ALL + 89 * - col1 DIV + col1 AS col0 FROM tab1 cor0
----
-89
-89
-89

skipif mysql # not compatible
query I rowsort label-4593
SELECT ALL + 89 * - col1 / + col1 AS col0 FROM tab1 cor0
----
-89
-89
-89

query I rowsort
SELECT DISTINCT ( + col0 ) * col1 + col0 * - col0 AS col1 FROM tab2 cor0
----
-1482
-4898
168

query I rowsort
SELECT - col2 * cor0.col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 99 * - col2 AS col1 FROM tab2
----
-2574
-2673
-3762

query I rowsort
SELECT + 8 * - col2 AS col0 FROM tab0 AS cor0
----
-264
-656
-8

query I rowsort
SELECT ( col0 ) + 35 * col0 FROM tab2 AS cor0
----
252
2808
2844

query I rowsort
SELECT ALL 86 + col1 * - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-108
-2838
-7467

query I rowsort
SELECT DISTINCT - 32 + col2 * col2 + col2 FROM tab2 cor0
----
1450
670
724

query I rowsort
SELECT ALL 79 * col1 + cor0.col0 AS col2 FROM tab1 AS cor0
----
1107
2057
854

query I rowsort
SELECT DISTINCT - 54 * - col2 + - col1 * + cor0.col0 * + col1 AS col2 FROM tab0 AS cor0
----
-175722
-329261
-732581

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * col2 - - col0 col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT 87 * + cor0.col1 FROM tab2 AS cor0
----
1479
2697
5133

query I rowsort
SELECT - 64 AS col1 FROM tab0 cor0
----
-64
-64
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4606
SELECT ALL - col1 * CAST( col1 AS SIGNED ) + col1 * 83 FROM tab2 cor0
----
1122
1416
1612

skipif mysql # not compatible
query I rowsort label-4606
SELECT ALL - col1 * CAST ( col1 AS INTEGER ) + col1 * 83 FROM tab2 cor0
----
1122
1416
1612

query I rowsort
SELECT - 18 * - col0 - ( tab2.col1 ) * + col1 AS col2 FROM tab2
----
-2077
-835
1133

query I rowsort
SELECT ( + col0 ) * col0 + cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT + - col1 * 73 AS col1 FROM tab2 AS cor0
----
-1241
-2263
-4307

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4610
SELECT ALL + col1 + - col1 * col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4610
SELECT ALL + col1 + - col1 * col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 93 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT - - ( col0 ) + + col0 * - 2 * - col2 AS col2 FROM tab1 AS cor0
----
15440
327
7360

query I rowsort
SELECT - + 15 * col1 AS col1 FROM tab2 AS cor0
----
-255
-465
-885

query I rowsort
SELECT DISTINCT + 53 * - 41 FROM tab0
----
-2173

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col0 * - col1 col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ( 17 ) - col2 AS col0 FROM tab2
----
-10
-21
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4617
SELECT 2 DIV tab2.col0 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-4617
SELECT 2 / tab2.col0 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + col2 - 58 FROM tab0
----
-25
-57
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + ( tab2.col1 ) * - ( - col0 + - col1 ) col1 FROM tab2
----
1209
1649
8142

onlyif mysql # use DIV operator for integer division
query I rowsort label-4620
SELECT col2 DIV - col2 + - col0 * - col0 col2 FROM tab1
----
4095
6399
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4620
SELECT col2 / - col2 + - col0 * - col0 col2 FROM tab1
----
4095
6399
8

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT col2 BETWEEN NULL AND NULL
----

query I rowsort
SELECT + tab2.col0 * col2 * col2 + - col1 FROM tab2
----
114059
5072
52669

query III rowsort
SELECT * FROM tab2 WHERE - col1 NOT BETWEEN - col1 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + tab0.col1 col0 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL - col0 * tab1.col0 * col2 + col1 * col0 * - col1 FROM tab1
----
-239872
-2514
-627920

query I rowsort
SELECT - col0 + + col0 * col1 FROM tab0
----
2040
3360
8010

query III rowsort
SELECT * FROM tab1 WHERE NOT - col2 NOT IN ( + col2 )
----

query I rowsort
SELECT DISTINCT col2 + + col1 * + tab1.col1 + col1 AS col0 FROM tab1
----
167
278
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-4629
SELECT + tab0.col1 DIV tab0.col1 AS col2 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4629
SELECT + tab0.col1 / tab0.col1 AS col2 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4630
SELECT DISTINCT col1 * col1 DIV + tab2.col1 AS col2 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4630
SELECT DISTINCT col1 * col1 / + tab2.col1 AS col2 FROM tab2
----
17
31
59

query III rowsort
SELECT * FROM tab0 WHERE NOT col2 * + col1 - - col1 BETWEEN ( col2 ) AND ( col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - - 46 + col1 AS col1 FROM tab1 AS cor0
----
56
59
72

query I rowsort
SELECT DISTINCT + col0 + + col0 + - col1 * col0 FROM tab1
----
-512
-72
-880

query I rowsort
SELECT 24 + col0 FROM tab0 AS cor0
----
113
48
59

query I rowsort
SELECT - col2 + col1 * col1 + + col1 * - col0 FROM tab2
----
-1092
-1147
717

query I rowsort
SELECT tab0.col1 * col1 + + col2 FROM tab0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 * + col1 * col2 col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT tab2.col0 * - col2 + col2 * tab2.col2 FROM tab2
----
-1352
-1558
540

query I rowsort
SELECT col1 + - tab2.col0 * col0 - col0 FROM tab2
----
-25
-6103
-6303

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL NOT IN ( - col2 + + col2 + + tab0.col1 * - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4641
SELECT DISTINCT + col1 + col1 DIV + col0 AS col2 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-4641
SELECT DISTINCT + col1 + col1 / + col0 AS col2 FROM tab2
----
17
35
59

query I rowsort
SELECT DISTINCT + col1 + col2 AS col0 FROM tab2 WHERE NULL IN ( tab2.col2 )
----

query I rowsort
SELECT col0 FROM tab1 AS cor0 WHERE NULL = col1
----

query I rowsort
SELECT col1 * - col0 + tab1.col1 AS col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT - col2 + - col2 * + col2 AS col2 FROM tab1
----
-2970
-3306
-9312

query I rowsort
SELECT tab0.col0 - + col2 * + col0 AS col1 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - tab1.col0 FROM tab1 WHERE NOT ( + col0 - col0 ) > ( col2 )
----
-3
-64
-80

query I rowsort
SELECT ALL - col2 * - col1 + col2 - + col2 AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT col2 FROM tab0 WHERE NULL IN ( col0 * + col2 )
----

query I rowsort
SELECT ALL col2 + col2 * - col1 * col2 - + col0 * - col1 FROM tab1
----
-118672
-31793
-75684

query I rowsort
SELECT ALL col1 * col0 * + col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT ALL col0 + col1 + - col0 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4653
SELECT ALL - col2 DIV - tab0.col2 AS col2 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4653
SELECT ALL - col2 / - tab0.col2 AS col2 FROM tab0
----
1
1
1

query I rowsort
SELECT col2 * - tab0.col0 * + col1 AS col0 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-4655
SELECT ALL - col2 DIV cor0.col2 - col1 AS col2 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-4655
SELECT ALL - col2 / cor0.col2 - col1 AS col2 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT + col0 + + col0 AS col0 FROM tab1 WHERE NOT NULL NOT IN ( - col1 * col2 + - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4657
SELECT col1 - - tab2.col0 DIV - col1 AS col2 FROM tab2
----
13
31
58

skipif mysql # not compatible
query I rowsort label-4657
SELECT col1 - - tab2.col0 / - col1 AS col2 FROM tab2
----
13
31
58

query I rowsort
SELECT cor0.col0 + - cor0.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 cor1
----
27 values hashing to b4cba4f278386334ce9a7cc0fa9e286a

query I rowsort
SELECT - 2 * + col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT - 79 AS col1 FROM tab2, tab1 AS cor0
----
-79

query I rowsort
SELECT ALL - cor0.col2 * 44 FROM tab1, tab1 cor0
----
9 values hashing to 6417af374ff403fda9c8f49bb0b3529f

query I rowsort
SELECT ALL ( ( + col0 ) ) * 28 FROM tab1
----
1792
2240
84

query I rowsort
SELECT DISTINCT 2 AS col2 FROM tab1, tab2 cor0
----
2

query I rowsort
SELECT DISTINCT - + col2 * col1 * - col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - col2 * ( col1 ) * ( - col2 * col2 ) AS col2 FROM tab2
----
1036984
610173
932824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col2 FROM tab1, tab0 cor0, tab2 cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ( cor0.col1 ) AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + ( - cor0.col2 ) + - cor0.col2 * 16 AS col0 FROM tab0 AS cor0
----
-1394
-17
-561

query I rowsort
SELECT - col2 * + 25 * - col2 + + 12 * ( col0 ) + - 89 FROM tab2 AS cor0
----
17747
18220
36959

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - ( col2 ) * + col0 col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - 58 + + col0 FROM tab1
----
-55
22
6

query I rowsort
SELECT + 61 + col1 * ( col2 ) AS col0 FROM tab0
----
158
2899
7523

query I rowsort
SELECT ALL + 64 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT 68 + col0 * - ( + col0 ) AS col1 FROM tab0 AS cor0
----
-1157
-508
-7853

onlyif mysql # use DIV operator for integer division
query I rowsort label-4675
SELECT ALL + col0 * col1 + + 3 DIV - ( col1 ) FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-4675
SELECT ALL + col0 * col1 + + 3 / - ( col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - ( + col0 ) * + col2 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT + 28 + col2 FROM tab1 AS cor0
----
124
82
85

query I rowsort
SELECT ALL - col0 * col1 * + ( col2 ) + + col1 AS col0 FROM tab0 AS cor0
----
-3298
-664027
-68026

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + col2 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - 78 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

query I rowsort
SELECT DISTINCT + 27 - + col2 AS col1 FROM tab1 AS cor0
----
-27
-30
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col2 col0 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4683
SELECT - col1 + - CAST( NULL AS SIGNED ) * 72 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4683
SELECT - col1 + - CAST ( NULL AS INTEGER ) * 72 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4684
SELECT DISTINCT - col0 DIV + 44 + 35 FROM tab2 AS cor0
----
34
35

skipif mysql # not compatible
query I rowsort label-4684
SELECT DISTINCT - col0 / + 44 + 35 FROM tab2 AS cor0
----
34
35

query I rowsort
SELECT col2 + col0 * + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL + col1 + + 7 * 51 AS col2 FROM tab1 AS cor0
----
367
370
383

query I rowsort
SELECT DISTINCT + col2 * col2 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ( - 39 ) + - cor0.col0 * col2 AS col0 FROM tab0 AS cor0
----
-7337
-74
-831

query I rowsort
SELECT ALL - col0 * + 85 AS col1 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT DISTINCT + 75 + + col1 FROM tab0 AS cor0
----
161
166
172

query I rowsort
SELECT ALL cor0.col0 + - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + 38 - - col2 FROM tab0 AS cor0
----
120
39
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4693
SELECT - CAST( NULL AS SIGNED ) * 51 + col2 * col2 * tab2.col0 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4693
SELECT - CAST ( NULL AS INTEGER ) * 51 + col2 * col2 * tab2.col0 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 35 FROM tab0, tab0 cor0
----
-35

query I rowsort
SELECT col0 * 20 - col2 AS col1 FROM tab0
----
1698
447
699

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4696
SELECT ALL - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4696
SELECT ALL - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( tab1.col1 ) * - col0 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + cor0.col2 + + ( + cor0.col0 + + col1 ) FROM tab1 AS cor0
----
131
189
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4699
SELECT - - col0 * CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-4699
SELECT - - col0 * CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - col1 * cor0.col0 * - col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 40 col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-4702
SELECT + col0 DIV - ( + 85 ) FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4702
SELECT + col0 / - ( + 85 ) FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT col2 + - col1 * - 46 AS col0 FROM tab2 AS cor0
----
1453
2740
820

query I rowsort
SELECT - + col0 * - col1 + cor0.col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-4705
SELECT + col0 + col2 DIV 72 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4705
SELECT + col0 + col2 / 72 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT col2 * tab2.col1 * + col0 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL - col2 + - col0 * col0 AS col2 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT - col1 + col1 + - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - col1 * col2 + - col0 AS col1 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT col0 FROM tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - col1 * col0 OR NULL < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4711
SELECT - cor0.col2 * col2 DIV col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4711
SELECT - cor0.col2 * col2 / col2 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4712
SELECT ALL + col0 + - col2 DIV + col0 + + col0 * col1 FROM tab1 AS cor0
----
1119
63
704

skipif mysql # not compatible
query I rowsort label-4712
SELECT ALL + col0 + - col2 / + col0 + + col0 * col1 FROM tab1 AS cor0
----
1119
63
704

query I rowsort
SELECT col1 + col1 * - col0 + + col1 AS col1 FROM tab1 AS cor0
----
-1014
-26
-620

query I rowsort
SELECT DISTINCT - - cor0.col2 * col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col2 * + col0 * + col2 FROM tab1 AS cor0
----
207936
737280
8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-4716
SELECT cor0.col0 * col2 DIV col2 + col1 + col2 AS col0 FROM tab0 AS cor0
----
133
143
262

skipif mysql # not compatible
query I rowsort label-4716
SELECT cor0.col0 * col2 / col2 + col1 + col2 AS col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT + - col1 * col1 + + col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - col1 * col0 col0 FROM tab2
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-4719
SELECT + 2 DIV - cor0.col2 - + col0 * - col2 AS col0 FROM tab1 cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4719
SELECT + 2 / - cor0.col2 - + col0 * - col2 AS col0 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4720
SELECT DISTINCT + - col1 + - cor0.col0 DIV col2 AS col2 FROM tab0 AS cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-4720
SELECT DISTINCT + - col1 + - cor0.col0 / col2 AS col2 FROM tab0 AS cor0
----
-132
-86
-92

query I rowsort
SELECT DISTINCT - + col0 * + col1 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT + col1 * + col2 - - col0 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - - cor0.col0 + - col0 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4724
SELECT ALL - cor0.col1 DIV col0 + + cor0.col1 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-4724
SELECT ALL - cor0.col1 / col0 + + cor0.col1 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT ALL + - col1 * + col1 + - col2 * col1 * col0 FROM tab2 AS cor0
----
-123133
-51323
-6820

query I rowsort
SELECT - col2 * - col1 * - col1 + col2 + col0 AS col1 FROM tab2 cor0
----
-10865
-25913
-90402

query I rowsort
SELECT DISTINCT + col2 - - col1 AS col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4728
SELECT ALL - ( - col2 * CAST( - 43 AS SIGNED ) + - col1 ) AS col2 FROM tab1
----
-2296
-2441
-4115

skipif mysql # not compatible
query I rowsort label-4728
SELECT ALL - ( - col2 * CAST ( - 43 AS INTEGER ) + - col1 ) AS col2 FROM tab1
----
-2296
-2441
-4115

query I rowsort
SELECT ALL + + col2 * + col1 + 50 AS col0 FROM tab0 AS cor0
----
147
2888
7512

query I rowsort
SELECT DISTINCT - ( + col0 ) * + col2 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT 42 + col1 AS col0 FROM tab2 AS cor0
----
101
59
73

query I rowsort
SELECT ALL - - 55 + - col0 FROM tab0 AS cor0
----
-34
20
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-4733
SELECT DISTINCT + 17 - col0 DIV + 92 FROM tab0 cor0
----
17

skipif mysql # not compatible
query I rowsort label-4733
SELECT DISTINCT + 17 - col0 / + 92 FROM tab0 cor0
----
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + col0 * + ( 26 * - col2 ) - + 58 * 42 col0 FROM tab2 AS cor0
----
-55242
-7357
-80567

query I rowsort
SELECT DISTINCT col2 * - col0 + ( cor0.col2 ) FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + - col2 * 73 * + col2 + + col1 * ( + cor0.col2 ) FROM tab1 AS cor0
----
-211464
-236607
-671520

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4737
SELECT - col2 * + ( col2 * + col2 ) + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4737
SELECT - col2 * + ( col2 * + col2 ) + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 + 89 * + 64 FROM tab1 AS cor0
----
5706
5709
5722

query I rowsort
SELECT + col1 + - ( cor0.col2 * - col1 ) AS col0 FROM tab0 cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-4740
SELECT DISTINCT + - col2 + - 6 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4740
SELECT DISTINCT + - col2 + - 6 / cor0.col2 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL tab1.col1 * + col1 * + col1 + + tab1.col0 - col2 * + 49 * + col0 AS col2 FROM tab1
----
-177688
-374043
9641

query I rowsort
SELECT - - col0 - ( 99 ) * col0 * ( - col0 ) FROM tab2 cor0
----
4858
602394
617938

query I rowsort
SELECT - ( 15 ) + col1 FROM tab1 AS cor0
----
-2
-5
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( 2 ) col0 FROM tab0 AS cor0
----
-2

query I rowsort
SELECT + + col0 * - 97 * col2 FROM tab2 AS cor0
----
-18333
-196716
-291194

onlyif mysql # use DIV operator for integer division
query I rowsort label-4746
SELECT ALL - CAST( 2 AS SIGNED ) + col0 DIV col0 + 83 col1 FROM tab1 cor0
----
82
82
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4746
SELECT ALL - CAST ( 2 AS INTEGER ) + col0 / col0 + 83 col1 FROM tab1 cor0
----
82
82
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - col2 col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT 33 * - col1 FROM tab1 AS cor0
----
-330
-429
-858

query I rowsort
SELECT ALL + ( + col2 ) * - col0 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - cor0.col2 * col1 + - col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT - - 51 + - 86 * + col0 FROM tab0 AS cor0
----
-2013
-2959
-7603

query I rowsort
SELECT DISTINCT - 38 + - col2 + - ( - col1 ) * col1 AS col2 FROM tab1 AS cor0
----
35
5
584

query I rowsort
SELECT ALL - col1 * col1 + col1 * - 66 FROM tab1 AS cor0
----
-1027
-2392
-760

query I rowsort
SELECT ALL - + ( col0 ) - 93 FROM tab1 cor0
----
-157
-173
-96

query I rowsort
SELECT ALL - col0 * 29 AS col1 FROM tab0
----
-1015
-2581
-696

query I rowsort
SELECT ALL - cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT DISTINCT 48 FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
48

query I rowsort
SELECT DISTINCT - + cor0.col1 AS col2 FROM tab0, tab2, tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 89 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
89

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 + 23 * cor0.col2 FROM tab2 AS cor0
----
598
621
874

onlyif mysql # use DIV operator for integer division
query I rowsort label-4762
SELECT DISTINCT + ( col2 ) - - col1 DIV col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4762
SELECT DISTINCT + ( col2 ) - - col1 / col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col0 + - ( col1 ) AS col2 FROM tab2
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4764
SELECT DISTINCT col2 * ( - 9 * + col0 ) + - col0 + tab0.col2 DIV - col2 FROM tab0
----
-351
-65772
-7153

skipif mysql # not compatible
query I rowsort label-4764
SELECT DISTINCT col2 * ( - 9 * + col0 ) + - col0 + tab0.col2 / - col2 FROM tab0
----
-351
-65772
-7153

query I rowsort
SELECT ALL - 73 + tab2.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to fb1b6ae0d940505dd5ada69272cfaa4d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4766
SELECT CAST( NULL AS SIGNED ) + 1 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4766
SELECT CAST ( NULL AS INTEGER ) + 1 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4767
SELECT DISTINCT - col2 / CAST( NULL AS DECIMAL ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4767
SELECT DISTINCT - col2 / CAST ( NULL AS REAL ) AS col0 FROM tab1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4768
SELECT ALL col0 * - CAST( NULL AS SIGNED ) + + col1 * - col2 * col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4768
SELECT ALL col0 * - CAST ( NULL AS INTEGER ) + + col1 * - col2 * col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col2 ) * tab1.col1 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL col1 + + 3 FROM tab1 AS cor0
----
13
16
29

query I rowsort
SELECT DISTINCT + ( 6 ) * + cor0.col1 * - col0 FROM tab2 AS cor0
----
-1302
-27612
-8058

query I rowsort
SELECT ALL + + 54 * - col1 AS col0 FROM tab2 AS cor0
----
-1674
-3186
-918

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - col1 * 43 * - col1 FROM tab1
----
29068
4300
7267

query I rowsort
SELECT - ( + col2 ) + col0 * col0 AS col2 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT + + 0 * col2 + + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 61 + ( col1 * - col2 ) FROM tab1 AS cor0
----
-1187
-1343
-509

query I rowsort
SELECT DISTINCT + ( col2 ) * + cor0.col1 + - col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + 10 * col0 + col0 * 26 * 36 + col1 FROM tab1 AS cor0
----
2864
60554
75693

query I rowsort
SELECT ALL + 66 * col1 AS col0 FROM tab1 cor0
----
1716
660
858

query I rowsort
SELECT col1 + 23 AS col2 FROM tab0 AS cor0
----
109
114
120

query I rowsort
SELECT ALL col1 + + 78 AS col2 FROM tab0
----
164
169
175

query I rowsort
SELECT ALL + col0 * col0 + col1 * col2 FROM tab0
----
1322
15383
3414

query I rowsort
SELECT DISTINCT + - col1 * cor0.col1 * - col0 - 88 * + col1 FROM tab0 AS cor0
----
169936
320779
729001

query I rowsort
SELECT + 0 * + col1 + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - 58 + - 33 AS col0 FROM tab0 AS cor0
----
-91
-91
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-4787
SELECT + - col2 + - col2 DIV + 77 AS col1 FROM tab0 AS cor0
----
-1
-33
-83

skipif mysql # not compatible
query I rowsort label-4787
SELECT + - col2 + - col2 / + 77 AS col1 FROM tab0 AS cor0
----
-1
-33
-83

query I rowsort
SELECT - col0 + + col0 * - 5 + cor0.col1 * - col1 AS col0 FROM tab2 AS cor0
----
-1003
-3949
-763

query I rowsort
SELECT - - cor0.col2 * col1 + 23 AS col0 FROM tab2 AS cor0
----
1557
669
860

query I rowsort
SELECT - + cor0.col0 * cor0.col1 + - 1 FROM tab1 AS cor0
----
-1041
-641
-79

query I rowsort
SELECT + col2 + + cor0.col0 - + col1 * - col0 * col0 AS col0 FROM tab2 cor0
----
106214
1553
359060

query I rowsort
SELECT ALL col1 + col0 * tab2.col2 AS col2 FROM tab2
----
2087
220
3019

query I rowsort
SELECT DISTINCT + ( col1 ) + col2 * - 28 FROM tab0
----
-2205
-838
69

query I rowsort
SELECT DISTINCT - 94 + tab1.col0 FROM tab1
----
-14
-30
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-4795
SELECT ALL ( - col2 * col1 ) + col2 DIV col0 + - col1 FROM tab1
----
-1260
-1412
-580

skipif mysql # not compatible
query I rowsort label-4795
SELECT ALL ( - col2 * col1 ) + col2 / col0 + - col1 FROM tab1
----
-1260
-1412
-580

query I rowsort
SELECT ALL - col2 - col0 * col1 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL + 74 * - tab1.col0 AS col2 FROM tab1
----
-222
-4736
-5920

query I rowsort
SELECT ALL + + col0 + - 3 AS col2 FROM tab1 AS cor0
----
0
61
77

query I rowsort
SELECT + - col0 + + 61 * - 67 * - col1 AS col0 FROM tab2 AS cor0
----
126690
241055
69400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT DISTINCT col2 DIV + tab0.col2 - + 83 AS col1 FROM tab0
----
-82

skipif mysql # not compatible
query I rowsort label-4800
SELECT DISTINCT col2 / + tab0.col2 - + 83 AS col1 FROM tab0
----
-82

query I rowsort
SELECT col1 + - col2 * - col2 AS col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT DISTINCT - - 0 * cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
0

query I rowsort
SELECT - + cor0.col2 + ( + 47 * + cor0.col1 + + cor0.col0 ) FROM tab2 AS cor0
----
1437
2825
840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4804
SELECT - cor0.col1 + col1 DIV - col2 AS col0 FROM tab0 AS cor0
----
-194
-88
-92

skipif mysql # not compatible
query I rowsort label-4804
SELECT - cor0.col1 + col1 / - col2 AS col0 FROM tab0 AS cor0
----
-194
-88
-92

query I rowsort
SELECT ALL + - col2 + - col2 * cor0.col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT - col2 * col1 + - col1 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4807
SELECT - ( 52 ) DIV + col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-4807
SELECT - ( 52 ) / + col0 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT col0 * - col0 * - col1 AS col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - 18 * + col1 + - col2 - + col2 AS col0 FROM tab1
----
-294
-426
-576

query I rowsort
SELECT 8 * - col1 + - 25 + ( + cor0.col0 ) * 96 FROM tab1 AS cor0
----
55
6039
7551

query I rowsort
SELECT DISTINCT col1 + col1 + + col2 AS col1 FROM tab0 cor0
----
195
205
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4812
SELECT + CAST( NULL AS SIGNED ) col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4812
SELECT + CAST ( NULL AS INTEGER ) col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - 24 + col0 * - col0 FROM tab1 AS cor0
----
-33
-4120
-6424

query I rowsort
SELECT + + col2 * + cor0.col0 + ( + cor0.col2 ) * - col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + col1 * - col0 + - cor0.col2 AS col0 FROM tab1 cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-4816
SELECT ALL col2 DIV - ( - col0 + col1 ) col1 FROM tab0
----
-41
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4816
SELECT ALL col2 / - ( - col0 + col1 ) col1 FROM tab0
----
-41
0
0

query I rowsort
SELECT col2 * + 51 AS col2 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT ( - 55 ) * - col2 AS col0 FROM tab2 AS cor0
----
1430
1485
2090

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4819
SELECT - CAST( NULL AS SIGNED ) * 86 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4819
SELECT - CAST ( NULL AS INTEGER ) * 86 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 90 + + col2 AS col1 FROM tab0 AS cor0
----
-57
-8
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 79 col0 FROM tab0 AS cor0
----
165
170
176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4822
SELECT ALL CAST( + 82 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
82
82
82

skipif mysql # not compatible
query I rowsort label-4822
SELECT ALL CAST ( + 82 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
82
82
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 93 col0 FROM tab0 AS cor0
----
-93
-93
-93

query I rowsort
SELECT ALL 68 * + col1 * - cor0.col1 + + 14 FROM tab0 cor0
----
-502914
-563094
-639798

query I rowsort
SELECT + 59 + col0 * col0 FROM tab2 AS cor0
----
108
6143
6300

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 17 - col2 * + col2 col1 FROM tab1 AS cor0
----
-2899
-3232
-9199

query I rowsort
SELECT DISTINCT + 52 * + cor0.col1 FROM tab2 AS cor0
----
1612
3068
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-4828
SELECT + - col1 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4828
SELECT + - col1 / cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + cor0.col2 col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT 66 + col1 * col1 FROM tab1 AS cor0
----
166
235
742

query I rowsort
SELECT + - col0 * - 28 FROM tab0 AS cor0
----
2492
672
980

query I rowsort
SELECT ( 70 ) * cor0.col1 AS col1 FROM tab0 AS cor0
----
6020
6370
6790

query I rowsort
SELECT DISTINCT - + cor1.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
-26
-27
-38

query I rowsort
SELECT ALL + col2 * col0 * ( - 5 + - cor0.col1 ) FROM tab2 cor0
----
-129792
-66044
-6804

query I rowsort
SELECT col2 + + col0 * ( - col2 ) FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - col0 + col1 + + col0 AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL col0 * col2 - - 56 AS col1 FROM tab0 AS cor0
----
7354
848
91

query I rowsort
SELECT cor0.col1 * + col2 + + col2 * + col0 AS col2 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT ALL + + 91 * - col2 FROM tab0 AS cor0
----
-3003
-7462
-91

query I rowsort
SELECT - col1 * col1 - - ( - col1 + col2 * + col1 ) FROM tab2 AS cor0
----
-155
-2006
340

query I rowsort
SELECT DISTINCT + 11 + col2 AS col0 FROM tab2 AS cor0
----
37
38
49

query I rowsort
SELECT + col1 * cor0.col1 + 78 AS col1 FROM tab1 AS cor0
----
178
247
754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4843
SELECT DISTINCT - col1 + col0 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4843
SELECT DISTINCT - col1 + col0 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 15 * - col0 + + ( 68 ) FROM tab2 AS cor0
----
-1102
-1117
-37

query I rowsort
SELECT DISTINCT + cor0.col1 * ( + 72 ) + cor0.col2 FROM tab2 AS cor0
----
1262
2259
4274

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + 41 col0 FROM tab1 AS cor0
----
137
95
98

query I rowsort
SELECT ALL - col0 + + col0 * + col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - cor0.col2 * + 51 FROM tab0 AS cor0
----
-1683
-4182
-51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4849
SELECT + + col1 * - CAST( NULL AS SIGNED ) + - col0 * col1 + 94 * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4849
SELECT + + col1 * - CAST ( NULL AS INTEGER ) + - col0 * col1 + 94 * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + + col1 * - col0 * col2 FROM tab1 AS cor0
----
-36423
-4158
-99744

query I rowsort
SELECT ALL + - col2 * + 90 FROM tab0 cor0
----
-2970
-7380
-90

query I rowsort
SELECT col1 * - ( + cor0.col2 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + - col2 + 3 AS col1 FROM tab2 AS cor0
----
-23
-24
-35

query I rowsort
SELECT ALL col2 * col2 + col2 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
1208
6897
99

query I rowsort
SELECT - col0 * - 52 + - col0 AS col2 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT DISTINCT + col1 + + ( ( - col0 ) ) FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + col2 + + ( col0 ) AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col1 - + 46 FROM tab2 AS cor0
----
-15
-29
13

query I rowsort
SELECT ALL - col0 * 19 - + col0 * - cor0.col0 FROM tab1 AS cor0
----
-48
2880
4880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + col1 col1 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 82 + - col1 + + cor0.col2 col1 FROM tab0 AS cor0
----
-135
-178
-91

query I rowsort
SELECT + col2 + ( tab0.col1 ) * col1 FROM tab0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-4863
SELECT - col0 * col0 + col0 * col2 DIV col2 FROM tab0 AS cor0
----
-1190
-552
-7832

skipif mysql # not compatible
query I rowsort label-4863
SELECT - col0 * col0 + col0 * col2 / col2 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT col0 + cor0.col0 * ( 43 ) AS col0 FROM tab1 AS cor0
----
132
2816
3520

query I rowsort
SELECT col1 * col1 * ( 23 ) FROM tab2
----
22103
6647
80063

query I rowsort
SELECT + col2 - col0 * + col2 * cor0.col1 AS col1 FROM tab2 cor0
----
-119626
-50996
-5832

onlyif mysql # use DIV operator for integer division
query I rowsort label-4867
SELECT DISTINCT col2 DIV col2 + CAST( col2 AS SIGNED ) FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4867
SELECT DISTINCT col2 / col2 + CAST ( col2 AS INTEGER ) FROM tab1
----
55
58
97

query I rowsort
SELECT DISTINCT - ( tab1.col0 * - col0 ) FROM tab1
----
4096
6400
9

query I rowsort
SELECT DISTINCT + 20 FROM tab1, tab0 cor0
----
20

query I rowsort
SELECT ALL col2 + tab2.col0 + - col2 * 65 AS col2 FROM tab2
----
-1586
-1721
-2353

query I rowsort
SELECT ALL - col2 * col0 + 4 FROM tab2 cor0
----
-185
-2024
-2998

onlyif mysql # use DIV operator for integer division
query I rowsort label-4872
SELECT + + col0 * cor0.col1 + - col1 DIV col0 FROM tab0 AS cor0
----
2061
3393
8098

skipif mysql # not compatible
query I rowsort label-4872
SELECT + + col0 * cor0.col1 + - col1 / col0 FROM tab0 AS cor0
----
2061
3393
8098

query I rowsort
SELECT + ( col1 ) * col1 + 63 FROM tab2 AS cor0
----
1024
352
3544

query I rowsort
SELECT 71 * 21 FROM tab2, tab1 AS cor0
----
9 values hashing to f2fa345ebd6b5ea8e478f8e18ad78366

onlyif mysql # use DIV operator for integer division
query I rowsort label-4875
SELECT ALL + col1 * col1 DIV - col0 AS col1 FROM tab2
----
-137
-3
-44

skipif mysql # not compatible
query I rowsort label-4875
SELECT ALL + col1 * col1 / - col0 AS col1 FROM tab2
----
-137
-3
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + ( - 10 ) col0 FROM tab2 AS cor0
----
70
780
790

query I rowsort
SELECT + 29 + cor0.col2 - col0 * col2 AS col0 FROM tab2 AS cor0
----
-133
-1973
-2935

onlyif mysql # use DIV operator for integer division
query I rowsort label-4878
SELECT col1 DIV + col0 + cor0.col0 + + col0 AS col2 FROM tab1 cor0
----
128
14
160

skipif mysql # not compatible
query I rowsort label-4878
SELECT col1 / + col0 + cor0.col0 + + col0 AS col2 FROM tab1 cor0
----
128
14
160

query I rowsort
SELECT + + col1 + 72 FROM tab2 AS cor0
----
103
131
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4880
SELECT col1 * col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
-3395
-62
-98

skipif mysql # not compatible
query I rowsort label-4880
SELECT col1 * col0 / - col2 AS col0 FROM tab0 AS cor0
----
-3395
-62
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4881
SELECT - - 92 * ( + col1 + - cor0.col2 ) DIV col0 AS col0 FROM tab2 AS cor0
----
-24
38
52

skipif mysql # not compatible
query I rowsort label-4881
SELECT - - 92 * ( + col1 + - cor0.col2 ) / col0 AS col0 FROM tab2 AS cor0
----
-24
38
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4882
SELECT 55 DIV - 57 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-4882
SELECT 55 / - 57 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-4883
SELECT - tab0.col2 DIV ( + col1 * col1 + - 88 ) AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4883
SELECT - tab0.col2 / ( + col1 * col1 + - 88 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + cor0.col0 - - 34 FROM tab2 AS cor0
----
112
113
41

query I rowsort
SELECT DISTINCT 98 + col0 AS col1 FROM tab0 AS cor0
----
122
133
187

query I rowsort
SELECT DISTINCT - 11 + 57 AS col2 FROM tab2 cor0
----
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4887
SELECT ALL - - CAST( NULL AS SIGNED ) + ( col1 ) + - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4887
SELECT ALL - - CAST ( NULL AS INTEGER ) + ( col1 ) + - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + + ( - col2 + + col2 ) * col0 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab0, tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT col2 + 53 AS col2 FROM tab2
----
79
80
91

query I rowsort
SELECT + 87 * - 69 + - col0 + + ( - col1 ) AS col2 FROM tab2
----
-6041
-6099
-6140

query I rowsort
SELECT DISTINCT + 55 * - cor0.col0 AS col2 FROM tab0, tab0 AS cor0
----
-1320
-1925
-4895

onlyif mysql # use DIV operator for integer division
query I rowsort label-4893
SELECT ALL - - 52 * + col1 DIV + cor0.col1 + 82 AS col2 FROM tab2 AS cor0
----
134
134
134

skipif mysql # not compatible
query I rowsort label-4893
SELECT ALL - - 52 * + col1 / + cor0.col1 + 82 AS col2 FROM tab2 AS cor0
----
134
134
134

query I rowsort
SELECT - - cor0.col2 * - col2 * - col0 AS col2 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - col2 * + col0 + col2 * - col0 AS col0 FROM tab0 AS cor0
----
-14596
-1584
-70

query I rowsort
SELECT ALL - + 50 + cor0.col0 * 17 AS col1 FROM tab0 AS cor0
----
1463
358
545

onlyif mysql # use DIV operator for integer division
query I rowsort label-4898
SELECT col1 DIV - col1 + col1 * + cor0.col0 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-4898
SELECT col1 / - col1 + col1 * + cor0.col0 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT ALL tab2.col0 - tab2.col2 AS col0 FROM tab2
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4900
SELECT 26 DIV col0 + 65 col2 FROM tab0 AS cor0
----
65
65
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4900
SELECT 26 / col0 + 65 col2 FROM tab0 AS cor0
----
65
65
66

query I rowsort
SELECT DISTINCT + 77 + - col0 AS col2 FROM tab2 cor0
----
-1
-2
70

query I rowsort
SELECT ALL + 81 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-15
24
27

query I rowsort
SELECT DISTINCT + - ( col2 ) * - ( col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - - col1 + col0 * - 92 FROM tab2 cor0
----
-613
-7117
-7251

query I rowsort
SELECT - col1 * - col2 + - col2 * cor0.col2 FROM tab0 AS cor0
----
1749
738
96

query I rowsort
SELECT 19 + + col1 + + col1 * + 88 FROM tab0
----
7673
8118
8652

onlyif mysql # use DIV operator for integer division
query I rowsort label-4907
SELECT ALL + col0 DIV 76 - + col0 * tab2.col2 FROM tab2
----
-189
-2027
-3001

skipif mysql # not compatible
query I rowsort label-4907
SELECT ALL + col0 / 76 - + col0 * tab2.col2 FROM tab2
----
-189
-2027
-3001

query I rowsort
SELECT DISTINCT 3 * col1 - col0 AS col1 FROM tab0
----
184
234
256

onlyif mysql # use DIV operator for integer division
query I rowsort label-4909
SELECT DISTINCT - tab0.col1 * col2 DIV col2 - 0 AS col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4909
SELECT DISTINCT - tab0.col1 * col2 / col2 - 0 AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + 15 - tab0.col1 FROM tab0
----
-71
-76
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4911
SELECT DISTINCT - CAST( + 31 AS SIGNED ) AS col2 FROM tab0, tab2, tab2 AS cor0
----
-31

skipif mysql # not compatible
query I rowsort label-4911
SELECT DISTINCT - CAST ( + 31 AS INTEGER ) AS col2 FROM tab0, tab2, tab2 AS cor0
----
-31

query I rowsort
SELECT ALL + col2 + 25 * cor0.col0 - + col0 AS col0 FROM tab0 cor0
----
2218
609
841

query I rowsort
SELECT DISTINCT - - col1 + ( col1 ) FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - col1 + + ( + col0 * + col1 ) FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL col1 - - 48 AS col0 FROM tab0 cor0
----
134
139
145

onlyif mysql # use DIV operator for integer division
query I rowsort label-4916
SELECT DISTINCT col0 + col0 DIV col1 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-4916
SELECT DISTINCT col0 + col0 / col1 FROM tab2
----
7
79
83

query I rowsort
SELECT DISTINCT 8 FROM tab1, tab2 AS cor0
----
8

query I rowsort
SELECT + + col0 * col1 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + - col1 + col1 * + col0 AS col0 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-4920
SELECT col1 * + col1 * col2 + - 98 DIV + col2 FROM tab0 AS cor0
----
244066
679041
9311

skipif mysql # not compatible
query I rowsort label-4920
SELECT col1 * + col1 * col2 + - 98 / + col2 FROM tab0 AS cor0
----
244066
679041
9311

query I rowsort
SELECT ALL + 47 - - col2 FROM tab1 cor0
----
101
104
143

query I rowsort
SELECT ALL 80 - col1 AS col0 FROM tab0 AS cor0
----
-11
-17
-6

query I rowsort
SELECT ALL 11 - - col2 AS col1 FROM tab0 cor0
----
12
44
93

query I rowsort
SELECT DISTINCT - - 51 AS col2 FROM tab0 cor0
----
51

query I rowsort
SELECT ( - col2 + + col2 ) * + 11 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT 62 * - 69 FROM tab1
----
-4278
-4278
-4278

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * tab2.col2 + col0 * 52 * col0 col2 FROM tab2
----
317902
325178
3385

query I rowsort
SELECT + 7 + - col0 FROM tab2 AS cor0
----
-71
-72
0

query I rowsort
SELECT DISTINCT 63 * - col1 + col0 * + col0 AS col1 FROM tab0
----
-4842
-4886
2188

query I rowsort
SELECT DISTINCT 38 + + ( col1 ) FROM tab1
----
48
51
64

query I rowsort
SELECT DISTINCT - 18 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-18

query I rowsort
SELECT DISTINCT - - 76 * + col2 AS col2 FROM tab1 AS cor0
----
4104
4332
7296

query I rowsort
SELECT DISTINCT + + ( cor0.col0 ) * col2 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 8 col2 FROM tab0 AS cor0
----
8
8
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * - col2 * 55 + + col2 col1 FROM tab0 AS cor0
----
-156057
-410328
-5334

query I rowsort
SELECT ALL - 95 * + col0 AS col2 FROM tab1
----
-285
-6080
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-4937
SELECT col1 * col1 DIV col1 AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4937
SELECT col1 * col1 / col1 AS col2 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4938
SELECT + CAST( - 2 AS SIGNED ) * + col2 + + ( col1 ) FROM tab1 AS cor0
----
-104
-179
-82

skipif mysql # not compatible
query I rowsort label-4938
SELECT + CAST ( - 2 AS INTEGER ) * + col2 + + ( col1 ) FROM tab1 AS cor0
----
-104
-179
-82

query I rowsort
SELECT + 58 FROM tab0, tab2 cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT ALL + - 59 * - 11 * cor0.col1 AS col0 FROM tab0 cor0
----
55814
59059
62953

query I rowsort
SELECT - col0 + + col0 - + col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + col0 + - col1 - + 37 FROM tab1
----
-60
17
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 95 col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL + + 75 * col0 AS col1 FROM tab2 AS cor0
----
525
5850
5925

query I rowsort
SELECT + 45 + 10 FROM tab0
----
55
55
55

query I rowsort
SELECT ALL + col2 + + col1 * + tab0.col1 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT ALL 82 * - 3 FROM tab2 AS cor0
----
-246
-246
-246

query I rowsort
SELECT ALL + ( 36 ) + - cor0.col1 FROM tab1 AS cor0
----
10
23
26

query I rowsort
SELECT DISTINCT - ( + 57 ) FROM tab0 cor0
----
-57

query I rowsort
SELECT + - ( + col1 ) * - col0 * col2 + + col0 FROM tab2 AS cor0
----
119730
51113
5866

query I rowsort
SELECT col0 + 86 * - col0 AS col2 FROM tab0 AS cor0
----
-2040
-2975
-7565

query I rowsort
SELECT + - col1 * - col0 + col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - - col1 * - ( col0 * - ( col1 ) ) + col0 - col1 FROM tab1 AS cor0
----
13587
2005
6454

query I rowsort
SELECT + + ( - col0 ) + col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + 44 AS col0 FROM tab1 AS cor0
----
-44
-44
-44

query I rowsort
SELECT 35 + col2 - col2 AS col1 FROM tab1 AS cor0
----
35
35
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 + - col1 col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-4958
SELECT - col0 DIV + 12 + col1 AS col0 FROM tab1 cor0
----
26
5
7

skipif mysql # not compatible
query I rowsort label-4958
SELECT - col0 / + 12 + col1 AS col0 FROM tab1 cor0
----
26
5
7

query I rowsort
SELECT DISTINCT - - 94 * + col0 + col2 AS col1 FROM tab1 AS cor0
----
336
6073
7616

onlyif mysql # use DIV operator for integer division
query I rowsort label-4960
SELECT - col2 DIV + col1 + col1 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-4960
SELECT - col2 / + col1 + col1 FROM tab2 AS cor0
----
15
31
59

query I rowsort
SELECT + col2 + col1 * - 6 FROM tab2 AS cor0
----
-159
-328
-64

query I rowsort
SELECT + - col2 + - col1 * 19 AS col1 FROM tab2 cor0
----
-1147
-361
-616

onlyif mysql # use DIV operator for integer division
query I rowsort label-4963
SELECT + 93 DIV + col0 FROM tab1 AS cor0
----
1
1
31

skipif mysql # not compatible
query I rowsort label-4963
SELECT + 93 / + col0 FROM tab1 AS cor0
----
1
1
31

query I rowsort
SELECT - col2 + + col2 * 81 FROM tab0 AS cor0
----
2640
6560
80

query I rowsort
SELECT 88 * + col1 + + 54 FROM tab2 AS cor0
----
1550
2782
5246

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 - + 7 * - 27 col2 FROM tab1 AS cor0
----
163
176
179

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4967
SELECT + - col2 * - CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-4967
SELECT + - col2 * - CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - + col2 * + col0 - + ( col2 ) AS col2 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-4969
SELECT ALL + - col1 - ( col0 ) DIV + cor0.col1 AS col0 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4969
SELECT ALL + - col1 - ( col0 ) / + cor0.col1 AS col0 FROM tab0 cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 + - 22 col1 FROM tab2 AS cor0
----
49
49
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + col1 + col2 col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT - 32 AS col2 FROM tab2, tab2 AS cor0
----
-32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4973
SELECT - col0 + CAST( NULL AS SIGNED ) col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4973
SELECT - col0 + CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + + col1 + + ( + col0 ) - - col0 AS col2 FROM tab2 AS cor0
----
175
215
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col1 * ( 4 ) col0 FROM tab1 AS cor0
----
104
40
52

query I rowsort
SELECT + 18 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4977
SELECT DISTINCT - + col1 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4977
SELECT DISTINCT - + col1 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4978
SELECT - - col1 * col1 DIV + cor0.col0 + col0 DIV - CAST( - ( + col1 ) AS SIGNED ) FROM tab0 AS cor0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-4978
SELECT - - col1 * col1 / + cor0.col0 + col0 / - CAST ( - ( + col1 ) AS INTEGER ) FROM tab0 AS cor0
----
268
308
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT DISTINCT + ( col1 + 31 ) DIV tab1.col0 col0 FROM tab1
----
0
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4979
SELECT DISTINCT + ( col1 + 31 ) / tab1.col0 col0 FROM tab1
----
0
19

query I rowsort
SELECT - tab1.col1 + col2 * col0 * + col0 FROM tab1
----
233462
460
614387

query I rowsort
SELECT col0 * - 49 * + tab2.col0 FROM tab2
----
-2401
-298116
-305809

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 99 + tab0.col0 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cb191f7d12f6fb1fa163796fe0edd055

query I rowsort
SELECT col1 * ( - tab0.col2 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col0 - + col0 AS col2 FROM tab2
----
-14
-156
-158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4985
SELECT + col2 * CAST( col1 AS SIGNED ) FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-4985
SELECT + col2 * CAST ( col1 AS INTEGER ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT - tab1.col1 + 21 * + col1 * + tab1.col0 FROM tab1
----
13430
1612
21827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( ( col1 ) ) col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 + + col1 AS REAL ) AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT col0 + col2 * tab1.col2 * - col0 AS col1 FROM tab1
----
-207872
-737200
-8745

query I rowsort
SELECT + col2 * 31 * cor0.col1 FROM tab2 AS cor0
----
20026
25947
47554

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col2 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-4992
SELECT + + 27 * col0 DIV - col0 col2 FROM tab1 AS cor0
----
-27
-27
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4992
SELECT + + 27 * col0 / - col0 col2 FROM tab1 AS cor0
----
-27
-27
-27

query I rowsort
SELECT + cor0.col1 + col2 * col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT 25 * col0 AS col1 FROM tab1 AS cor0
----
1600
2000
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-4995
SELECT + + 85 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4995
SELECT + + 85 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4996
SELECT - cor0.col1 DIV + col2 FROM tab0 cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4996
SELECT - cor0.col1 / + col2 FROM tab0 cor0
----
-1
-2
-97

query I rowsort
SELECT + col0 + col2 * tab0.col2 AS col0 FROM tab0
----
1113
36
6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 77 col0 FROM tab0
----
77

query I rowsort
SELECT ALL col2 * + col0 * - col2 FROM tab1
----
-207936
-737280
-8748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5000
SELECT col1 * col0 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5000
SELECT col1 * col0 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL - + col0 * col0 + - cor0.col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT ALL - + 3 + - col2 AS col0 FROM tab1 cor0
----
-57
-60
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5004
SELECT DISTINCT + - col1 DIV col0 AS col1 FROM tab1 AS cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-5004
SELECT DISTINCT + - col1 / col0 AS col1 FROM tab1 AS cor0
----
-8
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5005
SELECT ALL - - cor0.col1 * CAST( NULL AS DECIMAL ) * - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5005
SELECT ALL - - cor0.col1 * CAST ( NULL AS REAL ) * - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 + + col1 * col0 AS col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT col0 * - ( 84 ) + col1 FROM tab1 cor0
----
-226
-5366
-6707

query I rowsort
SELECT DISTINCT col0 * ( 33 ) + - cor0.col2 AS col1 FROM tab1 AS cor0
----
2055
2544
45

query I rowsort
SELECT DISTINCT - - col0 * 97 + col2 AS col0 FROM tab0 cor0
----
2361
3396
8715

query I rowsort
SELECT + col1 + + 29 FROM tab2 AS cor0
----
46
60
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-5011
SELECT + 47 + col2 DIV - 55 col2 FROM tab0
----
46
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5011
SELECT + 47 + col2 / - 55 col2 FROM tab0
----
46
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 37 + col2 col0 FROM tab0
----
119
38
70

query I rowsort
SELECT ALL col2 + - 79 FROM tab2 cor0
----
-41
-52
-53

query I rowsort
SELECT ALL - col0 * 31 + col2 FROM tab1 AS cor0
----
-1927
-2384
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5015
SELECT DISTINCT - col0 + + CAST( - col2 AS SIGNED ) * - col2 * col1 col2 FROM tab0 AS cor0
----
611795
62
93630

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5015
SELECT DISTINCT - col0 + + CAST ( - col2 AS INTEGER ) * - col2 * col1 col2 FROM tab0 AS cor0
----
611795
62
93630

query I rowsort
SELECT DISTINCT + col2 + - ( - col0 ) * - col1 + cor0.col0 AS col1 FROM tab1 AS cor0
----
-21
-519
-864

query I rowsort
SELECT ALL + col0 + - 74 FROM tab2 cor0
----
-67
4
5

query I rowsort
SELECT - + col0 + col1 * col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT 62 + + 84 FROM tab0 AS cor0
----
146
146
146

query I rowsort
SELECT + ( - tab1.col0 ) - + col0 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT cor0.col0 + - col0 * + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - col2 * - col2 + col0 FROM tab1 cor0
----
2919
3313
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 14 col1 FROM tab0 AS cor0
----
1204
1274
1358

query I rowsort
SELECT - - cor0.col0 * col0 + cor0.col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL 34 FROM tab0 cor0
----
34
34
34

query I rowsort
SELECT DISTINCT - - 54 AS col0 FROM tab1 AS cor0
----
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-5027
SELECT DISTINCT - cor0.col2 DIV + col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5027
SELECT DISTINCT - cor0.col2 / + col1 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5028
SELECT 40 DIV + 25 + cor0.col0 + - ( col0 + - col2 ) AS col1 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-5028
SELECT 40 / + 25 + cor0.col0 + - ( col0 + - col2 ) AS col1 FROM tab1 cor0
----
55
58
97

query I rowsort
SELECT DISTINCT - 99 * 27 + col1 AS col0 FROM tab0
----
-2576
-2582
-2587

query I rowsort
SELECT + + 60 AS col2 FROM tab2 AS cor0
----
60
60
60

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1, tab2 AS cor0 WHERE NULL <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5032
SELECT DISTINCT + + col0 + col1 DIV col1 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-5032
SELECT DISTINCT + + col0 + col1 / col1 FROM tab0 AS cor0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5033
SELECT - 18 DIV 46 + col2 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5033
SELECT - 18 / 46 + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - + col1 * + ( + col2 ) * 33 FROM tab2 AS cor0
----
-21318
-27621
-50622

query I rowsort
SELECT ALL - col2 * cor0.col2 + + col1 FROM tab2 cor0
----
-1427
-617
-698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 93 * 20 + - col1 col0 FROM tab2 AS cor0
----
1801
1829
1843

query I rowsort
SELECT - 33 + col0 AS col1 FROM tab1 AS cor0
----
-30
31
47

query I rowsort
SELECT - 63 * col0 AS col0 FROM tab2 AS cor0
----
-441
-4914
-4977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - cor0.col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col1 + col2 * - ( - col0 ) * + col0 AS col2 FROM tab2 AS cor0
----
1292
158125
237141

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) * - cor0.col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 82 * col1 AS col0 FROM tab0 cor0
----
7052
7462
7954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 59 col1 FROM tab0 AS cor0
----
59

query I rowsort
SELECT col0 * + col1 * ( col0 ) FROM tab0 cor0
----
118825
49536
720811

query I rowsort
SELECT + col1 * col0 + cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - ( + col1 ) * + col2 + + tab1.col1 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT ( + 91 ) + + tab1.col1 AS col2 FROM tab1
----
101
104
117

query I rowsort
SELECT 38 + 35 + + col0 FROM tab0
----
108
162
97

query I rowsort
SELECT + tab2.col2 + 45 FROM tab2
----
71
72
83

query I rowsort
SELECT - col2 * ( - col1 ) AS col2 FROM tab0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5051
SELECT DISTINCT 87 * col1 + col2 * CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5051
SELECT DISTINCT 87 * col1 + col2 * CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5052
SELECT ALL cor0.col0 * - CAST( + col0 AS SIGNED ) + + col1 FROM tab2 cor0
----
-18
-6025
-6224

skipif mysql # not compatible
query I rowsort label-5052
SELECT ALL cor0.col0 * - CAST ( + col0 AS INTEGER ) + + col1 FROM tab2 cor0
----
-18
-6025
-6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-5053
SELECT ALL + - col1 DIV CAST( + 47 AS SIGNED ) + - cor0.col1 * col2 FROM tab2 AS cor0
----
-1535
-646
-837

skipif mysql # not compatible
query I rowsort label-5053
SELECT ALL + - col1 / CAST ( + 47 AS INTEGER ) + - cor0.col1 * col2 FROM tab2 AS cor0
----
-1535
-646
-837

query I rowsort
SELECT DISTINCT + col1 * 89 + col2 - - col2 AS col0 FROM tab1 AS cor0
----
1004
1349
2422

query I rowsort
SELECT DISTINCT col1 + - col0 * col2 + col1 FROM tab2 AS cor0
----
-127
-1910
-2968

query I rowsort
SELECT + col1 + cor0.col2 * - 3 FROM tab1 AS cor0
----
-136
-161
-275

query I rowsort
SELECT ALL col1 * - col2 + cor0.col1 * + col0 * 85 + - 5 * col1 FROM tab1 AS cor0
----
5096
53780
87087

query I rowsort
SELECT - cor0.col0 + - 27 FROM tab2 AS cor0
----
-105
-106
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5059
SELECT DISTINCT col1 DIV col0 - col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-5059
SELECT DISTINCT col1 / col0 - col0 FROM tab1 AS cor0
----
-64
-80
5

query I rowsort
SELECT col0 * + cor0.col0 AS col2 FROM tab1 cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort
SELECT + col2 + CAST ( col2 AS REAL ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
54
57
96

query I rowsort
SELECT ALL + 41 FROM tab0, tab1 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT 26 + + col1 FROM tab2 AS cor0
----
43
57
85

query I rowsort
SELECT + + col0 + - col1 - col0 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col0 * - cor0.col0 + col1 AS col1 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT - 53 * cor0.col2 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 71378b6ee6e5b09105b1b58c3d50df38

query I rowsort
SELECT DISTINCT - tab2.col2 * 6 FROM tab2
----
-156
-162
-228

query I rowsort
SELECT DISTINCT tab0.col2 * - 96 AS col2 FROM tab0
----
-3168
-7872
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5070
SELECT col0 DIV 77 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5070
SELECT col0 / 77 FROM tab1
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5071
SELECT - + col1 + - cor0.col0 DIV - col2 AS col1 FROM tab1 AS cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-5071
SELECT - + col1 + - cor0.col0 / - col2 AS col1 FROM tab1 AS cor0
----
-13
-26
-9

query I rowsort
SELECT - - col0 * - col1 * col1 AS col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - 97 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-97

query I rowsort
SELECT ALL col1 * - col0 + - 31 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-10920
-4730
-6402

query I rowsort
SELECT ALL cor0.col0 + col0 + + 20 FROM tab1 AS cor0
----
148
180
26

query I rowsort
SELECT DISTINCT col0 * cor0.col1 + + col1 + + col2 FROM tab0 AS cor0
----
2183
3493
8272

query I rowsort
SELECT - 89 AS col0 FROM tab0 cor0
----
-89
-89
-89

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab0, tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5079
SELECT - cor0.col1 DIV ( + ( col0 ) * + 38 ) AS col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5079
SELECT - cor0.col1 / ( + ( col0 ) * + 38 ) AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + + col0 + - cor0.col1 AS col2 FROM tab0 cor0
----
-2
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5081
SELECT DISTINCT CAST( NULL AS DECIMAL ) col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5081
SELECT DISTINCT CAST ( NULL AS REAL ) col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
NULL

query I rowsort
SELECT ALL + col2 - + col2 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( col1 ) + - ( - col0 ) + - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-1247
-179
-4465

query I rowsort
SELECT DISTINCT + + 72 * - col1 FROM tab0 cor0
----
-6192
-6552
-6984

query I rowsort
SELECT ALL 78 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
52
65
68

query I rowsort
SELECT DISTINCT + + ( col2 ) * col1 - col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT DISTINCT + 74 + col1 DIV - 37 FROM tab2 AS cor0
----
73
74

skipif mysql # not compatible
query I rowsort label-5087
SELECT DISTINCT + 74 + col1 / - 37 FROM tab2 AS cor0
----
73
74

query I rowsort
SELECT ALL 97 - + col2 * - col2 * 78 FROM tab2 AS cor0
----
112729
52825
56959

query I rowsort
SELECT ALL - 76 - col1 AS col1 FROM tab0 AS cor0
----
-162
-167
-173

query I rowsort
SELECT ALL - col1 + - cor0.col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - col0 * col2 * col2 AS col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to b6efe6f7ec1a3daa3cc6ea9dd7d13455

query I rowsort
SELECT - col0 * col2 + col2 * col1 AS col1 FROM tab2 AS cor0
----
-2356
-494
648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 * col2 col1 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT + - 36 FROM tab0, tab1 AS cor0
----
9 values hashing to afecaf209e79e23b6674a73fffa3e837

query I rowsort
SELECT - 61 - - col2 * + tab2.col0 FROM tab2
----
128
1967
2941

onlyif mysql # use DIV operator for integer division
query I rowsort label-5097
SELECT DISTINCT - col1 * + 33 - col1 DIV + col0 FROM tab2 AS cor0
----
-1027
-1947
-561

skipif mysql # not compatible
query I rowsort label-5097
SELECT DISTINCT - col1 * + 33 - col1 / + col0 FROM tab2 AS cor0
----
-1027
-1947
-561

query I rowsort
SELECT ALL + - 15 * col2 * col2 + + 12 - - col1 AS col1 FROM tab1 AS cor0
----
-138215
-43702
-48713

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5099
SELECT ALL - + CAST( NULL AS SIGNED ) FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5099
SELECT ALL - + CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5100
SELECT ALL col2 * - col2 + CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5100
SELECT ALL col2 * - col2 + CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * cor0.col0 * 88 + cor0.col0 FROM tab2 AS cor0
----
-16625
-178386
-264097

query I rowsort
SELECT ALL - - 89 * col1 - - col1 * col1 FROM tab1 AS cor0
----
1326
2990
990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5103
SELECT DISTINCT CAST( NULL AS SIGNED ) * + tab2.col0 + col2 * - col2 + tab2.col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5103
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + tab2.col0 + col2 * - col2 + tab2.col2 FROM tab2
----
NULL

query I rowsort
SELECT col2 * + col1 + - 80 FROM tab0
----
17
2758
7382

query I rowsort
SELECT DISTINCT + 18 AS col2 FROM tab0, tab1, tab2 AS cor0
----
18

query I rowsort
SELECT - 12 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 3983bffe2adf88cb2efc3be93ee620c0

query I rowsort
SELECT - 53 - 53 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 10781c22afc25c64b7aeeaa3635843cd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5109
SELECT DISTINCT - cor0.col1 + col1 * + CAST( col0 * cor0.col2 AS SIGNED ) FROM tab2 AS cor0
----
119593
51017
5828

skipif mysql # not compatible
query I rowsort label-5109
SELECT DISTINCT - cor0.col1 + col1 * + CAST ( col0 * cor0.col2 AS INTEGER ) FROM tab2 AS cor0
----
119593
51017
5828

onlyif mysql # use DIV operator for integer division
query I rowsort label-5110
SELECT col1 + col1 DIV col0 + col0 * - tab1.col2 * + 75 FROM tab1
----
-12116
-273590
-575987

skipif mysql # not compatible
query I rowsort label-5110
SELECT col1 + col1 / col0 + col0 * - tab1.col2 * + 75 FROM tab1
----
-12116
-273590
-575987

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col2 - - col2 col2 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5112
SELECT + col0 DIV + tab0.col2 + - 97 + - col2 AS col0 FROM tab0
----
-130
-178
-63

skipif mysql # not compatible
query I rowsort label-5112
SELECT + col0 / + tab0.col2 + - 97 + - col2 AS col0 FROM tab0
----
-130
-178
-63

query I rowsort
SELECT + tab2.col0 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL + tab1.col2 - col1 * + ( col0 ) FROM tab1
----
-24
-583
-944

query I rowsort
SELECT ALL col0 + 56 - 89 AS col2 FROM tab2
----
-26
45
46

query I rowsort
SELECT DISTINCT + col0 - + col1 AS col1 FROM tab0
----
-2
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5117
SELECT - col0 * - 92 DIV 1 col1 FROM tab0
----
2208
3220
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5117
SELECT - col0 * - 92 / 1 col1 FROM tab0
----
2208
3220
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-5118
SELECT DISTINCT + - cor0.col0 DIV - cor0.col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5118
SELECT DISTINCT + - cor0.col0 / - cor0.col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT + - col1 + - 58 * col0 FROM tab0 cor0
----
-1478
-2127
-5253

query I rowsort
SELECT DISTINCT + - 0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + col1 + + col1 * - col2 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ( - tab1.col1 ) + - col2 AS col2 FROM tab1
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + col0 * + col0 col2 FROM tab1 AS cor0
----
-45
4039
6304

onlyif mysql # use DIV operator for integer division
query I rowsort label-5124
SELECT DISTINCT + 21 DIV col1 AS col1 FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5124
SELECT DISTINCT + 21 / col1 AS col1 FROM tab2 AS cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5125
SELECT - ( col2 ) DIV col0 AS col1 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5125
SELECT - ( col2 ) / col0 AS col1 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT ALL + - 87 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-7482
-7917
-8439

query I rowsort
SELECT DISTINCT - col1 * - col1 + - col2 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT + ( 86 ) + - col2 AS col0 FROM tab1 AS cor0
----
-10
29
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-5129
SELECT ALL - ( col0 ) DIV col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5129
SELECT ALL - ( col0 ) / col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + col2 + - col0 * - col1 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ( - cor0.col1 ) * + col1 + col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5133
SELECT col0 DIV 24 + col2 FROM tab1 AS cor0
----
54
59
99

skipif mysql # not compatible
query I rowsort label-5133
SELECT col0 / 24 + col2 FROM tab1 AS cor0
----
54
59
99

query I rowsort
SELECT DISTINCT cor0.col2 + 41 FROM tab0, tab2 AS cor0
----
67
68
79

query I rowsort
SELECT ALL + col1 + - col0 * cor0.col2 FROM tab2 cor0
----
-158
-1969
-2985

skipif mysql # not compatible
query I rowsort
SELECT + + cor0.col0 + - col2 * CAST ( - col0 AS REAL ) FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + + col1 * col1 + col2 - col0 AS col1 FROM tab1 AS cor0
----
185
727
93

query I rowsort
SELECT ALL - + col0 + + col1 * 81 FROM tab2 AS cor0
----
1298
2504
4701

query I rowsort
SELECT DISTINCT - col0 * - cor0.col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + col0 * col2 * col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT + col0 + - col1 * - col1 + col0 AS col1 FROM tab0 cor0
----
7444
8459
9479

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5143
SELECT ALL col0 * CAST( col1 * col1 AS SIGNED ) AS col1 FROM tab0 cor0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-5143
SELECT ALL col0 * CAST ( col1 * col1 AS INTEGER ) AS col1 FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT + col0 * - col2 + col0 FROM tab0 cor0
----
-7209
-768
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5145
SELECT - col0 / CAST( NULL AS SIGNED ) - col0 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5145
SELECT - col0 / CAST ( NULL AS INTEGER ) - col0 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + 67 - col2 FROM tab1 AS cor0
----
-16
20
39

query I rowsort
SELECT DISTINCT - + col2 * 89 AS col0 FROM tab0 AS cor0
----
-2937
-7298
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5148
SELECT ALL - + col0 + CAST( col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-5148
SELECT ALL - + col0 + CAST ( col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5149
SELECT - + col1 + col0 DIV col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-5149
SELECT - + col1 + col0 / col0 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT DISTINCT - col0 + - 60 AS col1 FROM tab1 AS cor0
----
-124
-140
-63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5151
SELECT ALL + CAST( NULL AS DECIMAL ) + col1 + col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5151
SELECT ALL + CAST ( NULL AS REAL ) + col1 + col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 45 * cor0.col1 FROM tab1 AS cor0
----
1170
450
585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col2 ) + col2 * col2 col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL + cor0.col2 * - 70 AS col2 FROM tab1 AS cor0
----
-3780
-3990
-6720

query I rowsort
SELECT DISTINCT + + col0 * ( + col1 + + col1 ) AS col2 FROM tab1 AS cor0
----
1280
156
2080

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5156
SELECT DISTINCT CAST( - col1 AS SIGNED ) + - col0 - + 91 col2 FROM tab2 AS cor0
----
-129
-187
-228

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5156
SELECT DISTINCT CAST ( - col1 AS INTEGER ) + - col0 - + 91 col2 FROM tab2 AS cor0
----
-129
-187
-228

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 15 col1 FROM tab0 AS cor0
----
15
15
15

query I rowsort
SELECT ALL - col1 + - ( col2 + col2 ) AS col2 FROM tab0 AS cor0
----
-152
-255
-99

query I rowsort
SELECT 3 FROM tab1 cor0
----
3
3
3

query I rowsort
SELECT col2 * - ( - cor0.col0 ) + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT ( - col2 ) + + col1 FROM tab0 cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( col1 AS REAL ) + col1 AS col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ( 8 ) FROM tab2 AS cor0
----
8
8
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5164
SELECT ALL + 17 + + col1 DIV col0 - + 51 FROM tab1 AS cor0
----
-26
-34
-34

skipif mysql # not compatible
query I rowsort label-5164
SELECT ALL + 17 + + col1 / col0 - + 51 FROM tab1 AS cor0
----
-26
-34
-34

query I rowsort
SELECT ALL ( col0 ) * - col1 + col0 * + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 39 * - ( - col1 ) + col1 FROM tab2 AS cor0
----
1240
2360
680

query I rowsort
SELECT + cor0.col2 + + col0 * - 58 FROM tab2 AS cor0
----
-379
-4498
-4544

query I rowsort
SELECT DISTINCT + + 72 * + col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT - col2 * col0 * + 15 AS col2 FROM tab1 AS cor0
----
-115200
-2430
-54720

query I rowsort
SELECT - 51 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5171
SELECT ALL + col1 * col0 DIV - col1 + col2 AS col1 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-5171
SELECT ALL + col1 * col0 / - col1 + col2 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + - col2 + cor0.col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * + col2 * col2 + - col1 FROM tab1 AS cor0
----
119795
32480
75790

query I rowsort
SELECT col1 + col1 * + ( + cor0.col2 ) FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - - col0 + - col1 * col0 FROM tab1 cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-5176
SELECT + col1 DIV 74 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5176
SELECT + col1 / 74 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT - ( 97 ) AS col0 FROM tab2
----
-97

query I rowsort
SELECT 71 * 39 AS col0 FROM tab0
----
2769
2769
2769

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5179
SELECT ALL + CAST( - col1 AS SIGNED ) FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5179
SELECT ALL + CAST ( - col1 AS INTEGER ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + 13 * 4 + - col2 * col2 FROM tab0
----
-1037
-6672
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5181
SELECT - CAST( - col2 AS SIGNED ) + + col1 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-5181
SELECT - CAST ( - col2 AS INTEGER ) + + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ( tab1.col0 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT col0 + 27 * col0 FROM tab0 AS cor0
----
2492
672
980

query I rowsort
SELECT ALL + col1 * + 36 FROM tab1 cor0
----
360
468
936

query I rowsort
SELECT + - col1 * + 97 * col0 + col1 FROM tab2 AS cor0
----
-130254
-21018
-446335

onlyif mysql # use DIV operator for integer division
query I rowsort label-5186
SELECT + cor0.col2 * + col1 + col2 DIV col1 FROM tab0 cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5186
SELECT + cor0.col2 * + col1 + col2 / col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + + col1 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + col0 * 44 * col2 + col1 AS col2 FROM tab0
----
1637
321203
34934

onlyif mysql # use DIV operator for integer division
query I rowsort label-5189
SELECT + col1 DIV col1 + 35 FROM tab2 AS cor0
----
36
36
36

skipif mysql # not compatible
query I rowsort label-5189
SELECT + col1 / col1 + 35 FROM tab2 AS cor0
----
36
36
36

query I rowsort
SELECT ALL - - col1 * 96 FROM tab0 AS cor0
----
8256
8736
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 44 * col1 col0 FROM tab0 AS cor0
----
3784
4004
4268

query I rowsort
SELECT + 53 * + col2 AS col1 FROM tab0 AS cor0
----
1749
4346
53

query I rowsort
SELECT DISTINCT + ( 55 ) * col0 AS col1 FROM tab0 AS cor0
----
1320
1925
4895

onlyif mysql # use DIV operator for integer division
query I rowsort label-5194
SELECT cor0.col2 DIV - 2 FROM tab2 AS cor0
----
-13
-13
-19

skipif mysql # not compatible
query I rowsort label-5194
SELECT cor0.col2 / - 2 FROM tab2 AS cor0
----
-13
-13
-19

onlyif mysql # use DIV operator for integer division
query I rowsort label-5195
SELECT - 45 DIV + col2 AS col1 FROM tab0 AS cor0
----
-1
-45
0

skipif mysql # not compatible
query I rowsort label-5195
SELECT - 45 / + col2 AS col1 FROM tab0 AS cor0
----
-1
-45
0

query I rowsort
SELECT DISTINCT - col0 * + 83 + col0 AS col0 FROM tab0 AS cor0
----
-1968
-2870
-7298

query I rowsort
SELECT DISTINCT + 14 * + col1 AS col2 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT DISTINCT col0 * tab1.col1 - + 73 FROM tab1
----
5
567
967

query I rowsort
SELECT + + col2 * cor0.col2 + + col0 AS col0 FROM tab1 cor0
----
2919
3313
9296

query I rowsort
SELECT - + col1 * col0 + + ( 82 ) FROM tab2 AS cor0
----
-1261
-135
-4520

query I rowsort
SELECT + 81 + col2 AS col2 FROM tab2 cor0
----
107
108
119

query I rowsort
SELECT + - 30 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + ( + col0 ) col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5204
SELECT - col0 + CAST( col1 + col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-24
51
7

skipif mysql # not compatible
query I rowsort label-5204
SELECT - col0 + CAST ( col1 + col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT 47 * col1 FROM tab2
----
1457
2773
799

query I rowsort
SELECT - col0 + - ( + col2 * - cor0.col1 ) + col1 AS col0 FROM tab1 cor0
----
1181
1427
516

onlyif mysql # use DIV operator for integer division
query I rowsort label-5207
SELECT col0 DIV 26 + col1 + - col1 FROM tab2 AS cor0
----
0
3
3

skipif mysql # not compatible
query I rowsort label-5207
SELECT col0 / 26 + col1 + - col1 FROM tab2 AS cor0
----
0
3
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5208
SELECT - col1 DIV + 43 + + 55 FROM tab2 AS cor0
----
54
55
55

skipif mysql # not compatible
query I rowsort label-5208
SELECT - col1 / + 43 + + 55 FROM tab2 AS cor0
----
54
55
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5209
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) + - 31 + col0 AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5209
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) + - 31 + col0 AS col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT col2 + + col2 + col1 FROM tab1 AS cor0
----
124
134
205

onlyif mysql # use DIV operator for integer division
query I rowsort label-5211
SELECT DISTINCT + col2 * - col0 + - col2 DIV - col1 AS col2 FROM tab0 cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-5211
SELECT DISTINCT + col2 * - col0 + - col2 / - col1 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + col1 * + ( + col1 ) + col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL + col2 * col1 + + 58 - + col0 AS col2 FROM tab0 AS cor0
----
120
2872
7431

onlyif mysql # use DIV operator for integer division
query I rowsort label-5214
SELECT ALL cor0.col1 DIV 5 + + col1 FROM tab0 cor0
----
103
109
116

skipif mysql # not compatible
query I rowsort label-5214
SELECT ALL cor0.col1 / 5 + + col1 FROM tab0 cor0
----
103
109
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col0 + col0 * - col2 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5216
SELECT ALL + col2 DIV col2 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5216
SELECT ALL + col2 / col2 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5217
SELECT - 0 DIV + col2 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5217
SELECT - 0 / + col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - tab2.col0 - 27 * + col2 FROM tab2
----
-1105
-736
-780

query I rowsort
SELECT - tab1.col0 * + 76 + + col2 FROM tab1
----
-174
-4807
-5984

query I rowsort
SELECT + col0 - col0 * + col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT DISTINCT col0 + 5 AS col1 FROM tab2
----
12
83
84

query I rowsort
SELECT col2 - 99 FROM tab2
----
-61
-72
-73

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab2, tab0 cor0
----
-76

query I rowsort
SELECT - - col1 * - col0 + - 53 FROM tab1 AS cor0
----
-1093
-131
-693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * tab2.col0 * - col2 col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT ALL col2 * - tab1.col1 + + col0 * - tab1.col2 AS col1 FROM tab1
----
-1566
-4218
-8928

query I rowsort
SELECT - col2 * col1 + + col0 * col0 AS col2 FROM tab1 AS cor0
----
-1395
3526
5152

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5228
SELECT ALL cor0.col0 * col0 + + ( + col0 * + col1 ) + + CAST( + 78 AS SIGNED ) FROM tab0 cor0
----
16098
2718
4698

skipif mysql # not compatible
query I rowsort label-5228
SELECT ALL cor0.col0 * col0 + + ( + col0 * + col1 ) + + CAST ( + 78 AS INTEGER ) FROM tab0 cor0
----
16098
2718
4698

query I rowsort
SELECT ALL + - col0 * col1 * - 74 AS col0 FROM tab1 AS cor0
----
47360
5772
76960

query I rowsort
SELECT ALL + ( col0 ) + ( - 0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + 90 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT + + 11 + col2 + col1 FROM tab0 AS cor0
----
109
130
184

query I rowsort
SELECT - 7 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT + col1 + col0 * col0 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col0 * col2 * cor0.col0 col1 FROM tab1 cor0
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 * + col1 col2 FROM tab0 AS cor0
----
6708
7098
7566

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * - 97 col1 FROM tab2 AS cor0
----
2522
2619
3686

query I rowsort
SELECT DISTINCT - ( cor0.col1 * - tab0.col2 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 1d94ea086ff4b04d01d3c46ff83c5c3d

query I rowsort
SELECT DISTINCT col1 * tab0.col2 * col1 AS col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - col1 + 36 FROM tab2
----
-23
19
5

query I rowsort
SELECT ( ( col2 ) ) FROM tab0
----
1
33
82

query I rowsort
SELECT - ( - 15 ) FROM tab0
----
15
15
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5244
SELECT DISTINCT CAST( 14 AS SIGNED ) AS col2 FROM tab1
----
14

skipif mysql # not compatible
query I rowsort label-5244
SELECT DISTINCT CAST ( 14 AS INTEGER ) AS col2 FROM tab1
----
14

query I rowsort
SELECT ( - 79 + - col2 ) FROM tab2
----
-105
-106
-117

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 29 ) + + col2 col0 FROM tab0
----
111
30
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5247
SELECT CAST( + 69 AS SIGNED ) + - col2 AS col0 FROM tab0
----
-13
36
68

skipif mysql # not compatible
query I rowsort label-5247
SELECT CAST ( + 69 AS INTEGER ) + - col2 AS col0 FROM tab0
----
-13
36
68

query I rowsort
SELECT - - ( col1 ) * + col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col1 + + col2 - + col0 * col2 AS col2 FROM tab0 AS cor0
----
-673
-7125
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 57 col0 FROM tab2 AS cor0
----
-57
-57
-57

query I rowsort
SELECT DISTINCT - 58 + 23 FROM tab2 AS cor0
----
-35

query I rowsort
SELECT 39 * + col1 AS col1 FROM tab1
----
1014
390
507

query I rowsort
SELECT - cor0.col0 + cor0.col2 + - 78 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 59830e1fda65992556a171242bf6b67c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 col2 FROM tab0, tab2, tab2 AS cor0
----
1
33
82

query I rowsort
SELECT col1 * - col0 + 63 FROM tab1 AS cor0
----
-15
-577
-977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col0 col0 FROM tab0, tab2, tab2 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + 93 + - cor0.col0 FROM tab2, tab1, tab1 cor0
----
13
29
90

query I rowsort
SELECT DISTINCT + 92 AS col1 FROM tab1, tab2, tab2 AS cor0
----
92

query I rowsort
SELECT ALL - col0 * - col1 + 5 + + tab0.col0 FROM tab0
----
2093
3435
8193

query I rowsort
SELECT - 9 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 3dfe689e16ce3a87877d40f349e6c7b5

query I rowsort
SELECT ALL - - cor0.col1 + 7 * col1 AS col2 FROM tab2 AS cor0
----
136
248
472

onlyif mysql # use DIV operator for integer division
query I rowsort label-5262
SELECT ALL - col0 DIV - col1 + - cor0.col2 FROM tab1 AS cor0
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-5262
SELECT ALL - col0 / - col1 + - cor0.col2 FROM tab1 AS cor0
----
-51
-54
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - + 83 col0 FROM tab0 AS cor0
----
-48
-59
6

query I rowsort
SELECT - - cor0.col2 * 67 * col1 AS col0 FROM tab1 AS cor0
----
38190
83616
94068

onlyif mysql # use DIV operator for integer division
query I rowsort label-5265
SELECT - + col0 DIV cor0.col1 col1 FROM tab1 AS cor0
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5265
SELECT - + col0 / cor0.col1 col1 FROM tab1 AS cor0
----
-6
-6
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5266
SELECT col2 + 96 DIV 84 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-5266
SELECT col2 + 96 / 84 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT DISTINCT + col1 * 49 AS col0 FROM tab0 AS cor0
----
4214
4459
4753

query I rowsort
SELECT + tab1.col2 + ( + tab1.col0 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8733ba2dd568938e338b27ad757d3e3b

query I rowsort
SELECT ALL + col2 * + 22 FROM tab2
----
572
594
836

query I rowsort
SELECT cor0.col2 + + cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to b24047a4766c1dbbfa5abb9df45d1883

query I rowsort
SELECT ( + 91 ) FROM tab1 AS cor0
----
91
91
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 * col1 + + 77 col2 FROM tab2 AS cor0
----
119729
51111
5936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 59 * - col0 col1 FROM tab0 AS cor0
----
-1416
-2065
-5251

query I rowsort
SELECT 54 + + col2 AS col1 FROM tab1
----
108
111
150

query I rowsort
SELECT ALL - col2 * - 92 * + col1 FROM tab2 AS cor0
----
141128
59432
77004

onlyif mysql # use DIV operator for integer division
query I rowsort label-5276
SELECT ALL col1 DIV + CAST( col1 AS SIGNED ) AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5276
SELECT ALL col1 / + CAST ( col1 AS INTEGER ) AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT col1 + - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-5278
SELECT + cor0.col2 * - col1 DIV + col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5278
SELECT + cor0.col2 * - col1 / + col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - 40 * col0 + col0 * + 71 FROM tab1 AS cor0
----
1984
2480
93

query I rowsort
SELECT + + col2 * cor0.col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - ( - 6 ) FROM tab1 cor0
----
6
6
6

query I rowsort
SELECT + - 43 + col0 * col1 * + 30 + - 50 AS col1 FROM tab2 AS cor0
----
137967
40197
6417

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 24 * + col2 + + ( col2 * - col2 ) col1 FROM tab2 cor0
----
-52
-532
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) + - ( + 15 ) col0 FROM tab0 AS cor0
----
20
74
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5285
SELECT - col2 DIV col0 - - cor0.col2 AS col2 FROM tab1 AS cor0
----
36
57
95

skipif mysql # not compatible
query I rowsort label-5285
SELECT - col2 / col0 - - cor0.col2 AS col2 FROM tab1 AS cor0
----
36
57
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 55 * - 47 col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 71115a0a21429f44fec599f85bd6311e

query I rowsort
SELECT + cor0.col1 * 98 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 417165b3b526524d7bd2d942a7236815

query I rowsort
SELECT DISTINCT col0 * + col0 + + col2 - - col2 FROM tab2 AS cor0
----
103
6136
6317

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5289
SELECT + ( col1 ) + + CAST( NULL AS SIGNED ) * + 91 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5289
SELECT + ( col1 ) + + CAST ( NULL AS INTEGER ) * + 91 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - cor0.col0 + cor0.col1 * ( + ( col1 ) ) AS col1 FROM tab0 AS cor0
----
7372
8192
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( cor0.col0 ) col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT 52 * col2 + + 70 * cor0.col2 AS col2 FROM tab1 AS cor0
----
11712
6588
6954

query I rowsort
SELECT ALL + 4 + col1 AS col2 FROM tab0 AS cor0
----
101
90
95

query I rowsort
SELECT col2 + + 43 + col0 FROM tab1
----
100
164
219

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5295
SELECT DISTINCT col2 + + tab0.col1 * tab0.col1 - - CAST( + col0 AS SIGNED ) AS col2 FROM tab0
----
7453
8452
9445

skipif mysql # not compatible
query I rowsort label-5295
SELECT DISTINCT col2 + + tab0.col1 * tab0.col1 - - CAST ( + col0 AS INTEGER ) AS col2 FROM tab0
----
7453
8452
9445

query I rowsort
SELECT + ( - 14 ) - tab2.col1 FROM tab2
----
-31
-45
-73

query I rowsort
SELECT ( - col0 ) + col0 + tab1.col0 FROM tab1
----
3
64
80

query I rowsort
SELECT + col0 * - col2 + - col0 * 22 AS col2 FROM tab2
----
-343
-3744
-4740

query I rowsort
SELECT - ( col0 ) * - col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - + ( col2 ) + 78 * - cor0.col2 FROM tab0 AS cor0
----
-2607
-6478
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5301
SELECT DISTINCT - + 89 DIV col0 FROM tab2 AS cor0
----
-1
-12

skipif mysql # not compatible
query I rowsort label-5301
SELECT DISTINCT - + 89 / col0 FROM tab2 AS cor0
----
-1
-12

query I rowsort
SELECT - + 89 * col2 * + 55 FROM tab2 cor0
----
-127270
-132165
-186010

query I rowsort
SELECT - col0 + + cor0.col0 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * 18 AS col1 FROM tab2
----
126
1404
1422

onlyif mysql # use DIV operator for integer division
query I rowsort label-5305
SELECT + tab0.col2 DIV - ( tab0.col0 ) col0 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5305
SELECT + tab0.col2 / - ( tab0.col0 ) col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT col1 * - 96 AS col0 FROM tab1 AS cor0
----
-1248
-2496
-960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5307
SELECT + col0 * - col1 + col0 - + CAST( NULL AS DECIMAL ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5307
SELECT + col0 * - col1 + col0 - + CAST ( NULL AS REAL ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 54 * 83 col0 FROM tab1 AS cor0
----
-4482
-4482
-4482

query I rowsort
SELECT ALL col2 + 59 * cor0.col1 FROM tab1 AS cor0
----
1588
647
863

onlyif mysql # use DIV operator for integer division
query I rowsort label-5310
SELECT + 74 DIV 13 FROM tab0 AS cor0
----
5
5
5

skipif mysql # not compatible
query I rowsort label-5310
SELECT + 74 / 13 FROM tab0 AS cor0
----
5
5
5

query I rowsort
SELECT ALL + - 4 * - 79 AS col0 FROM tab1 AS cor0
----
316
316
316

query I rowsort
SELECT + - ( col1 ) + - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL - + col1 * cor0.col2 + - col1 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1292
-1674
-3068

query I rowsort
SELECT + + ( col2 ) * - col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + - col2 * col0 col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL - + 45 * + col1 * col1 FROM tab1 AS cor0
----
-30420
-4500
-7605

onlyif mysql # use DIV operator for integer division
query I rowsort label-5317
SELECT + col0 + col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5317
SELECT + col0 + col0 / + col0 AS col1 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT ALL + - 28 + - cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
-125
-2866
-7490

onlyif mysql # use DIV operator for integer division
query I rowsort label-5319
SELECT DISTINCT + 12 DIV col2 + col2 col1 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5319
SELECT DISTINCT + 12 / col2 + col2 col1 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5320
SELECT ALL + 32 DIV col2 + - col2 * 57 * col0 + col2 * - 1 AS col1 FROM tab0 AS cor0
----
-1964
-416068
-45177

skipif mysql # not compatible
query I rowsort label-5320
SELECT ALL + 32 / col2 + - col2 * 57 * col0 + col2 * - 1 AS col1 FROM tab0 AS cor0
----
-1964
-416068
-45177

query I rowsort
SELECT ALL + + cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - + col0 * cor0.col1 + - ( ( + col2 ) ) FROM tab2 cor0
----
-1381
-244
-4628

query I rowsort
SELECT - 65 + col1 + + col1 FROM tab1
----
-13
-39
-45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 78 * col0 - - tab0.col1 col0 FROM tab0
----
-1786
-2633
-6851

query I rowsort
SELECT - 96 * - col0 + - col2 + col1 * + col1 FROM tab1 AS cor0
----
6187
7753
910

query I rowsort
SELECT + cor0.col0 * + col1 + col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query IIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT col2 * 31 + 92 AS col2 FROM tab0 AS cor0
----
1115
123
2634

query I rowsort
SELECT + + 42 FROM tab1, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT col2 + col0 * - 13 AS col1 FROM tab0 cor0
----
-1075
-279
-454

query I rowsort
SELECT ALL - col1 - - 73 FROM tab1 AS cor0
----
47
60
63

query I rowsort
SELECT + + col0 + 45 * 48 FROM tab0 AS cor0
----
2184
2195
2249

query I rowsort
SELECT ALL col0 + + ( ( - col1 ) ) * - cor0.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 + ( - col1 ) col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 17 col1 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT ALL - - col2 * col0 - + cor0.col0 FROM tab0 cor0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 52 * - col2 - - col2 col2 FROM tab1
----
-189639
-399264
-8370

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5338
SELECT DISTINCT + - CAST( NULL AS SIGNED ) - + col0 / + col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5338
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) - + col0 / + col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - 76 + col1 AS col2 FROM tab1 cor0
----
-50
-63
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5340
SELECT ALL - ( - 86 ) * col2 + + CAST( NULL AS SIGNED ) * col2 + - col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5340
SELECT ALL - ( - 86 ) * col2 + + CAST ( NULL AS INTEGER ) * col2 + - col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 44 * col1 AS col0 FROM tab0 AS cor0
----
3784
4004
4268

query I rowsort
SELECT - col2 * - col2 * col0 + + col1 AS col0 FROM tab0 AS cor0
----
132
26222
598527

query I rowsort
SELECT - cor0.col2 + col2 * + col1 * col1 FROM tab2 AS cor0
----
10944
25920
90480

onlyif mysql # use DIV operator for integer division
query I rowsort label-5344
SELECT col2 * col1 + + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
1534
646
840

skipif mysql # not compatible
query I rowsort label-5344
SELECT col2 * col1 + + col2 / col0 AS col2 FROM tab2 AS cor0
----
1534
646
840

query III rowsort
SELECT DISTINCT * FROM tab1 cor0 WHERE ( NULL ) NOT IN ( col1 * col2 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT + col1 NOT IN ( + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - tab1.col2 * col2 + - col2 * col2 AS col0 FROM tab1
----
-18432
-5832
-6498

query I rowsort
SELECT tab2.col0 * col1 AS col0 FROM tab2 WHERE col2 IN ( - col2 - - tab2.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * - tab0.col0 col2 FROM tab0
----
-35
-7298
-792

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL <= + col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5351
SELECT ALL col2 DIV col0 + tab2.col1 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5351
SELECT ALL col2 / col0 + tab2.col1 FROM tab2
----
17
34
59

query I rowsort
SELECT tab1.col0 + col1 AS col1 FROM tab1 WHERE NOT - col0 BETWEEN NULL AND - col0 * - tab1.col1 + + col2
----

query I rowsort
SELECT ALL col0 + + col2 * - col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - col2 + + col0 * tab1.col2 * tab1.col2 FROM tab1
----
207879
737184
8694

onlyif mysql # use DIV operator for integer division
query I rowsort label-5355
SELECT col2 * + col0 * + col2 - tab1.col0 DIV col1 AS col2 FROM tab1
----
207930
737274
8748

skipif mysql # not compatible
query I rowsort label-5355
SELECT col2 * + col0 * + col2 - tab1.col0 / col1 AS col2 FROM tab1
----
207930
737274
8748

query I rowsort
SELECT - col0 + + col1 FROM tab0 WHERE + col1 <= NULL
----

query I rowsort
SELECT - tab1.col2 + + tab1.col2 AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT col2 + + col2 DIV col0 FROM tab0 cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-5358
SELECT col2 + + col2 / col0 FROM tab0 cor0
----
1
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5359
SELECT + + col2 * + col0 - col2 DIV + col0 FROM tab2 AS cor0
----
186
2028
3002

skipif mysql # not compatible
query I rowsort label-5359
SELECT + + col2 * + col0 - col2 / + col0 FROM tab2 AS cor0
----
186
2028
3002

query I rowsort
SELECT + cor0.col1 + cor0.col1 * + col0 + - col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col2 * - cor0.col1 - + col1 * - col2 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 + cor0.col0 * + col2 AS col2 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-5363
SELECT col0 * col0 * + col1 + col2 DIV col2 AS col0 FROM tab0 AS cor0
----
118826
49537
720812

skipif mysql # not compatible
query I rowsort label-5363
SELECT col0 * col0 * + col1 + col2 / col2 AS col0 FROM tab0 AS cor0
----
118826
49537
720812

query I rowsort
SELECT col2 * + col2 + + tab0.col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT + col0 + col1 + - col0 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT tab0.col0 - + col2 * + tab0.col2 AS col1 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT tab1.col0 + + col0 - + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + col2 * + col2 + col0 - - tab2.col1 * col1 AS col1 FROM tab2
----
1697
1812
4235

onlyif mysql # use DIV operator for integer division
query I rowsort label-5369
SELECT DISTINCT + col1 DIV + tab0.col2 - + col1 col2 FROM tab0
----
-84
-90
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5369
SELECT DISTINCT + col1 / + tab0.col2 - + col1 col2 FROM tab0
----
-84
-90
0

query I rowsort
SELECT ALL col1 - tab1.col0 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT col1 * tab0.col1 + col0 FROM tab0
----
7420
8370
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-5372
SELECT - col2 - - col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-5372
SELECT - col2 - - col0 / col2 AS col0 FROM tab1 AS cor0
----
-54
-56
-96

query I rowsort
SELECT ALL col0 * + col2 * col2 AS col1 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT - + col2 * - col2 + col1 * - col1 FROM tab1 AS cor0
----
2240
3149
9047

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 * + tab2.col2 col0 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT - 54 * - col0 FROM tab2
----
378
4212
4266

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - ( - col1 ) col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - 64 + + col0 FROM tab2
----
-57
14
15

query I rowsort
SELECT ALL - 59 FROM tab2 cor0
----
-59
-59
-59

query I rowsort
SELECT + col0 * - col2 + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - + col2 + ( - 19 ) AS col0 FROM tab0 AS cor0
----
-101
-20
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 85 col1 FROM tab0 AS cor0
----
-2040
-2975
-7565

onlyif mysql # use DIV operator for integer division
query I rowsort label-5383
SELECT + col0 + ( - col0 ) DIV + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-5383
SELECT + col0 + ( - col0 ) / + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL col0 + - col0 * tab0.col0 AS col1 FROM tab0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col1 FROM tab0 WHERE col2 * - col2 IN ( + col0 )
----

query I rowsort
SELECT DISTINCT col0 + + col1 * col1 FROM tab1
----
164
249
679

query I rowsort
SELECT - col1 * - col2 FROM tab0 WHERE NOT + col2 IN ( + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5388
SELECT ALL tab2.col0 + - col2 DIV col0 FROM tab2
----
4
78
79

skipif mysql # not compatible
query I rowsort label-5388
SELECT ALL tab2.col0 + - col2 / col0 FROM tab2
----
4
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * col1 - col1 col0 FROM tab0
----
0
2752
7371

query I rowsort
SELECT + col2 + + col2 * - tab1.col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT col1 * col0 / col2 FROM tab1 WHERE NOT ( NULL ) <= NULL
----

query I rowsort
SELECT col1 + - col0 - col0 * + tab2.col2 FROM tab2
----
-165
-2047
-3064

query I rowsort
SELECT col1 + col2 + - col0 AS col1 FROM tab2
----
-24
51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + tab0.col2 - col0 col2 FROM tab0
----
0
7209
768

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE NOT col1 >= NULL
----

query I rowsort
SELECT col2 * - cor0.col2 * 63 FROM tab1 AS cor0
----
-183708
-204687
-580608

query I rowsort
SELECT DISTINCT col2 + - col1 * + col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + col2 + col2 * tab0.col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT col0 * + col1 + col0 * + col0 FROM tab2
----
10686
266
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-5400
SELECT - 86 + + col2 DIV + col0 FROM tab0 cor0
----
-85
-86
-86

skipif mysql # not compatible
query I rowsort label-5400
SELECT - 86 + + col2 / + col0 FROM tab0 cor0
----
-85
-86
-86

query I rowsort
SELECT col1 * - col0 * - ( col0 ) FROM tab1 AS cor0
----
234
40960
83200

skipif mysql # not compatible
query I rowsort
SELECT + cor0.col1 + CAST ( col0 AS REAL ) * - col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT + col1 + + col0 * + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - col1 - 46 * + col0 AS col2 FROM tab2 AS cor0
----
-353
-3647
-3651

query I rowsort
SELECT DISTINCT - col2 * - ( col0 ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + - col2 * + 47 * ( - col0 * col2 ) AS col0 FROM tab0 AS cor0
----
1228392
1645
28126492

query I rowsort
SELECT - + col0 + cor0.col0 * 92 FROM tab2 cor0
----
637
7098
7189

query I rowsort
SELECT + + col2 + 68 * 99 AS col2 FROM tab2 AS cor0
----
6758
6759
6770

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5409
SELECT ALL - col0 * + CAST( cor0.col0 AS SIGNED ) + + col1 FROM tab1 AS cor0
----
-4086
-6387
17

skipif mysql # not compatible
query I rowsort label-5409
SELECT ALL - col0 * + CAST ( cor0.col0 AS INTEGER ) + + col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT - col2 * - ( col1 ) - + col1 * col0 AS col2 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT + col2 - - cor0.col2 AS col0 FROM tab2 cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5412
SELECT ALL - - col2 * CAST( ( - col0 ) AS SIGNED ) + - cor0.col2 FROM tab1 AS cor0
----
-216
-3705
-7776

skipif mysql # not compatible
query I rowsort label-5412
SELECT ALL - - col2 * CAST ( ( - col0 ) AS INTEGER ) + - cor0.col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT - col2 * ( 44 ) - - col1 AS col1 FROM tab0 AS cor0
----
-1366
-3517
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-5414
SELECT - tab2.col2 DIV + col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-5414
SELECT - tab2.col2 / + col0 FROM tab2
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + cor0.col2 * cor0.col0 col2 FROM tab2 cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-5416
SELECT - 10 + - col0 DIV col1 AS col0 FROM tab0 cor0
----
-10
-10
-10

skipif mysql # not compatible
query I rowsort label-5416
SELECT - 10 + - col0 / col1 AS col0 FROM tab0 cor0
----
-10
-10
-10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( - tab2.col0 * col1 ) col2 FROM tab2
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 44 col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5419
SELECT 36 DIV - cor0.col2 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a46b7b0a5578e903d3acf08c027edab

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5419
SELECT 36 / - cor0.col2 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a46b7b0a5578e903d3acf08c027edab

query I rowsort
SELECT + 46 * - col2 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT DISTINCT 51 + col2 AS col1 FROM tab1 AS cor0
----
105
108
147

query I rowsort
SELECT ALL col2 + + col2 + - col2 AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL + 98 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5424
SELECT - - col1 DIV + col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5424
SELECT - - col1 / + col1 FROM tab0 cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5425
SELECT + ( cor0.col0 ) * CAST( col1 * + col1 AS SIGNED ) col1 FROM tab2 AS cor0
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5425
SELECT + ( cor0.col0 ) * CAST ( col1 * + col1 AS INTEGER ) col1 FROM tab2 AS cor0
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-5426
SELECT ALL - col1 + - col2 DIV + cor0.col0 + + col0 FROM tab2 AS cor0
----
-27
19
62

skipif mysql # not compatible
query I rowsort label-5426
SELECT ALL - col1 + - col2 / + cor0.col0 + + col0 FROM tab2 AS cor0
----
-27
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col0 col1 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5428
SELECT DISTINCT col0 * cor0.col2 DIV col1 FROM tab2 AS cor0
----
176
34
6

skipif mysql # not compatible
query I rowsort label-5428
SELECT DISTINCT col0 * cor0.col2 / col1 FROM tab2 AS cor0
----
176
34
6

query I rowsort
SELECT cor0.col2 + - col0 AS col1 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT + + col1 + col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5431
SELECT CAST( col0 AS SIGNED ) + - col2 FROM tab0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-5431
SELECT CAST ( col0 AS INTEGER ) + - col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL - 47 + 42 FROM tab0
----
-5
-5
-5

query I rowsort
SELECT + 19 + + col1 AS col1 FROM tab0
----
105
110
116

query I rowsort
SELECT DISTINCT col2 * - col1 * + col0 + - col0 AS col0 FROM tab1
----
-36544
-4215
-99920

query I rowsort
SELECT + 46 * + col1 + col2 AS col1 FROM tab1 AS cor0
----
1250
517
694

onlyif mysql # use DIV operator for integer division
query I rowsort label-5436
SELECT DISTINCT - ( - 96 ) + + cor0.col2 DIV col0 AS col0 FROM tab2 AS cor0
----
96
99

skipif mysql # not compatible
query I rowsort label-5436
SELECT DISTINCT - ( - 96 ) + + cor0.col2 / col0 AS col0 FROM tab2 AS cor0
----
96
99

query I rowsort
SELECT ALL 79 - cor0.col0 AS col2 FROM tab0 cor0
----
-10
44
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-5438
SELECT - - col0 DIV 99 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5438
SELECT - - col0 / 99 + - col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - 87 + col1 FROM tab2 AS cor0
----
-28
-56
-70

query I rowsort
SELECT col2 * 94 + col2 AS col2 FROM tab2 AS cor0
----
2470
2565
3610

query I rowsort
SELECT ALL + col0 + - 45 AS col2 FROM tab1 AS cor0
----
-42
19
35

query I rowsort
SELECT DISTINCT + col2 * col0 * col2 + col2 AS col2 FROM tab0 AS cor0
----
26169
36
598518

query I rowsort
SELECT ALL - cor0.col0 + + col1 AS col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT - col0 + + cor0.col1 * + col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL ( col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col1 * col0 + col2 + - col1 * col2 AS col2 FROM tab0 AS cor0
----
-741
3299
719

query I rowsort
SELECT + 22 - col1 AS col1 FROM tab1
----
-4
12
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5448
SELECT DISTINCT 96 + col1 * col1 DIV tab0.col1 FROM tab0
----
182
187
193

skipif mysql # not compatible
query I rowsort label-5448
SELECT DISTINCT 96 + col1 * col1 / tab0.col1 FROM tab0
----
182
187
193

query I rowsort
SELECT DISTINCT - ( - col2 ) + + col1 * - col0 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT col2 * + col2 + - tab0.col2 AS col1 FROM tab0
----
0
1056
6642

query I rowsort
SELECT ALL 45 + col1 FROM tab2
----
104
62
76

query I rowsort
SELECT ALL + col2 + col2 * col0 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - 11 * col0 + col0 FROM tab1 AS cor0
----
-30
-640
-800

query I rowsort
SELECT tab2.col1 * 53 AS col0 FROM tab2
----
1643
3127
901

query I rowsort
SELECT col0 * + 90 - col1 AS col1 FROM tab1
----
244
5750
7187

query I rowsort
SELECT ALL - - 12 AS col1 FROM tab2 AS cor0
----
12
12
12

query I rowsort
SELECT - col1 + - col2 - cor0.col1 FROM tab2 AS cor0
----
-144
-72
-89

query I rowsort
SELECT + 60 FROM tab2, tab2 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to 1ef27a1d2784b3ab642571630db70349

onlyif mysql # use DIV operator for integer division
query I rowsort label-5459
SELECT ALL ( - col1 ) DIV col0 AS col0 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-5459
SELECT ALL ( - col1 ) / col0 AS col0 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT col1 * + cor0.col2 + col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT 52 + col0 AS col2 FROM tab2 AS cor0
----
130
131
59

query I rowsort
SELECT DISTINCT + + ( - col1 ) * cor0.col2 * + 27 FROM tab2 AS cor0
----
-17442
-22599
-41418

query I rowsort
SELECT - - col1 + - col1 * - 56 AS col2 FROM tab2 AS cor0
----
1767
3363
969

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-5465
SELECT + - col2 + cor0.col1 DIV - col0 FROM tab0 cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-5465
SELECT + - col2 + cor0.col1 / - col0 FROM tab0 cor0
----
-3
-36
-83

query I rowsort
SELECT + 24 FROM tab2, tab0 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT + 88 + - col2 FROM tab0 AS cor0
----
55
6
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5468
SELECT ALL + CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5468
SELECT ALL + CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 + col1 col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - col2 + - cor0.col0 * 83 FROM tab1 AS cor0
----
-303
-5369
-6736

query I rowsort
SELECT 69 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5472
SELECT - col2 + CAST( - col0 AS SIGNED ) AS col1 FROM tab1 cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-5472
SELECT - col2 + CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT ALL - cor0.col2 * 15 + - col0 FROM tab1 AS cor0
----
-1520
-813
-919

onlyif mysql # use DIV operator for integer division
query I rowsort label-5474
SELECT + col2 + - ( + col2 ) - 59 DIV col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-5474
SELECT + col2 + - ( + col2 ) - 59 / col0 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT - col2 * + 3 AS col0 FROM tab0 cor0
----
-246
-3
-99

query I rowsort
SELECT - col1 * - col1 - col2 AS col2 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT - + 93 * cor0.col2 + col1 * + cor0.col0 * + col2 AS col1 FROM tab2 AS cor0
----
117234
3348
47500

query I rowsort
SELECT 64 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5479
SELECT DISTINCT col1 * CAST( col0 AS SIGNED ) FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5479
SELECT DISTINCT col1 * CAST ( col0 AS INTEGER ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT + 97 FROM tab0, tab0 cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT + cor0.col2 * + 33 * col0 FROM tab0 AS cor0
----
1155
240834
26136

query I rowsort
SELECT - col2 * - col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT + 56 * cor1.col2 FROM tab0, tab0 cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to 44e2612e503778d7ece72fbbdd950296

query I rowsort
SELECT ALL - ( + col1 ) + - col1 * - col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT 61 * cor0.col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
1116
1898
3677

onlyif mysql # use DIV operator for integer division
query I rowsort label-5486
SELECT DISTINCT col2 DIV - 92 AS col1 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-5486
SELECT DISTINCT col2 / - 92 AS col1 FROM tab1
----
-1
0

query I rowsort
SELECT tab0.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5488
SELECT 20 * tab0.col2 DIV - col0 FROM tab0
----
-18
-27
0

skipif mysql # not compatible
query I rowsort label-5488
SELECT 20 * tab0.col2 / - col0 FROM tab0
----
-18
-27
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + col2 - - cor0.col1 col1 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT - + col0 - col0 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT ALL cor0.col2 * - col0 + col2 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL + ( col2 ) + ( + col0 ) * col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT 21 + cor0.col2 FROM tab1 AS cor0
----
117
75
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5494
SELECT - col1 DIV - 7 FROM tab1
----
1
1
3

skipif mysql # not compatible
query I rowsort label-5494
SELECT - col1 / - 7 FROM tab1
----
1
1
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5495
SELECT CAST( + col2 AS SIGNED ) + - col1 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-5495
SELECT CAST ( + col2 AS INTEGER ) + - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + cor2.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT 92 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
92

query I rowsort
SELECT ALL - ( + tab0.col1 ) * 9 FROM tab0
----
-774
-819
-873

query I rowsort
SELECT - - cor0.col2 * - cor0.col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - cor0.col0 * 29 + 89 FROM tab2 AS cor0
----
-114
-2173
-2202

query I rowsort
SELECT - - cor0.col2 + - cor0.col1 * - col2 AS col0 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT + 85 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

query I rowsort
SELECT ALL ( col1 + col1 ) AS col1 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT + + 46 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
46

query I rowsort
SELECT + 58 * + 42 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 6288307cc43710956bf5ca975d034534

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col0 FROM tab2, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT + 97 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
97

query I rowsort
SELECT ALL + col0 * - ( col2 ) FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT - col0 + + 18 FROM tab2 cor0
----
-60
-61
11

query I rowsort
SELECT DISTINCT 97 AS col0 FROM tab1, tab0, tab1 AS cor0
----
97

query I rowsort
SELECT - col2 * col1 * 2 FROM tab1 cor0
----
-1140
-2496
-2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-5512
SELECT DISTINCT cor0.col0 + cor0.col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-5512
SELECT DISTINCT cor0.col0 + cor0.col2 / + col2 AS col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - - ( - col1 ) * - ( 72 ) FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT ALL - 60 FROM tab2, tab0 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5515
SELECT DISTINCT col1 + - cor0.col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5515
SELECT DISTINCT col1 + - cor0.col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + col1 - - col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL col2 * 73 FROM tab1 AS cor0
----
3942
4161
7008

query I rowsort
SELECT col2 * 83 * col1 AS col2 FROM tab2 cor0
----
127322
53618
69471

query I rowsort
SELECT DISTINCT - + col1 * + 32 AS col2 FROM tab2 AS cor0
----
-1888
-544
-992

query I rowsort
SELECT - col1 * col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT - col1 * - ( 23 ) * col2 AS col0 FROM tab2 AS cor0
----
14858
19251
35282

query I rowsort
SELECT - col0 + + cor0.col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-5523
SELECT - cor0.col1 DIV 49 AS col2 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5523
SELECT - cor0.col1 / 49 AS col2 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT col2 * 20 FROM tab1 AS cor0
----
1080
1140
1920

query I rowsort
SELECT DISTINCT - cor0.col0 AS col0 FROM tab0, tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 62 * - col2 FROM tab0
----
-2046
-5084
-62

query I rowsort
SELECT DISTINCT + + cor0.col2 * col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + - col1 * - 43 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT - cor0.col0 * cor0.col2 * + col1 FROM tab2 cor0
----
-119652
-51034
-5859

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 * - CAST ( - col0 AS REAL ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - + col1 * + col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - ( - cor0.col1 ) + col2 * + 94 * + col1 + + col2 FROM tab1 AS cor0
----
117421
132056
53647

query I rowsort
SELECT + col2 * - 59 FROM tab0 AS cor0
----
-1947
-4838
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5534
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col2 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5534
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col2 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - - col0 * - cor0.col2 + + col1 + + 2 AS col2 FROM tab1 cor0
----
-134
-3636
-7665

onlyif mysql # use DIV operator for integer division
query I rowsort label-5536
SELECT DISTINCT - + cor0.col2 * 51 DIV - col0 + - col0 * - col1 * + col2 AS col0 FROM tab0 AS cor0
----
3396
664164
68182

skipif mysql # not compatible
query I rowsort label-5536
SELECT DISTINCT - + cor0.col2 * 51 / - col0 + - col0 * - col1 * + col2 AS col0 FROM tab0 AS cor0
----
3396
664164
68182

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5537
SELECT - CAST( NULL AS SIGNED ) + 94 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5537
SELECT - CAST ( NULL AS INTEGER ) + 94 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col0 + 38 * col0 FROM tab1 AS cor0
----
111
2368
2960

query I rowsort
SELECT ALL 28 + - col0 FROM tab1 AS cor0
----
-36
-52
25

query I rowsort
SELECT ALL - col1 * - 33 * + col1 + col1 * col2 * + col1 + + cor0.col0 * - col1 AS col2 FROM tab0 AS cor0
----
316511
486072
944216

query I rowsort
SELECT ALL - ( + col1 ) * - col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - ( - col0 ) + + col0 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT col1 + + 14 AS col2 FROM tab1 AS cor0
----
24
27
40

query I rowsort
SELECT ALL + 17 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT DISTINCT + 19 AS col1 FROM tab2 cor0
----
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * cor0.col0 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1798
-5015
-935

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 + - col2 - - col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 53 + col0 AS col1 FROM tab0 cor0
----
142
77
88

query I rowsort
SELECT - + col1 * col1 + - col1 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-124
-1947
357

query I rowsort
SELECT ALL - 7 * + col1 AS col2 FROM tab0 cor0
----
-602
-637
-679

query I rowsort
SELECT DISTINCT - 56 + col2 FROM tab1 AS cor0
----
-2
1
40

query I rowsort
SELECT DISTINCT col2 + + 63 AS col2 FROM tab2
----
101
89
90

query I rowsort
SELECT + 10 + + col0 AS col0 FROM tab0
----
34
45
99

query I rowsort
SELECT col2 + - col0 * ( - col1 + col1 ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + ( - col0 ) * + ( + 72 ) FROM tab0 AS cor0
----
-1728
-2520
-6408

onlyif mysql # use DIV operator for integer division
query I rowsort label-5557
SELECT ALL + col2 DIV + col2 + cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-5557
SELECT ALL + col2 / + col2 + cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
36
7299
793

onlyif mysql # use DIV operator for integer division
query I rowsort label-5558
SELECT ALL + - 19 DIV cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

skipif mysql # not compatible
query I rowsort label-5558
SELECT ALL + - 19 / cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

query I rowsort
SELECT - + 23 * col0 + - col0 FROM tab2 AS cor0
----
-168
-1872
-1896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + col2 + + col0 + col0 col2 FROM tab1 AS cor0
----
168
3776
7840

query I rowsort
SELECT DISTINCT - - col0 * - 36 * col2 FROM tab0 AS cor0
----
-1260
-262728
-28512

query I rowsort
SELECT ALL - col2 + 39 FROM tab1
----
-15
-18
-57

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab2 cor1, tab2 AS cor2, tab1 AS cor3
----
3645 values hashing to 40a052eaf1d698dbf3ba319dc3e245ee

query I rowsort
SELECT ALL - 23 + + 44 * - tab2.col0 * col0 FROM tab2
----
-2179
-267719
-274627

query I rowsort
SELECT + ( + col0 ) + + col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT 1 * cor0.col1 + col0 - col1 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5567
SELECT DISTINCT ( col1 ) DIV + col0 col0 FROM tab2 AS cor0
----
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5567
SELECT DISTINCT ( col1 ) / + col0 col0 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT ALL - - col0 + - col1 * - col1 FROM tab1 cor0
----
164
249
679

query I rowsort
SELECT DISTINCT col2 * 49 + col1 FROM tab2 AS cor0
----
1333
1354
1879

query I rowsort
SELECT DISTINCT cor1.col2 AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5571
SELECT col2 DIV 50 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5571
SELECT col2 / 50 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col1 * col1 AS col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - 56 FROM tab2, tab1 AS cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

query I rowsort
SELECT DISTINCT + - col0 * + col2 + 6 AS col1 FROM tab2 AS cor0
----
-183
-2022
-2996

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col0 + - col2 col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL - 99 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

query I rowsort
SELECT ALL col1 * 19 FROM tab2
----
1121
323
589

query I rowsort
SELECT ALL ( col1 * col2 + - 40 ) FROM tab1
----
1208
1364
530

query I rowsort
SELECT + 25 + - col2 AS col0 FROM tab1
----
-29
-32
-71

query I rowsort
SELECT DISTINCT - 85 FROM tab1, tab0, tab1 cor0
----
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5581
SELECT DISTINCT + col2 * 50 DIV col0 + + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-13
-36
846

skipif mysql # not compatible
query I rowsort label-5581
SELECT DISTINCT + col2 * 50 / col0 + + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-13
-36
846

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 26 + col1 col2 FROM tab0 AS cor0
----
112
117
123

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5583
SELECT DISTINCT - CAST( - col0 AS SIGNED ) + col1 * col0 * col0 FROM tab2 AS cor0
----
106176
1526
359034

skipif mysql # not compatible
query I rowsort label-5583
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) + col1 * col0 * col0 FROM tab2 AS cor0
----
106176
1526
359034

onlyif mysql # use DIV operator for integer division
query I rowsort label-5584
SELECT ALL - ( - cor0.col2 ) * + col1 + col1 * + col2 DIV col2 FROM tab0 AS cor0
----
194
2924
7553

skipif mysql # not compatible
query I rowsort label-5584
SELECT ALL - ( - cor0.col2 ) * + col1 + col1 * + col2 / col2 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5585
SELECT ALL + cor0.col2 * - col0 + + col1 * + ( - col0 ) * - col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5585
SELECT ALL + cor0.col2 * - col0 + + col1 * + ( - col0 ) * - col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 59 + + 68 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 1de8a9fa3109e3012ceb238e719a41b3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5587
SELECT DISTINCT - 79 DIV col0 FROM tab0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-5587
SELECT DISTINCT - 79 / col0 FROM tab0
----
-2
-3
0

query I rowsort
SELECT + col1 + col1 * cor0.col0 + col1 FROM tab1 cor0
----
1066
130
660

query I rowsort
SELECT DISTINCT + 65 * col1 + - col2 + col0 FROM tab2 AS cor0
----
1146
1995
3887

query I rowsort
SELECT DISTINCT - - 13 + - cor0.col2 + col0 AS col1 FROM tab0 cor0
----
20
4
47

query I rowsort
SELECT ALL + 24 * col1 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT ALL 84 FROM tab0, tab2, tab2 cor0, tab1 cor1
----
81 values hashing to 3c092ed1a99ddb5afc7049fd2b9427f9

query I rowsort
SELECT - cor0.col0 * col0 * + col1 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-5594
SELECT - 87 DIV cor0.col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-5594
SELECT - 87 / cor0.col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT - - col1 + col2 * col1 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - col2 + + col2 * - 62 FROM tab0 AS cor0
----
-2079
-5166
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-5597
SELECT + col2 DIV col2 + + col1 * 81 FROM tab0 AS cor0
----
6967
7372
7858

skipif mysql # not compatible
query I rowsort label-5597
SELECT + col2 / col2 + + col1 * 81 FROM tab0 AS cor0
----
6967
7372
7858

query I rowsort
SELECT cor0.col1 + + 62 FROM tab0 cor0
----
148
153
159

query I rowsort
SELECT col0 + - 20 * 82 AS col1 FROM tab2 AS cor0
----
-1561
-1562
-1633

query I rowsort
SELECT ALL - + col1 * - 61 * 22 FROM tab2 AS cor0
----
22814
41602
79178

onlyif mysql # use DIV operator for integer division
query I rowsort label-5601
SELECT + - col1 DIV + 9 FROM tab2 AS cor0
----
-1
-3
-6

skipif mysql # not compatible
query I rowsort label-5601
SELECT + - col1 / + 9 FROM tab2 AS cor0
----
-1
-3
-6

query I rowsort
SELECT DISTINCT - cor1.col2 * 99 FROM tab1, tab0, tab1 AS cor0, tab2 cor1
----
-2574
-2673
-3762

query I rowsort
SELECT + ( - col2 ) + col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT 86 * col1 AS col0 FROM tab0 AS cor0
----
7396
7826
8342

query I rowsort
SELECT col2 + + 9 AS col0 FROM tab0 AS cor0
----
10
42
91

query I rowsort
SELECT + col0 * - ( col0 * + tab0.col0 + + ( 96 ) ) FROM tab0
----
-16128
-46235
-713513

query I rowsort
SELECT - col2 + ( - tab0.col2 ) * tab0.col1 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT ALL + col1 + - 1 FROM tab1
----
12
25
9

query I rowsort
SELECT ALL 10 - cor0.col1 FROM tab0 cor0
----
-76
-81
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5610
SELECT - col2 DIV 24 + col0 col2 FROM tab0 AS cor0
----
23
35
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5610
SELECT - col2 / 24 + col0 col2 FROM tab0 AS cor0
----
23
35
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 73 * 83 col2 FROM tab1
----
-6059
-6059
-6059

query I rowsort
SELECT + tab1.col1 * - 81 FROM tab1
----
-1053
-2106
-810

query I rowsort
SELECT + tab2.col1 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5614
SELECT DISTINCT - tab0.col2 DIV - col1 col2 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5614
SELECT DISTINCT - tab0.col2 / - col1 col2 FROM tab0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5615
SELECT ALL + col1 * + CAST( col0 AS SIGNED ) * col0 FROM tab0
----
118825
49536
720811

skipif mysql # not compatible
query I rowsort label-5615
SELECT ALL + col1 * + CAST ( col0 AS INTEGER ) * col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + col1 + + tab1.col0 FROM tab1
----
29
74
93

query I rowsort
SELECT - - col0 * - 53 AS col0 FROM tab1 AS cor0
----
-159
-3392
-4240

query I rowsort
SELECT DISTINCT + col0 + col0 * col1 * + cor0.col2 - col1 FROM tab2 AS cor0
----
119671
51096
5835

query I rowsort
SELECT DISTINCT 34 + col0 AS col2 FROM tab0 AS cor0
----
123
58
69

query I rowsort
SELECT ALL col2 * col1 * col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - col2 * - ( col2 ) AS col0 FROM tab2 cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5622
SELECT ALL + col0 + + cor0.col0 DIV col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-5622
SELECT ALL + col0 + + cor0.col0 / col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT 47 * col2 AS col2 FROM tab1 cor0
----
2538
2679
4512

query I rowsort
SELECT ALL - 2 * + col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT 55 + - 26 * - col2 AS col0 FROM tab0 AS cor0
----
2187
81
913

query I rowsort
SELECT ALL ( cor0.col0 ) + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5627
SELECT DISTINCT + cor0.col0 + col1 DIV - col1 AS col2 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-5627
SELECT DISTINCT + cor0.col0 + col1 / - col1 AS col2 FROM tab1 AS cor0
----
2
63
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5628
SELECT + - col2 DIV col1 AS col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-5628
SELECT + - col2 / col1 AS col1 FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT + 89 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT + - col2 * - cor0.col1 + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + + 79 * + col1 + 35 * + col0 AS col1 FROM tab1 AS cor0
----
2159
3030
3827

query I rowsort
SELECT + col2 * - col1 - 24 * col2 AS col2 FROM tab0 AS cor0
----
-121
-3630
-9430

onlyif mysql # use DIV operator for integer division
query I rowsort label-5633
SELECT 16 DIV - col2 + col0 DIV col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5633
SELECT 16 / - col2 + col0 / col2 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5634
SELECT col1 DIV - col0 + + 56 FROM tab0 AS cor0
----
53
54
55

skipif mysql # not compatible
query I rowsort label-5634
SELECT col1 / - col0 + + 56 FROM tab0 AS cor0
----
53
54
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 23 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT ( tab2.col1 * col0 ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT + cor0.col0 + col1 + + 73 AS col1 FROM tab1 AS cor0
----
102
147
166

query I rowsort
SELECT DISTINCT col2 * + 86 AS col2 FROM tab0 AS cor0
----
2838
7052
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-5639
SELECT DISTINCT - col2 DIV - cor0.col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5639
SELECT DISTINCT - col2 / - cor0.col2 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL + + cor0.col1 + col0 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + cor0.col1 * ( col1 ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - col2 + ( + cor0.col2 ) * col1 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL - - col0 * - 67 + + col1 * col1 FROM tab2 cor0
----
-1745
-5004
492

query I rowsort
SELECT ALL - - cor0.col2 + - col2 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5645
SELECT DISTINCT col0 DIV - ( col1 ) + - col2 FROM tab2 AS cor0
----
-27
-42

skipif mysql # not compatible
query I rowsort label-5645
SELECT DISTINCT col0 / - ( col1 ) + - col2 FROM tab2 AS cor0
----
-27
-42

onlyif mysql # use DIV operator for integer division
query I rowsort label-5646
SELECT ALL + + col0 + col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-5646
SELECT ALL + + col0 + col2 / + col1 AS col2 FROM tab2 AS cor0
----
7
78
81

query I rowsort
SELECT - + cor0.col2 * ( 84 * + col2 ) + ( 3 ) * col0 AS col1 FROM tab0 AS cor0
----
-564549
-91404
21

query I rowsort
SELECT + col0 + 9 FROM tab1 cor0
----
12
73
89

query I rowsort
SELECT ALL - 9 - - col2 FROM tab0
----
-8
24
73

query I rowsort
SELECT DISTINCT col2 * + col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + cor0.col2 + + col1 * - 86 AS col2 FROM tab1 AS cor0
----
-1022
-2182
-803

query I rowsort
SELECT col2 - + cor0.col1 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col2 * col0 - col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT + cor0.col2 * ( + cor0.col1 ) * - cor0.col2 + + col0 * col0 AS col1 FROM tab0 cor0
----
-603963
-93078
1128

query I rowsort
SELECT DISTINCT + - col2 + col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + - cor0.col2 + 10 * col0 FROM tab1 cor0
----
-24
583
704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5657
SELECT ALL - - col2 / + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5657
SELECT ALL - - col2 / + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col1 * + ( + tab0.col2 ) AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - col0 * col2 + cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-5660
SELECT ALL - col0 + col1 DIV col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5660
SELECT ALL - col0 + col1 / col2 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5661
SELECT 10 * - col2 - + tab0.col0 DIV 79 FROM tab0
----
-10
-330
-821

skipif mysql # not compatible
query I rowsort label-5661
SELECT 10 * - col2 - + tab0.col0 / 79 FROM tab0
----
-10
-330
-821

query I rowsort
SELECT DISTINCT - col2 * col0 * tab1.col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT ALL - tab1.col0 * - tab1.col2 * 25 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to a26be84bb7e9d4dc172d8dcf41281694

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5664
SELECT DISTINCT - - 36 * + col1 + CAST( NULL AS SIGNED ) col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5664
SELECT DISTINCT - - 36 * + col1 + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ( - 69 ) FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT ALL - 67 * - cor0.col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 94deb655cbd335c2b72ace3303b0f70b

query I rowsort
SELECT DISTINCT + col2 + + col1 * - 13 AS col0 FROM tab2
----
-183
-376
-741

query I rowsort
SELECT + col2 FROM tab2 AS cor0 WHERE NOT NULL IN ( - col1 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT - col0 <> col0 * tab0.col2 / col2 + col2
----

query III rowsort
SELECT * FROM tab2 WHERE - col1 + col0 NOT IN ( col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT tab0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT col0 + col1 * col1 * tab2.col1 FROM tab2
----
205457
29798
4992

onlyif mysql # use DIV operator for integer division
query I rowsort label-5673
SELECT ALL + tab2.col0 * + col1 DIV - col1 + col1 * col0 FROM tab2
----
1264
210
4524

skipif mysql # not compatible
query I rowsort label-5673
SELECT ALL + tab2.col0 * + col1 / - col1 + col1 * col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT col2 * col1 * + col2 + cor0.col2 AS col2 FROM tab0 cor0
----
611966
93687
98

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) <= + col0 + col0 * - col1 * - col0
----

query I rowsort
SELECT DISTINCT col1 + - col1 + col2 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5677
SELECT DISTINCT col1 DIV col1 + + col1 + + col0 FROM tab1
----
30
75
94

skipif mysql # not compatible
query I rowsort label-5677
SELECT DISTINCT col1 / col1 + + col1 + + col0 FROM tab1
----
30
75
94

query I rowsort
SELECT col2 - col0 AS col1 FROM tab1 WHERE NOT - col0 + col0 = - col2
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5679
SELECT DISTINCT + tab2.col1 DIV - col1 col0 FROM tab2
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5679
SELECT DISTINCT + tab2.col1 / - col1 col0 FROM tab2
----
-1

query I rowsort
SELECT ALL + tab1.col2 + + col1 + col2 FROM tab1
----
124
134
205

onlyif mysql # use DIV operator for integer division
query I rowsort label-5681
SELECT - col1 * - col2 DIV col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5681
SELECT - col1 * - col2 / col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + 21 + + tab2.col1 AS col0 FROM tab2
----
38
52
80

query I rowsort
SELECT + cor0.col0 * col0 + - col2 * col1 * - col2 FROM tab1 cor0
----
126208
36586
75825

query I rowsort
SELECT DISTINCT + col1 + + col2 * + 23 AS col1 FROM tab1
----
1268
1321
2221

query I rowsort
SELECT ALL col0 - cor0.col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - 57 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
-57

query I rowsort
SELECT + cor0.col1 + col2 * 93 FROM tab0 AS cor0
----
190
3155
7717

query I rowsort
SELECT DISTINCT + - col0 * col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 + + col0 * col1 FROM tab1 cor0
----
1027
52
630

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 + col0 * + col0 * - col2 - col2 <> NULL
----

query I rowsort
SELECT DISTINCT col0 * tab1.col2 FROM tab1 WHERE NOT NULL NOT IN ( - tab1.col0 )
----

query III rowsort
SELECT * FROM tab0 WHERE col1 < + col0
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL >= col2 * col1
----

query I rowsort
SELECT + col2 * - tab2.col2 + - col1 * + col0 FROM tab2
----
-2787
-5278
-946

query I rowsort
SELECT DISTINCT + col0 - + tab0.col2 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL - col0 * col1 * + col0 + col1 AS col1 FROM tab0
----
-118728
-49450
-720720

query I rowsort
SELECT col1 - + tab1.col0 * col1 AS col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + col0 * + col1 + + col0 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - tab1.col0 FROM tab1 WHERE NULL NOT BETWEEN + tab1.col2 * - col0 AND NULL
----

query I rowsort
SELECT ALL col1 AS col2 FROM tab0 AS cor0 WHERE NOT col1 = col2 * col1 * col2
----
86
91

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND ( col1 + - col2 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL BETWEEN ( tab0.col1 + - col1 * col1 * - col0 ) AND - col1 + - col2
----

query I rowsort
SELECT DISTINCT + col0 FROM tab2 WHERE - col0 + col2 <> ( col2 * + col0 + col1 )
----
7
78
79

query I rowsort
SELECT DISTINCT col0 * + col0 * tab2.col1 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT col1 * - col2 + tab1.col1 AS col2 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT ALL col2 + - tab1.col0 + + col1 AS col2 FROM tab1
----
29
3
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * tab2.col0 + col0 * col0 + - col2 col0 FROM tab2
----
10660
239
7546

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL >= ( - col1 * - col0 + col2 + - col0 )
----

query I rowsort
SELECT ALL col2 * + col2 + col1 * + col2 * tab0.col2 + tab0.col0 AS col0 FROM tab0
----
133
618697
94767

query I rowsort
SELECT DISTINCT - col0 + + tab2.col2 + col2 AS col2 FROM tab2
----
-26
-3
47

query I rowsort
SELECT col2 + + col0 * col1 FROM tab2
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-5712
SELECT + col1 DIV col1 + - tab0.col2 * col1 AS col1 FROM tab0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-5712
SELECT + col1 / col1 + - tab0.col2 * col1 AS col1 FROM tab0
----
-2837
-7461
-96

query I rowsort
SELECT DISTINCT tab2.col1 * - col1 AS col1 FROM tab2
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * col1 * col1 col0 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT col1 * - col0 * + col0 AS col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT col1 AS col2 FROM tab2 WHERE NOT col0 * + col1 <> col1 + col0
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5717
SELECT + CAST( NULL AS SIGNED ) + 69 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5717
SELECT + CAST ( NULL AS INTEGER ) + 69 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + col0 + - col2 * 36 AS col2 FROM tab2 AS cor0
----
-1289
-858
-965

onlyif mysql # use DIV operator for integer division
query I rowsort label-5719
SELECT ALL + cor0.col2 DIV - col1 + - 36 AS col1 FROM tab1 AS cor0
----
-38
-41
-43

skipif mysql # not compatible
query I rowsort label-5719
SELECT ALL + cor0.col2 / - col1 + - 36 AS col1 FROM tab1 AS cor0
----
-38
-41
-43

query I rowsort
SELECT ALL + col2 + cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-5721
SELECT + 15 DIV + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5721
SELECT + 15 / + col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 - - col1 col1 FROM tab0 AS cor0
----
168
173
179

onlyif mysql # use DIV operator for integer division
query I rowsort label-5723
SELECT DISTINCT + - cor0.col2 * + col0 + col1 DIV - 13 AS col0 FROM tab1 AS cor0
----
-164
-3648
-7681

skipif mysql # not compatible
query I rowsort label-5723
SELECT DISTINCT + - cor0.col2 * + col0 + col1 / - 13 AS col0 FROM tab1 AS cor0
----
-164
-3648
-7681

onlyif mysql # use DIV operator for integer division
query I rowsort label-5724
SELECT col2 DIV col0 - + tab1.col2 FROM tab1
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-5724
SELECT col2 / col0 - + tab1.col2 FROM tab1
----
-36
-57
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5725
SELECT + + col1 + + CAST( col2 * + col0 + col2 AS SIGNED ) col2 FROM tab2 AS cor0
----
2113
247
3057

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5725
SELECT + + col1 + + CAST ( col2 * + col0 + col2 AS INTEGER ) col2 FROM tab2 AS cor0
----
2113
247
3057

query I rowsort
SELECT - col1 + col1 * 74 FROM tab2
----
1241
2263
4307

query I rowsort
SELECT cor0.col0 + col0 * col1 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT - col1 * col1 + ( + 90 ) AS col1 FROM tab2 AS cor0
----
-199
-3391
-871

query I rowsort
SELECT DISTINCT - 37 + + col1 AS col0 FROM tab1 AS cor0
----
-11
-24
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 88 + + col2 col0 FROM tab0 AS cor0
----
121
170
89

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 + col2 + - CAST ( col2 + - col0 AS REAL ) * col0 AS col1 FROM tab0
----
-97
1288
796

onlyif mysql # use DIV operator for integer division
query I rowsort label-5732
SELECT DISTINCT + ( - col0 ) + col2 DIV + col0 AS col1 FROM tab1
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-5732
SELECT DISTINCT + ( - col0 ) + col2 / + col0 AS col1 FROM tab1
----
-64
-79
15

query I rowsort
SELECT ALL - 8 + + tab0.col2 FROM tab0
----
-7
25
74

query I rowsort
SELECT DISTINCT - col0 * 94 AS col2 FROM tab1
----
-282
-6016
-7520

query I rowsort
SELECT DISTINCT + 13 * 36 FROM tab2 AS cor0
----
468

query I rowsort
SELECT DISTINCT + - col1 + col0 * - col2 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT + col1 * - 23 + col1 * col1 AS col0 FROM tab0
----
5418
6188
7178

query I rowsort
SELECT ALL tab2.col2 + 13 FROM tab2, tab0 cor0
----
9 values hashing to de0d241e0d4cacdb6e1b4cc5e8ada56f

query I rowsort
SELECT ALL - col0 * 91 FROM tab1
----
-273
-5824
-7280

query I rowsort
SELECT + col2 * ( + 99 ) - + col1 FROM tab1
----
5320
5633
9491

query I rowsort
SELECT ALL tab0.col0 * col1 * - col2 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5742
SELECT DISTINCT + col2 + + col0 DIV col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-5742
SELECT DISTINCT + col2 + + col0 / col2 FROM tab0
----
33
36
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5743
SELECT ALL - ( col0 ) + - col0 * 24 DIV + 41 FROM tab1
----
-101
-126
-4

skipif mysql # not compatible
query I rowsort label-5743
SELECT ALL - ( col0 ) + - col0 * 24 / + 41 FROM tab1
----
-101
-126
-4

query I rowsort
SELECT DISTINCT col0 * col0 * col0 - - col0 AS col1 FROM tab0 AS cor0
----
13848
42910
705058

query I rowsort
SELECT ALL col2 * - 67 AS col0 FROM tab0 AS cor0
----
-2211
-5494
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + - col0 * - col2 col1 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5747
SELECT DISTINCT + col0 * col2 DIV - col1 + + 45 * + 29 AS col1 FROM tab2 AS cor0
----
1129
1271
1299

skipif mysql # not compatible
query I rowsort label-5747
SELECT DISTINCT + col0 * col2 / - col1 + + 45 * + 29 AS col1 FROM tab2 AS cor0
----
1129
1271
1299

query I rowsort
SELECT - ( cor0.col1 ) * + col1 + col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT 81 * cor0.col0 AS col0 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT - col2 - 0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col1 - 28 AS col1 FROM tab1 AS cor0
----
-15
-18
-2

query I rowsort
SELECT - 71 + col1 FROM tab2
----
-12
-40
-54

query I rowsort
SELECT DISTINCT ( cor0.col2 * cor0.col2 ) AS col0 FROM tab2, tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT 18 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT 15 + col1 * + col0 AS col2 FROM tab2
----
1358
232
4617

query I rowsort
SELECT ALL ( + 39 ) - + col1 FROM tab0
----
-47
-52
-58

query I rowsort
SELECT 18 + col2 + col0 * col2 FROM tab2
----
2072
234
3058

query I rowsort
SELECT DISTINCT + ( + col2 * - tab0.col1 ) + col0 * + col0 FROM tab0
----
-2262
1128
459

query I rowsort
SELECT + + col0 + col1 * - col1 FROM tab2 AS cor0
----
-210
-3403
-954

onlyif mysql # use DIV operator for integer division
query I rowsort label-5760
SELECT ALL + - cor0.col2 DIV 50 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5760
SELECT ALL + - cor0.col2 / 50 FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 81 * + cor0.col0 col0 FROM tab2 cor0
----
-567
-6318
-6399

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5762
SELECT + CAST( col2 * + col0 AS SIGNED ) FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-5762
SELECT + CAST ( col2 * + col0 AS INTEGER ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL 15 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT - - cor0.col0 + - col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT cor0.col0 + + col1 * + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT - + col2 * col1 + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5767
SELECT + + col1 DIV - col1 - - col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-5767
SELECT + + col1 / - col1 - - col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL + 72 * col0 * cor0.col0 AS col0 FROM tab0 AS cor0
----
41472
570312
88200

query I rowsort
SELECT DISTINCT col1 + - col0 + - col0 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-2002
-3333
-8097

query I rowsort
SELECT + + cor0.col2 * - cor0.col0 + - cor0.col0 + col2 * + col1 * col0 FROM tab1 AS cor0
----
32768
4047
92080

query I rowsort
SELECT cor0.col1 * - col0 * - col0 + + col2 + col1 FROM tab1 AS cor0
----
314
41027
83309

query I rowsort
SELECT ALL col1 * - cor0.col2 - + col2 AS col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT 29 * col2 + col0 AS col2 FROM tab0 AS cor0
----
2467
64
981

query I rowsort
SELECT DISTINCT - + col1 * cor0.col2 + - col2 * + col1 FROM tab1 AS cor0
----
-1140
-2496
-2808

query I rowsort
SELECT + col2 + + 22 FROM tab1 AS cor0
----
118
76
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 64 col0 FROM tab1 AS cor0
----
192
4096
5120

onlyif mysql # use DIV operator for integer division
query I rowsort label-5777
SELECT cor0.col0 DIV - 74 FROM tab2 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-5777
SELECT cor0.col0 / - 74 FROM tab2 cor0
----
-1
-1
0

query I rowsort
SELECT col1 + - ( - tab0.col0 ) FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-5779
SELECT - + cor0.col0 DIV col2 AS col0 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5779
SELECT - + cor0.col0 / col2 AS col0 FROM tab1 cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + col2 + + 63 FROM tab1 AS cor0
----
117
120
159

query I rowsort
SELECT DISTINCT + col0 + col0 AS col1 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT DISTINCT - col2 + 77 AS col2 FROM tab2 cor0
----
39
50
51

query I rowsort
SELECT ALL col0 + - 85 FROM tab2 AS cor0
----
-6
-7
-78

query I rowsort
SELECT DISTINCT + col1 + - 14 * - ( col1 ) AS col0 FROM tab1 AS cor0
----
150
195
390

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5785
SELECT + CAST( col0 AS SIGNED ) AS col0 FROM tab2 cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5785
SELECT + CAST ( col0 AS INTEGER ) AS col0 FROM tab2 cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5786
SELECT + - CAST( - col0 AS SIGNED ) * - col2 * col2 AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif mysql # not compatible
query I rowsort label-5786
SELECT + - CAST ( - col0 AS INTEGER ) * - col2 * col2 AS col1 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT + - ( 67 ) + col0 AS col0 FROM tab1 cor0
----
-3
-64
13

query I rowsort
SELECT ALL 55 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
4730
5005
5335

onlyif mysql # use DIV operator for integer division
query I rowsort label-5789
SELECT DISTINCT - col2 DIV + 91 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5789
SELECT DISTINCT - col2 / + 91 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - 15 + cor1.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b56f3e9275c057dd52029d987d39b458

query I rowsort
SELECT DISTINCT + - col0 * - col2 + + col0 AS col2 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + col2 * ( col0 ) * + col1 AS col0 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL - col2 * ( - col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col0 * 73 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-484
-5668
-5729

query I rowsort
SELECT col0 * + col2 + + ( - cor0.col1 ) FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + cor0.col1 * 46 + + col0 FROM tab1 AS cor0
----
1199
524
678

query I rowsort
SELECT col0 + col0 * - cor0.col0 FROM tab1 cor0
----
-4032
-6
-6320

query I rowsort
SELECT + + 93 AS col2 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT + - col1 * - ( col2 ) + - col0 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT - cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5801
SELECT DISTINCT col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5801
SELECT DISTINCT col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT - 46 + + col0 FROM tab1 AS cor0
----
-43
18
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5803
SELECT + + col1 * col1 DIV + 97 FROM tab0 AS cor0
----
76
85
97

skipif mysql # not compatible
query I rowsort label-5803
SELECT + + col1 * col1 / + 97 FROM tab0 AS cor0
----
76
85
97

query I rowsort
SELECT ALL - cor0.col0 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT ALL col1 * col2 + 2 AS col0 FROM tab1 AS cor0
----
1250
1406
572

query I rowsort
SELECT DISTINCT + 58 * + col1 FROM tab1 AS cor0
----
1508
580
754

query I rowsort
SELECT DISTINCT - 51 * cor0.col1 FROM tab2, tab2 AS cor0
----
-1581
-3009
-867

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab0 AS cor1
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

query I rowsort
SELECT + ( + col1 ) * 29 + - col2 FROM tab2 AS cor0
----
1685
455
872

onlyif mysql # use DIV operator for integer division
query I rowsort label-5810
SELECT 45 DIV + col1 FROM tab1
----
1
3
4

skipif mysql # not compatible
query I rowsort label-5810
SELECT 45 / + col1 FROM tab1
----
1
3
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 0 * - col0 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT ( - col1 ) * tab2.col2 + + tab2.col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT ALL + ( + col1 ) AS col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT 19 + + col0 * cor0.col2 AS col0 FROM tab0 AS cor0
----
54
7317
811

onlyif mysql # use DIV operator for integer division
query I rowsort label-5815
SELECT DISTINCT + col2 DIV + tab0.col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-5815
SELECT DISTINCT + col2 / + tab0.col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT col1 + 2 * col2 AS col0 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT - col2 + cor0.col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - - col0 + col2 * cor0.col1 + col1 * - 88 AS col1 FROM tab1 AS cor0
----
-246
-881
184

onlyif mysql # use DIV operator for integer division
query I rowsort label-5819
SELECT ( col0 ) DIV - col0 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5819
SELECT ( col0 ) / - col0 AS col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col0 * col0 - col1 * col1 AS col2 FROM tab2
----
-912
2603
5952

query I rowsort
SELECT + col0 * - 26 FROM tab1
----
-1664
-2080
-78

query I rowsort
SELECT - col0 - - col1 * col2 AS col1 FROM tab2
----
1456
567
830

query I rowsort
SELECT cor0.col0 + + col2 * col2 FROM tab0 AS cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-5824
SELECT col2 DIV 63 + + 87 AS col2 FROM tab0 AS cor0
----
87
87
88

skipif mysql # not compatible
query I rowsort label-5824
SELECT col2 / 63 + + 87 AS col2 FROM tab0 AS cor0
----
87
87
88

query I rowsort
SELECT ALL tab1.col2 + - 95 FROM tab1
----
-38
-41
1

query I rowsort
SELECT DISTINCT 39 * ( col2 ) AS col1 FROM tab1
----
2106
2223
3744

query I rowsort
SELECT DISTINCT - 97 * 47 FROM tab0
----
-4559

query I rowsort
SELECT ALL 46 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT ALL + 65 AS col0 FROM tab0
----
65
65
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 93 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT DISTINCT tab1.col0 * 38 FROM tab1
----
114
2432
3040

query I rowsort
SELECT col1 * 32 AS col1 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT + ( col0 + col0 ) FROM tab0
----
178
48
70

query I rowsort
SELECT - - 56 FROM tab2 AS cor0
----
56
56
56

query I rowsort
SELECT 35 * col0 + ( col1 ) AS col0 FROM tab0
----
1322
3206
926

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col0 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + - 0 * col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 52 + + col1 AS col1 FROM tab0
----
34
39
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5839
SELECT col0 DIV col0 + + col1 + col0 * - col0 col1 FROM tab2
----
-17
-6024
-6223

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5839
SELECT col0 / col0 + + col1 + col0 * - col0 col1 FROM tab2
----
-17
-6024
-6223

query I rowsort
SELECT DISTINCT + 17 * + col1 + col2 AS col2 FROM tab1
----
227
317
496

query I rowsort
SELECT 24 * col2 + col2 AS col1 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT 96 * - col1 + col0 AS col0 FROM tab2 AS cor0
----
-1553
-2969
-5586

query I rowsort
SELECT ALL col1 + cor0.col1 * - col0 * + col0 AS col1 FROM tab0 AS cor0
----
-118728
-49450
-720720

query I rowsort
SELECT col0 * col0 + - col1 AS col0 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT ALL - 86 * 43 + col1 FROM tab2 cor0
----
-3639
-3667
-3681

query I rowsort
SELECT DISTINCT + 89 + - col1 FROM tab1 AS cor0
----
63
76
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5847
SELECT DISTINCT - - 83 DIV col2 AS col0 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5847
SELECT DISTINCT - - 83 / col2 AS col0 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL - col1 + - col1 * + col0 * 10 - col2 * + col0 FROM tab1
----
-10058
-18093
-968

query I rowsort
SELECT DISTINCT 77 * + col2 + - 14 AS col0 FROM tab1 AS cor0
----
4144
4375
7378

query I rowsort
SELECT ALL 4 + - col1 * + 9 AS col0 FROM tab2 AS cor0
----
-149
-275
-527

query I rowsort
SELECT + + col1 * col2 + - 32 FROM tab1 AS cor0
----
1216
1372
538

query I rowsort
SELECT ALL tab1.col0 - col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - col1 + col0 - - col1 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT + tab2.col1 + + col2 * col0 AS col1 FROM tab2
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-5855
SELECT + col1 DIV 82 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5855
SELECT + col1 / 82 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - 52 - + col1 AS col1 FROM tab0
----
-138
-143
-149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 81 - col0 col2 FROM tab1
----
1
17
78

query I rowsort
SELECT ALL 98 FROM tab0, tab1 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT DISTINCT col2 * + col1 * 75 FROM tab0 AS cor0
----
212850
559650
7275

query I rowsort
SELECT DISTINCT col1 + + cor0.col0 * 8 FROM tab0 AS cor0
----
278
377
803

query I rowsort
SELECT ALL + col0 * - 90 FROM tab0 AS cor0
----
-2160
-3150
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5862
SELECT ALL + col2 + CAST( NULL AS SIGNED ) * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5862
SELECT ALL + col2 + CAST ( NULL AS INTEGER ) * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * - 0 + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + - col1 * - col2 + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5865
SELECT DISTINCT col1 - + CAST( col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-5865
SELECT DISTINCT col1 - + CAST ( col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - cor0.col2 + - 18 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-1684
-465
-631

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5867
SELECT - - col0 + - CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5867
SELECT - - col0 + - CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * ( + col0 + + col0 ) FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT ALL + 57 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT + col1 * tab1.col2 * col0 + + 33 FROM tab1
----
36513
4245
99873

query I rowsort
SELECT DISTINCT + col0 * - cor0.col2 * - 36 + col1 AS col0 FROM tab0 AS cor0
----
1357
262819
28598

onlyif mysql # use DIV operator for integer division
query I rowsort label-5872
SELECT - col0 * col0 DIV ( col1 ) + col1 FROM tab1
----
-399
-479
26

skipif mysql # not compatible
query I rowsort label-5872
SELECT - col0 * col0 / ( col1 ) + col1 FROM tab1
----
-399
-479
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 65 col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5874
SELECT + cor0.col1 * - CAST( + col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-5874
SELECT + cor0.col1 * - CAST ( + col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - ( cor1.col0 ) + - 82 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to da663fea9aa49ff9b95bbce70e26d8d8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 - ( + col2 ) col0 FROM tab1
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 49 col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT 46 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT DISTINCT 22 AS col2 FROM tab0, tab2 AS cor0
----
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5880
SELECT + col2 * col1 * col1 + + col0 / - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5880
SELECT + col2 * col1 * col1 + + col0 / - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 31 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5882
SELECT DISTINCT + CAST( NULL AS SIGNED ) - 29 FROM tab1, tab0, tab0 AS cor0, tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5882
SELECT DISTINCT + CAST ( NULL AS INTEGER ) - 29 FROM tab1, tab0, tab0 AS cor0, tab2
----
NULL

query I rowsort
SELECT ALL - col1 + col2 * + cor0.col2 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT + - col1 * - col2 + - col0 AS col2 FROM tab0 AS cor0
----
2814
62
7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5885
SELECT ALL CAST( NULL AS SIGNED ) * col2 + col0 - col1 * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5885
SELECT ALL CAST ( NULL AS INTEGER ) * col2 + col0 - col1 * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5886
SELECT DISTINCT - - 92 + col0 DIV col0 + - col2 FROM tab2 AS cor0
----
55
66
67

skipif mysql # not compatible
query I rowsort label-5886
SELECT DISTINCT - - 92 + col0 / col0 + - col2 FROM tab2 AS cor0
----
55
66
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5887
SELECT CAST( + 11 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
11
11
11

skipif mysql # not compatible
query I rowsort label-5887
SELECT CAST ( + 11 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
11
11
11

query I rowsort
SELECT + ( + 66 ) + col1 AS col1 FROM tab1 AS cor0
----
76
79
92

query I rowsort
SELECT DISTINCT + + 0 * cor0.col2 * + col0 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - - col2 * + 66 - + col0 FROM tab0 AS cor0
----
2154
31
5323

query I rowsort
SELECT ALL - col1 * col2 * col2 + col0 AS col1 FROM tab0
----
-611795
-62
-93630

query I rowsort
SELECT + 41 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

onlyif mysql # use DIV operator for integer division
query I rowsort label-5893
SELECT + col0 DIV + cor0.col0 AS col2 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5893
SELECT + col0 / + cor0.col0 AS col2 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL - 71 * col2 FROM tab1 AS cor0
----
-3834
-4047
-6816

query I rowsort
SELECT DISTINCT 73 * - col0 AS col2 FROM tab2 AS cor0
----
-511
-5694
-5767

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5896
SELECT 23 * cor0.col2 * CAST( ( col1 ) * CAST( NULL AS SIGNED ) AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5896
SELECT 23 * cor0.col2 * CAST ( ( col1 ) * CAST ( NULL AS INTEGER ) AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5897
SELECT DISTINCT - cor0.col0 DIV col2 col1 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5897
SELECT DISTINCT - cor0.col0 / col2 col1 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT - 77 + col0 FROM tab1 cor0
----
-13
-74
3

query I rowsort
SELECT DISTINCT - - 62 AS col1 FROM tab0 AS cor0
----
62

query I rowsort
SELECT DISTINCT - col0 * col1 * + 1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col0 * col1 - - 45 AS col0 FROM tab2 AS cor0
----
1388
262
4647

query I rowsort
SELECT ALL 61 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT DISTINCT col1 * - col1 - col2 * - cor0.col1 FROM tab0 AS cor0
----
-4558
-819
-9312

query I rowsort
SELECT DISTINCT - + col1 + col2 AS col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT - cor0.col0 + - 66 FROM tab2 AS cor0
----
-144
-145
-73

query I rowsort
SELECT + - col2 + + col0 * - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT + - cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT DISTINCT tab2.col2 AS col0 FROM tab2, tab2 cor0, tab0 AS cor1
----
26
27
38

query I rowsort
SELECT ALL - ( col2 ) * 86 AS col0 FROM tab2 AS cor0
----
-2236
-2322
-3268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5910
SELECT DISTINCT - col1 * col2 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-244068
-679042
-9409

skipif mysql # not compatible
query I rowsort label-5910
SELECT DISTINCT - col1 * col2 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-244068
-679042
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-5911
SELECT - col1 DIV 9 AS col0 FROM tab2
----
-1
-3
-6

skipif mysql # not compatible
query I rowsort label-5911
SELECT - col1 / 9 AS col0 FROM tab2
----
-1
-3
-6

query I rowsort
SELECT ALL - ( + ( col0 ) ) FROM tab1
----
-3
-64
-80

query I rowsort
SELECT 39 * - col2 + - 68 * - col1 AS col1 FROM tab1 AS cor0
----
-1543
-2860
-338

query I rowsort
SELECT - + col1 + col1 * - col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT + - col0 * 0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * ( + ( + cor0.col1 ) ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + col2 + 15 FROM tab1 AS cor0
----
111
69
72

query I rowsort
SELECT DISTINCT + - col1 + + 32 * + 52 FROM tab0 AS cor0
----
1567
1573
1578

query I rowsort
SELECT - - 37 * - col0 AS col1 FROM tab1 AS cor0
----
-111
-2368
-2960

query I rowsort
SELECT + 59 + col0 + col2 FROM tab0 cor0
----
116
230
95

query I rowsort
SELECT ALL - 34 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

query I rowsort
SELECT - + col2 + - 29 * col1 FROM tab1 AS cor0
----
-347
-473
-808

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5923
SELECT DISTINCT + - CAST( - col1 AS SIGNED ) + + cor0.col0 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5923
SELECT DISTINCT + - CAST ( - col1 AS INTEGER ) + + cor0.col0 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 77 col2 FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT ALL + - col2 * 4 FROM tab1 AS cor0
----
-216
-228
-384

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5926
SELECT - CAST( col2 AS SIGNED ) + + col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-5926
SELECT - CAST ( col2 AS INTEGER ) + + col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - col2 * 0 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT - + 61 + col0 AS col0 FROM tab0 AS cor0
----
-26
-37
28

query I rowsort
SELECT col2 * 37 AS col1 FROM tab0 cor0
----
1221
3034
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-5930
SELECT - + 76 DIV - col1 AS col1 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5930
SELECT - + 76 / - col1 AS col1 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT col2 * + 77 * + col1 AS col2 FROM tab2 AS cor0
----
118118
49742
64449

query I rowsort
SELECT - + 80 * col1 FROM tab1 cor0
----
-1040
-2080
-800

query I rowsort
SELECT DISTINCT - 79 + col2 AS col0 FROM tab1 AS cor0
----
-22
-25
17

query I rowsort
SELECT DISTINCT - + 1 * - col0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + + col2 * col0 + + col2 + 5 AS col2 FROM tab0 AS cor0
----
41
7385
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5936
SELECT - col0 + col1 * col1 DIV col0 + col1 * + 45 AS col0 FROM tab0 AS cor0
----
4099
4154
4598

skipif mysql # not compatible
query I rowsort label-5936
SELECT - col0 + col1 * col1 / col0 + col1 * + 45 AS col0 FROM tab0 AS cor0
----
4099
4154
4598

query I rowsort
SELECT tab2.col2 * col0 * col2 - ( col0 ) AS col2 FROM tab2
----
113997
5096
52650

query I rowsort
SELECT ( 69 * tab2.col0 ) FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to a4827b27febd044650a790f148b96d66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + 34 col0 FROM tab0 AS cor0
----
120
125
131

query I rowsort
SELECT - - col2 + + 70 FROM tab1 AS cor0
----
124
127
166

query I rowsort
SELECT + + cor0.col1 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - 99 + + tab1.col0 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to b45a085ed90fbc8be8780a6a43a58fa1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5943
SELECT DISTINCT col2 DIV + col1 + 2 + + col1 FROM tab1
----
17
22
30

skipif mysql # not compatible
query I rowsort label-5943
SELECT DISTINCT col2 / + col1 + 2 + + col1 FROM tab1
----
17
22
30

query I rowsort
SELECT DISTINCT col2 * - tab2.col0 + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + col0 + - 32 + col0 * + col1 FROM tab0
----
2056
3398
8156

query I rowsort
SELECT col0 - - ( col2 * - col1 ) AS col1 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT - tab1.col2 * 15 FROM tab1, tab2 cor0
----
9 values hashing to b70528ebff15fd010b47c337f13ef91b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 55 + - col0 * 10 col1 FROM tab0 AS cor0
----
-185
-295
-835

onlyif mysql # use DIV operator for integer division
query I rowsort label-5949
SELECT ALL 15 DIV + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5949
SELECT ALL 15 / + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5950
SELECT col0 DIV + col1 + 79 AS col0 FROM tab1
----
79
85
85

skipif mysql # not compatible
query I rowsort label-5950
SELECT col0 / + col1 + 79 AS col0 FROM tab1
----
79
85
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5951
SELECT DISTINCT + cor0.col0 + - 40 DIV + 97 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5951
SELECT DISTINCT + cor0.col0 + - 40 / + 97 AS col2 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5952
SELECT col1 + CAST( ( col0 ) AS SIGNED ) * 30 FROM tab1 AS cor0
----
116
1930
2413

skipif mysql # not compatible
query I rowsort label-5952
SELECT col1 + CAST ( ( col0 ) AS INTEGER ) * 30 FROM tab1 AS cor0
----
116
1930
2413

query I rowsort
SELECT DISTINCT - cor0.col2 * + 30 + 83 FROM tab1 AS cor0
----
-1537
-1627
-2797

query I rowsort
SELECT DISTINCT col0 + 49 FROM tab2
----
127
128
56

query I rowsort
SELECT DISTINCT col2 + + col1 * - col2 * col1 AS col0 FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT - col1 + - ( - cor0.col1 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL col2 * - ( - ( col2 ) ) + + ( 40 ) * - col0 AS col0 FROM tab1 AS cor0
----
2796
6016
689

query I rowsort
SELECT DISTINCT + + cor0.col0 * 33 + col2 AS col1 FROM tab0 AS cor0
----
1156
3019
825

query I rowsort
SELECT + col0 + - ( 37 ) FROM tab1 AS cor0
----
-34
27
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 col0 FROM tab1
----
51
51
51

query I rowsort
SELECT - + ( - col1 ) + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT 68 + col0 AS col0 FROM tab2
----
146
147
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-5964
SELECT DISTINCT CAST( col2 AS SIGNED ) + + col2 DIV tab1.col1 + - col2 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5964
SELECT DISTINCT CAST ( col2 AS INTEGER ) + + col2 / tab1.col1 + - col2 FROM tab1
----
2
5
7

query I rowsort
SELECT DISTINCT - col1 + 98 + col2 FROM tab2
----
119
65
94

query I rowsort
SELECT ALL col2 * ( col1 ) + col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-5967
SELECT ALL - col0 DIV col0 col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5967
SELECT ALL - col0 / col0 col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ( - col1 ) * - col0 + - col1 AS col2 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT col2 + - ( - col1 + 47 ) * col1 AS col1 FROM tab0 cor0
----
3387
4086
4851

onlyif mysql # use DIV operator for integer division
query I rowsort label-5970
SELECT 31 * col0 DIV col0 FROM tab0 AS cor0
----
31
31
31

skipif mysql # not compatible
query I rowsort label-5970
SELECT 31 * col0 / col0 FROM tab0 AS cor0
----
31
31
31

query I rowsort
SELECT DISTINCT 57 * - col1 AS col0 FROM tab2 AS cor0
----
-1767
-3363
-969

query I rowsort
SELECT DISTINCT - col1 - - cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - - 16 AS col0 FROM tab0 AS cor0
----
16

query I rowsort
SELECT ALL + col2 * - col0 + - col0 FROM tab0 AS cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + ( col0 ) ) + col0 col1 FROM tab1
----
128
160
6

query I rowsort
SELECT 82 - + col0 AS col2 FROM tab1
----
18
2
79

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - col0 AS REAL ) AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT col2 * - col1 + - col1 + + col1 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL - 58 * col2 * col0 AS col0 FROM tab1 AS cor0
----
-211584
-445440
-9396

query I rowsort
SELECT DISTINCT 39 * - col1 + col2 AS col0 FROM tab1
----
-333
-411
-960

query I rowsort
SELECT ( - 91 ) * + col0 + - 99 * - col0 FROM tab2
----
56
624
632

query I rowsort
SELECT ALL - col1 * + col1 + + tab0.col1 + - col0 FROM tab0
----
-7334
-8279
-9347

query I rowsort
SELECT cor1.col1 * cor1.col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 00f153c5d80e692faff5018d8701b92d

query I rowsort
SELECT - 76 * col2 AS col1 FROM tab1
----
-4104
-4332
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5985
SELECT ALL - 8 + col1 DIV + 21 + - col0 FROM tab0 AS cor0
----
-28
-39
-93

skipif mysql # not compatible
query I rowsort label-5985
SELECT ALL - 8 + col1 / + 21 + - col0 FROM tab0 AS cor0
----
-28
-39
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 92 * col1 + col1 col1 FROM tab2 cor0
----
1581
2883
5487

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + cor0.col2 * - col2 col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT + - 16 * col1 + col2 AS col1 FROM tab2 AS cor0
----
-234
-469
-918

query I rowsort
SELECT + col1 * - col0 + + col0 + + col1 AS col2 FROM tab1 AS cor0
----
-49
-566
-947

query I rowsort
SELECT DISTINCT tab1.col2 AS col1 FROM tab1, tab0, tab0 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * tab0.col2 col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + + col2 * col1 + + col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + col2 * col0 - + 53 FROM tab2
----
136
1975
2949

onlyif mysql # use DIV operator for integer division
query I rowsort label-5994
SELECT DISTINCT ( - col2 ) DIV + cor0.col2 col1 FROM tab1 cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5994
SELECT DISTINCT ( - col2 ) / + cor0.col2 col1 FROM tab1 cor0
----
-1

query I rowsort
SELECT ALL - 18 + col1 AS col2 FROM tab2 AS cor0
----
-1
13
41

query I rowsort
SELECT - + col2 * + cor0.col0 + - col1 AS col0 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL - col2 + 42 * - 56 FROM tab1
----
-2406
-2409
-2448

query I rowsort
SELECT col0 * ( + ( col2 ) ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT - col1 - ( col1 * + tab1.col0 ) AS col1 FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT ALL + col2 * 56 AS col2 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT DISTINCT cor0.col2 * + 1 + col2 * + col2 FROM tab1 cor0
----
2970
3306
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6002
SELECT DISTINCT + CAST( NULL AS SIGNED ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6002
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + cor0.col0 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + 6 * cor0.col2 + col1 FROM tab2 cor0
----
193
215
245

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 * ( cor0.col1 ) + - CAST ( 46 AS REAL ) AS col2 FROM tab2 AS cor0
----
1488
600
791

query I rowsort
SELECT ( 61 ) + - cor0.col0 FROM tab1 AS cor0
----
-19
-3
58

query I rowsort
SELECT DISTINCT + col0 + - 8 * col2 AS col0 FROM tab2 AS cor0
----
-130
-209
-225

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 44 - - col0 * col2 col0 FROM tab2 AS cor0
----
2072
233
3046

query I rowsort
SELECT DISTINCT col1 * 63 + + col1 + col2 FROM tab1 AS cor0
----
1718
697
928

query I rowsort
SELECT - col1 + 34 AS col2 FROM tab2 AS cor0
----
-25
17
3

query I rowsort
SELECT + col0 * 62 + + col1 AS col2 FROM tab0 AS cor0
----
1574
2267
5609

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6011
SELECT - col2 * CAST( 52 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-2808
-2964
-4992

skipif mysql # not compatible
query I rowsort label-6011
SELECT - col2 * CAST ( 52 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT ALL 84 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

query I rowsort
SELECT + col1 * col1 + + cor0.col0 FROM tab0 cor0
----
7420
8370
9444

query I rowsort
SELECT - 23 * ( - col0 ) + col1 FROM tab1
----
1482
1853
95

query I rowsort
SELECT ALL + cor0.col2 + - cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * ( col2 ) AS col1 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL - 39 FROM tab1, tab2 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

onlyif mysql # use DIV operator for integer division
query I rowsort label-6018
SELECT + tab2.col0 DIV - cor0.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 7bd2eee154b38460e7e524db3ab0a27b

skipif mysql # not compatible
query I rowsort label-6018
SELECT + tab2.col0 / - cor0.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 7bd2eee154b38460e7e524db3ab0a27b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col0 col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + 55 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT ALL + - 69 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT - - col0 + col2 * - col0 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT - col2 * + col0 * - 60 AS col0 FROM tab2 AS cor0
----
11340
121680
180120

query I rowsort
SELECT - col1 * - col1 * + 3 AS col1 FROM tab1 cor0
----
2028
300
507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * col1 col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - col2 + cor0.col1 + + col0 AS col1 FROM tab0 AS cor0
----
131
77
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6027
SELECT + + col2 * col2 + - col1 DIV 8 AS col2 FROM tab2 AS cor0
----
1442
669
726

skipif mysql # not compatible
query I rowsort label-6027
SELECT + + col2 * col2 + - col1 / 8 AS col2 FROM tab2 AS cor0
----
1442
669
726

query I rowsort
SELECT DISTINCT 42 AS col1 FROM tab2, tab1 AS cor0
----
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6029
SELECT DISTINCT + - cor0.col0 * CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6029
SELECT DISTINCT + - cor0.col0 * CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col1 * col0 + col1 * - ( - cor0.col0 ) FROM tab1 AS cor0
----
1280
156
2080

query I rowsort
SELECT 9 * + col2 FROM tab1
----
486
513
864

query I rowsort
SELECT ALL col2 + col0 * col1 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT - - 57 * col1 + - col0 * col2 AS col2 FROM tab2 AS cor0
----
-2033
1335
1578

query I rowsort
SELECT + - 73 + col0 * col1 AS col1 FROM tab1 AS cor0
----
5
567
967

query I rowsort
SELECT col2 + + 65 AS col0 FROM tab1 AS cor0
----
119
122
161

query I rowsort
SELECT - - col1 * 60 * - col0 - - 80 FROM tab0 AS cor0
----
-123760
-203620
-485860

query I rowsort
SELECT DISTINCT + - 47 + col1 AS col2 FROM tab2 AS cor0
----
-16
-30
12

query I rowsort
SELECT - col1 * col1 + + cor0.col1 FROM tab1 AS cor0
----
-156
-650
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 29 col2 FROM tab0 AS cor0
----
29

query I rowsort
SELECT - col0 * col1 + + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - + 37 * col2 AS col2 FROM tab2 AS cor0
----
-1406
-962
-999

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 75 + col1 col2 FROM tab0 AS cor0
----
11
16
22

query I rowsort
SELECT ALL 7 FROM tab0, tab0 cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6044
SELECT ALL CAST( 15 * - col2 AS SIGNED ) AS col0 FROM tab1
----
-1440
-810
-855

skipif mysql # not compatible
query I rowsort label-6044
SELECT ALL CAST ( 15 * - col2 AS INTEGER ) AS col0 FROM tab1
----
-1440
-810
-855

query I rowsort
SELECT DISTINCT 49 FROM tab1, tab2 AS cor0
----
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col1 ) - col1 col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col0 * ( + col2 ) - col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - 74 + 24 * col0 FROM tab2 cor0
----
1798
1822
94

query I rowsort
SELECT ALL 1 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6050
SELECT DISTINCT col2 + - CAST( NULL AS SIGNED ) * tab1.col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6050
SELECT DISTINCT col2 + - CAST ( NULL AS INTEGER ) * tab1.col2 FROM tab1
----
NULL

query I rowsort
SELECT ALL + col0 * col1 * 10 + col0 AS col2 FROM tab1
----
10480
6464
783

query I rowsort
SELECT ALL - ( - 88 ) AS col1 FROM tab1
----
88
88
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6053
SELECT CAST( - 58 AS SIGNED ) + col0 * + 84 FROM tab2
----
530
6494
6578

skipif mysql # not compatible
query I rowsort label-6053
SELECT CAST ( - 58 AS INTEGER ) + col0 * + 84 FROM tab2
----
530
6494
6578

query I rowsort
SELECT + - 29 * tab0.col2 AS col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 735b3bcf90d4511a1d30842190af512e

query I rowsort
SELECT ALL + col2 * - col0 + + col2 * + col2 AS col0 FROM tab1 AS cor0
----
-399
1536
2754

query I rowsort
SELECT DISTINCT + col2 * 31 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT 49 + 10 * + col1 AS col2 FROM tab1 AS cor0
----
149
179
309

query I rowsort
SELECT DISTINCT - 25 * cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
-1347
-1361
-2320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6059
SELECT ALL col1 DIV + ( cor0.col1 ) + col1 * 91 * + col2 FROM tab1 AS cor0
----
113569
127765
51871

skipif mysql # not compatible
query I rowsort label-6059
SELECT ALL col1 / + ( cor0.col1 ) + col1 * 91 * + col2 FROM tab1 AS cor0
----
113569
127765
51871

query I rowsort
SELECT 64 * tab2.col2 FROM tab2
----
1664
1728
2432

query I rowsort
SELECT ALL col1 + col1 * + tab0.col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT + 96 + col2 + 19 AS col2 FROM tab1
----
169
172
211

query I rowsort
SELECT DISTINCT col2 * - col0 * ( + col1 ) + col2 AS col2 FROM tab1
----
-36423
-4158
-99744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col1 FROM tab2, tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT + + 32 FROM tab2, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT ALL 4 * + col1 FROM tab1 AS cor0
----
104
40
52

query I rowsort
SELECT + 58 * col1 + col1 AS col2 FROM tab0
----
5074
5369
5723

query I rowsort
SELECT - 52 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to e8a5cb10c0973a78554f344d4f6e7e74

query I rowsort
SELECT DISTINCT - 66 AS col2 FROM tab2, tab1, tab2 AS cor0
----
-66

query I rowsort
SELECT DISTINCT + col2 * + 65 FROM tab0 AS cor0
----
2145
5330
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-6071
SELECT ALL + + col2 DIV + cor0.col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6071
SELECT ALL + + col2 / + cor0.col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col0 + - 10 * + col0 AS col0 FROM tab0 AS cor0
----
-216
-315
-801

query I rowsort
SELECT - - col2 + 52 AS col1 FROM tab2 AS cor0
----
78
79
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6074
SELECT DISTINCT col0 * col1 * - 14 + + col1 - col2 DIV 60 FROM tab1 AS cor0
----
-1066
-14548
-8950

skipif mysql # not compatible
query I rowsort label-6074
SELECT DISTINCT col0 * col1 * - 14 + + col1 - col2 / 60 FROM tab1 AS cor0
----
-1066
-14548
-8950

query I rowsort
SELECT col0 + ( col1 ) * + cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT col1 * - col0 + col2 * col1 AS col0 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT + col2 + - 52 FROM tab1
----
2
44
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6078
SELECT ALL col2 * CAST( + col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-6078
SELECT ALL col2 * CAST ( + col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-6079
SELECT - col1 * - 42 - col0 DIV col1 FROM tab0 AS cor0
----
3612
3822
4074

skipif mysql # not compatible
query I rowsort label-6079
SELECT - col1 * - 42 - col0 / col1 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT DISTINCT + col1 + ( col0 * + col0 ) FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT + col0 + col0 * - col2 AS col1 FROM tab1 cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-6082
SELECT ALL - col2 - col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-6082
SELECT ALL - col2 - col0 / - col1 AS col0 FROM tab1 AS cor0
----
-51
-54
-90

query I rowsort
SELECT DISTINCT + + col1 * 14 + + col1 FROM tab0 cor0
----
1290
1365
1455

onlyif mysql # use DIV operator for integer division
query I rowsort label-6084
SELECT ALL - + col0 * ( + col2 ) DIV + col0 + + 53 - - col0 FROM tab0 AS cor0
----
44
60
87

skipif mysql # not compatible
query I rowsort label-6084
SELECT ALL - + col0 * ( + col2 ) / + col0 + + 53 - - col0 FROM tab0 AS cor0
----
44
60
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-6085
SELECT ALL col1 DIV - 47 FROM tab0 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-6085
SELECT ALL col1 / - 47 FROM tab0 AS cor0
----
-1
-1
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6086
SELECT - col0 DIV - col0 + - col1 FROM tab2
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-6086
SELECT - col0 / - col0 + - col1 FROM tab2
----
-16
-30
-58

query I rowsort
SELECT 68 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT + col0 * cor0.col0 * col0 + col1 AS col0 FROM tab0 AS cor0
----
13910
42972
705060

query I rowsort
SELECT 3 + + col2 AS col2 FROM tab0 AS cor0
----
36
4
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6090
SELECT CAST( col2 AS SIGNED ) + col1 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-6090
SELECT CAST ( col2 AS INTEGER ) + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + cor0.col1 * + col0 + cor0.col2 FROM tab2 AS cor0
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 + + 47 col1 FROM tab0 AS cor0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + col0 col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 + ( + col0 ) * tab2.col2 AS col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL col0 * - tab2.col2 + col0 * - col2 AS col2 FROM tab2
----
-378
-4056
-6004

query I rowsort
SELECT + col0 * + col0 + col1 * + col0 FROM tab0 AS cor0
----
16020
2640
4620

query I rowsort
SELECT col1 + + 58 FROM tab0
----
144
149
155

onlyif mysql # use DIV operator for integer division
query I rowsort label-6098
SELECT DISTINCT + + cor0.col2 DIV cor0.col0 + ( col0 ) + col2 AS col2 FROM tab2 AS cor0
----
104
117
37

skipif mysql # not compatible
query I rowsort label-6098
SELECT DISTINCT + + cor0.col2 / cor0.col0 + ( col0 ) + col2 AS col2 FROM tab2 AS cor0
----
104
117
37

query I rowsort
SELECT ALL + cor0.col0 * + col2 - cor0.col0 * col1 AS col0 FROM tab0 cor0
----
-1272
-3360
-801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6100
SELECT col1 * - col0 / CAST( NULL AS SIGNED ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6100
SELECT col1 * - col0 / CAST ( NULL AS INTEGER ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col2 * cor0.col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT cor0.col0 * - col0 + ( + col2 ) FROM tab2 cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL + 42 * col2 FROM tab2 AS cor0
----
1092
1134
1596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 * col1 + col1 col0 FROM tab2 AS cor0
----
-272
-3422
-930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6105
SELECT DISTINCT - - 7 + - col1 * - CAST( NULL AS SIGNED ) * col1 + col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6105
SELECT DISTINCT - - 7 + - col1 * - CAST ( NULL AS INTEGER ) * col1 + col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - 1 * col1 + - 94 AS col0 FROM tab2 AS cor0
----
-35
-63
-77

query I rowsort
SELECT ( col1 ) * col0 AS col2 FROM tab1 cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6108
SELECT 94 DIV + col0 AS col2 FROM tab1
----
1
1
31

skipif mysql # not compatible
query I rowsort label-6108
SELECT 94 / + col0 AS col2 FROM tab1
----
1
1
31

query I rowsort
SELECT + 21 + tab2.col1 + - 90 AS col0 FROM tab2
----
-10
-38
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6110
SELECT DISTINCT 33 * col1 * CAST( NULL AS SIGNED ) - + tab1.col2 * col0 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6110
SELECT DISTINCT 33 * col1 * CAST ( NULL AS INTEGER ) - + tab1.col2 * col0 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT col2 + + col1 - col1 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - - col2 * - col0 - 75 FROM tab1 AS cor0
----
-237
-3723
-7755

query I rowsort
SELECT ALL col1 * + cor0.col2 + cor0.col1 + 46 FROM tab1 AS cor0
----
1307
1476
626

query I rowsort
SELECT ALL + 49 + col2 FROM tab1
----
103
106
145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col2 ) - ( - col2 ) col1 FROM tab1
----
108
114
192

query I rowsort
SELECT - col0 + col0 * 72 AS col0 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT + 21 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col0 * - 94 ) col0 FROM tab1
----
282
6016
7520

query I rowsort
SELECT ALL 93 + cor1.col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to b377f4a4e3c80bc02a41bdfb7e300e6e

query I rowsort
SELECT DISTINCT + 91 * - col0 FROM tab2
----
-637
-7098
-7189

onlyif mysql # use DIV operator for integer division
query I rowsort label-6121
SELECT - col0 DIV + 72 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6121
SELECT - col0 / + 72 AS col0 FROM tab0 AS cor0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6122
SELECT ALL + - col1 * CAST( - col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-6122
SELECT ALL + - col1 * CAST ( - col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col0 * + 50 col0 FROM tab1 AS cor0
----
-124
-3190
-3987

query I rowsort
SELECT DISTINCT + 7 * + col2 FROM tab1
----
378
399
672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 36 col1 FROM tab0 AS cor0
----
-1
-12
53

query I rowsort
SELECT - ( - col0 ) + - col2 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + - 80 + 33 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1334
-938
-971

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + 33 * + col1 col1 FROM tab0 AS cor0
----
2871
3085
3202

query I rowsort
SELECT + 45 AS col0 FROM tab2 cor0
----
45
45
45

query I rowsort
SELECT 74 * - col2 + + col1 FROM tab2 AS cor0
----
-1865
-1967
-2795

query I rowsort
SELECT + 94 * col0 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT 18 + col2 AS col0 FROM tab2 AS cor0
----
44
45
56

query I rowsort
SELECT DISTINCT ( 51 ) FROM tab1
----
51

query I rowsort
SELECT DISTINCT + + cor0.col1 + + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT - 90 + col0 + + col0 * + col1 FROM tab0 AS cor0
----
1998
3340
8098

query I rowsort
SELECT ALL - + cor0.col2 + col1 * - cor0.col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + ( + 65 ) AS col2 FROM tab0
----
65

query I rowsort
SELECT ( - 16 ) * col0 AS col2 FROM tab2
----
-112
-1248
-1264

query I rowsort
SELECT ALL + 47 * - col1 + - col0 * col2 * col1 + 55 FROM tab1 AS cor0
----
-100396
-36895
-5379

query I rowsort
SELECT ALL - cor0.col0 * col2 + - ( 33 ) AS col1 FROM tab0 AS cor0
----
-68
-7331
-825

query I rowsort
SELECT + 5 + + col1 FROM tab2 AS cor0
----
22
36
64

query I rowsort
SELECT DISTINCT col2 * - col0 + - ( + 67 ) * col1 AS col1 FROM tab2 AS cor0
----
-2266
-4141
-5981

query I rowsort
SELECT - col1 * + col2 + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6144
SELECT ALL + col0 + - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6144
SELECT ALL + col0 + - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 31 + - ( col2 ) AS col2 FROM tab1
----
-23
-26
-65

query I rowsort
SELECT ALL - col2 + - col1 * - 65 AS col0 FROM tab0
----
5557
5833
6304

query I rowsort
SELECT tab1.col2 + ( + 21 ) AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to c301dd6dc3b92c26477525b2c4d49c33

query I rowsort
SELECT DISTINCT + col2 * + col0 + col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + 96 + col2 * col0 FROM tab1 AS cor0
----
258
3744
7776

query I rowsort
SELECT - + 92 * - col0 + - 91 * - col2 AS col2 FROM tab2 AS cor0
----
10726
3101
9542

onlyif mysql # use DIV operator for integer division
query I rowsort label-6151
SELECT + - 14 DIV + cor0.col2 + + 19 FROM tab0 AS cor0
----
19
19
5

skipif mysql # not compatible
query I rowsort label-6151
SELECT + - 14 / + cor0.col2 + + 19 FROM tab0 AS cor0
----
19
19
5

query I rowsort
SELECT ALL - 27 AS col2 FROM tab2 AS cor0
----
-27
-27
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-6153
SELECT DISTINCT 20 + + cor0.col2 DIV + 79 col2 FROM tab2 AS cor0
----
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6153
SELECT DISTINCT 20 + + cor0.col2 / + 79 col2 FROM tab2 AS cor0
----
20

query I rowsort
SELECT + - 41 + col2 FROM tab0 AS cor0
----
-40
-8
41

query I rowsort
SELECT ALL - 98 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT DISTINCT - + 54 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-54

query I rowsort
SELECT + col1 * - 19 FROM tab1 AS cor0
----
-190
-247
-494

query I rowsort
SELECT ALL 35 * 87 + col1 FROM tab0
----
3131
3136
3142

query I rowsort
SELECT 21 * ( col2 ) AS col2 FROM tab0
----
1722
21
693

query I rowsort
SELECT ALL col0 * col1 + cor0.col2 AS col1 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + + col1 + - ( col1 ) + + 68 AS col2 FROM tab2 AS cor0
----
68

query I rowsort
SELECT + cor0.col1 * - cor0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 9b23e5e74ef3405a4dbf05cceb18c8a8

query I rowsort
SELECT DISTINCT - - col2 * ( cor0.col2 ) * - col1 - ( - col2 ) * col2 AS col2 FROM tab1 AS cor0
----
-110592
-29241
-72900

query I rowsort
SELECT 21 * - 82 - cor0.col1 FROM tab0 AS cor0
----
-1808
-1813
-1819

query I rowsort
SELECT cor0.col1 AS col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT 4 * cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
16384
25600
36

query I rowsort
SELECT ALL - + ( col1 ) + + cor0.col1 + - col1 * 14 AS col2 FROM tab1 AS cor0
----
-140
-182
-364

query I rowsort
SELECT ALL - + 48 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-74
-75
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 * col2 col2 FROM tab0 cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-6170
SELECT DISTINCT - col1 DIV - cor0.col0 + cor0.col2 DIV col2 FROM tab0 AS cor0
----
2
3
4

skipif mysql # not compatible
query I rowsort label-6170
SELECT DISTINCT - col1 / - cor0.col0 + cor0.col2 / col2 FROM tab0 AS cor0
----
2
3
4

query I rowsort
SELECT + - col0 * col0 + - col0 FROM tab2 cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6172
SELECT ALL - col1 * + 67 + col0 DIV col0 AS col1 FROM tab2 AS cor0
----
-1138
-2076
-3952

skipif mysql # not compatible
query I rowsort label-6172
SELECT ALL - col1 * + 67 + col0 / col0 AS col1 FROM tab2 AS cor0
----
-1138
-2076
-3952

query I rowsort
SELECT cor0.col2 + - 30 * 65 FROM tab0 AS cor0
----
-1868
-1917
-1949

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6174
SELECT ALL + col2 * CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-6174
SELECT ALL + col2 * CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6175
SELECT DISTINCT + + col0 + col1 DIV col2 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-6175
SELECT DISTINCT + + col0 + col1 / col2 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT + col1 * col1 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT + col0 + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - - col0 + - ( + 26 ) * col2 AS col0 FROM tab1 AS cor0
----
-1401
-1418
-2416

query I rowsort
SELECT - col0 * - col1 + - col2 * cor0.col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col0 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-744
1054
1121

onlyif mysql # use DIV operator for integer division
query I rowsort label-6181
SELECT + col0 DIV - ( - col0 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6181
SELECT + col0 / - ( - col0 ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + col1 * ( - col2 ) + + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + cor0.col0 * ( - col1 ) AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 1 + - cor0.col2 col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT col1 * + ( - col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - ( col1 ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT ALL 12 + col2 AS col0 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT DISTINCT 73 + col2 AS col2 FROM tab2 AS cor0
----
100
111
99

query I rowsort
SELECT ALL - col1 FROM tab2 WHERE NOT ( NULL ) IN ( col2 + - col2 / + col2 + - col2 )
----

query I rowsort
SELECT DISTINCT + col1 * - col2 + col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - tab1.col0 AS col2 FROM tab1 WHERE NOT col0 >= col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6193
SELECT DISTINCT col0 + + col2 DIV + col0 AS col1 FROM tab0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-6193
SELECT DISTINCT col0 + + col2 / + col0 AS col1 FROM tab0
----
25
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6194
SELECT DISTINCT 80 + col0 DIV tab1.col2 FROM tab1
----
80
81

skipif mysql # not compatible
query I rowsort label-6194
SELECT DISTINCT 80 + col0 / tab1.col2 FROM tab1
----
80
81

query I rowsort
SELECT col1 + - col1 + ( + col1 + + col0 ) AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL col0 - + tab1.col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - tab2.col0 * - tab2.col1 AS col0 FROM tab2
----
1343
217
4602

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 DISTINCT 71 * + col0 FROM tab0 cor0
----
1704
2485
6319

query I rowsort
SELECT + + 46 + + col1 AS col2 FROM tab1 AS cor0
----
56
59
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-6201
SELECT DISTINCT col0 + - col2 DIV col1 + + 39 AS col2 FROM tab1
----
112
40
98

skipif mysql # not compatible
query I rowsort label-6201
SELECT DISTINCT col0 + - col2 / col1 + + 39 AS col2 FROM tab1
----
112
40
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6202
SELECT DISTINCT col1 DIV + col0 + + 36 * tab1.col0 * col2 AS col2 FROM tab1
----
131328
276480
5840

skipif mysql # not compatible
query I rowsort label-6202
SELECT DISTINCT col1 / + col0 + + 36 * tab1.col0 * col2 AS col2 FROM tab1
----
131328
276480
5840

query I rowsort
SELECT ALL 76 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT DISTINCT + 77 AS col0 FROM tab1, tab2 AS cor0
----
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-6205
SELECT - col1 DIV - 21 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6205
SELECT - col1 / - 21 FROM tab2
----
0
1
2

query I rowsort
SELECT + col0 * + 5 + - col0 FROM tab2 AS cor0
----
28
312
316

onlyif mysql # use DIV operator for integer division
query I rowsort label-6207
SELECT col2 DIV - col1 + cor0.col1 AS col2 FROM tab2 cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-6207
SELECT col2 / - col1 + cor0.col1 AS col2 FROM tab2 cor0
----
15
31
59

query I rowsort
SELECT ALL ( - col2 + col2 * + 49 ) FROM tab0
----
1584
3936
48

query I rowsort
SELECT ALL + - cor0.col1 + + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + + 90 * + ( col0 + ( - col1 ) ) FROM tab0 AS cor0
----
-180
-5580
-5580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6211
SELECT ALL + ( col1 ) + col0 * col2 DIV - col0 AS col0 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-6211
SELECT ALL + ( col1 ) + col0 * col2 / - col0 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + + 5 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-28
-77
4

query I rowsort
SELECT + - ( col1 ) * + cor0.col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col1 + col0 - - cor0.col2 AS col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT - col0 * 55 AS col1 FROM tab0 AS cor0
----
-1320
-1925
-4895

query I rowsort
SELECT + + 36 * col0 AS col1 FROM tab1 AS cor0
----
108
2304
2880

query I rowsort
SELECT ALL + + col0 + - col1 - + col2 FROM tab2 AS cor0
----
-51
-7
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6218
SELECT ALL + ( - col1 ) + - CAST( - col1 AS SIGNED ) * + col2 AS col1 FROM tab2 AS cor0
----
1475
629
806

skipif mysql # not compatible
query I rowsort label-6218
SELECT ALL + ( - col1 ) + - CAST ( - col1 AS INTEGER ) * + col2 AS col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT col0 * col1 + - col1 FROM tab1
----
1027
52
630

query I rowsort
SELECT DISTINCT - 56 - + 30 FROM tab0, tab0 cor0
----
-86

query I rowsort
SELECT 27 * - cor0.col0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to bc4ba142e01cf8908b59b57f0026ae45

query I rowsort
SELECT col2 + 88 * - col2 FROM tab0 cor0
----
-2871
-7134
-87

query I rowsort
SELECT + ( col0 ) + + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6224
SELECT - 94 DIV col1 AS col2 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6224
SELECT - 94 / col1 AS col2 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT + 23 + 53 * - col2 FROM tab1 AS cor0
----
-2839
-2998
-5065

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6226
SELECT ALL + CAST( 75 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
75
75
75

skipif mysql # not compatible
query I rowsort label-6226
SELECT ALL + CAST ( 75 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
75
75
75

query I rowsort
SELECT - col2 + 74 * + col0 AS col2 FROM tab2 AS cor0
----
491
5746
5808

query I rowsort
SELECT DISTINCT - + col2 * col1 + col2 + 92 AS col0 FROM tab0 AS cor0
----
-2713
-4
-7288

query I rowsort
SELECT DISTINCT + - ( - col0 ) + + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6230
SELECT col0 + - col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-6230
SELECT col0 + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT DISTINCT - 66 * + tab0.col2 AS col0 FROM tab0
----
-2178
-5412
-66

query I rowsort
SELECT DISTINCT + + ( col1 ) * + cor0.col0 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT + + 0 + + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col1 * cor0.col0 + 21 * + col2 AS col0 FROM tab0 AS cor0
----
2757
3416
9821

query I rowsort
SELECT - col0 + cor0.col0 - + col1 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6236
SELECT + + col2 DIV col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6236
SELECT + + col2 / col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT 71 * - col0 + + col2 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1704
-2485
-6319

query I rowsort
SELECT + col2 + col1 * - col0 + - col2 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - col0 + - 52 * 23 FROM tab1 AS cor0
----
-1199
-1260
-1276

query I rowsort
SELECT DISTINCT + + 4 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 + col2 col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT - col1 + - cor0.col0 * cor0.col1 * col2 FROM tab1 AS cor0
----
-36490
-4238
-99853

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6243
SELECT - CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6243
SELECT - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - - col0 * - cor0.col1 * - 57 - col1 FROM tab0 AS cor0
----
117562
193418
461552

onlyif mysql # use DIV operator for integer division
query I rowsort label-6245
SELECT - col1 DIV col0 + - 91 * + col1 AS col1 FROM tab1 AS cor0
----
-1183
-2374
-910

skipif mysql # not compatible
query I rowsort label-6245
SELECT - col1 / col0 + - 91 * + col1 AS col1 FROM tab1 AS cor0
----
-1183
-2374
-910

query I rowsort
SELECT + + col1 * + col0 * 35 AS col2 FROM tab1 AS cor0
----
22400
2730
36400

query I rowsort
SELECT DISTINCT - col0 + 94 AS col1 FROM tab1 cor0
----
14
30
91

query I rowsort
SELECT ALL cor0.col1 + - ( - col1 ) FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6249
SELECT col2 DIV + col1 - - col1 AS col0 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-6249
SELECT col2 / + col1 - - col1 AS col0 FROM tab2 AS cor0
----
19
31
59

query I rowsort
SELECT + 13 * + tab0.col0 AS col1 FROM tab0
----
1157
312
455

query I rowsort
SELECT DISTINCT col2 * - 92 AS col0 FROM tab1 AS cor0
----
-4968
-5244
-8832

query I rowsort
SELECT - + col1 - col2 * + col2 AS col1 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + - col0 + 72 + col1 FROM tab2 AS cor0
----
10
53
96

query I rowsort
SELECT + - col2 + ( cor0.col1 + col0 ) FROM tab1 AS cor0
----
-25
-3
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-6255
SELECT ALL + + col1 DIV 36 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6255
SELECT ALL + + col1 / 36 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT 67 + cor1.col0 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 59bf1e3e730c7c6f6cf0548084c467d1

query I rowsort
SELECT DISTINCT + col2 * - col2 - 6 FROM tab0
----
-1095
-6730
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6258
SELECT ALL - - ( col1 ) * - col2 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6258
SELECT ALL - - ( col1 ) * - col2 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( + ( col1 ) ) + col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6260
SELECT ALL tab0.col0 / CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6260
SELECT ALL tab0.col0 / CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( - col0 ) + col1 * + col0 FROM tab1 cor0
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6262
SELECT ALL col1 * col0 + - CAST( 1 AS SIGNED ) + + col1 AS col0 FROM tab2 AS cor0
----
1359
247
4660

skipif mysql # not compatible
query I rowsort label-6262
SELECT ALL col1 * col0 + - CAST ( 1 AS INTEGER ) + + col1 AS col0 FROM tab2 AS cor0
----
1359
247
4660

query I rowsort
SELECT ALL - 49 * - tab0.col1 * ( - col0 ) AS col0 FROM tab0
----
-101136
-166355
-396851

query I rowsort
SELECT ALL col0 + - col2 * - tab0.col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT cor0.col2 AS col0 FROM tab2, tab0 cor0 CROSS JOIN tab1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - 30 * + col1 + col0 FROM tab0 AS cor0
----
-2556
-2641
-2875

query I rowsort
SELECT DISTINCT - ( + ( + cor0.col1 ) ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + 39 * + col2 AS col2 FROM tab1 cor0
----
2106
2223
3744

query I rowsort
SELECT col1 * - col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + col2 * + 19 FROM tab0 AS cor0
----
1558
19
627

query I rowsort
SELECT - 7 + + col0 * col1 AS col0 FROM tab2 AS cor0
----
1336
210
4595

query I rowsort
SELECT - + ( + col2 ) * + col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + ( col2 ) * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - + col0 + col1 * col1 AS col2 FROM tab2 AS cor0
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-6275
SELECT ALL - ( - col1 ) + ( col2 ) DIV col0 AS col2 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-6275
SELECT ALL - ( - col1 ) + ( col2 ) / col0 AS col2 FROM tab0 AS cor0
----
87
91
97

query I rowsort
SELECT DISTINCT + - 1 * - col2 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6277
SELECT col0 + - col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6277
SELECT col0 + - col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6278
SELECT 88 + col2 DIV - col0 col0 FROM tab0
----
87
88
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6278
SELECT 88 + col2 / - col0 col0 FROM tab0
----
87
88
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - col0 * col0 * 0 col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL col2 + 46 AS col1 FROM tab0 cor0
----
128
47
79

query I rowsort
SELECT ALL + - cor0.col0 * 31 * col2 + - col2 FROM tab1 AS cor0
----
-113145
-238176
-5076

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6282
SELECT col1 * CAST( NULL AS SIGNED ) / + 74 + col1 * ( col2 + col0 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6282
SELECT col1 * CAST ( NULL AS INTEGER ) / + 74 + col1 * ( col2 + col0 ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6283
SELECT ALL 6 + cor0.col1 DIV - CAST( + 81 AS SIGNED ) col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6283
SELECT ALL 6 + cor0.col1 / - CAST ( + 81 AS INTEGER ) col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

onlyif mysql # use DIV operator for integer division
query I rowsort label-6284
SELECT - col0 DIV 64 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6284
SELECT - col0 / 64 FROM tab0 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6285
SELECT DISTINCT - col1 DIV cor0.col0 AS col0 FROM tab1 cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-6285
SELECT DISTINCT - col1 / cor0.col0 AS col0 FROM tab1 cor0
----
-8
0

query I rowsort
SELECT + col1 * - ( + ( + col2 ) ) AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - tab2.col0 - + col2 AS col1 FROM tab2
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6288
SELECT ALL - CAST( NULL AS SIGNED ) * - ( col1 ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6288
SELECT ALL - CAST ( NULL AS INTEGER ) * - ( col1 ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 69 * 23 AS col0 FROM tab0 AS cor0
----
-1587
-1587
-1587

query I rowsort
SELECT DISTINCT + col2 * 72 FROM tab0 AS cor0
----
2376
5904
72

query I rowsort
SELECT + 90 + + col2 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT + + col2 + + ( + col1 ) * col2 FROM tab0 AS cor0
----
2871
7544
98

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2, tab2 cor0, tab1 AS cor1
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

query I rowsort
SELECT cor0.col2 * - col2 * cor0.col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6295
SELECT + CAST( + col0 AS SIGNED ) + - col2 FROM tab0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-6295
SELECT + CAST ( + col0 AS INTEGER ) + - col2 FROM tab0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 41 col1 FROM tab2
----
41
41
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * 55 + col2 col2 FROM tab2 AS cor0
----
-1404
-1458
-2052

query I rowsort
SELECT DISTINCT 96 AS col2 FROM tab1, tab0, tab1 cor0
----
96

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( - col1 AS REAL ) + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL - - col0 * - col2 * - col1 AS col2 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - cor0.col0 * tab2.col0 AS col1 FROM tab2, tab0, tab0 cor0
----
9 values hashing to 02551feb5ca40c11f08ef3f9e9603264

query I rowsort
SELECT DISTINCT col1 * - 54 FROM tab1
----
-1404
-540
-702

query I rowsort
SELECT DISTINCT + col1 + col1 + col0 AS col2 FROM tab1
----
106
55
84

query I rowsort
SELECT DISTINCT + 7 AS col2 FROM tab0, tab2, tab1 AS cor0
----
7

query I rowsort
SELECT DISTINCT + 5 + col2 AS col1 FROM tab0
----
38
6
87

query I rowsort
SELECT DISTINCT col2 + col0 + - ( col1 + - col1 ) FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT 8 * col1 + + ( col2 ) FROM tab2
----
174
275
498

query I rowsort
SELECT - + 56 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT + cor0.col1 FROM tab1, tab2, tab1 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col2 * col1 * + 19 + + 78 * - col1 FROM tab1
----
10050
22698
24648

query I rowsort
SELECT ALL + ( + col2 ) * 40 AS col2 FROM tab1 AS cor0
----
2160
2280
3840

query I rowsort
SELECT DISTINCT 19 + col0 AS col1 FROM tab1
----
22
83
99

query I rowsort
SELECT col1 * - tab1.col0 * - tab1.col0 AS col2 FROM tab1
----
234
40960
83200

query I rowsort
SELECT - col2 * + ( cor0.col2 ) * - col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT col1 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6316
SELECT DISTINCT - col0 DIV + 70 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6316
SELECT DISTINCT - col0 / + 70 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT - col2 + + 16 * + col2 AS col2 FROM tab2 AS cor0
----
390
405
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6318
SELECT ALL + col0 * + CAST( col2 AS SIGNED ) * + col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-6318
SELECT ALL + col0 * + CAST ( col2 AS INTEGER ) * + col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-6319
SELECT - col1 + - ( col0 ) DIV + col0 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-6319
SELECT - col1 + - ( col0 ) / + col0 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT ALL cor0.col1 + cor0.col0 * - col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT col0 + + 29 * col0 FROM tab2 AS cor0
----
210
2340
2370

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6322
SELECT ALL - + col2 + CAST( NULL AS SIGNED ) * 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-6322
SELECT ALL - + col2 + CAST ( NULL AS INTEGER ) * col1 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + cor0.col2 * cor0.col0 AS col0 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col1 * col2 + col1 * ( col2 ) FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6325
SELECT + col0 DIV col2 - col0 * col0 AS col0 FROM tab0 AS cor0
----
-1190
-576
-7920

skipif mysql # not compatible
query I rowsort label-6325
SELECT + col0 / col2 - col0 * col0 AS col0 FROM tab0 AS cor0
----
-1190
-576
-7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6326
SELECT ALL 62 + + col2 DIV col0 AS col1 FROM tab0 AS cor0
----
62
62
63

skipif mysql # not compatible
query I rowsort label-6326
SELECT ALL 62 + + col2 / col0 AS col1 FROM tab0 AS cor0
----
62
62
63

query I rowsort
SELECT ALL - 98 + col0 FROM tab2 AS cor0
----
-19
-20
-91

query I rowsort
SELECT - - cor1.col0 + cor0.col2 + - 84 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1b46f7c2a17f83839640f208c45831a4

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab0, tab0 cor0 CROSS JOIN tab1 AS cor1
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6330
SELECT 13 - + col1 DIV col2 col2 FROM tab0
----
-84
11
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6330
SELECT 13 - + col1 / col2 col2 FROM tab0
----
-84
11
12

query I rowsort
SELECT ALL + col2 + col1 * - 45 * col2 AS col2 FROM tab1
----
-25593
-56064
-63126

query I rowsort
SELECT col2 * col2 - 54 FROM tab2
----
1390
622
675

query I rowsort
SELECT - 11 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

query I rowsort
SELECT - col0 + cor0.col0 + 79 * col1 * cor0.col0 AS col1 FROM tab2 cor0
----
106097
17143
363558

onlyif mysql # use DIV operator for integer division
query I rowsort label-6335
SELECT col1 + + col1 * ( + cor0.col0 ) DIV col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-6335
SELECT col1 + + col1 * ( + cor0.col0 ) / col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT ( 41 ) AS col1 FROM tab1, tab2 cor0
----
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6337
SELECT DISTINCT + col1 * + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6337
SELECT DISTINCT + col1 * + CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT - 76 + - col0 FROM tab0 AS cor0
----
-100
-111
-165

query I rowsort
SELECT + 59 * 39 + - col2 AS col1 FROM tab2 AS cor0
----
2263
2274
2275

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 13 col1 FROM tab1 AS cor0
----
-13

query I rowsort
SELECT DISTINCT - + ( 57 ) + col1 FROM tab0 AS cor0
----
29
34
40

query I rowsort
SELECT + col2 * + 11 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT ALL - col2 * - col2 + col0 - + ( 82 ) FROM tab0 cor0
----
-46
1031
6731

query I rowsort
SELECT - ( 12 ) FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT - 7 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT DISTINCT + 58 AS col1 FROM tab1, tab0 AS cor0
----
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6347
SELECT + CAST( col0 AS SIGNED ) + + col2 col0 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6347
SELECT + CAST ( col0 AS INTEGER ) + + col2 col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - ( 83 ) + - cor0.col2 FROM tab1 AS cor0
----
-137
-140
-179

query I rowsort
SELECT + - col0 * - col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + col2 - cor0.col2 * col2 FROM tab2 AS cor0
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-6351
SELECT ALL - + col1 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6351
SELECT ALL - + col1 / + col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6352
SELECT col0 - col2 * CAST( - 42 AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
122475
136522
387152

skipif mysql # not compatible
query I rowsort label-6352
SELECT col0 - col2 * CAST ( - 42 AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
122475
136522
387152

query I rowsort
SELECT DISTINCT - - 42 * col2 FROM tab2 cor0
----
1092
1134
1596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 - + col0 col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - cor0.col1 * + col0 - - 28 AS col1 FROM tab2 AS cor0
----
-1315
-189
-4574

query I rowsort
SELECT + ( + col1 ) * - 62 FROM tab2 AS cor0
----
-1054
-1922
-3658

query I rowsort
SELECT + 95 FROM tab1, tab1 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ALL + + ( col0 ) * 6 FROM tab1 AS cor0
----
18
384
480

query I rowsort
SELECT DISTINCT col2 + - col2 * 98 AS col1 FROM tab0 cor0
----
-3201
-7954
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 78 * + cor0.col1 * - ( cor0.col1 ) col1 FROM tab1 AS cor0
----
-13182
-52728
-7800

query I rowsort
SELECT ALL - - col1 * - cor0.col2 + - col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT + col2 * + col1 + col1 * col0 * - col1 + col1 FROM tab0 AS cor0
----
-174580
-329121
-729456

onlyif mysql # use DIV operator for integer division
query I rowsort label-6363
SELECT DISTINCT - cor0.col1 + + col1 DIV col0 AS col2 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-6363
SELECT DISTINCT - cor0.col1 + + col1 / col0 AS col2 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT - col1 + - ( 55 ) FROM tab1 AS cor0
----
-65
-68
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6365
SELECT + - col1 * ( - col0 ) + col0 * + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6365
SELECT + - col1 * ( - col0 ) + col0 * + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6367
SELECT + col1 + CAST( - col2 AS SIGNED ) * + col1 col2 FROM tab0 AS cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6367
SELECT + col1 + CAST ( - col2 AS INTEGER ) * + col1 col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - + col1 * + ( + 95 ) AS col1 FROM tab1 AS cor0
----
-1235
-2470
-950

query I rowsort
SELECT DISTINCT - col2 * + ( + cor0.col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6370
SELECT DISTINCT + cor0.col2 + col2 DIV - 33 FROM tab0 cor0
----
1
32
80

skipif mysql # not compatible
query I rowsort label-6370
SELECT DISTINCT + cor0.col2 + col2 / - 33 FROM tab0 cor0
----
1
32
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6371
SELECT DISTINCT - - cor0.col0 + CAST( col0 + col0 * - col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-35
-5928
-6083

skipif mysql # not compatible
query I rowsort label-6371
SELECT DISTINCT - - cor0.col0 + CAST ( col0 + col0 * - col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-35
-5928
-6083

query I rowsort
SELECT ALL + + col2 + + col2 * - col1 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6373
SELECT DISTINCT col2 * CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6373
SELECT DISTINCT col2 * CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col1 * col1 + 86 FROM tab1 AS cor0
----
-14
-590
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6375
SELECT - col1 + 22 + ( - col1 + + col1 ) DIV - 17 AS col2 FROM tab2 AS cor0
----
-37
-9
5

skipif mysql # not compatible
query I rowsort label-6375
SELECT - col1 + 22 + ( - col1 + + col1 ) / - 17 AS col2 FROM tab2 AS cor0
----
-37
-9
5

query I rowsort
SELECT col1 + + 30 AS col0 FROM tab0 AS cor0
----
116
121
127

query I rowsort
SELECT DISTINCT + col1 * - ( - col0 ) FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 42 + ( - col1 ) FROM tab0 AS cor0
----
-44
-49
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-6379
SELECT - + col0 DIV cor0.col0 col1 FROM tab1 cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6379
SELECT - + col0 / cor0.col0 col1 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT + - 85 * + col1 FROM tab1 AS cor0
----
-1105
-2210
-850

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
1
33
82

query I rowsort
SELECT ALL - col1 * ( + col2 ) * + col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL ( - col2 * ( 17 ) + + tab2.col0 ) FROM tab2
----
-364
-452
-567

query I rowsort
SELECT - - col2 + 95 FROM tab0 AS cor0
----
128
177
96

query I rowsort
SELECT 52 + col2 FROM tab0
----
134
53
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6386
SELECT - col2 * + col1 + CAST( NULL AS SIGNED ) / + 89 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6386
SELECT - col2 * + col1 + CAST ( NULL AS INTEGER ) / + 89 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * ( 17 ) col0 FROM tab0 cor0
----
-1462
-1547
-1649

query I rowsort
SELECT ALL - + col0 * - 48 + + col1 FROM tab2 AS cor0
----
367
3803
3809

query I rowsort
SELECT ALL + - col0 * - col1 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - cor0.col1 + - col0 * col0 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + col1 * - ( col2 * + 31 ) + + col2 FROM tab2
----
-19988
-25920
-47528

onlyif mysql # use DIV operator for integer division
query I rowsort label-6392
SELECT DISTINCT col1 + - cor0.col0 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6392
SELECT DISTINCT col1 + - cor0.col0 / cor0.col0 AS col2 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL + col0 - col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT col1 * + col1 * col0 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6395
SELECT ALL + CAST( NULL AS SIGNED ) + cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6395
SELECT ALL + CAST ( NULL AS INTEGER ) + cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 47 + ( + col0 ) - + col2 FROM tab2 AS cor0
----
-6
-67
5

query I rowsort
SELECT + + ( + cor0.col0 ) + + col2 * + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - col2 + 32 AS col1 FROM tab1 AS cor0
----
-22
-25
-64

query I rowsort
SELECT ALL - - col0 + + 38 * col2 FROM tab2 AS cor0
----
1033
1066
1523

query I rowsort
SELECT ALL - col1 * col2 + cor0.col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL col2 * cor0.col0 - - col1 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT 77 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT DISTINCT - 68 - + cor0.col0 AS col2 FROM tab2 cor0
----
-146
-147
-75

query I rowsort
SELECT DISTINCT - 12 * + cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
-77
-858
-869

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - col1 ) col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL 96 AS col0 FROM tab2 cor0
----
96
96
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6407
SELECT + - col1 DIV cor0.col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6407
SELECT + - col1 / cor0.col0 FROM tab1 AS cor0
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 59 + col0 col0 FROM tab2 AS cor0
----
137
138
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6409
SELECT col2 + - cor0.col0 * ( - col1 + CAST( NULL AS SIGNED ) * - col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6409
SELECT col2 + - cor0.col0 * ( - col1 + CAST ( NULL AS INTEGER ) * - col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 col0 FROM tab2
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 40 * col0 * - ( - col1 ) col2 FROM tab1 AS cor0
----
25590
3094
41587

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 15ae1b54cae2dcf5c6eef7f1d15689eb

query I rowsort
SELECT 30 * - 8 - - col0 FROM tab0 AS cor0
----
-151
-205
-216

query I rowsort
SELECT DISTINCT col1 + 78 FROM tab2
----
109
137
95

query I rowsort
SELECT DISTINCT + 24 + col0 + + tab2.col2 FROM tab2
----
128
141
58

query I rowsort
SELECT ( ( + col2 ) + + ( + col2 ) ) AS col2 FROM tab0
----
164
2
66

query I rowsort
SELECT + - 51 * + col0 + ( col0 ) FROM tab1 AS cor0
----
-150
-3200
-4000

query I rowsort
SELECT + 40 * - col2 FROM tab1 AS cor0
----
-2160
-2280
-3840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6419
SELECT + 14 DIV + col2 - - 57 FROM tab0 AS cor0
----
57
57
71

skipif mysql # not compatible
query I rowsort label-6419
SELECT + 14 / + col2 - - 57 FROM tab0 AS cor0
----
57
57
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6420
SELECT + CAST( 70 AS SIGNED ) * + tab2.col2 FROM tab2
----
1820
1890
2660

skipif mysql # not compatible
query I rowsort label-6420
SELECT + CAST ( 70 AS INTEGER ) * + tab2.col2 FROM tab2
----
1820
1890
2660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 43 col0 FROM tab2, tab2 AS cor0
----
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6422
SELECT ALL + CAST( 41 AS SIGNED ) * - col2 FROM tab1
----
-2214
-2337
-3936

skipif mysql # not compatible
query I rowsort label-6422
SELECT ALL + CAST ( 41 AS INTEGER ) * - col2 FROM tab1
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT cor0.col2 - cor0.col1 FROM tab2, tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + + cor0.col0 * col1 * col0 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-6425
SELECT DISTINCT + tab2.col0 * + col0 DIV - col0 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-6425
SELECT DISTINCT + tab2.col0 * + col0 / - col0 FROM tab2
----
-7
-78
-79

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NULL < NULL OR col2 NOT IN ( col0 * - cor0.col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6427
SELECT + col1 DIV - col0 + - col0 * - cor0.col1 - col1 FROM tab2 AS cor0
----
1326
182
4543

skipif mysql # not compatible
query I rowsort label-6427
SELECT + col1 / - col0 + - col0 * - cor0.col1 - col1 FROM tab2 AS cor0
----
1326
182
4543

query I rowsort
SELECT DISTINCT col1 * - col2 * col1 AS col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL 62 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-24
-29
-35

query I rowsort
SELECT DISTINCT - 71 * col1 AS col1 FROM tab1
----
-1846
-710
-923

query I rowsort
SELECT 47 * - col1 AS col0 FROM tab1 AS cor0
----
-1222
-470
-611

query I rowsort
SELECT ALL - - cor0.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # use DIV operator for integer division
query I rowsort label-6433
SELECT col2 DIV col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-6433
SELECT col2 / col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
14
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col2 + + col1 ) col2 FROM tab1
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6435
SELECT + 24 DIV col2 AS col1 FROM tab0 AS cor0
----
0
0
24

skipif mysql # not compatible
query I rowsort label-6435
SELECT + 24 / col2 AS col1 FROM tab0 AS cor0
----
0
0
24

query I rowsort
SELECT ALL - col0 - + col1 * - col1 FROM tab1
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6437
SELECT DISTINCT - col2 - col1 DIV - col1 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-6437
SELECT DISTINCT - col2 - col1 / - col1 FROM tab1
----
-53
-56
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6438
SELECT col2 DIV col1 + - tab1.col1 * col1 + - col1 AS col0 FROM tab1
----
-105
-175
-700

skipif mysql # not compatible
query I rowsort label-6438
SELECT col2 / col1 + - tab1.col1 * col1 + - col1 AS col0 FROM tab1
----
-105
-175
-700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - tab2.col0 col2 FROM tab2
----
-49
-6084
-6241

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT IN ( - col2 + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6441
SELECT ALL + col0 * - col1 * + col2 + col2 DIV - col2 FROM tab0
----
-3396
-664119
-68113

skipif mysql # not compatible
query I rowsort label-6441
SELECT ALL + col0 * - col1 * + col2 + col2 / - col2 FROM tab0
----
-3396
-664119
-68113

query I rowsort
SELECT ALL col0 * col0 - col0 * - col2 * tab2.col0 FROM tab2
----
1372
164268
243399

query I rowsort
SELECT DISTINCT + col1 + col2 * - col1 AS col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT - col1 + + col1 * tab1.col1 FROM tab1
----
156
650
90

query I rowsort
SELECT ALL col0 + + tab2.col2 * col2 FROM tab2
----
1523
736
754

query III rowsort
SELECT ALL * FROM tab2 WHERE tab2.col2 BETWEEN ( - col2 ) AND NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NOT ( - col2 ) BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT DISTINCT + col2 + - tab1.col2 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6449
SELECT - tab0.col2 + - tab0.col2 DIV col1 AS col0 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6449
SELECT - tab0.col2 + - tab0.col2 / col1 AS col0 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col1 * - tab1.col2 col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT ALL - col2 + col2 * - col2 AS col1 FROM tab0 WHERE NOT + col0 <> NULL
----

query I rowsort
SELECT DISTINCT - col0 - col1 AS col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT col1 AS col2 FROM tab2 WHERE - col2 > NULL
----

query I rowsort
SELECT DISTINCT col2 + col1 * col1 AS col1 FROM tab1
----
157
265
730

query I rowsort
SELECT ALL - col1 + - col2 * col0 * - col1 AS col2 FROM tab1
----
36470
4186
99827

query I rowsort
SELECT DISTINCT + col1 + + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT col2 AS col1 FROM tab1 WHERE NOT + col0 * col2 BETWEEN NULL AND + col0
----
54
57
96

query I rowsort
SELECT DISTINCT - col0 - + col2 * - col1 AS col2 FROM tab2
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6459
SELECT ALL - col2 * col2 + + col0 / + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6459
SELECT ALL - col2 * col2 + + col0 / + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6460
SELECT + - cor0.col2 + - 44 DIV + col0 col1 FROM tab1 AS cor0
----
-57
-68
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6460
SELECT + - cor0.col2 + - 44 / + col0 col1 FROM tab1 AS cor0
----
-57
-68
-96

query I rowsort
SELECT ALL - cor0.col2 * + cor0.col2 + col1 * 9 * col0 FROM tab0 cor0
----
17487
30554
66167

query I rowsort
SELECT DISTINCT - - col2 * - col1 + + col1 * col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + - 57 + - col0 FROM tab0 AS cor0
----
-146
-81
-92

query I rowsort
SELECT ALL + col2 + col2 * + col0 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + cor0.col0 * cor0.col2 + col1 * 84 FROM tab1 AS cor0
----
2346
4488
8772

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 3 * col0 col1 FROM tab0 cor0
----
105
267
72

query I rowsort
SELECT + col1 * col1 * col1 + col2 FROM tab2
----
205405
29818
4951

query I rowsort
SELECT - tab0.col1 + - ( - 9 ) FROM tab0
----
-77
-82
-88

query I rowsort
SELECT DISTINCT + col2 * - 25 + - ( + col0 ) FROM tab1
----
-1353
-1489
-2480

onlyif mysql # use DIV operator for integer division
query I rowsort label-6470
SELECT col1 DIV - 75 + - tab0.col1 DIV - col1 - + col0 AS col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6470
SELECT col1 / - 75 + - tab0.col1 / - col1 - + col0 AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL + col1 * - col1 + - 0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT - 15 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 91b10a00c89b36b5bf0bed723e656ccc

query I rowsort
SELECT - ( 70 ) AS col2 FROM tab2
----
-70
-70
-70

query I rowsort
SELECT ALL + col2 * + 45 AS col2 FROM tab0
----
1485
3690
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6475
SELECT DISTINCT + - col1 DIV col0 + col0 AS col1 FROM tab2 AS cor0
----
3
78
79

skipif mysql # not compatible
query I rowsort label-6475
SELECT DISTINCT + - col1 / col0 + col0 AS col1 FROM tab2 AS cor0
----
3
78
79

query I rowsort
SELECT 81 * + col0 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT ALL - 52 AS col1 FROM tab0 cor0
----
-52
-52
-52

query I rowsort
SELECT DISTINCT cor0.col0 + tab1.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to a842fe91e5dc1346a95ce3987ec1b2fb

query I rowsort
SELECT + col0 + ( + cor0.col1 ) * col2 * col0 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT ALL - col2 + + 50 FROM tab2 AS cor0
----
12
23
24

query I rowsort
SELECT DISTINCT col1 + + 28 FROM tab1
----
38
41
54

query I rowsort
SELECT col0 + + col1 + + tab1.col0 FROM tab1
----
138
173
32

query I rowsort
SELECT DISTINCT 22 * + tab2.col1 + tab2.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
1357
391
713

query I rowsort
SELECT col0 + 82 AS col2 FROM tab1
----
146
162
85

query I rowsort
SELECT DISTINCT + 22 AS col2 FROM tab0, tab1 AS cor0
----
22

query I rowsort
SELECT DISTINCT - + col1 * col0 + - col2 * col1 * cor0.col0 AS col1 FROM tab0 cor0
----
-672217
-6790
-70176

onlyif mysql # use DIV operator for integer division
query I rowsort label-6487
SELECT + col1 DIV ( + cor0.col0 ) + - cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-6487
SELECT + col1 / ( + cor0.col0 ) + - cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
-1343
-213
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6488
SELECT + col0 DIV + col0 + - col2 AS col1 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-6488
SELECT + col0 / + col0 + - col2 AS col1 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT DISTINCT + col2 - ( + col0 ) AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + col1 * - col1 * 54 + col0 AS col2 FROM tab2 AS cor0
----
-15527
-187896
-51887

query I rowsort
SELECT ALL + 93 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT ALL - cor0.col0 * - col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 20 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6494
SELECT col2 + CAST( - 71 AS SIGNED ) FROM tab1 AS cor0
----
-14
-17
25

skipif mysql # not compatible
query I rowsort label-6494
SELECT col2 + CAST ( - 71 AS INTEGER ) FROM tab1 AS cor0
----
-14
-17
25

query I rowsort
SELECT - + cor0.col2 * 85 * - cor0.col0 - + cor0.col2 AS col1 FROM tab1 AS cor0
----
13716
310023
652704

query I rowsort
SELECT ALL - cor0.col0 * col2 + col0 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL - - cor0.col2 + - col1 * col0 FROM tab1 AS cor0
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 - ( cor0.col0 ) * - col1 * - col1 col0 FROM tab2 cor0
----
-22848
-271577
-6758

query I rowsort
SELECT DISTINCT + col1 * - cor0.col1 - col2 FROM tab1 cor0
----
-157
-265
-730

query I rowsort
SELECT - col1 + + 9 * - col0 AS col0 FROM tab1 AS cor0
----
-53
-586
-733

query I rowsort
SELECT ALL - - col2 * col1 - col0 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT ( + col2 * col1 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL col1 * - col2 + col2 * + col0 AS col1 FROM tab1
----
-1242
3078
6432

query I rowsort
SELECT + 21 + - col1 FROM tab0 AS cor0
----
-65
-70
-76

query I rowsort
SELECT - + ( + 33 ) * - col1 + col0 FROM tab1 AS cor0
----
394
509
861

query I rowsort
SELECT + 31 * + col2 FROM tab1 cor0
----
1674
1767
2976

query I rowsort
SELECT - 81 * + col1 AS col1 FROM tab0 AS cor0
----
-6966
-7371
-7857

query I rowsort
SELECT DISTINCT + - 24 * col1 + col1 AS col0 FROM tab0 cor0
----
-1978
-2093
-2231

query I rowsort
SELECT DISTINCT 14 * col2 * + ( col2 + + col0 ) FROM tab0
----
196308
26334
504

query I rowsort
SELECT - + 55 + + col2 * cor0.col0 FROM tab0 AS cor0
----
-20
7243
737

query I rowsort
SELECT - col1 * - col2 * - col2 + + col2 + col0 * + col0 * col2 FROM tab1 AS cor0
----
-75276
201039
494688

query I rowsort
SELECT col0 * 70 FROM tab2 cor0
----
490
5460
5530

query I rowsort
SELECT + - col0 - col1 * - 9 FROM tab2 AS cor0
----
272
453
74

query I rowsort
SELECT - cor0.col0 * col0 + - col2 AS col0 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT col0 * + ( col2 ) + + cor0.col0 + cor0.col2 AS col1 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT DISTINCT + 81 AS col0 FROM tab0
----
81

query I rowsort
SELECT + col2 + col1 * - ( + col0 + - col2 * tab1.col1 ) AS col1 FROM tab1
----
15280
36480
5117

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 48 * col0 col1 FROM tab2
----
-336
-3744
-3792

query I rowsort
SELECT ALL - ( col0 ) * + 65 + + tab2.col1 * col2 AS col1 FROM tab2
----
-3536
-4489
382

onlyif mysql # use DIV operator for integer division
query I rowsort label-6520
SELECT ALL col2 DIV col1 + col0 + 80 * col2 * + tab0.col0 AS col0 FROM tab0
----
2835
583929
63384

skipif mysql # not compatible
query I rowsort label-6520
SELECT ALL col2 / col1 + col0 + 80 * col2 * + tab0.col0 AS col0 FROM tab0
----
2835
583929
63384

query I rowsort
SELECT DISTINCT - cor0.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-24
-35
-89

query I rowsort
SELECT + 22 * + col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT - 25 + + ( cor0.col2 * - ( cor0.col2 ) ) AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to b2896906352b90203dcb78a0b91ebe31

query I rowsort
SELECT ALL + col1 * 43 FROM tab0 cor0
----
3698
3913
4171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col2 * + col1 col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - 42 + + col1 * col1 AS col2 FROM tab2 AS cor0
----
247
3439
919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6527
SELECT CAST( NULL AS SIGNED ) + + tab2.col0 + col2 * - col2 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6527
SELECT CAST ( NULL AS INTEGER ) + + tab2.col0 + col2 * - col2 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col2 ) + + col1 * + col1 AS col1 FROM tab0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - col0 + + col1 col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-6530
SELECT ALL - 86 DIV col0 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-6530
SELECT ALL - 86 / col0 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT ALL + + col0 + + 67 FROM tab1 AS cor0
----
131
147
70

query I rowsort
SELECT ALL - + ( 63 ) FROM tab0 AS cor0
----
-63
-63
-63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6533
SELECT + CAST( + col1 AS SIGNED ) * col1 - - col1 * col1 AS col0 FROM tab1 AS cor0
----
1352
200
338

skipif mysql # not compatible
query I rowsort label-6533
SELECT + CAST ( + col1 AS INTEGER ) * col1 - - col1 * col1 AS col0 FROM tab1 AS cor0
----
1352
200
338

query I rowsort
SELECT 79 + col2 * col1 * col0 FROM tab2 AS cor0
----
119731
51113
5938

query I rowsort
SELECT ALL - + 78 FROM tab1 AS cor0
----
-78
-78
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + col0 * col0 col1 FROM tab2 AS cor0
----
56
6162
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - cor0.col1 col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + cor0.col0 + cor0.col2 * ( col1 * + col2 ) AS col0 FROM tab1 AS cor0
----
119888
32554
75819

query I rowsort
SELECT + cor0.col1 * - col1 + - col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT + 56 * + col1 + + ( cor0.col1 ) FROM tab1 AS cor0
----
1482
570
741

query I rowsort
SELECT ALL + 73 + + col2 AS col0 FROM tab2
----
100
111
99

query I rowsort
SELECT ALL + tab1.col1 * tab1.col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL + 16 FROM tab2 cor0
----
16
16
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-6544
SELECT DISTINCT + + col1 + + col1 DIV ( - 60 ) FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6544
SELECT DISTINCT + + col1 + + col1 / ( - 60 ) FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT DISTINCT col0 * col1 + - 39 * col2 AS col1 FROM tab1 AS cor0
----
-1583
-2028
-2704

query I rowsort
SELECT DISTINCT - 1 + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT - 41 * col0 + col0 AS col0 FROM tab2
----
-280
-3120
-3160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6548
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6548
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6549
SELECT - CAST( NULL AS SIGNED ) * col1 * - col1 - + 38 / + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6549
SELECT - CAST ( NULL AS INTEGER ) * col1 * - col1 - + 38 / + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 32 * + col1 + ( col2 + - col0 ) AS col0 FROM tab0
----
2761
2905
3070

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 28 * col1 + - col1 * - col1 + - col1 col2 FROM tab1
----
-190
-208
-78

query I rowsort
SELECT 81 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT ( col2 ) * 21 FROM tab0
----
1722
21
693

query I rowsort
SELECT DISTINCT ( col1 + 27 ) FROM tab0
----
113
118
124

query I rowsort
SELECT ( col0 ) + ( col1 ) FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT - col1 * 30 * - col2 AS col0 FROM tab2
----
19380
25110
46020

query I rowsort
SELECT ALL - col1 * + col2 + col0 + col1 FROM tab0 AS cor0
----
-2728
-7282
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6559
SELECT + + CAST( NULL AS SIGNED ) - - col1 * - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6559
SELECT + + CAST ( NULL AS INTEGER ) - - col1 * - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6560
SELECT DISTINCT 21 DIV + 37 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-6560
SELECT DISTINCT 21 / + 37 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL - col1 + col1 * col1 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6562
SELECT DISTINCT - CAST( ( + col2 ) AS SIGNED ) * + col2 * + col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

skipif mysql # not compatible
query I rowsort label-6562
SELECT DISTINCT - CAST ( ( + col2 ) AS INTEGER ) * + col2 * + col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

onlyif mysql # use DIV operator for integer division
query I rowsort label-6563
SELECT DISTINCT col0 + + col2 DIV col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6563
SELECT DISTINCT col0 + + col2 / col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT DISTINCT - ( 85 ) * col1 FROM tab0 AS cor0
----
-7310
-7735
-8245

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6565
SELECT - col1 + + col2 * + ( + col1 + - CAST( NULL AS SIGNED ) ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6565
SELECT - col1 + + col2 * + ( + col1 + - CAST ( NULL AS INTEGER ) ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6566
SELECT + col0 + + tab0.col1 DIV - 46 AS col1 FROM tab0
----
23
33
88

skipif mysql # not compatible
query I rowsort label-6566
SELECT + col0 + + tab0.col1 / - 46 AS col1 FROM tab0
----
23
33
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6567
SELECT + CAST( NULL AS SIGNED ) + - col1 * - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6567
SELECT + CAST ( NULL AS INTEGER ) + - col1 * - col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL 11 + col1 * col1 * 59 AS col0 FROM tab1 AS cor0
----
39895
5911
9982

onlyif mysql # use DIV operator for integer division
query I rowsort label-6570
SELECT - col2 DIV + col1 + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-6570
SELECT - col2 / + col1 + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - 80 + col2 * - col1 * + col0 FROM tab2 AS cor0
----
-119732
-51114
-5939

query I rowsort
SELECT ALL + + col1 + 97 FROM tab1 AS cor0
----
107
110
123

query I rowsort
SELECT - col0 * ( + tab0.col0 ) FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ALL 63 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT DISTINCT 77 * 83 FROM tab2, tab2 AS cor0
----
6391

query I rowsort
SELECT - col2 * 46 + + col2 FROM tab1 cor0
----
-2430
-2565
-4320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6577
SELECT ALL + col0 * + CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6577
SELECT ALL + col0 * + CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 + 14 + col0 FROM tab0 AS cor0
----
14
14
14

query I rowsort
SELECT 4 * + cor0.col0 * - col1 AS col1 FROM tab2 AS cor0
----
-18408
-5372
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6580
SELECT ALL + col1 DIV - col0 + col1 * - ( col0 ) AS col1 FROM tab1 AS cor0
----
-1040
-640
-86

skipif mysql # not compatible
query I rowsort label-6580
SELECT ALL + col1 / - col0 + col1 * - ( col0 ) AS col1 FROM tab1 AS cor0
----
-1040
-640
-86

query I rowsort
SELECT DISTINCT + + 98 - - 22 FROM tab2 AS cor0
----
120

query I rowsort
SELECT cor0.col1 * ( - cor0.col2 ) + ( + cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + ( + 22 ) * + col1 + col1 AS col1 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT ALL col1 * ( 26 ) + col0 AS col1 FROM tab0
----
2260
2455
2557

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6585
SELECT CAST( NULL AS SIGNED ) * 58 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6585
SELECT CAST ( NULL AS INTEGER ) * 58 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * + col1 col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-6587
SELECT + + col2 + - col0 DIV - col2 AS col0 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-6587
SELECT + + col2 + - col0 / - col2 AS col0 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT DISTINCT 56 * col2 FROM tab2 cor0
----
1456
1512
2128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 8 * col2 col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT DISTINCT + + 41 + col2 * + ( col1 ) FROM tab1 AS cor0
----
1289
1445
611

onlyif mysql # use DIV operator for integer division
query I rowsort label-6591
SELECT DISTINCT + + cor0.col2 * cor0.col1 DIV col0 AS col0 FROM tab2 cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-6591
SELECT DISTINCT + + cor0.col2 * cor0.col1 / col0 AS col0 FROM tab2 cor0
----
119
19
8

query I rowsort
SELECT ALL - ( + ( + col2 ) ) FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 18 col0 FROM tab0 cor0
----
-18
-18
-18

onlyif mysql # use DIV operator for integer division
query I rowsort label-6594
SELECT tab2.col2 DIV + col1 col2 FROM tab2
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6594
SELECT tab2.col2 / + col1 col2 FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT + 78 + + col2 * + 98 + - ( + col0 + col2 ) FROM tab2
----
2522
2690
3685

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6596
SELECT + + col2 * + 55 + 4 * - col1 * CAST( NULL AS SIGNED ) - + 70 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6596
SELECT + + col2 * + 55 + 4 * - col1 * CAST ( NULL AS INTEGER ) - + 70 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - ( col1 * - col1 ) FROM tab1 cor0
----
110
182
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6598
SELECT DISTINCT - ( + col0 ) + + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6598
SELECT DISTINCT - ( + col0 ) + + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT - - col1 + cor0.col0 - + col0 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT col1 * 3 + - cor0.col0 FROM tab1 cor0
----
-34
-41
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 col2 FROM tab0
----
36
36
36

query I rowsort
SELECT ALL + col0 + - ( - col0 ) * + col1 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + cor0.col1 col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT col2 - ( - col2 ) AS col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + + col2 + 36 AS col1 FROM tab1 cor0
----
132
90
93

query I rowsort
SELECT ALL - 60 * cor0.col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT DISTINCT - 31 + col0 * + col1 FROM tab0 AS cor0
----
2033
3364
8068

query I rowsort
SELECT + 1 * col2 + col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-6609
SELECT DISTINCT - - col1 * col2 + col0 DIV + col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-6609
SELECT DISTINCT - - col1 * col2 + col0 / + col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 24 * col2 FROM tab1
----
1296
1368
2304

onlyif mysql # use DIV operator for integer division
query I rowsort label-6611
SELECT cor0.col1 DIV 79 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-6611
SELECT cor0.col1 / 79 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - + 5 AS col1 FROM tab0 cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT + col2 * + col1 + cor0.col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT - - col1 DIV col1 + col2 * col0 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-6614
SELECT - - col1 / col1 + col2 * col0 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT + cor1.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + tab2.col0 ) col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6617
SELECT DISTINCT - col0 DIV col2 + col1 FROM tab0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-6617
SELECT DISTINCT - col0 / col2 + col1 FROM tab0
----
62
86
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6618
SELECT + ( 14 * col2 ) + CAST( col2 AS SIGNED ) AS col0 FROM tab1
----
1440
810
855

skipif mysql # not compatible
query I rowsort label-6618
SELECT + ( 14 * col2 ) + CAST ( col2 AS INTEGER ) AS col0 FROM tab1
----
1440
810
855

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6619
SELECT + CAST( 10 AS SIGNED ) + - col1 AS col1 FROM tab2 AS cor0
----
-21
-49
-7

skipif mysql # not compatible
query I rowsort label-6619
SELECT + CAST ( 10 AS INTEGER ) + - col1 AS col1 FROM tab2 AS cor0
----
-21
-49
-7

query I rowsort
SELECT DISTINCT + 46 * - col2 + col1 * col0 AS col1 FROM tab2 AS cor0
----
-1025
-405
3406

query I rowsort
SELECT DISTINCT - 93 AS col2 FROM tab1 AS cor0
----
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6622
SELECT - ( + 65 ) / - col1 + CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6622
SELECT - ( + 65 ) / - col1 + CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 3 + cor0.col2 * col0 AS col1 FROM tab2 cor0
----
186
2025
2999

query I rowsort
SELECT DISTINCT 25 * + tab2.col1 * + 88 - 54 FROM tab2
----
129746
37346
68146

query I rowsort
SELECT + 25 * col2 * - col0 AS col2 FROM tab0
----
-182450
-19800
-875

query I rowsort
SELECT 53 * + col1 FROM tab2 AS cor0
----
1643
3127
901

query I rowsort
SELECT + col1 + - col2 * col0 * - col1 AS col2 FROM tab0 AS cor0
----
3492
664209
68198

onlyif mysql # use DIV operator for integer division
query I rowsort label-6628
SELECT + cor0.col1 + cor0.col2 DIV cor0.col1 col0 FROM tab2 AS cor0
----
19
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6628
SELECT + cor0.col1 + cor0.col2 / cor0.col1 col0 FROM tab2 AS cor0
----
19
31
59

query I rowsort
SELECT + - cor0.col2 - col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT - cor0.col1 * 83 + - cor0.col2 * col0 FROM tab0 AS cor0
----
-14851
-7930
-8086

query I rowsort
SELECT ( - col2 ) * col1 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL + col0 * 2 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - cor0.col0 * - ( ( col2 ) ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col0 * - 60 AS col0 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT + col0 + + col1 + + cor0.col2 * - col0 FROM tab0 cor0
----
-682
-7118
97

query I rowsort
SELECT ALL + col0 + + col2 + - col2 AS col0 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6637
SELECT col2 * col0 DIV + 44 + + tab1.col1 + - ( - col0 ) * col1 AS col1 FROM tab1
----
107
1227
732

skipif mysql # not compatible
query I rowsort label-6637
SELECT col2 * col0 / + 44 + + tab1.col1 + - ( - col0 ) * col1 AS col1 FROM tab1
----
107
1227
732

query I rowsort
SELECT ALL + col2 * + 69 FROM tab2 AS cor0
----
1794
1863
2622

query I rowsort
SELECT ALL - + col2 * - 87 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT ALL + col2 + 59 * col0 FROM tab1 cor0
----
231
3833
4816

query I rowsort
SELECT + - 93 + col0 AS col2 FROM tab1 cor0
----
-13
-29
-90

query I rowsort
SELECT ALL - - ( + col0 ) * - col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 49 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6644
SELECT + ( col1 ) * col1 * + CAST( NULL AS SIGNED ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6644
SELECT + ( col1 ) * col1 * + CAST ( NULL AS INTEGER ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * cor0.col2 * + col1 AS col1 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + ( 91 ) * + col1 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT + 35 * - col1 + + col0 * col1 FROM tab2 AS cor0
----
-868
2537
748

query I rowsort
SELECT ALL + col2 * col0 + col1 FROM tab0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6649
SELECT ALL + col2 - CAST( - 76 + - col2 AS SIGNED ) * 66 AS col1 FROM tab2
----
6758
6825
7562

skipif mysql # not compatible
query I rowsort label-6649
SELECT ALL + col2 - CAST ( - 76 + - col2 AS INTEGER ) * 66 AS col1 FROM tab2
----
6758
6825
7562

query I rowsort
SELECT + 60 * 45 FROM tab2, tab1 AS cor0
----
9 values hashing to ee2c7dd9dc2fb0bca99b57eeb94d7e8c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 44 + col1 col2 FROM tab1 AS cor0
----
54
57
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6652
SELECT ALL - - col0 DIV + col1 + + col2 AS col0 FROM tab1 AS cor0
----
102
54
63

skipif mysql # not compatible
query I rowsort label-6652
SELECT ALL - - col0 / + col1 + + col2 AS col0 FROM tab1 AS cor0
----
102
54
63

query I rowsort
SELECT ALL - col2 * + col1 + + 16 FROM tab0 AS cor0
----
-2822
-7446
-81

query I rowsort
SELECT DISTINCT - ( + col2 ) + col2 * col0 AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + + col2 * + col0 + 8 AS col1 FROM tab0 AS cor0
----
43
7306
800

onlyif mysql # use DIV operator for integer division
query I rowsort label-6656
SELECT ALL - + 10 DIV col2 + col0 AS col0 FROM tab0 cor0
----
24
25
89

skipif mysql # not compatible
query I rowsort label-6656
SELECT ALL - + 10 / col2 + col0 AS col0 FROM tab0 cor0
----
24
25
89

query I rowsort
SELECT ALL + 64 * col0 * col0 AS col1 FROM tab0 AS cor0
----
36864
506944
78400

query I rowsort
SELECT ALL + 86 + - col0 * + col2 FROM tab1 AS cor0
----
-3562
-7594
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 + - col1 * - col2 col2 FROM tab1
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6660
SELECT DISTINCT - col2 DIV 75 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-6660
SELECT DISTINCT - col2 / 75 FROM tab1
----
-1
0

query I rowsort
SELECT cor0.col1 + + col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL 63 + + col2 * - col2 FROM tab2
----
-1381
-613
-666

query I rowsort
SELECT DISTINCT - 51 + col1 AS col2 FROM tab0
----
35
40
46

query I rowsort
SELECT ALL col2 * col1 + col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT ALL col2 * col0 + - col2 * col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL 17 * - col1 - - col0 AS col2 FROM tab1 AS cor0
----
-106
-141
-439

query I rowsort
SELECT DISTINCT - - 30 * col0 + - col2 FROM tab0 cor0
----
1049
2588
687

query I rowsort
SELECT + cor0.col2 * - col1 + - 16 FROM tab0 AS cor0
----
-113
-2854
-7478

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 75 - - col1 col1 FROM tab1 AS cor0
----
-49
-62
-65

query I rowsort
SELECT ALL - + col0 + col0 * ( ( - col0 ) ) AS col2 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT ALL 22 + + col0 FROM tab0 AS cor0
----
111
46
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6672
SELECT DISTINCT + ( + cor0.col1 ) * + CAST( NULL AS SIGNED ) + + col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6672
SELECT DISTINCT + ( + cor0.col1 ) * + CAST ( NULL AS INTEGER ) + + col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL 32 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
1216
832
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-6674
SELECT ALL 51 DIV + col2 AS col1 FROM tab0 AS cor0
----
0
1
51

skipif mysql # not compatible
query I rowsort label-6674
SELECT ALL 51 / + col2 AS col1 FROM tab0 AS cor0
----
0
1
51

query I rowsort
SELECT ALL + + 61 * - col2 + col2 * col0 FROM tab0 cor0
----
-1221
-26
2296

query I rowsort
SELECT + - 94 - cor0.col0 * + 10 FROM tab2 AS cor0
----
-164
-874
-884

query I rowsort
SELECT 83 + - col1 * 89 * + col1 AS col2 FROM tab0 AS cor0
----
-658161
-736926
-837318

query I rowsort
SELECT + col1 * col0 + + col2 + - col0 FROM tab0 AS cor0
----
2073
3361
8092

query I rowsort
SELECT + + col0 + 41 * 82 AS col0 FROM tab1 AS cor0
----
3365
3426
3442

query I rowsort
SELECT ALL col0 * + ( - col2 ) AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6681
SELECT - cor0.col1 DIV + ( 78 ) AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6681
SELECT - cor0.col1 / + ( 78 ) AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * - 22 AS col0 FROM tab1
----
-1188
-1254
-2112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + 64 col0 FROM tab2 AS cor0
----
123
81
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6684
SELECT ALL - - col0 * CAST( + col1 AS SIGNED ) col1 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6684
SELECT ALL - - col0 * CAST ( + col1 AS INTEGER ) col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - + col0 * + col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT + col1 * - 89 FROM tab1 AS cor0
----
-1157
-2314
-890

query I rowsort
SELECT ALL - col2 + col2 * 14 FROM tab2 AS cor0
----
338
351
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - 26 col2 FROM tab2 AS cor0
----
-104
-105
-33

query I rowsort
SELECT col2 * 19 FROM tab2 AS cor0
----
494
513
722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6690
SELECT DISTINCT col1 * CAST( 90 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1170
2340
900

skipif mysql # not compatible
query I rowsort label-6690
SELECT DISTINCT col1 * CAST ( 90 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1170
2340
900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6691
SELECT DISTINCT + + col2 * col1 + col1 * col0 * - CAST( col0 AS SIGNED ) - col2 FROM tab1 AS cor0
----
-40447
-82048
1116

skipif mysql # not compatible
query I rowsort label-6691
SELECT DISTINCT + + col2 * col1 + col1 * col0 * - CAST ( col0 AS INTEGER ) - col2 FROM tab1 AS cor0
----
-40447
-82048
1116

query I rowsort
SELECT ALL cor0.col0 * 12 + - 14 * col2 FROM tab2 AS cor0
----
-294
416
572

query I rowsort
SELECT + 44 * + 76 FROM tab2 AS cor0
----
3344
3344
3344

query I rowsort
SELECT DISTINCT + col2 * 8 FROM tab2 AS cor0
----
208
216
304

onlyif mysql # use DIV operator for integer division
query I rowsort label-6695
SELECT - col0 + + 63 DIV col0 FROM tab2
----
-78
-79
2

skipif mysql # not compatible
query I rowsort label-6695
SELECT - col0 + + 63 / col0 FROM tab2
----
-78
-79
2

query I rowsort
SELECT ALL + col0 * - ( - col2 + col2 ) FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 6 col1 FROM tab2 AS cor0
----
102
186
354

query I rowsort
SELECT 46 * + cor0.col2 FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT col1 + + 3 * + ( tab1.col0 ) FROM tab1
----
202
253
35

query I rowsort
SELECT col2 * + cor0.col1 + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - - 60 FROM tab2 cor0
----
60
60
60

query I rowsort
SELECT - 81 * - col1 AS col1 FROM tab2 AS cor0
----
1377
2511
4779

onlyif mysql # use DIV operator for integer division
query I rowsort label-6703
SELECT cor0.col2 + - col2 DIV + col1 AS col0 FROM tab1 AS cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-6703
SELECT cor0.col2 + - col2 / + col1 AS col0 FROM tab1 AS cor0
----
52
52
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 * + col2 col2 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT col0 + + col1 + col1 AS col1 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT + col2 + + 20 FROM tab1 cor0
----
116
74
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6707
SELECT col1 * + CAST( NULL AS SIGNED ) * - 95 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6707
SELECT col1 * + CAST ( NULL AS INTEGER ) * - 95 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * - 25 + cor0.col1 + col2 AS col2 FROM tab0 AS cor0
----
2269
2448
2523

query I rowsort
SELECT - cor0.col1 + + 76 * - col0 FROM tab1 AS cor0
----
-254
-4874
-6093

query I rowsort
SELECT + col1 * 13 * col0 AS col0 FROM tab1
----
1014
13520
8320

query I rowsort
SELECT DISTINCT + col1 + 27 FROM tab0 AS cor0
----
113
118
124

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6712
SELECT - col1 + CAST( NULL AS SIGNED ) + - cor0.col1 * - col2 * col1 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6712
SELECT - col1 + CAST ( NULL AS INTEGER ) + - cor0.col1 * - col2 * col1 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6713
SELECT - + col2 * + col0 + cor0.col0 DIV - col2 FROM tab1 AS cor0
----
-162
-3649
-7680

skipif mysql # not compatible
query I rowsort label-6713
SELECT - + col2 * + col0 + cor0.col0 / - col2 FROM tab1 AS cor0
----
-162
-3649
-7680

query I rowsort
SELECT DISTINCT ( + col0 ) * col1 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT + 26 + + col0 * - cor0.col0 * - col2 FROM tab2 AS cor0
----
1349
158210
237184

query I rowsort
SELECT cor0.col2 - + cor0.col1 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - - col2 + - col0 - cor0.col1 AS col1 FROM tab2 AS cor0
----
-11
-111
-58

query I rowsort
SELECT + col1 + col1 * + col2 AS col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6719
SELECT CAST( NULL AS SIGNED ) / - col1 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6719
SELECT CAST ( NULL AS INTEGER ) / - col1 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + col1 + - col0 ) * tab2.col2 FROM tab2
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-6721
SELECT - + col2 + + col1 * + col0 DIV col0 FROM tab2 cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-6721
SELECT - + col2 + + col1 * + col0 / col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL - - ( + col0 ) * + col2 + col2 * - cor0.col2 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT ALL - 4 + + col1 FROM tab2 AS cor0
----
13
27
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col1 + + col1 + col0 col0 FROM tab0 cor0
----
7506
8461
9541

query I rowsort
SELECT - + col1 * - cor0.col2 - + col0 * col2 FROM tab2 cor0
----
-2356
-494
648

onlyif mysql # use DIV operator for integer division
query I rowsort label-6726
SELECT ALL col2 DIV col2 + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6726
SELECT ALL col2 / col2 + col0 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6727
SELECT - 1 DIV + col0 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6727
SELECT - 1 / + col0 AS col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6728
SELECT DISTINCT ( col2 ) + col1 DIV + col1 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6728
SELECT DISTINCT ( col2 ) + col1 / + col1 FROM tab0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6729
SELECT col2 DIV tab1.col1 + col0 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-6729
SELECT col2 / tab1.col1 + col0 FROM tab1
----
5
69
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-6730
SELECT - col0 DIV + col0 + - col1 FROM tab0 cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-6730
SELECT - col0 / + col0 + - col1 FROM tab0 cor0
----
-87
-92
-98

query I rowsort
SELECT ALL 22 * + tab2.col2 + col1 AS col1 FROM tab2
----
625
631
853

query I rowsort
SELECT DISTINCT - 56 FROM tab2, tab1 AS cor0
----
-56

query I rowsort
SELECT DISTINCT + ( + ( col2 ) ) * + col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL + 93 FROM tab1 cor0
----
93
93
93

query I rowsort
SELECT DISTINCT 53 * + col1 AS col2 FROM tab2 AS cor0
----
1643
3127
901

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6737
SELECT ALL - col2 DIV - 85 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6737
SELECT ALL - col2 / - 85 AS col2 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6738
SELECT CAST( NULL AS SIGNED ) / col2 - + col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6738
SELECT CAST ( NULL AS INTEGER ) / col2 - + col0 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 67 * col0 FROM tab0
----
1608
2345
5963

query I rowsort
SELECT 89 - col1 FROM tab2
----
30
58
72

query I rowsort
SELECT ALL - col0 - col0 * - col1 FROM tab2
----
1264
210
4524

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( tab1.col1 + + col0 AS REAL ) * col0 / + col0 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT ALL 97 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT 50 * cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 23db6aaea1c3c3760656b9ee76665877

query I rowsort
SELECT - col0 * col2 * col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT ALL ( - 98 ) * col0 FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT col1 * + ( col0 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col2 * col1 + - col0 * + col0 AS col0 FROM tab1
----
-3526
-5152
1395

onlyif mysql # use DIV operator for integer division
query I rowsort label-6749
SELECT ALL - col1 + - col1 DIV - cor0.col0 AS col2 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-6749
SELECT ALL - col1 + - col1 / - cor0.col0 AS col2 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT ALL - + cor0.col1 + - col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT tab1.col2 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL col0 AS col0 FROM tab1 WHERE NOT NULL IN ( + col1 )
----

query I rowsort
SELECT ALL col2 * col1 * + col1 AS col2 FROM tab0 AS cor0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + tab0.col2 * col2 AS col0 FROM tab0 WHERE NOT ( NULL ) <= ( col0 )
----

query I rowsort
SELECT DISTINCT + tab1.col0 * col2 * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT col0 + cor0.col2 * col2 FROM tab1 AS cor0
----
2919
3313
9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 * + col0 col0 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6759
SELECT - col2 DIV col1 + col2 col2 FROM tab2 AS cor0
----
26
27
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6759
SELECT - col2 / col1 + col2 col2 FROM tab2 AS cor0
----
26
27
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * tab1.col2 + - col0 * col1 col0 FROM tab1
----
3008
6640
84

query I rowsort
SELECT DISTINCT col1 - - col2 * cor0.col2 AS col2 FROM tab2 cor0
----
1461
735
760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + cor0.col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - col1 * - col2 - - col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + + col2 + col2 * cor0.col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - - cor0.col1 * col2 FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 * + col0 + col0 + + cor0.col2 col0 FROM tab2 AS cor0
----
-1226
-183
-4498

query I rowsort
SELECT DISTINCT - col1 + - col0 + col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - + col1 - - col2 AS col0 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 * col0 + cor0.col0 * col2 col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - tab1.col1 * + col2 * col1 + col2 FROM tab1
----
-16128
-36450
-5643

query I rowsort
SELECT DISTINCT + col2 * + col1 + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT cor0.col0 + col0 * - col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - cor0.col0 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6774
SELECT DISTINCT + tab2.col2 DIV + col0 + col0 + - col2 AS col2 FROM tab2
----
-17
41
52

skipif mysql # not compatible
query I rowsort label-6774
SELECT DISTINCT + tab2.col2 / + col0 + col0 + - col2 AS col2 FROM tab2
----
-17
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6775
SELECT col1 + + tab2.col1 DIV + col0 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-6775
SELECT col1 + + tab2.col1 / + col0 FROM tab2
----
17
35
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6776
SELECT - cor0.col2 * CAST( - col2 + col1 AS SIGNED ) DIV col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-6776
SELECT - cor0.col2 * CAST ( - col2 + col1 AS INTEGER ) / col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0, tab1 AS cor1, tab0, tab0 cor2
----
3645 values hashing to d24b34b0673c90715a7101e7e630fa94

query I rowsort
SELECT DISTINCT - cor1.col0 * + 6 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-144
-210
-534

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * 3 col1 FROM tab2
----
-21
-234
-237

query I rowsort
SELECT + 94 FROM tab0, tab1 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT ALL - cor0.col1 * - 36 + col1 AS col1 FROM tab0 AS cor0
----
3182
3367
3589

query I rowsort
SELECT DISTINCT col2 * ( col0 ) * col0 FROM tab1 AS cor0
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-6783
SELECT DISTINCT col2 + col1 DIV col2 FROM tab0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-6783
SELECT DISTINCT col2 + col1 / col2 FROM tab0
----
35
83
98

query I rowsort
SELECT ( 98 ) + tab0.col1 * - col2 + - ( - tab0.col1 ) FROM tab0
----
-2654
-7273
98

query I rowsort
SELECT ( col2 ) + cor0.col0 + - 58 FROM tab0 AS cor0
----
-1
-22
113

query I rowsort
SELECT + ( - col0 ) * - col1 + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - tab2.col1 + 26 AS col2 FROM tab2
----
-33
-5
9

query I rowsort
SELECT - tab2.col0 + - 89 AS col0 FROM tab2
----
-167
-168
-96

query I rowsort
SELECT ALL col1 * + 70 FROM tab1
----
1820
700
910

query I rowsort
SELECT 89 * + col0 FROM tab2
----
623
6942
7031

query I rowsort
SELECT ALL + ( 38 ) * - col0 AS col1 FROM tab1 AS cor0
----
-114
-2432
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * - tab1.col2 col0 FROM tab1
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6793
SELECT DISTINCT - - CAST( NULL AS SIGNED ) FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6793
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT + col0 * col0 + col0 AS col0 FROM tab2 cor0
----
56
6162
6320

query I rowsort
SELECT ( col0 ) + - col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 33 + col0 + 51 AS col1 FROM tab1 AS cor0
----
148
164
87

query I rowsort
SELECT ( + col1 ) * + cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + 24 * col2 + + ( col0 ) * col1 * - cor0.col1 FROM tab2 AS cor0
----
-21919
-270894
-6079

query I rowsort
SELECT + + 26 + cor0.col1 FROM tab2 cor0
----
43
57
85

query I rowsort
SELECT ALL + 75 * - col1 AS col0 FROM tab1 AS cor0
----
-1950
-750
-975

query I rowsort
SELECT DISTINCT + - cor0.col0 * col0 + + col2 - 22 AS col2 FROM tab2 AS cor0
----
-44
-6080
-6225

query I rowsort
SELECT ALL - - 76 AS col0 FROM tab2 AS cor0
----
76
76
76

query I rowsort
SELECT - col0 * col0 + col0 FROM tab2 cor0
----
-42
-6006
-6162

query I rowsort
SELECT ALL + cor0.col1 * + 79 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to be59d6d511c65c7f5007b61e1f39866f

query I rowsort
SELECT + + 90 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 97 - + col2 col1 FROM tab1
----
1
40
43

query I rowsort
SELECT + - col2 + - cor0.col0 * 91 AS col1 FROM tab1 AS cor0
----
-327
-5881
-7376

query I rowsort
SELECT + + col2 * - col2 AS col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col1 * 52 + col1 FROM tab1 AS cor0
----
-1326
-510
-663

query I rowsort
SELECT + col2 + 69 * cor0.col2 AS col2 FROM tab1 AS cor0
----
3780
3990
6720

query I rowsort
SELECT ALL + col0 + + 20 + col1 AS col1 FROM tab1 AS cor0
----
113
49
94

query I rowsort
SELECT DISTINCT + + col1 * + 85 * + 6 - col0 AS col1 FROM tab1 AS cor0
----
13257
5036
6550

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6813
SELECT - CAST( + col0 AS SIGNED ) + - col1 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-6813
SELECT - CAST ( + col0 AS INTEGER ) + - col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6814
SELECT + + ( + col2 ) * col2 - + col1 DIV + col2 FROM tab0 AS cor0
----
-96
1087
6723

skipif mysql # not compatible
query I rowsort label-6814
SELECT + + ( + col2 ) * col2 - + col1 / + col2 FROM tab0 AS cor0
----
-96
1087
6723

query I rowsort
SELECT - - cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT 18 + + tab2.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 37b7e91dce281e1457459881844ef3d5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 34 + ( col2 ) * 79 + 48 col0 FROM tab0 AS cor0
----
2621
6492
93

query I rowsort
SELECT ( + 15 ) AS col1 FROM tab2 AS cor0
----
15
15
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 35 - cor0.col2 col1 FROM tab2 AS cor0
----
1058
2039
557

query I rowsort
SELECT - 12 * - col1 * + col2 + col2 + + 68 * + col2 AS col1 FROM tab2 cor0
----
10374
11907
20202

query I rowsort
SELECT ALL + col2 * + col2 * - cor0.col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT - ( col1 * + col1 ) AS col2 FROM tab0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 28 ) col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to eac00a95d734c7071360ed392c3f39bc

onlyif mysql # use DIV operator for integer division
query I rowsort label-6824
SELECT - col2 + - col2 DIV 28 FROM tab1 AS cor0
----
-55
-59
-99

skipif mysql # not compatible
query I rowsort label-6824
SELECT - col2 + - col2 / 28 FROM tab1 AS cor0
----
-55
-59
-99

query I rowsort
SELECT + 94 + col1 AS col1 FROM tab0 AS cor0
----
180
185
191

query I rowsort
SELECT - + 73 * + col2 AS col1 FROM tab2 AS cor0
----
-1898
-1971
-2774

query I rowsort
SELECT DISTINCT + + 44 * + col0 AS col0 FROM tab0 AS cor0
----
1056
1540
3916

query I rowsort
SELECT DISTINCT 93 AS col2 FROM tab2 AS cor0
----
93

query I rowsort
SELECT DISTINCT 65 * - col2 AS col0 FROM tab2 AS cor0
----
-1690
-1755
-2470

query I rowsort
SELECT DISTINCT - 67 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
-67

query I rowsort
SELECT ALL - ( - col1 ) * ( cor0.col1 ) FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * + col2 col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 20 * col1 - - 62 * 36 AS col2 FROM tab1 AS cor0
----
1712
1972
2032

query I rowsort
SELECT DISTINCT col1 + + col2 * - 79 AS col2 FROM tab2 cor0
----
-1995
-2102
-2985

query I rowsort
SELECT - ( + col2 ) + ( col0 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + 17 * col1 + 38 * col1 AS col2 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT DISTINCT - col2 + col1 + 76 FROM tab0 AS cor0
----
129
172
85

query I rowsort
SELECT DISTINCT - - col1 * + col2 + - ( col1 * col2 + + col2 ) AS col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT + + col1 * - cor0.col1 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT 24 AS col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT ( - col1 ) * col2 + ( - 19 + - col0 ) * 76 AS col1 FROM tab0
----
-15670
-4201
-6106

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6842
SELECT - - col1 + CAST( NULL AS SIGNED ) + cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6842
SELECT - - col1 + CAST ( NULL AS INTEGER ) + cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * - ( + cor0.col1 ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + cor0.col0 col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - + col0 * + cor0.col1 + - col0 AS col2 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT ALL - + col2 + ( col2 ) * - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT ALL ( + 12 ) FROM tab1, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT + tab1.col0 * + ( + 63 ) FROM tab1, tab1 AS cor0
----
9 values hashing to eb7f702b26154bcf0db5c9ba3607c9ce

query I rowsort
SELECT col2 + - 65 * col0 * + col2 AS col1 FROM tab1
----
-10476
-237063
-499104

query I rowsort
SELECT col0 * col2 + 61 FROM tab2
----
2089
250
3063

query I rowsort
SELECT + col0 - 11 FROM tab2
----
-4
67
68

query I rowsort
SELECT ALL + 96 + ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
160
176
99

query I rowsort
SELECT - col2 - col0 * col2 * - col1 FROM tab2
----
119626
50996
5832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6854
SELECT col1 + - CAST( + col0 AS SIGNED ) FROM tab0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-6854
SELECT col1 + - CAST ( + col0 AS INTEGER ) FROM tab0
----
2
62
62

query I rowsort
SELECT col1 + - 96 * + col2 FROM tab2 AS cor0
----
-2437
-2561
-3631

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6856
SELECT - CAST( 60 AS SIGNED ) FROM tab0 AS cor0
----
-60
-60
-60

skipif mysql # not compatible
query I rowsort label-6856
SELECT - CAST ( 60 AS INTEGER ) FROM tab0 AS cor0
----
-60
-60
-60

query I rowsort
SELECT + col2 + col1 + + col0 FROM tab1 AS cor0
----
131
189
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6858
SELECT DISTINCT + + ( + ( + col0 ) ) + + CAST( + 84 AS SIGNED ) FROM tab1 AS cor0
----
148
164
87

skipif mysql # not compatible
query I rowsort label-6858
SELECT DISTINCT + + ( + ( + col0 ) ) + + CAST ( + 84 AS INTEGER ) FROM tab1 AS cor0
----
148
164
87

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( ( col0 ) AS REAL ) + col0 * col0 * - col0 AS col0 FROM tab2 AS cor0
----
-336
-474474
-492960

query I rowsort
SELECT DISTINCT tab0.col1 * 39 FROM tab0
----
3354
3549
3783

query I rowsort
SELECT ALL 32 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT ALL 66 * 92 FROM tab2
----
6072
6072
6072

query I rowsort
SELECT - + 8 * col1 AS col1 FROM tab2 AS cor0
----
-136
-248
-472

query I rowsort
SELECT DISTINCT + 60 + 44 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1084
-1128
-1612

query I rowsort
SELECT + - cor0.col1 * cor0.col2 * - cor0.col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT DISTINCT - - ( col0 ) + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + col2 * + 93 AS col2 FROM tab2 AS cor0
----
2418
2511
3534

query I rowsort
SELECT DISTINCT 16 * col2 FROM tab2 AS cor0
----
416
432
608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + - col2 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - 45 * - 78 + col1 AS col1 FROM tab2 AS cor0
----
-3451
-3479
-3493

query I rowsort
SELECT DISTINCT + ( col1 ) + + col1 AS col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT - + 68 * + col1 + col1 FROM tab0 AS cor0
----
-5762
-6097
-6499

query I rowsort
SELECT ALL + col2 * - col1 + + col1 AS col2 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT ALL col0 - - col2 * - 66 * - tab0.col1 FROM tab0
----
187332
492581
6437

query I rowsort
SELECT DISTINCT + - 14 * col2 * col2 + col2 AS col2 FROM tab0 cor0
----
-13
-15213
-94054

query I rowsort
SELECT - col0 + tab2.col2 + 20 FROM tab2
----
-21
-32
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-6877
SELECT - col0 + - col0 DIV tab0.col2 FROM tab0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-6877
SELECT - col0 + - col0 / tab0.col2 FROM tab0
----
-24
-70
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6878
SELECT ALL 56 + + col1 DIV + 93 FROM tab1
----
56
56
56

skipif mysql # not compatible
query I rowsort label-6878
SELECT ALL 56 + + col1 / + 93 FROM tab1
----
56
56
56

query I rowsort
SELECT ALL + col0 * - col1 + col2 FROM tab1 cor0
----
-24
-583
-944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6880
SELECT ALL - + cor0.col2 + + CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-6880
SELECT ALL - + cor0.col2 + + CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + col0 + ( - col0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col1 + - ( + col1 ) AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6883
SELECT + col0 * + CAST( NULL AS SIGNED ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6883
SELECT + col0 * + CAST ( NULL AS INTEGER ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + 16 FROM tab1 cor0
----
-10
3
6

query I rowsort
SELECT ALL col2 + col0 - col1 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT ALL + col1 * 63 + - 37 + col2 FROM tab0 AS cor0
----
5414
5778
6075

query I rowsort
SELECT ALL + col0 + 42 FROM tab0 AS cor0
----
131
66
77

query I rowsort
SELECT - col0 * - col1 + - 92 FROM tab1 cor0
----
-14
548
948

query I rowsort
SELECT DISTINCT - col2 + + 39 * 40 + col0 FROM tab1 AS cor0
----
1509
1544
1567

query I rowsort
SELECT - + col1 * - 14 + + col1 AS col0 FROM tab1 AS cor0
----
150
195
390

query I rowsort
SELECT DISTINCT - col0 * + col1 * + cor0.col0 + col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-118824
-48447
-714087

onlyif mysql # use DIV operator for integer division
query I rowsort label-6892
SELECT DISTINCT - - cor0.col2 * - CAST( 18 AS SIGNED ) + - col0 DIV - col1 - col1 FROM tab0 AS cor0
----
-115
-1567
-680

skipif mysql # not compatible
query I rowsort label-6892
SELECT DISTINCT - - cor0.col2 * - CAST ( 18 AS INTEGER ) + - col0 / - col1 - col1 FROM tab0 AS cor0
----
-115
-1567
-680

query I rowsort
SELECT ALL + + col1 * - 17 + - col1 * + col2 FROM tab1 AS cor0
----
-1469
-1846
-740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6894
SELECT DISTINCT + col0 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6894
SELECT DISTINCT + col0 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 * col0 - cor0.col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT - col0 * - col2 + + cor0.col2 AS col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - cor0.col1 * 81 AS col1 FROM tab0 AS cor0
----
-6966
-7371
-7857

query I rowsort
SELECT - 92 + - col0 FROM tab0 cor0
----
-116
-127
-181

query I rowsort
SELECT col0 * col1 + ( - col2 ) * - col2 AS col2 FROM tab2 AS cor0
----
2787
5278
946

query I rowsort
SELECT - + col2 + - col0 * - col1 * col2 AS col1 FROM tab0 AS cor0
----
3394
664036
68079

query I rowsort
SELECT ALL tab1.col0 + 81 + 3 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to d3e7cd01dcd7d17906ca81f6a9d1475f

query I rowsort
SELECT + + col2 + - col1 * - cor0.col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL col1 * col0 * + 46 FROM tab0
----
156170
372554
94944

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT cor0.col1 * - 8 + 22 FROM tab0, tab1 AS cor0
----
9 values hashing to 45f66323c6bb8caea9da7d4e45215204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col0 * + col2 col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL + col2 + col2 - tab1.col0 FROM tab1
----
105
112
50

query I rowsort
SELECT tab1.col1 * + col1 FROM tab1 WHERE col1 - col1 >= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - tab1.col1 * + col0 col1 FROM tab1
----
36480
4212
99840

query III rowsort
SELECT * FROM tab2 WHERE NOT + col0 - tab2.col2 * + col1 = ( NULL )
----

query I rowsort
SELECT + col2 * col2 + col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT ALL col2 + - col2 + col1 * - col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + col0 * - col1 + col1 * - col1 + col0 AS col0 FROM tab0
----
-12769
-16291
-9436

query I rowsort
SELECT tab2.col0 * col0 * - tab2.col1 AS col0 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT + col2 * - col2 + - col1 AS col1 FROM tab1
----
-2942
-3259
-9229

query I rowsort
SELECT DISTINCT + col1 + - col0 + + col1 FROM tab1
----
-44
-54
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-6917
SELECT ALL - col0 + col0 - col0 DIV col2 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-6917
SELECT ALL - col0 + col0 - col0 / col2 FROM tab0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6918
SELECT + col2 DIV + col1 + col2 FROM tab1
----
103
56
62

skipif mysql # not compatible
query I rowsort label-6918
SELECT + col2 / + col1 + col2 FROM tab1
----
103
56
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 + + col2 + col1 * + col0 * - col0 col0 FROM tab0
----
-118789
-49479
-720640

query I rowsort
SELECT ALL + col1 + col0 + + col1 * + col2 AS col2 FROM tab1
----
1341
1433
644

query I rowsort
SELECT ALL col2 * - col0 + - col0 * - col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL col0 AS col0 FROM tab2 WHERE NULL NOT IN ( col0 * col1 )
----

query I rowsort
SELECT + tab1.col2 * + col1 + tab1.col0 * + col0 AS col2 FROM tab1
----
1413
4666
7648

onlyif mysql # use DIV operator for integer division
query I rowsort label-6924
SELECT ALL + col1 + - col0 DIV col0 col0 FROM tab2
----
16
30
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6924
SELECT ALL + col1 + - col0 / col0 col0 FROM tab2
----
16
30
58

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 * col0 <> ( col2 / col2 + + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6926
SELECT ALL + col1 + - col2 DIV - col2 AS col0 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6926
SELECT ALL + col1 + - col2 / - col2 AS col0 FROM tab0
----
87
92
98

query I rowsort
SELECT + col1 - - col1 AS col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT col1 + tab0.col2 * - tab0.col2 AS col0 FROM tab0
----
-1003
-6633
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 88 col2 FROM tab2
----
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6930
SELECT DISTINCT + cor0.col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6930
SELECT DISTINCT + cor0.col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
1

query I rowsort
SELECT ALL - 33 * + cor0.col1 + 49 AS col1 FROM tab1 AS cor0
----
-281
-380
-809

onlyif mysql # use DIV operator for integer division
query I rowsort label-6932
SELECT + col0 + col0 DIV 82 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-6932
SELECT + col0 + col0 / 82 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 55 * col2 col1 FROM tab1 AS cor0
----
2970
3135
5280

query I rowsort
SELECT ALL col0 - ( - col0 ) AS col2 FROM tab1
----
128
160
6

query I rowsort
SELECT 88 * tab1.col2 AS col0 FROM tab1
----
4752
5016
8448

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( ( col0 ) ) col0 FROM tab1
----
3
64
80

query I rowsort
SELECT + - col0 * - cor0.col1 + - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + - col0 * - col0 * ( - col0 ) + + col1 * col1 FROM tab1 AS cor0
----
-262044
-511831
649

query I rowsort
SELECT 99 + - col0 + ( + col1 ) AS col1 FROM tab2 AS cor0
----
123
37
80

query I rowsort
SELECT - 56 + + col0 FROM tab1 AS cor0
----
-53
24
8

query I rowsort
SELECT - col0 + cor0.col0 * - col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT col2 * + col0 + 62 AS col1 FROM tab2 AS cor0
----
2090
251
3064

query I rowsort
SELECT ALL + col0 * + ( col2 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT - col1 * 69 + + col0 AS col0 FROM tab0 cor0
----
-5910
-6190
-6658

query I rowsort
SELECT + cor0.col2 * - 97 AS col2 FROM tab0 cor0
----
-3201
-7954
-97

query I rowsort
SELECT col0 - + tab1.col2 AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT + 51 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 95 ) col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

query I rowsort
SELECT ALL - - col2 + + col2 * col2 * col0 AS col1 FROM tab1 cor0
----
207993
737376
8802

query I rowsort
SELECT DISTINCT - col0 + - cor0.col2 * - 54 * col0 FROM tab2 AS cor0
----
10199
109434
162029

query I rowsort
SELECT - cor0.col2 * + 69 FROM tab1 AS cor0
----
-3726
-3933
-6624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + col2 col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT col2 * col0 - + 54 FROM tab2
----
135
1974
2948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6954
SELECT - 10 + - col2 * - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6954
SELECT - 10 + - col2 * - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * 1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + col2 * + ( - 27 * col0 ) AS col0 FROM tab1 cor0
----
-207360
-4374
-98496

query I rowsort
SELECT ALL + col2 + 48 AS col2 FROM tab2 AS cor0
----
74
75
86

query I rowsort
SELECT ALL + + col2 * col0 + - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6959
SELECT ALL tab2.col0 DIV col1 AS col2 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6959
SELECT ALL tab2.col0 / col1 AS col2 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL - - cor0.col2 - ( - cor0.col0 + cor0.col2 ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col0 * 95 FROM tab1 cor0
----
285
6080
7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6962
SELECT DISTINCT + col2 * + CAST( col0 AS SIGNED ) FROM tab0 cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-6962
SELECT DISTINCT + col2 * + CAST ( col0 AS INTEGER ) FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 + col0 * - 82 AS col2 FROM tab1 AS cor0
----
-192
-5191
-6464

query I rowsort
SELECT DISTINCT - col1 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - ( col0 ) col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col0 * 17 FROM tab2 AS cor0
----
119
1326
1343

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6967
SELECT ALL - col0 * CAST( + col0 AS SIGNED ) + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

skipif mysql # not compatible
query I rowsort label-6967
SELECT ALL - col0 * CAST ( + col0 AS INTEGER ) + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + + col1 * + col0 + + ( col0 ) * ( - col1 + col1 ) FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6969
SELECT ALL CAST( + 38 AS SIGNED ) + col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6969
SELECT ALL CAST ( + 38 AS INTEGER ) + col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 22 - + tab0.col2 * col2 col0 FROM tab0
----
-1067
-6702
21

query I rowsort
SELECT DISTINCT + 28 + - col2 FROM tab1 AS cor0
----
-26
-29
-68

query I rowsort
SELECT - 28 + col1 * - col0 FROM tab1 AS cor0
----
-106
-1068
-668

query I rowsort
SELECT ALL + col2 * + 85 AS col1 FROM tab0 AS cor0
----
2805
6970
85

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6975
SELECT DISTINCT 3 DIV col2 - - col1 FROM tab0 AS cor0
----
100
86
91

skipif mysql # not compatible
query I rowsort label-6975
SELECT DISTINCT 3 / col2 - - col1 FROM tab0 AS cor0
----
100
86
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6976
SELECT ALL + - CAST( - col1 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-6976
SELECT ALL + - CAST ( - col1 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + + col1 + cor0.col1 * + col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT + - ( + col2 ) + - col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - + 75 + col2 FROM tab1 AS cor0
----
-18
-21
21

query I rowsort
SELECT ALL - col1 - - col0 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - + 24 * col1 * col0 + - 36 AS col0 FROM tab0 AS cor0
----
-194412
-49572
-81516

query I rowsort
SELECT ALL - ( - 50 ) * cor1.col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 3d04c0f6e95c0ec18ecf33c832a7dcd5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6983
SELECT ALL 39 DIV - cor0.col0 col2 FROM tab0 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6983
SELECT ALL 39 / - cor0.col0 col2 FROM tab0 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col0 ) * col1 col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 30 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT DISTINCT - + 44 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-44

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - - 64 + - col0 * col2 * cor0.col2 FROM tab1 AS cor0
----
-207872
-737216
-8684

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col2 - 66 col2 FROM tab1 AS cor0
----
126
42
48

query I rowsort
SELECT + 38 * col0 + 98 * + col0 * col1 AS col2 FROM tab0 AS cor0
----
203184
334040
797084

query I rowsort
SELECT ALL - col1 * + col0 + 50 AS col2 FROM tab0 cor0
----
-2014
-3345
-8049

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 * + col1 col1 FROM tab1 AS cor0
----
1235
2470
950

onlyif mysql # use DIV operator for integer division
query I rowsort label-6993
SELECT col1 DIV + col0 + col2 * col2 AS col1 FROM tab0 AS cor0
----
1092
3
6725

skipif mysql # not compatible
query I rowsort label-6993
SELECT col1 / + col0 + col2 * col2 AS col1 FROM tab0 AS cor0
----
1092
3
6725

query I rowsort
SELECT + col1 + + 59 AS col0 FROM tab1 AS cor0
----
69
72
85

query I rowsort
SELECT ALL - 6 + 43 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 71 col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6997
SELECT DISTINCT CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6997
SELECT DISTINCT CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - - col0 * - col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT DISTINCT - 71 * col2 FROM tab0 AS cor0
----
-2343
-5822
-71

query I rowsort
SELECT + ( cor0.col2 ) * col0 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - cor0.col2 - + 16 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
-17
-49
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7002
SELECT - ( tab0.col0 ) DIV - col0 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7002
SELECT - ( tab0.col0 ) / - col0 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL 40 + + col2 * col1 FROM tab0
----
137
2878
7502

query I rowsort
SELECT 79 * + col0 AS col0 FROM tab0
----
1896
2765
7031

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 32 col2 FROM tab0 AS cor0
----
-32
-32
-32

query I rowsort
SELECT ALL - cor0.col2 * + ( - col2 ) AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT tab0.col0 + cor0.col2 * cor0.col0 * cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 818a31719c2181879d19b6ffdaa933aa

query I rowsort
SELECT tab0.col0 * 89 FROM tab0
----
2136
3115
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-7009
SELECT + ( col0 ) DIV col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7009
SELECT + ( col0 ) / col1 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL - col1 * + col2 + 99 AS col1 FROM tab1 AS cor0
----
-1149
-1305
-471

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 40 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + 43 col2 FROM tab2 AS cor0
----
-35
-36
36

query I rowsort
SELECT - col1 * col1 + + 81 AS col1 FROM tab1 cor0
----
-19
-595
-88

query I rowsort
SELECT - - cor0.col2 * ( + col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col0 + - col1 * col0 * + tab1.col2 + tab1.col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - + col1 * col2 + - cor0.col0 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-7017
SELECT col1 DIV - 58 + - col0 col2 FROM tab0 AS cor0
----
-25
-36
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7017
SELECT col1 / - 58 + - col0 col2 FROM tab0 AS cor0
----
-25
-36
-90

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab2 cor1, tab2 AS cor2
----
972 values hashing to 958533d1a7bf61199ed7c03eadf37f9a

query I rowsort
SELECT 30 * col0 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT DISTINCT - + 64 * col0 + - col0 - col2 AS col2 FROM tab2 AS cor0
----
-482
-5096
-5173

query I rowsort
SELECT + - 33 AS col2 FROM tab2 AS cor0
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 26 col1 FROM tab1 cor0
----
-26
-26
-26

query I rowsort
SELECT - col0 - ( 8 ) AS col0 FROM tab1 AS cor0
----
-11
-72
-88

query I rowsort
SELECT - - col0 * 65 + col0 FROM tab2 AS cor0
----
462
5148
5214

query I rowsort
SELECT DISTINCT 39 * tab2.col1 AS col0 FROM tab2
----
1209
2301
663

query I rowsort
SELECT ALL ( - col1 ) * col0 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL - tab1.col1 + col1 * - 13 AS col2 FROM tab1
----
-140
-182
-364

query I rowsort
SELECT DISTINCT + 31 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 * col1 col0 FROM tab2
----
306
3540
992

query I rowsort
SELECT ALL - col1 + col1 * - ( 37 ) + col2 FROM tab1
----
-323
-398
-934

query I rowsort
SELECT ALL 81 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT - col0 * - ( col0 * col1 ) AS col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT + - col0 * ( - col2 ) FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT + col0 DIV ( + col0 * - col0 ) AS col1 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7034
SELECT + col0 / ( + col0 * - col0 ) AS col1 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - + cor0.col2 * - CAST ( - col1 AS REAL ) * - cor0.col1 col0 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-7036
SELECT ALL + + col0 DIV 6 col1 FROM tab0 cor0
----
14
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7036
SELECT ALL + + col0 / 6 col1 FROM tab0 cor0
----
14
4
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7037
SELECT + col2 * 93 DIV cor0.col0 AS col2 FROM tab0 AS cor0
----
127
2
85

skipif mysql # not compatible
query I rowsort label-7037
SELECT + col2 * 93 / cor0.col0 AS col2 FROM tab0 AS cor0
----
127
2
85

query I rowsort
SELECT DISTINCT tab2.col0 * + 48 FROM tab2
----
336
3744
3792

skipif mysql # not compatible
query I rowsort
SELECT - col0 * CAST ( - col0 AS REAL ) AS col1 FROM tab1
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7040
SELECT - col0 DIV 35 AS col1 FROM tab1
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-7040
SELECT - col0 / 35 AS col1 FROM tab1
----
-1
-2
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7041
SELECT + 17 * col2 + col0 DIV 30 FROM tab2 cor0
----
444
459
648

skipif mysql # not compatible
query I rowsort label-7041
SELECT + 17 * col2 + col0 / 30 FROM tab2 cor0
----
444
459
648

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( - col0 ) + - col2 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7043
SELECT - - CAST( NULL AS DECIMAL ) + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7043
SELECT - - CAST ( NULL AS REAL ) + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 13 * + col1 + + col2 FROM tab0 AS cor0
----
1151
1262
1265

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col1 ) + + col2 col0 FROM tab1 cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7046
SELECT ALL + col0 DIV + 33 + - col0 * col0 - + 68 * - ( col0 ) FROM tab0
----
-1867
1056
1156

skipif mysql # not compatible
query I rowsort label-7046
SELECT ALL + col0 / + 33 + - col0 * col0 - + 68 * - ( col0 ) FROM tab0
----
-1867
1056
1156

onlyif mysql # use DIV operator for integer division
query I rowsort label-7047
SELECT ALL col1 - 57 DIV 20 FROM tab0
----
84
89
95

skipif mysql # not compatible
query I rowsort label-7047
SELECT ALL col1 - 57 / 20 FROM tab0
----
84
89
95

query I rowsort
SELECT DISTINCT col2 * + ( + col1 ) FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7049
SELECT + 80 DIV col2 AS col2 FROM tab0 AS cor0
----
0
2
80

skipif mysql # not compatible
query I rowsort label-7049
SELECT + 80 / col2 AS col2 FROM tab0 AS cor0
----
0
2
80

query I rowsort
SELECT 0 + - cor0.col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT cor0.col2 + col2 * col2 FROM tab2 cor0
----
1482
702
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 3 col2 FROM tab2 AS cor0
----
-3
-3
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 87 col2 FROM tab1
----
87

query I rowsort
SELECT ALL - 10 * + tab2.col1 FROM tab2
----
-170
-310
-590

query I rowsort
SELECT DISTINCT - ( tab1.col0 * tab1.col1 ) FROM tab1, tab0 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - ( - 37 ) + + col2 FROM tab2 AS cor0
----
-10
-11
1

query I rowsort
SELECT 17 + col2 AS col1 FROM tab1 AS cor0
----
113
71
74

query I rowsort
SELECT + col2 * + col2 * ( col1 + - ( 82 ) ) AS col0 FROM tab2
----
-15548
-37179
-93860

query I rowsort
SELECT DISTINCT + 64 * col2 AS col0 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT DISTINCT - col1 * col1 + tab0.col2 AS col2 FROM tab0
----
-7363
-8199
-9408

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7061
SELECT ALL + CAST( - col1 AS SIGNED ) * col0 + col1 AS col2 FROM tab0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-7061
SELECT ALL + CAST ( - col1 AS INTEGER ) * col0 + col1 AS col2 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - col2 * col1 * - col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT + ( + 44 ) * col2 AS col1 FROM tab2 cor0
----
1144
1188
1672

onlyif mysql # use DIV operator for integer division
query I rowsort label-7064
SELECT ALL ( - col0 ) * col0 + + 74 * 78 DIV cor0.col2 FROM tab0 AS cor0
----
-402
-7851
4547

skipif mysql # not compatible
query I rowsort label-7064
SELECT ALL ( - col0 ) * col0 + + 74 * 78 / cor0.col2 FROM tab0 AS cor0
----
-402
-7851
4547

query I rowsort
SELECT DISTINCT + ( 12 ) FROM tab1 AS cor0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 * col2 col0 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT + - cor0.col0 + + col1 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT DISTINCT 54 * + col1 AS col2 FROM tab2 AS cor0
----
1674
3186
918

query I rowsort
SELECT 97 * - 86 FROM tab0 AS cor0
----
-8342
-8342
-8342

query I rowsort
SELECT tab2.col0 * + cor0.col2 * - 22 FROM tab2, tab0 AS cor0
----
9 values hashing to 3c05c3e5b34278f97ae7ffe640d5b68b

query I rowsort
SELECT + 95 + col0 FROM tab0 AS cor0
----
119
130
184

query I rowsort
SELECT DISTINCT - ( + col1 * + col1 ) FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ALL + col0 + + col0 + ( col2 ) FROM tab2
----
182
196
41

query I rowsort
SELECT DISTINCT + col2 + ( + col1 + + col2 ) AS col2 FROM tab0
----
152
255
99

query I rowsort
SELECT DISTINCT - tab1.col0 + ( col2 + col0 ) FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col1 FROM tab1, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # use DIV operator for integer division
query I rowsort label-7077
SELECT ALL + col1 DIV - col0 - + cor0.col0 FROM tab2 AS cor0
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-7077
SELECT ALL + col1 / - col0 - + cor0.col0 FROM tab2 AS cor0
----
-11
-78
-79

query I rowsort
SELECT - - col1 - cor0.col1 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7079
SELECT - col1 DIV ( + 4 ) + + col0 FROM tab2 AS cor0
----
0
64
75

skipif mysql # not compatible
query I rowsort label-7079
SELECT - col1 / ( + 4 ) + + col0 FROM tab2 AS cor0
----
0
64
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7080
SELECT ALL col0 + CAST( NULL AS SIGNED ) * - cor0.col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7080
SELECT ALL col0 + CAST ( NULL AS INTEGER ) * - cor0.col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + + col1 * ( col0 ) FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - col0 * + 52 * cor0.col2 + - col2 AS col0 FROM tab2 AS cor0
----
-105482
-156142
-9855

query I rowsort
SELECT DISTINCT - col0 * 77 + col2 * cor0.col1 + col1 AS col1 FROM tab1 AS cor0
----
-4348
-4899
1199

query I rowsort
SELECT ALL + + col1 - + col1 * - col1 FROM tab0 cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + col0 + - ( + tab2.col2 ) * + col1 AS col2 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT cor0.col0 + col2 + + cor0.col1 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT ALL + col1 * 23 AS col2 FROM tab0 cor0
----
1978
2093
2231

query I rowsort
SELECT ALL - + col2 * 15 - 21 * + col0 FROM tab1 cor0
----
-2199
-3120
-873

onlyif mysql # use DIV operator for integer division
query I rowsort label-7089
SELECT DISTINCT - + col2 DIV + col2 + col1 AS col0 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-7089
SELECT DISTINCT - + col2 / + col2 + col1 AS col0 FROM tab1 AS cor0
----
12
25
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7090
SELECT DISTINCT + col2 * CAST( + 87 AS SIGNED ) * + col1 + 67 * col0 AS col0 FROM tab0 AS cor0
----
10784
248514
655157

skipif mysql # not compatible
query I rowsort label-7090
SELECT DISTINCT + col2 * CAST ( + 87 AS INTEGER ) * + col1 + 67 * col0 AS col0 FROM tab0 AS cor0
----
10784
248514
655157

query I rowsort
SELECT + - cor0.col0 * 27 - - col0 AS col1 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT DISTINCT - col2 * 9 + - ( - col1 ) FROM tab0 AS cor0
----
-211
-647
88

query I rowsort
SELECT + col0 + col2 * 6 + col0 AS col0 FROM tab2 AS cor0
----
176
312
386

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7094
SELECT DISTINCT + col2 / CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7094
SELECT DISTINCT + col2 / CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( ( + col2 ) ) AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL 22 * + col1 + col0 FROM tab1 AS cor0
----
284
366
575

query I rowsort
SELECT + 87 FROM tab0, tab0 cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to 969f31ae779866644763e8a07f1ec501

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7098
SELECT - - CAST( NULL AS SIGNED ) * - 54 + + col1 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7098
SELECT - - CAST ( NULL AS INTEGER ) * - 54 + + col1 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * col0 + col2 col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - col1 + + col1 * - col2 * 85 FROM tab2 cor0
----
-130449
-54927
-71176

query I rowsort
SELECT + + col0 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7102
SELECT DISTINCT - col0 + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7102
SELECT DISTINCT - col0 + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 91 + col1 AS col0 FROM tab1 AS cor0
----
101
104
117

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7104
SELECT DISTINCT ( - col2 ) * - CAST( NULL AS DECIMAL ) * 82 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7104
SELECT DISTINCT ( - col2 ) * - CAST ( NULL AS REAL ) * 82 FROM tab2 cor0
----
NULL

query I rowsort
SELECT 41 + col1 * - cor0.col2 AS col1 FROM tab0 cor0
----
-2797
-56
-7421

query I rowsort
SELECT ALL + - col2 * - col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT col1 * + col0 + + col2 * - ( col0 ) FROM tab0 cor0
----
1272
3360
801

query I rowsort
SELECT + + 57 + - col0 FROM tab2 AS cor0
----
-21
-22
50

query I rowsort
SELECT ALL + col2 * col2 + ( col2 ) AS col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT - 8 + - col1 AS col0 FROM tab1 AS cor0
----
-18
-21
-34

query I rowsort
SELECT ALL - col1 * - tab2.col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL cor0.col2 + + 91 AS col1 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT DISTINCT col1 * + col1 + 11 FROM tab0 AS cor0
----
7407
8292
9420

query I rowsort
SELECT DISTINCT - - col2 + ( - col1 ) * + col2 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL + + col0 - 53 AS col0 FROM tab1 AS cor0
----
-50
11
27

query I rowsort
SELECT - ( - col1 ) * 6 + col1 * col2 FROM tab1
----
1326
1560
630

query I rowsort
SELECT DISTINCT col2 + + col2 * col2 * + col2 AS col1 FROM tab1
----
157518
185250
884832

onlyif mysql # use DIV operator for integer division
query I rowsort label-7118
SELECT col2 * col1 + - col2 - col2 DIV cor0.col2 FROM tab1 AS cor0
----
1151
1349
512

skipif mysql # not compatible
query I rowsort label-7118
SELECT col2 * col1 + - col2 - col2 / cor0.col2 FROM tab1 AS cor0
----
1151
1349
512

query I rowsort
SELECT - cor0.col1 + col1 - col1 FROM tab2 cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) * - col2 col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL 88 FROM tab2, tab0, tab2 cor0
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT ALL - 96 * - col0 FROM tab0
----
2304
3360
8544

query I rowsort
SELECT 28 * col0 FROM tab0
----
2492
672
980

query I rowsort
SELECT ( col0 + col2 ) AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT + - col2 * + col2 + ( col1 ) AS col0 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT + - 27 + - col1 * - ( + 5 * col1 ) AS col2 FROM tab2 cor0
----
1418
17378
4778

query I rowsort
SELECT DISTINCT - - col0 * 76 + 94 AS col2 FROM tab1 AS cor0
----
322
4958
6174

query I rowsort
SELECT ALL col0 * + 92 + 18 * - col0 * col0 AS col2 FROM tab1 cor0
----
-107840
-67840
114

onlyif mysql # use DIV operator for integer division
query I rowsort label-7129
SELECT DISTINCT + 11 DIV 53 FROM tab2, tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7129
SELECT DISTINCT + 11 / 53 FROM tab2, tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7130
SELECT CAST( NULL AS DECIMAL ) + - 25 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7130
SELECT CAST ( NULL AS REAL ) + - 25 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 37 * - ( cor0.col2 ) AS col2 FROM tab2 AS cor0
----
1406
962
999

query I rowsort
SELECT DISTINCT + ( 54 ) + - cor0.col0 * - col0 FROM tab2 AS cor0
----
103
6138
6295

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + col1 ) + cor0.col2 + col1 col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT col0 * ( + col1 + - cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT ALL 57 * tab0.col2 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 1d6306f216c759692cd9a50966ae3340

query I rowsort
SELECT - ( 58 ) AS col0 FROM tab2 cor0
----
-58
-58
-58

query I rowsort
SELECT - ( 91 ) * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT + col2 + col1 * col2 * col2 AS col1 FROM tab0 AS cor0
----
611966
93687
98

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-7140
SELECT - cor0.col0 DIV - 60 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-7140
SELECT - cor0.col0 / - 60 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

query I rowsort
SELECT ALL + 23 + + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
123
192
699

query I rowsort
SELECT DISTINCT col0 + + col0 - 42 FROM tab1 AS cor0
----
-36
118
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7143
SELECT ALL - col1 + + col2 DIV 38 col1 FROM tab2 AS cor0
----
-16
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7143
SELECT ALL - col1 + + col2 / 38 col1 FROM tab2 AS cor0
----
-16
-31
-59

query I rowsort
SELECT - + cor0.col2 * col1 + + 56 AS col2 FROM tab0 cor0
----
-2782
-41
-7406

query I rowsort
SELECT DISTINCT col0 * - cor0.col1 - + col1 * col2 AS col2 FROM tab0 AS cor0
----
-15561
-3492
-4902

query I rowsort
SELECT ALL col1 + + col0 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7147
SELECT - CAST( tab1.col0 AS SIGNED ) AS col0 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-7147
SELECT - CAST ( tab1.col0 AS INTEGER ) AS col0 FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7148
SELECT DISTINCT + col2 DIV - tab1.col2 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-7148
SELECT DISTINCT + col2 / - tab1.col2 FROM tab1
----
-1

query I rowsort
SELECT ALL cor0.col1 * - 41 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d8d3c8bc31e7ffec49a89a0fb4650100

query I rowsort
SELECT ALL 72 * col1 FROM tab1
----
1872
720
936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7151
SELECT DISTINCT + ( - ( tab1.col2 ) * CAST( - col2 AS SIGNED ) ) FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-7151
SELECT DISTINCT + ( - ( tab1.col2 ) * CAST ( - col2 AS INTEGER ) ) FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - cor0.col2 * - col0 + - col1 * + col1 FROM tab2 AS cor0
----
-1453
-772
2713

onlyif mysql # use DIV operator for integer division
query I rowsort label-7153
SELECT + col2 DIV + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7153
SELECT + col2 / + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT col0 * ( - col0 ) + + col2 AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT - col2 * 54 AS col0 FROM tab0 AS cor0
----
-1782
-4428
-54

query I rowsort
SELECT col0 * 74 + col2 FROM tab2 AS cor0
----
545
5798
5884

query I rowsort
SELECT col1 + + cor0.col2 * 73 FROM tab1 AS cor0
----
3968
4171
7021

query I rowsort
SELECT + col1 * + ( col1 ) FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + 89 AS col0 FROM tab2, tab0, tab2 AS cor0
----
89

query I rowsort
SELECT DISTINCT + cor0.col1 - - col1 * cor0.col0 * ( + col1 ) AS col1 FROM tab1 AS cor0
----
13533
2054
6410

query I rowsort
SELECT DISTINCT 87 + + col0 AS col2 FROM tab2 AS cor0
----
165
166
94

query I rowsort
SELECT DISTINCT + col0 + 26 + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1238
-184
-4498

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7163
SELECT + cor0.col0 * + CAST( + ( col0 ) AS SIGNED ) + col1 * - col0 FROM tab1 cor0
----
-69
3456
5360

skipif mysql # not compatible
query I rowsort label-7163
SELECT + cor0.col0 * + CAST ( + ( col0 ) AS INTEGER ) + col1 * - col0 FROM tab1 cor0
----
-69
3456
5360

query I rowsort
SELECT ALL + col2 + - ( - ( col0 ) ) * - 71 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
13446
144014
213180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7165
SELECT tab0.col2 * CAST( col1 AS SIGNED ) AS col0 FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-7165
SELECT tab0.col2 * CAST ( col1 AS INTEGER ) AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col0 + - 21 AS col0 FROM tab0
----
-110
-45
-56

query I rowsort
SELECT col1 - 21 AS col0 FROM tab1 AS cor0
----
-11
-8
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7168
SELECT + col2 + CAST( NULL AS SIGNED ) + 12 * + col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7168
SELECT + col2 + CAST ( NULL AS INTEGER ) + 12 * + col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + 53 FROM tab1 AS cor0
----
107
110
149

query I rowsort
SELECT col2 * ( 61 ) * cor0.col0 + - ( + col0 ) * + cor0.col2 + - 85 * - 44 FROM tab2 AS cor0
----
125420
15080
183860

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7171
SELECT ALL - CAST( - 82 AS SIGNED ) FROM tab2 AS cor0
----
82
82
82

skipif mysql # not compatible
query I rowsort label-7171
SELECT ALL - CAST ( - 82 AS INTEGER ) FROM tab2 AS cor0
----
82
82
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7172
SELECT DISTINCT - ( + col1 ) DIV + col0 + + 81 * col0 + col2 * col2 DIV - col1 AS col1 FROM tab1 AS cor0
----
123
4860
5772

skipif mysql # not compatible
query I rowsort label-7172
SELECT DISTINCT - ( + col1 ) / + col0 + + 81 * col0 + col2 * col2 / - col1 AS col1 FROM tab1 AS cor0
----
123
4860
5772

query I rowsort
SELECT ALL - col2 + 15 FROM tab2 AS cor0
----
-11
-12
-23

query I rowsort
SELECT + ( 54 ) FROM tab0 AS cor0
----
54
54
54

query I rowsort
SELECT col0 * - col0 + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + col2 + 52 * col2 * col0 AS col0 FROM tab2 AS cor0
----
105482
156142
9855

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col1 AS REAL ) - + col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + cor0.col1 * 27 FROM tab0 AS cor0
----
2322
2457
2619

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 47 * - col0 * + col2 + ( col1 ) col1 FROM tab1 AS cor0
----
171466
360973
7640

query I rowsort
SELECT - col1 + - 20 FROM tab0
----
-106
-111
-117

query I rowsort
SELECT ALL - col2 + 64 FROM tab1
----
-32
10
7

query I rowsort
SELECT ALL + col2 * 30 + + 35 * + tab2.col0 * ( col2 * - tab2.col0 ) FROM tab2
----
-45495
-5535660
-8299390

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + col1 + + 35 FROM tab1
----
45
48
61

query I rowsort
SELECT ALL 25 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7186
SELECT ALL + + col1 + + col1 DIV - 9 FROM tab1 AS cor0
----
12
24
9

skipif mysql # not compatible
query I rowsort label-7186
SELECT ALL + + col1 + + col1 / - 9 FROM tab1 AS cor0
----
12
24
9

query I rowsort
SELECT DISTINCT - + 67 * col1 AS col2 FROM tab0 AS cor0
----
-5762
-6097
-6499

query I rowsort
SELECT DISTINCT - - 30 * col0 FROM tab1 AS cor0
----
1920
2400
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 81 + - col0 col0 FROM tab0
----
-8
46
57

query I rowsort
SELECT + 27 AS col2 FROM tab1 cor0
----
27
27
27

query I rowsort
SELECT ALL + + 16 * col0 FROM tab0 AS cor0
----
1424
384
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-7192
SELECT 40 + + col0 DIV col1 FROM tab0 AS cor0
----
40
40
40

skipif mysql # not compatible
query I rowsort label-7192
SELECT 40 + + col0 / col1 FROM tab0 AS cor0
----
40
40
40

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-7194
SELECT 87 DIV col1 FROM tab2 AS cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-7194
SELECT 87 / col1 FROM tab2 AS cor0
----
1
2
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7195
SELECT - tab0.col2 * - col1 + - tab0.col0 DIV + col0 col0 FROM tab0
----
2837
7461
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7195
SELECT - tab0.col2 * - col1 + - tab0.col0 / + col0 col0 FROM tab0
----
2837
7461
96

query I rowsort
SELECT - + cor0.col1 + 20 * col2 AS col1 FROM tab1 AS cor0
----
1054
1130
1907

query I rowsort
SELECT - col1 + - col0 * - col0 AS col1 FROM tab1 AS cor0
----
-17
4086
6387

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7198
SELECT + col0 + - col0 * - CAST( - tab0.col1 AS SIGNED ) AS col2 FROM tab0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort label-7198
SELECT + col0 + - col0 * - CAST ( - tab0.col1 AS INTEGER ) AS col2 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - 4 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT DISTINCT + + cor0.col1 + + cor0.col2 + + cor0.col1 * col2 FROM tab1 AS cor0
----
1357
1484
637

query I rowsort
SELECT ALL - cor0.col1 * + 93 FROM tab1 AS cor0
----
-1209
-2418
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-7202
SELECT DISTINCT col1 DIV 78 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-7202
SELECT DISTINCT col1 / 78 FROM tab0 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7203
SELECT DISTINCT col2 * + CAST( NULL AS SIGNED ) + + cor0.col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7203
SELECT DISTINCT col2 * + CAST ( NULL AS INTEGER ) + + cor0.col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col1 + - ( cor0.col0 ) AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - + col0 + + cor0.col2 * col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT - + col2 + + 68 AS col1 FROM tab0 AS cor0
----
-14
35
67

query I rowsort
SELECT ALL 6 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT DISTINCT - + 39 + - col2 AS col1 FROM tab1 AS cor0
----
-135
-93
-96

query I rowsort
SELECT ALL + + cor0.col2 + - 22 FROM tab0 AS cor0
----
-21
11
60

query I rowsort
SELECT col2 * 24 FROM tab2 AS cor0
----
624
648
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-7211
SELECT DISTINCT + - cor0.col1 * col2 + - col1 * - cor0.col0 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-7211
SELECT DISTINCT + - cor0.col1 * col2 + - col1 * - cor0.col0 / cor0.col0 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-7212
SELECT ALL + 36 DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7212
SELECT ALL + 36 / cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7213
SELECT DISTINCT 64 DIV col1 FROM tab2 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-7213
SELECT DISTINCT 64 / col1 FROM tab2 AS cor0
----
1
2
3

query I rowsort
SELECT + 42 * cor0.col2 + - col1 AS col0 FROM tab1 cor0
----
2242
2384
4019

query I rowsort
SELECT ALL + 29 + + col0 FROM tab1 AS cor0
----
109
32
93

query I rowsort
SELECT - cor0.col1 + - col1 AS col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + ( + col1 ) + + 36 FROM tab2 cor0
----
53
67
95

query I rowsort
SELECT DISTINCT - - col1 * - col1 + 75 FROM tab0 AS cor0
----
-7321
-8206
-9334

query I rowsort
SELECT ALL + cor0.col0 * col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT - 52 * - col2 + + 80 FROM tab1 cor0
----
2888
3044
5072

query I rowsort
SELECT - col1 + + tab0.col0 AS col1 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7224
SELECT ALL col0 DIV col2 + col0 FROM tab1
----
3
65
80

skipif mysql # not compatible
query I rowsort label-7224
SELECT ALL col0 / col2 + col0 FROM tab1
----
3
65
80

query I rowsort
SELECT ALL col2 + col2 * tab1.col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT col2 FROM tab2 WHERE + col1 IN ( + col0 )
----

query I rowsort
SELECT DISTINCT tab1.col0 + col1 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL tab2.col1 FROM tab2 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT - col1 + + tab1.col0 + tab1.col2 FROM tab1
----
111
163
31

query I rowsort
SELECT DISTINCT col2 * + col2 - col1 FROM tab1
----
2890
3239
9203

query I rowsort
SELECT ALL + col0 + + tab0.col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT col2 + - col1 * col2 AS col0 FROM tab1
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 col2 FROM tab0 WHERE ( - col2 * - col0 ) <= NULL
----

query I rowsort
SELECT ALL - col0 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - col0 + tab2.col2 * col2 FROM tab2
----
1365
598
722

onlyif mysql # use DIV operator for integer division
query I rowsort label-7236
SELECT DISTINCT col1 DIV tab0.col1 + col0 * - col2 FROM tab0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-7236
SELECT DISTINCT col1 / tab0.col1 + col0 * - col2 FROM tab0
----
-34
-7297
-791

query I rowsort
SELECT DISTINCT - 4 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 22 + col0 col0 FROM tab1 AS cor0
----
-19
42
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7239
SELECT DISTINCT col0 + + col1 DIV + col1 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-7239
SELECT DISTINCT col0 + + col1 / + col1 FROM tab1
----
4
65
81

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL <> - col1 + - col2
----

query I rowsort
SELECT ALL - tab0.col2 + col1 * - col0 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT col0 FROM tab1 WHERE col0 IN ( col2 )
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT ( col2 * + col1 ) NOT IN ( cor0.col0 + - col0 )
----

query I rowsort
SELECT + col0 * col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col2 AS col0 FROM tab0 WHERE NULL > NULL
----

query I rowsort
SELECT DISTINCT + col1 FROM tab0 WHERE NOT ( + col2 ) > ( col2 )
----
86
91
97

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL BETWEEN NULL AND + col2 + + col0 * - col1
----

query I rowsort
SELECT ALL - tab0.col2 + tab0.col0 AS col2 FROM tab0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + tab2.col0 col1 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 FROM tab1 AS cor0 WHERE ( NULL ) > NULL
----

query I rowsort
SELECT + col2 * col2 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-7252
SELECT col1 + + col1 * col1 DIV - col2 AS col2 FROM tab0 cor0
----
-138
-9
-9312

skipif mysql # not compatible
query I rowsort label-7252
SELECT col1 + + col1 * col1 / - col2 AS col2 FROM tab0 cor0
----
-138
-9
-9312

query I rowsort
SELECT - - 71 + + cor0.col0 FROM tab1 cor0
----
135
151
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7254
SELECT col0 DIV cor0.col0 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7254
SELECT col0 / cor0.col0 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-2
-63
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7255
SELECT ALL col0 DIV - ( - 32 * col2 ) + + ( tab0.col2 + col0 ) AS col2 FROM tab0
----
171
37
57

skipif mysql # not compatible
query I rowsort label-7255
SELECT ALL col0 / - ( - 32 * col2 ) + + ( tab0.col2 + col0 ) AS col2 FROM tab0
----
171
37
57

query I rowsort
SELECT tab1.col0 * 92 * + col1 FROM tab1
----
58880
7176
95680

query I rowsort
SELECT - ( col2 ) * + col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-7258
SELECT ALL - cor0.col1 DIV tab0.col1 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7258
SELECT ALL - cor0.col1 / tab0.col1 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ( - 39 ) + + col0 FROM tab1
----
-36
25
41

query I rowsort
SELECT ALL + + ( col1 ) + + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + 66 + col1 FROM tab2 cor0
----
125
83
97

query I rowsort
SELECT - col2 + - col2 * col2 + 25 AS col2 FROM tab0 AS cor0
----
-1097
-6781
23

query I rowsort
SELECT + col2 * + col1 - - ( col0 ) FROM tab2
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7264
SELECT col2 + col2 DIV col0 - + col2 DIV col1 FROM tab0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-7264
SELECT col2 + col2 / col0 - + col2 / col1 FROM tab0
----
1
34
82

query I rowsort
SELECT ALL + 39 - col2 AS col0 FROM tab1
----
-15
-18
-57

query I rowsort
SELECT DISTINCT col1 * + col0 - ( col0 ) * tab1.col0 AS col2 FROM tab1
----
-3456
-5360
69

query I rowsort
SELECT - 28 + col1 * ( col0 ) FROM tab0 AS cor0
----
2036
3367
8071

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7268
SELECT 80 * - col1 * ( - col0 * - col1 ) + CAST( - col1 AS SIGNED ) * col0 FROM tab2 AS cor0
----
-1827823
-21726042
-538377

skipif mysql # not compatible
query I rowsort label-7268
SELECT 80 * - col1 * ( - col0 * - col1 ) + CAST ( - col1 AS INTEGER ) * col0 FROM tab2 AS cor0
----
-1827823
-21726042
-538377

query I rowsort
SELECT col2 * + col0 - + col2 * col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + cor0.col2 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT + - col1 + 49 FROM tab2 AS cor0
----
-10
18
32

query I rowsort
SELECT + col1 + ( 34 ) + + col0 FROM tab2 cor0
----
130
171
72

query I rowsort
SELECT - col0 + - 62 * 17 FROM tab0 AS cor0
----
-1078
-1089
-1143

query I rowsort
SELECT + col2 * - 81 FROM tab1 AS cor0
----
-4374
-4617
-7776

query I rowsort
SELECT - 43 * col1 * + col0 AS col2 FROM tab2
----
-197886
-57749
-9331

query I rowsort
SELECT ALL - col2 * - 46 AS col2 FROM tab2 AS cor0
----
1196
1242
1748

query I rowsort
SELECT DISTINCT + - col0 + col1 + col2 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT + cor0.col1 + 12 FROM tab2 AS cor0
----
29
43
71

query I rowsort
SELECT DISTINCT - - col2 * col2 + + col0 AS col1 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col1 * + 74 * col1 FROM tab2 AS cor0
----
21403
257653
71145

query I rowsort
SELECT + tab2.col1 + + col1 * + col0 FROM tab2
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 48 ) col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT DISTINCT + 27 * - cor0.col1 * 42 FROM tab2, tab1 AS cor0
----
-11340
-14742
-29484

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7284
SELECT - CAST( col2 AS SIGNED ) * - col0 + + col1 AS col1 FROM tab2 AS cor0
----
2087
220
3019

skipif mysql # not compatible
query I rowsort label-7284
SELECT - CAST ( col2 AS INTEGER ) * - col0 + + col1 AS col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + - 34 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1054
-2006
-578

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7286
SELECT + - cor2.col2 * + CAST( 61 AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 39ef3fb9b62389142de4b4cf428d5cf9

skipif mysql # not compatible
query I rowsort label-7286
SELECT + - cor2.col2 * + CAST ( 61 AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 39ef3fb9b62389142de4b4cf428d5cf9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7287
SELECT DISTINCT 85 * 25 DIV + col0 AS col2 FROM tab0 cor0
----
23
60
88

skipif mysql # not compatible
query I rowsort label-7287
SELECT DISTINCT 85 * 25 / + col0 AS col2 FROM tab0 cor0
----
23
60
88

query I rowsort
SELECT ALL + col1 - - cor0.col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + 32 + col1 AS col1 FROM tab1 AS cor0
----
42
45
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7290
SELECT + 59 + - col0 + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
110
52
75

skipif mysql # not compatible
query I rowsort label-7290
SELECT + 59 + - col0 + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
110
52
75

query I rowsort
SELECT - + 40 * - col1 - + col1 AS col2 FROM tab0 AS cor0
----
3354
3549
3783

query I rowsort
SELECT - 39 + + col0 FROM tab0 AS cor0
----
-15
-4
50

query I rowsort
SELECT ALL ( col2 ) - col2 AS col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7294
SELECT - col2 + CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-7294
SELECT - col2 + CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL - col0 * + ( - ( - col0 ) ) AS col2 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT + cor0.col1 * + ( col0 ) + - col2 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7297
SELECT ALL + cor0.col1 * cor0.col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7297
SELECT ALL + cor0.col1 * cor0.col0 / + col0 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col1 * - 0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col2 * col2 + - col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT col1 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - - 94 + + col1 AS col0 FROM tab0 AS cor0
----
180
185
191

query I rowsort
SELECT + 52 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT DISTINCT - + col2 + 37 FROM tab1 AS cor0
----
-17
-20
-59

query I rowsort
SELECT ALL - + ( 75 ) + - col1 FROM tab1 AS cor0
----
-101
-85
-88

query I rowsort
SELECT + col2 + - tab1.col0 * + 92 FROM tab1
----
-222
-5831
-7264

query I rowsort
SELECT - col0 + - col1 * + col1 + 14 * - col1 FROM tab0 AS cor0
----
-10802
-8624
-9644

query I rowsort
SELECT + cor0.col1 + - col0 * + col2 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + col0 * + col1 + cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + + 27 * 16 * col2 FROM tab0 AS cor0
----
14256
35424
432

query I rowsort
SELECT DISTINCT - col2 * ( + cor0.col2 * - cor0.col1 ) AS col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT 16 + cor0.col1 + col0 AS col2 FROM tab1 AS cor0
----
109
45
90

query I rowsort
SELECT - col2 + - 49 FROM tab2
----
-75
-76
-87

query I rowsort
SELECT ALL tab0.col2 + col0 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT ( + cor1.col1 ) + ( ( cor1.col2 ) ) * - 31 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-1161
-747
-806

query I rowsort
SELECT ALL + col0 * col2 * - 71 + col2 * - col1 FROM tab1
----
-12906
-259578
-546528

query I rowsort
SELECT DISTINCT + col2 + col0 * - col0 + + tab1.col2 * tab1.col1 AS col1 FROM tab1
----
-3469
-5056
1449

query I rowsort
SELECT ALL - col2 * - cor0.col2 + - col1 AS col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT - col0 + 96 + col0 FROM tab0 AS cor0
----
96

query I rowsort
SELECT - 41 * - col0 * col2 + tab1.col2 FROM tab1
----
149625
314976
6696

query I rowsort
SELECT ( + 5 ) FROM tab1
----
5
5
5

query I rowsort
SELECT - 19 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7322
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) col0 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7322
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) col0 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7323
SELECT col2 DIV + col0 + col2 + col2 AS col0 FROM tab0 AS cor0
----
164
2
67

skipif mysql # not compatible
query I rowsort label-7323
SELECT col2 / + col0 + col2 + col2 AS col0 FROM tab0 AS cor0
----
164
2
67

query I rowsort
SELECT col0 * - col0 * col2 + tab1.col0 * col0 FROM tab1
----
-229376
-477
-608000

query I rowsort
SELECT DISTINCT 10 + 74 FROM tab1, tab1 cor0
----
84

query I rowsort
SELECT ALL + col1 + - col0 * - 44 FROM tab2 AS cor0
----
339
3491
3493

query I rowsort
SELECT DISTINCT + cor0.col1 + 53 AS col2 FROM tab2 AS cor0
----
112
70
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-7328
SELECT ALL cor0.col1 DIV col0 + - col1 AS col1 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-7328
SELECT ALL cor0.col1 / col0 + - col1 AS col1 FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT col2 * 72 * col2 + + col1 AS col0 FROM tab2 cor0
----
103985
48731
52519

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + cor0.col2 * 13 col0 FROM tab1 cor0
----
1328
705
805

query I rowsort
SELECT - + col0 + - cor0.col0 * col0 AS col1 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT ( col1 ) + - cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - 77 + + col2 * col1 FROM tab1 cor0
----
1325
1481
647

onlyif mysql # use DIV operator for integer division
query I rowsort label-7334
SELECT cor0.col0 + - col0 DIV - col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-7334
SELECT cor0.col0 + - col0 / - col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT - + col0 + - col1 * 4 AS col0 FROM tab2 AS cor0
----
-131
-147
-314

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7336
SELECT + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7336
SELECT + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col0 + + 36 * - col1 FROM tab0 AS cor0
----
-3120
-3365
-3527

query I rowsort
SELECT - + col2 * - col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - - 47 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT DISTINCT cor0.col1 * - 74 AS col2 FROM tab1, tab1 AS cor0
----
-1924
-740
-962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7341
SELECT DISTINCT + col1 + CAST( NULL AS SIGNED ) * - tab0.col0 + col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7341
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) * - tab0.col0 + col2 FROM tab0
----
NULL

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab1 AS cor3
----
3645 values hashing to 0a3bf4d9642f43f11aad64de0d046e6b

query I rowsort
SELECT + col0 * col0 + col1 - + 25 AS col2 FROM tab0 AS cor0
----
1297
637
7987

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) * - col1 col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT 43 * col2 AS col1 FROM tab0
----
1419
3526
43

query I rowsort
SELECT - col0 * + col1 + - col1 AS col0 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - - col1 * + cor0.col0 + + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT 51 + col1 * - col0 FROM tab1
----
-27
-589
-989

query I rowsort
SELECT - col1 * 86 FROM tab1
----
-1118
-2236
-860

onlyif mysql # use DIV operator for integer division
query I rowsort label-7350
SELECT DISTINCT - col1 DIV + ( col0 ) FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-7350
SELECT DISTINCT - col1 / + ( col0 ) FROM tab0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 * - col1 col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + + 94 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT col1 * - col1 * col1 + col0 FROM tab0 AS cor0
----
-636032
-753482
-912638

onlyif mysql # use DIV operator for integer division
query I rowsort label-7354
SELECT ALL + - 47 DIV - col2 + 93 + 43 FROM tab1 AS cor0
----
136
136
136

skipif mysql # not compatible
query I rowsort label-7354
SELECT ALL + - 47 / - col2 + 93 + 43 FROM tab1 AS cor0
----
136
136
136

query I rowsort
SELECT + 1 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to 2a004dce2d308bae163576f54ee1a3fc

query I rowsort
SELECT + 31 + - col0 FROM tab1 cor0
----
-33
-49
28

query I rowsort
SELECT ALL + col1 * col0 + col0 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL 33 + - col2 AS col0 FROM tab0
----
-49
0
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-7359
SELECT ALL col0 DIV - col0 + + col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-7359
SELECT ALL col0 / - col0 + + col0 FROM tab1
----
2
63
79

query I rowsort
SELECT DISTINCT tab1.col2 + cor0.col2 FROM tab1, tab1 cor0
----
108
111
114
150
153
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 * col1 col0 FROM tab1
----
1326
510
663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - tab1.col1 col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col1 * - col0 + col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT col2 + col1 - - tab0.col2 FROM tab0
----
152
255
99

query I rowsort
SELECT ALL - 33 * + col2 + + 51 FROM tab1
----
-1731
-1830
-3117

query I rowsort
SELECT + 74 - col0 FROM tab1
----
-6
10
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-7367
SELECT ALL col2 DIV 58 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7367
SELECT ALL col2 / 58 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT - 3 FROM tab0, tab0 AS cor0
----
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * + ( - col0 + - col1 ) * col1 col0 FROM tab0
----
-1457820
-227040
-448140

query I rowsort
SELECT - + 91 + - col1 AS col2 FROM tab2 AS cor0
----
-108
-122
-150

query I rowsort
SELECT - - ( cor0.col2 ) + - col2 * + col1 - - col1 FROM tab0 AS cor0
----
-2719
-7289
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7372
SELECT CAST( NULL AS SIGNED ) + col1 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-7372
SELECT CAST ( NULL AS INTEGER ) + col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * - col1 + + col1 col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col2 - 70 * - col1 AS col2 FROM tab0 AS cor0
----
5987
6288
6789

query I rowsort
SELECT DISTINCT + + cor0.col0 + ( col2 ) + + ( - col0 ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort
SELECT ALL + - CAST ( - 17 AS REAL ) - - col0 FROM tab2 AS cor0
----
24
95
96

query I rowsort
SELECT DISTINCT 69 FROM tab1, tab0 cor0, tab0 AS cor1
----
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-7378
SELECT DISTINCT + col2 DIV 66 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-7378
SELECT DISTINCT + col2 / 66 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL 70 * + col1 AS col0 FROM tab0
----
6020
6370
6790

query I rowsort
SELECT ALL + 27 * tab0.col2 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 21735c23a08529f05dbf43375d13a9d2

query I rowsort
SELECT DISTINCT + 43 + + 38 AS col1 FROM tab2, tab1 AS cor0
----
81

query I rowsort
SELECT DISTINCT - - col0 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col1 * 21 AS col0 FROM tab1 AS cor0
----
-210
-273
-546

query I rowsort
SELECT - 73 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT ALL cor0.col2 + - col2 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT 66 FROM tab0, tab1 cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT - 77 - - col0 * col1 FROM tab2
----
1266
140
4525

onlyif mysql # use DIV operator for integer division
query I rowsort label-7388
SELECT ALL ( + col2 ) + - col0 DIV col1 FROM tab2
----
25
27
34

skipif mysql # not compatible
query I rowsort label-7388
SELECT ALL ( + col2 ) + - col0 / col1 FROM tab2
----
25
27
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7389
SELECT - + cor0.col2 + col1 DIV col1 FROM tab0 cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-7389
SELECT - + cor0.col2 + col1 / col1 FROM tab0 cor0
----
-32
-81
0

query I rowsort
SELECT ALL col0 + col1 + + col2 AS col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL 17 + - col0 FROM tab2 AS cor0
----
-61
-62
10

query I rowsort
SELECT ALL col2 * + col2 + col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + 5 + + 61 AS col0 FROM tab1
----
66
66
66

query I rowsort
SELECT ALL + 56 AS col1 FROM tab1 AS cor0
----
56
56
56

query I rowsort
SELECT - 97 + + col0 + + 66 * + col1 AS col2 FROM tab1 cor0
----
1622
627
841

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 + + 55 col0 FROM tab0 AS cor0
----
165
187
235

query I rowsort
SELECT DISTINCT 78 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
78

query I rowsort
SELECT ALL - 39 * + tab0.col1 FROM tab0
----
-3354
-3549
-3783

query I rowsort
SELECT 65 * col1 + col1 AS col0 FROM tab1 AS cor0
----
1716
660
858

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 * + cor0.col0 + col1 col0 FROM tab1 AS cor0
----
260
40970
83213

query I rowsort
SELECT ALL - col2 + + col1 + - 47 AS col2 FROM tab0 AS cor0
----
-38
49
6

query I rowsort
SELECT DISTINCT + col0 + - col1 * + col0 AS col0 FROM tab2 cor0
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7403
SELECT - 63 * + col2 + + CAST( 64 AS SIGNED ) AS col2 FROM tab0 cor0
----
-2015
-5102
1

skipif mysql # not compatible
query I rowsort label-7403
SELECT - 63 * + col2 + + CAST ( 64 AS INTEGER ) AS col2 FROM tab0 cor0
----
-2015
-5102
1

query I rowsort
SELECT + + cor0.col0 * col2 * 63 + col1 + - col0 AS col0 FROM tab1 AS cor0
----
10229
229770
483773

query I rowsort
SELECT DISTINCT + col2 + col0 + + 43 AS col0 FROM tab1 AS cor0
----
100
164
219

query I rowsort
SELECT ALL + + col1 + - col2 * - 50 FROM tab0 AS cor0
----
147
1736
4191

query I rowsort
SELECT tab0.col2 * tab0.col1 AS col0 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7408
SELECT - col1 DIV - col2 + + col2 * + col1 FROM tab0
----
194
2840
7463

skipif mysql # not compatible
query I rowsort label-7408
SELECT - col1 / - col2 + + col2 * + col1 FROM tab0
----
194
2840
7463

query I rowsort
SELECT DISTINCT - 4 + col0 * + col0 FROM tab2 cor0
----
45
6080
6237

query I rowsort
SELECT DISTINCT + col1 * - col2 + - ( + col2 ) * + cor0.col0 FROM tab2 AS cor0
----
-1026
-3562
-3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-7411
SELECT ALL + + col0 + + col1 DIV col1 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7411
SELECT ALL + + col0 + + col1 / col1 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - col1 + col2 * - 48 AS col2 FROM tab2 AS cor0
----
-1307
-1327
-1841

query I rowsort
SELECT ALL - col0 - - col2 * col1 FROM tab1 cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + col1 * - ( col0 ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT cor0.col1 + ( col0 ) * - col2 FROM tab1 cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col2 col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ( col1 ) * - col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT 81 * col0 * col2 AS col0 FROM tab2
----
15309
164268
243162

query I rowsort
SELECT - col1 + - col0 * - col0 * col1 FROM tab1 AS cor0
----
208
40950
83187

query I rowsort
SELECT col2 * - col2 * - col0 + ( + col1 ) AS col1 FROM tab0
----
132
26222
598527

query I rowsort
SELECT DISTINCT 39 * - col0 FROM tab1 AS cor0
----
-117
-2496
-3120

onlyif mysql # use DIV operator for integer division
query I rowsort label-7422
SELECT DISTINCT - + cor0.col0 DIV - col0 - - col0 AS col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-7422
SELECT DISTINCT - + cor0.col0 / - col0 - - col0 AS col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT DISTINCT - cor0.col2 * + col0 + + col1 AS col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL - cor0.col1 + cor0.col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT ALL + cor0.col1 + ( + col2 * col0 ) AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL 40 - + cor0.col2 AS col2 FROM tab1 AS cor0
----
-14
-17
-56

query I rowsort
SELECT ALL - 2 + + col2 AS col2 FROM tab2 AS cor0
----
24
25
36

query I rowsort
SELECT col0 * col0 + col1 * + col1 * col1 AS col0 FROM tab1
----
17585
5096
8597

query I rowsort
SELECT - col2 + - 30 FROM tab2
----
-56
-57
-68

query I rowsort
SELECT - col2 * - col0 * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT + + 74 * col1 - col0 FROM tab0 AS cor0
----
6340
6645
7143

query I rowsort
SELECT 33 + - col0 FROM tab2 AS cor0
----
-45
-46
26

query I rowsort
SELECT ALL + 37 * + col0 + tab2.col1 AS col0 FROM tab2
----
290
2940
2945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7434
SELECT DISTINCT col1 * CAST( - col0 AS SIGNED ) AS col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-7434
SELECT DISTINCT col1 * CAST ( - col0 AS INTEGER ) AS col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * 35 col2 FROM tab2
----
1085
2065
595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7436
SELECT ALL + CAST( cor0.col1 AS SIGNED ) * col0 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-7436
SELECT ALL + CAST ( cor0.col1 AS INTEGER ) * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT col1 + - col0 * + col2 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + - 94 * - ( - col2 ) FROM tab2 AS cor0
----
-2444
-2538
-3572

query I rowsort
SELECT - ( cor0.col2 ) + - col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT - + ( col0 ) + - col0 AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - 1 * + col2 + - tab1.col1 FROM tab1
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7442
SELECT + CAST( NULL AS SIGNED ) * + col1 * - col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7442
SELECT + CAST ( NULL AS INTEGER ) * + col1 * - col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 13 + - col2 FROM tab1 AS cor0
----
-41
-44
-83

query I rowsort
SELECT - - 99 * + col0 FROM tab1 AS cor0
----
297
6336
7920

query I rowsort
SELECT - col0 * + 85 + cor0.col2 FROM tab2 AS cor0
----
-568
-6604
-6677

query I rowsort
SELECT col0 + ( + col1 ) * - col2 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-7447
SELECT - - ( - 83 ) DIV - cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7447
SELECT - - ( - 83 ) / - cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 96 * col2 * + col2 FROM tab2 AS cor0
----
138624
64896
69984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 56 * - col1 col1 FROM tab0 AS cor0
----
-4816
-5096
-5432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col0 * col2 col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col1 + + col0 * + cor0.col0 * col0 FROM tab0 AS cor0
----
13910
42972
705060

query I rowsort
SELECT cor0.col0 - cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * + col0 * col2 + col2 AS col0 FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT + + col0 * + 10 AS col2 FROM tab2 AS cor0
----
70
780
790

query I rowsort
SELECT + col2 * + 8 AS col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT DISTINCT - + col0 * + col1 * - col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT col1 * + ( + col0 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + 3 col0 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT ALL + cor0.col2 - 75 AS col1 FROM tab1 AS cor0
----
-18
-21
21

query I rowsort
SELECT ALL - + col2 * 50 * col2 FROM tab0 AS cor0
----
-336200
-50
-54450

query I rowsort
SELECT DISTINCT - col2 * + 62 + + 11 AS col0 FROM tab0 AS cor0
----
-2035
-5073
-51

query I rowsort
SELECT - col1 + col2 * + col2 AS col0 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT + - col1 * 7 FROM tab2 AS cor0
----
-119
-217
-413

query I rowsort
SELECT ALL cor0.col0 + col2 * col1 AS col2 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 39 col1 FROM tab2 cor0
----
273
3042
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-7466
SELECT - col0 + col0 DIV - cor0.col1 AS col2 FROM tab1 AS cor0
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-7466
SELECT - col0 + col0 / - cor0.col1 AS col2 FROM tab1 AS cor0
----
-3
-70
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7467
SELECT DISTINCT col0 - - 88 DIV col1 AS col2 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-7467
SELECT DISTINCT col0 - - 88 / col1 AS col2 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT - 77 FROM tab2, tab2 cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + + col0 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + ( 39 ) + col2 FROM tab2 AS cor0
----
65
66
77

query I rowsort
SELECT DISTINCT + + col2 * - col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT + col2 + col2 + col1 AS col0 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT - - col0 + - col0 * 30 AS col2 FROM tab2 AS cor0
----
-203
-2262
-2291

query I rowsort
SELECT ALL - - 98 + - col2 FROM tab2 AS cor0
----
60
71
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-7475
SELECT 6 DIV - cor0.col0 AS col1 FROM tab1 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-7475
SELECT 6 / - cor0.col0 AS col1 FROM tab1 AS cor0
----
-2
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7476
SELECT + col2 + - col0 + CAST( col0 AS SIGNED ) DIV col1 FROM tab2 AS cor0
----
-37
-51
20

skipif mysql # not compatible
query I rowsort label-7476
SELECT + col2 + - col0 + CAST ( col0 AS INTEGER ) / col1 FROM tab2 AS cor0
----
-37
-51
20

query I rowsort
SELECT DISTINCT - 45 * - tab2.col2 FROM tab2
----
1170
1215
1710

query I rowsort
SELECT 17 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT - 98 * col1 - - ( col2 ) FROM tab1
----
-1178
-2494
-923

query I rowsort
SELECT - tab0.col0 * col0 * 28 + col1 FROM tab0
----
-16042
-221697
-34203

query I rowsort
SELECT col1 + col2 * - col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT ALL 92 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT - ( col1 ) + tab1.col1 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL tab2.col2 * col1 * ( + tab2.col1 ) AS col0 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT 42 - col2 AS col1 FROM tab0
----
-40
41
9

query I rowsort
SELECT - ( + cor0.col0 ) * col2 * col2 + col1 FROM tab2 AS cor0
----
-114059
-5072
-52669

query I rowsort
SELECT ALL + + col1 * - ( col1 ) FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT - col1 + - col2 * col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-7489
SELECT col1 DIV - 37 AS col2 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7489
SELECT col1 / - 37 AS col2 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT 58 - 11 * col2 AS col0 FROM tab0 AS cor0
----
-305
-844
47

query I rowsort
SELECT ALL + col0 + 76 FROM tab1
----
140
156
79

query I rowsort
SELECT ALL col2 * + 60 FROM tab1 AS cor0
----
3240
3420
5760

query I rowsort
SELECT ALL - col2 * col0 + - col1 AS col1 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT 3 + tab2.col2 AS col1 FROM tab2
----
29
30
41

query I rowsort
SELECT DISTINCT col1 + - col1 * + col0 AS col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - ( 85 ) FROM tab1
----
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7497
SELECT col2 DIV + col1 + tab0.col1 * + col2 FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-7497
SELECT col2 / + col1 + tab0.col1 * + col2 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7498
SELECT + 31 DIV + ( - col1 ) - + col1 * col1 FROM tab0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-7498
SELECT + 31 / + ( - col1 ) - + col1 * col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + col1 * col0 * + col2 + col2 AS col1 FROM tab1
----
36537
4266
99936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT ( col0 ) * col0 * col1 + col0 FROM tab2
----
106176
1526
359034

query I rowsort
SELECT - - ( col2 ) + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7503
SELECT ALL - CAST( - col2 AS SIGNED ) + - col1 DIV col1 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-7503
SELECT ALL - CAST ( - col2 AS INTEGER ) + - col1 / col1 FROM tab0 AS cor0
----
0
32
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7504
SELECT DISTINCT + col1 + + cor0.col1 * - col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7504
SELECT DISTINCT + col1 + + cor0.col1 * - col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7505
SELECT + CAST( - col0 + + col2 AS SIGNED ) AS col0 FROM tab1
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-7505
SELECT + CAST ( - col0 + + col2 AS INTEGER ) AS col0 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7506
SELECT + + col2 * + col0 + col0 - col1 DIV col0 FROM tab1 AS cor0
----
157
3712
7760

skipif mysql # not compatible
query I rowsort label-7506
SELECT + + col2 * + col0 + col0 - col1 / col0 FROM tab1 AS cor0
----
157
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7507
SELECT + 28 * tab0.col0 DIV col2 FROM tab0
----
20
30
980

skipif mysql # not compatible
query I rowsort label-7507
SELECT + 28 * tab0.col0 / col2 FROM tab0
----
20
30
980

query I rowsort
SELECT DISTINCT tab1.col1 * - tab1.col0 + col0 - + 12 AS col2 FROM tab1
----
-588
-87
-972

query I rowsort
SELECT DISTINCT - col2 * col0 + - 40 FROM tab0 AS cor0
----
-7338
-75
-832

onlyif mysql # use DIV operator for integer division
query I rowsort label-7510
SELECT ALL col0 + 80 DIV col0 + cor0.col1 AS col1 FROM tab1 cor0
----
55
75
94

skipif mysql # not compatible
query I rowsort label-7510
SELECT ALL col0 + 80 / col0 + cor0.col1 AS col1 FROM tab1 cor0
----
55
75
94

query I rowsort
SELECT cor0.col2 * col0 + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + + col0 * 63 AS col1 FROM tab1 AS cor0
----
189
4032
5040

onlyif mysql # use DIV operator for integer division
query I rowsort label-7513
SELECT ALL + + col1 DIV - 89 col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7513
SELECT ALL + + col1 / - 89 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 99 + col1 * col1 AS col2 FROM tab0
----
7495
8380
9508

query I rowsort
SELECT + 2 + + tab1.col1 FROM tab1
----
12
15
28

query I rowsort
SELECT 53 * + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 253e513dc3ae3f65e2f61ab264666bc1

query I rowsort
SELECT - col0 * + 42 AS col2 FROM tab2
----
-294
-3276
-3318

onlyif mysql # use DIV operator for integer division
query I rowsort label-7518
SELECT DISTINCT - col0 * - col2 + 79 * tab0.col0 DIV col2 FROM tab0
----
2800
7383
849

skipif mysql # not compatible
query I rowsort label-7518
SELECT DISTINCT - col0 * - col2 + 79 * tab0.col0 / col2 FROM tab0
----
2800
7383
849

query I rowsort
SELECT + col0 + - 49 - col2 * col0 AS col2 FROM tab0 AS cor0
----
-49
-7258
-817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7520
SELECT col0 - CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7520
SELECT col0 - CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col0 + - ( 72 ) AS col2 FROM tab0 AS cor0
----
-37
-48
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * ( col1 ) + col1 + col2 col0 FROM tab0 cor0
----
195
2957
7635

onlyif mysql # use DIV operator for integer division
query I rowsort label-7523
SELECT - col2 + + col1 * col2 DIV + col0 col0 FROM tab1 AS cor0
----
-49
-81
414

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7523
SELECT - col2 + + col1 * col2 / + col0 col0 FROM tab1 AS cor0
----
-49
-81
414

query I rowsort
SELECT ALL - + cor0.col2 + - col0 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7525
SELECT - col0 DIV - 49 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7525
SELECT - col0 / - 49 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + col1 * + 36 + - col1 * + cor0.col2 FROM tab0 AS cor0
----
-4186
258
3395

query I rowsort
SELECT DISTINCT - col2 * col0 + + col0 * col1 AS col1 FROM tab0 AS cor0
----
1272
3360
801

query I rowsort
SELECT DISTINCT col2 + 74 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1058
1978
797

query I rowsort
SELECT DISTINCT col1 FROM tab1 WHERE ( NULL ) NOT IN ( + col1 ) AND NOT ( + col0 + - col0 ) = NULL
----

query I rowsort
SELECT ALL col1 * tab1.col1 + col0 AS col1 FROM tab1
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-7531
SELECT ALL - col2 * - col0 + col1 * col0 + col0 DIV + col0 FROM tab2
----
407
4346
6631

skipif mysql # not compatible
query I rowsort label-7531
SELECT ALL - col2 * - col0 + col1 * col0 + col0 / + col0 FROM tab2
----
407
4346
6631

query I rowsort
SELECT ALL - col0 + + col0 * tab0.col1 + col1 FROM tab0
----
2126
3457
8101

onlyif mysql # use DIV operator for integer division
query I rowsort label-7533
SELECT ALL tab1.col1 DIV col0 + + col2 AS col0 FROM tab1
----
57
62
96

skipif mysql # not compatible
query I rowsort label-7533
SELECT ALL tab1.col1 / col0 + + col2 AS col0 FROM tab1
----
57
62
96

query I rowsort
SELECT DISTINCT col1 * col0 + + col0 - col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col0 + + col0 * col0 * col1 col1 FROM tab1
----
231
40896
83120

query I rowsort
SELECT + tab2.col0 + + col1 + - col0 * col0 FROM tab2
----
-11
-5947
-6145

query I rowsort
SELECT ALL - col2 * col1 + + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-7538
SELECT ALL - col0 DIV - cor0.col2 AS col0 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7538
SELECT ALL - col0 / - cor0.col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT col0 - + col2 * col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT - - col1 * - col0 * + col2 + col2 AS col0 FROM tab0 AS cor0
----
-3394
-664036
-68079

query I rowsort
SELECT + - col0 + cor0.col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + col2 * col1 * col1 + cor0.col0 * col0 * - col1 AS col0 FROM tab2 cor0
----
-117079
-27466
-449462

query I rowsort
SELECT DISTINCT - 4 * - col2 AS col2 FROM tab2 AS cor0
----
104
108
152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( cor0.col1 ) + - col1 - + col1 col0 FROM tab0 AS cor0
----
-258
-273
-291

query I rowsort
SELECT ALL + 97 - col1 AS col0 FROM tab2 cor0
----
38
66
80

query I rowsort
SELECT DISTINCT + + 2 + col1 AS col0 FROM tab2 AS cor0
----
19
33
61

query I rowsort
SELECT - col0 + - col2 * col2 FROM tab0 cor0
----
-1113
-36
-6813

query I rowsort
SELECT ALL - col0 + cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT + 0 + col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + col2 * + cor0.col1 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 19 AS col0 FROM tab0
----
-19

query I rowsort
SELECT ALL + col0 * + col2 * + col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT - ( - cor0.col1 ) * - 39 + cor0.col1 FROM tab1 cor0
----
-380
-494
-988

query I rowsort
SELECT - ( col1 ) + - col2 * + col2 AS col1 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT 87 AS col2 FROM tab0 AS cor0
----
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7557
SELECT + col0 * col1 + - CAST( NULL AS SIGNED ) + 70 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7557
SELECT + col0 * col1 + - CAST ( NULL AS INTEGER ) + 70 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 + cor0.col0 * col1 AS col0 FROM tab1 cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-7559
SELECT - + 89 - - col2 DIV - col0 AS col2 FROM tab1 AS cor0
----
-107
-89
-90

skipif mysql # not compatible
query I rowsort label-7559
SELECT - + 89 - - col2 / - col0 AS col2 FROM tab1 AS cor0
----
-107
-89
-90

query I rowsort
SELECT ALL + 36 AS col1 FROM tab1
----
36
36
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7561
SELECT CAST( + 79 AS SIGNED ) AS col0 FROM tab0
----
79
79
79

skipif mysql # not compatible
query I rowsort label-7561
SELECT CAST ( + 79 AS INTEGER ) AS col0 FROM tab0
----
79
79
79

query I rowsort
SELECT - 66 + + col0 FROM tab2 AS cor0
----
-59
12
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 + 39 - col2 col2 FROM tab0 cor0
----
135
2844
7419

onlyif mysql # use DIV operator for integer division
query I rowsort label-7564
SELECT col0 + + col0 DIV col1 + - col0 AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-7564
SELECT col0 + + col0 / col1 + - col0 AS col1 FROM tab1 AS cor0
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * 70 col1 FROM tab0
----
-6020
-6370
-6790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col1 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT + col0 + + 13 * - 34 AS col0 FROM tab0 AS cor0
----
-353
-407
-418

query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col0 AS col0 FROM tab2, tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - cor1.col1 AS col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
-10
-13
-26

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 WHERE NULL < ( NULL )
----

query I rowsort
SELECT + 58 FROM tab1, tab2 cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT - - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL 99 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

query I rowsort
SELECT ALL tab2.col0 * 3 + + cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 4bb40b9cc858df9aaa259a6d2a8225c0

query I rowsort
SELECT ALL + 29 * - col2 FROM tab1 AS cor0
----
-1566
-1653
-2784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col0 col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL tab2.col0 + col0 * + 89 AS col0 FROM tab2
----
630
7020
7110

query I rowsort
SELECT - col2 + 29 FROM tab1 cor0
----
-25
-28
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7579
SELECT ALL + cor0.col2 * - CAST( - col1 AS SIGNED ) DIV - col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-7579
SELECT ALL + cor0.col2 * - CAST ( - col1 AS INTEGER ) / - col1 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7580
SELECT cor0.col1 + + CAST( NULL AS DECIMAL ) * 92 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-7580
SELECT cor0.col1 + + CAST ( NULL AS REAL ) * 92 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 * + cor0.col0 * + cor0.col0 + + col0 FROM tab0 AS cor0
----
-118790
-49512
-720722

query I rowsort
SELECT DISTINCT - col1 * ( + 18 * col0 ) AS col2 FROM tab2 cor0
----
-24174
-3906
-82836

query I rowsort
SELECT - col1 + + col1 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT 14 * - col0 FROM tab1 AS cor0
----
-1120
-42
-896

query I rowsort
SELECT ALL + - ( col1 ) * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7586
SELECT DISTINCT + 37 * col1 DIV + col2 AS col2 FROM tab1 AS cor0
----
17
5
6

skipif mysql # not compatible
query I rowsort label-7586
SELECT DISTINCT + 37 * col1 / + col2 AS col2 FROM tab1 AS cor0
----
17
5
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7587
SELECT DISTINCT - col2 + + col0 DIV col1 AS col1 FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7587
SELECT DISTINCT - col2 + + col0 / col1 AS col1 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 12 * + col0 AS col0 FROM tab0 AS cor0
----
1068
288
420

query I rowsort
SELECT - + 33 + 54 FROM tab2 cor0
----
21
21
21

query I rowsort
SELECT DISTINCT - col0 * + col2 * - col1 + + 15 * col2 FROM tab0 AS cor0
----
3410
665348
68607

query I rowsort
SELECT DISTINCT col2 * col2 + col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL - col1 * + col0 + col0 * + 78 FROM tab2 AS cor0
----
1482
329
4819

query I rowsort
SELECT ALL + + cor0.col2 * + ( + col0 ) - - col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + - col2 - - col0 * + cor0.col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL - col1 * + col2 + 34 FROM tab1 AS cor0
----
-1214
-1370
-536

onlyif mysql # use DIV operator for integer division
query I rowsort label-7596
SELECT DISTINCT cor0.col0 DIV col2 + - col0 FROM tab0 AS cor0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-7596
SELECT DISTINCT cor0.col0 / col2 + - col0 FROM tab0 AS cor0
----
-24
-88
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 * 73 col2 FROM tab0 AS cor0
----
1838
2652
6588

onlyif mysql # use DIV operator for integer division
query I rowsort label-7598
SELECT + cor0.col1 DIV - cor0.col2 + - col0 FROM tab0 cor0
----
-132
-26
-90

skipif mysql # not compatible
query I rowsort label-7598
SELECT + cor0.col1 / - cor0.col2 + - col0 FROM tab0 cor0
----
-132
-26
-90

query I rowsort
SELECT DISTINCT + + col1 + ( + 98 ) AS col1 FROM tab0 AS cor0
----
184
189
195

query I rowsort
SELECT ALL - + col2 - + 43 AS col2 FROM tab0 AS cor0
----
-125
-44
-76

query I rowsort
SELECT col0 * + 84 + col2 AS col0 FROM tab0 cor0
----
2049
2941
7558

query I rowsort
SELECT ALL cor0.col0 * ( + 38 * col2 ) FROM tab1 AS cor0
----
138624
291840
6156

query I rowsort
SELECT - col1 * + col2 + + cor0.col2 + - col1 FROM tab1 AS cor0
----
-1165
-1376
-523

onlyif mysql # use DIV operator for integer division
query I rowsort label-7604
SELECT DISTINCT + col0 + - col1 * cor0.col0 DIV + 3 FROM tab2 AS cor0
----
-1456
-368
-65

skipif mysql # not compatible
query I rowsort label-7604
SELECT DISTINCT + col0 + - col1 * cor0.col0 / + 3 FROM tab2 AS cor0
----
-1456
-368
-65

query I rowsort
SELECT ALL - 78 + cor0.col0 + col0 FROM tab0 AS cor0
----
-30
-8
100

query I rowsort
SELECT + col0 * col1 + cor0.col0 * + col2 * + cor0.col0 FROM tab2 AS cor0
----
1540
162786
238501

query I rowsort
SELECT DISTINCT col1 + col0 * 1 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT col2 - + col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL 82 + col1 FROM tab2 AS cor0
----
113
141
99

query I rowsort
SELECT ALL + col2 * - tab0.col0 * - 92 FROM tab0
----
3220
671416
72864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col1 ) * - col0 col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL cor0.col0 + col0 * - col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT col0 + col0 * 83 FROM tab0 AS cor0
----
2016
2940
7476

query I rowsort
SELECT 84 + - 46 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT DISTINCT + 59 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 58 * col2 col0 FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT DISTINCT ( - col0 ) + col1 * col2 FROM tab0 cor0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 + + col0 * CAST ( - col1 AS REAL ) col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT tab2.col1 * + col0 * col2 + col0 * col2 FROM tab2
----
121680
54036
6048

query I rowsort
SELECT ALL - + col2 + cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * col2 - + col0 AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT - + col2 + - ( + 34 ) * col0 FROM tab2 cor0
----
-265
-2678
-2724

query I rowsort
SELECT col2 * + 9 FROM tab0 cor0
----
297
738
9

query I rowsort
SELECT + 33 * + 74 - - col0 * ( - col1 ) FROM tab0 AS cor0
----
-5657
-953
378

query I rowsort
SELECT + - col0 * + cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col0 + 33 * + col1 FROM tab2 AS cor0
----
1016
1869
482

query I rowsort
SELECT ALL + col0 * col0 + + ( col1 ) * col2 FROM tab0 AS cor0
----
1322
15383
3414

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7628
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0, tab0 AS cor0, tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7628
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0, tab0 AS cor0, tab1
----
NULL

query I rowsort
SELECT DISTINCT + col1 * ( + col2 ) AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - cor0.col0 AS col0 FROM tab0, tab2, tab1 AS cor0, tab1 AS cor1
----
-3
-64
-80

query I rowsort
SELECT col1 * col2 * tab2.col0 AS col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT - col2 * - col0 + cor0.col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + col0 * 39 * + col0 col1 FROM tab1 AS cor0
----
159754
249613
377

query I rowsort
SELECT 16 * + 10 AS col0 FROM tab2
----
160
160
160

query I rowsort
SELECT - tab0.col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT - - 33 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col0 * - col2 col0 FROM tab1 AS cor0
----
233472
486
614400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7638
SELECT CAST( + 17 AS SIGNED ) + - col2 AS col0 FROM tab1
----
-37
-40
-79

skipif mysql # not compatible
query I rowsort label-7638
SELECT CAST ( + 17 AS INTEGER ) + - col2 AS col0 FROM tab1
----
-37
-40
-79

query I rowsort
SELECT 11 * col2 * + col2 AS col1 FROM tab2
----
15884
7436
8019

query I rowsort
SELECT + 32 + col2 FROM tab0
----
114
33
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7641
SELECT DISTINCT CAST( - col0 * + col1 + ( 27 ) AS SIGNED ) FROM tab0
----
-2037
-3368
-8072

skipif mysql # not compatible
query I rowsort label-7641
SELECT DISTINCT CAST ( - col0 * + col1 + ( 27 ) AS INTEGER ) FROM tab0
----
-2037
-3368
-8072

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 74 * + 56 col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ee5a15f8fdb48d1371fb53c920a0e744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col1 + + 12 col1 FROM tab1 AS cor0
----
12
12
12

query I rowsort
SELECT + + col2 * + col2 * col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT + cor0.col2 + - col1 * - col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT cor0.col0 + - col1 * col2 FROM tab0 cor0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 63 col2 FROM tab0 AS cor0
----
63
63
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col0 * + 69 col1 FROM tab2 AS cor0
----
-14973
-317538
-92667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col0 * + 77 col2 FROM tab2 AS cor0
----
512
5980
6045

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 ( tab1.col2 + col1 * + col2 ) FROM tab1
----
1344
1458
627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7652
SELECT - CAST( + col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7652
SELECT - CAST ( + col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - 43 AS REAL ) FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT + 87 AS col0 FROM tab2, tab2 AS cor0
----
87

query I rowsort
SELECT - - ( + 16 ) AS col1 FROM tab1 AS cor0
----
16
16
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7656
SELECT ALL - col2 * + col1 + - CAST( col0 AS SIGNED ) FROM tab1 cor0
----
-1328
-1407
-634

skipif mysql # not compatible
query I rowsort label-7656
SELECT ALL - col2 * + col1 + - CAST ( col0 AS INTEGER ) FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL col2 + col2 * + col1 + + col1 FROM tab0 AS cor0
----
195
2957
7635

query I rowsort
SELECT + ( + col1 ) * - col2 + - col2 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT - - cor0.col0 + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7660
SELECT ALL col0 + - col0 + CAST( NULL AS SIGNED ) * cor0.col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7660
SELECT ALL col0 + - col0 + CAST ( NULL AS INTEGER ) * cor0.col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + + col2 col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 36 * + col0 + - col0 * tab2.col0 AS col0 FROM tab2
----
-3276
-3397
203

query I rowsort
SELECT col1 * 65 + - 46 AS col2 FROM tab2 AS cor0
----
1059
1969
3789

query I rowsort
SELECT + col1 + col0 * col2 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL ( + cor0.col1 * - cor0.col2 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c52f276f0448e9317aa4a2c462e0bab5

query I rowsort
SELECT DISTINCT col0 + col0 * col1 AS col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT + + col0 + + 38 AS col2 FROM tab0 AS cor0
----
127
62
73

query I rowsort
SELECT - + col0 * + 89 + col1 FROM tab2 AS cor0
----
-592
-6883
-7014

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 * col2 col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL col2 + - 67 * col0 FROM tab1 AS cor0
----
-147
-4231
-5264

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 52 ) + cor0.col0 col1 FROM tab2 cor0
----
130
131
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7672
SELECT + - 67 * + col1 + cor0.col2 DIV CAST( + ( col2 ) AS SIGNED ) + ( col0 * cor0.col1 ) FROM tab1 AS cor0
----
-1663
-29
170

skipif mysql # not compatible
query I rowsort label-7672
SELECT + - 67 * + col1 + cor0.col2 / CAST ( + ( col2 ) AS INTEGER ) + ( col0 * cor0.col1 ) FROM tab1 AS cor0
----
-1663
-29
170

onlyif mysql # use DIV operator for integer division
query I rowsort label-7673
SELECT - ( + ( + col0 ) ) DIV - 14 FROM tab2 AS cor0
----
0
5
5

skipif mysql # not compatible
query I rowsort label-7673
SELECT - ( + ( + col0 ) ) / - 14 FROM tab2 AS cor0
----
0
5
5

query I rowsort
SELECT col0 + 71 AS col2 FROM tab2 AS cor0
----
149
150
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7675
SELECT DISTINCT - col2 DIV col0 AS col0 FROM tab0 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7675
SELECT DISTINCT - col2 / col0 AS col0 FROM tab0 cor0
----
-1
0

query I rowsort
SELECT ALL + 53 * - col1 + col0 AS col0 FROM tab2 AS cor0
----
-1636
-3049
-822

query I rowsort
SELECT - + col2 + col1 + col2 AS col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7678
SELECT - + col1 DIV - col0 AS col1 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-7678
SELECT - + col1 / - col0 AS col1 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + - 29 col0 FROM tab2 AS cor0
----
-12
2
30

query I rowsort
SELECT DISTINCT 97 + 8 * col1 AS col1 FROM tab0 cor0
----
785
825
873

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7681
SELECT ALL - CAST( col1 AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7681
SELECT ALL - CAST ( col1 AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 * 75 + + col2 AS col0 FROM tab2
----
552
5876
5963

query I rowsort
SELECT DISTINCT col0 + tab0.col1 * col0 * - col0 + - ( col1 ) AS col2 FROM tab0
----
-118887
-49598
-720813

query I rowsort
SELECT ALL - 5 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

query I rowsort
SELECT + - 4 + col0 FROM tab2 AS cor0
----
3
74
75

query I rowsort
SELECT DISTINCT - + col1 + - 87 FROM tab1 AS cor0
----
-100
-113
-97

query I rowsort
SELECT ALL - + 94 + - col0 AS col0 FROM tab0 AS cor0
----
-118
-129
-183

query I rowsort
SELECT ( + 71 ) AS col2 FROM tab0 AS cor0
----
71
71
71

query I rowsort
SELECT ALL 63 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT DISTINCT 82 - + col1 AS col0 FROM tab0
----
-15
-4
-9

query I rowsort
SELECT + col1 * + col1 + + cor0.col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL - 57 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT + - cor0.col0 * col1 + + ( - col2 ) * ( + col1 ) * - col0 AS col0 FROM tab1 cor0
----
35840
4134
98800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7694
SELECT - col2 * ( - ( col2 ) ) + ( ( col0 ) + CAST( NULL AS SIGNED ) ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7694
SELECT - col2 * ( - ( col2 ) ) + ( ( col0 ) + CAST ( NULL AS INTEGER ) ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7695
SELECT - col0 + + CAST( col1 AS SIGNED ) * col1 - + col0 AS col2 FROM tab0 AS cor0
----
7348
8103
9339

skipif mysql # not compatible
query I rowsort label-7695
SELECT - col0 + + CAST ( col1 AS INTEGER ) * col1 - + col0 AS col2 FROM tab0 AS cor0
----
7348
8103
9339

query I rowsort
SELECT DISTINCT col1 * cor0.col2 * col2 + - col1 * col0 AS col1 FROM tab1 AS cor0
----
118768
31850
75738

query I rowsort
SELECT DISTINCT col0 + ( col2 ) AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT cor0.col1 * col0 * + col2 + col0 * + col2 * col2 FROM tab1 AS cor0
----
12960
244416
837120

query I rowsort
SELECT DISTINCT 98 * - 99 - cor0.col2 FROM tab1, tab2 cor0
----
-9728
-9729
-9740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 52 + + col1 col0 FROM tab1 AS cor0
----
-2782
-2954
-4979

onlyif mysql # use DIV operator for integer division
query I rowsort label-7701
SELECT ALL + 98 DIV + col1 AS col1 FROM tab1
----
3
7
9

skipif mysql # not compatible
query I rowsort label-7701
SELECT ALL + 98 / + col1 AS col1 FROM tab1
----
3
7
9

query I rowsort
SELECT ALL 7 * cor0.col0 AS col0 FROM tab2 AS cor0
----
49
546
553

query I rowsort
SELECT - + col1 * - ( - col2 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col0 + ( col2 + + ( col0 ) ) AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7705
SELECT ALL - - col0 * cor0.col1 + - col0 DIV + 41 FROM tab0 AS cor0
----
2064
3395
8097

skipif mysql # not compatible
query I rowsort label-7705
SELECT ALL - - col0 * cor0.col1 + - col0 / + 41 FROM tab0 AS cor0
----
2064
3395
8097

query I rowsort
SELECT DISTINCT - + col0 + + col0 * col1 FROM tab1 cor0
----
576
75
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7707
SELECT + + CAST( - 31 AS SIGNED ) + col1 FROM tab0 AS cor0
----
55
60
66

skipif mysql # not compatible
query I rowsort label-7707
SELECT + + CAST ( - 31 AS INTEGER ) + col1 FROM tab0 AS cor0
----
55
60
66

query I rowsort
SELECT ALL - col0 * 64 + - col2 * + ( col0 ) AS col2 FROM tab2 AS cor0
----
-637
-7020
-8058

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 * col1 col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL col1 * col2 + 71 FROM tab2
----
1605
717
908

onlyif mysql # use DIV operator for integer division
query I rowsort label-7711
SELECT DISTINCT 89 * col1 DIV - col1 + + tab0.col0 FROM tab0
----
-54
-65
0

skipif mysql # not compatible
query I rowsort label-7711
SELECT DISTINCT 89 * col1 / - col1 + + tab0.col0 FROM tab0
----
-54
-65
0

query I rowsort
SELECT ( col2 ) * - ( ( - col2 ) + col1 ) AS col1 FROM tab2
----
-108
-858
798

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 66 col0 FROM tab0 AS cor0
----
-66
-66
-66

query I rowsort
SELECT ALL + + cor0.col0 + cor0.col2 AS col2 FROM tab2 cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7715
SELECT ALL + col0 DIV col1 + - ( - col2 ) col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7715
SELECT ALL + col0 / col1 + - ( - col2 ) col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - tab1.col1 + - 31 FROM tab1
----
-41
-44
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7717
SELECT DISTINCT - col2 * + col2 - ( + col0 ) DIV 56 FROM tab0 AS cor0
----
-1
-1089
-6725

skipif mysql # not compatible
query I rowsort label-7717
SELECT DISTINCT - col2 * + col2 - ( + col0 ) / 56 FROM tab0 AS cor0
----
-1
-1089
-6725

query I rowsort
SELECT col2 * + col1 + + 54 AS col0 FROM tab2 AS cor0
----
1588
700
891

query I rowsort
SELECT ALL - col0 * + col1 * col1 + - col1 * ( ( - col2 ) * + col0 ) AS col2 FROM tab1 cor0
----
2184
30080
86320

query I rowsort
SELECT ALL cor0.col1 + 48 FROM tab2 AS cor0
----
107
65
79

query I rowsort
SELECT DISTINCT col0 + + 75 AS col1 FROM tab1 cor0
----
139
155
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7722
SELECT DISTINCT + cor0.col2 + - col2 * col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7722
SELECT DISTINCT + cor0.col2 + - col2 * col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7723
SELECT - - 40 DIV + col0 AS col1 FROM tab1 AS cor0
----
0
0
13

skipif mysql # not compatible
query I rowsort label-7723
SELECT - - 40 / + col0 AS col1 FROM tab1 AS cor0
----
0
0
13

query I rowsort
SELECT ALL + - ( + 90 ) FROM tab0 AS cor0
----
-90
-90
-90

query I rowsort
SELECT DISTINCT - + 88 + - 2 * + col2 AS col2 FROM tab1 AS cor0
----
-196
-202
-280

query I rowsort
SELECT ALL 45 + + col0 AS col0 FROM tab0 AS cor0
----
134
69
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7727
SELECT ALL - + col2 DIV + col2 + + col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-7727
SELECT ALL - + col2 / + col2 + + col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT DISTINCT + + col2 * col1 + col2 + - ( - 81 ) FROM tab0 AS cor0
----
179
2952
7625

onlyif mysql # use DIV operator for integer division
query I rowsort label-7729
SELECT ALL + col1 DIV + col2 + col2 AS col0 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-7729
SELECT ALL + col1 / + col2 + col2 AS col0 FROM tab0 AS cor0
----
35
83
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 33 col1 FROM tab2 AS cor0
----
33
33
33

query I rowsort
SELECT DISTINCT - col2 * + ( cor0.col0 + col1 ) FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT ALL 48 + col1 AS col0 FROM tab1 cor0
----
58
61
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7733
SELECT DISTINCT - cor0.col2 DIV + col2 col0 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7733
SELECT DISTINCT - cor0.col2 / + col2 col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - 60 - - 75 FROM tab1 AS cor0
----
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7735
SELECT ALL CAST( col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7735
SELECT ALL CAST ( col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + 76 + col0 FROM tab2 AS cor0
----
154
155
83

query I rowsort
SELECT + col2 + + 69 * col1 FROM tab2 AS cor0
----
1211
2166
4097

query I rowsort
SELECT + + 75 * - 2 + - col0 AS col1 FROM tab2 AS cor0
----
-157
-228
-229

query I rowsort
SELECT cor0.col1 * col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT col2 + 38 FROM tab2
----
64
65
76

query I rowsort
SELECT - col1 * 81 + + 22 * + cor0.col0 * - 6 FROM tab1 AS cor0
----
-11613
-2502
-9258

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7742
SELECT + cor0.col1 * ( - 56 ) + + col2 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7742
SELECT + cor0.col1 * ( - 56 ) + + col2 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col2 * 97 AS col2 FROM tab1 AS cor0
----
5238
5529
9312

query I rowsort
SELECT + col1 * + cor0.col2 * col1 + col2 FROM tab1 AS cor0
----
16320
36558
5757

query I rowsort
SELECT + - col1 * cor0.col1 - - 17 AS col2 FROM tab1 AS cor0
----
-152
-659
-83

query I rowsort
SELECT ALL col1 + col1 + tab1.col2 AS col2 FROM tab1
----
106
122
77

query I rowsort
SELECT + 75 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

onlyif mysql # use DIV operator for integer division
query I rowsort label-7748
SELECT - 36 DIV col0 + 45 FROM tab1
----
33
45
45

skipif mysql # not compatible
query I rowsort label-7748
SELECT - 36 / col0 + 45 FROM tab1
----
33
45
45

query I rowsort
SELECT ALL - col2 * + col2 * col0 + + ( - col0 ) AS col1 FROM tab2
----
-114155
-5110
-52806

query I rowsort
SELECT ALL + 52 + + col2 AS col1 FROM tab0
----
134
53
85

query I rowsort
SELECT ALL + 4 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + + col1 + - 3 FROM tab2 cor0
----
14
28
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + cor0.col2 * col2 col1 FROM tab2 AS cor0
----
17576
19683
54872

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 * CAST ( col1 + + col0 AS REAL ) * col0 FROM tab0 AS cor0
----
1313640
4620
87120

query I rowsort
SELECT DISTINCT tab1.col1 * + 49 AS col2 FROM tab1, tab0 AS cor0
----
1274
490
637

onlyif mysql # use DIV operator for integer division
query I rowsort label-7756
SELECT ALL - ( col0 ) DIV ( - 71 ) + - col1 FROM tab1
----
-10
-12
-26

skipif mysql # not compatible
query I rowsort label-7756
SELECT ALL - ( col0 ) / ( - 71 ) + - col1 FROM tab1
----
-10
-12
-26

query I rowsort
SELECT DISTINCT ( - tab2.col1 ) FROM tab2
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 61 col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

onlyif mysql # use DIV operator for integer division
query I rowsort label-7759
SELECT + col2 DIV 23 FROM tab1 AS cor0
----
2
2
4

skipif mysql # not compatible
query I rowsort label-7759
SELECT + col2 / 23 FROM tab1 AS cor0
----
2
2
4

query I rowsort
SELECT - + cor0.col2 * - col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - - col2 + col1 * col2 AS col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + - col2 * - col0 + + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - - col2 + 24 * - 23 * col2 FROM tab1 AS cor0
----
-29754
-31407
-52896

query I rowsort
SELECT ALL + cor0.col1 * + 37 * - col1 FROM tab1 AS cor0
----
-25012
-3700
-6253

query I rowsort
SELECT col0 + - cor0.col1 + - col2 AS col2 FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT DISTINCT + + cor0.col2 * col0 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-7767
SELECT ALL + col2 DIV + 27 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7767
SELECT ALL + col2 / + 27 FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT col0 * - col0 + ( + col2 ) FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT + col1 * - col1 + col0 AS col2 FROM tab0 cor0
----
-7372
-8192
-9374

query I rowsort
SELECT + 7 + col1 AS col2 FROM tab1 AS cor0
----
17
20
33

query I rowsort
SELECT DISTINCT - 63 AS col1 FROM tab0
----
-63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7772
SELECT + col2 * col1 + + cor0.col0 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7772
SELECT + col2 * col1 + + cor0.col0 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + + ( + cor0.col1 ) * - col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT 4 + + 92 AS col1 FROM tab0 AS cor0
----
96
96
96

query I rowsort
SELECT ( - cor0.col1 ) * col2 - + col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7776
SELECT DISTINCT - col2 * col1 * + CAST( - col0 * cor0.col2 AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
2079424
227451
9584720

skipif mysql # not compatible
query I rowsort label-7776
SELECT DISTINCT - col2 * col1 * + CAST ( - col0 * cor0.col2 AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
2079424
227451
9584720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 82 + col2 col0 FROM tab0 AS cor0
----
-49
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 4 col1 FROM tab0 AS cor0
----
4

query I rowsort
SELECT DISTINCT col1 * + cor0.col2 * col2 + + col1 FROM tab2 AS cor0
----
22630
24565
39943

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 col2 FROM tab1 AS cor0
----
82
82
82

query I rowsort
SELECT - col1 + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1322
-662
-8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-7782
SELECT ALL col2 * + col0 - 75 DIV - cor0.col2 FROM tab0 AS cor0
----
110
7298
794

skipif mysql # not compatible
query I rowsort label-7782
SELECT ALL col2 * + col0 - 75 / - cor0.col2 FROM tab0 AS cor0
----
110
7298
794

query I rowsort
SELECT DISTINCT - + 70 AS col2 FROM tab0 AS cor0
----
-70

query I rowsort
SELECT ALL - 54 - col1 AS col1 FROM tab2 AS cor0
----
-113
-71
-85

query I rowsort
SELECT ALL + + ( col2 ) * col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-7786
SELECT tab1.col0 * ( col2 ) DIV tab1.col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7786
SELECT tab1.col0 * ( col2 ) / tab1.col2 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7787
SELECT + ( 68 ) DIV + col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7787
SELECT + ( 68 ) / + col0 FROM tab0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 66 col2 FROM tab1, tab2 cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

onlyif mysql # use DIV operator for integer division
query I rowsort label-7789
SELECT DISTINCT 98 DIV col0 FROM tab0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-7789
SELECT DISTINCT 98 / col0 FROM tab0
----
1
2
4

query I rowsort
SELECT ALL 71 * + col0 FROM tab0 AS cor0
----
1704
2485
6319

query I rowsort
SELECT ALL - 67 * col0 * ( - ( cor0.col2 ) ) FROM tab1 AS cor0
----
10854
244416
514560

query I rowsort
SELECT ALL + - 79 * - col2 FROM tab2 cor0
----
2054
2133
3002

query I rowsort
SELECT col1 + + col0 - 18 AS col1 FROM tab1 AS cor0
----
11
56
75

query I rowsort
SELECT + cor0.col2 + + col2 * 86 AS col2 FROM tab0 AS cor0
----
2871
7134
87

query I rowsort
SELECT ALL + col0 + 89 FROM tab2 AS cor0
----
167
168
96

query I rowsort
SELECT DISTINCT + cor0.col1 * - col0 * + 49 AS col1 FROM tab1 cor0
----
-31360
-3822
-50960

query I rowsort
SELECT - col1 * ( col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 * - ( tab0.col1 ) col1 FROM tab0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 57 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT DISTINCT + col0 + col2 * + col2 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT col1 - col1 * col1 FROM tab2
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT tab1.col0 + col0 * ( col0 ) FROM tab1
----
12
4160
6480

query I rowsort
SELECT DISTINCT 67 + - col0 FROM tab1 AS cor0
----
-13
3
64

query I rowsort
SELECT + + 65 * + 12 * col1 FROM tab0 AS cor0
----
67080
70980
75660

query I rowsort
SELECT DISTINCT ( col1 ) * + col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7806
SELECT ALL + cor0.col1 DIV - col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7806
SELECT ALL + cor0.col1 / - col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - - ( - cor0.col2 ) * + col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT 66 FROM tab1, tab2 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 cor1, tab2, tab1 AS cor2
----
3645 values hashing to c0625992cd48bef51317edf43a55d9e4

query I rowsort
SELECT ALL ( + col1 ) * col2 - - ( - col1 ) AS col1 FROM tab2
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7811
SELECT DISTINCT - CAST( 81 AS SIGNED ) + col0 - - col1 FROM tab1
----
-52
-7
12

skipif mysql # not compatible
query I rowsort label-7811
SELECT DISTINCT - CAST ( 81 AS INTEGER ) + col0 - - col1 FROM tab1
----
-52
-7
12

query I rowsort
SELECT DISTINCT + col2 * + col1 - col1 AS col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT + 74 - - col2 AS col0 FROM tab1
----
128
131
170

query I rowsort
SELECT + col0 * + col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + + cor0.col2 + + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT - col1 + col0 * - col2 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT - col1 * ( col2 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col2 + + col2 * + cor0.col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL - col1 + ( 38 ) AS col1 FROM tab1 AS cor0
----
12
25
28

query I rowsort
SELECT DISTINCT cor0.col2 * ( + ( + col2 ) * col1 ) FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7821
SELECT ALL + cor0.col1 DIV 30 FROM tab0 cor0
----
2
3
3

skipif mysql # not compatible
query I rowsort label-7821
SELECT ALL + cor0.col1 / 30 FROM tab0 cor0
----
2
3
3

query I rowsort
SELECT + + col2 * + ( + col0 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT 5 * + col0 AS col1 FROM tab1
----
15
320
400

query I rowsort
SELECT 8 + col1 FROM tab0
----
105
94
99

query I rowsort
SELECT ALL - cor0.col1 * - ( - col2 * col0 ) AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-7826
SELECT DISTINCT + col2 DIV - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-7826
SELECT DISTINCT + col2 / - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ALL - col0 * - ( + col0 ) FROM tab2 AS cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ( tab1.col1 ) * + col2 + + 81 FROM tab1
----
1329
1485
651

query I rowsort
SELECT - + cor0.col0 * 27 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 30daa29f4cd03eb157c2346a198a49f9

query I rowsort
SELECT - ( + col2 ) * col2 + col1 AS col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT ( col0 * col2 ) + col0 * - col0 FROM tab0
----
-1190
-623
216

query I rowsort
SELECT DISTINCT 78 + - col0 AS col2 FROM tab1
----
-2
14
75

query I rowsort
SELECT DISTINCT 82 * + col1 * tab1.col2 AS col0 FROM tab1
----
102336
115128
46740

query I rowsort
SELECT - cor0.col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL + tab2.col0 * tab2.col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT 30 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7838
SELECT DISTINCT col2 + + col2 * - CAST( 86 AS SIGNED ) FROM tab0 cor0
----
-2805
-6970
-85

skipif mysql # not compatible
query I rowsort label-7838
SELECT DISTINCT col2 + + col2 * - CAST ( 86 AS INTEGER ) FROM tab0 cor0
----
-2805
-6970
-85

query I rowsort
SELECT + 56 * col0 + - col0 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT - col2 + - col1 * 93 FROM tab1 AS cor0
----
-1305
-2472
-987

query I rowsort
SELECT - 13 + col2 AS col1 FROM tab2 AS cor0
----
13
14
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-7842
SELECT col0 DIV + col2 + col1 AS col2 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-7842
SELECT col0 / + col2 + col1 AS col2 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT + + ( col2 ) * cor0.col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + tab2.col2 * col0 * + col0 + col0 AS col2 FROM tab2
----
1330
158262
237237

query I rowsort
SELECT ALL 34 * - col1 FROM tab0 AS cor0
----
-2924
-3094
-3298

query I rowsort
SELECT + ( 26 ) AS col2 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT ALL - - 89 * col0 AS col1 FROM tab0 AS cor0
----
2136
3115
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-7848
SELECT ALL col0 * 64 DIV col1 col1 FROM tab1 AS cor0
----
393
409
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7848
SELECT ALL col0 * 64 / col1 col1 FROM tab1 AS cor0
----
393
409
7

query I rowsort
SELECT ( + 87 ) FROM tab1
----
87
87
87

query I rowsort
SELECT 11 + + col0 FROM tab1 cor0
----
14
75
91

query I rowsort
SELECT 46 * + cor0.col2 FROM tab1 cor0
----
2484
2622
4416

onlyif mysql # use DIV operator for integer division
query I rowsort label-7852
SELECT - - col0 DIV - col1 - col2 FROM tab1 AS cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-7852
SELECT - - col0 / - col1 - col2 FROM tab1 AS cor0
----
-102
-54
-63

query I rowsort
SELECT - col2 - + col1 * - col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT + 79 * cor0.col0 + - col0 FROM tab1 AS cor0
----
234
4992
6240

query I rowsort
SELECT - + col1 * cor0.col1 + col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT - col0 * col0 - - col2 * - col0 FROM tab0 AS cor0
----
-1260
-1368
-15219

onlyif mysql # use DIV operator for integer division
query I rowsort label-7857
SELECT ALL ( - ( - col2 ) ) DIV col1 + col0 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-7857
SELECT ALL ( - ( - col2 ) ) / col1 + col0 FROM tab2
----
7
78
81

query I rowsort
SELECT DISTINCT col2 + tab1.col2 * + col1 AS col0 FROM tab1
----
1344
1458
627

query I rowsort
SELECT - col2 + col0 + col0 * - ( + cor0.col0 ) AS col1 FROM tab1 cor0
----
-4089
-60
-6416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7860
SELECT ALL col2 + + ( col0 ) - CAST( - ( col1 ) AS SIGNED ) * 34 FROM tab0 AS cor0
----
2981
3265
3334

skipif mysql # not compatible
query I rowsort label-7860
SELECT ALL col2 + + ( col0 ) - CAST ( - ( col1 ) AS INTEGER ) * 34 FROM tab0 AS cor0
----
2981
3265
3334

query I rowsort
SELECT ALL + 84 AS col0 FROM tab2 AS cor0
----
84
84
84

query I rowsort
SELECT ALL - ( col1 ) * col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + + 86 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to bb6428239bf7f3ea361f6a10500a581d

query I rowsort
SELECT ALL - 46 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT DISTINCT tab2.col0 + 87 * col0 AS col2 FROM tab2
----
616
6864
6952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7867
SELECT - CAST( NULL AS SIGNED ) + - col1 * col0 * + col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7867
SELECT - CAST ( NULL AS INTEGER ) + - col1 * col0 * + col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( col1 AS REAL ) * + col2 + 68 AS col2 FROM tab1 AS cor0
----
-1180
-1336
-502

onlyif mysql # use DIV operator for integer division
query I rowsort label-7869
SELECT - col0 DIV 33 + + col2 FROM tab2
----
24
27
36

skipif mysql # not compatible
query I rowsort label-7869
SELECT - col0 / 33 + + col2 FROM tab2
----
24
27
36

query I rowsort
SELECT ALL + 27 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT DISTINCT - 37 AS col0 FROM tab0, tab0 AS cor0
----
-37

query I rowsort
SELECT DISTINCT - col1 + + col2 * col0 FROM tab2
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-7873
SELECT ALL - ( + ( + tab1.col0 ) ) + 6 DIV 8 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-7873
SELECT ALL - ( + ( + tab1.col0 ) ) + 6 / 8 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + 44 * col1 + - col1 FROM tab0
----
3698
3913
4171

query I rowsort
SELECT DISTINCT + col0 + col1 * + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - col2 * + col1 - + ( - col1 ) FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT 88 FROM tab1, tab2, tab2 cor0
----
88

query I rowsort
SELECT + col0 + 48 AS col1 FROM tab0 AS cor0
----
137
72
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7879
SELECT DISTINCT - col1 + + col1 DIV 5 FROM tab2 AS cor0
----
-14
-25
-48

skipif mysql # not compatible
query I rowsort label-7879
SELECT DISTINCT - col1 + + col1 / 5 FROM tab2 AS cor0
----
-14
-25
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-7880
SELECT DISTINCT - col1 DIV ( col2 ) AS col0 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-7880
SELECT DISTINCT - col1 / ( col2 ) AS col0 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT ALL - + col0 * 48 * - col0 + cor0.col1 AS col2 FROM tab0 cor0
----
27734
380299
58897

query I rowsort
SELECT + col1 * col1 * - col1 FROM tab0 AS cor0
----
-636056
-753571
-912673

query I rowsort
SELECT - col2 + + col1 * - col0 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT + col1 * - col1 + col1 AS col1 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT 38 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
38

query I rowsort
SELECT cor1.col2 + cor1.col2 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 82040855cb50fa1e428b3499d58f252b

query I rowsort
SELECT DISTINCT cor0.col0 + - ( 67 ) FROM tab2 AS cor0
----
-60
11
12

query I rowsort
SELECT ALL ( 87 ) * - col2 FROM tab0 AS cor0
----
-2871
-7134
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + col1 AS REAL ) col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - 68 * + col2 * col0 + col2 AS col0 FROM tab2 AS cor0
----
-12825
-137878
-204098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 + col1 col1 FROM tab0 AS cor0
----
122
127
133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 20 * + col2 col2 FROM tab2 AS cor0
----
520
540
760

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - 25 * - ( col1 ) + CAST ( col2 + - col1 AS REAL ) AS col1 FROM tab0 AS cor0
----
-2203
-2284
-2521

query I rowsort
SELECT 72 * col1 + - col2 FROM tab2 AS cor0
----
1186
2205
4222

query I rowsort
SELECT + 96 + col2 FROM tab0 AS cor0
----
129
178
97

query I rowsort
SELECT ALL + col0 + - 27 FROM tab0 AS cor0
----
-3
62
8

query I rowsort
SELECT 48 + - 66 * col1 - - col2 AS col2 FROM tab1 AS cor0
----
-1614
-555
-714

query I rowsort
SELECT col0 * - 0 + 12 AS col0 FROM tab0
----
12
12
12

query I rowsort
SELECT - 25 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

onlyif mysql # use DIV operator for integer division
query I rowsort label-7900
SELECT DISTINCT + col2 DIV + 40 - ( tab2.col2 * 57 ) AS col0 FROM tab2
----
-1482
-1539
-2166

skipif mysql # not compatible
query I rowsort label-7900
SELECT DISTINCT + col2 / + 40 - ( tab2.col2 * 57 ) AS col0 FROM tab2
----
-1482
-1539
-2166

query I rowsort
SELECT + ( + 94 ) FROM tab2 AS cor0
----
94
94
94

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( col0 AS REAL ) AS col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7903
SELECT col2 + 73 DIV col1 FROM tab1 AS cor0
----
101
56
64

skipif mysql # not compatible
query I rowsort label-7903
SELECT col2 + 73 / col1 FROM tab1 AS cor0
----
101
56
64

query I rowsort
SELECT ALL + + 75 * + col1 * col0 AS col2 FROM tab2 AS cor0
----
100725
16275
345150

query I rowsort
SELECT DISTINCT + - 30 * 96 FROM tab2 AS cor0
----
-2880

query I rowsort
SELECT ALL + ( - cor0.col0 ) * col0 FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7907
SELECT DISTINCT - col2 DIV - cor0.col1 + col1 * ( 35 ) + - col1 FROM tab1 AS cor0
----
345
449
886

skipif mysql # not compatible
query I rowsort label-7907
SELECT DISTINCT - col2 / - cor0.col1 + col1 * ( 35 ) + - col1 FROM tab1 AS cor0
----
345
449
886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 33 + col2 col1 FROM tab0 AS cor0
----
-32
0
49

query I rowsort
SELECT - - 39 * col2 FROM tab0 AS cor0
----
1287
3198
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7910
SELECT ALL + + col1 + col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7910
SELECT ALL + + col1 + col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 78 + + col2 AS col1 FROM tab1 AS cor0
----
132
135
174

query I rowsort
SELECT ALL + - 36 * cor0.col2 + col1 FROM tab0 AS cor0
----
-1102
-2861
61

query I rowsort
SELECT - 82 + col1 FROM tab1 AS cor0
----
-56
-69
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-7914
SELECT DISTINCT + + cor0.col2 DIV - col0 - - col0 FROM tab0 cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-7914
SELECT DISTINCT + + cor0.col2 / - col0 - - col0 FROM tab0 cor0
----
23
35
89

query I rowsort
SELECT + - col2 * cor0.col0 + 7 * col0 AS col1 FROM tab0 AS cor0
----
-624
-6675
210

query I rowsort
SELECT DISTINCT 64 * + 40 AS col0 FROM tab0
----
2560

query I rowsort
SELECT ALL + ( cor0.col1 ) + - col1 * col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT - 84 * + cor0.col2 - - 44 AS col1 FROM tab0 cor0
----
-2728
-40
-6844

query I rowsort
SELECT - ( col2 ) * - 37 * 96 + col2 FROM tab1 AS cor0
----
191862
202521
341088

query I rowsort
SELECT ALL col0 + - col0 * - col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-7921
SELECT DISTINCT + + col0 * + col1 + col2 DIV + col0 FROM tab2 AS cor0
----
1343
220
4602

skipif mysql # not compatible
query I rowsort label-7921
SELECT DISTINCT + + col0 * + col1 + col2 / + col0 FROM tab2 AS cor0
----
1343
220
4602

query I rowsort
SELECT col1 + + 76 * ( - col1 ) AS col1 FROM tab2 cor0
----
-1275
-2325
-4425

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + 97 col2 FROM tab1 AS cor0
----
-1261
-2522
-970

query I rowsort
SELECT DISTINCT + + col0 + + col0 + col0 AS col2 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) * col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + cor0.col2 * col1 + col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7928
SELECT ALL col0 * + col0 + col1 DIV - col0 FROM tab0 AS cor0
----
1223
573
7920

skipif mysql # not compatible
query I rowsort label-7928
SELECT ALL col0 * + col0 + col1 / - col0 FROM tab0 AS cor0
----
1223
573
7920

query I rowsort
SELECT ALL + col1 + - col1 * col1 + - 67 AS col2 FROM tab2 AS cor0
----
-339
-3489
-997

query I rowsort
SELECT col1 * cor0.col0 + - col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL + + 11 + col0 AS col1 FROM tab0 AS cor0
----
100
35
46

query I rowsort
SELECT DISTINCT 55 * col2 - - col2 FROM tab1 cor0
----
3024
3192
5376

query I rowsort
SELECT col0 - - col1 * - 4 FROM tab0 AS cor0
----
-275
-320
-353

query I rowsort
SELECT - ( 48 ) + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 260c8be135eb122ce2cb63749850447d

query I rowsort
SELECT DISTINCT cor1.col2 * 51 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
1326
1377
1938

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * cor0.col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT - - ( - col1 ) + col2 * col1 FROM tab2 AS cor0
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-7939
SELECT ALL col1 DIV - 37 AS col2 FROM tab0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-7939
SELECT ALL col1 / - 37 AS col2 FROM tab0
----
-2
-2
-2

query I rowsort
SELECT 71 * + 67 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 8397f784e0cb9200534faa438e9c2e6e

query I rowsort
SELECT DISTINCT + col2 + + 68 FROM tab0 cor0
----
101
150
69

query I rowsort
SELECT - col2 + + 24 FROM tab0 AS cor0
----
-58
-9
23

query I rowsort
SELECT DISTINCT - ( col0 ) + col0 * + ( col1 * col2 ) FROM tab2 AS cor0
----
119574
50955
5852

query I rowsort
SELECT col1 * col1 * - col1 AS col2 FROM tab0
----
-636056
-753571
-912673

onlyif mysql # use DIV operator for integer division
query I rowsort label-7945
SELECT + col1 - + col1 DIV 94 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7945
SELECT + col1 - + col1 / 94 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 34 * col2 AS col0 FROM tab0
----
1122
2788
34

query I rowsort
SELECT - + 76 * - col0 + - ( col2 ) AS col2 FROM tab1 AS cor0
----
174
4807
5984

query I rowsort
SELECT + - col2 * col1 + 53 + + col0 FROM tab2 cor0
----
-1403
-514
-777

query I rowsort
SELECT - ( + cor0.col0 ) + cor0.col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT + col2 * + col0 + - col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT DISTINCT + - tab2.col2 * 74 AS col0 FROM tab2, tab1, tab0 AS cor0
----
-1924
-1998
-2812

query I rowsort
SELECT DISTINCT 12 AS col1 FROM tab1, tab1 AS cor0, tab1 cor1
----
12

query I rowsort
SELECT - 75 * - 34 FROM tab1, tab2 AS cor0
----
9 values hashing to 47f370ced2b2b7be7e40c5b86589a252

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * + col2 - 80 col2 FROM tab1 cor0
----
-2996
-3329
-9296

query I rowsort
SELECT DISTINCT 8 * - cor1.col0 * + 95 AS col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
-18240
-26600
-67640

query I rowsort
SELECT DISTINCT - ( - col1 ) AS col1 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 11 + - 46 col1 FROM tab1 AS cor0
----
-35
-35
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7958
SELECT ALL - col0 * col1 + col0 + 31 DIV ( - col1 ) AS col1 FROM tab2 AS cor0
----
-1265
-211
-4524

skipif mysql # not compatible
query I rowsort label-7958
SELECT ALL - col0 * col1 + col0 + 31 / ( - col1 ) AS col1 FROM tab2 AS cor0
----
-1265
-211
-4524

query I rowsort
SELECT DISTINCT + col2 * ( col2 + + col0 ) FROM tab2 AS cor0
----
2704
4446
918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 * + col2 col0 FROM tab0 AS cor0
----
-2739
-6806
-83

query I rowsort
SELECT + col1 + col0 * 55 * col0 FROM tab1
----
225290
352013
521

query I rowsort
SELECT + ( - 18 ) + + col2 * - col0 AS col0 FROM tab1 AS cor0
----
-180
-3666
-7698

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( + col0 * + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7964
SELECT DISTINCT col1 DIV col0 + + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1223
-573
-7920

skipif mysql # not compatible
query I rowsort label-7964
SELECT DISTINCT col1 / col0 + + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1223
-573
-7920

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) NOT BETWEEN col0 + - col1 AND NULL
----

query I rowsort
SELECT - col1 + + col1 * + col1 AS col2 FROM tab0
----
7310
8190
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-7967
SELECT DISTINCT + col1 DIV col1 - col0 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7967
SELECT DISTINCT + col1 / col1 - col0 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT col2 * - tab0.col0 * col0 - - col2 FROM tab0
----
-1224
-18975
-649440

onlyif mysql # use DIV operator for integer division
query I rowsort label-7969
SELECT ALL + col1 DIV + col2 - col1 AS col0 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7969
SELECT ALL + col1 / + col2 - col1 AS col0 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7970
SELECT ALL - col2 DIV - col0 AS col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7970
SELECT ALL - col2 / - col0 AS col0 FROM tab0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7971
SELECT col2 DIV - col1 + col2 * col1 + col0 AS col2 FROM tab1
----
1321
1405
629

skipif mysql # not compatible
query I rowsort label-7971
SELECT col2 / - col1 + col2 * col1 + col0 AS col2 FROM tab1
----
1321
1405
629

onlyif mysql # use DIV operator for integer division
query I rowsort label-7972
SELECT col2 * tab1.col0 DIV + col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7972
SELECT col2 * tab1.col0 / + col0 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT col0 * - tab1.col2 + col1 * - col2 FROM tab1
----
-1566
-4218
-8928

onlyif mysql # use DIV operator for integer division
query I rowsort label-7974
SELECT + col0 DIV - col0 + - col2 AS col1 FROM tab0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-7974
SELECT + col0 / - col0 + - col2 AS col1 FROM tab0
----
-2
-34
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7975
SELECT - col0 * - col0 DIV col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7975
SELECT - col0 * - col0 / col0 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT - + col0 - - col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - col2 + + col2 * cor0.col0 + + col1 FROM tab0 AS cor0
----
131
7307
845

query I rowsort
SELECT ALL + - cor0.col1 * + cor0.col2 + col2 * col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT + - col1 * - col2 * - col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL + + col1 * - col2 * col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL col0 * + col2 * + col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + col2 * tab0.col2 * col0 AS col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT + col0 * col0 - col1 * - col2 FROM tab1
----
1413
4666
7648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 col2 FROM tab1 AS cor0 CROSS JOIN tab0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT + col2 * - col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT col1 * + col2 + col0 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT + 24 AS col0 FROM tab2
----
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7990
SELECT tab2.col0 - col2 DIV + 44 AS col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7990
SELECT tab2.col0 - col2 / + 44 AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT - cor0.col1 AS col0 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

onlyif mysql # use DIV operator for integer division
query I rowsort label-7992
SELECT + - cor0.col0 DIV - 25 FROM tab1 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-7992
SELECT + - cor0.col0 / - 25 FROM tab1 AS cor0
----
0
2
3

query I rowsort
SELECT DISTINCT - - col2 * col2 + - col0 AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT DISTINCT - ( + col2 + col1 ) * - col0 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT - - 68 + col1 AS col1 FROM tab1 AS cor0
----
78
81
94

query I rowsort
SELECT 52 * col2 * + col0 AS col2 FROM tab0
----
1820
379496
41184

query I rowsort
SELECT col2 + cor0.col0 * - cor0.col0 FROM tab1 cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT - col1 * - 18 FROM tab1 AS cor0
----
180
234
468

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * col2 col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL - col2 * - cor0.col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - + col2 + + 28 AS col1 FROM tab0 cor0
----
-5
-54
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-8002
SELECT - col0 + col1 DIV 84 col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8002
SELECT - col0 + col1 / 84 col0 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8003
SELECT DISTINCT + col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8003
SELECT DISTINCT + col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 * + 77 AS col1 FROM tab2 AS cor0
----
-539
-6006
-6083

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8005
SELECT ALL col2 / 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-8005
SELECT ALL col2 / CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * 97 AS col2 FROM tab2 AS cor0
----
2522
2619
3686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * tab1.col2 col1 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-8008
SELECT col2 DIV + col0 + + col1 + + col2 * col2 DIV col1 FROM tab2
----
101
57
70

skipif mysql # not compatible
query I rowsort label-8008
SELECT col2 / + col0 + + col1 + + col2 * col2 / col1 FROM tab2
----
101
57
70

query I rowsort
SELECT DISTINCT + col1 * col0 * - col0 AS col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT ALL tab2.col2 * - col1 + col0 * col2 * + col0 AS col2 FROM tab2
----
156650
236512
486

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) <> ( - col2 )
----

query I rowsort
SELECT tab0.col1 * col2 * col0 + - col2 FROM tab0
----
3394
664036
68079

onlyif mysql # use DIV operator for integer division
query I rowsort label-8013
SELECT + col1 * tab1.col0 + col1 DIV - col2 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-8013
SELECT + col1 * tab1.col0 + col1 / - col2 FROM tab1
----
1040
640
78

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT BETWEEN ( + col2 ) AND NULL
----

query I rowsort
SELECT - col1 * col1 * col0 + + col2 FROM tab0
----
-177471
-329314
-736927

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + tab2.col1 col0 FROM tab2 WHERE col2 * - col1 + + col0 <> NULL
----

query I rowsort
SELECT + col2 * col1 * col1 AS col2 FROM tab2
----
10982
25947
90506

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col2 + col0 > + col0 / - tab0.col2 + - col1
----

query I rowsort
SELECT ALL col0 * col2 + tab2.col2 * tab2.col0 FROM tab2
----
378
4056
6004

query I rowsort
SELECT col1 FROM tab0 WHERE NULL NOT IN ( - col0 + + tab0.col1 * + col2 + col2 * col1 )
----

query I rowsort
SELECT DISTINCT col0 * + col2 + - col2 AS col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT ALL col0 - - col1 * + col1 FROM tab2
----
3559
368
968

query I rowsort
SELECT DISTINCT - col0 * + col0 * col2 + - col1 * + col0 FROM tab2
----
-1540
-162786
-238501

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 17 + cor0.col0 * col1 col0 FROM tab2 AS cor0
----
1360
234
4619

onlyif mysql # use DIV operator for integer division
query I rowsort label-8025
SELECT 21 DIV - col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-8025
SELECT 21 / - col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT - - cor0.col2 + + col0 + + cor0.col0 * + 11 * + col1 AS col1 FROM tab1 AS cor0
----
11616
7161
915

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8027
SELECT DISTINCT + CAST( + 6 AS SIGNED ) AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
6

skipif mysql # not compatible
query I rowsort label-8027
SELECT DISTINCT + CAST ( + 6 AS INTEGER ) AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 + + col2 col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT col0 * col0 + tab1.col0 * tab1.col2 FROM tab1
----
14080
171
7744

query I rowsort
SELECT ALL - col2 + - col2 + col1 FROM tab1
----
-104
-179
-82

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( + col0 + - col0 ) <> NULL
----

query I rowsort
SELECT ALL + 91 * cor0.col2 FROM tab0 AS cor0
----
3003
7462
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - 81 col1 FROM tab0
----
-46
-57
8

query I rowsort
SELECT ALL col2 * - tab1.col2 + + col1 * col1 + - col0 AS col1 FROM tab1
----
-2243
-3213
-9127

query I rowsort
SELECT ALL + 42 FROM tab0, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT ALL - col2 * + 65 + 21 FROM tab0
----
-2124
-44
-5309

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 87 + ( + col1 ) * - ( 89 ) col1 FROM tab2
----
-1409
-2641
-5105

query I rowsort
SELECT ALL - - col2 + - col1 * - col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - ( 14 ) FROM tab2, tab0 cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT + col1 * ( - col0 ) AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + - 82 * 71 AS col2 FROM tab2 AS cor0
----
-5822
-5822
-5822

query I rowsort
SELECT DISTINCT - 34 * col1 AS col1 FROM tab2 AS cor0
----
-1054
-2006
-578

onlyif mysql # use DIV operator for integer division
query I rowsort label-8043
SELECT DISTINCT - + col1 + - col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-8043
SELECT DISTINCT - + col1 + - col0 / - col0 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8044
SELECT ALL - 66 * - ( col1 + CAST( col1 AS SIGNED ) ) DIV + col1 AS col2 FROM tab0 AS cor0
----
132
132
132

skipif mysql # not compatible
query I rowsort label-8044
SELECT ALL - 66 * - ( col1 + CAST ( col1 AS INTEGER ) ) / + col1 AS col2 FROM tab0 AS cor0
----
132
132
132

onlyif mysql # use DIV operator for integer division
query I rowsort label-8045
SELECT - cor0.col0 - + col1 DIV - col1 AS col2 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-8045
SELECT - cor0.col0 - + col1 / - col1 AS col2 FROM tab2 AS cor0
----
-6
-77
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-8046
SELECT + 39 DIV + 32 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8046
SELECT + 39 / + 32 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT - - ( 7 ) * col2 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT ( - col0 ) + - col1 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT cor0.col2 * + col2 + col0 - - col0 * + col2 AS col1 FROM tab0 AS cor0
----
14111
1905
71

query I rowsort
SELECT ( - cor0.col2 ) * + col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT 57 * + col1 * + col0 - 13 FROM tab1 AS cor0
----
36467
4433
59267

query I rowsort
SELECT DISTINCT - ( col2 + - ( col2 ) ) * col1 FROM tab0
----
0

query I rowsort
SELECT DISTINCT + 93 + cor0.col0 FROM tab2 cor0
----
100
171
172

query I rowsort
SELECT ALL - - 81 + + col1 AS col2 FROM tab2 AS cor0
----
112
140
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8055
SELECT + + 97 DIV col2 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8055
SELECT + + 97 / col2 AS col2 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8056
SELECT ALL - + col0 DIV + col1 + CAST( + col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-8056
SELECT ALL - + col0 / + col1 + CAST ( + col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
7
75
77

query I rowsort
SELECT DISTINCT + 90 * - col2 + + 57 FROM tab2 AS cor0
----
-2283
-2373
-3363

query I rowsort
SELECT col0 * cor0.col2 * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL + + 50 * + cor0.col1 + - 45 FROM tab1 AS cor0
----
1255
455
605

query I rowsort
SELECT ALL - col0 + - col0 + col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + col2 * col1 + col1 * - col1 FROM tab1 AS cor0
----
1079
470
728

query I rowsort
SELECT col1 + 64 * col0 FROM tab2 AS cor0
----
479
5051
5073

query I rowsort
SELECT DISTINCT 6 FROM tab1, tab2 cor0, tab1 AS cor1
----
6

query I rowsort
SELECT DISTINCT + cor0.col0 * 71 FROM tab2 cor0
----
497
5538
5609

query I rowsort
SELECT col1 + - col2 * + 75 FROM tab0 AS cor0
----
-2389
-6059
22

query I rowsort
SELECT - 48 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

query I rowsort
SELECT ALL + + cor0.col2 + - col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 87 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
87

query I rowsort
SELECT - + cor0.col1 + + ( + col1 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col0 * - col0 + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-4736
-7440
-87

query I rowsort
SELECT - col0 + - col1 * + col0 AS col1 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT + 40 * - col1 + col1 AS col1 FROM tab1 cor0
----
-1014
-390
-507

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8073
SELECT DISTINCT CAST( - col1 AS SIGNED ) + col0 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-8073
SELECT DISTINCT CAST ( - col1 AS INTEGER ) + col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-8074
SELECT ALL - CAST( + col0 AS SIGNED ) * - col1 - + CAST( + col2 AS SIGNED ) DIV + col1 FROM tab2 AS cor0
----
1341
217
4602

skipif mysql # not compatible
query I rowsort label-8074
SELECT ALL - CAST ( + col0 AS INTEGER ) * - col1 - + CAST ( + col2 AS INTEGER ) / + col1 FROM tab2 AS cor0
----
1341
217
4602

query I rowsort
SELECT + 70 * + col2 FROM tab2 AS cor0
----
1820
1890
2660

query I rowsort
SELECT cor0.col0 * col2 * - col1 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + - ( - col0 ) * col1 + + 96 * col2 FROM tab0 AS cor0
----
15971
3491
5232

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 66 col1 FROM tab2
----
-66
-66
-66

query I rowsort
SELECT DISTINCT 19 AS col2 FROM tab2, tab0 AS cor0
----
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 51 ) * - tab1.col2 + 83 * - 3 col0 FROM tab1
----
-3003
-3156
-5145

onlyif mysql # use DIV operator for integer division
query I rowsort label-8081
SELECT ALL + col1 + + col0 DIV col1 + col1 * col2 * col0 FROM tab1 AS cor0
----
36496
4238
99859

skipif mysql # not compatible
query I rowsort label-8081
SELECT ALL + col1 + + col0 / col1 + col1 * col2 * col0 FROM tab1 AS cor0
----
36496
4238
99859

query I rowsort
SELECT 94 * col2 AS col0 FROM tab0 AS cor0
----
3102
7708
94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8083
SELECT CAST( + cor0.col0 AS SIGNED ) * col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-8083
SELECT CAST ( + cor0.col0 AS INTEGER ) * col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + - col1 + + cor0.col1 * cor0.col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + 25 * + col0 FROM tab1 cor0
----
1600
2000
75

query I rowsort
SELECT ALL - col1 * - cor0.col1 + + col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT 12 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT DISTINCT - - 71 * cor0.col1 FROM tab0 AS cor0
----
6106
6461
6887

query I rowsort
SELECT ALL + + col1 * + col0 * - col1 AS col1 FROM tab0 cor0
----
-177504
-329315
-737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
86
91
97

skipif mysql # not compatible
query I rowsort
SELECT col0 + + CAST ( col1 AS REAL ) * + col2 AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + col0 * col2 * - col1 + col0 * + 61 FROM tab1 cor0
----
-32576
-4029
-94960

skipif mysql # not compatible
query I rowsort
SELECT cor0.col0 + CAST ( col2 AS REAL ) * - col1 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 col0 FROM tab2, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL + col0 * col1 + col2 * col1 FROM tab0
----
15561
3492
4902

query I rowsort
SELECT DISTINCT col2 * col2 + + col2 * + col1 FROM tab2 cor0
----
1566
2090
2210

query I rowsort
SELECT ALL + col1 * 77 AS col1 FROM tab2 AS cor0
----
1309
2387
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col0 - 28 col2 FROM tab2 AS cor0
----
-14
128
130

query I rowsort
SELECT - + cor0.col0 + + 73 FROM tab2 AS cor0
----
-5
-6
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8100
SELECT + col0 + - CAST( - col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-8100
SELECT + col0 + - CAST ( - col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT - - 6 * cor0.col1 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 7b6f7b44d971ceaede5dfcdeaa8a82a3

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 + col1 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - col0 * col0 + - 36 * - col2 * - cor0.col0 FROM tab2 AS cor0
----
-114313
-6853
-79092

query I rowsort
SELECT DISTINCT col2 - cor0.col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL 35 + - cor0.col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2029
-3360
-8064

query I rowsort
SELECT + 95 + + col2 AS col0 FROM tab2 AS cor0
----
121
122
133

query I rowsort
SELECT DISTINCT - + 63 * + col0 + - col2 FROM tab1 AS cor0
----
-243
-4089
-5136

query I rowsort
SELECT ALL - ( col1 ) * + cor0.col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL + - ( + cor0.col2 ) * col1 * - col1 + 23 AS col1 FROM tab2 cor0
----
11005
25970
90529

query I rowsort
SELECT DISTINCT - col0 * col0 * - col0 + - cor0.col2 * col0 FROM tab2 AS cor0
----
154
472524
490037

query I rowsort
SELECT ALL - tab2.col2 + tab2.col0 AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT - col2 * - 63 + + col0 AS col0 FROM tab1 AS cor0
----
3405
3655
6128

query I rowsort
SELECT ALL - + col2 + - col0 * col2 AS col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT + 19 * col1 AS col0 FROM tab1 cor0
----
190
247
494

query I rowsort
SELECT DISTINCT + col0 + - col0 * col0 * col0 FROM tab1 AS cor0
----
-24
-262080
-511920

query I rowsort
SELECT ALL - + ( ( - col2 ) ) - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - col2 - col1 AS col2 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL + + 3 * col2 * col1 + 95 + - cor0.col2 FROM tab2 AS cor0
----
1995
2579
4671

onlyif mysql # use DIV operator for integer division
query I rowsort label-8119
SELECT DISTINCT col1 + col2 * col1 DIV + ( + ( col0 ) ) FROM tab0 cor0
----
174
204
99

skipif mysql # not compatible
query I rowsort label-8119
SELECT DISTINCT col1 + col2 * col1 / + ( + ( col0 ) ) FROM tab0 cor0
----
174
204
99

query I rowsort
SELECT + - 87 * 78 + cor0.col2 FROM tab1 AS cor0
----
-6690
-6729
-6732

query I rowsort
SELECT - - 55 AS col2 FROM tab2 AS cor0
----
55
55
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8122
SELECT - CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8122
SELECT - CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col2 * col0 * + 86 col2 FROM tab2 AS cor0
----
16285
174467
258189

query I rowsort
SELECT ALL + col0 - + col1 AS col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + ( col1 + col0 ) * ( 36 * - col2 + + 17 ) FROM tab2
----
-125903
-129696
-36290

query I rowsort
SELECT - + col0 + + 60 - + ( - cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-2
41
84

query I rowsort
SELECT - col1 * + col1 * ( tab0.col0 ) AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT - col1 + - col1 - + col0 * col1 FROM tab1
----
-1066
-130
-660

query I rowsort
SELECT DISTINCT col2 * - col0 - ( + 56 * col1 ) FROM tab2
----
-1925
-3954
-5332

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8130
SELECT ALL - col2 / CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8130
SELECT ALL - col2 / CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 col1 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT col1 * 41 - col1 FROM tab2 AS cor0
----
1240
2360
680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8133
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) + - col1 * col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8133
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) + - col1 * col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col1 + col2 + - 40 * col0 AS col2 FROM tab0
----
-1302
-3387
-841

onlyif mysql # use DIV operator for integer division
query I rowsort label-8135
SELECT col1 * col1 + - 22 + + ( + col2 + col0 ) DIV 16 FROM tab0
----
7377
8269
9389

skipif mysql # not compatible
query I rowsort label-8135
SELECT col1 * col1 + - 22 + + ( + col2 + col0 ) / 16 FROM tab0
----
7377
8269
9389

query I rowsort
SELECT col1 + ( - 32 ) * col1 FROM tab1
----
-310
-403
-806

query I rowsort
SELECT - - col0 + - ( + col0 * - col2 ) FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col2 + 50 FROM tab2 cor0
----
76
77
88

query I rowsort
SELECT + - cor0.col1 * - col2 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-8140
SELECT DISTINCT - col0 DIV + col1 - - col0 DIV - col1 FROM tab2 cor0
----
-2
-8
0

skipif mysql # not compatible
query I rowsort label-8140
SELECT DISTINCT - col0 / + col1 - - col0 / - col1 FROM tab2 cor0
----
-2
-8
0

query I rowsort
SELECT DISTINCT ( + tab0.col1 ) * + col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - cor0.col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 * col0 AS col2 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 65 * col2 col2 FROM tab0
----
2145
5330
65

query I rowsort
SELECT ALL 24 * + col2 AS col1 FROM tab2
----
624
648
912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col1 ) col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + tab1.col1 + col1 * tab1.col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT 10 + + col1 + 55 * 52 FROM tab1
----
2880
2883
2896

query I rowsort
SELECT ALL col2 * + col0 + 69 AS col2 FROM tab0
----
104
7367
861

query I rowsort
SELECT DISTINCT + tab2.col1 + - col2 AS col0 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL - - col0 + + col0 * - 46 AS col1 FROM tab0 AS cor0
----
-1080
-1575
-4005

query I rowsort
SELECT DISTINCT - col2 - - col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - - ( col1 ) * - 71 * 81 AS col1 FROM tab1 AS cor0
----
-149526
-57510
-74763

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 87 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT ALL + col1 * - cor0.col0 + - col0 * col1 FROM tab0 AS cor0
----
-16198
-4128
-6790

query I rowsort
SELECT - col1 + 78 AS col2 FROM tab2
----
19
47
61

query I rowsort
SELECT DISTINCT 4 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
4

query I rowsort
SELECT DISTINCT - 30 + - col2 FROM tab0 AS cor0
----
-112
-31
-63

query I rowsort
SELECT DISTINCT + - 66 * + 68 + - col0 FROM tab2 cor0
----
-4495
-4566
-4567

query I rowsort
SELECT DISTINCT + + 66 * - col2 + + col1 FROM tab2 AS cor0
----
-1657
-1751
-2491

query I rowsort
SELECT col1 * - 73 FROM tab1 AS cor0
----
-1898
-730
-949

query I rowsort
SELECT - 71 + - 69 * col0 FROM tab0 AS cor0
----
-1727
-2486
-6212

query I rowsort
SELECT 52 * 46 + - col1 FROM tab2 AS cor0
----
2333
2361
2375

onlyif mysql # use DIV operator for integer division
query I rowsort label-8164
SELECT - 80 DIV col0 FROM tab2 AS cor0
----
-1
-1
-11

skipif mysql # not compatible
query I rowsort label-8164
SELECT - 80 / col0 FROM tab2 AS cor0
----
-1
-1
-11

query I rowsort
SELECT + 42 - tab2.col1 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to afe4d19a8057ce80169689f37ef14b57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8166
SELECT + col0 DIV - cor0.col1 + col0 AS col2 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-8166
SELECT + col0 / - cor0.col1 + col0 AS col2 FROM tab1 AS cor0
----
3
58
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-8167
SELECT ( col1 ) DIV + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8167
SELECT ( col1 ) / + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8168
SELECT - 21 DIV col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-8168
SELECT - 21 / col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT + - ( - col0 ) AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - col1 + col0 * - col0 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL - ( tab0.col1 + col0 ) FROM tab0
----
-110
-132
-180

query I rowsort
SELECT + col1 * - 60 + col2 * col2 AS col1 FROM tab0 AS cor0
----
-4071
-5819
1264

query I rowsort
SELECT ALL col2 * + cor0.col0 - col1 AS col2 FROM tab0 cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8174
SELECT + ( + tab1.col2 ) + CAST( NULL AS SIGNED ) + - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8174
SELECT + ( + tab1.col2 ) + CAST ( NULL AS INTEGER ) + - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col0 - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + - col1 * col2 + col2 * - col1 FROM tab1 AS cor0
----
-1140
-2496
-2808

query I rowsort
SELECT DISTINCT 83 FROM tab2, tab2 AS cor0, tab1 cor1
----
83

query I rowsort
SELECT DISTINCT - col2 * + col1 * col2 AS col0 FROM tab0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - ( 98 ) col0 FROM tab1
----
-294
-6272
-7840

skipif mysql # not compatible
query I rowsort
SELECT col0 * CAST ( + col0 + + col2 AS REAL ) AS col1 FROM tab2
----
238
8112
9243

query I rowsort
SELECT ALL + 55 * + 53 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 0c91bf8547b1dd1009d546780bfbe458

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT - tab0.col2 * - col0 + 64 AS col2 FROM tab0
----
7362
856
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 + col0 col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT tab1.col0 - + col0 * tab1.col1 AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + col0 * 0 AS col2 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - - tab2.col1 col2 FROM tab2
----
137
38
96

query I rowsort
SELECT + col0 + - col0 * col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT cor0.col0 + 88 * col1 FROM tab0 AS cor0
----
7592
8097
8571

query I rowsort
SELECT ALL - - col1 * + cor0.col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL + tab1.col2 * col1 - + col0 FROM tab1
----
1168
1401
506

onlyif mysql # use DIV operator for integer division
query I rowsort label-8192
SELECT ALL col2 + - col1 * + col0 - - col1 DIV col1 AS col0 FROM tab2
----
-1304
-189
-4575

skipif mysql # not compatible
query I rowsort label-8192
SELECT ALL col2 + - col1 * + col0 - - col1 / col1 AS col0 FROM tab2
----
-1304
-189
-4575

onlyif mysql # use DIV operator for integer division
query I rowsort label-8193
SELECT - tab0.col2 DIV col2 col0 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8193
SELECT - tab0.col2 / col2 col0 FROM tab0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8194
SELECT ALL + 10 DIV - col1 - col2 AS col0 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8194
SELECT ALL + 10 / - col1 - col2 AS col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - 12 + - col2 AS col2 FROM tab2 AS cor0
----
-38
-39
-50

query I rowsort
SELECT + cor0.col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT 25 + + col2 + - ( + 31 ) * cor0.col0 * 52 FROM tab2 AS cor0
----
-11232
-125685
-127285

query I rowsort
SELECT ALL + - 48 AS col2 FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT + col0 * col2 + ( + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-8200
SELECT ALL 87 DIV + col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8200
SELECT ALL 87 / + col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT 19 + + cor0.col1 * col2 FROM tab2 AS cor0
----
1553
665
856

query I rowsort
SELECT + - col0 * col2 * col2 + + col0 AS col1 FROM tab0 AS cor0
----
-26112
-598347
0

query I rowsort
SELECT - + cor0.col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8204
SELECT ( - col2 + col0 ) DIV + col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8204
SELECT ( - col2 + col0 ) / + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + 84 FROM tab1, tab1 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8206
SELECT col0 DIV col0 + - 19 FROM tab1 AS cor0
----
-18
-18
-18

skipif mysql # not compatible
query I rowsort label-8206
SELECT col0 / col0 + - 19 FROM tab1 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + + col2 + col0 + 46 FROM tab0 AS cor0
----
103
217
82

query I rowsort
SELECT ALL + 66 * + col1 * 52 AS col0 FROM tab1 AS cor0
----
34320
44616
89232

query I rowsort
SELECT ALL - 50 * + col0 + + col0 * + 55 FROM tab1 AS cor0
----
15
320
400

query I rowsort
SELECT ALL + - 93 * - col1 AS col0 FROM tab2 AS cor0
----
1581
2883
5487

onlyif mysql # use DIV operator for integer division
query I rowsort label-8211
SELECT DISTINCT + + col1 DIV col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8211
SELECT DISTINCT + + col1 / col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT cor0.col1 + col2 * + col1 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ALL + - cor0.col0 + col2 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - + 8 + cor0.col1 FROM tab1 AS cor0
----
18
2
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 - + col2 col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + + 62 + + col0 * + col1 AS col2 FROM tab1 AS cor0
----
1102
140
702

query I rowsort
SELECT - ( col0 ) * + 58 + 99 FROM tab2 AS cor0
----
-307
-4425
-4483

query I rowsort
SELECT DISTINCT + - col2 + col1 * 99 FROM tab0 cor0
----
8481
8927
9602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + cor0.col0 col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT col1 * col2 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
22606
24627
39962

query I rowsort
SELECT DISTINCT - col2 * 93 + + col1 * + col0 + col2 FROM tab2 cor0
----
-2153
-2267
2210

onlyif mysql # use DIV operator for integer division
query I rowsort label-8222
SELECT ALL - cor0.col0 DIV + col0 + + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-8222
SELECT ALL - cor0.col0 / + col0 + + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT DISTINCT + cor0.col0 - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL ( - col1 ) * tab1.col0 + col0 AS col1 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8225
SELECT ALL col2 DIV col0 + 58 AS col1 FROM tab1
----
58
59
76

skipif mysql # not compatible
query I rowsort label-8225
SELECT ALL col2 / col0 + 58 AS col1 FROM tab1
----
58
59
76

query I rowsort
SELECT ALL col1 + - col1 * + col1 AS col1 FROM tab2
----
-272
-3422
-930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + + col2 col0 FROM tab1
----
0

query I rowsort
SELECT ALL - - ( + 19 ) * + col1 AS col0 FROM tab0 AS cor0
----
1634
1729
1843

query I rowsort
SELECT + cor0.col1 + col1 * + col0 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + + cor0.col2 + col2 * + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ( - col1 ) * col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - ( + 38 ) * + col2 FROM tab0 AS cor0
----
-1254
-3116
-38

query I rowsort
SELECT DISTINCT - + cor0.col1 * col2 * col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT + cor0.col2 AS col0 FROM tab0, tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - col1 * 84 + tab1.col1 AS col0 FROM tab1
----
-1079
-2158
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col0 ) col1 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + col0 - - tab0.col0 FROM tab0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 3 col2 FROM tab0 AS cor0
----
3
3
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8239
SELECT - - CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8239
SELECT - - CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8240
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - 75 col0 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8240
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - 75 col0 FROM tab0 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8241
SELECT ALL 72 DIV ( + tab2.col0 ) AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 360126deab7a1905ac15f3157d809d1c

skipif mysql # not compatible
query I rowsort label-8241
SELECT ALL 72 / ( + tab2.col0 ) AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 360126deab7a1905ac15f3157d809d1c

query I rowsort
SELECT + - col0 + - ( - col2 ) FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT ALL + - cor0.col2 + 10 FROM tab2 AS cor0
----
-16
-17
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-8244
SELECT - col2 DIV cor0.col2 + - col1 AS col2 FROM tab0 cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-8244
SELECT - col2 / cor0.col2 + - col1 AS col2 FROM tab0 cor0
----
-87
-92
-98

query I rowsort
SELECT ALL + + ( ( col0 ) ) * + 42 - + 60 AS col2 FROM tab0 AS cor0
----
1410
3678
948

query I rowsort
SELECT + 50 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1298
1454
620

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8247
SELECT - + ( - col1 ) * col2 + + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8247
SELECT - + ( - col1 ) * col2 + + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - col2 + col1 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT ( + col2 ) + + cor0.col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT ( tab2.col0 ) * + col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT 67 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + + col0 * ( col0 ) col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT col2 * ( 29 ) FROM tab0 AS cor0
----
2378
29
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 col0 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT 85 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
85

query I rowsort
SELECT - col1 + + col2 * ( + tab0.col0 ) + col2 AS col2 FROM tab0
----
-61
7289
739

query I rowsort
SELECT col0 + col1 * - col1 * - col1 AS col2 FROM tab2
----
205457
29798
4992

query I rowsort
SELECT col0 * col2 * - 44 + - cor0.col1 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1636
-321121
-34901

query I rowsort
SELECT DISTINCT - col2 * ( cor0.col1 ) + + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT col0 + 35 * ( + col0 ) AS col1 FROM tab2 AS cor0
----
252
2808
2844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col0 * + cor0.col2 + - col1 * - col1 col0 FROM tab1 AS cor0
----
-233372
-614231
190

onlyif mysql # use DIV operator for integer division
query I rowsort label-8262
SELECT ALL col1 DIV cor0.col0 + + 38 * - cor0.col0 - col0 AS col0 FROM tab0 AS cor0
----
-1363
-3470
-933

skipif mysql # not compatible
query I rowsort label-8262
SELECT ALL col1 / cor0.col0 + + 38 * - cor0.col0 - col0 AS col0 FROM tab0 AS cor0
----
-1363
-3470
-933

query I rowsort
SELECT - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT col1 * - ( - 79 ) FROM tab2
----
1343
2449
4661

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0, tab0 AS cor0 WHERE ( NULL ) = NULL
----

query I rowsort
SELECT col1 + - 36 * - col2 FROM tab1 AS cor0
----
1970
2062
3469

query I rowsort
SELECT DISTINCT 54 + col0 FROM tab1 AS cor0
----
118
134
57

query I rowsort
SELECT ALL + 14 + + 22 AS col0 FROM tab1 AS cor0
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 13 * col0 + col0 col1 FROM tab1 AS cor0
----
1120
42
896

onlyif mysql # use DIV operator for integer division
query I rowsort label-8270
SELECT 89 DIV + col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-8270
SELECT 89 / + col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + 88 + 43 FROM tab2, tab2 AS cor0
----
9 values hashing to 2a1963143aee0d56f95aea0f030bc48f

onlyif mysql # use DIV operator for integer division
query I rowsort label-8272
SELECT col2 DIV ( + tab1.col2 ) FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8272
SELECT col2 / ( + tab1.col2 ) FROM tab1
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8273
SELECT DISTINCT + col2 DIV - ( col1 ) AS col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-8273
SELECT DISTINCT + col2 / - ( col1 ) AS col1 FROM tab1
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8274
SELECT DISTINCT tab2.col0 + + col1 + + col0 DIV col0 FROM tab2
----
138
39
97

skipif mysql # not compatible
query I rowsort label-8274
SELECT DISTINCT tab2.col0 + + col1 + + col0 / col0 FROM tab2
----
138
39
97

query I rowsort
SELECT cor0.col2 + - 70 * - col0 FROM tab1 AS cor0
----
264
4537
5696

query I rowsort
SELECT + + ( ( col1 ) ) * col0 * col1 + - col1 * + 96 FROM tab2 AS cor0
----
21199
265854
3751

query I rowsort
SELECT ALL 44 * col1 FROM tab2 AS cor0
----
1364
2596
748

query I rowsort
SELECT - + ( + ( - cor0.col2 ) ) AS col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8279
SELECT - + cor0.col1 + col2 DIV col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-8279
SELECT - + cor0.col1 + col2 / col2 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT col1 + + 23 AS col0 FROM tab2 AS cor0
----
40
54
82

query I rowsort
SELECT + + col1 + 46 AS col0 FROM tab0 AS cor0
----
132
137
143

onlyif mysql # use DIV operator for integer division
query I rowsort label-8282
SELECT - 72 DIV tab1.col0 col1 FROM tab1
----
-1
-24
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8282
SELECT - 72 / tab1.col0 col1 FROM tab1
----
-1
-24
0

query I rowsort
SELECT DISTINCT 12 * col1 * - col0 + + col2 * col1 + - col2 AS col2 FROM tab0
----
-21963
-40644
-89808

query I rowsort
SELECT DISTINCT + col1 * col2 - - col2 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-8285
SELECT - col0 * - cor0.col1 + + col0 DIV cor0.col0 FROM tab0 AS cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-8285
SELECT - col0 * - cor0.col1 + + col0 / cor0.col0 FROM tab0 AS cor0
----
2065
3396
8100

query I rowsort
SELECT ALL + col0 * - cor0.col1 + col0 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-8287
SELECT ALL + col1 DIV col0 + col0 AS col2 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-8287
SELECT ALL + col1 / col0 + col0 AS col2 FROM tab2 AS cor0
----
11
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * col0 + + col2 col1 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - col1 * col2 + + col0 * col0 * - col2 FROM tab2 cor0
----
-159718
-2160
-237804

query I rowsort
SELECT DISTINCT - col2 + col2 * tab0.col1 AS col0 FROM tab0
----
2805
7380
96

query I rowsort
SELECT col0 + + cor0.col0 * col2 * - col2 AS col1 FROM tab2 AS cor0
----
-113997
-5096
-52650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + tab1.col2 * col1 * col1 col0 FROM tab1
----
16320
36558
5757

query I rowsort
SELECT DISTINCT - col1 + - tab1.col2 AS col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col0 * + tab0.col0 * + col0 + - col0 * + col2 AS col2 FROM tab0
----
13032
42840
697671

query I rowsort
SELECT + + cor0.col0 * - col0 FROM tab0 cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * cor0.col1 col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL - - col1 + - col1 * col1 AS col2 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL - tab2.col0 - + col0 * + col0 * col0 FROM tab2
----
-350
-474630
-493118

query I rowsort
SELECT DISTINCT col2 + + col2 - + col2 AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT - col1 + tab0.col0 * - col1 AS col0 FROM tab0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT tab0.col1 - - tab0.col0 * + col2 AS col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT - tab1.col1 * col0 - - tab1.col0 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT col0 + col0 * - col0 - col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT ALL + col1 - + col0 * + col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + tab2.col0 * tab2.col2 * col1 AS col2 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-8306
SELECT DISTINCT cor0.col1 * col2 + + cor0.col0 * col1 DIV - cor0.col0 + + cor0.col0 FROM tab1 AS cor0
----
1315
1381
624

skipif mysql # not compatible
query I rowsort label-8306
SELECT DISTINCT cor0.col1 * col2 + + cor0.col0 * col1 / - cor0.col0 + + cor0.col0 FROM tab1 AS cor0
----
1315
1381
624

onlyif mysql # use DIV operator for integer division
query I rowsort label-8307
SELECT col1 DIV + cor0.col1 - + col2 col1 FROM tab2 AS cor0
----
-25
-26
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8307
SELECT col1 / + cor0.col1 - + col2 col1 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT + col2 + tab2.col0 * col0 * tab2.col0 AS col0 FROM tab2
----
370
474578
493077

query I rowsort
SELECT DISTINCT col0 * col0 + - tab0.col0 FROM tab0
----
1190
552
7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-8310
SELECT col2 + - col2 + + col2 DIV + col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8310
SELECT col2 + - col2 + + col2 / + col2 FROM tab1
----
1
1
1

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) IN ( - col0 - - tab0.col2 )
----

query I rowsort
SELECT col0 AS col2 FROM tab1 WHERE NOT col2 > NULL
----

query I rowsort
SELECT ALL col0 + - col1 * tab0.col0 AS col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - col0 * + col2 * col1 FROM tab1 WHERE NOT - col1 <= NULL
----

query I rowsort
SELECT DISTINCT + col2 + + col1 * col0 * col2 AS col0 FROM tab0
----
3396
664200
68145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 col2 FROM tab1 WHERE ( + col2 ) BETWEEN NULL AND ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL + 89 + tab2.col1 AS col2 FROM tab2
----
106
120
148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 col0 FROM tab2, tab0, tab0 cor0 WHERE ( NULL ) NOT IN ( tab2.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8320
SELECT - 77 DIV - col0 AS col0 FROM tab1
----
0
1
25

skipif mysql # not compatible
query I rowsort label-8320
SELECT - 77 / - col0 AS col0 FROM tab1
----
0
1
25

query I rowsort
SELECT + col2 * col1 + + 78 * + 66 * + col1 AS col1 FROM tab1 cor0
----
135252
52050
68172

query I rowsort
SELECT + cor0.col1 * - cor0.col2 * 13 FROM tab1 cor0
----
-16224
-18252
-7410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 + - cor0.col1 col2 FROM tab1 AS cor0
----
2890
3239
9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-8324
SELECT ALL + 87 * + col0 + 68 DIV + col0 AS col2 FROM tab2 AS cor0
----
618
6786
6873

skipif mysql # not compatible
query I rowsort label-8324
SELECT ALL + 87 * + col0 + 68 / + col0 AS col2 FROM tab2 AS cor0
----
618
6786
6873

query I rowsort
SELECT ALL + - 62 AS col2 FROM tab1 AS cor0
----
-62
-62
-62

query I rowsort
SELECT DISTINCT - col2 * + tab1.col1 + + tab1.col2 * col1 FROM tab1
----
0

query I rowsort
SELECT col1 + - col2 * col2 AS col1 FROM tab2
----
-1427
-617
-698

query III rowsort
SELECT ALL * FROM tab1 WHERE ( + col2 / - col2 ) IN ( tab1.col1 )
----

query I rowsort
SELECT ALL col0 * col2 - + tab0.col2 FROM tab0
----
34
7216
759

query I rowsort
SELECT DISTINCT + col2 + - col0 * + tab2.col1 AS col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT ALL - cor0.col1 * cor0.col2 * col0 AS col1 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL col1 * col0 + col2 + col0 FROM tab0 AS cor0
----
2121
3431
8270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - cor0.col2 / col1 col1 FROM tab0 AS cor0 WHERE - cor0.col0 / + col2 = col2
----

query I rowsort
SELECT ALL col2 + col0 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT cor0.col2 * col0 + + col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
71
7469
849

onlyif mysql # use DIV operator for integer division
query I rowsort label-8336
SELECT - col2 + - cor0.col2 DIV col2 + col2 * - col1 FROM tab1 AS cor0
----
-1345
-1459
-628

skipif mysql # not compatible
query I rowsort label-8336
SELECT - col2 + - cor0.col2 / col2 + col2 * - col1 FROM tab1 AS cor0
----
-1345
-1459
-628

query III rowsort
SELECT * FROM tab1 WHERE NULL BETWEEN - col2 AND NULL
----

query I rowsort
SELECT DISTINCT + col0 + col0 * - col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + tab1.col2 + - col1 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL tab0.col1 + - col2 FROM tab0 WHERE ( NULL ) <> + col1 + + col0 * col0
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT BETWEEN + col2 AND ( NULL )
----

query I rowsort
SELECT + col1 - + col0 * col1 AS col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 * + col1 FROM tab1
----
13533
2054
6410

query I rowsort
SELECT - col1 + col0 + + col2 AS col1 FROM tab2
----
100
3
45

query I rowsort
SELECT col1 AS col2 FROM tab1 WHERE NULL NOT IN ( + col1 )
----

query I rowsort
SELECT - col1 + col1 * - col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT col2 + col1 + col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT + col0 * col0 + - 7 * col2 + col1 AS col0 FROM tab0 AS cor0
----
1315
431
7438

query I rowsort
SELECT DISTINCT + - col1 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - col1 + col1 * - ( - col2 ) + + col2 AS col1 FROM tab2 AS cor0
----
1501
667
833

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8351
SELECT - col0 + + CAST( + col0 * + col0 + col1 AS SIGNED ) FROM tab0 cor0
----
1287
638
7923

skipif mysql # not compatible
query I rowsort label-8351
SELECT - col0 + + CAST ( + col0 * + col0 + col1 AS INTEGER ) FROM tab0 cor0
----
1287
638
7923

query I rowsort
SELECT - col0 + + 72 + - 35 AS col0 FROM tab0 AS cor0
----
-52
13
2

query I rowsort
SELECT cor0.col2 * col1 + + col0 * col2 + + col0 FROM tab1 cor0
----
1569
4282
9008

query I rowsort
SELECT ALL - tab2.col1 * - col0 * + 5 AS col0 FROM tab2
----
1085
23010
6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-8355
SELECT - col2 DIV 73 + - 68 + + cor0.col1 DIV col1 FROM tab0 AS cor0
----
-67
-67
-68

skipif mysql # not compatible
query I rowsort label-8355
SELECT - col2 / 73 + - 68 + + cor0.col1 / col1 FROM tab0 AS cor0
----
-67
-67
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-8356
SELECT + col2 * - cor0.col0 + col1 DIV - col0 + - col1 AS col1 FROM tab2 AS cor0
----
-2087
-224
-3019

skipif mysql # not compatible
query I rowsort label-8356
SELECT + col2 * - cor0.col0 + col1 / - col0 + - col1 AS col1 FROM tab2 AS cor0
----
-2087
-224
-3019

query I rowsort
SELECT ALL 29 * + 19 + + tab2.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 00d27bfe18a1b3c4d9f4485096ba7e49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8358
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col2 * col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8358
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col2 * col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 53 * cor0.col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT - 93 + + col2 AS col0 FROM tab2 AS cor0
----
-55
-66
-67

query I rowsort
SELECT ALL - 67 * 77 AS col2 FROM tab1 AS cor0
----
-5159
-5159
-5159

onlyif mysql # use DIV operator for integer division
query I rowsort label-8362
SELECT DISTINCT - 67 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1
-22
0

skipif mysql # not compatible
query I rowsort label-8362
SELECT DISTINCT - 67 / + col0 AS col2 FROM tab1 AS cor0
----
-1
-22
0

query I rowsort
SELECT ALL + col2 * - 61 FROM tab2 AS cor0
----
-1586
-1647
-2318

query I rowsort
SELECT DISTINCT - col2 * + col2 + + col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT cor0.col1 * - col0 * - col1 - col0 * - 72 AS col2 FROM tab1 AS cor0
----
11008
19280
2244

query I rowsort
SELECT ALL + col2 * - 15 * + col0 + col0 * + col2 FROM tab2 cor0
----
-2646
-28392
-42028

query I rowsort
SELECT DISTINCT + ( col2 ) - + col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - + col2 * + 44 + col2 AS col0 FROM tab2 AS cor0
----
-1118
-1161
-1634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + cor0.col1 * col2 * col1 col0 FROM tab2 AS cor0
----
12426
26676
91182

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col1 col0 FROM tab1
----
109
67
80

query I rowsort
SELECT + 44 + + col2 FROM tab1 AS cor0
----
101
140
98

query I rowsort
SELECT - + cor1.col1 * - cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 23253cfee4cea5e1d4f993bec937f9fe

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8373
SELECT ALL + CAST( col0 AS SIGNED ) AS col1 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8373
SELECT ALL + CAST ( col0 AS INTEGER ) AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT cor0.col0 + col2 * - ( + col2 ) + + col2 FROM tab1 cor0
----
-2859
-3128
-9040

query I rowsort
SELECT - 91 - - col0 FROM tab2 AS cor0
----
-12
-13
-84

query I rowsort
SELECT col1 * col1 + col0 + col0 AS col1 FROM tab1 AS cor0
----
228
329
682

query I rowsort
SELECT - col1 + + col0 * + col1 + - 83 FROM tab0 cor0
----
1895
3215
7925

onlyif mysql # use DIV operator for integer division
query I rowsort label-8378
SELECT DISTINCT - - col1 DIV - col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8378
SELECT DISTINCT - - col1 / - col1 FROM tab0 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8379
SELECT - + 49 DIV col2 + - 65 * col1 * + col2 col2 FROM tab0 AS cor0
----
-184471
-485030
-6354

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8379
SELECT - + 49 / col2 + - 65 * col1 * + col2 col2 FROM tab0 AS cor0
----
-184471
-485030
-6354

query I rowsort
SELECT 4 * tab0.col0 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to d7ba7ed61b7057db35c81f7023c2891b

query I rowsort
SELECT 94 + tab1.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to c7cada3662d7d6ab022e26625f2d9ba4

query I rowsort
SELECT + + cor0.col1 - - col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + - cor0.col0 + - col2 * + cor0.col0 FROM tab0 AS cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 * col2 col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col0 * - 77 FROM tab0
----
-1848
-2695
-6853

query I rowsort
SELECT - 55 AS col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

query I rowsort
SELECT DISTINCT tab2.col1 * 60 AS col0 FROM tab2
----
1020
1860
3540

query I rowsort
SELECT + tab1.col0 - + col0 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + + ( - col0 ) * + col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + col2 + 8 * - col1 * - 27 FROM tab0 AS cor0
----
18543
19574
20951

query I rowsort
SELECT + + col0 * col2 + + 43 FROM tab2 AS cor0
----
2071
232
3045

query I rowsort
SELECT DISTINCT - cor0.col0 * + 20 + ( col2 + - 55 ) AS col2 FROM tab0 AS cor0
----
-1753
-502
-754

query I rowsort
SELECT DISTINCT col2 * ( 15 ) AS col2 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT DISTINCT + + col2 + + 61 + col0 FROM tab2 AS cor0
----
165
178
95

query I rowsort
SELECT DISTINCT - col2 + ( - 92 * + col0 ) + + col2 FROM tab2 cor0
----
-644
-7176
-7268

query I rowsort
SELECT - + col2 + - col0 * col1 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col2 col0 FROM tab2 cor0
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * - col1 + col1 col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + + col2 + + 57 * col1 AS col1 FROM tab0 AS cor0
----
4935
5269
5530

query I rowsort
SELECT ALL + col0 + col1 * + 48 + col1 AS col2 FROM tab0 AS cor0
----
4238
4548
4788

onlyif mysql # use DIV operator for integer division
query I rowsort label-8401
SELECT ALL + cor0.col1 * + col0 * 39 + + col2 DIV + col1 + - 31 col1 FROM tab1 AS cor0
----
24934
3013
40536

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8401
SELECT ALL + cor0.col1 * + col0 * 39 + + col2 / + col1 + - 31 col1 FROM tab1 AS cor0
----
24934
3013
40536

query I rowsort
SELECT ALL 23 * - col1 + col0 AS col1 FROM tab0 AS cor0
----
-1954
-2004
-2196

query I rowsort
SELECT DISTINCT - + 57 * - 44 + + col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
2543
3300
9806

query I rowsort
SELECT ALL + + 39 * col1 + col0 FROM tab0 AS cor0
----
3378
3638
3818

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8405
SELECT + CAST( NULL AS SIGNED ) + 68 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8405
SELECT + CAST ( NULL AS INTEGER ) + 68 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8407
SELECT DISTINCT CAST( NULL AS SIGNED ) + 55 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8407
SELECT DISTINCT CAST ( NULL AS INTEGER ) + 55 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8408
SELECT - 82 * - col0 + + col2 DIV col0 col2 FROM tab2 AS cor0
----
577
6396
6478

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8408
SELECT - 82 * - col0 + + col2 / col0 col2 FROM tab2 AS cor0
----
577
6396
6478

onlyif mysql # use DIV operator for integer division
query I rowsort label-8409
SELECT ALL - tab2.col0 * + ( - col0 ) + col1 * 53 DIV col0 - + col0 * col1 FROM tab2
----
1522
4909
66

skipif mysql # not compatible
query I rowsort label-8409
SELECT ALL - tab2.col0 * + ( - col0 ) + col1 * 53 / col0 - + col0 * col1 FROM tab2
----
1522
4909
66

query I rowsort
SELECT - ( - col0 ) + 43 * - col0 AS col0 FROM tab1 AS cor0
----
-126
-2688
-3360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col0 * + col2 col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - 74 * col1 + 84 FROM tab1 cor0
----
-1840
-656
-878

query I rowsort
SELECT DISTINCT - col0 * col1 + ( - col1 ) * - cor0.col0 FROM tab1 AS cor0
----
0

query IIIIIIIII rowsort
SELECT * FROM tab0, tab1, tab1 AS cor0 WHERE NULL >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8415
SELECT DISTINCT + + col1 DIV 14 + col0 FROM tab0 AS cor0
----
30
41
95

skipif mysql # not compatible
query I rowsort label-8415
SELECT DISTINCT + + col1 / 14 + col0 FROM tab0 AS cor0
----
30
41
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 + - col2 col1 FROM tab0
----
-117
-166
-85

query I rowsort
SELECT - 27 + + col1 AS col0 FROM tab1
----
-1
-14
-17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 47 col2 FROM tab1 AS cor0
----
47
47
47

query I rowsort
SELECT tab2.col0 * - col2 * + 3 + + col2 FROM tab2
----
-540
-6058
-8968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8420
SELECT - - CAST( NULL AS SIGNED ) * 15 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8420
SELECT - - CAST ( NULL AS INTEGER ) * 15 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col1 + + col0 * col2 AS col0 FROM tab1 AS cor0
----
136
3638
7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + 79 col0 FROM tab1 AS cor0
----
133
136
175

query I rowsort
SELECT ALL col1 * - 68 + tab0.col2 AS col1 FROM tab0
----
-5815
-6106
-6595

query I rowsort
SELECT - cor0.col2 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT tab0.col2 + cor1.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 940a6b82c800eab4d330c129dc095a0c

query I rowsort
SELECT ALL - tab0.col1 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col2 AS REAL ) * + col1 + col1 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8428
SELECT + cor0.col0 + cor0.col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-8428
SELECT + cor0.col0 + cor0.col2 / + col0 AS col1 FROM tab1 AS cor0
----
21
64
81

query I rowsort
SELECT ALL - ( 49 ) FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT 81 FROM tab0, tab2 cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ALL col1 + col1 * - col1 AS col2 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - 46 + + col0 * + ( - 8 * + col1 ) AS col0 FROM tab0 cor0
----
-16558
-27206
-64838

query I rowsort
SELECT ALL + + col1 * col1 * 30 + - col1 * col2 AS col0 FROM tab0 AS cor0
----
219042
240968
282173

query I rowsort
SELECT 27 * col1 AS col0 FROM tab2 AS cor0
----
1593
459
837

query I rowsort
SELECT DISTINCT - 27 + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1
0
11

query I rowsort
SELECT DISTINCT 85 * cor0.col2 AS col0 FROM tab1 cor0
----
4590
4845
8160

onlyif mysql # use DIV operator for integer division
query I rowsort label-8437
SELECT ALL cor0.col0 + + col0 DIV col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-8437
SELECT ALL cor0.col0 + + col0 / col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT - 80 * - col0 FROM tab0 cor0
----
1920
2800
7120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 97 * - cor1.col1 col2 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a5180d07d316c0bacc2b209dd40b3c8d

query I rowsort
SELECT ALL + ( cor0.col0 ) * + 79 * 8 FROM tab0 AS cor0
----
15168
22120
56248

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( - cor0.col0 ) col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT 21 * - col0 AS col2 FROM tab2 AS cor0
----
-147
-1638
-1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-8443
SELECT ALL ( col0 ) DIV + col0 + - col2 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-8443
SELECT ALL ( col0 ) / + col0 + - col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT DISTINCT - 80 * - col2 FROM tab2 AS cor0
----
2080
2160
3040

query I rowsort
SELECT + - 33 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
-1782
-1881
-3168

query I rowsort
SELECT 66 * 29 FROM tab2, tab0 AS cor0, tab0 cor1, tab1 AS cor2
----
81 values hashing to a8d7f414f5ede7659a639cd297f6e5d6

query I rowsort
SELECT col1 + col2 + - col1 * + col0 AS col1 FROM tab0 AS cor0
----
-1945
-3297
-7926

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8448
SELECT + CAST( + 96 AS SIGNED ) - col0 * - ( cor0.col2 ) FROM tab2 cor0
----
2124
285
3098

skipif mysql # not compatible
query I rowsort label-8448
SELECT + CAST ( + 96 AS INTEGER ) - col0 * - ( cor0.col2 ) FROM tab2 cor0
----
2124
285
3098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col2 col0 FROM tab2, tab0 AS cor0, tab1, tab2 AS cor1
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col1 col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 * - col2 col0 FROM tab0
----
-1
-35937
-551368

query I rowsort
SELECT col1 * 22 AS col0 FROM tab2
----
1298
374
682

query I rowsort
SELECT - 59 + + col1 AS col1 FROM tab2 AS cor0
----
-28
-42
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 13 * col2 + - col1 col2 FROM tab2 cor0
----
-382
-397
-511

query I rowsort
SELECT 20 + col2 FROM tab1
----
116
74
77

query I rowsort
SELECT DISTINCT + - col1 * col2 * - 49 FROM tab1 cor0
----
27930
61152
68796

query I rowsort
SELECT DISTINCT + - col2 + + col1 AS col2 FROM tab2 cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-8458
SELECT + col1 * col2 DIV col0 AS col2 FROM tab2 cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-8458
SELECT + col1 * col2 / col0 AS col2 FROM tab2 cor0
----
119
19
8

query I rowsort
SELECT - + col0 * + 74 FROM tab1 AS cor0
----
-222
-4736
-5920

query I rowsort
SELECT DISTINCT + cor0.col0 + - col0 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT col0 * - ( + col0 ) FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-8462
SELECT col1 DIV - 1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-8462
SELECT col1 / - 1 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8463
SELECT - col1 + - col1 DIV cor0.col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-8463
SELECT - col1 + - col1 / cor0.col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + - col2 * - 59 AS col0 FROM tab1 AS cor0
----
3186
3363
5664

query I rowsort
SELECT + col0 - 8 AS col1 FROM tab1
----
-5
56
72

query I rowsort
SELECT tab1.col1 - + 12 AS col1 FROM tab1
----
-2
1
14

query I rowsort
SELECT DISTINCT + 10 + cor0.col2 FROM tab0, tab1 cor0
----
106
64
67

query I rowsort
SELECT cor0.col1 + col1 * - 83 FROM tab2 AS cor0
----
-1394
-2542
-4838

query I rowsort
SELECT + 78 + 44 FROM tab2 cor0
----
122
122
122

query I rowsort
SELECT DISTINCT col0 + - 33 FROM tab0 AS cor0
----
-9
2
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-8471
SELECT ALL col2 DIV + cor0.col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-8471
SELECT ALL col2 / + cor0.col1 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8472
SELECT DISTINCT + col0 + col2 DIV col1 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8472
SELECT DISTINCT + col0 + col2 / col1 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + ( + 38 ) FROM tab2 AS cor0
----
38
38
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8474
SELECT ALL CAST( NULL AS SIGNED ) + col2 * + col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8474
SELECT ALL CAST ( NULL AS INTEGER ) + col2 * + col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8475
SELECT CAST( NULL AS SIGNED ) * + col1 + - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8475
SELECT CAST ( NULL AS INTEGER ) * + col1 + - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 + - 85 * cor0.col0 col0 FROM tab0 AS cor0
----
-2007
-2974
-7483

query I rowsort
SELECT ( 5 ) FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT ALL + ( - col1 ) * col2 + - col1 + col2 AS col1 FROM tab0 AS cor0
----
-193
-2891
-7471

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8479
SELECT ALL - CAST( col2 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-8479
SELECT ALL - CAST ( col2 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT ( - 49 ) + - col2 + - col2 FROM tab0 AS cor0
----
-115
-213
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-8481
SELECT - + 93 + col2 DIV - col1 AS col1 FROM tab0 AS cor0
----
-93
-93
-93

skipif mysql # not compatible
query I rowsort label-8481
SELECT - + 93 + col2 / - col1 AS col1 FROM tab0 AS cor0
----
-93
-93
-93

query I rowsort
SELECT cor0.col2 * + cor0.col0 + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ( - col2 ) + + col0 * + col1 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-8484
SELECT DISTINCT col2 DIV col1 + + col0 * col2 AS col2 FROM tab2 cor0
----
189
2028
3004

skipif mysql # not compatible
query I rowsort label-8484
SELECT DISTINCT col2 / col1 + + col0 * col2 AS col2 FROM tab2 cor0
----
189
2028
3004

query I rowsort
SELECT 54 * cor0.col2 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT ALL - ( col0 ) + + 64 FROM tab0 AS cor0
----
-25
29
40

query I rowsort
SELECT 25 + + cor0.col0 * 87 * ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
116866
18904
400399

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT cor0.col0 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + cor1.col1 + - cor0.col0 * + cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 721d9efcd6fafada903b80988c80ceb4

query I rowsort
SELECT 51 + 73 AS col0 FROM tab1
----
124
124
124

query I rowsort
SELECT 7 + col1 * col1 FROM tab2
----
296
3488
968

query I rowsort
SELECT ( col1 ) * 2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT col0 * - col2 + col0 + + 87 AS col0 FROM tab2 cor0
----
-1863
-2836
-95

query I rowsort
SELECT ( + 9 ) + + col1 FROM tab2
----
26
40
68

query I rowsort
SELECT DISTINCT + ( - col2 * - col2 ) FROM tab1
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8497
SELECT + CAST( NULL AS DECIMAL ) * col1 + col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8497
SELECT + CAST ( NULL AS REAL ) * col1 + col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 15 * - col1 AS col1 FROM tab0 AS cor0
----
1290
1365
1455

onlyif mysql # use DIV operator for integer division
query I rowsort label-8499
SELECT ALL - - col0 * col2 DIV - 12 AS col2 FROM tab0 AS cor0
----
-2
-608
-66

skipif mysql # not compatible
query I rowsort label-8499
SELECT ALL - - col0 * col2 / - 12 AS col2 FROM tab0 AS cor0
----
-2
-608
-66

query I rowsort
SELECT DISTINCT - 19 * + col2 FROM tab2 AS cor0
----
-494
-513
-722

query I rowsort
SELECT ALL - + col0 * col2 * + ( col2 ) + + col2 * + cor0.col0 AS col0 FROM tab1 cor0
----
-204288
-729600
-8586

query I rowsort
SELECT DISTINCT + cor0.col1 + - col1 * + col2 * + col1 AS col0 FROM tab2 AS cor0
----
-10965
-25916
-90447

query I rowsort
SELECT - 91 * + col2 * - col0 AS col0 FROM tab1 AS cor0
----
14742
331968
698880

query I rowsort
SELECT ALL + 85 - + cor0.col1 FROM tab2 AS cor0
----
26
54
68

query I rowsort
SELECT DISTINCT - col1 * cor0.col2 * + ( col2 ) AS col0 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8506
SELECT DISTINCT - - 45 * col2 DIV + ( 58 ) AS col2 FROM tab2 AS cor0
----
20
29

skipif mysql # not compatible
query I rowsort label-8506
SELECT DISTINCT - - 45 * col2 / + ( 58 ) AS col2 FROM tab2 AS cor0
----
20
29

query I rowsort
SELECT + ( col1 ) * - col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1, tab0 cor2
----
3645 values hashing to b803f2d602a28da5cf35ddc7c7fa2eeb

query I rowsort
SELECT DISTINCT - col1 * 97 FROM tab2 AS cor0
----
-1649
-3007
-5723

query I rowsort
SELECT ALL + col2 + + 90 AS col1 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT DISTINCT col1 * 45 AS col2 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT DISTINCT - col1 + - 41 AS col2 FROM tab0 AS cor0
----
-127
-132
-138

onlyif mysql # use DIV operator for integer division
query I rowsort label-8513
SELECT + + col0 DIV col1 - + 80 FROM tab1 AS cor0
----
-74
-74
-80

skipif mysql # not compatible
query I rowsort label-8513
SELECT + + col0 / col1 - + 80 FROM tab1 AS cor0
----
-74
-74
-80

query I rowsort
SELECT + - col1 * + col0 * + col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8515
SELECT ALL CAST( NULL AS DECIMAL ) + col2 + + col2 * col0 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8515
SELECT ALL CAST ( NULL AS REAL ) + col2 + + col2 * col0 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + 94 col2 FROM tab1 AS cor0
----
1222
2444
940

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + 67 col1 FROM tab1 AS cor0
----
-3618
-3819
-6432

query I rowsort
SELECT DISTINCT + col2 + - col2 * + col2 * - 45 FROM tab1 cor0
----
131274
146262
414816

query I rowsort
SELECT - + col0 + + ( - col0 ) * + col2 + 80 AS col0 FROM tab2 cor0
----
-116
-2026
-3001

onlyif mysql # use DIV operator for integer division
query I rowsort label-8520
SELECT DISTINCT - ( - col0 ) DIV col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8520
SELECT DISTINCT - ( - col0 ) / col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT cor0.col0 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL 56 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( ( + col1 ) ) * 11 + col2 col1 FROM tab2 AS cor0
----
-149
-314
-623

query I rowsort
SELECT DISTINCT col1 + - 85 * col0 AS col2 FROM tab1 cor0
----
-229
-5430
-6787

query I rowsort
SELECT + - cor0.col1 * col0 + + col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT + + col1 + + 69 AS col1 FROM tab0 AS cor0
----
155
160
166

onlyif mysql # use DIV operator for integer division
query I rowsort label-8527
SELECT ALL - + 53 DIV 86 - - col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8527
SELECT ALL - + 53 / 86 - - col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + - ( - cor0.col0 ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + - 4 + col0 AS col2 FROM tab0 AS cor0
----
20
31
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8530
SELECT ALL CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8530
SELECT ALL CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + ( ( col1 ) * ( col2 ) ) FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col1 + col1 + col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT + ( - col2 ) + - cor0.col0 * - 21 FROM tab1 AS cor0
----
1287
1584
9

query I rowsort
SELECT - - 74 + + col0 FROM tab0 AS cor0
----
109
163
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8535
SELECT ALL + ( cor0.col2 ) DIV + col0 + ( 5 ) - col2 DIV + col2 AS col0 FROM tab0 AS cor0
----
4
4
5

skipif mysql # not compatible
query I rowsort label-8535
SELECT ALL + ( cor0.col2 ) / + col0 + ( 5 ) - col2 / + col2 AS col0 FROM tab0 AS cor0
----
4
4
5

query I rowsort
SELECT + col2 + col1 * col1 AS col0 FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT ALL 69 * 51 + col1 FROM tab1 AS cor0
----
3529
3532
3545

query I rowsort
SELECT + col1 + - col0 * col0 * col2 + 45 FROM tab0 AS cor0
----
-1083
-18877
-649386

query I rowsort
SELECT + cor0.col2 * cor0.col1 + + 64 * + col1 + cor0.col1 AS col1 FROM tab2 AS cor0
----
1751
2852
5369

query I rowsort
SELECT DISTINCT 12 AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
12

query I rowsort
SELECT - col2 * col1 + cor0.col0 FROM tab2 cor0
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8542
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) + cor0.col2 * col2 * + ( - 60 ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8542
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) + cor0.col2 * col2 * + ( - 60 ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 + - 86 + col2 AS col1 FROM tab0 AS cor0
----
-29
-50
85

query I rowsort
SELECT ALL + col1 + - ( - col0 * cor0.col1 ) AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL col0 + col1 * + cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + + col1 - + col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - col2 * - col2 * 25 + + col0 * col2 + + col0 AS col0 FROM tab2 AS cor0
----
18421
19006
39181

query I rowsort
SELECT DISTINCT + col1 + ( + col0 ) * - col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT col2 + + 99 FROM tab0
----
100
132
181

query I rowsort
SELECT ALL + col0 + ( + col1 ) AS col1 FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8551
SELECT DISTINCT col2 * CAST( 77 * col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
111188
52052
56133

skipif mysql # not compatible
query I rowsort label-8551
SELECT DISTINCT col2 * CAST ( 77 * col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
111188
52052
56133

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8552
SELECT DISTINCT - - col2 + CAST( NULL AS SIGNED ) / + col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8552
SELECT DISTINCT - - col2 + CAST ( NULL AS INTEGER ) / + col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + cor0.col0 + - 93 * - col1 AS col2 FROM tab1 AS cor0
----
1289
2421
994

query I rowsort
SELECT DISTINCT - col0 + + col2 * col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT col0 + ( + ( col2 ) * + col1 ) FROM tab2
----
1612
725
844

query I rowsort
SELECT + col2 * col0 * col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT - + 59 AS col2 FROM tab2 cor0
----
-59
-59
-59

query I rowsort
SELECT - 68 * - col2 + 24 AS col2 FROM tab2 AS cor0
----
1792
1860
2608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 col1 FROM tab2 AS cor0
----
89
89
89

query I rowsort
SELECT - 63 + col0 * - col0 FROM tab0 AS cor0
----
-1288
-639
-7984

onlyif mysql # use DIV operator for integer division
query I rowsort label-8561
SELECT + col1 * col0 + cor0.col2 DIV - col1 FROM tab1 AS cor0
----
1033
635
76

skipif mysql # not compatible
query I rowsort label-8561
SELECT + col1 * col0 + cor0.col2 / - col1 FROM tab1 AS cor0
----
1033
635
76

query I rowsort
SELECT + ( col2 ) * col2 * + col0 AS col1 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT col2 * + ( + col2 + + col2 ) * col1 FROM tab2
----
45198
49096
79768

query I rowsort
SELECT + col2 * - 76 + + 19 FROM tab2
----
-1957
-2033
-2869

query I rowsort
SELECT col1 + col1 * tab2.col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT DISTINCT + ( - 46 ) AS col1 FROM tab2, tab2 AS cor0
----
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( + col2 ) col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8568
SELECT cor0.col2 + col2 DIV col1 AS col2 FROM tab2 cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-8568
SELECT cor0.col2 + col2 / col1 AS col2 FROM tab2 cor0
----
26
27
40

query I rowsort
SELECT ALL + ( + 99 ) FROM tab1 AS cor0
----
99
99
99

query I rowsort
SELECT DISTINCT + + 85 + col1 FROM tab1 cor0
----
111
95
98

query I rowsort
SELECT - 91 * 3 - + cor0.col2 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 53c01542ca9e11a806e23b11097648ab

query I rowsort
SELECT 36 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT - 58 + + col2 AS col0 FROM tab2 AS cor0
----
-20
-31
-32

query I rowsort
SELECT + col0 * col2 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL col2 * - 22 FROM tab2 AS cor0
----
-572
-594
-836

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8576
SELECT - + CAST( - 65 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
65
65
65

skipif mysql # not compatible
query I rowsort label-8576
SELECT - + CAST ( - 65 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
65
65
65

query I rowsort
SELECT DISTINCT + cor0.col2 * + cor0.col0 + + col0 * ( col1 ) AS col1 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT ALL + cor0.col2 - col0 FROM tab2 cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 5 * col0 + cor0.col1 col1 FROM tab1 AS cor0
----
-310
-387
11

query I rowsort
SELECT DISTINCT 51 + - tab1.col0 AS col2 FROM tab1, tab2 AS cor0
----
-13
-29
48

query I rowsort
SELECT - ( - 25 * + col2 + - col1 * col2 ) FROM tab2
----
1512
1596
2184

query I rowsort
SELECT ALL col0 * - tab0.col2 + - col1 * tab0.col0 FROM tab0
----
-15397
-2856
-3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-8583
SELECT + 30 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8583
SELECT + 30 / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 49 * + col2 AS col1 FROM tab2 cor0
----
1274
1323
1862

query I rowsort
SELECT ALL - + col1 + - col2 * cor0.col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - - 72 AS col0 FROM tab2 AS cor0
----
72

query I rowsort
SELECT DISTINCT + 41 + col2 * col0 FROM tab0 AS cor0
----
7339
76
833

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col1 * + col0 col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col0 + ( + cor0.col1 * col0 ) FROM tab0 cor0
----
2040
3360
8010

query I rowsort
SELECT + col2 * + ( 8 ) + col1 * col1 * col2 AS col2 FROM tab1 AS cor0
----
16992
36936
6156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - cor0.col2 col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT cor0.col0 - + 82 AS col1 FROM tab2 AS cor0
----
-3
-4
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-8593
SELECT - cor0.col2 + + ( + col1 + + col0 ) DIV col2 AS col0 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-8593
SELECT - cor0.col2 + + ( + col1 + + col0 ) / col2 AS col0 FROM tab1 AS cor0
----
-54
-56
-96

query I rowsort
SELECT + - col0 * - col2 + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + cor0.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL 92 * + col1 + cor0.col0 FROM tab1 cor0
----
1276
2395
984

query I rowsort
SELECT + 97 * - cor0.col2 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 0cabdf99b89b6403892255197f81d042

query I rowsort
SELECT + 96 + + col2 FROM tab1 AS cor0
----
150
153
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-8599
SELECT 83 DIV + col2 + col0 + - col1 FROM tab0 AS cor0
----
-1
-60
21

skipif mysql # not compatible
query I rowsort label-8599
SELECT 83 / + col2 + col0 + - col1 FROM tab0 AS cor0
----
-1
-60
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col1 + col0 col2 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8601
SELECT col0 * col1 * + col1 + + col1 DIV + col1 col1 FROM tab0 AS cor0
----
177505
329316
737010

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8601
SELECT col0 * col1 * + col1 + + col1 / + col1 col1 FROM tab0 AS cor0
----
177505
329316
737010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 + col2 * - 53 col2 FROM tab0 AS cor0
----
-1773
-4435
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - 41 * cor0.col2 col1 FROM tab0 cor0
----
1435
299218
32472

query I rowsort
SELECT DISTINCT + 39 * - tab0.col2 FROM tab0
----
-1287
-3198
-39

query I rowsort
SELECT ALL + col1 + + 53 FROM tab1 AS cor0
----
63
66
79

query I rowsort
SELECT ALL col1 - col2 AS col2 FROM tab1 cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8607
SELECT DISTINCT - col2 + ( cor0.col1 ) DIV + col1 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-8607
SELECT DISTINCT - col2 + ( cor0.col1 ) / + col1 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT DISTINCT col1 * + col1 + col1 + + col1 * + col1 FROM tab2 AS cor0
----
1953
595
7021

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * 40 - col0 * col2 col0 FROM tab2 AS cor0
----
-2322
1051
332

query I rowsort
SELECT + cor0.col0 + col1 * + 87 AS col1 FROM tab1 AS cor0
----
1211
2265
934

query I rowsort
SELECT ALL + 97 + - col1 AS col2 FROM tab0
----
0
11
6

query I rowsort
SELECT ALL col1 + - col0 * + 26 FROM tab2
----
-151
-1969
-2037

query I rowsort
SELECT - col2 * + ( - col1 * - tab2.col1 ) + + col1 AS col0 FROM tab2
----
-10965
-25916
-90447

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0, tab0 AS cor2 WHERE ( NULL ) < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8615
SELECT ALL + cor0.col2 DIV col0 + 93 * col0 AS col0 FROM tab2 AS cor0
----
654
7254
7347

skipif mysql # not compatible
query I rowsort label-8615
SELECT ALL + cor0.col2 / col0 + 93 * col0 AS col0 FROM tab2 AS cor0
----
654
7254
7347

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * + ( + cor0.col0 ) + - col2 * col2 * - cor0.col0 col0 FROM tab0 AS cor0
----
26928
605734
70

query I rowsort
SELECT DISTINCT + col1 + - 89 FROM tab1 AS cor0
----
-63
-76
-79

query I rowsort
SELECT ALL 44 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 19a2b9512177749564ba22ea2213fe3f

query I rowsort
SELECT ALL - - ( + col1 ) * - 87 FROM tab1 AS cor0
----
-1131
-2262
-870

query I rowsort
SELECT - col2 * - col0 + - col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + + cor0.col1 + col2 - - col2 AS col1 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT col0 + - 86 * col0 AS col0 FROM tab0 AS cor0
----
-2040
-2975
-7565

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 - - col1 * - col0 col1 FROM tab2
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8624
SELECT ( col2 ) + - col1 DIV - col0 AS col1 FROM tab1
----
57
62
96

skipif mysql # not compatible
query I rowsort label-8624
SELECT ( col2 ) + - col1 / - col0 AS col1 FROM tab1
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 43 col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT - 81 + col0 AS col0 FROM tab2 AS cor0
----
-2
-3
-74

query I rowsort
SELECT ALL 26 * col1 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT ALL + col2 + + col1 * 79 FROM tab2
----
1381
2476
4687

query I rowsort
SELECT col2 * + col2 + 79 * - cor0.col0 FROM tab0 cor0
----
-2764
-307
-807

query I rowsort
SELECT DISTINCT col0 + + col0 * 32 FROM tab1 AS cor0
----
2112
2640
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-8631
SELECT DISTINCT - + 7 DIV col1 AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8631
SELECT DISTINCT - + 7 / col1 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - 42 * col0 + + col2 * + col0 AS col1 FROM tab2 AS cor0
----
-105
-1248
-316

query I rowsort
SELECT DISTINCT + ( col1 ) - + col2 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 + - col0 * + CAST ( + col1 + col0 AS REAL ) FROM tab1 cor0
----
-33
-4679
-7344

query I rowsort
SELECT DISTINCT - 50 * - col2 AS col2 FROM tab0 AS cor0
----
1650
4100
50

query I rowsort
SELECT DISTINCT 50 + + col0 FROM tab1 cor0
----
114
130
53

query I rowsort
SELECT + col2 * col0 + - col0 AS col1 FROM tab0 cor0
----
0
7209
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-8638
SELECT - - col1 * col0 DIV - col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8638
SELECT - - col1 * col0 / - col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL cor0.col0 * col2 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - col1 * + col1 - + cor0.col0 * 88 FROM tab1 AS cor0
----
-5732
-7209
-940

query I rowsort
SELECT ALL - col2 + col2 * - 73 * 76 AS col1 FROM tab0 AS cor0
----
-183117
-455018
-5549

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col2 * col1 col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col1 * 22 AS col0 FROM tab1 AS cor0
----
220
286
572

query I rowsort
SELECT - col1 + - 48 + 65 FROM tab1 AS cor0
----
-9
4
7

query I rowsort
SELECT + col2 + - 0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - + col1 * - col2 * cor0.col2 + + col0 AS col0 FROM tab0 AS cor0
----
132
611973
93678

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col0 + + col2 col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL + + col0 + - col1 - col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 18 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col1 + 32 * cor0.col0 col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
9 values hashing to 7c96638281386499b8c4aa5ee5c8a720

query I rowsort
SELECT ALL + 74 * col1 * col0 + col0 AS col0 FROM tab0 AS cor0
----
152760
251265
599415

query I rowsort
SELECT - + ( col1 ) + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8653
SELECT + col2 + col0 DIV col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8653
SELECT + col2 + col0 / col1 FROM tab0
----
1
33
82

query I rowsort
SELECT - - col0 * - col0 + col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT ( col2 ) * - col0 - col2 AS col1 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT + col0 + col1 * tab1.col1 FROM tab1
----
164
249
679

query I rowsort
SELECT + - 14 + - col0 AS col0 FROM tab1 cor0
----
-17
-78
-94

query I rowsort
SELECT - 82 * col1 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-2040
-3379
-6372

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 43 * - 40 * col2 + - col2 col2 FROM tab2 AS cor0
----
-44746
-46467
-65398

query I rowsort
SELECT + col2 + col0 * + 44 FROM tab2 cor0
----
335
3458
3514

query I rowsort
SELECT - col2 + - 75 FROM tab1 AS cor0
----
-129
-132
-171

query I rowsort
SELECT ALL + col1 + 92 + col2 FROM tab2 AS cor0
----
147
150
177

query I rowsort
SELECT ALL cor0.col0 * col1 * - col2 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - - col0 + - 11 FROM tab1 AS cor0
----
-8
53
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-8665
SELECT CAST( - col2 AS SIGNED ) * - col0 + + col1 DIV - col1 + - col2 FROM tab0 AS cor0
----
33
7215
758

skipif mysql # not compatible
query I rowsort label-8665
SELECT CAST ( - col2 AS INTEGER ) * - col0 + + col1 / - col1 + - col2 FROM tab0 AS cor0
----
33
7215
758

query I rowsort
SELECT + 6 + - col0 AS col1 FROM tab2 AS cor0
----
-1
-72
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-8667
SELECT col0 + - 32 DIV col1 + col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-8667
SELECT col0 + - 32 / col1 + col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - + ( col0 ) * - col0 + - col1 AS col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT + cor0.col1 * - cor1.col2 * cor0.col0 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to db77f515b1f090ff0ce5d148d46f664c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8670
SELECT DISTINCT + col0 DIV 32 - - cor0.col1 FROM tab2 AS cor0
----
19
31
61

skipif mysql # not compatible
query I rowsort label-8670
SELECT DISTINCT + col0 / 32 - - cor0.col1 FROM tab2 AS cor0
----
19
31
61

query I rowsort
SELECT + col0 + - 96 FROM tab1 AS cor0
----
-16
-32
-93

query I rowsort
SELECT ALL - col2 + + 20 * cor0.col0 - col1 * + col0 FROM tab1 AS cor0
----
-72
464
583

query I rowsort
SELECT ALL + 5 + col2 FROM tab0 cor0
----
38
6
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-8674
SELECT col0 DIV col1 + cor0.col1 AS col1 FROM tab2 cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-8674
SELECT col0 / col1 + cor0.col1 AS col1 FROM tab2 cor0
----
21
31
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-8675
SELECT DISTINCT - + col0 + + col2 * col0 DIV col0 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-8675
SELECT DISTINCT - + col0 + + col2 * col0 / col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8676
SELECT ALL + CAST( NULL AS SIGNED ) + cor0.col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8676
SELECT ALL + CAST ( NULL AS INTEGER ) + cor0.col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8677
SELECT ALL col2 DIV - ( tab0.col2 ) + 72 * col2 FROM tab0
----
2375
5903
71

skipif mysql # not compatible
query I rowsort label-8677
SELECT ALL col2 / - ( tab0.col2 ) + 72 * col2 FROM tab0
----
2375
5903
71

query I rowsort
SELECT ALL + 97 + col0 AS col2 FROM tab1
----
100
161
177

query I rowsort
SELECT + ( + col2 + - col2 ) FROM tab1
----
0
0
0

query I rowsort
SELECT ( - col2 ) * + col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col1 + ( col1 ) AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - 61 * col1 + col0 FROM tab0 cor0
----
-5222
-5462
-5882

onlyif mysql # use DIV operator for integer division
query I rowsort label-8683
SELECT ALL col2 DIV + col0 + - col0 AS col2 FROM tab2
----
-4
-78
-79

skipif mysql # not compatible
query I rowsort label-8683
SELECT ALL col2 / + col0 + - col0 AS col2 FROM tab2
----
-4
-78
-79

query I rowsort
SELECT DISTINCT 61 + tab1.col2 * col2 AS col1 FROM tab1
----
2977
3310
9277

query I rowsort
SELECT DISTINCT + 73 FROM tab0, tab2, tab1 AS cor0
----
73

query I rowsort
SELECT 2 AS col0 FROM tab1
----
2
2
2

query I rowsort
SELECT ALL + + col1 * - col0 - - col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT col1 + ( + col0 ) + cor0.col0 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT + col1 * - col2 + 76 * - col2 FROM tab0
----
-13694
-173
-5346

query I rowsort
SELECT - col2 * + col2 + - tab0.col0 * col2 FROM tab0
----
-14022
-1881
-36

query I rowsort
SELECT - col2 - 77 * - col0 FROM tab2 cor0
----
512
5980
6045

query I rowsort
SELECT + + col2 + ( col2 ) * + col2 - + 2 FROM tab0 AS cor0
----
0
1120
6804

query I rowsort
SELECT + col0 + - 38 * col2 FROM tab2 cor0
----
-1019
-1365
-910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col2 + col1 * col2 col2 FROM tab0 AS cor0
----
133
2895
7633

query I rowsort
SELECT DISTINCT + + col0 * ( col0 * + col1 ) - 6 * ( col1 ) FROM tab0 AS cor0
----
118243
49020
720265

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 * col0 AS col0 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-8697
SELECT - col2 + col1 * + col1 DIV col1 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-8697
SELECT - col2 + col1 * + col1 / col1 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8698
SELECT ALL - col1 DIV - ( 25 ) + col2 AS col0 FROM tab0 AS cor0
----
36
4
85

skipif mysql # not compatible
query I rowsort label-8698
SELECT ALL - col1 / - ( 25 ) + col2 AS col0 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT + col0 + - col0 * - 9 AS col2 FROM tab1 cor0
----
30
640
800

onlyif mysql # use DIV operator for integer division
query I rowsort label-8700
SELECT ALL - 13 DIV + col0 + + ( col1 ) FROM tab1 AS cor0
----
10
13
22

skipif mysql # not compatible
query I rowsort label-8700
SELECT ALL - 13 / + col0 + + ( col1 ) FROM tab1 AS cor0
----
10
13
22

query I rowsort
SELECT DISTINCT + + 86 * col1 AS col2 FROM tab2 AS cor0
----
1462
2666
5074

query I rowsort
SELECT ALL - col1 * - col0 + + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT 29 * - tab0.col2 + col0 FROM tab0
----
-2289
-933
6

query I rowsort
SELECT DISTINCT + ( col0 ) * - 3 FROM tab2 AS cor0
----
-21
-234
-237

query I rowsort
SELECT + 35 + - col2 FROM tab0 cor0
----
-47
2
34

query I rowsort
SELECT ALL - 55 + + col1 FROM tab2 AS cor0
----
-24
-38
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-8707
SELECT col0 + col0 DIV 87 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-8707
SELECT col0 + col0 / 87 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - + 37 * - col1 * col0 + col1 FROM tab1 AS cor0
----
23690
2912
38493

query I rowsort
SELECT + col1 * ( 97 ) FROM tab1 AS cor0
----
1261
2522
970

query I rowsort
SELECT + - col1 + - ( + 48 ) * col0 + col2 AS col1 FROM tab2 AS cor0
----
-340
-3771
-3777

query I rowsort
SELECT col0 * ( 49 ) FROM tab1 AS cor0
----
147
3136
3920

query I rowsort
SELECT - col0 + 57 + + 13 AS col1 FROM tab2 AS cor0
----
-8
-9
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + cor0.col1 + cor0.col0 col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - 84 + tab2.col2 + col2 FROM tab2
----
-30
-32
-8

query I rowsort
SELECT ALL - col1 + - col1 * col1 FROM tab1
----
-110
-182
-702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8717
SELECT DISTINCT - col0 + - tab2.col0 * + CAST( NULL AS SIGNED ) + 76 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-8717
SELECT DISTINCT - col0 + - tab2.col0 * + CAST ( NULL AS INTEGER ) + 76 FROM tab2
----
NULL

query I rowsort
SELECT ALL 80 * col0 + ( - col1 ) * + col2 AS col2 FROM tab1
----
-1164
4550
5152

query I rowsort
SELECT ALL - - 16 * + 65 + cor0.col1 FROM tab2 AS cor0
----
1057
1071
1099

query I rowsort
SELECT ALL + 24 * - 42 + - col0 - cor0.col0 FROM tab0 cor0
----
-1056
-1078
-1186

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col0 + + col0 col1 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col2 ) + - col2 * - col0 col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT - 6 + - col1 * col1 FROM tab0 cor0
----
-7402
-8287
-9415

query I rowsort
SELECT DISTINCT + col0 + - 53 AS col0 FROM tab2 AS cor0
----
-46
25
26

query I rowsort
SELECT ALL col0 * - cor0.col2 + - col1 * - ( + col2 ) + + col1 AS col0 FROM tab1 AS cor0
----
-3068
-6419
1268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8726
SELECT ALL - CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-8726
SELECT ALL - CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - - col0 * col1 + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-8728
SELECT DISTINCT col0 * - 54 + + cor0.col2 DIV - cor0.col0 AS col2 FROM tab2 AS cor0
----
-381
-4212
-4266

skipif mysql # not compatible
query I rowsort label-8728
SELECT DISTINCT col0 * - 54 + + cor0.col2 / - cor0.col0 AS col2 FROM tab2 AS cor0
----
-381
-4212
-4266

query I rowsort
SELECT ALL + 3 AS col2 FROM tab0 cor0
----
3
3
3

query I rowsort
SELECT - col1 - - col0 * 81 FROM tab0
----
1858
2738
7118

query I rowsort
SELECT - 75 + - cor0.col0 * + col2 FROM tab1 AS cor0
----
-237
-3723
-7755

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 24 - 53 col0 FROM tab0 cor0
----
-29

query I rowsort
SELECT ALL - col0 + 76 AS col1 FROM tab2 AS cor0
----
-2
-3
69

query I rowsort
SELECT DISTINCT cor1.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
26
27
38

query I rowsort
SELECT + col1 * + tab1.col0 + - col1 * - 90 - - 61 FROM tab1
----
1601
2271
2479

query I rowsort
SELECT - col1 + tab1.col0 AS col1 FROM tab1
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 2 * col0 col1 FROM tab1 AS cor0
----
-128
-160
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 * + col1 ) col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT - col0 + - 12 AS col0 FROM tab0
----
-101
-36
-47

query I rowsort
SELECT tab1.col2 + col0 * - col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT 79 AS col1 FROM tab1, tab2 cor0
----
79

query I rowsort
SELECT DISTINCT + + ( - col1 ) * ( col1 ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - col0 * col0 + - 5 AS col0 FROM tab0 AS cor0
----
-1230
-581
-7926

query I rowsort
SELECT - - col2 * col0 * + ( - 14 ) FROM tab0 AS cor0
----
-102172
-11088
-490

query I rowsort
SELECT ALL - col0 * + cor0.col2 + col2 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL + cor2.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to de2705ff0bb8b4f714dafb07497c6119

query I rowsort
SELECT DISTINCT col2 * 56 AS col0 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT ALL - col2 * 27 FROM tab2 AS cor0
----
-1026
-702
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 18 * col2 col2 FROM tab1 AS cor0
----
1026
1728
972

query I rowsort
SELECT - 14 * cor0.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f47235fee495ba41876342db7489e599

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8751
SELECT ALL CAST( ( tab0.col1 ) AS SIGNED ) AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

skipif mysql # not compatible
query I rowsort label-8751
SELECT ALL CAST ( ( tab0.col1 ) AS INTEGER ) AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ALL ( 8 ) AS col2 FROM tab0 cor0
----
8
8
8

query I rowsort
SELECT ALL col2 * + 11 FROM tab2
----
286
297
418

query I rowsort
SELECT + ( + col1 ) + + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8755
SELECT + CAST( 76 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
76
76
76

skipif mysql # not compatible
query I rowsort label-8755
SELECT + CAST ( 76 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
76
76
76

query I rowsort
SELECT ( col1 ) - + 95 FROM tab1 AS cor0
----
-69
-82
-85

query I rowsort
SELECT 6 * + col2 + - col0 FROM tab2 AS cor0
----
149
155
78

query I rowsort
SELECT ALL + col0 * + ( + tab2.col0 ) AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL col1 + 0 * col2 FROM tab0
----
86
91
97

query I rowsort
SELECT - col2 * + col0 + + col2 * + col1 * col2 FROM tab1 AS cor0
----
112128
28842
75654

query I rowsort
SELECT - - col0 * + 98 + - col1 FROM tab2 cor0
----
655
7585
7725

query I rowsort
SELECT + + col2 * col0 + col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-8763
SELECT 90 DIV tab1.col2 AS col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-8763
SELECT 90 / tab1.col2 AS col2 FROM tab1
----
0
1
1

query I rowsort
SELECT + - ( - 83 ) + col2 FROM tab1 AS cor0
----
137
140
179

onlyif mysql # use DIV operator for integer division
query I rowsort label-8765
SELECT 78 + col2 DIV col2 FROM tab1 AS cor0
----
79
79
79

skipif mysql # not compatible
query I rowsort label-8765
SELECT 78 + col2 / col2 FROM tab1 AS cor0
----
79
79
79

query I rowsort
SELECT col0 * cor0.col0 + col0 - - col2 FROM tab1 AS cor0
----
4217
6576
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-8767
SELECT col1 + col0 DIV - col0 col1 FROM tab1 AS cor0
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8767
SELECT col1 + col0 / - col0 col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT - + col0 - cor0.col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8769
SELECT - col2 * + col2 + CAST( + 89 AS SIGNED ) FROM tab2 AS cor0
----
-1355
-587
-640

skipif mysql # not compatible
query I rowsort label-8769
SELECT - col2 * + col2 + CAST ( + 89 AS INTEGER ) FROM tab2 AS cor0
----
-1355
-587
-640

query I rowsort
SELECT DISTINCT - col1 + ( - col2 ) * - col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL 77 + tab2.col0 + col0 FROM tab2
----
233
235
91

query I rowsort
SELECT ALL + 47 + - col0 AS col2 FROM tab0 cor0
----
-42
12
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 32 - + col2 * + ( + 21 + col1 ) col0 FROM tab0
----
-3499
-86
-9152

query I rowsort
SELECT + 16 * - col0 FROM tab1
----
-1024
-1280
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-8775
SELECT ALL col0 + cor0.col0 DIV - cor0.col2 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-8775
SELECT ALL col0 + cor0.col0 / - cor0.col2 FROM tab1 AS cor0
----
3
63
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 31 + col2 col2 FROM tab1 AS cor0
----
127
85
88

query I rowsort
SELECT ALL + 50 - col1 * - col0 * - col0 AS col0 FROM tab2 AS cor0
----
-106047
-1469
-358906

query I rowsort
SELECT col2 + ( + 55 * col1 ) FROM tab2 cor0
----
1732
3271
973

query I rowsort
SELECT ALL - col0 * ( - ( + col0 ) ) * col1 FROM tab1 cor0
----
234
40960
83200

query I rowsort
SELECT cor0.col0 * 53 FROM tab0 AS cor0
----
1272
1855
4717

query I rowsort
SELECT ALL col2 * - 51 FROM tab2 AS cor0
----
-1326
-1377
-1938

query I rowsort
SELECT ALL - col0 + ( ( + cor0.col2 ) ) FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT 31 * col1 AS col2 FROM tab1
----
310
403
806

query I rowsort
SELECT ALL + 35 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

onlyif mysql # use DIV operator for integer division
query I rowsort label-8785
SELECT DISTINCT - col2 DIV - col2 - col0 AS col2 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-8785
SELECT DISTINCT - col2 / - col2 - col0 AS col2 FROM tab1
----
-2
-63
-79

query I rowsort
SELECT ALL col2 + col0 - col0 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - + col0 + + col2 * col0 AS col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL - - col1 + col2 * - col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT - + 6 AS col1 FROM tab2 cor0
----
-6
-6
-6

query I rowsort
SELECT ALL col1 - - 23 FROM tab0 AS cor0
----
109
114
120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8791
SELECT + CAST( NULL AS DECIMAL ) FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-8791
SELECT + CAST ( NULL AS REAL ) FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT + 29 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
29

query I rowsort
SELECT + ( - 97 ) * - col0 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT - col1 * + col0 + - col1 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT + col2 + - 25 FROM tab2
----
1
13
2

query I rowsort
SELECT DISTINCT + cor0.col1 * tab2.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 3aa3dc9c06ac75ec040ed5bc20953cf9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8797
SELECT + col2 DIV + 43 col0 FROM tab1
----
1
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8797
SELECT + col2 / + 43 col0 FROM tab1
----
1
1
2

query I rowsort
SELECT ALL - col0 + - ( - col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * 97 * 93 AS col1 FROM tab0 AS cor0
----
775806
820911
875037

query I rowsort
SELECT ALL + + col0 + 88 * + col2 FROM tab1 AS cor0
----
4755
5080
8528

query I rowsort
SELECT ALL - 97 FROM tab0 cor0
----
-97
-97
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8802
SELECT - col2 + + col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-8802
SELECT - col2 + + col0 / - col0 AS col2 FROM tab2 AS cor0
----
-27
-28
-39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * + col2 col1 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-8804
SELECT DISTINCT - 1 * - col2 DIV + col1 AS col2 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-8804
SELECT DISTINCT - 1 * - col2 / + col1 AS col2 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + ( col0 ) * + col0 + ( + col0 ) * + col0 + col0 FROM tab2 AS cor0
----
105
12246
12561

query I rowsort
SELECT ALL + 17 + col1 * + col1 AS col2 FROM tab2 AS cor0
----
306
3498
978

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * col2 col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL col1 * 37 FROM tab0 cor0
----
3182
3367
3589

onlyif mysql # use DIV operator for integer division
query I rowsort label-8809
SELECT DISTINCT - - 3 DIV + col1 col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8809
SELECT DISTINCT - - 3 / + col1 col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + + ( 78 ) + col0 AS col2 FROM tab2 AS cor0
----
156
157
85

query I rowsort
SELECT ALL + ( + 53 ) * + col2 AS col1 FROM tab2 AS cor0
----
1378
1431
2014

query I rowsort
SELECT ALL 66 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT DISTINCT + tab0.col0 * col2 - + 1 AS col0 FROM tab0
----
34
7297
791

query I rowsort
SELECT ALL + + 16 AS col0 FROM tab2 cor0
----
16
16
16

query I rowsort
SELECT - 36 + - col0 - + col1 AS col1 FROM tab1 AS cor0
----
-110
-129
-65

query I rowsort
SELECT ALL - col1 * - col2 + - col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - col0 * cor0.col0 + - col2 * - col0 - col0 AS col2 FROM tab2 AS cor0
----
-3318
-4134
133

query I rowsort
SELECT DISTINCT + ( - 86 ) FROM tab0 AS cor0
----
-86

query I rowsort
SELECT DISTINCT + col0 + - col2 * - col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL - - cor0.col0 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - - col0 * col0 + - col2 * - 87 AS col0 FROM tab2 AS cor0
----
2398
8346
9547

query I rowsort
SELECT + ( - col2 ) * - col1 + 55 * + col0 * + col2 AS col0 FROM tab0 AS cor0
----
2022
408852
46398

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8823
SELECT DISTINCT - 45 + - col1 * CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-1085
-123
-685

skipif mysql # not compatible
query I rowsort label-8823
SELECT DISTINCT - 45 + - col1 * CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-1085
-123
-685

query I rowsort
SELECT 98 * col1 + + 40 * - col2 FROM tab1 cor0
----
-1300
-2566
388

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * + cor0.col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + cor0.col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - ( col2 ) + 22 FROM tab0 AS cor0
----
-11
-60
21

query I rowsort
SELECT ALL - + col0 * col0 * - col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - 67 * col2 * - cor0.col1 + col2 AS col1 FROM tab1 AS cor0
----
38247
83712
94122

query I rowsort
SELECT ALL + col1 - col1 * col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT + cor0.col0 * - col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT col0 * + col1 + + ( + col0 ) FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + - col2 + + col2 * - col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL - col2 - + col2 * 17 AS col2 FROM tab1 AS cor0
----
-1026
-1728
-972

query I rowsort
SELECT + 77 * cor0.col0 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a6f8fefb781d297b2edd0462b31c8162

query I rowsort
SELECT ALL - + col0 + + 4 * ( col2 ) AS col0 FROM tab0 AS cor0
----
-31
108
239

query I rowsort
SELECT + + col2 * 39 AS col2 FROM tab2 cor0
----
1014
1053
1482

query I rowsort
SELECT DISTINCT + - col2 + cor0.col1 * - col1 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT - col1 + + cor0.col0 * + col2 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT col0 + - col1 * col1 * 21 AS col0 FROM tab2
----
-20174
-5990
-73023

query I rowsort
SELECT DISTINCT col2 + ( col0 ) + cor0.col1 * 5 FROM tab0 AS cor0
----
487
521
626

query I rowsort
SELECT ALL - col1 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + col1 * - ( + ( - col1 ) + col2 ) * col2 FROM tab1 AS cor0
----
-103584
-26790
-39312

query I rowsort
SELECT DISTINCT + - cor0.col0 * cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT + cor0.col0 + - 64 * + col0 FROM tab1 cor0
----
-189
-4032
-5040

query I rowsort
SELECT + 57 + 98 AS col1 FROM tab1, tab2 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 5b067b70cd532661814c93cb82304b09

query I rowsort
SELECT DISTINCT - - col2 + - 39 AS col2 FROM tab1 AS cor0
----
15
18
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8848
SELECT ALL + + col0 + col1 DIV col0 AS col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-8848
SELECT ALL + + col0 + col1 / col0 AS col0 FROM tab2 AS cor0
----
11
78
79

query I rowsort
SELECT DISTINCT 86 AS col0 FROM tab2, tab0 AS cor0
----
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8850
SELECT - CAST( - 28 AS SIGNED ) * + col1 + 43 * + 88 AS col0 FROM tab2
----
4260
4652
5436

skipif mysql # not compatible
query I rowsort label-8850
SELECT - CAST ( - 28 AS INTEGER ) * + col1 + 43 * + 88 AS col0 FROM tab2
----
4260
4652
5436

query I rowsort
SELECT 49 FROM tab0, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to e587c122dea39a2488ff88b884cea462

query I rowsort
SELECT DISTINCT ( - col2 ) * tab2.col0 AS col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + cor0.col0 + - tab0.col0 * + 11 AS col1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to cdd00bd20258e167f2844190b141fd80

query I rowsort
SELECT DISTINCT + 85 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8855
SELECT ( + col1 ) * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8855
SELECT ( + col1 ) * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + cor0.col0 * 19 * col1 FROM tab1 AS cor0
----
12217
1536
19856

query I rowsort
SELECT DISTINCT - ( col2 ) + + 17 AS col2 FROM tab0 AS cor0
----
-16
-65
16

query I rowsort
SELECT - col2 * col0 + - 64 AS col1 FROM tab1 AS cor0
----
-226
-3712
-7744

query I rowsort
SELECT + - col0 + col2 AS col1 FROM tab1 cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8860
SELECT cor0.col1 + CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8860
SELECT cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + - col0 * cor0.col1 + - 48 FROM tab0 AS cor0
----
-2112
-3443
-8147

onlyif mysql # use DIV operator for integer division
query I rowsort label-8862
SELECT DISTINCT + col1 * col0 + col0 DIV cor0.col0 - - cor0.col2 FROM tab2 AS cor0
----
1382
245
4629

skipif mysql # not compatible
query I rowsort label-8862
SELECT DISTINCT + col1 * col0 + col0 / cor0.col0 - - cor0.col2 FROM tab2 AS cor0
----
1382
245
4629

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 + col1 * - ( - col1 * col2 + 45 ) col2 FROM tab1 AS cor0
----
15653
35348
5264

query I rowsort
SELECT col1 + - cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
-4086
-6387
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col1 col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - - col2 * - ( + col1 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - 25 + cor0.col1 FROM tab2 AS cor0
----
-8
34
6

query I rowsort
SELECT DISTINCT + - ( - cor0.col2 ) * - col0 * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL + 10 - + col2 AS col1 FROM tab2 cor0
----
-16
-17
-28

query I rowsort
SELECT ( col1 ) - cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col1 * 11 AS col1 FROM tab0 AS cor0
----
1001
1067
946

query I rowsort
SELECT - 41 * 36 - + col1 * col1 FROM tab1 AS cor0
----
-1576
-1645
-2152

query I rowsort
SELECT + 95 + + col1 AS col1 FROM tab2 AS cor0
----
112
126
154

query I rowsort
SELECT DISTINCT + col1 * - ( + col0 + col0 ) AS col0 FROM tab1 AS cor0
----
-1280
-156
-2080

query I rowsort
SELECT ALL ( col0 + + col2 ) FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + ( + col1 ) * col0 - + 14 * col2 FROM tab2
----
-161
4238
811

query I rowsort
SELECT - - ( + 65 ) * + cor0.col1 * + 20 - col1 AS col2 FROM tab0 cor0
----
111714
118209
126003

query I rowsort
SELECT 23 * - 65 FROM tab0 AS cor0
----
-1495
-1495
-1495

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8879
SELECT DISTINCT - + col0 + - CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8879
SELECT DISTINCT - + col0 + - CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 * + col0 + - col1 - - col0 FROM tab1 AS cor0
----
1107
55
694

query I rowsort
SELECT cor0.col1 + col0 * 90 FROM tab0 AS cor0
----
2246
3247
8101

query I rowsort
SELECT ALL 81 * col0 FROM tab1
----
243
5184
6480

query I rowsort
SELECT DISTINCT 73 * col1 FROM tab1
----
1898
730
949

query I rowsort
SELECT - 29 * - 41 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 92d853b52c35a1d7e52561817bde56b6

query I rowsort
SELECT - col2 * - 55 FROM tab1 cor0
----
2970
3135
5280

query I rowsort
SELECT - + col0 * 80 AS col0 FROM tab0 AS cor0
----
-1920
-2800
-7120

query I rowsort
SELECT DISTINCT + col0 * - 22 FROM tab0 AS cor0
----
-1958
-528
-770

query I rowsort
SELECT ALL + cor1.col0 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL - - ( - 59 ) * col1 FROM tab1 AS cor0
----
-1534
-590
-767

query I rowsort
SELECT col0 + col2 * + col1 AS col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8891
SELECT ALL + + CAST( col2 AS SIGNED ) * + col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-8891
SELECT ALL + + CAST ( col2 AS INTEGER ) * + col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT cor1.col0 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
24
35
89

query I rowsort
SELECT col0 + 19 FROM tab0 AS cor0
----
108
43
54

query I rowsort
SELECT DISTINCT - + 17 AS col0 FROM tab1 AS cor0
----
-17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8895
SELECT CAST( NULL AS SIGNED ) + col0 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8895
SELECT CAST ( NULL AS INTEGER ) + col0 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8896
SELECT ALL - ( col2 ) DIV - col1 AS col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-8896
SELECT ALL - ( col2 ) / - col1 AS col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT 82 * col1 * 8 AS col0 FROM tab2 AS cor0
----
11152
20336
38704

query I rowsort
SELECT + col0 + cor0.col0 + - ( 19 * col2 + + col1 ) FROM tab2 AS cor0
----
-397
-530
-581

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col2 col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL + 97 + col2 FROM tab0
----
130
179
98

query I rowsort
SELECT + ( + col0 ) * col1 + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - - col0 + col2 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + + 66 AS col2 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT DISTINCT - - col0 + + col2 * - col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT ALL + col2 * col2 + 79 AS col2 FROM tab0 AS cor0
----
1168
6803
80

query I rowsort
SELECT DISTINCT - col0 - col2 AS col1 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT + - cor0.col1 + - cor0.col2 * col2 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL - col1 + + col2 * + 79 AS col0 FROM tab2 AS cor0
----
1995
2102
2985

query I rowsort
SELECT + - col2 * col1 + cor0.col1 * - col1 + col0 AS col1 FROM tab1 cor0
----
-1337
-2077
-606

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8910
SELECT col2 * - CAST( - 98 AS SIGNED ) FROM tab2 AS cor0
----
2548
2646
3724

skipif mysql # not compatible
query I rowsort label-8910
SELECT col2 * - CAST ( - 98 AS INTEGER ) FROM tab2 AS cor0
----
2548
2646
3724

query I rowsort
SELECT ALL + col0 * + 21 FROM tab0 AS cor0
----
1869
504
735

query I rowsort
SELECT - cor0.col1 * 24 * 24 FROM tab2 AS cor0
----
-17856
-33984
-9792

query I rowsort
SELECT ALL col0 + + col0 + - tab1.col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL - col0 * col0 * ( - col1 ) + col0 + col2 FROM tab2
----
106214
1553
359060

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - 94 col2 FROM tab2
----
-35
-63
-77

query I rowsort
SELECT + + tab0.col1 + tab0.col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 30f96c938ee95872f59e2a087590314f

query I rowsort
SELECT + ( - col2 ) + + tab0.col0 FROM tab0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8918
SELECT col2 + + col1 DIV + col0 col1 FROM tab1
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8918
SELECT col2 + + col1 / + col0 col1 FROM tab1
----
57
62
96

query I rowsort
SELECT ALL - - col1 + - cor0.col2 - + col2 FROM tab1 AS cor0
----
-104
-179
-82

query I rowsort
SELECT ALL 48 + - col0 * + col1 AS col0 FROM tab2 AS cor0
----
-1295
-169
-4554

query I rowsort
SELECT DISTINCT 2 - + col0 AS col1 FROM tab2 AS cor0
----
-5
-76
-77

query I rowsort
SELECT - - ( - col2 ) * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8923
SELECT - col2 + CAST( + col2 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8923
SELECT - col2 + CAST ( + col2 AS INTEGER ) FROM tab1
----
0
0
0

query I rowsort
SELECT - col1 - col1 * 78 * - col2 FROM tab0
----
221278
581945
7469

query I rowsort
SELECT DISTINCT - col1 * - tab1.col1 + + col0 * - col0 FROM tab1
----
-3996
-6231
667

onlyif mysql # use DIV operator for integer division
query I rowsort label-8926
SELECT - tab0.col2 DIV 90 + 19 AS col2 FROM tab0
----
19
19
19

skipif mysql # not compatible
query I rowsort label-8926
SELECT - tab0.col2 / 90 + 19 AS col2 FROM tab0
----
19
19
19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8927
SELECT ALL col2 * col2 + col2 * + tab1.col1 * CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8927
SELECT ALL col2 * col2 + col2 * + tab1.col1 * CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 31 col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8929
SELECT DISTINCT + cor0.col1 * CAST( NULL AS SIGNED ) - col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8929
SELECT DISTINCT + cor0.col1 * CAST ( NULL AS INTEGER ) - col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - col2 + col1 * 97 + col2 * + col0 FROM tab1
----
2630
4561
8845

onlyif mysql # use DIV operator for integer division
query I rowsort label-8931
SELECT + tab0.col0 DIV tab0.col0 + 60 AS col2 FROM tab0
----
61
61
61

skipif mysql # not compatible
query I rowsort label-8931
SELECT + tab0.col0 / tab0.col0 + 60 AS col2 FROM tab0
----
61
61
61

query I rowsort
SELECT col1 * - 0 * + col1 + col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL + + ( + 44 ) + col2 * ( 31 ) FROM tab0 AS cor0
----
1067
2586
75

query I rowsort
SELECT - - 24 * col2 FROM tab2 AS cor0
----
624
648
912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 76 + col1 col0 FROM tab1 AS cor0
----
-50
-63
-66

query I rowsort
SELECT + - col1 * cor0.col2 + cor0.col0 * 84 FROM tab1 AS cor0
----
-1152
4806
5472

query I rowsort
SELECT ALL col0 * - 96 - col2 AS col2 FROM tab2 cor0
----
-699
-7514
-7622

query I rowsort
SELECT DISTINCT + + 39 * - col2 FROM tab0 AS cor0
----
-1287
-3198
-39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( cor0.col1 ) col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col0 FROM tab0 AS cor0
----
25
25
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8941
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col0 * - col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8941
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col0 * - col0 FROM tab1 cor0
----
NULL

query I rowsort
SELECT + - 46 + + col0 * - col0 FROM tab0 cor0
----
-1271
-622
-7967

query I rowsort
SELECT + + 30 * 41 + - col0 AS col1 FROM tab0 AS cor0
----
1141
1195
1206

query I rowsort
SELECT ( col1 ) + col2 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL - 17 + - col2 * + col0 AS col2 FROM tab0 AS cor0
----
-52
-7315
-809

query I rowsort
SELECT + - col1 + 6 FROM tab1 AS cor0
----
-20
-4
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 90 col1 FROM tab1 AS cor0
----
90
90
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8948
SELECT DISTINCT CAST( - ( col0 ) AS SIGNED ) AS col1 FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8948
SELECT DISTINCT CAST ( - ( col0 ) AS INTEGER ) AS col1 FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8949
SELECT DISTINCT - 0 DIV 40 AS col0 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-8949
SELECT DISTINCT - 0 / 40 AS col0 FROM tab1
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8950
SELECT CAST( NULL AS SIGNED ) * tab0.col2 * + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8950
SELECT CAST ( NULL AS INTEGER ) * tab0.col2 * + col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8951
SELECT CAST( - 15 AS SIGNED ) col2 FROM tab1
----
-15
-15
-15

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8951
SELECT CAST ( - 15 AS INTEGER ) col2 FROM tab1
----
-15
-15
-15

query I rowsort
SELECT - col0 * - 34 FROM tab0
----
1190
3026
816

query I rowsort
SELECT DISTINCT + col2 * ( col2 ) * 13 AS col0 FROM tab0
----
13
14157
87412

query I rowsort
SELECT - col0 * 30 + - col1 * + col0 AS col0 FROM tab1 AS cor0
----
-168
-2560
-3440

query I rowsort
SELECT + - cor0.col0 * col1 + col0 * 78 FROM tab0 AS cor0
----
-1157
-192
-665

query I rowsort
SELECT ALL + 74 AS col1 FROM tab2 cor0
----
74
74
74

query I rowsort
SELECT - ( ( col2 ) ) + ( 14 ) AS col2 FROM tab1 AS cor0
----
-40
-43
-82

query I rowsort
SELECT + + 11 * - col2 AS col1 FROM tab0 cor0
----
-11
-363
-902

query I rowsort
SELECT 89 * col2 FROM tab1 cor0
----
4806
5073
8544

query I rowsort
SELECT - col1 + col1 * cor0.col2 AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT 28 FROM tab2 cor0
----
28
28
28

query I rowsort
SELECT + 12 + + col2 FROM tab0 cor0
----
13
45
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-8963
SELECT - + cor0.col0 DIV ( col0 ) FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8963
SELECT - + cor0.col0 / ( col0 ) FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL col0 * col1 + 82 AS col1 FROM tab0 AS cor0
----
2146
3477
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8965
SELECT ALL - + col0 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8965
SELECT ALL - + col0 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col1 * - 72 + col2 FROM tab0 AS cor0
----
-6159
-6470
-6983

query I rowsort
SELECT - + col2 * col1 * ( col0 ) - + cor0.col1 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT DISTINCT - col1 + 25 AS col2 FROM tab0 AS cor0
----
-61
-66
-72

query I rowsort
SELECT DISTINCT - - col0 * + ( - col2 ) + col0 * col1 AS col0 FROM tab2 AS cor0
----
-1659
2574
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-8970
SELECT cor0.col0 DIV + 72 + col2 * - col2 FROM tab0 AS cor0
----
-1
-1089
-6723

skipif mysql # not compatible
query I rowsort label-8970
SELECT cor0.col0 / + 72 + col2 * - col2 FROM tab0 AS cor0
----
-1
-1089
-6723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * - cor0.col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 + col0 * + tab0.col1 col2 FROM tab0
----
2133
3464
8168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8973
SELECT + cor0.col1 - + CAST( NULL AS SIGNED ) * - ( - col2 + col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8973
SELECT + cor0.col1 - + CAST ( NULL AS INTEGER ) * - ( - col2 + col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col2 - col0 AS col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + + 95 * col0 + col0 AS col0 FROM tab2 AS cor0
----
672
7488
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-8976
SELECT ( col1 ) DIV + col2 + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-8976
SELECT ( col1 ) / + col2 + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT cor0.col1 * 54 FROM tab2, tab1 AS cor0
----
1404
540
702

query I rowsort
SELECT + tab2.col2 + + 1 FROM tab2
----
27
28
39

query I rowsort
SELECT + + cor0.col0 + + 45 * col0 FROM tab2 AS cor0
----
322
3588
3634

onlyif mysql # use DIV operator for integer division
query I rowsort label-8980
SELECT - + col1 + - 36 DIV - 98 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-8980
SELECT - + col1 + - 36 / - 98 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - col0 + ( - col1 ) * col1 AS col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT + + col0 + cor0.col0 * col0 AS col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT col2 * + col2 + + tab2.col2 AS col0 FROM tab2
----
1482
702
756

query I rowsort
SELECT ALL 95 * + col1 + col1 + col0 * col0 AS col2 FROM tab2 cor0
----
11748
3025
7873

query I rowsort
SELECT DISTINCT ( col1 ) * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT col1 * - col1 + + col1 AS col0 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT cor1.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT col2 * col2 + + tab1.col0 AS col1 FROM tab1
----
2919
3313
9296

query III rowsort
SELECT * FROM tab1 WHERE col2 <> col2
----

query I rowsort
SELECT DISTINCT tab1.col1 * 64 FROM tab1, tab1 AS cor0
----
1664
640
832

query I rowsort
SELECT + cor0.col2 * + cor0.col2 + - ( 15 ) * - col0 FROM tab0 AS cor0
----
1449
526
8059

query I rowsort
SELECT ALL + tab2.col0 * + col1 AS col2 FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + 82 + + tab0.col1 * col2 FROM tab0
----
179
2920
7544

query I rowsort
SELECT - 37 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 395d44ccbce08828bc493e93ec3d9207

query I rowsort
SELECT - ( - col0 ) + + 87 AS col0 FROM tab0 AS cor0
----
111
122
176

query I rowsort
SELECT DISTINCT - col0 * 13 * - col0 AS col2 FROM tab2
----
637
79092
81133

query I rowsort
SELECT + col1 - + 59 FROM tab2
----
-28
-42
0

query I rowsort
SELECT - col1 * tab0.col2 + col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + col2 * 25 + + col2 FROM tab2 cor0
----
676
702
988

query I rowsort
SELECT DISTINCT + + col2 * + ( - col1 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col1 * ( col2 ) - - col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + + col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT 1 AS col1 FROM tab2, tab1 AS cor0, tab0 cor1
----
1

query I rowsort
SELECT - + col1 * + ( + col1 ) AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - ( + 35 ) * - tab0.col2 + ( col2 ) - + col1 FROM tab0
----
-61
1102
2861

query I rowsort
SELECT - 10 * 31 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 286e6abee5c98e49bb26d551edba70e0

query I rowsort
SELECT ( + col0 * + col0 ) - 66 AS col2 FROM tab2
----
-17
6018
6175

query I rowsort
SELECT + 41 * col0 AS col0 FROM tab0
----
1435
3649
984

onlyif mysql # use DIV operator for integer division
query I rowsort label-9010
SELECT DISTINCT + ( + tab1.col1 ) DIV - col0 AS col2 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-9010
SELECT DISTINCT + ( + tab1.col1 ) / - col0 AS col2 FROM tab1
----
-8
0

query I rowsort
SELECT DISTINCT col1 * tab1.col0 + col1 - col0 AS col0 FROM tab1
----
101
586
973

query I rowsort
SELECT - + col2 + 46 AS col1 FROM tab0 AS cor0
----
-36
13
45

query I rowsort
SELECT col0 * col0 * 11 FROM tab0 AS cor0
----
13475
6336
87131

query I rowsort
SELECT DISTINCT + 87 + - col0 * - col0 FROM tab0 cor0
----
1312
663
8008

query I rowsort
SELECT + col1 + - col1 * 36 FROM tab2 AS cor0
----
-1085
-2065
-595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 * col2 col1 FROM tab1
----
1026
1728
972

query I rowsort
SELECT DISTINCT + 7 AS col0 FROM tab0
----
7

query I rowsort
SELECT 31 * + col1 + + col0 AS col0 FROM tab0 AS cor0
----
2690
2910
3042

query I rowsort
SELECT DISTINCT - 83 + col2 FROM tab0 cor0
----
-1
-50
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9020
SELECT + col1 * col0 DIV + 96 + col0 * col2 FROM tab2 AS cor0
----
191
2075
3015

skipif mysql # not compatible
query I rowsort label-9020
SELECT + col1 * col0 / + 96 + col0 * col2 FROM tab2 AS cor0
----
191
2075
3015

query I rowsort
SELECT ALL + 84 * cor0.col1 AS col1 FROM tab0 AS cor0
----
7224
7644
8148

query I rowsort
SELECT + + 34 * col2 AS col2 FROM tab2 AS cor0
----
1292
884
918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 col2 FROM tab2 AS cor0
----
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-9024
SELECT DISTINCT + col2 + col2 + col0 DIV - col0 FROM tab1 AS cor0
----
107
113
191

skipif mysql # not compatible
query I rowsort label-9024
SELECT DISTINCT + col2 + col2 + col0 / - col0 FROM tab1 AS cor0
----
107
113
191

query I rowsort
SELECT - + col1 * + cor0.col0 + + col1 * + col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + - col0 * cor0.col0 + - col2 FROM tab0 AS cor0
----
-1129
-523
-7912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL + 73 + col0 AS col1 FROM tab2
----
151
152
80

query I rowsort
SELECT ALL col1 + col0 * cor0.col2 - + col1 * - col0 AS col2 FROM tab0 AS cor0
----
15488
2942
3527

query I rowsort
SELECT col2 * + tab2.col0 + col1 FROM tab2
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-9031
SELECT DISTINCT - tab0.col1 * + tab0.col0 DIV - col0 AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9031
SELECT DISTINCT - tab0.col1 * + tab0.col0 / - col0 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT + tab2.col2 + col1 * + col2 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-9033
SELECT DISTINCT 0 DIV cor0.col0 - col2 col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9033
SELECT DISTINCT 0 / cor0.col0 - col2 col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col0 * 94 + col2 + col2 * + col2 AS col1 FROM tab1
----
16832
3252
9322

query I rowsort
SELECT ALL + ( col0 * + tab1.col0 ) - - tab1.col1 * + col2 FROM tab1
----
1413
4666
7648

onlyif mysql # use DIV operator for integer division
query I rowsort label-9036
SELECT ALL 68 * + col0 + + col2 * col1 DIV col2 AS col0 FROM tab0 cor0
----
1718
2477
6143

skipif mysql # not compatible
query I rowsort label-9036
SELECT ALL 68 * + col0 + + col2 * col1 / col2 AS col0 FROM tab0 cor0
----
1718
2477
6143

query I rowsort
SELECT - 93 * col1 AS col1 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT DISTINCT - + ( col2 ) + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 70 * col1 - col1 col0 FROM tab2
----
1173
2139
4071

query I rowsort
SELECT 62 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9041
SELECT CAST( 13 AS SIGNED ) + - tab0.col0 * - col1 + col2 FROM tab0
----
2110
3409
8194

skipif mysql # not compatible
query I rowsort label-9041
SELECT CAST ( 13 AS INTEGER ) + - tab0.col0 * - col1 + col2 FROM tab0
----
2110
3409
8194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 col2 FROM tab1
----
16
16
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-9043
SELECT + 38 DIV 30 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9043
SELECT + 38 / 30 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT col2 - 46 FROM tab2
----
-19
-20
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 col1 FROM tab1, tab2 cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

onlyif mysql # use DIV operator for integer division
query I rowsort label-9046
SELECT col0 - col2 DIV + col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9046
SELECT col0 - col2 / + col1 FROM tab0
----
24
35
89

query I rowsort
SELECT + 22 * + col0 FROM tab0
----
1958
528
770

query I rowsort
SELECT DISTINCT + col2 + col2 - col1 * + col0 AS col0 FROM tab0
----
-1998
-3393
-7935

query I rowsort
SELECT - col0 + + col1 + tab0.col1 AS col0 FROM tab0
----
148
159
93

query I rowsort
SELECT DISTINCT col2 * + col0 + col0 AS col2 FROM tab1
----
165
3712
7760

query I rowsort
SELECT col2 + - cor0.col1 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - 72 * + col0 FROM tab1 AS cor0
----
-216
-4608
-5760

query I rowsort
SELECT DISTINCT 66 + col0 AS col0 FROM tab1 AS cor0
----
130
146
69

query I rowsort
SELECT DISTINCT - col2 * - col1 * col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + ( col1 ) * - col2 + - col0 * - col0 * col0 + col0 FROM tab0 cor0
----
11010
42813
697596

query I rowsort
SELECT ALL - - col0 * cor0.col2 - col2 AS col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + - col2 * - cor0.col0 AS col1 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * cor0.col0 + col1 col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - 15 + + col0 FROM tab2 cor0
----
-8
63
64

query I rowsort
SELECT DISTINCT - col1 + col2 * + col1 AS col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT col1 * + col0 * - col0 AS col0 FROM tab1
----
-234
-40960
-83200

query III rowsort
SELECT ALL * FROM tab1 WHERE - col1 * + col1 + col0 NOT BETWEEN NULL AND + col2
----

query I rowsort
SELECT DISTINCT tab1.col2 * - col0 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + col1 * col2 + - col1 AS col0 FROM tab0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - col2 * + col2 AS col1 FROM tab2 WHERE ( NULL ) <> col2
----

query I rowsort
SELECT DISTINCT - col0 * col1 * + cor0.col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - col1 AS col1 FROM tab2 WHERE NOT NULL <= col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9068
SELECT col0 + tab1.col0 DIV - col2 FROM tab1
----
3
63
80

skipif mysql # not compatible
query I rowsort label-9068
SELECT col0 + tab1.col0 / - col2 FROM tab1
----
3
63
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9069
SELECT ALL + col1 DIV tab1.col0 - col2 AS col2 FROM tab1
----
-46
-57
-96

skipif mysql # not compatible
query I rowsort label-9069
SELECT ALL + col1 / tab1.col0 - col2 AS col2 FROM tab1
----
-46
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + tab1.col2 col0 FROM tab1
----
121
176
57

query III rowsort
SELECT * FROM tab0 WHERE col0 + - col2 - + col1 BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT ALL col1 + + col2 * - col2 + - col0 * col0 FROM tab0
----
-1129
-14554
-1579

query I rowsort
SELECT ALL col0 * col2 + - tab1.col1 AS col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + col2 * tab2.col0 * col0 + col2 * - col2 FROM tab2
----
157508
235714
594

query I rowsort
SELECT ALL col2 * - col2 + - col0 + col1 FROM tab1
----
-2893
-3303
-9283

query I rowsort
SELECT ALL + col2 + + col2 + col0 * + col0 * + col1 FROM tab0
----
118827
49602
720975

onlyif mysql # use DIV operator for integer division
query I rowsort label-9077
SELECT - col0 * col0 DIV - col1 FROM tab2
----
1
103
367

skipif mysql # not compatible
query I rowsort label-9077
SELECT - col0 * col0 / - col1 FROM tab2
----
1
103
367

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) IN ( + col2 + col0 )
----

query I rowsort
SELECT ALL + col1 * col1 / col1 + col0 + col2 AS col1 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col0 + + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9080
SELECT ALL - col0 DIV col0 + - col2 + col0 FROM tab0
----
-10
33
6

skipif mysql # not compatible
query I rowsort label-9080
SELECT ALL - col0 / col0 + - col2 + col0 FROM tab0
----
-10
33
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col1 col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - col1 AS col1 FROM tab1 WHERE NOT NULL = NULL
----

query I rowsort
SELECT ALL + col2 + - col0 FROM tab2 WHERE ( NULL ) IN ( - col1 )
----

query I rowsort
SELECT ALL + + col0 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + + col1 * - col1 + + col1 * col1 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9086
SELECT DISTINCT - + col0 DIV + col2 + col0 AS col0 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-9086
SELECT DISTINCT - + col0 / + col2 + col0 AS col0 FROM tab0 AS cor0
----
0
24
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col2 * col1 col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL - cor0.col0 * cor0.col0 + col1 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT ALL - + cor0.col0 * + col0 + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL + col0 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-9091
SELECT DISTINCT - + col0 + + col1 DIV + col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-9091
SELECT DISTINCT - + col0 + + col1 / + col0 FROM tab1 AS cor0
----
-64
-80
5

query I rowsort
SELECT DISTINCT col2 AS col2 FROM tab1 AS cor0 WHERE NULL IN ( col0 )
----

query I rowsort
SELECT + cor0.col0 + col2 * cor0.col0 FROM tab0 cor0 WHERE NULL <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 col2 FROM tab0 AS cor0 WHERE NOT NULL NOT IN ( + col0 * - col1 )
----

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab2, tab0 AS cor0
----
47

query I rowsort
SELECT ALL - ( col2 ) * tab0.col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9097
SELECT ALL - CAST( col1 AS SIGNED ) AS col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9097
SELECT ALL - CAST ( col1 AS INTEGER ) AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT col1 + + col2 + col1 * ( col1 ) AS col0 FROM tab0 AS cor0
----
7515
8454
9507

query I rowsort
SELECT ALL - 13 * cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 61ccd319ad73ab5f49bc436892fccfa5

query I rowsort
SELECT DISTINCT - + cor0.col1 * col1 * - col2 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9101
SELECT col0 + col1 * CAST( + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
132
2862
7551

skipif mysql # not compatible
query I rowsort label-9101
SELECT col0 + col1 * CAST ( + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - ( col0 ) + - col2 * col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( tab0.col2 ) col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + + 36 * col2 FROM tab0 AS cor0
----
1188
2952
36

query I rowsort
SELECT + + col0 * col2 * 91 AS col1 FROM tab1 AS cor0
----
14742
331968
698880

query I rowsort
SELECT ALL - 75 * - col0 FROM tab1 AS cor0
----
225
4800
6000

query I rowsort
SELECT ALL - + 20 AS col2 FROM tab0 AS cor0
----
-20
-20
-20

query I rowsort
SELECT - - col0 * - 74 AS col2 FROM tab0 cor0
----
-1776
-2590
-6586

query I rowsort
SELECT col2 * - cor0.col0 + + 49 * - col1 + col0 FROM tab0 cor0
----
-11668
-4753
-4982

onlyif mysql # use DIV operator for integer division
query I rowsort label-9110
SELECT cor0.col1 * ( col0 ) + + col2 DIV - ( + col1 ) FROM tab2 AS cor0
----
1341
217
4602

skipif mysql # not compatible
query I rowsort label-9110
SELECT cor0.col1 * ( col0 ) + + col2 / - ( + col1 ) FROM tab2 AS cor0
----
1341
217
4602

query I rowsort
SELECT - col1 + + 31 FROM tab0 AS cor0
----
-55
-60
-66

query I rowsort
SELECT - + col2 * - col0 + - col1 AS col0 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9113
SELECT - col0 + CAST( ( + col1 ) AS SIGNED ) * col0 FROM tab2 cor0
----
1264
210
4524

skipif mysql # not compatible
query I rowsort label-9113
SELECT - col0 + CAST ( ( + col1 ) AS INTEGER ) * col0 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT - col2 * + 80 AS col1 FROM tab0 cor0
----
-2640
-6560
-80

query I rowsort
SELECT + col1 - cor0.col1 * - col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - ( col2 ) * + col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + + col0 + + col0 AS col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT cor0.col0 * + 32 + - col2 FROM tab1 AS cor0
----
1991
2464
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
86
91
97

query I rowsort
SELECT ALL - - col1 * col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - - col2 + 87 * col2 AS col0 FROM tab2 AS cor0
----
2288
2376
3344

query I rowsort
SELECT + 54 * + col2 + col0 * + ( cor0.col2 + + col2 * ( - col1 ) ) AS col0 FROM tab2 AS cor0
----
-116220
-4212
-45980

query I rowsort
SELECT DISTINCT col1 + + col0 * col2 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT col2 + - cor0.col2 * col2 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT + col0 + - 63 FROM tab2 cor0
----
-56
15
16

query I rowsort
SELECT + 17 + col2 + + col2 AS col0 FROM tab0 AS cor0
----
181
19
83

query I rowsort
SELECT + 78 * + col0 - col2 FROM tab0 cor0
----
1839
2729
6860

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9128
SELECT DISTINCT + + CAST( + col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-9128
SELECT DISTINCT + + CAST ( + col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9129
SELECT DISTINCT - col2 + 59 DIV cor0.col2 FROM tab1 AS cor0
----
-53
-56
-96

skipif mysql # not compatible
query I rowsort label-9129
SELECT DISTINCT - col2 + 59 / cor0.col2 FROM tab1 AS cor0
----
-53
-56
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + 55 col2 FROM tab0 AS cor0
----
-31
-36
-42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 92 * col2 col2 FROM tab0 AS cor0
----
3036
7544
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-9132
SELECT DISTINCT col0 DIV + 87 + + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9132
SELECT DISTINCT col0 / + 87 + + col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 15 * - ( col2 ) col2 FROM tab0 AS cor0
----
-1230
-15
-495

query I rowsort
SELECT ALL 3 * - 76 * + col0 + col0 FROM tab1 AS cor0
----
-14528
-18160
-681

query I rowsort
SELECT ( - col0 ) - col2 * 7 FROM tab0 AS cor0
----
-255
-42
-663

query I rowsort
SELECT ALL cor0.col0 * - col0 + - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + + col1 col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - + cor0.col1 * - ( - col0 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col1 * - col0 + - col2 * col1 AS col0 FROM tab0
----
-774
3298
637

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9141
SELECT DISTINCT col0 * - col1 + CAST( NULL AS SIGNED ) col0 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9141
SELECT DISTINCT col0 * - col1 + CAST ( NULL AS INTEGER ) col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT + col2 * - col1 + - 77 + + col2 * col0 * - col1 AS col2 FROM tab0 AS cor0
----
-3569
-671657
-71027

query I rowsort
SELECT 64 * + tab0.col0 AS col1 FROM tab0
----
1536
2240
5696

query I rowsort
SELECT DISTINCT - tab2.col1 + ( + tab2.col2 ) AS col1 FROM tab2
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-9145
SELECT + col0 + - 58 DIV - tab0.col0 FROM tab0
----
26
36
89

skipif mysql # not compatible
query I rowsort label-9145
SELECT + col0 + - 58 / - tab0.col0 FROM tab0
----
26
36
89

query I rowsort
SELECT DISTINCT + cor0.col0 + - 28 * - ( - col1 ) AS col2 FROM tab1 AS cor0
----
-216
-284
-725

query I rowsort
SELECT ALL + 49 AS col2 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT DISTINCT - + col1 * col2 + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT col2 + ( 72 ) * col1 + - ( tab0.col2 ) * col1 FROM tab0
----
-828
3387
6888

query I rowsort
SELECT DISTINCT col0 - ( col2 ) * - col0 AS col2 FROM tab0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-9151
SELECT col0 + - tab2.col0 * ( + col1 ) DIV + tab2.col1 AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9151
SELECT col0 + - tab2.col0 * ( + col1 ) / + tab2.col1 AS col2 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9152
SELECT - tab0.col1 - CAST( col1 + col0 AS SIGNED ) FROM tab0
----
-196
-229
-271

skipif mysql # not compatible
query I rowsort label-9152
SELECT - tab0.col1 - CAST ( col1 + col0 AS INTEGER ) FROM tab0
----
-196
-229
-271

query I rowsort
SELECT col0 * - 41 + 65 + col1 * - col0 AS col1 FROM tab1
----
-136
-3199
-4255

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 + + col1 col0 FROM tab2
----
-24
51
7

query I rowsort
SELECT ALL + 67 * - col2 AS col2 FROM tab1
----
-3618
-3819
-6432

query I rowsort
SELECT + ( - 13 ) FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - col0 * + col1 + + col0 + 74 FROM tab2 AS cor0
----
-1190
-136
-4450

query I rowsort
SELECT + 78 - col0 AS col1 FROM tab0 AS cor0
----
-11
43
54

query I rowsort
SELECT col2 + col2 * - 34 FROM tab2 AS cor0
----
-1254
-858
-891

query I rowsort
SELECT DISTINCT + - col2 + col1 * col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT + ( - col0 ) * col0 * - 69 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
39830
546640
84622

query I rowsort
SELECT ALL - ( + col0 ) * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - col2 * - col2 + + cor0.col1 + 74 FROM tab2 AS cor0
----
1535
809
834

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab1 cor1, tab1, tab1 AS cor2
----
3645 values hashing to d10b928ceb6690f7c98bfe77a5adfcac

query I rowsort
SELECT - ( - 66 ) * cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 08947d915aab150cea9ea45d94d4263b

skipif mysql # not compatible
query I rowsort
SELECT - + col1 + + CAST ( col0 AS REAL ) AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - cor0.col2 * + col1 + - ( + col2 + col2 ) FROM tab1 AS cor0
----
-1440
-1512
-684

query I rowsort
SELECT DISTINCT - + col1 + 69 AS col1 FROM tab1 AS cor0
----
43
56
59

query I rowsort
SELECT ALL - col2 - ( 52 ) * + col1 FROM tab1 AS cor0
----
-1406
-577
-772

query I rowsort
SELECT ALL col1 - 97 FROM tab0 AS cor0
----
-11
-6
0

query I rowsort
SELECT ALL - col1 - col0 * + col2 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + cor0.col2 + - cor0.col1 col2 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT ALL col0 * + 27 FROM tab1
----
1728
2160
81

query I rowsort
SELECT DISTINCT + cor0.col0 - cor0.col1 FROM tab2, tab0 AS cor0
----
-2
-62

query I rowsort
SELECT DISTINCT + - 60 * + col1 + col0 AS col1 FROM tab0 AS cor0
----
-5136
-5371
-5785

query I rowsort
SELECT ALL + 16 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to 9ffb4aaf972de606a4957894645b6216

query I rowsort
SELECT - ( + cor0.col1 ) * col2 + - 57 FROM tab2 AS cor0
----
-1591
-703
-894

query I rowsort
SELECT + col1 + col0 + col1 AS col2 FROM tab2
----
113
196
69

query I rowsort
SELECT DISTINCT 97 * - 30 - - col1 FROM tab1
----
-2884
-2897
-2900

query I rowsort
SELECT - 59 + - col0 * 74 FROM tab1 AS cor0
----
-281
-4795
-5979

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9182
SELECT DISTINCT CAST( + 44 AS SIGNED ) * + tab1.col1 FROM tab1
----
1144
440
572

skipif mysql # not compatible
query I rowsort label-9182
SELECT DISTINCT CAST ( + 44 AS INTEGER ) * + tab1.col1 FROM tab1
----
1144
440
572

query I rowsort
SELECT ( - 6 ) AS col0 FROM tab0
----
-6
-6
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9184
SELECT DISTINCT + col1 * + tab0.col1 DIV col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9184
SELECT DISTINCT + col1 * + tab0.col1 / col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + col2 * - col1 * ( - col0 ) AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + col2 * + col2 AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT + col2 - 82 FROM tab2 AS cor0
----
-44
-55
-56

query I rowsort
SELECT DISTINCT - cor0.col2 * ( - 51 ) AS col2 FROM tab0 AS cor0
----
1683
4182
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - 38 col1 FROM tab1 AS cor0
----
-102
-118
-41

query I rowsort
SELECT ALL cor0.col0 + - 25 FROM tab1, tab0 AS cor0
----
9 values hashing to 8c01861655db553c6402de5d7f0033ea

query I rowsort
SELECT ( - col1 ) + + 91 AS col0 FROM tab2 AS cor0
----
32
60
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-9192
SELECT ALL tab2.col1 DIV 78 + + 95 FROM tab2, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif mysql # not compatible
query I rowsort label-9192
SELECT ALL tab2.col1 / 78 + + 95 FROM tab2, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT - 28 * + tab1.col0 AS col2 FROM tab1
----
-1792
-2240
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9194
SELECT - col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9194
SELECT - col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + 28 FROM tab2 AS cor0
----
1652
476
868

query I rowsort
SELECT - + ( + col0 ) + + col2 * col1 AS col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + col0 * col0 + col1 + cor0.col1 AS col2 FROM tab1 AS cor0
----
4116
61
6426

query I rowsort
SELECT ALL + + 18 * col1 FROM tab2 cor0
----
1062
306
558

query I rowsort
SELECT ALL + + ( col0 ) * col2 + - ( + 97 ) * - col0 FROM tab2 AS cor0
----
10665
868
9594

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 80 AS REAL ) + col1 col2 FROM tab2 AS cor0
----
111
139
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9201
SELECT - CAST( 97 AS SIGNED ) FROM tab2 AS cor0
----
-97
-97
-97

skipif mysql # not compatible
query I rowsort label-9201
SELECT - CAST ( 97 AS INTEGER ) FROM tab2 AS cor0
----
-97
-97
-97

query I rowsort
SELECT ( col2 * + col0 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL - col1 + - col0 * col1 * col2 FROM tab2 cor0
----
-119711
-51051
-5890

query I rowsort
SELECT DISTINCT - col0 * col2 + + 0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + + col1 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - - col2 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col1 * - col0 + + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT tab0.col0 + col1 + - col1 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT - col1 * + 64 + - 92 AS col0 FROM tab0
----
-5596
-5916
-6300

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - col0 + + CAST ( col2 + col0 AS REAL ) col0 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT col0 + 55 * col2 * + col2 AS col2 FROM tab0
----
369909
59919
90

query I rowsort
SELECT col2 * - col1 + col0 AS col1 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT - col1 * - ( cor0.col1 + - col0 ) AS col1 FROM tab1 AS cor0
----
-540
-871
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-9214
SELECT - col0 * cor0.col1 + 57 DIV - col0 FROM tab1 AS cor0
----
-1040
-640
-97

skipif mysql # not compatible
query I rowsort label-9214
SELECT - col0 * cor0.col1 + 57 / - col0 FROM tab1 AS cor0
----
-1040
-640
-97

query I rowsort
SELECT ALL ( 43 ) FROM tab0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-9216
SELECT ( 40 + col1 ) DIV col2 AS col1 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9216
SELECT ( 40 + col1 ) / col2 AS col1 FROM tab1
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9217
SELECT - CAST( NULL AS SIGNED ) * 5 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9217
SELECT - CAST ( NULL AS INTEGER ) * 5 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 83 * col2 AS col2 FROM tab2 AS cor0
----
-2158
-2241
-3154

query I rowsort
SELECT + + col0 * 52 FROM tab2 AS cor0
----
364
4056
4108

onlyif mysql # use DIV operator for integer division
query I rowsort label-9220
SELECT + + col0 + col0 DIV + col1 AS col0 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-9220
SELECT + + col0 + col0 / + col1 AS col0 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT - + col1 * cor0.col0 + - col0 AS col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT col0 + col1 + - ( + cor0.col1 ) FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - + col2 * col0 + - col1 * + col2 - col1 FROM tab0 AS cor0
----
-14851
-229
-3716

query I rowsort
SELECT ALL + col0 - + col1 * 8 AS col1 FROM tab0
----
-639
-664
-741

query I rowsort
SELECT ALL + - cor0.col1 + - col1 AS col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT + ( col0 ) * + ( + col2 ) FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-9227
SELECT ALL col1 DIV col0 + 47 AS col2 FROM tab1 AS cor0
----
47
47
55

skipif mysql # not compatible
query I rowsort label-9227
SELECT ALL col1 / col0 + 47 AS col2 FROM tab1 AS cor0
----
47
47
55

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col0 + - col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-9229
SELECT - ( col2 ) DIV + cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9229
SELECT - ( col2 ) / + cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * - col0 + col2 FROM tab2 cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9231
SELECT ALL col2 * - cor0.col2 + cor0.col1 + cor0.col1 DIV + col1 FROM tab1 AS cor0
----
-2889
-3238
-9202

skipif mysql # not compatible
query I rowsort label-9231
SELECT ALL col2 * - cor0.col2 + cor0.col1 + cor0.col1 / + col1 FROM tab1 AS cor0
----
-2889
-3238
-9202

query I rowsort
SELECT DISTINCT - col2 * + col2 + col0 + col0 FROM tab2 cor0
----
-1286
-520
-715

query I rowsort
SELECT ALL + col0 * + col1 * 27 FROM tab2 AS cor0
----
124254
36261
5859

query I rowsort
SELECT col2 + + 53 * col1 AS col2 FROM tab2 AS cor0
----
1670
3153
939

query I rowsort
SELECT + + cor0.col2 * col0 * col2 + col2 AS col1 FROM tab0 AS cor0
----
26169
36
598518

query I rowsort
SELECT ALL col0 * + ( + col2 + col1 ) FROM tab0 AS cor0
----
15397
2856
3430

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9237
SELECT - + col1 + CAST( + cor0.col1 + col0 AS SIGNED ) * - col2 FROM tab2 cor0
----
-1057
-3621
-3665

skipif mysql # not compatible
query I rowsort label-9237
SELECT - + col1 + CAST ( + cor0.col1 + col0 AS INTEGER ) * - col2 FROM tab2 cor0
----
-1057
-3621
-3665

onlyif mysql # use DIV operator for integer division
query I rowsort label-9238
SELECT DISTINCT + - col0 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9238
SELECT DISTINCT + - col0 / cor0.col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - col2 + col2 * col1 - + col2 AS col0 FROM tab2 AS cor0
----
1482
570
783

query I rowsort
SELECT DISTINCT - col0 + - 29 * + col1 AS col1 FROM tab0 AS cor0
----
-2518
-2728
-2848

query I rowsort
SELECT ALL ( col1 ) - col0 AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT col1 + + ( + col1 ) AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + 29 * + col1 * + col0 FROM tab0 cor0
----
234871
59856
98455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( cor1.col0 ) col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL - col0 * + col1 * + col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - col2 * + 27 FROM tab1 AS cor0
----
-1458
-1539
-2592

query I rowsort
SELECT DISTINCT + col2 + + ( - col1 ) * - 36 AS col0 FROM tab2 AS cor0
----
1143
2150
650

query I rowsort
SELECT DISTINCT - 28 AS col1 FROM tab2
----
-28

query I rowsort
SELECT 59 * - col2 * col2 FROM tab1 cor0
----
-172044
-191691
-543744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 30 col1 FROM tab2, tab1 AS cor0
----
30

query I rowsort
SELECT + ( - col1 + + col1 * tab2.col2 ) FROM tab2
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9252
SELECT CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9252
SELECT CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + + 42 FROM tab1
----
106
122
45

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 cor1, tab1 AS cor2
----
-17
-31
-59

query I rowsort
SELECT DISTINCT cor0.col1 * + 49 FROM tab1, tab2 cor0
----
1519
2891
833

query I rowsort
SELECT 32 - - 86 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 528a2467a4ebc1dbbdbc606b82f4dd83

query I rowsort
SELECT 28 * cor0.col0 + col1 FROM tab2 AS cor0
----
2229
2243
227

query I rowsort
SELECT ALL + 78 * + col2 AS col1 FROM tab1 AS cor0
----
4212
4446
7488

query I rowsort
SELECT + 64 + - 91 AS col1 FROM tab1 cor0
----
-27
-27
-27

query I rowsort
SELECT DISTINCT + 84 + cor0.col2 FROM tab1 AS cor0
----
138
141
180

query I rowsort
SELECT DISTINCT ( + 93 ) FROM tab2
----
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9262
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + col1 * col1 / 85 + - col2 * - col2 AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9262
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + col1 * col1 / 85 + - col2 * - col2 AS col1 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9263
SELECT - + CAST( NULL AS SIGNED ) + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9263
SELECT - + CAST ( NULL AS INTEGER ) + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9264
SELECT ALL + CAST( col1 AS SIGNED ) * - col0 AS col1 FROM tab1 cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-9264
SELECT ALL + CAST ( col1 AS INTEGER ) * - col0 AS col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT - ( col1 + 22 ) * - 32 FROM tab1
----
1024
1120
1536

query I rowsort
SELECT DISTINCT ( + tab2.col1 ) AS col2 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9267
SELECT DISTINCT - ( col1 ) + + col2 DIV 58 AS col0 FROM tab0 AS cor0
----
-86
-90
-97

skipif mysql # not compatible
query I rowsort label-9267
SELECT DISTINCT - ( col1 ) + + col2 / 58 AS col0 FROM tab0 AS cor0
----
-86
-90
-97

query I rowsort
SELECT + col1 * col1 + - 90 AS col0 FROM tab2 AS cor0
----
199
3391
871

query I rowsort
SELECT ALL - 60 AS col1 FROM tab2 cor0
----
-60
-60
-60

query I rowsort
SELECT + + 7 + - col0 AS col2 FROM tab0 AS cor0
----
-17
-28
-82

query I rowsort
SELECT DISTINCT + 57 FROM tab2, tab1 cor0, tab1 AS cor1
----
57

skipif mysql # not compatible
query I rowsort
SELECT + col1 * + col1 + - CAST ( - 56 AS REAL ) FROM tab0 AS cor0
----
7452
8337
9465

query I rowsort
SELECT DISTINCT - - 14 + col2 + 69 * - cor0.col2 FROM tab0 AS cor0
----
-2230
-54
-5562

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col0 * - 37 col0 FROM tab1 cor0
----
-2311
-2864
-57

skipif mysql # not compatible
query I rowsort
SELECT + col0 + CAST ( ( + col0 ) AS REAL ) FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + + col2 + + 50 AS col1 FROM tab1 AS cor0
----
104
107
146

onlyif mysql # use DIV operator for integer division
query I rowsort label-9277
SELECT ALL col2 * - col1 + + col1 DIV col0 AS col2 FROM tab1 AS cor0
----
-1248
-1396
-570

skipif mysql # not compatible
query I rowsort label-9277
SELECT ALL col2 * - col1 + + col1 / col0 AS col2 FROM tab1 AS cor0
----
-1248
-1396
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * ( col0 ) col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col1 + col2 * + 82 FROM tab0 AS cor0
----
179
2792
6815

query I rowsort
SELECT ALL col1 + + 42 FROM tab0 AS cor0
----
128
133
139

query I rowsort
SELECT DISTINCT - col0 * - col0 - - 30 AS col1 FROM tab0 AS cor0
----
1255
606
7951

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT col2 * 31 AS col2 FROM tab2 AS cor0
----
1178
806
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9284
SELECT + cor0.col2 * CAST( col1 AS SIGNED ) FROM tab0 cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-9284
SELECT + cor0.col2 * CAST ( col1 AS INTEGER ) FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT col2 + - ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT tab1.col0 * 70 AS col1 FROM tab1
----
210
4480
5600

query I rowsort
SELECT - col0 * - 37 * + col2 AS col2 FROM tab0 AS cor0
----
1295
270026
29304

query I rowsort
SELECT ALL - 28 * 31 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 13fcae0b54faa16545e581b383f55529

query I rowsort
SELECT + 29 * + col2 FROM tab2 AS cor0
----
1102
754
783

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9290
SELECT + - CAST( + cor0.col1 AS SIGNED ) * col2 col1 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9290
SELECT + - CAST ( + cor0.col1 AS INTEGER ) * col2 col1 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9291
SELECT + col1 + - col0 DIV + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9291
SELECT + col1 + - col0 / + col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + ( col1 ) + 92 FROM tab1 AS cor0
----
102
105
118

onlyif mysql # use DIV operator for integer division
query I rowsort label-9293
SELECT ALL + cor0.col1 DIV - col2 + col1 * + 28 FROM tab1 AS cor0
----
280
364
728

skipif mysql # not compatible
query I rowsort label-9293
SELECT ALL + cor0.col1 / - col2 + col1 * + 28 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT + + col2 + + col0 * 14 AS col2 FROM tab2 AS cor0
----
1118
1144
125

query I rowsort
SELECT ALL + tab2.col1 * tab2.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to bc669a3cc969c7619ebcffb5400ba0ba

query I rowsort
SELECT + 42 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT ALL 50 + tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to f295a2607c134d3fa8a7b9b3519a6b22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col1 ) col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT + 38 + 56 AS col1 FROM tab1
----
94

query I rowsort
SELECT ALL + col0 * 75 + col1 FROM tab2
----
556
5909
5942

query I rowsort
SELECT cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT + cor0.col2 + - col1 * + 67 AS col1 FROM tab2 AS cor0
----
-1101
-2050
-3927

query I rowsort
SELECT DISTINCT - - 0 * - col1 - 56 AS col2 FROM tab2 AS cor0
----
-56

query I rowsort
SELECT + cor0.col1 * + col1 + - 47 AS col2 FROM tab1 cor0
----
122
53
629

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * - col0 col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - ( cor0.col0 ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT col1 * col0 + + ( col0 ) AS col1 FROM tab0 cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-9308
SELECT - 80 DIV - col0 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-9308
SELECT - 80 / - col0 FROM tab0
----
0
2
3

query I rowsort
SELECT col0 + + col1 * col2 * 64 FROM tab1
----
36544
79952
89859

onlyif mysql # use DIV operator for integer division
query I rowsort label-9310
SELECT ALL 9 * col2 DIV col0 + col2 * col1 FROM tab0
----
2850
7470
97

skipif mysql # not compatible
query I rowsort label-9310
SELECT ALL 9 * col2 / col0 + col2 * col1 FROM tab0
----
2850
7470
97

query I rowsort
SELECT DISTINCT + - col0 * col0 + - 26 + 11 FROM tab2 AS cor0
----
-6099
-6256
-64

query I rowsort
SELECT ALL col2 * - col2 + + col2 FROM tab2
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-9313
SELECT - col0 + col2 * cor0.col0 - cor0.col0 DIV + col0 FROM tab0 AS cor0
----
-1
7208
767

skipif mysql # not compatible
query I rowsort label-9313
SELECT - col0 + col2 * cor0.col0 - cor0.col0 / + col0 FROM tab0 AS cor0
----
-1
7208
767

query I rowsort
SELECT ALL + col0 * + 74 FROM tab1 cor0
----
222
4736
5920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9315
SELECT ALL + col1 + CAST( ( col1 ) AS SIGNED ) FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-9315
SELECT ALL + col1 + CAST ( ( col1 ) AS INTEGER ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + - cor0.col1 * col0 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-1178
-1632
-8083

onlyif mysql # use DIV operator for integer division
query I rowsort label-9317
SELECT - col1 DIV + CAST( - cor0.col0 AS SIGNED ) + + col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-9317
SELECT - col1 / + CAST ( - cor0.col0 AS INTEGER ) + + col2 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT - col1 * + 11 AS col0 FROM tab1 AS cor0
----
-110
-143
-286

query I rowsort
SELECT + 41 + col0 + + 44 * col0 FROM tab1
----
176
2921
3641

query I rowsort
SELECT DISTINCT 42 - + col1 AS col1 FROM tab0
----
-44
-49
-55

query I rowsort
SELECT ALL - 49 * tab0.col2 * col2 + + ( - col2 ) FROM tab0
----
-329558
-50
-53394

query I rowsort
SELECT DISTINCT - col2 * col1 + + ( col1 ) FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL + 13 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT + col0 + col1 * col2 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT - col2 FROM tab2 WHERE NOT NULL <> col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 col1 FROM tab2
----
14
156
158

query I rowsort
SELECT col1 FROM tab1 WHERE ( NULL ) NOT BETWEEN + col2 / - col0 AND col0
----

query I rowsort
SELECT DISTINCT col2 + tab2.col2 * + col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT ALL + col1 * + tab2.col1 * col1 + + col0 FROM tab2
----
205457
29798
4992

query I rowsort
SELECT col2 AS col1 FROM tab1 WHERE NULL < - col0 * col2 * col0
----

query I rowsort
SELECT - col0 + col2 * - col1 AS col0 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT ALL - col1 + + col2 * - tab1.col2 * col2 FROM tab1
----
-157490
-185203
-884749

query I rowsort
SELECT ALL col0 * tab2.col2 - col1 * + col2 * - col2 AS col0 FROM tab2
----
22788
27550
41912

onlyif mysql # use DIV operator for integer division
query I rowsort label-9334
SELECT ALL - tab1.col2 DIV + col1 + col2 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-9334
SELECT ALL - tab1.col2 / + col1 + col2 FROM tab1
----
52
52
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9335
SELECT + tab0.col2 DIV tab0.col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9335
SELECT + tab0.col2 / tab0.col1 AS col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col2 * col2 col1 FROM tab0
----
1113
36
6813

query I rowsort
SELECT DISTINCT tab1.col1 + - tab1.col2 * tab1.col1 * + col2 AS col2 FROM tab1
----
-119795
-32480
-75790

query I rowsort
SELECT DISTINCT col1 * + col2 + - col1 AS col2 FROM tab2
----
1475
629
806

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( tab2.col0 )
----

query I rowsort
SELECT ALL col0 * tab1.col1 + col0 AS col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT col1 * - col1 / col2 AS col2 FROM tab0 WHERE NOT NULL BETWEEN + col1 / + col1 AND - col0 * col0 + col0
----

query I rowsort
SELECT + col2 + - col1 * tab0.col2 * col0 AS col0 FROM tab0
----
-3394
-664036
-68079

query III rowsort
SELECT * FROM tab1 WHERE NOT col2 = col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT col0 AS col0 FROM tab0 WHERE NOT NULL <= col2
----

query I rowsort
SELECT ALL col1 * tab1.col0 * col2 + - col2 AS col2 FROM tab1
----
36423
4158
99744

query I rowsort
SELECT + - ( col0 ) + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + + 77 + col1 FROM tab1 AS cor0
----
103
87
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 col1 FROM tab2, tab2 cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT - col2 + 86 * col2 FROM tab2
----
2210
2295
3230

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9350
SELECT - CAST( + col1 AS SIGNED ) + + col0 * col2 FROM tab1
----
136
3638
7667

skipif mysql # not compatible
query I rowsort label-9350
SELECT - CAST ( + col1 AS INTEGER ) + + col0 * col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT 4 * col1 + + 16 FROM tab2
----
140
252
84

query I rowsort
SELECT ALL + col1 * col2 + - 14 FROM tab0 AS cor0
----
2824
7448
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9353
SELECT ALL + col2 DIV col1 + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9353
SELECT ALL + col2 / col1 + col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9354
SELECT DISTINCT + + col2 * - cor0.col1 + col1 DIV col2 AS col2 FROM tab0 AS cor0
----
-2836
-7461
0

skipif mysql # not compatible
query I rowsort label-9354
SELECT DISTINCT + + col2 * - cor0.col1 + col1 / col2 AS col2 FROM tab0 AS cor0
----
-2836
-7461
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9355
SELECT ALL + ( col0 ) / CAST( NULL AS SIGNED ) + + 1 - col2 * col2 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9355
SELECT ALL + ( col0 ) / CAST ( NULL AS INTEGER ) + + 1 - col2 * col2 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + + col1 * 73 FROM tab2 cor0
----
1224
2232
4248

query I rowsort
SELECT DISTINCT 22 + col0 * cor0.col0 * + col1 FROM tab2 AS cor0
----
106119
1541
358978

query I rowsort
SELECT DISTINCT - - 14 - - cor0.col0 AS col0 FROM tab2 AS cor0
----
21
92
93

query I rowsort
SELECT - - cor0.col1 * - col0 + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL 33 * + col1 FROM tab1 AS cor0
----
330
429
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-9361
SELECT DISTINCT - 75 DIV + col0 AS col0 FROM tab2 AS cor0
----
-10
0

skipif mysql # not compatible
query I rowsort label-9361
SELECT DISTINCT - 75 / + col0 AS col0 FROM tab2 AS cor0
----
-10
0

query I rowsort
SELECT ALL - col2 * cor0.col0 * col2 + col2 AS col1 FROM tab2 AS cor0
----
-114038
-5076
-52702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9363
SELECT ALL - - col1 + col2 * + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
194
2924
7553

skipif mysql # not compatible
query I rowsort label-9363
SELECT ALL - - col1 + col2 * + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + 88 * - col2 + + col1 * - 20 * col1 FROM tab0 AS cor0
----
-150824
-172836
-188268

query I rowsort
SELECT - col2 + - col1 * - col0 AS col0 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT col0 + col1 * + 5 FROM tab1
----
114
133
145

onlyif mysql # use DIV operator for integer division
query I rowsort label-9367
SELECT + col2 * - col1 + col0 DIV col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-569

skipif mysql # not compatible
query I rowsort label-9367
SELECT + col2 * - col1 + col0 / col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-569

query I rowsort
SELECT DISTINCT col0 * + 16 AS col2 FROM tab0 AS cor0
----
1424
384
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-9369
SELECT + col1 + 79 DIV - col0 FROM tab2 AS cor0
----
16
20
58

skipif mysql # not compatible
query I rowsort label-9369
SELECT + col1 + 79 / - col0 FROM tab2 AS cor0
----
16
20
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-9370
SELECT - col1 + col2 DIV cor0.col2 col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9370
SELECT - col1 + col2 / cor0.col2 col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + 6 * - cor0.col0 col1 FROM tab1 AS cor0
----
-327
-384
36

query I rowsort
SELECT col2 * 99 AS col0 FROM tab0 AS cor0
----
3267
8118
99

query I rowsort
SELECT + - col2 + - col2 * 37 FROM tab0 AS cor0
----
-1254
-3116
-38

query I rowsort
SELECT ALL ( + col0 ) - - cor0.col0 AS col2 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT DISTINCT 30 AS col0 FROM tab1 cor0
----
30

query I rowsort
SELECT DISTINCT + - ( 21 ) AS col1 FROM tab2 AS cor0
----
-21

query I rowsort
SELECT DISTINCT - - col1 + + col2 + col2 FROM tab2 AS cor0
----
111
85
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 30 * col0 - cor0.col2 col1 FROM tab0 AS cor0
----
1049
2588
687

query I rowsort
SELECT ALL + col1 + ( + col0 ) FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - col1 * - 42 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT ALL - - ( col0 ) * col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - col1 * col1 * - col0 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT 38 * + col0 + + col2 AS col0 FROM tab1 AS cor0
----
168
2489
3136

query I rowsort
SELECT ALL + - col1 * - cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - - col1 * + col1 * - col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT cor1.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL 57 * + col2 FROM tab0
----
1881
4674
57

query I rowsort
SELECT DISTINCT + - 40 * col2 + + cor0.col0 FROM tab2 AS cor0
----
-1073
-1441
-962

onlyif mysql # use DIV operator for integer division
query I rowsort label-9389
SELECT DISTINCT + col2 + 61 DIV - col0 FROM tab1
----
34
57
96

skipif mysql # not compatible
query I rowsort label-9389
SELECT DISTINCT + col2 + 61 / - col0 FROM tab1
----
34
57
96

query I rowsort
SELECT DISTINCT - tab0.col1 * - 52 + - 21 AS col1 FROM tab0
----
4451
4711
5023

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 53 col2 FROM tab0 AS cor0
----
139
144
150

query I rowsort
SELECT col0 * 47 AS col2 FROM tab0
----
1128
1645
4183

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9393
SELECT ALL CAST( NULL AS DECIMAL ) + 11 col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9393
SELECT ALL CAST ( NULL AS REAL ) + 11 col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 * cor0.col2 + - col1 - col1 * col0 FROM tab0 cor0
----
-14914
-3239
-3493

query I rowsort
SELECT DISTINCT + 88 * 59 FROM tab2 AS cor0
----
5192

query I rowsort
SELECT + col2 + col1 * + col2 * col2 FROM tab2 AS cor0
----
22626
24586
39910

query I rowsort
SELECT DISTINCT 22 + 14 AS col1 FROM tab2 AS cor0
----
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9398
SELECT ALL CAST( 29 AS SIGNED ) * col0 + - col0 AS col2 FROM tab1 AS cor0
----
1792
2240
84

skipif mysql # not compatible
query I rowsort label-9398
SELECT ALL CAST ( 29 AS INTEGER ) * col0 + - col0 AS col2 FROM tab1 AS cor0
----
1792
2240
84

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) + col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9400
SELECT + col0 DIV col2 col2 FROM tab1 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9400
SELECT + col0 / col2 col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT tab1.col2 - col1 * tab1.col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT - col1 * tab0.col2 AS col1 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 col2 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9404
SELECT - col2 * + col2 DIV - col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9404
SELECT - col2 * + col2 / - col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - col2 * - col1 * - col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT col1 * - col2 - - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - cor0.col1 * cor0.col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9408
SELECT DISTINCT - col1 * col2 DIV + col2 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9408
SELECT DISTINCT - col1 * col2 / + col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT col0 * - col0 + col1 * cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1322
-619805
-94230

query I rowsort
SELECT + tab1.col2 AS col0 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - col1 + + col2 * - col0 AS col0 FROM tab0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-9412
SELECT + col1 - col1 DIV col2 FROM tab0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-9412
SELECT + col1 - col1 / col2 FROM tab0
----
0
84
90

query I rowsort
SELECT + tab1.col1 - + col0 AS col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT + 15 * cor0.col1 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to e86c1144a1443e69e90e4492f722df0b

query I rowsort
SELECT + col1 * - ( col0 ) * + col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT ALL - - col1 * - 92 FROM tab1 AS cor0
----
-1196
-2392
-920

query I rowsort
SELECT ALL - col0 * 51 * col0 AS col2 FROM tab0 AS cor0
----
-29376
-403971
-62475

onlyif mysql # use DIV operator for integer division
query I rowsort label-9418
SELECT col0 + col0 DIV col2 AS col0 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-9418
SELECT col0 + col0 / col2 AS col0 FROM tab0 AS cor0
----
24
70
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9419
SELECT ALL + CAST( NULL AS DECIMAL ) * ( - col0 ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9419
SELECT ALL + CAST ( NULL AS REAL ) * ( - col0 ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 ) - cor0.col2 * - cor0.col2 * - col1 AS col1 FROM tab1 AS cor0
----
-119728
-32426
-75813

query I rowsort
SELECT 80 + 68 * col2 * ( - 54 ) FROM tab2 AS cor0
----
-139456
-95392
-99064

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9422
SELECT ALL + CAST( NULL AS SIGNED ) * 58 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9422
SELECT ALL + CAST ( NULL AS INTEGER ) * 58 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col2 * + col1 + - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT 52 * + col1 FROM tab1 AS cor0
----
1352
520
676

query I rowsort
SELECT - ( - 83 ) AS col0 FROM tab0 AS cor0
----
83
83
83

query I rowsort
SELECT ALL - - ( - ( - col1 ) ) + + col1 - cor0.col2 FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT + cor0.col0 - 57 FROM tab2 AS cor0
----
-50
21
22

query I rowsort
SELECT ALL cor0.col1 + col1 + col0 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT - 11 * - col0 AS col0 FROM tab0 AS cor0
----
264
385
979

query I rowsort
SELECT DISTINCT + - 50 - - col2 AS col0 FROM tab1 AS cor0
----
4
46
7

query I rowsort
SELECT ALL - 23 FROM tab1 cor0
----
-23
-23
-23

query I rowsort
SELECT + col1 * + col1 * + cor0.col1 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT ALL + + 36 + 41 FROM tab2 AS cor0
----
77
77
77

query I rowsort
SELECT ALL - 46 * + cor0.col1 FROM tab1 cor0
----
-1196
-460
-598

onlyif mysql # use DIV operator for integer division
query I rowsort label-9435
SELECT - 77 DIV cor0.col0 FROM tab0 cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-9435
SELECT - 77 / cor0.col0 FROM tab0 cor0
----
-2
-3
0

query I rowsort
SELECT - - 39 * - col2 FROM tab1 AS cor0
----
-2106
-2223
-3744

query I rowsort
SELECT - - 62 + + col0 + ( - 5 ) FROM tab2 AS cor0
----
135
136
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-9438
SELECT ALL - col0 DIV col1 + - 77 FROM tab0 AS cor0
----
-77
-77
-77

skipif mysql # not compatible
query I rowsort label-9438
SELECT ALL - col0 / col1 + - 77 FROM tab0 AS cor0
----
-77
-77
-77

query I rowsort
SELECT + cor0.col0 + col1 * col0 AS col0 FROM tab1 AS cor0
----
1120
704
81

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + 11 AS REAL ) FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT ALL - + 79 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT DISTINCT + ( tab1.col1 ) + 19 * - 39 * - col2 FROM tab1
----
40040
42247
71149

query I rowsort
SELECT + + 82 * + col1 + - col2 AS col0 FROM tab0 AS cor0
----
7019
7380
7953

query I rowsort
SELECT ALL 64 AS col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL - cor0.col1 + col1 * col0 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9446
SELECT DISTINCT - + col1 * - CAST( - col2 AS SIGNED ) + col0 * col1 FROM tab2 AS cor0
----
-620
3068
697

skipif mysql # not compatible
query I rowsort label-9446
SELECT DISTINCT - + col1 * - CAST ( - col2 AS INTEGER ) + col0 * col1 FROM tab2 AS cor0
----
-620
3068
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + cor0.col1 * cor0.col2 col2 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT ALL + + col0 * - ( col0 ) AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-9449
SELECT + col2 DIV - 36 col2 FROM tab1 cor0
----
-1
-1
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9449
SELECT + col2 / - 36 col2 FROM tab1 cor0
----
-1
-1
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-9450
SELECT DISTINCT - - col0 DIV col1 col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9450
SELECT DISTINCT - - col0 / col1 col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL col0 + + col1 * + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL tab1.col2 * col2 * col0 + - col1 FROM tab1
----
207926
737267
8722

query I rowsort
SELECT + 85 * col2 * tab0.col0 AS col0 FROM tab0
----
2975
620330
67320

query I rowsort
SELECT ALL 30 + + col2 AS col0 FROM tab2
----
56
57
68

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 13 + col1 col0 FROM tab0
----
104
110
99

query I rowsort
SELECT col0 - - 41 * + col0 AS col1 FROM tab0
----
1008
1470
3738

query I rowsort
SELECT DISTINCT - + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9459
SELECT ALL + col1 * CAST( - 22 AS SIGNED ) + col1 AS col0 FROM tab0 cor0
----
-1806
-1911
-2037

skipif mysql # not compatible
query I rowsort label-9459
SELECT ALL + col1 * CAST ( - 22 AS INTEGER ) + col1 AS col0 FROM tab0 cor0
----
-1806
-1911
-2037

query I rowsort
SELECT ALL col0 * ( + 27 ) + + col1 + - col0 * col1 AS col1 FROM tab1 cor0
----
1098
1133
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9461
SELECT - col1 + CAST( + 20 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-6
10
7

skipif mysql # not compatible
query I rowsort label-9461
SELECT - col1 + CAST ( + 20 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-6
10
7

query I rowsort
SELECT ALL - + col2 + - 22 FROM tab2 AS cor0
----
-48
-49
-60

query I rowsort
SELECT ALL 58 AS col0 FROM tab0, tab2 cor0 CROSS JOIN tab1, tab2 AS cor1
----
81 values hashing to 793ce5fda3f22b0a251dca7e8a07baed

query I rowsort
SELECT - - 32 AS col2 FROM tab1, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 6bef041528d0147be26f7de162c66a5f

onlyif mysql # use DIV operator for integer division
query I rowsort label-9465
SELECT + 91 DIV + 18 FROM tab1
----
5
5
5

skipif mysql # not compatible
query I rowsort label-9465
SELECT + 91 / + 18 FROM tab1
----
5
5
5

query I rowsort
SELECT - 65 - - ( col0 * - 60 + col1 ) AS col2 FROM tab0 AS cor0
----
-1419
-2068
-5314

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9467
SELECT DISTINCT CAST( + col0 AS SIGNED ) - + tab0.col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-9467
SELECT DISTINCT CAST ( + col0 AS INTEGER ) - + tab0.col0 FROM tab0
----
0

query I rowsort
SELECT DISTINCT - col0 * col0 + - col0 AS col2 FROM tab1 cor0
----
-12
-4160
-6480

query I rowsort
SELECT ALL ( col1 ) + - col2 * + 94 AS col0 FROM tab2
----
-2385
-2507
-3555

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col2 ) + cor0.col1 * - 22 col1 FROM tab1 AS cor0
----
-163
-190
-518

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9471
SELECT ALL + col2 + + col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9471
SELECT ALL + col2 + + col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - col2 + + 5 AS col1 FROM tab2 cor0
----
-47
-49
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-9473
SELECT DISTINCT cor0.col0 + - col1 DIV col0 FROM tab2 AS cor0
----
3
78
79

skipif mysql # not compatible
query I rowsort label-9473
SELECT DISTINCT cor0.col0 + - col1 / col0 FROM tab2 AS cor0
----
3
78
79

query I rowsort
SELECT - + 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 + + ( col2 ) * + col2 * - col2 - cor0.col1 col1 FROM tab1 AS cor0
----
-157490
-185203
-884749

query I rowsort
SELECT - + ( col0 ) + cor0.col2 + + cor0.col2 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT ALL - ( - col2 ) * - col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 + + ( col2 ) * col2 col0 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9479
SELECT ALL + ( col1 ) DIV - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9479
SELECT ALL + ( col1 ) / - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 30 * + col0 FROM tab0 AS cor0
----
-1050
-2670
-720

query I rowsort
SELECT ALL tab2.col0 * 71 * col2 AS col2 FROM tab2
----
13419
143988
213142

query I rowsort
SELECT + col1 * 36 * cor0.col2 + cor0.col2 FROM tab0 AS cor0
----
102201
268714
3493

onlyif mysql # use DIV operator for integer division
query I rowsort label-9483
SELECT + - ( col2 ) DIV + cor0.col0 + col2 * - col0 FROM tab1 cor0
----
-180
-3648
-7681

skipif mysql # not compatible
query I rowsort label-9483
SELECT + - ( col2 ) / + cor0.col0 + col2 * - col0 FROM tab1 cor0
----
-180
-3648
-7681

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9484
SELECT - CAST( + 61 AS SIGNED ) * - col2 AS col2 FROM tab0 AS cor0
----
2013
5002
61

skipif mysql # not compatible
query I rowsort label-9484
SELECT - CAST ( + 61 AS INTEGER ) * - col2 AS col2 FROM tab0 AS cor0
----
2013
5002
61

query I rowsort
SELECT + ( 71 ) + col2 * col2 FROM tab0 AS cor0
----
1160
6795
72

query I rowsort
SELECT ALL - cor0.col0 * col2 + col1 * col0 AS col2 FROM tab0 AS cor0
----
1272
3360
801

query I rowsort
SELECT - ( col0 ) + col0 * col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT - 19 + col2 FROM tab0 AS cor0
----
-18
14
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9489
SELECT - CAST( col2 AS SIGNED ) + cor0.col0 + col0 FROM tab1 AS cor0
----
-48
64
71

skipif mysql # not compatible
query I rowsort label-9489
SELECT - CAST ( col2 AS INTEGER ) + cor0.col0 + col0 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT DISTINCT ( 88 ) * - col1 FROM tab0
----
-7568
-8008
-8536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9491
SELECT - - col2 * + CAST( NULL AS SIGNED ) + - 40 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9491
SELECT - - col2 * + CAST ( NULL AS INTEGER ) + - 40 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9492
SELECT + - col2 * + CAST( NULL AS SIGNED ) + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9492
SELECT + - col2 * + CAST ( NULL AS INTEGER ) + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 + ( - col0 ) FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT - + col0 + + 2 AS col0 FROM tab2 cor0
----
-5
-76
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9495
SELECT - + col0 - + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9495
SELECT - + col0 - + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 37 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT ALL col1 + - 64 FROM tab2
----
-33
-47
-5

query I rowsort
SELECT ALL + col0 + tab0.col2 + col1 FROM tab0
----
133
143
262

query I rowsort
SELECT DISTINCT - tab0.col1 + - 7 + 68 FROM tab0
----
-25
-30
-36

query I rowsort
SELECT ALL col1 + col2 * - 40 * - col2 FROM tab0
----
137
269051
43646

query I rowsort
SELECT + col2 + tab0.col0 * + col0 AS col1 FROM tab0
----
1226
609
8003

query I rowsort
SELECT - col1 + ( + 80 ) AS col1 FROM tab2 cor0
----
21
49
63

query I rowsort
SELECT DISTINCT col0 + + ( - col1 ) + + col1 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + 19 ) col0 FROM tab0, tab1 AS cor0
----
19

query I rowsort
SELECT + - col2 * - col0 + col1 * + col1 * - col0 FROM tab2 AS cor0
----
-19829
-269490
-6538

query I rowsort
SELECT DISTINCT tab1.col1 + + col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT - col0 - - col2 * + col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT col0 * - 80 * col0 AS col1 FROM tab0
----
-46080
-633680
-98000

query I rowsort
SELECT ( tab1.col2 ) * + 60 FROM tab1, tab1 AS cor0
----
9 values hashing to 6ee85309e05757a775ead99d5fd0ef50

query I rowsort
SELECT + col0 + + 99 FROM tab1 AS cor0
----
102
163
179

query I rowsort
SELECT + - 73 * col2 + - col0 AS col2 FROM tab0 AS cor0
----
-108
-2433
-6075

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 + cor1.col0 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d022aee3e165a85ae0b196a859d1dc98

query I rowsort
SELECT - 25 AS col1 FROM tab1
----
-25
-25
-25

query I rowsort
SELECT ALL - - ( - cor0.col2 ) AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL 38 * tab0.col0 AS col1 FROM tab0
----
1330
3382
912

query I rowsort
SELECT - + 70 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to c2a2994a4e94583683ccda2cc098c58f

query I rowsort
SELECT - col2 * - ( 97 ) + col1 AS col1 FROM tab1 AS cor0
----
5264
5539
9325

query I rowsort
SELECT DISTINCT + col1 - - ( 52 ) * + col1 * cor0.col0 FROM tab2 cor0
----
11315
239363
69853

query I rowsort
SELECT - - cor0.col2 + col1 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col0 * - 55 AS col2 FROM tab1 AS cor0
----
-165
-3520
-4400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9521
SELECT DISTINCT + + 2 * - col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9521
SELECT DISTINCT + + 2 * - col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col2 + - col2 * tab1.col1 FROM tab1
----
-1152
-1350
-513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9523
SELECT CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9523
SELECT CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( - col1 ) * col2 * - ( - ( + col2 ) ) + 57 FROM tab2
----
-22542
-24491
-39827

query I rowsort
SELECT 23 + + col0 FROM tab0
----
112
47
58

query I rowsort
SELECT DISTINCT + + cor0.col2 * - cor0.col0 * col2 AS col1 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT ALL 53 + col0 * col1 AS col1 FROM tab0 AS cor0
----
2117
3448
8152

query I rowsort
SELECT ALL + + cor0.col1 - + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 79 * col1 FROM tab0 AS cor0
----
6794
7189
7663

query I rowsort
SELECT ALL - cor0.col0 + - col1 AS col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + col2 - ( col1 ) AS col0 FROM tab2
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 77 * col0 col1 FROM tab0
----
1934
2792
6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT + col0 * - 87 FROM tab2
----
-609
-6786
-6873

onlyif mysql # use DIV operator for integer division
query I rowsort label-9535
SELECT DISTINCT tab1.col0 - + 12 DIV 44 AS col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9535
SELECT DISTINCT tab1.col0 - + 12 / 44 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT col2 + - 58 AS col0 FROM tab2 AS cor0
----
-20
-31
-32

query I rowsort
SELECT DISTINCT col2 + + 33 * col1 AS col2 FROM tab1
----
387
525
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-9538
SELECT + col2 + col0 * col1 DIV col0 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-9538
SELECT + col2 + col0 * col1 / col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9539
SELECT + CAST( + 30 AS SIGNED ) FROM tab2 cor0
----
30
30
30

skipif mysql # not compatible
query I rowsort label-9539
SELECT + CAST ( + 30 AS INTEGER ) FROM tab2 cor0
----
30
30
30

query I rowsort
SELECT ALL - - 96 + col0 FROM tab1 AS cor0
----
160
176
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9541
SELECT DISTINCT - col1 + col2 DIV + col1 FROM tab2 AS cor0
----
-15
-31
-59

skipif mysql # not compatible
query I rowsort label-9541
SELECT DISTINCT - col1 + col2 / + col1 FROM tab2 AS cor0
----
-15
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9542
SELECT col2 + + 27 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9542
SELECT col2 + + 27 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT col1 - + 40 AS col1 FROM tab0 cor0
----
46
51
57

query I rowsort
SELECT - col1 * - ( - col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col0 * col0 * col0 FROM tab0 cor0
----
13824
42875
704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-9546
SELECT DISTINCT - - col2 * col1 - col0 DIV - col1 AS col0 FROM tab2 AS cor0
----
1535
650
837

skipif mysql # not compatible
query I rowsort label-9546
SELECT DISTINCT - - col2 * col1 - col0 / - col1 AS col0 FROM tab2 AS cor0
----
1535
650
837

query I rowsort
SELECT + col2 * cor0.col1 + - col1 AS col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-9548
SELECT ALL + 52 + + col0 DIV col1 AS col2 FROM tab0 AS cor0
----
52
52
52

skipif mysql # not compatible
query I rowsort label-9548
SELECT ALL + 52 + + col0 / col1 AS col2 FROM tab0 AS cor0
----
52
52
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 + col1 * - 70 col1 FROM tab0 AS cor0
----
-14291
-6596
-8015

query I rowsort
SELECT ( + 55 ) AS col0 FROM tab2 cor0
----
55
55
55

query I rowsort
SELECT ALL - 56 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

query I rowsort
SELECT DISTINCT + 99 * 53 AS col0 FROM tab2 AS cor0
----
5247

query I rowsort
SELECT - ( cor0.col2 ) * col0 + ( col1 ) AS col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + col1 * + 23 + - col2 * + col1 FROM tab0
----
-5369
-860
2134

query I rowsort
SELECT + + ( + 94 ) + col1 AS col1 FROM tab2 AS cor0
----
111
125
153

query I rowsort
SELECT DISTINCT 71 AS col1 FROM tab0 cor0
----
71

query I rowsort
SELECT ( col0 ) * + col0 + cor0.col2 AS col0 FROM tab1 cor0
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col0 + col1 col0 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT ALL - col1 * - col2 * col2 AS col1 FROM tab1 AS cor0
----
119808
32490
75816

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab1 cor1, tab1 cor2
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query I rowsort
SELECT + 12 + + col2 * + cor0.col1 FROM tab1 AS cor0
----
1260
1416
582

query I rowsort
SELECT - - col2 + col1 * 94 * col1 FROM tab2 cor0
----
27204
327240
90361

query I rowsort
SELECT - 63 * - cor0.col1 FROM tab2 AS cor0
----
1071
1953
3717

query I rowsort
SELECT DISTINCT - 20 + - col2 * - col0 * ( col0 * col0 ) FROM tab2 AS cor0
----
12338332
18735462
9241

query I rowsort
SELECT col0 * + col2 + col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT col2 * cor0.col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL + + col0 - + col0 * ( col2 + col2 ) FROM tab2 AS cor0
----
-371
-3978
-5925

query I rowsort
SELECT col0 * - col0 + tab2.col0 * + tab2.col2 * col0 AS col0 FROM tab2
----
1274
152100
230917

query I rowsort
SELECT - 28 + - 83 AS col2 FROM tab0
----
-111
-111
-111

query I rowsort
SELECT ALL - col0 * ( - col2 ) + + col1 AS col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT - col2 + col0 * 29 FROM tab1 AS cor0
----
1799
2224
33

query I rowsort
SELECT ALL - cor0.col1 * - 69 AS col1 FROM tab1 cor0
----
1794
690
897

query I rowsort
SELECT ALL + - col0 * cor0.col0 + 7 AS col1 FROM tab0 cor0
----
-1218
-569
-7914

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9574
SELECT ALL col0 + CAST( col0 AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

skipif mysql # not compatible
query I rowsort label-9574
SELECT ALL col0 + CAST ( col0 AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + col0 + col1 * + col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL + col1 * col1 * 33 FROM tab0 AS cor0
----
244068
273273
310497

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9577
SELECT DISTINCT - cor0.col1 + - CAST( NULL AS DECIMAL ) + - col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9577
SELECT DISTINCT - cor0.col1 + - CAST ( NULL AS REAL ) + - col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 + - 49 FROM tab0 AS cor0
----
-2113
-3444
-8148

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9579
SELECT DISTINCT - + cor0.col0 * - CAST( NULL AS DECIMAL ) * col0 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9579
SELECT DISTINCT - + cor0.col0 * - CAST ( NULL AS REAL ) * col0 AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9580
SELECT ALL - col1 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9580
SELECT ALL - col1 / cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 + 91 FROM tab1 AS cor0
----
145
148
187

query I rowsort
SELECT ALL col2 + + 22 AS col2 FROM tab2
----
48
49
60

query I rowsort
SELECT col1 + tab0.col0 + - 71 FROM tab0
----
109
39
61

query I rowsort
SELECT DISTINCT col0 * - col0 * - ( tab0.col0 ) + col2 AS col1 FROM tab0
----
13857
42876
705051

query I rowsort
SELECT ALL + 40 + - col0 AS col2 FROM tab0
----
-49
16
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9586
SELECT ALL + cor0.col2 DIV 75 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-9586
SELECT ALL + cor0.col2 / 75 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

query I rowsort
SELECT ALL + + col0 * + col2 * - col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + col0 * ( - col0 ) AS col2 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT - - col0 * + col1 + col0 AS col0 FROM tab1 AS cor0
----
1120
704
81

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab0, tab1 cor1
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

query I rowsort
SELECT - - col2 + col0 AS col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT + col1 * - 59 + - col1 FROM tab0 AS cor0
----
-5160
-5460
-5820

query I rowsort
SELECT ALL ( - 80 ) FROM tab2 AS cor0
----
-80
-80
-80

query I rowsort
SELECT ALL ( + col2 * - col0 ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + + ( col2 ) + col2 * cor0.col0 * - col1 FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT col0 + col1 * - col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT - 94 AS col0 FROM tab0 cor0
----
-94

query I rowsort
SELECT DISTINCT - - 38 + - col0 * + col1 AS col1 FROM tab1 AS cor0
----
-1002
-40
-602

query I rowsort
SELECT + ( + col0 ) * col0 AS col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT + ( + col0 ) + + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL - 16 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 6a726f8493b62c5d4e1dd657007160c3

query I rowsort
SELECT - + col2 + + col1 + - cor0.col0 FROM tab1 AS cor0
----
-111
-163
-31

query I rowsort
SELECT DISTINCT - + 95 + - col0 AS col1 FROM tab2 cor0
----
-102
-173
-174

query I rowsort
SELECT + cor0.col1 + col2 + col1 AS col0 FROM tab1 AS cor0
----
106
122
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * + col1 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + 94 * + col1 AS col1 FROM tab2 cor0
----
1598
2914
5546

query I rowsort
SELECT col1 + col1 * ( + col0 ) FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-9608
SELECT + 87 + + cor0.col1 DIV + 75 AS col1 FROM tab2 cor0
----
87
87
87

skipif mysql # not compatible
query I rowsort label-9608
SELECT + 87 + + cor0.col1 / + 75 AS col1 FROM tab2 cor0
----
87
87
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-9609
SELECT DISTINCT - + col2 + 49 DIV + col0 - col1 AS col0 FROM tab1 AS cor0
----
-109
-64
-67

skipif mysql # not compatible
query I rowsort label-9609
SELECT DISTINCT - + col2 + 49 / + col0 - col1 AS col0 FROM tab1 AS cor0
----
-109
-64
-67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9610
SELECT + col0 * + CAST( 9 AS SIGNED ) - - col2 AS col0 FROM tab1 AS cor0
----
633
81
816

skipif mysql # not compatible
query I rowsort label-9610
SELECT + col0 * + CAST ( 9 AS INTEGER ) - - col2 AS col0 FROM tab1 AS cor0
----
633
81
816

query I rowsort
SELECT ALL + - cor0.col1 * 27 FROM tab2 cor0
----
-1593
-459
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-9612
SELECT col1 DIV + col0 + 12 + col2 AS col1 FROM tab1 cor0
----
108
69
74

skipif mysql # not compatible
query I rowsort label-9612
SELECT col1 / + col0 + 12 + col2 AS col1 FROM tab1 cor0
----
108
69
74

query I rowsort
SELECT + col0 + 39 - col0 FROM tab2 AS cor0
----
39
39
39

query I rowsort
SELECT ALL - 59 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

query I rowsort
SELECT ALL cor0.col0 + - 1 FROM tab1 cor0
----
2
63
79

query I rowsort
SELECT - + 0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 7 * - 84 + col0 col0 FROM tab1 cor0
----
-508
-524
-585

query I rowsort
SELECT - col2 + + 99 AS col0 FROM tab1 AS cor0
----
3
42
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-9619
SELECT + + col2 * cor0.col1 DIV + col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9619
SELECT + + col2 * cor0.col1 / + col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 16 + 57 FROM tab1, tab1 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT 14 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-9622
SELECT DISTINCT col1 DIV 85 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-9622
SELECT DISTINCT col1 / 85 FROM tab0
----
1

query I rowsort
SELECT + 31 + 38 AS col2 FROM tab1 AS cor0
----
69
69
69

query I rowsort
SELECT ALL - ( ( col0 ) ) AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + col1 + - 84 + 31 FROM tab1 AS cor0
----
-27
-40
-43

query I rowsort
SELECT - + col2 * 75 * - ( + cor0.col0 ) + col0 * col1 + col1 FROM tab0 AS cor0
----
555540
6117
61550

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 + 46 * col0 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-460
3484
4551

query I rowsort
SELECT ALL - cor0.col1 + + ( col2 ) * - col0 AS col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT col0 * - 27 + + ( + col1 ) * + 72 AS col0 FROM tab2 AS cor0
----
-909
2043
2142

onlyif mysql # use DIV operator for integer division
query I rowsort label-9630
SELECT + col2 DIV + 33 + + 78 FROM tab0 AS cor0
----
78
79
80

skipif mysql # not compatible
query I rowsort label-9630
SELECT + col2 / + 33 + + 78 FROM tab0 AS cor0
----
78
79
80

query I rowsort
SELECT DISTINCT + + cor0.col1 + col0 * + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL col0 + + 58 FROM tab2
----
136
137
65

query I rowsort
SELECT DISTINCT + col2 + col0 * + col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL col1 + + 68 AS col2 FROM tab1
----
78
81
94

query I rowsort
SELECT DISTINCT col1 * col0 + + col2 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col0 - 3 AS col0 FROM tab1
----
0
61
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9637
SELECT ALL - CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9637
SELECT ALL - CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col1 + cor0.col1 * 98 AS col2 FROM tab0 AS cor0
----
8514
9009
9603

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 0 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 * col1 - + col0 col1 FROM tab0 AS cor0
----
2556
2641
2875

query I rowsort
SELECT DISTINCT + + 40 * col0 FROM tab2 AS cor0
----
280
3120
3160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9642
SELECT DISTINCT + CAST( + 30 AS SIGNED ) AS col0 FROM tab2, tab0, tab0 AS cor0
----
30

skipif mysql # not compatible
query I rowsort label-9642
SELECT DISTINCT + CAST ( + 30 AS INTEGER ) AS col0 FROM tab2, tab0, tab0 AS cor0
----
30

query I rowsort
SELECT - col2 * col0 * tab2.col2 - + ( col0 ) FROM tab2
----
-114155
-5110
-52806

query I rowsort
SELECT + col2 * - col1 - - tab2.col0 FROM tab2
----
-1456
-567
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9645
SELECT - CAST( - col1 AS SIGNED ) AS col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9645
SELECT - CAST ( - col1 AS INTEGER ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT 87 * - 15 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-1305

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9647
SELECT ALL col0 + + col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9647
SELECT ALL col0 + + col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 38 * col0 + ( cor0.col2 ) AS col0 FROM tab2 AS cor0
----
293
2990
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-9649
SELECT DISTINCT col1 - - col1 DIV - col0 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-9649
SELECT DISTINCT col1 - - col1 / - col0 FROM tab2 AS cor0
----
17
27
59

query I rowsort
SELECT ALL - + col1 + col2 * col0 AS col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - + 26 + cor0.col1 * ( + ( col2 ) ) FROM tab2 cor0
----
1508
620
811

onlyif mysql # use DIV operator for integer division
query I rowsort label-9652
SELECT DISTINCT + 11 DIV + cor0.col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-9652
SELECT DISTINCT + 11 / + cor0.col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + + col0 + col0 AS col2 FROM tab0 cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 75 + + col1 col0 FROM tab1
----
101
85
88

query I rowsort
SELECT tab1.col2 * col2 + + col2 + col2 AS col0 FROM tab1
----
3024
3363
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-9656
SELECT + 45 DIV + col0 + col2 * + col2 FROM tab2
----
1444
676
735

skipif mysql # not compatible
query I rowsort label-9656
SELECT + 45 / + col0 + col2 * + col2 FROM tab2
----
1444
676
735

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9657
SELECT ALL CAST( NULL AS SIGNED ) + + ( - cor1.col2 ) AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9657
SELECT ALL CAST ( NULL AS INTEGER ) + + ( - cor1.col2 ) AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col2 ) * 56 - 99 col1 FROM tab2
----
1357
1413
2029

query I rowsort
SELECT DISTINCT - tab0.col1 - tab0.col2 FROM tab0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9660
SELECT + col1 * col1 DIV 31 AS col2 FROM tab1
----
21
3
5

skipif mysql # not compatible
query I rowsort label-9660
SELECT + col1 * col1 / 31 AS col2 FROM tab1
----
21
3
5

query I rowsort
SELECT col1 * col0 + 47 FROM tab2
----
1390
264
4649

query I rowsort
SELECT + + 95 * - col0 FROM tab2 AS cor0
----
-665
-7410
-7505

query I rowsort
SELECT DISTINCT - - col0 + col0 * - ( ( + cor0.col1 ) ) AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + + 26 * + col2 AS col2 FROM tab2 AS cor0
----
676
702
988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9665
SELECT DISTINCT - col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9665
SELECT DISTINCT - col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - cor0.col2 + - 58 AS col1 FROM tab2 AS cor0
----
-20
-31
-32

query I rowsort
SELECT ALL - col2 + - 17 AS col2 FROM tab0 AS cor0
----
-18
-50
-99

query I rowsort
SELECT DISTINCT + col1 + col1 * + col0 - + col0 AS col0 FROM tab1 cor0
----
101
586
973

query I rowsort
SELECT + col0 * 20 - col1 * - col1 FROM tab0 AS cor0
----
10061
10109
7876

query I rowsort
SELECT + cor0.col0 + col1 * - 79 AS col1 FROM tab1 AS cor0
----
-2051
-726
-947

query I rowsort
SELECT ALL + col2 * - col2 + + col2 + col1 AS col2 FROM tab2 AS cor0
----
-1389
-591
-671

query I rowsort
SELECT - + col1 + 24 FROM tab2 AS cor0
----
-35
-7
7

query I rowsort
SELECT + + cor0.col0 - + ( col2 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + col0 + 75 AS col1 FROM tab0 AS cor0
----
110
164
99

query I rowsort
SELECT + col1 + + ( col1 ) FROM tab2 cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9676
SELECT col0 DIV col1 - - 75 FROM tab1 AS cor0
----
75
81
81

skipif mysql # not compatible
query I rowsort label-9676
SELECT col0 / col1 - - 75 FROM tab1 AS cor0
----
75
81
81

query I rowsort
SELECT + col0 + tab2.col1 + - 3 AS col2 FROM tab2
----
134
35
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9678
SELECT DISTINCT + - col2 * - CAST( + col0 AS SIGNED ) + - cor0.col2 FROM tab1 cor0
----
108
3591
7584

skipif mysql # not compatible
query I rowsort label-9678
SELECT DISTINCT + - col2 * - CAST ( + col0 AS INTEGER ) + - cor0.col2 FROM tab1 cor0
----
108
3591
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-9679
SELECT DISTINCT + col0 DIV ( + 15 * col1 ) + + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-9679
SELECT DISTINCT + col0 / ( + 15 * col1 ) + + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + - 49 * col1 FROM tab1 AS cor0
----
-1274
-490
-637

query I rowsort
SELECT + - 48 * col2 AS col0 FROM tab1 AS cor0
----
-2592
-2736
-4608

query I rowsort
SELECT ALL - + col0 * 48 FROM tab0 AS cor0
----
-1152
-1680
-4272

query I rowsort
SELECT ALL - - col2 + + ( col2 ) * + ( - col1 ) * col2 AS col2 FROM tab1 cor0
----
-119712
-32433
-75762

query I rowsort
SELECT DISTINCT ( 1 ) AS col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT + 98 - - cor0.col0 FROM tab2, tab0 cor0, tab1, tab1 cor1
----
81 values hashing to efaf470cdcefa38f247e62f7979ed361

query I rowsort
SELECT + - 44 * 52 FROM tab2 AS cor0
----
-2288
-2288
-2288

onlyif mysql # use DIV operator for integer division
query I rowsort label-9687
SELECT ALL col0 + col0 + - col2 DIV + col1 FROM tab1 AS cor0
----
123
153
4

skipif mysql # not compatible
query I rowsort label-9687
SELECT ALL col0 + col0 + - col2 / + col1 FROM tab1 AS cor0
----
123
153
4

query I rowsort
SELECT DISTINCT + - 18 * col2 + - col0 FROM tab1 AS cor0
----
-1090
-1808
-975

onlyif mysql # use DIV operator for integer division
query I rowsort label-9689
SELECT DISTINCT - + cor0.col0 * col1 + col0 DIV 50 + col2 DIV - col1 FROM tab1 AS cor0
----
-1046
-644
-80

skipif mysql # not compatible
query I rowsort label-9689
SELECT DISTINCT - + cor0.col0 * col1 + col0 / 50 + col2 / - col1 FROM tab1 AS cor0
----
-1046
-644
-80

query I rowsort
SELECT DISTINCT 26 * col0 FROM tab1 AS cor0
----
1664
2080
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9691
SELECT ALL - + CAST( 9 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-9
-9
-9

skipif mysql # not compatible
query I rowsort label-9691
SELECT ALL - + CAST ( 9 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-9
-9
-9

query I rowsort
SELECT ALL + col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - - col0 + + 8 + + col0 AS col2 FROM tab0 cor0
----
186
56
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9694
SELECT - ( + col2 ) * - CAST( col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-9694
SELECT - ( + col2 ) * - CAST ( col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + 31 * + col2 FROM tab0
----
1023
2542
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9696
SELECT CAST( NULL AS SIGNED ) * - 66 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9696
SELECT CAST ( NULL AS INTEGER ) * - 66 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 31 * 88 AS col2 FROM tab1 cor0
----
2728
2728
2728

query I rowsort
SELECT col0 * - col2 + - ( - col0 ) * 19 AS col0 FROM tab1
----
-105
-2432
-6160

query I rowsort
SELECT col2 + col0 * 16 FROM tab0
----
1506
417
561

query I rowsort
SELECT DISTINCT 15 FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
15

query I rowsort
SELECT - 77 * - col1 - - col0 FROM tab2 AS cor0
----
1388
2394
4621

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - 48 ) col2 FROM tab0 AS cor0
----
-48
-48
-48

query I rowsort
SELECT DISTINCT + - cor0.col2 + + 16 FROM tab0 cor0
----
-17
-66
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9704
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * col0 * cor0.col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9704
SELECT DISTINCT - CAST ( NULL AS REAL ) * col0 * cor0.col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col0 - + col1 AS col0 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT 90 - + col1 FROM tab0 AS cor0
----
-1
-7
4

query I rowsort
SELECT DISTINCT col2 + col2 * + cor0.col1 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9708
SELECT DISTINCT col1 * col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9708
SELECT DISTINCT col1 * col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT 28 * col0 + col1 FROM tab0
----
1077
2583
758

query I rowsort
SELECT DISTINCT + 59 AS col2 FROM tab1 AS cor0
----
59

query I rowsort
SELECT ALL + col0 + cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + 78 * tab2.col0 * - col0 AS col0 FROM tab2
----
-3822
-474552
-486798

query I rowsort
SELECT 78 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT 53 * col2 FROM tab0 AS cor0
----
1749
4346
53

query I rowsort
SELECT DISTINCT - + col1 + - col1 * col0 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL + col2 * col1 * + col0 AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col1 * col0 * ( + col1 ) + col0 FROM tab1
----
13600
2031
6464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 92 ) col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT + col2 * col2 * col1 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT col2 + + col0 * + col1 * col2 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT cor0.col1 * - 1 + 18 + - col2 * - col1 FROM tab1 AS cor0
----
1253
1396
578

query I rowsort
SELECT cor0.col0 * + 44 AS col0 FROM tab2 AS cor0
----
308
3432
3476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT DISTINCT + - col2 * - 69 + + col0 FROM tab1 AS cor0
----
3729
3997
6704

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 71 ) * - col0 col1 FROM tab2 AS cor0
----
-497
-5538
-5609

query I rowsort
SELECT - ( - col1 ) * col1 FROM tab2 cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL col0 * - ( - col1 + col2 ) FROM tab2
----
-1659
2574
28

query I rowsort
SELECT - 64 * + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-448
-4992
-5056

query I rowsort
SELECT ALL + col2 * + ( col1 * ( - col2 ) ) AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9731
SELECT ( + col0 ) + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9731
SELECT ( + col0 ) + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - cor0.col0 + 88 AS col0 FROM tab0 cor0
----
-1976
-3307
-8011

onlyif mysql # use DIV operator for integer division
query I rowsort label-9733
SELECT 23 DIV 80 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9733
SELECT 23 / 80 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9734
SELECT DISTINCT CAST( + col2 AS SIGNED ) * col0 + + col1 * + col0 FROM tab0
----
15397
2856
3430

skipif mysql # not compatible
query I rowsort label-9734
SELECT DISTINCT CAST ( + col2 AS INTEGER ) * col0 + + col1 * + col0 FROM tab0
----
15397
2856
3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 * + col0 * - col0 col2 FROM tab1 AS cor0
----
-208
-40950
-83187

query I rowsort
SELECT - 60 + col2 FROM tab2 cor0
----
-22
-33
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9737
SELECT + col2 * CAST( NULL AS SIGNED ) / col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9737
SELECT + col2 * CAST ( NULL AS INTEGER ) / col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + ( col1 ) * + cor0.col0 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT cor0.col1 + - 50 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 5ec5769ab18dc1b59e43d5dbfc1b106f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 29 col2 FROM tab0
----
29

query I rowsort
SELECT 28 + - tab2.col1 FROM tab2
----
-3
-31
11

query I rowsort
SELECT + 13 + - col0 * col1 FROM tab0 AS cor0
----
-2051
-3382
-8086

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9743
SELECT - 29 + + col1 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9743
SELECT - 29 + + col1 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 96 * col0 FROM tab1 AS cor0
----
288
6144
7680

query I rowsort
SELECT + + 46 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
72
73
84

query I rowsort
SELECT - - 45 - col0 * 29 FROM tab2 AS cor0
----
-158
-2217
-2246

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 96 col1 FROM tab0 cor0
----
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col2 col1 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT 4 * col1 AS col2 FROM tab2 AS cor0
----
124
236
68

query I rowsort
SELECT ALL - - col2 * col1 + + 22 * - col1 FROM tab2 AS cor0
----
155
236
272

onlyif mysql # use DIV operator for integer division
query I rowsort label-9751
SELECT DISTINCT + col2 + 26 * ( - cor0.col1 * + col1 ) - - ( col1 ) DIV col1 FROM tab0 cor0
----
-192262
-215223
-244632

skipif mysql # not compatible
query I rowsort label-9751
SELECT DISTINCT + col2 + 26 * ( - cor0.col1 * + col1 ) - - ( col1 ) / col1 FROM tab0 cor0
----
-192262
-215223
-244632

query I rowsort
SELECT + col2 - + ( + col0 + col2 * + col2 ) AS col1 FROM tab0 AS cor0
----
-1080
-35
-6731

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9753
SELECT + col1 * - ( col0 ) + col0 / CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9753
SELECT + col1 * - ( col0 ) + col0 / CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 + ( - ( - col0 ) * - 31 ) AS col0 FROM tab0 AS cor0
----
-1084
-2677
-711

query I rowsort
SELECT ALL - ( + col2 * col1 ) - tab2.col2 AS col2 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT + - 43 AS col2 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

onlyif mysql # use DIV operator for integer division
query I rowsort label-9757
SELECT ALL + col0 DIV + ( 87 ) - col1 * ( - 75 ) * + col2 AS col1 FROM tab0 AS cor0
----
212850
559651
7275

skipif mysql # not compatible
query I rowsort label-9757
SELECT ALL + col0 / + ( 87 ) - col1 * ( - 75 ) * + col2 AS col1 FROM tab0 AS cor0
----
212850
559651
7275

query I rowsort
SELECT col0 * col2 + + col1 * col1 FROM tab1 cor0
----
3748
7849
838

query I rowsort
SELECT DISTINCT - - col1 + + 16 FROM tab0 AS cor0
----
102
107
113

query I rowsort
SELECT ALL cor0.col2 * cor0.col1 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to b2e5b025b1c725661248b0f29aaef908

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 7 - + 7 col0 FROM tab1, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - 0 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - + col0 * - col0 + - cor0.col1 FROM tab2 cor0
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-9764
SELECT DISTINCT - - cor0.col0 DIV + 27 AS col0 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-9764
SELECT DISTINCT - - cor0.col0 / + 27 AS col0 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT + - 21 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT DISTINCT + 73 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1241
-2263
-4307

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 15 col1 FROM tab2
----
-15
-15
-15

query I rowsort
SELECT DISTINCT 99 * col0 FROM tab2
----
693
7722
7821

query I rowsort
SELECT + 93 * + col1 + 63 AS col2 FROM tab0 AS cor0
----
8061
8526
9084

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9770
SELECT + - CAST( + 80 AS SIGNED ) + tab2.col0 AS col1 FROM tab2, tab0, tab0 cor0
----
27 values hashing to aa956d0fcc660c9147c8b85f2f723d65

skipif mysql # not compatible
query I rowsort label-9770
SELECT + - CAST ( + 80 AS INTEGER ) + tab2.col0 AS col1 FROM tab2, tab0, tab0 cor0
----
27 values hashing to aa956d0fcc660c9147c8b85f2f723d65

query I rowsort
SELECT DISTINCT tab0.col0 AS col0 FROM tab0, tab0 cor0
----
24
35
89

query I rowsort
SELECT - 95 * + tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 55f04e0ce0dee30d2f57216e372567a9

query I rowsort
SELECT - ( col2 ) * - col0 + col2 FROM tab1
----
216
3705
7776

query I rowsort
SELECT - 25 AS col2 FROM tab1
----
-25
-25
-25

query I rowsort
SELECT ( + col1 ) * - col1 * tab1.col2 + 74 FROM tab1
----
-16150
-36430
-5626

query I rowsort
SELECT DISTINCT 73 * + col0 + col2 AS col2 FROM tab1 AS cor0
----
273
4729
5936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9777
SELECT DISTINCT + CAST( NULL AS DECIMAL ) AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9777
SELECT DISTINCT + CAST ( NULL AS REAL ) AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT ALL - + col0 * cor0.col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT col2 + + 64 FROM tab1
----
118
121
160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9780
SELECT ALL + col1 * CAST( NULL AS SIGNED ) + 15 / - col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9780
SELECT ALL + col1 * CAST ( NULL AS INTEGER ) + 15 / - col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + + 79 AS col2 FROM tab1
----
53
66
69

query I rowsort
SELECT ALL - 6 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

query I rowsort
SELECT DISTINCT ( col0 ) * col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT col1 * + col1 + + cor0.col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL + 20 + ( + col2 ) * + 45 FROM tab0 cor0
----
1505
3710
65

query I rowsort
SELECT DISTINCT + - col1 * 81 + + col0 AS col0 FROM tab0 AS cor0
----
-6942
-7282
-7822

query I rowsort
SELECT col2 * 9 FROM tab1 AS cor0
----
486
513
864

query I rowsort
SELECT DISTINCT + col1 * 1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL + col1 + + col1 * col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-9790
SELECT DISTINCT ( col1 ) DIV + col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9790
SELECT DISTINCT ( col1 ) / + col1 FROM tab0 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 * col0 col2 FROM tab1 AS cor0
----
-177
-3776
-4720

query I rowsort
SELECT DISTINCT + - col2 * col2 + - col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT ALL 82 * col2 AS col0 FROM tab1 AS cor0
----
4428
4674
7872

query I rowsort
SELECT DISTINCT - - 69 * + col1 * - col2 + col2 FROM tab0 AS cor0
----
-195789
-514796
-6692

query I rowsort
SELECT DISTINCT + 42 + + 94 * - col1 FROM tab2 AS cor0
----
-1556
-2872
-5504

query I rowsort
SELECT ALL - 42 + + col0 AS col2 FROM tab0 AS cor0
----
-18
-7
47

query I rowsort
SELECT ALL ( col2 ) - + col1 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - ( col0 ) + + col1 * ( - col0 * - col2 ) FROM tab1 AS cor0
----
36416
4209
99760

query I rowsort
SELECT 79 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9800
SELECT ALL CAST( NULL AS SIGNED ) + - 1 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9800
SELECT ALL CAST ( NULL AS INTEGER ) + - 1 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL ( 15 ) FROM tab2, tab0 cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT ALL + col0 + 93 FROM tab0 AS cor0
----
117
128
182

query I rowsort
SELECT - cor0.col1 + cor0.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 92ef426526338653e88acd4aba639c47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col1 FROM tab0 cor0
----
-98
-98
-98

query I rowsort
SELECT + 97 * - col2 FROM tab0 AS cor0
----
-3201
-7954
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9806
SELECT ALL + col2 DIV CAST( - col1 + - col1 AS SIGNED ) FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-9806
SELECT ALL + col2 / CAST ( - col1 + - col1 AS INTEGER ) FROM tab1
----
-1
-2
-3

query I rowsort
SELECT + + 97 * - col1 FROM tab1 cor0
----
-1261
-2522
-970

query I rowsort
SELECT + - col0 * col2 * ( + col2 ) FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT 37 * - col1 + ( col0 ) AS col2 FROM tab1 cor0
----
-306
-401
-959

query I rowsort
SELECT col1 + - col0 * + 61 FROM tab2 AS cor0
----
-396
-4699
-4802

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9811
SELECT DISTINCT + CAST( col2 AS SIGNED ) + col0 * col2 * col1 FROM tab0
----
3396
664200
68145

skipif mysql # not compatible
query I rowsort label-9811
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + col0 * col2 * col1 FROM tab0
----
3396
664200
68145

query I rowsort
SELECT - 99 * col1 FROM tab1 cor0
----
-1287
-2574
-990

query I rowsort
SELECT ALL col1 + - col2 * - col2 * tab2.col2 FROM tab2
----
17635
19714
54889

onlyif mysql # use DIV operator for integer division
query I rowsort label-9814
SELECT 36 DIV 48 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9814
SELECT 36 / 48 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * - col2 + col2 + col2 AS col0 FROM tab1
----
-2808
-3135
-9024

onlyif mysql # use DIV operator for integer division
query I rowsort label-9816
SELECT - col0 + + col2 DIV CAST( - 64 AS SIGNED ) + + col1 col1 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9816
SELECT - col0 + + col2 / CAST ( - 64 AS INTEGER ) + + col1 col1 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9817
SELECT ALL - - col1 * + col1 DIV CAST( - col1 AS SIGNED ) + col1 * cor0.col0 FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-9817
SELECT ALL - - col1 * + col1 / CAST ( - col1 AS INTEGER ) + col1 * cor0.col0 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-9818
SELECT col0 + ( col1 ) DIV - col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-9818
SELECT col0 + ( col1 ) / - col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT DISTINCT col2 + col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + ( - col2 ) * + col0 col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT col1 + + tab1.col2 - col1 FROM tab1
----
54
57
96

query I rowsort
SELECT - 87 * + col2 * ( - tab0.col1 * tab0.col2 ) FROM tab0
----
53233908
8147898
8439

query I rowsort
SELECT + col1 * + 51 * col2 + - col1 * - col0 FROM tab1
----
29710
64688
71682

onlyif mysql # use DIV operator for integer division
query I rowsort label-9824
SELECT - col2 + - col1 DIV col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-9824
SELECT - col2 + - col1 / col2 FROM tab1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9825
SELECT + CAST( NULL AS SIGNED ) * - tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9825
SELECT + CAST ( NULL AS INTEGER ) * - tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col1 * - col0 + + col2 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT - - col0 + + ( - col2 ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - col0 + - col1 * + cor0.col1 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT + - col0 * 42 FROM tab2 AS cor0
----
-294
-3276
-3318

query I rowsort
SELECT DISTINCT - + cor1.col1 + cor1.col2 + 88 AS col0 FROM tab1, tab0 AS cor0, tab2, tab0 AS cor1
----
-8
35
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9831
SELECT + CAST( - col1 AS SIGNED ) * + cor0.col1 FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-9831
SELECT + CAST ( - col1 AS INTEGER ) * + cor0.col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col1 * col0 * col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT + 50 + - col2 AS col1 FROM tab1 AS cor0
----
-4
-46
-7

query I rowsort
SELECT - 90 + cor0.col2 FROM tab1 cor0
----
-33
-36
6

query I rowsort
SELECT cor1.col1 AS col1 FROM tab1, tab0 cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 87 - - col1 AS col1 FROM tab2 AS cor0
----
-28
-56
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9837
SELECT ALL - - col0 - - col1 DIV - col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-9837
SELECT ALL - - col0 - - col1 / - col0 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT 27 + - cor0.col0 * 49 AS col0 FROM tab0 AS cor0
----
-1149
-1688
-4334

query I rowsort
SELECT + col0 + col1 * + 0 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col2 + 43 * - col2 AS col0 FROM tab0 AS cor0
----
-1452
-3608
-44

query I rowsort
SELECT DISTINCT + col0 * 41 FROM tab2 cor0
----
287
3198
3239

query I rowsort
SELECT ALL col0 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - col2 * - col0 + + col1 FROM tab0 cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + col1 ) col2 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9845
SELECT CAST( NULL AS SIGNED ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9845
SELECT CAST ( NULL AS INTEGER ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9846
SELECT CAST( + col0 AS SIGNED ) + col0 * - 9 AS col0 FROM tab1 AS cor0
----
-24
-512
-640

skipif mysql # not compatible
query I rowsort label-9846
SELECT CAST ( + col0 AS INTEGER ) + col0 * - 9 AS col0 FROM tab1 AS cor0
----
-24
-512
-640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col1 + col1 * col1 col1 FROM tab0 AS cor0
----
14792
16562
18818

query I rowsort
SELECT DISTINCT - 38 * 27 AS col1 FROM tab1 AS cor0
----
-1026

query I rowsort
SELECT ALL + 41 + - 10 FROM tab0 AS cor0
----
31
31
31

query I rowsort
SELECT ALL + col1 + + cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + tab0.col1 col1 FROM tab0
----
172
182
194

query I rowsort
SELECT + 50 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT 15 - tab0.col0 AS col0 FROM tab0
----
-20
-74
-9

query I rowsort
SELECT + col1 + + col2 * - col1 AS col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL - + col2 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9856
SELECT + col2 + cor0.col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-9856
SELECT + col2 + cor0.col0 / + col2 AS col1 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT DISTINCT col0 * - col2 + - cor0.col0 * col0 * 3 FROM tab2 AS cor0
----
-20280
-21725
-336

query I rowsort
SELECT ALL - + col0 * ( 11 ) AS col1 FROM tab2 AS cor0
----
-77
-858
-869

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9859
SELECT col2 * CAST( col1 * - col2 AS SIGNED ) FROM tab0 cor0
----
-611884
-93654
-97

skipif mysql # not compatible
query I rowsort label-9859
SELECT col2 * CAST ( col1 * - col2 AS INTEGER ) FROM tab0 cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL - col2 * + col1 * 98 FROM tab2 cor0
----
-150332
-63308
-82026

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + - 99 - - col1 col0 FROM tab0 AS cor0
----
-3
-46
-90

query I rowsort
SELECT - ( + col1 ) - - col2 AS col0 FROM tab1
----
28
47
83

query I rowsort
SELECT - 38 * + col1 * - tab2.col0 AS col0 FROM tab2
----
174876
51034
8246

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 68 col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
68

query I rowsort
SELECT DISTINCT - col1 * + 6 FROM tab1 AS cor0
----
-156
-60
-78

query I rowsort
SELECT ALL + + col1 + + ( + col1 ) AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL - col0 * + ( + 70 ) FROM tab1 AS cor0
----
-210
-4480
-5600

query I rowsort
SELECT DISTINCT col1 * 20 + + col1 * cor0.col0 FROM tab1 AS cor0
----
1300
598
840

query I rowsort
SELECT ALL - col1 + ( + 53 ) + col2 FROM tab1 AS cor0
----
100
136
81

query I rowsort
SELECT ALL + col1 * - 78 FROM tab2 AS cor0
----
-1326
-2418
-4602

query I rowsort
SELECT - + cor0.col1 + - col2 + - cor0.col0 * + col0 AS col1 FROM tab1 AS cor0
----
-4163
-6509
-89

query I rowsort
SELECT ALL col2 * col1 + - col0 * 87 FROM tab1
----
-4998
-5712
1143

query I rowsort
SELECT + col0 + + col0 * cor0.col2 * col0 FROM tab1 cor0
----
233536
489
614480

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + col1 + ( + cor0.col1 ) * col2 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - 68 FROM tab2, tab2 cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query I rowsort
SELECT DISTINCT ( col2 ) * - col0 * + col1 + + col2 * col0 * ( - col2 ) AS col0 FROM tab1 AS cor0
----
-12960
-244416
-837120

query I rowsort
SELECT - ( cor0.col2 ) + ( ( + col2 ) ) + col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - 21 * 62 + col2 * col1 FROM tab1
----
-54
-732
102

query I rowsort
SELECT DISTINCT + 29 * - col1 * - col0 + col0 FROM tab0 AS cor0
----
234960
59880
98490

query I rowsort
SELECT ALL - col0 * cor0.col1 + + 32 FROM tab1 AS cor0
----
-1008
-46
-608

query I rowsort
SELECT + - cor0.col0 - col2 * col1 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-9883
SELECT DISTINCT - ( ( col0 ) ) DIV 89 + col0 * col0 FROM tab0
----
1225
576
7920

skipif mysql # not compatible
query I rowsort label-9883
SELECT DISTINCT - ( ( col0 ) ) / 89 + col0 * col0 FROM tab0
----
1225
576
7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-9884
SELECT ( + col2 ) DIV col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-9884
SELECT ( + col2 ) / col0 FROM tab1
----
0
1
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9885
SELECT - CAST( + col2 AS SIGNED ) + col2 + - ( + col0 + - col2 * - col1 ) AS col2 FROM tab0
----
-132
-2862
-7551

skipif mysql # not compatible
query I rowsort label-9885
SELECT - CAST ( + col2 AS INTEGER ) + col2 + - ( + col0 + - col2 * - col1 ) AS col2 FROM tab0
----
-132
-2862
-7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9886
SELECT DISTINCT + CAST( NULL AS DECIMAL ) + - col1 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9886
SELECT DISTINCT + CAST ( NULL AS REAL ) + - col1 AS col1 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT - tab0.col1 AS col1 FROM tab0, tab1, tab2 AS cor0, tab2
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + 84 AS col1 FROM tab2, tab0, tab1 AS cor0
----
84

query I rowsort
SELECT DISTINCT - cor0.col0 + + col0 * + 38 FROM tab1 AS cor0
----
111
2368
2960

query I rowsort
SELECT DISTINCT - col1 * col1 + - ( - col1 ) * - col1 AS col0 FROM tab1 AS cor0
----
-1352
-200
-338

query I rowsort
SELECT ALL + ( - cor0.col0 ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col0 * - col1 * + ( 90 ) AS col0 FROM tab1 AS cor0
----
57600
7020
93600

onlyif mysql # use DIV operator for integer division
query I rowsort label-9893
SELECT ALL - + cor0.col2 * - col2 * - col1 + col1 DIV col0 FROM tab0 cor0
----
-611883
-93651
-95

skipif mysql # not compatible
query I rowsort label-9893
SELECT ALL - + cor0.col2 * - col2 * - col1 + col1 / col0 FROM tab0 cor0
----
-611883
-93651
-95

query I rowsort
SELECT ( - col2 ) * + 48 + + col0 FROM tab1 AS cor0
----
-2589
-2672
-4528

query I rowsort
SELECT DISTINCT - ( col2 ) * col2 * + ( cor0.col0 * + 14 ) + - col2 AS col2 FROM tab2 cor0
----
-1597102
-71469
-738218

query I rowsort
SELECT DISTINCT tab1.col1 AS col1 FROM tab1, tab0, tab2 cor0
----
10
13
26

query I rowsort
SELECT ( - col0 + + col2 ) * 67 FROM tab0
----
-2278
-469
603

query I rowsort
SELECT - ( col0 ) * col1 AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT 95 * + 10 AS col1 FROM tab2
----
950
950
950

query I rowsort
SELECT DISTINCT + ( - col0 ) * - col2 FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-9901
SELECT DISTINCT + - col2 DIV + cor0.col1 + + col0 DIV col0 AS col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9901
SELECT DISTINCT + - col2 / + cor0.col1 + + col0 / col0 AS col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT 91 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to 8a48d0ac75792561e233f0311a8872fd

query I rowsort
SELECT - cor1.col0 * + 96 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 40e642a199c2f71c3e5b8f29b0dbb78f

query I rowsort
SELECT + col0 * + col1 + + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - + 8 + - col1 * col1 AS col0 FROM tab0 cor0
----
-7404
-8289
-9417

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + tab1.col1 col2 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + cor0.col2 ) col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - - 23 + col0 * 85 FROM tab0 AS cor0
----
2063
2998
7588

onlyif mysql # use DIV operator for integer division
query I rowsort label-9910
SELECT col1 * + col0 - + col2 DIV - cor0.col1 FROM tab2 AS cor0
----
1345
217
4602

skipif mysql # not compatible
query I rowsort label-9910
SELECT col1 * + col0 - + col2 / - cor0.col1 FROM tab2 AS cor0
----
1345
217
4602

query I rowsort
SELECT ALL + - col1 + + 34 AS col1 FROM tab0 AS cor0
----
-52
-57
-63

query I rowsort
SELECT + col2 - ( - col1 ) AS col0 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + 84 col0 FROM tab2 AS cor0
----
1428
2604
4956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9914
SELECT + col2 * + CAST( NULL AS SIGNED ) + + col1 - col2 * - CAST( - col0 * col1 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-9914
SELECT + col2 * + CAST ( NULL AS INTEGER ) + + col1 - col2 * - CAST ( - col0 * col1 AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9915
SELECT - cor0.col2 DIV + 85 AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9915
SELECT - cor0.col2 / + 85 AS col0 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col0 * col0 - col0 * col1 AS col2 FROM tab2 AS cor0
----
-168
1482
4898

query I rowsort
SELECT col2 * 29 + + col1 FROM tab1 cor0
----
1592
1663
2797

query I rowsort
SELECT + 74 + - col0 FROM tab0
----
-15
39
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-9919
SELECT col0 DIV col1 + + col2 * + col0 AS col1 FROM tab1 cor0
----
162
3654
7686

skipif mysql # not compatible
query I rowsort label-9919
SELECT col0 / col1 + + col2 * + col0 AS col1 FROM tab1 cor0
----
162
3654
7686

query I rowsort
SELECT - col2 + + 12 - + cor0.col1 FROM tab0 AS cor0
----
-107
-161
-86

query I rowsort
SELECT + col0 + col2 - ( col1 ) * + ( - col1 ) * col1 AS col0 FROM tab0 AS cor0
----
636113
753742
912709

onlyif mysql # use DIV operator for integer division
query I rowsort label-9922
SELECT - col0 DIV - ( + col2 * + tab1.col0 ) + col1 * ( - col0 + - col2 ) FROM tab1
----
-1210
-1482
-2288

skipif mysql # not compatible
query I rowsort label-9922
SELECT - col0 / - ( + col2 * + tab1.col0 ) + col1 * ( - col0 + - col2 ) FROM tab1
----
-1210
-1482
-2288

query I rowsort
SELECT - col2 + col0 * + col0 AS col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT col2 * + 76 FROM tab0
----
2508
6232
76

query I rowsort
SELECT col2 * + ( + col1 ) + col1 AS col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT DISTINCT col1 * - 4 * - col0 + col0 * col0 FROM tab0
----
14805
40317
8832

query I rowsort
SELECT + col2 + 93 * col1 + + col0 FROM tab2 AS cor0
----
1698
2917
5591

query I rowsort
SELECT + col2 * + 67 + + col1 AS col0 FROM tab1 AS cor0
----
3644
3829
6445

onlyif mysql # use DIV operator for integer division
query I rowsort label-9929
SELECT + col2 * - col1 + col1 * 49 - col1 DIV col2 AS col0 FROM tab0 AS cor0
----
-3004
1374
4559

skipif mysql # not compatible
query I rowsort label-9929
SELECT + col2 * - col1 + col1 * 49 - col1 / col2 AS col0 FROM tab0 AS cor0
----
-3004
1374
4559

onlyif mysql # use DIV operator for integer division
query I rowsort label-9930
SELECT ALL - 67 DIV + col0 + + col0 FROM tab1 AS cor0
----
-19
63
80

skipif mysql # not compatible
query I rowsort label-9930
SELECT ALL - 67 / + col0 + + col0 FROM tab1 AS cor0
----
-19
63
80

query I rowsort
SELECT DISTINCT ( col1 ) * cor0.col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + - ( - 60 ) * - col1 + col0 FROM tab2 AS cor0
----
-1853
-3462
-941

query I rowsort
SELECT ( - 5 ) * col2 FROM tab1 AS cor0
----
-270
-285
-480

query I rowsort
SELECT col1 * + 46 - col2 FROM tab2 AS cor0
----
1399
2688
744

query I rowsort
SELECT + col2 * - tab1.col0 AS col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9936
SELECT CAST( 63 AS SIGNED ) FROM tab2, tab1 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

skipif mysql # not compatible
query I rowsort label-9936
SELECT CAST ( 63 AS INTEGER ) FROM tab2, tab1 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT DISTINCT - col1 + ( col2 ) * + 43 AS col1 FROM tab2 AS cor0
----
1059
1130
1617

query I rowsort
SELECT ALL - ( col1 ) * col1 + cor0.col1 FROM tab0 cor0
----
-7310
-8190
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-9939
SELECT col0 DIV - 63 AS col1 FROM tab1
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9939
SELECT col0 / - 63 AS col1 FROM tab1
----
-1
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9940
SELECT col0 DIV - col2 AS col0 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9940
SELECT col0 / - col2 AS col0 FROM tab1 cor0
----
-1
0
0

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1, tab0 cor1
----
3645 values hashing to 2566f3fa788816c8bfc482e730aaed74

query I rowsort
SELECT ALL - ( + col0 * - 66 + - ( - col1 ) ) FROM tab0
----
1498
2213
5783

query I rowsort
SELECT 4 * col1 + + col2 AS col1 FROM tab1 AS cor0
----
148
158
97

query I rowsort
SELECT col2 + 87 AS col1 FROM tab0
----
120
169
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-9945
SELECT col1 DIV 37 + - col1 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9945
SELECT col1 / 37 + - col1 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9946
SELECT - + cor0.col1 DIV - col2 AS col0 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-9946
SELECT - + cor0.col1 / - col2 AS col0 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL + ( - col0 ) + col1 * col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL 55 * + col0 + - 78 FROM tab2 AS cor0
----
307
4212
4267

query I rowsort
SELECT + cor0.col2 * cor0.col1 + col1 * col0 + col0 AS col1 FROM tab2 AS cor0
----
1061
2068
6214

query I rowsort
SELECT ALL + - col2 + + col0 * - ( col0 ) AS col2 FROM tab2 AS cor0
----
-6110
-6279
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-9952
SELECT - col2 DIV col1 + - CAST( ( + col1 ) AS SIGNED ) FROM tab1 AS cor0
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-9952
SELECT - col2 / col1 + - CAST ( ( + col1 ) AS INTEGER ) FROM tab1 AS cor0
----
-15
-20
-28

query I rowsort
SELECT DISTINCT - + col1 * - col0 + + cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT DISTINCT - col1 + - cor0.col2 * - ( col0 * - col0 ) AS col2 FROM tab0 AS cor0
----
-1322
-19094
-649613

query I rowsort
SELECT ALL + + 81 * + col2 * col0 AS col1 FROM tab1 cor0
----
13122
295488
622080

query I rowsort
SELECT DISTINCT - ( col0 ) * cor0.col0 + - 20 AS col0 FROM tab2 AS cor0
----
-6104
-6261
-69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9957
SELECT - CAST( NULL AS DECIMAL ) - - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9957
SELECT - CAST ( NULL AS REAL ) - - col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9958
SELECT ALL + CAST( - col0 AS SIGNED ) + tab2.col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9958
SELECT ALL + CAST ( - col0 AS INTEGER ) + tab2.col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col2 * + 91 FROM tab0
----
-3003
-7462
-91

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col2 * col0 AS REAL ) AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT col2 * col2 - - col2 * + col0 FROM tab2
----
2704
4446
918

query I rowsort
SELECT - ( - col2 ) + col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT ( + col0 ) + - col1 * ( 80 ) + col0 FROM tab1
----
-2074
-672
-880

query I rowsort
SELECT 52 * + col2 FROM tab0
----
1716
4264
52

query I rowsort
SELECT 80 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT DISTINCT - col1 * + col0 * col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT - + 17 * + cor0.col2 AS col0 FROM tab0 cor0
----
-1394
-17
-561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 64 col1 FROM tab0 AS cor0
----
-64
-64
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-9969
SELECT + - col2 + col1 DIV - 45 FROM tab2 AS cor0
----
-27
-27
-38

skipif mysql # not compatible
query I rowsort label-9969
SELECT + - col2 + col1 / - 45 FROM tab2 AS cor0
----
-27
-27
-38

query I rowsort
SELECT - col1 + col0 + col2 FROM tab0 cor0
----
-29
-61
80

query I rowsort
SELECT DISTINCT - 99 FROM tab1 cor0
----
-99

query I rowsort
SELECT cor1.col2 + 79 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2224b5dae363b805d66c0776c0e82627

query I rowsort
SELECT ALL + col0 - col2 * - 88 * + tab1.col2 AS col1 FROM tab1
----
256611
285976
811088

query I rowsort
SELECT - 30 + cor0.col1 FROM tab0 AS cor0
----
56
61
67

query I rowsort
SELECT DISTINCT + col0 + - col0 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - - 30 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT + col2 * + col1 * - col1 AS col0 FROM tab1
----
-16224
-36504
-5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + ( + 32 ) col1 FROM tab1
----
19
22
6

query I rowsort
SELECT cor0.col0 + ( 26 ) AS col1 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 28131d6e1689a174e12a97f01c75d81a

query I rowsort
SELECT DISTINCT + 23 * + 28 AS col0 FROM tab2 AS cor0
----
644

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9981
SELECT - CAST( NULL AS SIGNED ) * 23 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9981
SELECT - CAST ( NULL AS INTEGER ) * 23 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL tab2.col0 + 16 * - col1 FROM tab2
----
-193
-489
-866

query I rowsort
SELECT 60 + col0 FROM tab0
----
149
84
95

query I rowsort
SELECT DISTINCT + 25 + + 3 + cor0.col2 AS col1 FROM tab2 AS cor0
----
54
55
66

query I rowsort
SELECT ALL ( 90 ) * col1 * + col1 + - 91 FROM tab0 AS cor0
----
665549
745199
846719

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 ) + col0 col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - - 93 + cor0.col0 * col2 AS col2 FROM tab1 AS cor0
----
255
3741
7773

onlyif mysql # use DIV operator for integer division
query I rowsort label-9988
SELECT ALL - cor0.col2 DIV col2 + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-9988
SELECT ALL - cor0.col2 / col2 + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9989
SELECT DISTINCT cor0.col0 + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9989
SELECT DISTINCT cor0.col0 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT + col2 + ( - col2 * - col2 + + 16 ) FROM tab0
----
1138
18
6822

query I rowsort
SELECT ALL + + ( col1 ) * col1 * col1 + col1 - col0 FROM tab2 cor0
----
205360
29815
4851

query I rowsort
SELECT DISTINCT cor0.col1 * ( col0 ) + 24 AS col1 FROM tab1 AS cor0
----
102
1064
664

query I rowsort
SELECT - col2 - + col2 * - cor0.col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT + - cor0.col2 * 62 AS col1 FROM tab2 AS cor0
----
-1612
-1674
-2356

query I rowsort
SELECT DISTINCT + tab1.col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT col2 + 1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT - col0 * 87 AS col1 FROM tab2
----
-609
-6786
-6873

