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)

onlyif mysql # use DIV operator for integer division
query I rowsort label-0
SELECT ALL - CAST( - 72 AS SIGNED ) DIV - col2 FROM tab0 cor0
----
-2
-72
0

skipif mysql # not compatible
query I rowsort label-0
SELECT ALL - CAST ( - 72 AS INTEGER ) / - col2 FROM tab0 cor0
----
-2
-72
0

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

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

query I rowsort
SELECT DISTINCT col2 + 29 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT + col0 * + col2 + - cor0.col2 + - 32 FROM tab2 AS cor0
----
130
1970
2932

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

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

skipif mysql # not compatible
query I rowsort label-6
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 67 AS col1 FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - 99 + + col0 + + col0 AS col0 FROM tab0
----
-29
-51
79

query I rowsort
SELECT + 69 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9
SELECT ALL tab0.col1 DIV col0 + + col0 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9
SELECT ALL tab0.col1 / col0 + + col0 FROM tab0
----
27
37
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 95 * 90 + col1 + col0 * 4 col2 FROM tab2
----
-8179
-8217
-8491

query I rowsort
SELECT ALL - col0 + - 59 + col2 FROM tab2 AS cor0
----
-100
-111
-39

query I rowsort
SELECT cor0.col0 + col1 * + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-231
-40896
-83120

query I rowsort
SELECT - 34 AS col0 FROM tab0
----
-34
-34
-34

query I rowsort
SELECT DISTINCT col1 * - 47 + col0 * col1 * col1 FROM tab0
----
173462
324756
732732

query I rowsort
SELECT tab2.col1 + 84 AS col0 FROM tab2
----
101
115
143

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-17
SELECT col0 - col0 * ( - col1 ) DIV col1 FROM tab2
----
14
156
158

skipif mysql # not compatible
query I rowsort label-17
SELECT col0 - col0 * ( - col1 ) / col1 FROM tab2
----
14
156
158

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

query I rowsort
SELECT ALL 70 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to c07fb58c935d7dd3a559c80465f90463

query I rowsort
SELECT col1 * - col0 - 60 * col1 FROM tab1
----
-1240
-1638
-1820

onlyif mysql # use DIV operator for integer division
query I rowsort label-21
SELECT ALL - tab1.col1 * ( + col2 ) + - col1 DIV 49 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-21
SELECT ALL - tab1.col1 * ( + col2 ) + - col1 / 49 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT col2 + col0 * - 33 * - col1 AS col2 FROM tab0
----
112036
267349
68145

query I rowsort
SELECT col2 * - 28 - - 6 AS col2 FROM tab2 AS cor0
----
-1058
-722
-750

query I rowsort
SELECT col0 * - 21 AS col1 FROM tab2
----
-147
-1638
-1659

query I rowsort
SELECT DISTINCT - - cor0.col1 * cor0.col0 - ( + col0 ) * ( + 17 ) FROM tab2 AS cor0
----
0
3276
98

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

query I rowsort
SELECT + col0 + 8 AS col2 FROM tab2 AS cor0
----
15
86
87

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-29
SELECT DISTINCT cor0.col1 DIV + ( col0 ) AS col2 FROM tab1 cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-29
SELECT DISTINCT cor0.col1 / + ( col0 ) AS col2 FROM tab1 cor0
----
0
8

query I rowsort
SELECT DISTINCT col2 + ( + 66 ) * col2 FROM tab1 AS cor0
----
3618
3819
6432

query I rowsort
SELECT DISTINCT col2 + 81 AS col2 FROM tab1 AS cor0
----
135
138
177

query I rowsort
SELECT + col2 * - 22 + + 72 FROM tab0 AS cor0
----
-1732
-654
50

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

query I rowsort
SELECT ALL - col1 - + 29 * + col2 AS col0 FROM tab0 AS cor0
----
-1043
-126
-2469

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

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

query I rowsort
SELECT col1 * 45 AS col0 FROM tab0 AS cor0
----
3870
4095
4365

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

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

skipif mysql # not compatible
query I rowsort label-38
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - 32 / col1 - col1 AS col1 FROM tab1 AS cor0
----
NULL

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

query I rowsort
SELECT DISTINCT ( + col1 ) * + cor0.col0 - - col1 * col0 AS col1 FROM tab0 AS cor0
----
16198
4128
6790

query I rowsort
SELECT DISTINCT + - 24 * + 91 AS col2 FROM tab2 AS cor0
----
-2184

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

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

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

query I rowsort
SELECT ALL col1 + 62 FROM tab2 cor0
----
121
79
93

query I rowsort
SELECT + ( + col0 ) * - cor0.col2 + 86 FROM tab1 AS cor0
----
-3562
-7594
-76

query I rowsort
SELECT + col2 + 5 FROM tab1 AS cor0
----
101
59
62

query I rowsort
SELECT + 99 - + col1 FROM tab1 AS cor0
----
73
86
89

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

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

query I rowsort
SELECT DISTINCT col1 * + col1 FROM tab0 cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 96 col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT + 55 * col1 FROM tab0
----
4730
5005
5335

query I rowsort
SELECT + 84 * + col1 FROM tab0 AS cor0
----
7224
7644
8148

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

query I rowsort
SELECT DISTINCT - - col2 * - col1 * col1 + col2 FROM tab0 AS cor0
----
-244035
-678960
-9408

query I rowsort
SELECT DISTINCT col0 + col2 + + cor0.col0 * + col0 FROM tab2 AS cor0
----
6188
6358
83

query I rowsort
SELECT - col2 * col2 + + 54 FROM tab0 AS cor0
----
-1035
-6670
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-58
SELECT ALL + + col0 * + col0 + col1 DIV - col2 + col2 FROM tab0 AS cor0
----
1129
607
8002

skipif mysql # not compatible
query I rowsort label-58
SELECT ALL + + col0 * + col0 + col1 / - col2 + col2 FROM tab0 AS cor0
----
1129
607
8002

query I rowsort
SELECT ALL + + ( col0 ) + col2 * col1 + - col2 FROM tab2 cor0
----
1586
687
817

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( + col1 ) * - col0 col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

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

query I rowsort
SELECT DISTINCT - ( 61 ) FROM tab0, tab0 AS cor0
----
-61

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

skipif mysql # not compatible
query I rowsort label-65
SELECT col2 * col1 * + CAST ( col2 AS INTEGER ) + col0 AS col2 FROM tab1
----
119888
32554
75819

query I rowsort
SELECT ALL + - 42 + - col1 * - col2 FROM tab2 AS cor0
----
1492
604
795

query I rowsort
SELECT ALL 88 AS col0 FROM tab2 AS cor0
----
88
88
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-68
SELECT 1 + 48 DIV - col2 col1 FROM tab0 AS cor0
----
-47
0
1

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

query I rowsort
SELECT DISTINCT col2 + + ( + col1 ) * + 31 FROM tab0 AS cor0
----
2699
2903
3008

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + 63 + - col2 col0 FROM tab0 AS cor0
----
2046
5084
62

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

query I rowsort
SELECT + + col1 + col1 + + col1 AS col0 FROM tab1 AS cor0
----
30
39
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 * - col0 * + col0 col2 FROM tab0 AS cor0
----
-118860
-49560
-720900

query I rowsort
SELECT + ( 63 ) AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
-17
-31
-59

query I rowsort
SELECT DISTINCT tab0.col2 AS col2 FROM tab0, tab1 cor0, tab2 cor1
----
1
33
82

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

query I rowsort
SELECT DISTINCT cor0.col1 * 9 FROM tab2, tab0 AS cor0
----
774
819
873

query I rowsort
SELECT col2 * tab2.col0 * col2 AS col1 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - col0 + - col2 + col1 FROM tab0
----
-80
29
61

query I rowsort
SELECT 7 FROM tab0, tab1 cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + 30 col1 FROM tab0
----
119
54
65

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-87
SELECT ALL - tab2.col1 + col1 + - col1 DIV + col1 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-87
SELECT ALL - tab2.col1 + col1 + - col1 / + col1 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col2 + + col0 + 20 AS col0 FROM tab0
----
191
56
77

query I rowsort
SELECT ALL + cor0.col1 + ( 76 ) * col0 FROM tab1 AS cor0
----
254
4874
6093

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

query I rowsort
SELECT ALL + col1 + + col0 + cor0.col1 AS col1 FROM tab0 AS cor0
----
196
229
271

onlyif mysql # use DIV operator for integer division
query I rowsort label-92
SELECT DISTINCT - col2 DIV + 99 + cor0.col2 col1 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-92
SELECT DISTINCT - col2 / + 99 + cor0.col2 col1 FROM tab2 AS cor0
----
26
27
38

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

query I rowsort
SELECT - + ( - 47 ) * + col1 + - ( - 48 ) * col0 FROM tab0 AS cor0
----
5194
6239
8549

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-96
SELECT - CAST( col2 AS SIGNED ) - col0 AS col0 FROM tab2
----
-104
-117
-34

skipif mysql # not compatible
query I rowsort label-96
SELECT - CAST ( col2 AS INTEGER ) - col0 AS col0 FROM tab2
----
-104
-117
-34

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( 85 ) col1 FROM tab1, tab2, tab2 cor0
----
85

query I rowsort
SELECT DISTINCT col1 * + col1 * + col1 FROM tab2
----
205379
29791
4913

query I rowsort
SELECT 30 * + tab1.col1 * col1 AS col1 FROM tab1
----
20280
3000
5070

onlyif mysql # use DIV operator for integer division
query I rowsort label-101
SELECT ALL - tab1.col1 DIV + col0 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-101
SELECT ALL - tab1.col1 / + col0 FROM tab1
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 46 + col0 * col1 col1 FROM tab1 AS cor0
----
1100
1274
1638

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-104
SELECT + + col1 + cor0.col2 DIV cor0.col0 + - cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-927

skipif mysql # not compatible
query I rowsort label-104
SELECT + + col1 + cor0.col2 / cor0.col0 + - cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-927

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

query I rowsort
SELECT + col1 * 74 FROM tab1 cor0
----
1924
740
962

query I rowsort
SELECT + col1 + - col2 * + 81 AS col2 FROM tab1 cor0
----
-4348
-4607
-7763

query I rowsort
SELECT DISTINCT - 95 FROM tab0 AS cor0
----
-95

query I rowsort
SELECT + + 84 + cor0.col0 AS col0 FROM tab1 AS cor0
----
148
164
87

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

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

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

query I rowsort
SELECT DISTINCT - col2 * col0 * 68 + + col1 FROM tab0 AS cor0
----
-2283
-496173
-53770

query I rowsort
SELECT ALL + - col0 + - col2 * - col2 FROM tab1 AS cor0
----
2913
3185
9136

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

skipif mysql # not compatible
query I rowsort label-114
SELECT + cor0.col2 / - col2 FROM tab0 AS cor0
----
-1
-1
-1

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 16 * tab0.col1 * - tab0.col2 + col0 * col2 + 47 col1 FROM tab0
----
126737
1634
46247

query I rowsort
SELECT DISTINCT + + cor0.col1 * col0 * 8 - col0 * + 25 AS col2 FROM tab0 cor0
----
15912
26285
62567

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

query I rowsort
SELECT ALL + col1 * - col0 * - col1 AS col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT ALL ( col2 ) + - tab0.col1 - + ( + col1 ) * col0 FROM tab0
----
-2117
-3491
-8108

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

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

query I rowsort
SELECT DISTINCT - 60 - col2 AS col1 FROM tab1
----
-114
-117
-156

query I rowsort
SELECT ALL + tab2.col1 + col1 - col2 * + ( col1 + + 78 ) FROM tab2
----
-2881
-3444
-3576

query I rowsort
SELECT ALL - 5 * + 42 FROM tab1 AS cor0
----
-210
-210
-210

query I rowsort
SELECT DISTINCT 75 * ( - col1 + - col2 ) AS col0 FROM tab2 AS cor0
----
-4125
-4350
-6375

query I rowsort
SELECT ALL + cor0.col2 * col1 + + cor0.col1 FROM tab2 cor0
----
1593
663
868

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

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

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

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

query I rowsort
SELECT ALL + cor0.col1 + 92 FROM tab1 AS cor0
----
102
105
118

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

query I rowsort
SELECT DISTINCT - - col0 + 5 AS col2 FROM tab0 AS cor0
----
29
40
94

query I rowsort
SELECT ALL - 5 + + 17 * col1 AS col2 FROM tab1 cor0
----
165
216
437

query I rowsort
SELECT - 90 + cor0.col2 FROM tab2 AS cor0
----
-52
-63
-64

query I rowsort
SELECT col0 * 42 FROM tab1
----
126
2688
3360

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

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

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

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

query I rowsort
SELECT ( col2 * col0 ) - 69 FROM tab0
----
-34
7229
723

query I rowsort
SELECT - col1 + 96 AS col2 FROM tab1
----
70
83
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 28 - - col1 col1 FROM tab1
----
38
41
54

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

query I rowsort
SELECT DISTINCT col0 * ( - tab2.col0 ) * col0 FROM tab2
----
-343
-474552
-493039

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 30 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

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

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

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

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

query I rowsort
SELECT + 51 * + col0 AS col2 FROM tab2 AS cor0
----
357
3978
4029

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

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

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

query I rowsort
SELECT ALL + - col2 * - col2 + 88 AS col0 FROM tab1 AS cor0
----
3004
3337
9304

query I rowsort
SELECT - - 69 + col2 FROM tab1 cor0
----
123
126
165

query I rowsort
SELECT DISTINCT + 20 - - cor0.col0 AS col0 FROM tab0 cor0
----
109
44
55

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

query I rowsort
SELECT ALL + cor0.col1 * + 79 FROM tab0 AS cor0
----
6794
7189
7663

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - + ( - cor0.col1 ) * col2 * col0 col0 FROM tab2 AS cor0
----
119711
51051
5890

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

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

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

query I rowsort
SELECT DISTINCT - + col1 + 6 FROM tab0 cor0
----
-80
-85
-91

query I rowsort
SELECT - col1 * + col0 * + cor0.col2 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
-119574
-50955
-5852

query I rowsort
SELECT ALL 2 - + col1 * col0 * - col2 FROM tab0 cor0
----
3397
664120
68114

query I rowsort
SELECT DISTINCT col2 + + col0 * + col2 + - col0 FROM tab2 AS cor0
----
1976
209
2961

query I rowsort
SELECT + + 24 + col2 AS col2 FROM tab0 AS cor0
----
106
25
57

query I rowsort
SELECT DISTINCT + + 82 * + 8 - - cor0.col2 AS col2 FROM tab1 AS cor0
----
710
713
752

query I rowsort
SELECT ALL - 32 AS col2 FROM tab0 cor0
----
-32
-32
-32

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

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col2 FROM tab0 AS cor0
----
119
173
98

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-173
SELECT ALL + CAST ( - col0 AS INTEGER ) * col0 * + col1 col1 FROM tab0 cor0
----
-118825
-49536
-720811

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

query I rowsort
SELECT ALL 81 AS col0 FROM tab2
----
81
81
81

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

skipif mysql # not compatible
query I rowsort label-176
SELECT 72 / - col2 AS col0 FROM tab1
----
-1
-1
0

query I rowsort
SELECT col1 + 91 FROM tab2 AS cor0
----
108
122
150

onlyif mysql # use DIV operator for integer division
query I rowsort label-178
SELECT 82 DIV + col1 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-178
SELECT 82 / + col1 FROM tab2
----
1
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 99 * - col2 * - col0 AS col2 FROM tab2
----
18711
200772
297198

query I rowsort
SELECT + 90 * + tab2.col0 AS col2 FROM tab2
----
630
7020
7110

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

query I rowsort
SELECT cor0.col1 * col2 * col0 + - col0 FROM tab2 AS cor0
----
119574
50955
5852

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

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

query I rowsort
SELECT + col2 * + col0 * + tab2.col0 FROM tab2
----
1323
158184
237158

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * cor0.col1 - - col0 col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - col1 + 70 AS col0 FROM tab2 AS cor0
----
11
39
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + col0 col1 FROM tab1 AS cor0
----
128
160
6

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

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

query I rowsort
SELECT ALL + 45 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-195
SELECT + 18 / col1 col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + + col1 + - 81 * + col1 FROM tab2 cor0
----
-1360
-2480
-4720

query I rowsort
SELECT 7 * cor0.col2 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT ALL 53 + - 21 * + col2 AS col0 FROM tab1 AS cor0
----
-1081
-1144
-1963

query I rowsort
SELECT col0 * + 23 FROM tab2 cor0
----
161
1794
1817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-200
SELECT - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-200
SELECT - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

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

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

query I rowsort
SELECT - col2 * col1 * - ( col2 ) FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL cor0.col0 + - ( cor0.col2 * + cor1.col0 ) FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 95f5ec5b8703f20bf9459ba9d77e78a0

query I rowsort
SELECT + - 89 AS col1 FROM tab1, tab0 AS cor0, tab2, tab1 cor1
----
81 values hashing to 1e1759ead845b97a0ef58dbd6a959d73

query I rowsort
SELECT + 5 * + col1 AS col2 FROM tab0 cor0
----
430
455
485

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-208
SELECT + ( col0 ) + 29 DIV ( col1 ) FROM tab1 AS cor0
----
4
66
82

skipif mysql # not compatible
query I rowsort label-208
SELECT + ( col0 ) + 29 / ( col1 ) FROM tab1 AS cor0
----
4
66
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-209
SELECT col0 * col2 DIV 5 AS col2 FROM tab0 cor0
----
1459
158
7

skipif mysql # not compatible
query I rowsort label-209
SELECT col0 * col2 / 5 AS col2 FROM tab0 cor0
----
1459
158
7

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

query I rowsort
SELECT DISTINCT - 36 * + col1 AS col1 FROM tab0 AS cor0
----
-3096
-3276
-3492

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

skipif mysql # not compatible
query I rowsort label-212
SELECT + ( + col0 ) / 77 AS col0 FROM tab1 AS cor0
----
0
0
1

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

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

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

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

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

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

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

query I rowsort
SELECT ALL + col2 * cor0.col0 + ( + col1 * 95 ) AS col1 FROM tab0 AS cor0
----
15943
8962
9250

query I rowsort
SELECT DISTINCT col2 * cor0.col0 - + col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-220
SELECT DISTINCT + - col2 + 51 DIV cor0.col1 FROM tab1 AS cor0
----
-52
-53
-93

skipif mysql # not compatible
query I rowsort label-220
SELECT DISTINCT + - col2 + 51 / cor0.col1 FROM tab1 AS cor0
----
-52
-53
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-221
SELECT DISTINCT col1 + col2 DIV - 59 AS col2 FROM tab0 cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-221
SELECT DISTINCT col1 + col2 / - 59 AS col2 FROM tab0 cor0
----
86
90
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-222
SELECT ALL col0 DIV + 57 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-81

skipif mysql # not compatible
query I rowsort label-222
SELECT ALL col0 / + 57 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-81

query I rowsort
SELECT ALL + col0 * ( + col0 ) + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT + col0 * 90 AS col1 FROM tab0 AS cor0
----
2160
3150
8010

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-225
SELECT - + col1 / - col0 col1 FROM tab2 AS cor0
----
0
0
4

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-231
SELECT + col2 DIV + tab2.col1 + + col2 * 38 * ( col2 + col1 ) FROM tab2
----
59508
79422
83980

skipif mysql # not compatible
query I rowsort label-231
SELECT + col2 / + tab2.col1 + + col2 * 38 * ( col2 + col1 ) FROM tab2
----
59508
79422
83980

query I rowsort
SELECT ALL tab0.col0 + - 75 + + col2 AS col0 FROM tab0
----
-18
-39
96

query I rowsort
SELECT + col2 * ( + 23 * col0 + - col2 ) AS col2 FROM tab2 AS cor0
----
3618
45968
67602

query I rowsort
SELECT DISTINCT - - col2 * 42 FROM tab1 cor0
----
2268
2394
4032

query I rowsort
SELECT col0 * 10 AS col2 FROM tab1 AS cor0
----
30
640
800

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-237
SELECT + cor0.col0 DIV - cor0.col0 + col0 + - col1 FROM tab2 AS cor0
----
-25
18
61

skipif mysql # not compatible
query I rowsort label-237
SELECT + cor0.col0 / - cor0.col0 + col0 + - col1 FROM tab2 AS cor0
----
-25
18
61

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

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

query I rowsort
SELECT + + col2 + col1 * 25 AS col1 FROM tab1 AS cor0
----
307
421
704

query I rowsort
SELECT DISTINCT cor0.col1 * + 1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT 74 * - cor0.col0 + - col2 FROM tab0 AS cor0
----
-1809
-2591
-6668

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

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

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

query I rowsort
SELECT ALL 40 * col1 + + cor0.col0 * 99 FROM tab2 AS cor0
----
10082
1933
8501

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

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

query I rowsort
SELECT DISTINCT - 80 + col2 AS col2 FROM tab0 AS cor0
----
-47
-79
2

query I rowsort
SELECT ALL 56 + + col1 FROM tab2 AS cor0
----
115
73
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-248
SELECT - + 56 * col0 + col2 * col1 DIV col1 AS col2 FROM tab1 cor0
----
-114
-3527
-4384

skipif mysql # not compatible
query I rowsort label-248
SELECT - + 56 * col0 + col2 * col1 / col1 AS col2 FROM tab1 cor0
----
-114
-3527
-4384

query I rowsort
SELECT col2 + col0 * ( + col2 + + col2 * 88 ) FROM tab0 AS cor0
----
3116
649604
70521

query I rowsort
SELECT DISTINCT - 61 + + col1 AS col2 FROM tab2
----
-2
-30
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 * + col1 col0 FROM tab0
----
5762
6097
6499

onlyif mysql # use DIV operator for integer division
query I rowsort label-252
SELECT + 10 DIV - col0 + cor0.col0 * cor0.col2 FROM tab2 AS cor0
----
188
2028
3002

skipif mysql # not compatible
query I rowsort label-252
SELECT + 10 / - col0 + cor0.col0 * cor0.col2 FROM tab2 AS cor0
----
188
2028
3002

query I rowsort
SELECT ALL - 93 * + cor0.col0 + - 22 AS col1 FROM tab0 AS cor0
----
-2254
-3277
-8299

query I rowsort
SELECT ALL + 97 AS col2 FROM tab1 cor0
----
97
97
97

query I rowsort
SELECT ALL col0 * - ( col0 ) + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + + col0 * + 37 * - col0 - + col0 AS col2 FROM tab1 AS cor0
----
-151616
-236880
-336

query I rowsort
SELECT DISTINCT + + cor0.col0 * 66 AS col1 FROM tab2 AS cor0
----
462
5148
5214

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

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

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

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

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

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

query I rowsort
SELECT ALL - col2 + col2 * + cor0.col1 FROM tab1 AS cor0
----
1152
1350
513

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

query I rowsort
SELECT - 88 * - col2 + col1 AS col1 FROM tab1
----
4778
5026
8461

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

query I rowsort
SELECT col2 * - col0 + col0 + col0 FROM tab0 AS cor0
----
-7120
-744
35

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

query I rowsort
SELECT ALL + - col2 * 94 + 85 * col1 FROM tab0 AS cor0
----
27
4208
8151

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

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

query I rowsort
SELECT col0 + 25 * col0 * + col1 FROM tab0 AS cor0
----
202564
51624
84910

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

query I rowsort
SELECT col0 * 9 * + col1 AS col1 FROM tab1 AS cor0
----
5760
702
9360

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

query I rowsort
SELECT + col2 * - 76 + col0 + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-2262
-4152
-6500

query I rowsort
SELECT + col1 + 31 * col0 AS col0 FROM tab1
----
119
1994
2493

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

query I rowsort
SELECT + 24 * + 34 * tab2.col0 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 247c2e3030a56ff4047f4f59e8648391

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

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

query I rowsort
SELECT + col0 * 40 + col0 - - 62 FROM tab0
----
1046
1497
3711

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

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

query I rowsort
SELECT ( tab0.col0 ) + tab0.col0 + col1 AS col2 FROM tab0
----
134
167
269

query I rowsort
SELECT ALL - 86 * 67 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to d78a0958d167f496fd9878dc3e0fde0f

query I rowsort
SELECT ( - col0 ) * + 98 * col1 AS col0 FROM tab0
----
-202272
-332710
-793702

query I rowsort
SELECT DISTINCT - col2 + - col1 * + 96 FROM tab0 AS cor0
----
-8289
-8818
-9313

query I rowsort
SELECT DISTINCT - col2 + - col0 * + 99 FROM tab0 AS cor0
----
-2409
-3466
-8893

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-291
SELECT DISTINCT + col1 * cor0.col0 DIV + col1 + - col2 + col1 AS col2 FROM tab2 AS cor0
----
11
111
58

skipif mysql # not compatible
query I rowsort label-291
SELECT DISTINCT + col1 * cor0.col0 / + col1 + - col2 + col1 AS col2 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT DISTINCT - - col0 * col1 + + col0 FROM tab1 AS cor0
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-293
SELECT ALL + col2 DIV cor0.col0 + + 40 FROM tab0 AS cor0
----
40
40
41

skipif mysql # not compatible
query I rowsort label-293
SELECT ALL + col2 / cor0.col0 + + 40 FROM tab0 AS cor0
----
40
40
41

query I rowsort
SELECT DISTINCT cor1.col0 + 79 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
103
114
168

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

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

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

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

query I rowsort
SELECT + 74 + col1 AS col1 FROM tab2 AS cor0
----
105
133
91

query I rowsort
SELECT ALL - cor0.col0 * - col2 * 55 + col2 + + col0 AS col1 FROM tab0 AS cor0
----
1961
401561
43617

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

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

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

query I rowsort
SELECT - col1 FROM tab1 WHERE ( col1 / + col2 ) = NULL
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE col2 + + col0 <= - col0 OR + col2 <> NULL
----

query I rowsort
SELECT ALL - col0 * - col1 + - col0 * - cor0.col2 * cor0.col1 FROM tab0 AS cor0
----
672217
6790
70176

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

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

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

query I rowsort
SELECT ALL 29 + col2 * + col0 FROM tab0 AS cor0
----
64
7327
821

onlyif mysql # use DIV operator for integer division
query I rowsort label-309
SELECT ALL + col2 DIV - col0 + - col2 * - tab1.col2 * col1 AS col0 FROM tab1
----
119807
32490
75798

skipif mysql # not compatible
query I rowsort label-309
SELECT ALL + col2 / - col0 + - col2 * - tab1.col2 * col1 AS col0 FROM tab1
----
119807
32490
75798

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

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

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col0 * col1 + - col1 NOT IN ( + col2 * col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col2 + col0 * - col0 - col0 * col0 AS col2 FROM tab2
----
-12142
-12444
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-314
SELECT DISTINCT - col0 * + col2 DIV - col2 + - col0 * col2 * + col1 AS col0 FROM tab1
----
-36416
-4209
-99760

skipif mysql # not compatible
query I rowsort label-314
SELECT DISTINCT - col0 * + col2 / - col2 + - col0 * col2 * + col1 AS col0 FROM tab1
----
-36416
-4209
-99760

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

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

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

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

query I rowsort
SELECT col2 * tab1.col2 + tab1.col2 * col2 AS col1 FROM tab1
----
18432
5832
6498

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( col0 - + col2 / - col2 )
----

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-322
SELECT - col0 + - col1 + - col2 DIV + tab1.col1 AS col1 FROM tab1
----
-100
-31
-79

skipif mysql # not compatible
query I rowsort label-322
SELECT - col0 + - col1 + - col2 / + tab1.col1 AS col1 FROM tab1
----
-100
-31
-79

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

query I rowsort
SELECT DISTINCT + col1 FROM tab1 WHERE NULL IN ( col0 )
----

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

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

query I rowsort
SELECT - 6 + - cor0.col2 FROM tab1 AS cor0
----
-102
-60
-63

query I rowsort
SELECT col0 + tab2.col1 * col1 AS col0 FROM tab2
----
3559
368
968

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

query III rowsort
SELECT * FROM tab0 WHERE NULL BETWEEN NULL AND col1
----

query III rowsort
SELECT ALL * FROM tab0 cor0 WHERE ( NULL ) BETWEEN NULL AND NULL
----

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

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

skipif mysql # not compatible
query I rowsort label-332
SELECT DISTINCT + col0 * col2 + - col1 / - col0 FROM tab1
----
170
3648
7680

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT ( col0 ) NOT IN ( col0 * + cor0.col1 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 col1 FROM tab1 WHERE col2 >= - col0 / + col2
----
10
13
26

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

skipif mysql # not compatible
query I rowsort label-336
SELECT ALL col2 / col0 + - col0 / col0 FROM tab1
----
-1
0
17

query I rowsort
SELECT col2 * col0 + tab1.col2 * col1 - - col2 FROM tab1
----
1620
4275
9024

onlyif mysql # use DIV operator for integer division
query I rowsort label-338
SELECT - col0 + - col1 * - col2 + - col0 DIV col2 AS col2 FROM tab1
----
1168
1401
505

skipif mysql # not compatible
query I rowsort label-338
SELECT - col0 + - col1 * - col2 + - col0 / col2 AS col2 FROM tab1
----
1168
1401
505

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-341
SELECT DISTINCT - tab0.col2 + col1 * col1 DIV + col2 FROM tab0
----
18
191
9408

skipif mysql # not compatible
query I rowsort label-341
SELECT DISTINCT - tab0.col2 + col1 * col1 / + col2 FROM tab0
----
18
191
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-342
SELECT DISTINCT 34 + col2 DIV - tab0.col2 AS col2 FROM tab0
----
33

skipif mysql # not compatible
query I rowsort label-342
SELECT DISTINCT 34 + col2 / - tab0.col2 AS col2 FROM tab0
----
33

query I rowsort
SELECT cor0.col0 + 83 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to fe170710d7330cb44fef92d278f03e03

query I rowsort
SELECT - 83 + - col0 AS col0 FROM tab2
----
-161
-162
-90

query I rowsort
SELECT ALL + 72 + + 98 * col2 AS col0 FROM tab1
----
5364
5658
9480

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

query I rowsort
SELECT - col0 + - col1 * + ( 9 ) * col0 FROM tab0
----
-18600
-30590
-72980

query I rowsort
SELECT DISTINCT + 25 * + col1 FROM tab1
----
250
325
650

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

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

query I rowsort
SELECT + 64 * + cor0.col2 + - col2 AS col2 FROM tab2 AS cor0
----
1638
1701
2394

query I rowsort
SELECT ALL col0 - 2 AS col1 FROM tab0
----
22
33
87

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + 5 ) col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

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

query I rowsort
SELECT - col2 + 97 FROM tab1
----
1
40
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-357
SELECT - col1 * col0 DIV 25 AS col1 FROM tab2
----
-184
-53
-8

skipif mysql # not compatible
query I rowsort label-357
SELECT - col1 * col0 / 25 AS col1 FROM tab2
----
-184
-53
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-358
SELECT + tab2.col0 + + CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-358
SELECT + tab2.col0 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - - col2 + - col2 * 97 FROM tab1 AS cor0
----
-5184
-5472
-9216

query I rowsort
SELECT - + col1 + 32 * col2 FROM tab2 AS cor0
----
1199
773
833

query I rowsort
SELECT DISTINCT - - ( 54 ) FROM tab1 AS cor0
----
54

query I rowsort
SELECT 48 * col1 FROM tab2 AS cor0
----
1488
2832
816

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

query I rowsort
SELECT ALL - col1 + + ( + col1 * - 48 ) FROM tab2 cor0
----
-1519
-2891
-833

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

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

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

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

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

query I rowsort
SELECT ALL ( 97 ) + - col0 * + col1 FROM tab2 cor0
----
-120
-1246
-4505

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-371
SELECT + col2 DIV - 5 AS col1 FROM tab1
----
-10
-11
-19

skipif mysql # not compatible
query I rowsort label-371
SELECT + col2 / - 5 AS col1 FROM tab1
----
-10
-11
-19

query I rowsort
SELECT DISTINCT - 76 - cor0.col1 FROM tab2 AS cor0
----
-107
-135
-93

query I rowsort
SELECT + 59 + - 60 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-374
SELECT DISTINCT 45 - - col1 DIV col1 FROM tab1 AS cor0
----
46

skipif mysql # not compatible
query I rowsort label-374
SELECT DISTINCT 45 - - col1 / col1 FROM tab1 AS cor0
----
46

query I rowsort
SELECT + - 27 - - col2 AS col0 FROM tab1 AS cor0
----
27
30
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-376
SELECT ALL CAST( col1 AS SIGNED ) * - col2 DIV col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-376
SELECT ALL CAST ( col1 AS INTEGER ) * - col2 / col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + + 30 + - col1 AS col2 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT ALL - col2 + 25 FROM tab1 cor0
----
-29
-32
-71

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

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

query I rowsort
SELECT DISTINCT - ( + 76 ) * col0 - col2 FROM tab2 AS cor0
----
-559
-5954
-6042

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

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

query I rowsort
SELECT ( - 17 ) + + cor0.col2 FROM tab1 AS cor0
----
37
40
79

query I rowsort
SELECT ALL - 42 + col1 FROM tab1 AS cor0
----
-16
-29
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-385
SELECT - col0 * - col1 + col0 DIV col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-385
SELECT - col0 * - col1 + col0 / col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - - 91 FROM tab0 AS cor0
----
91
91
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 75 col2 FROM tab1
----
-225
-4800
-6000

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-388
SELECT - + col0 / col1 + - col2 col2 FROM tab1 AS cor0
----
-102
-54
-63

query I rowsort
SELECT 82 + + col1 AS col2 FROM tab0 AS cor0
----
168
173
179

query I rowsort
SELECT DISTINCT - - 31 * col2 FROM tab0 AS cor0
----
1023
2542
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col0 * col2 col1 FROM tab1 AS cor0
----
-136
-3638
-7667

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

query I rowsort
SELECT + 27 * col2 FROM tab1 AS cor0
----
1458
1539
2592

query I rowsort
SELECT 31 * - col0 FROM tab1 AS cor0
----
-1984
-2480
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-395
SELECT 51 + col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
50
50
50

skipif mysql # not compatible
query I rowsort label-395
SELECT 51 + col0 / - col0 AS col2 FROM tab2 AS cor0
----
50
50
50

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-400
SELECT DISTINCT 41 / - 24 + - col1 FROM tab2
----
-18
-32
-60

query I rowsort
SELECT ALL col0 + + col0 * + col0 + tab0.col2 * - col0 FROM tab0
----
-192
1225
712

query I rowsort
SELECT ALL col1 * - col2 + col1 FROM tab0
----
-2752
-7371
0

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

skipif mysql # not compatible
query I rowsort label-403
SELECT ALL CAST ( + col2 AS INTEGER ) + col0 AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL - col0 * 9 FROM tab1 AS cor0
----
-27
-576
-720

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

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

query I rowsort
SELECT col2 + + ( - 34 ) * col2 AS col2 FROM tab2 cor0
----
-1254
-858
-891

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

query I rowsort
SELECT + col1 * col0 * col1 FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT ALL col0 * - ( col0 + cor0.col2 ) AS col2 FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT - col1 * 85 FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT + 18 * + col0 + - ( - col2 * col2 ) FROM tab0
----
1521
631
8326

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

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

query I rowsort
SELECT DISTINCT + col0 * - 38 AS col0 FROM tab2 cor0
----
-266
-2964
-3002

query I rowsort
SELECT ( col2 ) - - tab2.col0 * 48 AS col0 FROM tab2
----
363
3770
3830

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

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

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) + - cor0.col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL col1 + ( col0 ) + - col2 FROM tab2 cor0
----
11
111
58

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

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

query I rowsort
SELECT DISTINCT - col0 * 77 AS col0 FROM tab0 AS cor0
----
-1848
-2695
-6853

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

query I rowsort
SELECT - col1 + + 26 * + cor0.col2 AS col1 FROM tab2 cor0
----
617
671
971

query I rowsort
SELECT ALL - cor2.col0 FROM tab2, tab0 cor0, tab2 cor1, tab0, tab0 AS cor2
----
243 values hashing to 68438270ef4dcbfd48dcdbe0b98336f5

query I rowsort
SELECT DISTINCT col0 + - col1 + col1 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-427
SELECT + col2 * col2 DIV - 43 FROM tab0 cor0
----
-156
-25
0

skipif mysql # not compatible
query I rowsort label-427
SELECT + col2 * col2 / - 43 FROM tab0 cor0
----
-156
-25
0

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

query I rowsort
SELECT DISTINCT - 29 - col1 AS col2 FROM tab0 AS cor0
----
-115
-120
-126

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

query I rowsort
SELECT ALL - 29 + col1 * col2 FROM tab1 AS cor0
----
1219
1375
541

query I rowsort
SELECT + 7 * - col0 FROM tab2 AS cor0
----
-49
-546
-553

onlyif mysql # use DIV operator for integer division
query I rowsort label-433
SELECT DISTINCT + - col2 * col2 DIV col1 AS col2 FROM tab2 cor0
----
-11
-23
-84

skipif mysql # not compatible
query I rowsort label-433
SELECT DISTINCT + - col2 * col2 / col1 AS col2 FROM tab2 cor0
----
-11
-23
-84

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

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

skipif mysql # not compatible
query I rowsort label-435
SELECT + CAST ( - cor0.col0 AS INTEGER ) FROM tab0, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT + cor0.col1 + col1 + - ( ( col2 ) + col0 ) FROM tab1 AS cor0
----
-101
-150
-5

query I rowsort
SELECT + - 8 + + col2 * + 27 AS col0 FROM tab1 AS cor0
----
1450
1531
2584

query I rowsort
SELECT + col0 * col2 + + col2 * col0 FROM tab1 AS cor0
----
15360
324
7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-439
SELECT + cor0.col2 + cor0.col2 * ( + col1 ) DIV - col0 FROM tab2 cor0
----
-92
30
7

skipif mysql # not compatible
query I rowsort label-439
SELECT + cor0.col2 + cor0.col2 * ( + col1 ) / - col0 FROM tab2 cor0
----
-92
30
7

query I rowsort
SELECT - col2 * col1 * col2 + cor0.col1 + col2 AS col2 FROM tab0 cor0
----
-611711
-93535
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-441
SELECT - col2 + cor0.col1 * + col1 DIV + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-441
SELECT - col2 + cor0.col1 * + col1 / + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL 32 + - col0 FROM tab0
----
-3
-57
8

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

query I rowsort
SELECT DISTINCT 98 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
98

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

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

query I rowsort
SELECT + + col1 * + col1 + col2 + col2 * - col1 AS col0 FROM tab2 AS cor0
----
-319
151
1973

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

query I rowsort
SELECT - 20 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

query I rowsort
SELECT DISTINCT col1 + - col2 + + col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-451
SELECT DISTINCT col1 * + col1 - col2 DIV col0 AS col0 FROM tab2 AS cor0
----
289
3481
958

skipif mysql # not compatible
query I rowsort label-451
SELECT DISTINCT col1 * + col1 - col2 / col0 AS col0 FROM tab2 AS cor0
----
289
3481
958

query I rowsort
SELECT DISTINCT col0 * + col1 * col0 + col0 FROM tab1 AS cor0
----
237
41024
83280

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

query I rowsort
SELECT DISTINCT - - col1 + + col0 * 94 AS col2 FROM tab2 AS cor0
----
689
7391
7443

onlyif mysql # use DIV operator for integer division
query I rowsort label-455
SELECT ALL + 65 DIV col1 - - 5 * tab2.col0 AS col0 FROM tab2
----
37
391
398

skipif mysql # not compatible
query I rowsort label-455
SELECT ALL + 65 / col1 - - 5 * tab2.col0 AS col0 FROM tab2
----
37
391
398

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

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

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

skipif mysql # not compatible
query I rowsort label-458
SELECT - tab0.col0 * + col0 + CAST ( - col1 AS INTEGER ) + - col0 AS col0 FROM tab0
----
-1357
-686
-8101

query I rowsort
SELECT ALL + 64 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT ALL - cor0.col1 + 84 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 07473b34633286566feeddad35114092

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

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

query I rowsort
SELECT col1 * 83 * 96 FROM tab1
----
103584
207168
79680

query I rowsort
SELECT ALL - - col0 + 87 * col2 AS col2 FROM tab0 AS cor0
----
122
2895
7223

query I rowsort
SELECT DISTINCT + - col1 * col0 + + 80 AS col2 FROM tab0 AS cor0
----
-1984
-3315
-8019

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

query I rowsort
SELECT + col1 + 48 AS col2 FROM tab1 AS cor0
----
58
61
74

query I rowsort
SELECT - - col1 * cor0.col1 + + col2 * + col2 * + col1 AS col2 FROM tab0 AS cor0
----
101050
620165
9506

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

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

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

query I rowsort
SELECT DISTINCT - 93 * - cor0.col2 + - cor0.col0 FROM tab2 AS cor0
----
2340
2504
3455

query I rowsort
SELECT 1 + - col0 + col2 AS col0 FROM tab0 AS cor0
----
-33
-6
10

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

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

query I rowsort
SELECT ALL 6 - cor0.col1 AS col2 FROM tab0 AS cor0
----
-80
-85
-91

query I rowsort
SELECT ALL col1 + + col1 * ( 48 ) FROM tab2 AS cor0
----
1519
2891
833

onlyif mysql # use DIV operator for integer division
query I rowsort label-477
SELECT ALL + col2 * col2 * + col1 - + 38 DIV + col0 col1 FROM tab0 AS cor0
----
611884
93653
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-477
SELECT ALL + col2 * col2 * + col1 - + 38 / + col0 col1 FROM tab0 AS cor0
----
611884
93653
96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-479
SELECT DISTINCT - col1 DIV - 87 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-479
SELECT DISTINCT - col1 / - 87 FROM tab1 AS cor0
----
0

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

skipif mysql # not compatible
query I rowsort label-480
SELECT - CAST ( NULL AS REAL ) * + 90 * col2 + 93 + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( 70 ) + col1 + - 4 col2 FROM tab2 AS cor0
----
125
83
97

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

query I rowsort
SELECT DISTINCT + - col1 + + 45 FROM tab0 AS cor0
----
-41
-46
-52

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

skipif mysql # not compatible
query I rowsort label-485
SELECT ALL + - CAST ( - 84 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
84
84
84

query I rowsort
SELECT col2 * + col1 + col1 * + 76 AS col2 FROM tab2 AS cor0
----
1938
3193
6018

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

query I rowsort
SELECT + - 49 + - 43 FROM tab2 AS cor0
----
-92
-92
-92

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

query I rowsort
SELECT - + ( 68 ) * + col0 - + col0 AS col0 FROM tab0 AS cor0
----
-1656
-2415
-6141

query I rowsort
SELECT 50 - - 45 * tab0.col2 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to 1a8e6376508e91b98c61d6ac30a45ace

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + ( col0 ) * + col1 - + ( col1 ) col1 FROM tab0
----
2002
3333
8097

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-496
SELECT + col0 / - col1 - cor0.col2 * col1 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - + 26 + cor0.col2 * col0 * 95 FROM tab2 AS cor0
----
17929
192634
285164

onlyif mysql # use DIV operator for integer division
query I rowsort label-498
SELECT ALL - cor0.col0 + col1 * col2 DIV - 70 AS col1 FROM tab0 AS cor0
----
-195
-36
-64

skipif mysql # not compatible
query I rowsort label-498
SELECT ALL - cor0.col0 + col1 * col2 / - 70 AS col1 FROM tab0 AS cor0
----
-195
-36
-64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 44 + 42 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT + + cor1.col2 + - 28 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to d950c55cb268e0f133f7bb4f871d0210

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

query I rowsort
SELECT DISTINCT + - cor1.col2 * 94 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
-2444
-2538
-3572

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-504
SELECT DISTINCT ( col0 ) * col2 * col1 + - tab1.col0 DIV col1 col1 FROM tab1
----
36474
4212
99834

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-504
SELECT DISTINCT ( col0 ) * col2 * col1 + - tab1.col0 / col1 col1 FROM tab1
----
36474
4212
99834

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

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

query I rowsort
SELECT DISTINCT col2 + ( cor0.col0 ) * + col2 * - 70 FROM tab0 AS cor0
----
-2449
-510778
-55407

query I rowsort
SELECT ALL - 1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

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

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

query I rowsort
SELECT + ( - col2 ) * col1 + + col1 * - col2 AS col0 FROM tab0
----
-14924
-194
-5676

onlyif mysql # use DIV operator for integer division
query I rowsort label-510
SELECT ALL col2 DIV 86 + col2 + - col2 * + col2 AS col2 FROM tab1
----
-2862
-3192
-9119

skipif mysql # not compatible
query I rowsort label-510
SELECT ALL col2 / 86 + col2 + - col2 * + col2 AS col2 FROM tab1
----
-2862
-3192
-9119

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

query I rowsort
SELECT DISTINCT - col1 * + ( + col0 ) - tab1.col0 AS col0 FROM tab1
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-513
SELECT DISTINCT tab0.col2 DIV + 36 - + col0 * + col1 * col0 FROM tab0
----
-118825
-49536
-720809

skipif mysql # not compatible
query I rowsort label-513
SELECT DISTINCT tab0.col2 / + 36 - + col0 * + col1 * col0 FROM tab0
----
-118825
-49536
-720809

query I rowsort
SELECT ALL - col0 + 14 + col2 * + col1 AS col0 FROM tab2
----
1470
581
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-515
SELECT DISTINCT col0 + - CAST( - col1 AS SIGNED ) col0 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-515
SELECT DISTINCT col0 + - CAST ( - col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 36 col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * cor0.col0 col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 368b2268fa85c1d99bbd086f4591b02b

query I rowsort
SELECT ALL - + col0 * - 52 AS col1 FROM tab1 cor0
----
156
3328
4160

query I rowsort
SELECT ALL cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 cor1, tab1, tab1 AS cor2
----
243 values hashing to de2705ff0bb8b4f714dafb07497c6119

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

query I rowsort
SELECT ALL - 76 + 74 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 20c9213316527d507e26425041e08387

onlyif mysql # use DIV operator for integer division
query I rowsort label-522
SELECT + 37 DIV col0 + col2 FROM tab0 AS cor0
----
2
34
82

skipif mysql # not compatible
query I rowsort label-522
SELECT + 37 / col0 + col2 FROM tab0 AS cor0
----
2
34
82

query I rowsort
SELECT DISTINCT col1 * - 79 FROM tab0 AS cor0
----
-6794
-7189
-7663

query I rowsort
SELECT + col0 + - col1 * col2 * 58 AS col1 FROM tab2 AS cor0
----
-37389
-48539
-88894

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

query I rowsort
SELECT ALL - 78 FROM tab0
----
-78
-78
-78

query I rowsort
SELECT + col1 * col2 + - col2 * col2 AS col2 FROM tab0 AS cor0
----
1749
738
96

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

skipif mysql # not compatible
query I rowsort label-528
SELECT DISTINCT + col0 + + col0 / cor0.col2 AS col0 FROM tab1 AS cor0
----
3
65
80

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

query I rowsort
SELECT col0 * - col1 + col0 FROM tab0
----
-2040
-3360
-8010

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

query I rowsort
SELECT - + ( col1 ) + 83 FROM tab1 AS cor0
----
57
70
73

query I rowsort
SELECT DISTINCT + ( col1 ) - 69 AS col0 FROM tab2 AS cor0
----
-10
-38
-52

query I rowsort
SELECT ALL 76 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT DISTINCT + 95 AS col0 FROM tab1 cor0
----
95

query I rowsort
SELECT ALL cor1.col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 95 * col0 col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

query I rowsort
SELECT DISTINCT + col0 + + col1 * + 90 FROM tab2 AS cor0
----
1609
2797
5388

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-539
SELECT DISTINCT - col0 - CAST( - 93 AS SIGNED ) FROM tab2 AS cor0
----
14
15
86

skipif mysql # not compatible
query I rowsort label-539
SELECT DISTINCT - col0 - CAST ( - 93 AS INTEGER ) FROM tab2 AS cor0
----
14
15
86

query I rowsort
SELECT - + col2 + 85 AS col1 FROM tab0 AS cor0
----
3
52
84

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

query I rowsort
SELECT ALL + - col2 * - 56 FROM tab0 AS cor0
----
1848
4592
56

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

query I rowsort
SELECT + col2 + col2 * + ( tab2.col2 ) FROM tab2
----
1482
702
756

query I rowsort
SELECT ALL - 52 * col0 FROM tab1
----
-156
-3328
-4160

query I rowsort
SELECT col0 + - col2 * - 58 AS col1 FROM tab2
----
1573
1586
2283

query I rowsort
SELECT - col2 * + tab0.col0 + - 11 FROM tab0
----
-46
-7309
-803

query I rowsort
SELECT + 91 + tab1.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to c70a33adfad247032cc9009fcfccad61

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-550
SELECT - col2 + 48 * col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
-48
-6
-9

skipif mysql # not compatible
query I rowsort label-550
SELECT - col2 + 48 * col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
-48
-6
-9

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

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

query I rowsort
SELECT DISTINCT + col0 * - col2 + col0 * 16 FROM tab2 AS cor0
----
-1738
-77
-780

query I rowsort
SELECT DISTINCT + 57 * col2 * ( - 67 * + col0 ) - 14 AS col2 FROM tab2 AS cor0
----
-11464652
-721805
-7744946

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-555
SELECT + col1 + CAST( 78 AS SIGNED ) * + col2 AS col0 FROM tab2 AS cor0
----
2087
2137
2981

skipif mysql # not compatible
query I rowsort label-555
SELECT + col1 + CAST ( 78 AS INTEGER ) * + col2 AS col0 FROM tab2 AS cor0
----
2087
2137
2981

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

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 - col1 * cor0.col1 FROM tab1 AS cor0
----
-514
3548
7511

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

query I rowsort
SELECT - - cor0.col2 + col2 * - col1 * + col0 FROM tab0 AS cor0
----
-3394
-664036
-68079

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

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

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

query I rowsort
SELECT DISTINCT + col1 * - ( col1 ) + col2 AS col1 FROM tab2
----
-251
-3455
-934

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

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

query I rowsort
SELECT ALL - 20 * + col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-11400
-24960
-28080

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-569
SELECT col0 * - col1 + - col2 DIV 50 col0 FROM tab1 AS cor0
----
-1041
-641
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-569
SELECT col0 * - col1 + - col2 / 50 col0 FROM tab1 AS cor0
----
-1041
-641
-79

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

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

query I rowsort
SELECT DISTINCT + - col1 + col0 * col1 AS col2 FROM tab2 cor0
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - cor0.col1 * col1 + - col1 col2 FROM tab0 AS cor0
----
-244154
-679133
-9506

query I rowsort
SELECT 40 * - 40 - - col2 FROM tab0 AS cor0
----
-1518
-1567
-1599

onlyif mysql # use DIV operator for integer division
query I rowsort label-574
SELECT ( - cor0.col0 ) * col2 DIV col2 + 89 col0 FROM tab1 AS cor0
----
25
86
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-574
SELECT ( - cor0.col0 ) * col2 / col2 + 89 col0 FROM tab1 AS cor0
----
25
86
9

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

query I rowsort
SELECT + col1 + + 11 * - col2 FROM tab1 AS cor0
----
-1043
-568
-617

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

query I rowsort
SELECT - ( 99 ) * - col1 * - col1 FROM tab0
----
-732204
-819819
-931491

query I rowsort
SELECT ALL + tab2.col0 + + tab2.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 10977325261681ddca962e0a5d2b348b

query I rowsort
SELECT + 83 * + col0 + col0 * col2 FROM tab0 AS cor0
----
14685
2784
2940

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + + col1 + ( col0 ) * cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

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

query I rowsort
SELECT + + col2 + - 48 * + col0 FROM tab0 cor0
----
-1119
-1679
-4190

query I rowsort
SELECT - col1 - + ( + 46 ) * col0 FROM tab2
----
-353
-3647
-3651

query I rowsort
SELECT DISTINCT + col0 * 48 + - col0 AS col1 FROM tab1 AS cor0
----
141
3008
3760

query I rowsort
SELECT ALL - col2 * + col2 + - 9 FROM tab2 cor0
----
-1453
-685
-738

onlyif mysql # use DIV operator for integer division
query I rowsort label-592
SELECT DISTINCT + - col1 - col0 DIV + 11 AS col2 FROM tab2 AS cor0
----
-24
-31
-66

skipif mysql # not compatible
query I rowsort label-592
SELECT DISTINCT + - col1 - col0 / + 11 AS col2 FROM tab2 AS cor0
----
-24
-31
-66

skipif mysql # not compatible
query I rowsort
SELECT ALL + 60 + col0 * - CAST ( col0 AS REAL ) AS col1 FROM tab2
----
-6024
-6181
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col2 + + col2 * + col0 col0 FROM tab2
----
2054
216
3040

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

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

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

query I rowsort
SELECT + + col0 + cor0.col2 * - 88 FROM tab0 AS cor0
----
-2880
-53
-7127

query I rowsort
SELECT + 68 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT + 99 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

onlyif mysql # use DIV operator for integer division
query I rowsort label-601
SELECT - col2 - - col2 DIV + 46 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-601
SELECT - col2 - - col2 / + 46 FROM tab2 AS cor0
----
-26
-27
-38

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

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

query I rowsort
SELECT ALL cor0.col2 + 24 FROM tab2 AS cor0
----
50
51
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-605
SELECT DISTINCT col2 DIV + 87 + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-605
SELECT DISTINCT col2 / + 87 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - col2 * - 70 + - 77 FROM tab1 AS cor0
----
3703
3913
6643

query I rowsort
SELECT DISTINCT col1 - - col0 * + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT + col2 * 6 + col2 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT ALL - - ( + col2 ) + col2 * ( col0 ) * + col1 AS col0 FROM tab1 AS cor0
----
36537
4266
99936

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

query I rowsort
SELECT + + col0 + col2 * col2 AS col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT DISTINCT + ( 84 ) + cor0.col1 FROM tab1 AS cor0
----
110
94
97

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

query I rowsort
SELECT + 23 * ( col1 ) FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT 67 * cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 33e66bfe952f4745b3097d3bd663d4d6

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

skipif mysql # not compatible
query I rowsort label-616
SELECT ALL - col2 + - col1 / tab2.col0 AS col0 FROM tab2
----
-26
-31
-38

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

query I rowsort
SELECT + ( col2 ) - - col1 * col1 AS col1 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT 61 AS col2 FROM tab1, tab1 cor0
----
61

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

query I rowsort
SELECT DISTINCT + ( + 16 + + tab0.col2 ) AS col2 FROM tab0
----
17
49
98

query I rowsort
SELECT + 2 + - col1 AS col2 FROM tab1
----
-11
-24
-8

query I rowsort
SELECT + tab1.col2 + + 39 AS col0 FROM tab1
----
135
93
96

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

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

query I rowsort
SELECT ( - 64 ) AS col1 FROM tab2
----
-64
-64
-64

query I rowsort
SELECT DISTINCT + ( - col0 + + col2 ) * 82 FROM tab0
----
-2788
-574
738

query I rowsort
SELECT - - 34 * cor0.col1 FROM tab1 AS cor0
----
340
442
884

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

query I rowsort
SELECT - 72 * cor0.col2 FROM tab0 AS cor0
----
-2376
-5904
-72

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

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

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

query I rowsort
SELECT ALL - ( col0 ) * 54 AS col2 FROM tab0
----
-1296
-1890
-4806

onlyif mysql # use DIV operator for integer division
query I rowsort label-633
SELECT ALL col1 * - col1 DIV - col1 + ( col0 ) AS col2 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-633
SELECT ALL col1 * - col1 / - col1 + ( col0 ) AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT col2 * 6 + 19 FROM tab0
----
217
25
511

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-636
SELECT col2 * - 18 + col2 DIV + col1 + + col2 AS col0 FROM tab1
----
-1625
-916
-964

skipif mysql # not compatible
query I rowsort label-636
SELECT col2 * - 18 + col2 / + col1 + + col2 AS col0 FROM tab1
----
-1625
-916
-964

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

query I rowsort
SELECT col2 * - 10 AS col0 FROM tab0
----
-10
-330
-820

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 83 col1 FROM tab1
----
249
5312
6640

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-644
SELECT + 50 DIV 24 FROM tab1 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-644
SELECT + 50 / 24 FROM tab1 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT - cor0.col1 * + 41 FROM tab0 AS cor0
----
-3526
-3731
-3977

onlyif mysql # use DIV operator for integer division
query I rowsort label-646
SELECT DISTINCT 53 + col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
54

skipif mysql # not compatible
query I rowsort label-646
SELECT DISTINCT 53 + col0 / + col0 AS col0 FROM tab0 AS cor0
----
54

query I rowsort
SELECT DISTINCT - ( + 56 ) * + col0 + - 99 FROM tab0 AS cor0
----
-1443
-2059
-5083

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

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

query I rowsort
SELECT col0 * + col2 + + col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-650
SELECT ALL cor0.col1 DIV + col0 + cor0.col2 * 84 AS col2 FROM tab1 AS cor0
----
4544
4788
8064

skipif mysql # not compatible
query I rowsort label-650
SELECT ALL cor0.col1 / + col0 + cor0.col2 * 84 AS col2 FROM tab1 AS cor0
----
4544
4788
8064

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-653
SELECT ALL 57 DIV + 94 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-653
SELECT ALL 57 / + 94 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ( 58 ) FROM tab1 AS cor0
----
58
58
58

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

skipif mysql # not compatible
query I rowsort label-655
SELECT DISTINCT - - CAST ( - col1 AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col1 * 27 FROM tab2 cor0
----
1593
459
837

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

query I rowsort
SELECT DISTINCT + + 55 + + col2 FROM tab1 AS cor0
----
109
112
151

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-662
SELECT ALL - col1 + col1 DIV + col2 FROM tab0 AS cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-662
SELECT ALL - col1 + col1 / + col2 FROM tab0 AS cor0
----
-84
-90
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-663
SELECT ALL col1 + - col0 DIV cor0.col2 FROM tab1 AS cor0
----
13
26
9

skipif mysql # not compatible
query I rowsort label-663
SELECT ALL col1 + - col0 / cor0.col2 FROM tab1 AS cor0
----
13
26
9

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-665
SELECT ALL col0 DIV + col1 - col1 * col2 FROM tab1
----
-1242
-1404
-564

skipif mysql # not compatible
query I rowsort label-665
SELECT ALL col0 / + col1 - col1 * col2 FROM tab1
----
-1242
-1404
-564

query I rowsort
SELECT DISTINCT col0 - - col2 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL col0 * - col0 * + col1 + col0 * col1 FROM tab1
----
-156
-40320
-82160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col0 - col1 * + col2 col1 FROM tab2
----
-1430
-529
-803

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

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

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

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

query I rowsort
SELECT col1 + tab2.col0 + col0 FROM tab2
----
175
215
45

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

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

query I rowsort
SELECT ALL + 15 AS col0 FROM tab1
----
15
15
15

query I rowsort
SELECT ALL ( 93 ) AS col2 FROM tab1
----
93
93
93

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-679
SELECT DISTINCT - col2 DIV col2 - - col2 AS col1 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-679
SELECT DISTINCT - col2 / col2 - - col2 AS col1 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT - 2 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-12
-15
-28

query I rowsort
SELECT - col2 * - cor0.col2 + col1 AS col2 FROM tab1 AS cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col2 * + col2 + + col1 col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT col0 AS col0 FROM tab2 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT tab1.col2 FROM tab1 WHERE NOT ( - col2 ) > col0 + col1 * + col2
----
54
57
96

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

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE - col2 IN ( - col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-687
SELECT DISTINCT + col2 * cor0.col2 DIV col1 FROM tab2 AS cor0
----
11
23
84

skipif mysql # not compatible
query I rowsort label-687
SELECT DISTINCT + col2 * cor0.col2 / col1 FROM tab2 AS cor0
----
11
23
84

query I rowsort
SELECT cor0.col0 * col0 AS col1 FROM tab0 cor0 WHERE NULL = + col1 + col2 / col1
----

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

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

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

query I rowsort
SELECT ALL tab2.col0 FROM tab2 WHERE NOT NULL BETWEEN - col0 + col1 AND NULL
----

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

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

query I rowsort
SELECT ALL col1 * + col1 + + tab2.col1 FROM tab2
----
306
3540
992

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

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

query I rowsort
SELECT col0 + col2 * col2 * + col2 AS col1 FROM tab2
----
17654
19690
54951

onlyif mysql # use DIV operator for integer division
query I rowsort label-697
SELECT col1 DIV col2 col2 FROM tab1
----
0
0
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-698
SELECT ALL col0 DIV col1 - + col1 FROM tab2
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-698
SELECT ALL col0 / col1 - + col1 FROM tab2
----
-13
-31
-58

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

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

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN NULL AND ( NULL )
----

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

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

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

skipif mysql # not compatible
query I rowsort label-704
SELECT + tab1.col0 / - col0 AS col0 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-705
SELECT DISTINCT col1 DIV col1 - + col2 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-705
SELECT DISTINCT col1 / col1 - + col2 FROM tab2
----
-25
-26
-37

query I rowsort
SELECT DISTINCT - col0 * col0 + col1 AS col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT - col2 * col1 * - col1 + col2 AS col1 FROM tab2 cor0
----
11020
25974
90532

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

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

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

skipif mysql # not compatible
query I rowsort label-710
SELECT + + col0 * col2 + - cor0.col0 + col2 / col2 FROM tab0 AS cor0
----
1
7210
769

query I rowsort
SELECT + - col1 + col1 * + col1 AS col2 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT col2 * tab1.col2 * - col2 FROM tab1
----
-157464
-185193
-884736

query I rowsort
SELECT col0 * - tab0.col1 * tab0.col2 AS col2 FROM tab0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - cor0.col2 * - col2 col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL + - col1 * col2 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
22599
24548
39884

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

query I rowsort
SELECT DISTINCT + tab0.col2 * col1 + - col0 + + col0 * col2 AS col1 FROM tab0
----
14671
3606
97

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

query I rowsort
SELECT DISTINCT tab2.col1 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col1 + col1 col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + col2 * + col2 * col0 + - col2 FROM tab0
----
26103
34
598354

query I rowsort
SELECT col0 * - 63 + col2 AS col2 FROM tab1
----
-135
-3975
-4944

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

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

query I rowsort
SELECT ALL 55 * + col0 * + col0 AS col2 FROM tab2 AS cor0
----
2695
334620
343255

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-730
SELECT 47 / - col1 col1 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT 91 + col2 + - col1 * col0 AS col2 FROM tab1 AS cor0
----
-492
-853
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-732
SELECT - 35 DIV 86 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-732
SELECT - 35 / 86 FROM tab1 AS cor0
----
0
0
0

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

query I rowsort
SELECT col0 + - col0 * 62 FROM tab0
----
-1464
-2135
-5429

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

skipif mysql # not compatible
query I rowsort label-735
SELECT DISTINCT + col1 - + cor0.col2 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 59 * col1 + col1 * col1 FROM tab0 AS cor0
----
12470
13650
15132

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col2 * - 41 col1 FROM tab1 AS cor0
----
-2211
-2273
-3856

query I rowsort
SELECT DISTINCT 36 * col0 AS col2 FROM tab2 AS cor0
----
252
2808
2844

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

skipif mysql # not compatible
query I rowsort label-739
SELECT DISTINCT + cor0.col1 + + col1 / 91 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT 1 + + col1 AS col2 FROM tab0 AS cor0
----
87
92
98

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

query I rowsort
SELECT ALL + 29 + + col1 * 7 AS col1 FROM tab0 AS cor0
----
631
666
708

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

query I rowsort
SELECT + 90 + - col0 * ( col0 ) FROM tab2 AS cor0
----
-5994
-6151
41

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

query I rowsort
SELECT DISTINCT - 90 * - cor0.col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
630
7020
7110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + + col1 * + col1 col2 FROM tab1 AS cor0
----
110
182
702

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

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

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

query I rowsort
SELECT ALL 71 AS col0 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

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

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

query I rowsort
SELECT DISTINCT + 34 + - col2 FROM tab1
----
-20
-23
-62

query I rowsort
SELECT - 35 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT ( col1 ) + + 97 * - 78 AS col2 FROM tab0
----
-7469
-7475
-7480

query I rowsort
SELECT DISTINCT col2 * - ( col1 ) * - col2 FROM tab2 AS cor0
----
22599
24548
39884

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

query I rowsort
SELECT ALL + col1 * - 94 AS col1 FROM tab0 AS cor0
----
-8084
-8554
-9118

query I rowsort
SELECT DISTINCT - col2 * ( - col2 + + col1 ) AS col2 FROM tab1
----
1512
2679
7968

query I rowsort
SELECT - col0 + 78 FROM tab0 AS cor0
----
-11
43
54

query I rowsort
SELECT col2 * 47 AS col2 FROM tab2 AS cor0
----
1222
1269
1786

query I rowsort
SELECT col2 + + 96 * col1 FROM tab2 cor0
----
1670
3003
5690

query I rowsort
SELECT - - col2 * 15 + col1 FROM tab0 AS cor0
----
112
1321
581

query I rowsort
SELECT + ( 85 ) * - col0 + + col2 FROM tab1 AS cor0
----
-201
-5383
-6704

query I rowsort
SELECT + + 36 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

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

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

query I rowsort
SELECT 60 * - 90 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 86e06350e86332c4e730b373b673a56f

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

query I rowsort
SELECT DISTINCT + 46 * + col0 + - col2 * + tab1.col1 * + col1 AS col1 FROM tab1
----
-12544
-2756
-36366

query I rowsort
SELECT + + col2 * - 58 + col2 + - col2 AS col0 FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT + 35 * col0 + + col2 FROM tab0 AS cor0
----
1226
3197
873

onlyif mysql # use DIV operator for integer division
query I rowsort label-774
SELECT - 81 DIV col0 FROM tab0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-774
SELECT - 81 / col0 FROM tab0
----
-2
-3
0

query I rowsort
SELECT + - 36 * col2 AS col1 FROM tab1 AS cor0
----
-1944
-2052
-3456

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

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

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

skipif mysql # not compatible
query I rowsort label-777
SELECT - 25 / col2 AS col1 FROM tab0 cor0
----
-25
0
0

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

query I rowsort
SELECT DISTINCT 10 + - col2 AS col2 FROM tab2 AS cor0
----
-16
-17
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-780
SELECT DISTINCT - col0 DIV 96 AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-780
SELECT DISTINCT - col0 / 96 AS col2 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-781
SELECT - 32 DIV col1 FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-781
SELECT - 32 / col1 FROM tab1
----
-1
-2
-3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-783
SELECT + cor0.col1 * col1 DIV - ( col2 + col2 ) FROM tab0 AS cor0
----
-112
-4704
-50

skipif mysql # not compatible
query I rowsort label-783
SELECT + cor0.col1 * col1 / - ( col2 + col2 ) FROM tab0 AS cor0
----
-112
-4704
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-784
SELECT + col0 + tab2.col2 DIV - ( col0 + - col2 ) AS col1 FROM tab2
----
78
79
8

skipif mysql # not compatible
query I rowsort label-784
SELECT + col0 + tab2.col2 / - ( col0 + - col2 ) AS col1 FROM tab2
----
78
79
8

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

query I rowsort
SELECT ( col2 * - 80 ) - + col1 AS col0 FROM tab2
----
-2139
-2191
-3057

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + tab2.col2 ) col2 FROM tab2, tab0 AS cor0
----
26
27
38

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

query I rowsort
SELECT DISTINCT - ( - col2 ) * col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - 56 - col1 * col2 FROM tab2
----
-1590
-702
-893

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

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

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

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

query I rowsort
SELECT + col1 * - 90 * - col2 + + col0 * + 28 FROM tab1 AS cor0
----
114560
126444
53092

onlyif mysql # use DIV operator for integer division
query I rowsort label-798
SELECT ALL 74 + tab0.col2 DIV - col2 col2 FROM tab0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-798
SELECT ALL 74 + tab0.col2 / - col2 col2 FROM tab0
----
73
73
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-799
SELECT ALL - ( - col2 ) * - col2 + - tab0.col0 * col1 DIV col0 AS col1 FROM tab0
----
-1175
-6815
-98

skipif mysql # not compatible
query I rowsort label-799
SELECT ALL - ( - col2 ) * - col2 + - tab0.col0 * col1 / col0 AS col1 FROM tab0
----
-1175
-6815
-98

query I rowsort
SELECT ALL col0 + + 28 AS col2 FROM tab2
----
106
107
35

query I rowsort
SELECT - + 11 + - col2 FROM tab0 AS cor0
----
-12
-44
-93

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-804
SELECT ALL + col2 / cor0.col1 + col2 col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + + 23 * + col1 AS col0 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT DISTINCT + + ( col1 ) * 45 + col1 AS col0 FROM tab2 cor0
----
1426
2714
782

query I rowsort
SELECT DISTINCT - col0 * - col1 * + cor0.col2 + 78 AS col1 FROM tab0 cor0
----
3473
664196
68190

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

skipif mysql # not compatible
query I rowsort label-808
SELECT DISTINCT - col2 * col2 + - CAST ( col2 * col2 AS INTEGER ) + + cor0.col0 * ( col0 ) AS col0 FROM tab2 AS cor0
----
-1409
3353
4732

query I rowsort
SELECT ALL + 80 + - col2 AS col0 FROM tab0 AS cor0
----
-2
47
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-810
SELECT ALL - 21 + + col0 DIV col1 + + 75 * - col1 AS col0 FROM tab0 AS cor0
----
-6471
-6846
-7296

skipif mysql # not compatible
query I rowsort label-810
SELECT ALL - 21 + + col0 / col1 + + 75 * - col1 AS col0 FROM tab0 AS cor0
----
-6471
-6846
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-811
SELECT DISTINCT - 67 DIV + col0 + + 97 FROM tab2 AS cor0
----
88
97

skipif mysql # not compatible
query I rowsort label-811
SELECT DISTINCT - 67 / + col0 + + 97 FROM tab2 AS cor0
----
88
97

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

query I rowsort
SELECT ALL 87 * + col0 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT DISTINCT + + 91 * col2 + + ( + col1 + + col2 ) AS col2 FROM tab0 AS cor0
----
189
3122
7635

query I rowsort
SELECT col2 * col0 - - 4 FROM tab2 AS cor0
----
193
2032
3006

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

query I rowsort
SELECT cor0.col2 + ( 43 * col1 ) FROM tab2 AS cor0
----
1360
2563
769

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - 89 col2 FROM tab2 AS cor0
----
1513
2759
5251

query I rowsort
SELECT ALL + - col2 + - 77 FROM tab0 AS cor0
----
-110
-159
-78

query I rowsort
SELECT + col2 * col0 + + 72 * - col1 AS col2 FROM tab1 AS cor0
----
-1710
2928
6744

query I rowsort
SELECT + col1 + - col1 * + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT + - col1 * col2 + - 53 FROM tab1 AS cor0
----
-1301
-1457
-623

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

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

query I rowsort
SELECT + cor1.col0 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

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

query I rowsort
SELECT ALL col1 + + 41 AS col2 FROM tab2 cor0
----
100
58
72

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * 57 + + col2 col2 FROM tab1 AS cor0
----
-117
-3591
-4464

query I rowsort
SELECT col1 + - col0 * + 79 AS col0 FROM tab2 AS cor0
----
-522
-6103
-6224

query I rowsort
SELECT DISTINCT - - col2 * 70 + col1 AS col0 FROM tab1 AS cor0
----
3806
4000
6733

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

query I rowsort
SELECT DISTINCT col0 * - col1 * + cor0.col1 + + col2 + - 79 AS col1 FROM tab2 AS cor0
----
-22872
-271571
-6779

onlyif mysql # use DIV operator for integer division
query I rowsort label-836
SELECT ALL col2 * col1 DIV col0 FROM tab0 AS cor0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-836
SELECT ALL col2 * col1 / col0 FROM tab0 AS cor0
----
118
2
83

query I rowsort
SELECT + col2 * 45 AS col2 FROM tab1 AS cor0
----
2430
2565
4320

query I rowsort
SELECT - tab1.col0 + + col1 * col2 + col1 FROM tab1
----
1181
1427
516

query I rowsort
SELECT ALL col1 + - col1 * + 93 FROM tab2
----
-1564
-2852
-5428

onlyif mysql # use DIV operator for integer division
query I rowsort label-840
SELECT DISTINCT + col0 * - col2 + tab0.col2 DIV col0 AS col1 FROM tab0
----
-35
-7298
-791

skipif mysql # not compatible
query I rowsort label-840
SELECT DISTINCT + col0 * - col2 + tab0.col2 / col0 AS col1 FROM tab0
----
-35
-7298
-791

onlyif mysql # use DIV operator for integer division
query I rowsort label-841
SELECT DISTINCT + - col1 + 37 DIV - ( + col0 + + ( 86 ) ) FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-841
SELECT DISTINCT + - col1 + 37 / - ( + col0 + + ( 86 ) ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - - col1 * + col0 + + 72 FROM tab1 AS cor0
----
1112
150
712

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

skipif mysql # not compatible
query I rowsort label-843
SELECT - col0 + + CAST ( col2 AS INTEGER ) + - col1 AS col2 FROM tab1 AS cor0
----
-17
25
3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-845
SELECT - col0 + - col2 DIV - col1 AS col0 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-845
SELECT - col0 + - col2 / - col1 AS col0 FROM tab2 AS cor0
----
-7
-77
-78

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-847
SELECT DISTINCT + col2 * + col1 DIV + col1 AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-847
SELECT DISTINCT + col2 * + col1 / + col1 AS col1 FROM tab1
----
54
57
96

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

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

query I rowsort
SELECT ALL col0 * - col0 + col0 + - tab0.col0 AS col1 FROM tab0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * - col1 col0 FROM tab1
----
-1000
-17576
-2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-851
SELECT DISTINCT col2 DIV col0 + - col2 + + tab2.col1 FROM tab2
----
-21
33
7

skipif mysql # not compatible
query I rowsort label-851
SELECT DISTINCT col2 / col0 + - col2 + + tab2.col1 FROM tab2
----
-21
33
7

query I rowsort
SELECT ALL col0 / + col0 + + tab0.col0 FROM tab0 WHERE NOT + col0 + - col2 * + col2 * col0 >= NULL
----

query I rowsort
SELECT + + col1 * - col2 - - ( 2 + + cor0.col2 ) FROM tab0 AS cor0
----
-2803
-7378
-94

query I rowsort
SELECT - col0 * tab0.col2 + - col2 + - col2 FROM tab0
----
-37
-7462
-858

query I rowsort
SELECT tab1.col2 * + col1 * col2 FROM tab1
----
119808
32490
75816

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

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

query I rowsort
SELECT DISTINCT - tab1.col2 + col0 * + col2 + - col1 * col0 FROM tab1
----
2951
30
6544

query I rowsort
SELECT DISTINCT col0 + col2 * col0 + - col1 * col2 * - col2 FROM tab1
----
127568
36202
75981

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col2 + col0 <> ( col2 * + col2 )
----

query I rowsort
SELECT col2 * - col1 * + col2 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT - col1 * - col0 * col1 AS col0 FROM tab1
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-862
SELECT + col1 DIV - col1 - - col2 * tab2.col0 FROM tab2
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-862
SELECT + col1 / - col1 - - col2 * tab2.col0 FROM tab2
----
188
2027
3001

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

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

query I rowsort
SELECT ALL - col0 * tab0.col2 * col1 AS col1 FROM tab0
----
-3395
-664118
-68112

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-866
SELECT DISTINCT tab2.col2 * - col2 + col0 DIV - tab2.col1 + + col2 AS col2 FROM tab2
----
-1410
-651
-702

skipif mysql # not compatible
query I rowsort label-866
SELECT DISTINCT tab2.col2 * - col2 + col0 / - tab2.col1 + + col2 AS col2 FROM tab2
----
-1410
-651
-702

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

query I rowsort
SELECT - + col0 + + col2 + + ( + 58 ) AS col0 FROM tab0 AS cor0
----
24
51
67

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

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

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

query I rowsort
SELECT - col2 * - cor0.col1 + + ( col2 ) * col2 + 95 AS col2 FROM tab1 AS cor0
----
10559
3914
4415

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

query I rowsort
SELECT + + col0 * + col2 * 69 + col2 + - col0 AS col1 FROM tab0 AS cor0
----
2381
503555
54657

query I rowsort
SELECT ALL - + cor0.col2 + + col1 + 18 * col0 FROM tab1 cor0
----
1105
1357
26

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

query I rowsort
SELECT DISTINCT + 62 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
62

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

query I rowsort
SELECT DISTINCT + col2 * col2 + - 60 * col2 AS col0 FROM tab0 AS cor0
----
-59
-891
1804

query I rowsort
SELECT ALL - 67 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 95c9eba643f6489e03be4d5e83f1ef99

onlyif mysql # use DIV operator for integer division
query I rowsort label-880
SELECT col1 + col2 + cor0.col0 * + cor0.col1 DIV + col1 FROM tab1 AS cor0
----
131
189
83

skipif mysql # not compatible
query I rowsort label-880
SELECT col1 + col2 + cor0.col0 * + cor0.col1 / + col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT ALL + 77 * col2 + + 64 * + col0 + - col1 AS col0 FROM tab0 AS cor0
----
11919
2220
3991

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-882
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-882
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - 50 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT ( - 26 ) AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 47d0574274146de273829785364ada39

query I rowsort
SELECT ALL tab1.col0 * 68 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 11e7210f9a25842b6563b24e624b5361

query I rowsort
SELECT DISTINCT - col2 * col2 + 74 AS col2 FROM tab2 AS cor0
----
-1370
-602
-655

query I rowsort
SELECT ALL 68 * col0 + - ( 56 ) - - col1 FROM tab2 AS cor0
----
451
5307
5333

query I rowsort
SELECT ALL - - 89 + col1 AS col0 FROM tab2 AS cor0
----
106
120
148

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

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

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

skipif mysql # not compatible
query I rowsort label-891
SELECT col1 + + cor0.col0 / + 58 AS col2 FROM tab2 AS cor0
----
18
31
60

query I rowsort
SELECT DISTINCT - cor0.col2 - col2 FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT + col0 * ( + 39 ) + - col2 AS col2 FROM tab0 AS cor0
----
1364
3389
903

query I rowsort
SELECT 45 + + cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to c646207615c2745ffbc171cd4ca4c906

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

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

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

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

query I rowsort
SELECT ALL col2 * 13 FROM tab0
----
1066
13
429

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

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

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

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

query I rowsort
SELECT col2 + + 72 AS col2 FROM tab2
----
110
98
99

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

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

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

query I rowsort
SELECT ( - 30 ) * - col0 + col2 FROM tab2
----
2366
237
2408

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

query I rowsort
SELECT DISTINCT col2 + 61 FROM tab2
----
87
88
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 86 + + ( cor0.col2 ) * - col2 col0 FROM tab1 AS cor0
----
-2830
-3163
-9130

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

query I rowsort
SELECT - 5 + col2 AS col2 FROM tab2 AS cor0
----
21
22
33

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

query I rowsort
SELECT ALL ( - col0 ) * + col2 + - 70 AS col0 FROM tab1 AS cor0
----
-232
-3718
-7750

query I rowsort
SELECT ALL ( 10 ) * col2 AS col1 FROM tab1 AS cor0
----
540
570
960

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

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

skipif mysql # not compatible
query I rowsort label-916
SELECT 33 + + col2 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

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

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

query I rowsort
SELECT 44 * + col0 - - 73 FROM tab0 AS cor0
----
1129
1613
3989

query I rowsort
SELECT + 24 * tab0.col0 FROM tab0
----
2136
576
840

query I rowsort
SELECT DISTINCT col0 * - 39 + col1 + - col1 FROM tab2 AS cor0
----
-273
-3042
-3081

query I rowsort
SELECT ALL + - col0 + - ( 91 ) AS col1 FROM tab1 AS cor0
----
-155
-171
-94

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

query I rowsort
SELECT - 36 * col2 FROM tab1
----
-1944
-2052
-3456

query I rowsort
SELECT DISTINCT col0 + tab2.col1 * tab2.col1 FROM tab2
----
3559
368
968

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

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

query I rowsort
SELECT + col2 + + ( 7 ) * col2 FROM tab0 cor0
----
264
656
8

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

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

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

skipif mysql # not compatible
query I rowsort label-930
SELECT col1 * col1 * - col0 + + col1 * + CAST ( col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-22185
-269984
-5890

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

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

query I rowsort
SELECT ALL - col0 + - 97 + col1 * col1 AS col2 FROM tab0
----
7275
8095
9277

query I rowsort
SELECT + cor0.col1 * col0 + - col2 * + cor0.col0 + + ( + col2 + col2 ) FROM tab2 AS cor0
----
-1583
2626
82

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

query I rowsort
SELECT ALL - 50 FROM tab0, tab0 AS cor0
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT + col2 * col0 + ( col0 * 92 + col2 * col2 ) FROM tab1
----
12785
24256
3354

query I rowsort
SELECT DISTINCT - col1 * col0 * 60 AS col2 FROM tab0
----
-123840
-203700
-485940

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-938
SELECT - CAST( NULL AS DECIMAL ) AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-938
SELECT - CAST ( NULL AS REAL ) AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-940
SELECT DISTINCT - ( tab0.col1 ) DIV - col1 col1 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-940
SELECT DISTINCT - ( tab0.col1 ) / - col1 col1 FROM tab0
----
1

query I rowsort
SELECT DISTINCT 55 * col1 AS col1 FROM tab0
----
4730
5005
5335

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

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

query I rowsort
SELECT - 4 - col1 * col1 AS col2 FROM tab2
----
-293
-3485
-965

query I rowsort
SELECT + cor0.col1 * col2 + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + col0 * col2 + + ( + col0 + col2 * 53 ) AS col2 FROM tab1 AS cor0
----
12848
3027
6733

query I rowsort
SELECT + 35 * + col0 AS col0 FROM tab2
----
245
2730
2765

query I rowsort
SELECT DISTINCT 80 + + col0 * col1 AS col1 FROM tab1 AS cor0
----
1120
158
720

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

query I rowsort
SELECT DISTINCT + 28 * col1 + col1 * + 75 AS col0 FROM tab1 AS cor0
----
1030
1339
2678

query I rowsort
SELECT DISTINCT + 60 * - col0 FROM tab1 AS cor0
----
-180
-3840
-4800

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

query I rowsort
SELECT ALL + + col0 + + cor0.col2 * col0 AS col1 FROM tab2 AS cor0
----
196
2106
3081

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

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

query I rowsort
SELECT + col0 * + 12 + col1 FROM tab0 AS cor0
----
1159
374
517

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col0 AS REAL ) + + col1 FROM tab1 AS cor0
----
-54
-67
23

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

query I rowsort
SELECT ALL - ( 60 ) + - col1 FROM tab0 AS cor0
----
-146
-151
-157

query I rowsort
SELECT DISTINCT + col1 * 76 + col2 FROM tab2 AS cor0
----
1330
2383
4510

query I rowsort
SELECT - col0 - - 62 * + col0 AS col0 FROM tab1 cor0
----
183
3904
4880

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-963
SELECT + col1 * - col2 + - col0 DIV col0 AS col1 FROM tab1 cor0
----
-1249
-1405
-571

skipif mysql # not compatible
query I rowsort label-963
SELECT + col1 * - col2 + - col0 / col0 AS col1 FROM tab1 cor0
----
-1249
-1405
-571

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-965
SELECT - + col1 * col0 + - CAST( 73 AS SIGNED ) AS col0 FROM tab0 cor0
----
-2137
-3468
-8172

skipif mysql # not compatible
query I rowsort label-965
SELECT - + col1 * col0 + - CAST ( 73 AS INTEGER ) AS col0 FROM tab0 cor0
----
-2137
-3468
-8172

query I rowsort
SELECT 16 * 40 AS col2 FROM tab1
----
640
640
640

query I rowsort
SELECT ALL col2 + - 34 AS col1 FROM tab0
----
-1
-33
48

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

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

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

query I rowsort
SELECT ALL + col1 * col0 + - 58 FROM tab0 AS cor0
----
2006
3337
8041

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

skipif mysql # not compatible
query I rowsort label-972
SELECT DISTINCT - col0 / - 96 FROM tab0 AS cor0
----
0

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-976
SELECT DISTINCT + col0 * + CAST( - 2 AS SIGNED ) AS col1 FROM tab1 cor0
----
-128
-160
-6

skipif mysql # not compatible
query I rowsort label-976
SELECT DISTINCT + col0 * + CAST ( - 2 AS INTEGER ) AS col1 FROM tab1 cor0
----
-128
-160
-6

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

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

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

query I rowsort
SELECT + col2 * ( 64 ) * col0 FROM tab1 AS cor0
----
10368
233472
491520

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col0 * col0 col2 FROM tab2 cor0
----
-6110
-6279
-76

query I rowsort
SELECT DISTINCT col1 + col0 * + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

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

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

query I rowsort
SELECT - 88 * 30 AS col1 FROM tab1 cor0
----
-2640
-2640
-2640

query I rowsort
SELECT + - 47 * - col1 AS col0 FROM tab0 AS cor0
----
4042
4277
4559

onlyif mysql # use DIV operator for integer division
query I rowsort label-987
SELECT DISTINCT col1 DIV + 6 FROM tab0
----
14
15
16

skipif mysql # not compatible
query I rowsort label-987
SELECT DISTINCT col1 / + 6 FROM tab0
----
14
15
16

query I rowsort
SELECT ALL col0 * 69 AS col2 FROM tab1
----
207
4416
5520

onlyif mysql # use DIV operator for integer division
query I rowsort label-989
SELECT DISTINCT col1 DIV 84 AS col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-989
SELECT DISTINCT col1 / 84 AS col1 FROM tab1
----
0

query I rowsort
SELECT ALL + ( - 5 + - tab1.col0 ) AS col1 FROM tab1
----
-69
-8
-85

query I rowsort
SELECT 3 * - col1 AS col0 FROM tab0
----
-258
-273
-291

query I rowsort
SELECT ( 45 * col1 ) FROM tab0
----
3870
4095
4365

query I rowsort
SELECT 13 * - col0 AS col2 FROM tab2 AS cor0
----
-1014
-1027
-91

query I rowsort
SELECT + - col1 * 87 FROM tab2 AS cor0
----
-1479
-2697
-5133

query I rowsort
SELECT col2 + + col0 * + col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT 35 - 84 FROM tab2 AS cor0
----
-49
-49
-49

query I rowsort
SELECT 28 + + col0 * col0 AS col0 FROM tab0 AS cor0
----
1253
604
7949

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

skipif mysql # not compatible
query I rowsort label-998
SELECT ALL - tab1.col2 / - col2 AS col1 FROM tab1
----
1
1
1

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

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

query I rowsort
SELECT ALL - - 80 * cor0.col2 + col0 FROM tab2 AS cor0
----
2158
2167
3119

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1003
SELECT 97 * + col1 DIV col1 + - 94 FROM tab0 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-1003
SELECT 97 * + col1 / col1 + - 94 FROM tab0 AS cor0
----
3
3
3

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

query I rowsort
SELECT ALL + col1 + + col2 * 27 FROM tab2 AS cor0
----
1043
760
761

query I rowsort
SELECT - 59 * col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-174
-3712
-4640

query I rowsort
SELECT DISTINCT 19 * col0 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT - cor1.col1 * + cor0.col2 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9248dc8e2a9503d5bb41eb88b96ebec3

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

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

query I rowsort
SELECT - col0 + 17 FROM tab2 AS cor0
----
-61
-62
10

query I rowsort
SELECT DISTINCT - col1 * tab1.col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - - ( + 79 ) FROM tab1 cor0
----
79
79
79

query I rowsort
SELECT - col1 - - 38 AS col0 FROM tab1 cor0
----
12
25
28

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

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

query I rowsort
SELECT - col2 + col1 * col0 * 38 AS col2 FROM tab0
----
129009
307680
78399

query I rowsort
SELECT - ( cor0.col2 ) * + col2 * 40 + cor0.col1 AS col1 FROM tab1 AS cor0
----
-116614
-129950
-368627

query I rowsort
SELECT - ( - col0 ) * 98 * 47 FROM tab1 AS cor0
----
13818
294784
368480

onlyif mysql # use DIV operator for integer division
query I rowsort label-1019
SELECT + col2 + - col2 * cor0.col2 DIV - col0 FROM tab2 cor0
----
131
34
56

skipif mysql # not compatible
query I rowsort label-1019
SELECT + col2 + - col2 * cor0.col2 / - col0 FROM tab2 cor0
----
131
34
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-1020
SELECT ALL + col2 * + col2 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1020
SELECT ALL + col2 * + col2 / cor0.col2 AS col1 FROM tab1 AS cor0
----
54
57
96

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1025
SELECT - CAST( NULL AS DECIMAL ) * 13 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1025
SELECT - CAST ( NULL AS REAL ) * 13 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

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

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

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

query I rowsort
SELECT tab0.col1 * - 3 FROM tab0
----
-258
-273
-291

onlyif mysql # use DIV operator for integer division
query I rowsort label-1030
SELECT + ( cor0.col0 ) - - cor0.col0 * 21 DIV 39 FROM tab2 AS cor0
----
10
120
121

skipif mysql # not compatible
query I rowsort label-1030
SELECT + ( cor0.col0 ) - - cor0.col0 * 21 / 39 FROM tab2 AS cor0
----
10
120
121

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

query I rowsort
SELECT col0 * 45 FROM tab0 AS cor0
----
1080
1575
4005

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

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

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

query I rowsort
SELECT - 47 * + 83 - col1 * 95 AS col0 FROM tab2 AS cor0
----
-5516
-6846
-9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1036
SELECT DISTINCT - CAST( - col0 AS SIGNED ) * col0 + col2 * 46 AS col2 FROM tab2 AS cor0
----
1291
7280
7989

skipif mysql # not compatible
query I rowsort label-1036
SELECT DISTINCT - CAST ( - col0 AS INTEGER ) * col0 + col2 * 46 AS col2 FROM tab2 AS cor0
----
1291
7280
7989

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 17 col0 FROM tab0 AS cor0
----
1513
408
595

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

skipif mysql # not compatible
query I rowsort label-1038
SELECT ALL - CAST ( + col0 AS INTEGER ) + - col0 FROM tab1 cor0
----
-128
-160
-6

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

query I rowsort
SELECT ALL ( - col2 ) * - col2 + 8 FROM tab2 AS cor0
----
1452
684
737

onlyif mysql # use DIV operator for integer division
query I rowsort label-1041
SELECT ALL - col1 + - col2 DIV col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1041
SELECT ALL - col1 + - col2 / col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + 50 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT ALL + ( + cor0.col2 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + 82 * col0 * col1 FROM tab2 AS cor0
----
110126
17794
377364

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 52 * 77 col2 FROM tab1 AS cor0
----
4004
4004
4004

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

query I rowsort
SELECT DISTINCT + ( + col2 ) * + col0 - col2 AS col2 FROM tab1
----
108
3591
7584

query I rowsort
SELECT ALL - cor0.col1 + col0 * ( cor0.col2 + + cor0.col2 ) AS col1 FROM tab2 AS cor0
----
347
3997
5987

onlyif mysql # use DIV operator for integer division
query I rowsort label-1050
SELECT + col2 * - cor0.col2 + col1 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-1050
SELECT + col2 * - cor0.col2 + col1 / cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-1051
SELECT DISTINCT - 46 DIV col0 FROM tab2 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-1051
SELECT DISTINCT - 46 / col0 FROM tab2 AS cor0
----
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 93 + - cor0.col0 * col1 col1 FROM tab2 AS cor0
----
-1436
-310
-4695

query I rowsort
SELECT DISTINCT - 52 * + col2 FROM tab2 cor0
----
-1352
-1404
-1976

query I rowsort
SELECT - + 2 + col0 AS col0 FROM tab0 AS cor0
----
22
33
87

query I rowsort
SELECT ALL col1 + + 2 AS col2 FROM tab2
----
19
33
61

query I rowsort
SELECT ALL - 99 * col1 + col2 AS col2 FROM tab2
----
-1645
-3042
-5815

query I rowsort
SELECT col0 + 70 * col1 * + ( col2 ) + - col1 FROM tab1
----
39954
87427
98257

query I rowsort
SELECT ALL + 41 * - col2 - tab0.col2 FROM tab0
----
-1386
-3444
-42

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

query I rowsort
SELECT DISTINCT + 35 - - ( col1 ) FROM tab1
----
45
48
61

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

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

query I rowsort
SELECT DISTINCT + - col0 * - col0 + - ( - col0 + - 2 ) * 11 AS col0 FROM tab2 AS cor0
----
148
6964
7132

query I rowsort
SELECT + col2 * cor0.col1 * 9 AS col1 FROM tab1 AS cor0
----
11232
12636
5130

query I rowsort
SELECT ALL col1 * + 13 FROM tab1 AS cor0
----
130
169
338

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1066
SELECT ALL - + col2 * CAST( 10 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-260
-270
-380

skipif mysql # not compatible
query I rowsort label-1066
SELECT ALL - + col2 * CAST ( 10 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-260
-270
-380

query I rowsort
SELECT ALL - col2 + col0 + - col2 FROM tab2
----
-47
26
3

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

query I rowsort
SELECT - col2 * - col1 * + cor0.col2 FROM tab1 AS cor0
----
119808
32490
75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 97 * col0 col1 FROM tab2 AS cor0
----
710
7625
7680

query I rowsort
SELECT col0 * + 22 * col2 AS col0 FROM tab1 AS cor0
----
168960
3564
80256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 + + 25 col1 FROM tab2
----
-34
-6
8

query I rowsort
SELECT DISTINCT - tab1.col1 + + 8 FROM tab2, tab0, tab0 AS cor0, tab1
----
-18
-2
-5

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

query I rowsort
SELECT ALL - 37 + + col1 FROM tab0 cor0
----
49
54
60

query I rowsort
SELECT + - cor0.col1 * col1 + + col2 * + col0 FROM tab1 AS cor0
----
-514
3548
7511

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

query I rowsort
SELECT ALL 40 + col2 * - col2 AS col2 FROM tab0 AS cor0
----
-1049
-6684
39

query I rowsort
SELECT DISTINCT + 33 * col1 AS col1 FROM tab1 AS cor0
----
330
429
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-1080
SELECT - col1 DIV + 80 + - col1 col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1080
SELECT - col1 / + 80 + - col1 col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col1 * - 96 + - 47 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1696
-3054
-5770

query I rowsort
SELECT + col1 * 8 * col2 - col2 AS col1 FROM tab2 AS cor0
----
12246
5130
6669

query I rowsort
SELECT DISTINCT - col0 + col2 * col2 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT ALL + - col0 + 95 AS col0 FROM tab1 AS cor0
----
15
31
92

query I rowsort
SELECT DISTINCT + col0 * col0 + - ( + cor0.col0 ) * ( - cor0.col1 * cor0.col2 + col2 ) AS col1 FROM tab2 AS cor0
----
123708
54273
5719

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

query I rowsort
SELECT col2 + + col1 + + col1 FROM tab1
----
106
122
77

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

query I rowsort
SELECT - col2 - 97 * 9 AS col0 FROM tab0 AS cor0
----
-874
-906
-955

query I rowsort
SELECT DISTINCT + + ( ( - col2 ) ) * - col0 + col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT ALL + + 37 + - col0 - - col1 FROM tab0 AS cor0
----
39
99
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 51 col0 FROM tab1 AS cor0
----
-13
-29
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1093
SELECT ALL - CAST( 80 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
2080
2160
3040

skipif mysql # not compatible
query I rowsort label-1093
SELECT ALL - CAST ( 80 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
2080
2160
3040

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 9 * 23 col1 FROM tab2 AS cor0
----
207

onlyif mysql # use DIV operator for integer division
query I rowsort label-1096
SELECT + 46 DIV - col2 + + col2 AS col2 FROM tab0 AS cor0
----
-45
32
82

skipif mysql # not compatible
query I rowsort label-1096
SELECT + 46 / - col2 + + col2 AS col2 FROM tab0 AS cor0
----
-45
32
82

query I rowsort
SELECT - - col0 + 21 * + col2 + - ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1083
1204
2000

query I rowsort
SELECT ALL + - col2 + col2 * col2 FROM tab0 AS cor0
----
0
1056
6642

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1102
SELECT DISTINCT - + col1 DIV - col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-1102
SELECT DISTINCT - + col1 / - col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT DISTINCT - col1 * - 93 + + col0 AS col2 FROM tab1 AS cor0
----
1289
2421
994

query I rowsort
SELECT ALL + - col1 * 6 + col2 FROM tab1 AS cor0
----
-102
-3
18

query I rowsort
SELECT ALL col1 + + col2 - - col1 * col0 AS col0 FROM tab2 AS cor0
----
1398
275
4687

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

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

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

query I rowsort
SELECT + col2 + cor0.col0 * col2 * - col0 FROM tab2 AS cor0
----
-1296
-158158
-237120

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

query I rowsort
SELECT ALL + ( + 68 * col2 ) AS col1 FROM tab0
----
2244
5576
68

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

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

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

query I rowsort
SELECT + 2 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

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

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

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

query I rowsort
SELECT + 52 * col1 FROM tab2
----
1612
3068
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-1118
SELECT + 18 DIV col1 + - col2 * + col1 AS col1 FROM tab2
----
-1534
-645
-837

skipif mysql # not compatible
query I rowsort label-1118
SELECT + 18 / col1 + - col2 * + col1 AS col1 FROM tab2
----
-1534
-645
-837

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

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

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-1122
SELECT ALL + col2 * + col2 DIV + col2 FROM tab0 AS cor0
----
1
33
82

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

query I rowsort
SELECT ( col0 ) + + col0 - - col0 AS col2 FROM tab1 AS cor0
----
192
240
9

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

query I rowsort
SELECT ALL + 7 + col0 AS col0 FROM tab2 AS cor0
----
14
85
86

query I rowsort
SELECT + - col2 * - col1 + + col2 * + 62 AS col1 FROM tab0 AS cor0
----
12546
159
4884

query I rowsort
SELECT - + ( col1 ) + col2 - + col1 FROM tab0 AS cor0
----
-100
-139
-193

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

query I rowsort
SELECT + 37 * 2 AS col0 FROM tab0 AS cor0
----
74
74
74

query I rowsort
SELECT ( 17 ) * + col1 FROM tab0 cor0
----
1462
1547
1649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col0 ) col0 FROM tab0 AS cor0
----
-24
-35
-89

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1133
SELECT ALL - CAST( - 49 AS SIGNED ) FROM tab0 AS cor0
----
49
49
49

skipif mysql # not compatible
query I rowsort label-1133
SELECT ALL - CAST ( - 49 AS INTEGER ) FROM tab0 AS cor0
----
49
49
49

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

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

query I rowsort
SELECT ALL - - 12 + col0 AS col0 FROM tab2 AS cor0
----
19
90
91

query I rowsort
SELECT + - 27 * - col1 * col2 FROM tab1 AS cor0
----
15390
33696
37908

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

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

query I rowsort
SELECT 6 + col2 * col2 FROM tab0 AS cor0
----
1095
6730
7

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

query I rowsort
SELECT 22 + col0 * - tab0.col2 FROM tab0
----
-13
-7276
-770

onlyif mysql # use DIV operator for integer division
query I rowsort label-1143
SELECT DISTINCT ( + col0 + col2 ) DIV + tab1.col2 AS col0 FROM tab1
----
1
2

skipif mysql # not compatible
query I rowsort label-1143
SELECT DISTINCT ( + col0 + col2 ) / + tab1.col2 AS col0 FROM tab1
----
1
2

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

query I rowsort
SELECT + 76 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT ALL - + col1 * 9 FROM tab2 cor0
----
-153
-279
-531

query I rowsort
SELECT - col0 * col0 + col1 * col1 FROM tab0
----
360
6820
8184

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

skipif mysql # not compatible
query I rowsort label-1148
SELECT DISTINCT col2 / - tab0.col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT - col0 * + col2 * col2 + - col2 * 7 FROM tab0
----
-26367
-42
-599010

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

skipif mysql # not compatible
query I rowsort label-1150
SELECT DISTINCT - col1 / - col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT - col2 * cor0.col0 * + 50 AS col1 FROM tab0 AS cor0
----
-1750
-364900
-39600

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1153
SELECT ALL col0 DIV ( 30 ) AS col1 FROM tab2 cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-1153
SELECT ALL col0 / ( 30 ) AS col1 FROM tab2 cor0
----
0
2
2

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

query I rowsort
SELECT DISTINCT + - col1 + 42 * col0 * col0 AS col0 FROM tab1 AS cor0
----
172022
268787
352

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1157
SELECT DISTINCT col1 DIV col1 + - 88 + col0 AS col2 FROM tab2 AS cor0
----
-8
-80
-9

skipif mysql # not compatible
query I rowsort label-1157
SELECT DISTINCT col1 / col1 + - 88 + col0 AS col2 FROM tab2 AS cor0
----
-8
-80
-9

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

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

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

query I rowsort
SELECT DISTINCT - 72 * cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
-20808
-250632
-69192

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1165
SELECT ALL 55 + + col1 DIV 65 FROM tab2 AS cor0
----
55
55
55

skipif mysql # not compatible
query I rowsort label-1165
SELECT ALL 55 + + col1 / 65 FROM tab2 AS cor0
----
55
55
55

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

query I rowsort
SELECT - 50 * - col1 FROM tab1
----
1300
500
650

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

query I rowsort
SELECT - 56 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

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

query I rowsort
SELECT DISTINCT - 5 * - col0 FROM tab2 cor0
----
35
390
395

query I rowsort
SELECT ALL - col2 * - 23 * 56 FROM tab2 AS cor0
----
33488
34776
48944

query I rowsort
SELECT ALL col1 * + col0 + - ( col1 ) + - col2 AS col0 FROM tab0 AS cor0
----
1945
3297
7926

query I rowsort
SELECT ALL + col2 + + 98 FROM tab1 cor0
----
152
155
194

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 25 col2 FROM tab2 AS cor0
----
-650
-675
-950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1177
SELECT DISTINCT + col2 - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-1177
SELECT DISTINCT + col2 - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + col0 * 90 * + ( col2 ) + - 72 FROM tab1 AS cor0
----
14508
328248
691128

query I rowsort
SELECT ALL - col0 * + 10 + - col2 + col1 FROM tab1 AS cor0
----
-58
-687
-883

query I rowsort
SELECT ALL - col2 * - 35 - + col1 FROM tab0 AS cor0
----
-62
1069
2779

onlyif mysql # use DIV operator for integer division
query I rowsort label-1181
SELECT DISTINCT col2 * + col0 DIV - col0 - + col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

skipif mysql # not compatible
query I rowsort label-1181
SELECT DISTINCT col2 * + col0 / - col0 - + col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - 0 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT + 35 * + col2 AS col0 FROM tab1
----
1890
1995
3360

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

query I rowsort
SELECT ALL 58 + + col1 FROM tab1
----
68
71
84

query I rowsort
SELECT ALL - col0 * + col0 + col1 FROM tab1
----
-4086
-6387
17

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1188
SELECT + col1 + + col1 DIV CAST( 93 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1188
SELECT + col1 + + col1 / CAST ( 93 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
10
13
26

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

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

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

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

query I rowsort
SELECT - 89 * col0 FROM tab0 cor0
----
-2136
-3115
-7921

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

query I rowsort
SELECT DISTINCT 13 + - col0 FROM tab0 AS cor0
----
-11
-22
-76

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

query I rowsort
SELECT col1 * - tab1.col0 + col2 * + col1 * col2 AS col2 FROM tab1
----
118768
31850
75738

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1200
SELECT - col2 + - col2 DIV - col0 FROM tab1
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-1200
SELECT - col2 + - col2 / - col0 FROM tab1
----
-36
-57
-95

query I rowsort
SELECT ALL - col2 * col2 + - tab0.col0 FROM tab0
----
-1113
-36
-6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-1202
SELECT DISTINCT - col1 * col2 * + col1 + - col0 DIV - tab1.col1 FROM tab1
----
-16218
-36504
-5694

skipif mysql # not compatible
query I rowsort label-1202
SELECT DISTINCT - col1 * col2 * + col1 + - col0 / - tab1.col1 FROM tab1
----
-16218
-36504
-5694

query I rowsort
SELECT - col0 + - col0 * + col0 + - col1 AS col0 FROM tab0 WHERE NOT ( NULL ) > NULL
----

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

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL NOT IN ( + col0 )
----

query I rowsort
SELECT ALL + col0 * col0 * col0 FROM tab2 AS cor0
----
343
474552
493039

query I rowsort
SELECT + col1 * - col1 + tab1.col1 * col0 AS col0 FROM tab1
----
-598
540
871

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

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

query I rowsort
SELECT DISTINCT - col2 * - tab2.col2 + - col1 FROM tab2
----
1427
617
698

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col2 BETWEEN NULL AND ( + col1 )
----

query I rowsort
SELECT ALL + col1 * col0 + tab2.col1 * + col1 AS col0 FROM tab2
----
1178
1632
8083

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

query I rowsort
SELECT ALL tab0.col0 * col0 + col2 * col2 AS col2 FROM tab0
----
1226
14645
1665

query I rowsort
SELECT ALL - col0 + col1 * col0 FROM tab0
----
2040
3360
8010

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1217
SELECT - col1 / + col2 col0 FROM tab0
----
-1
-2
-97

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

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

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

query I rowsort
SELECT col2 * + col1 + col1 AS col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT - col2 AS col0 FROM tab2 WHERE + col2 + - col1 > + col1
----
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1223
SELECT ALL + col0 DIV + col0 + col0 DIV - col2 + - col1 FROM tab0
----
-131
-85
-91

skipif mysql # not compatible
query I rowsort label-1223
SELECT ALL + col0 / + col0 + col0 / - col2 + - col1 FROM tab0
----
-131
-85
-91

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

query I rowsort
SELECT DISTINCT col1 + col1 * col2 + col2 FROM tab0
----
195
2957
7635

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1226
SELECT + col0 / tab2.col1 col0 FROM tab2
----
0
1
4

query I rowsort
SELECT DISTINCT - ( col1 * col1 ) FROM tab1
----
-100
-169
-676

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

query I rowsort
SELECT ( - 90 + col2 ) AS col1 FROM tab2
----
-52
-63
-64

query I rowsort
SELECT + col0 + - 57 AS col1 FROM tab2 AS cor0
----
-50
21
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1231
SELECT - + CAST( 14 AS SIGNED ) + col0 FROM tab2 AS cor0
----
-7
64
65

skipif mysql # not compatible
query I rowsort label-1231
SELECT - + CAST ( 14 AS INTEGER ) + col0 FROM tab2 AS cor0
----
-7
64
65

query I rowsort
SELECT + - ( + 89 ) + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-102
-115
-99

query I rowsort
SELECT - ( col2 ) + - 36 FROM tab1 AS cor0
----
-132
-90
-93

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
1
33
82

query I rowsort
SELECT col0 * - 51 FROM tab2
----
-357
-3978
-4029

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

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

query I rowsort
SELECT + 76 * col2 + 60 AS col2 FROM tab1 cor0
----
4164
4392
7356

onlyif mysql # use DIV operator for integer division
query I rowsort label-1240
SELECT - + col2 + ( col2 + col0 ) DIV + 4 AS col2 FROM tab2 cor0
----
-19
-9
0

skipif mysql # not compatible
query I rowsort label-1240
SELECT - + col2 + ( col2 + col0 ) / + 4 AS col2 FROM tab2 cor0
----
-19
-9
0

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

query I rowsort
SELECT ALL 40 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

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

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

query I rowsort
SELECT + col1 * - 53 AS col0 FROM tab1 AS cor0
----
-1378
-530
-689

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

query I rowsort
SELECT col1 * - col1 - col0 FROM tab2 AS cor0
----
-3559
-368
-968

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

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

query I rowsort
SELECT - 44 - + 71 FROM tab1 AS cor0
----
-115
-115
-115

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

query I rowsort
SELECT + 74 + cor0.col0 FROM tab1 AS cor0
----
138
154
77

query I rowsort
SELECT - 15 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1252
SELECT - - col2 + + col0 * CAST( col0 AS SIGNED ) col0 FROM tab0 AS cor0
----
1226
609
8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1252
SELECT - - col2 + + col0 * CAST ( col0 AS INTEGER ) col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT 68 * + col0 FROM tab0 cor0
----
1632
2380
6052

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

query I rowsort
SELECT DISTINCT - 1 * cor0.col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - 24 + col2 * + cor0.col0 + col2 FROM tab2 AS cor0
----
192
2030
3016

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

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

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

query I rowsort
SELECT ALL + col0 - + col1 * ( - 68 ) FROM tab0 AS cor0
----
5872
6277
6631

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1260
SELECT - + col2 + - col0 * + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-36
-7380
-825

skipif mysql # not compatible
query I rowsort label-1260
SELECT - + col2 + - col0 * + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT ALL col2 - - col0 * 21 FROM tab1 AS cor0
----
117
1401
1776

query I rowsort
SELECT DISTINCT + - col0 * + 84 AS col2 FROM tab2 AS cor0
----
-588
-6552
-6636

query I rowsort
SELECT - cor0.col1 + + 57 * + col2 FROM tab1 AS cor0
----
3052
3239
5459

query I rowsort
SELECT - col0 + 41 * 78 - col2 FROM tab2 cor0
----
3081
3094
3164

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1266
SELECT DISTINCT - col2 DIV col2 - 69 AS col0 FROM tab0 AS cor0
----
-70

skipif mysql # not compatible
query I rowsort label-1266
SELECT DISTINCT - col2 / col2 - 69 AS col0 FROM tab0 AS cor0
----
-70

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

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

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

query I rowsort
SELECT + col0 * - col2 - col2 AS col0 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT col2 + - tab1.col1 * - ( - col0 + + col2 ) * + tab1.col0 FROM tab1
----
-4423
16736
4032

query I rowsort
SELECT - 70 + col1 AS col2 FROM tab2 AS cor0
----
-11
-39
-53

query I rowsort
SELECT DISTINCT - ( 13 ) AS col0 FROM tab0 AS cor0
----
-13

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

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

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

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

query I rowsort
SELECT ALL + 55 * col0 AS col0 FROM tab2
----
385
4290
4345

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

skipif mysql # not compatible
query I rowsort label-1276
SELECT ALL CAST ( NULL AS INTEGER ) * 20 + + col1 FROM tab1
----
NULL
NULL
NULL

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

query I rowsort
SELECT - 39 * col1 FROM tab2 AS cor0
----
-1209
-2301
-663

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

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

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

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

query I rowsort
SELECT + 65 + 81 FROM tab2
----
146
146
146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

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

query I rowsort
SELECT col1 * + col1 * tab2.col0 + - col0 FROM tab2
----
22752
271440
6720

query I rowsort
SELECT DISTINCT - 64 * - col1 AS col2 FROM tab2
----
1088
1984
3776

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

query I rowsort
SELECT DISTINCT + 70 * col2 AS col1 FROM tab2 AS cor0
----
1820
1890
2660

query I rowsort
SELECT cor0.col2 * + 4 FROM tab2, tab2 AS cor0
----
9 values hashing to 315f93d11152c2cf40009a8d4d7c678c

query I rowsort
SELECT DISTINCT + 50 * col0 + col0 AS col2 FROM tab2 AS cor0
----
357
3978
4029

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

skipif mysql # not compatible
query I rowsort label-1292
SELECT col2 * CAST ( col2 AS INTEGER ) + col1 AS col0 FROM tab2
----
1461
735
760

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

skipif mysql # not compatible
query I rowsort label-1293
SELECT DISTINCT tab0.col1 + CAST ( + col2 AS INTEGER ) * + col1 FROM tab0
----
194
2924
7553

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

skipif mysql # not compatible
query I rowsort label-1294
SELECT ALL + col1 - CAST ( - col2 AS INTEGER ) AS col1 FROM tab0
----
119
173
98

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

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

query I rowsort
SELECT cor0.col0 * col1 + - 15 AS col2 FROM tab0 AS cor0
----
2049
3380
8084

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 70 col0 FROM tab2 AS cor0
----
108
96
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1300
SELECT ALL + col0 * CAST( ( + col1 ) * 49 AS SIGNED ) + - col2 AS col1 FROM tab1
----
31303
3768
50864

skipif mysql # not compatible
query I rowsort label-1300
SELECT ALL + col0 * CAST ( ( + col1 ) * 49 AS INTEGER ) + - col2 AS col1 FROM tab1
----
31303
3768
50864

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

skipif mysql # not compatible
query I rowsort label-1301
SELECT - col0 / 63 + + cor0.col0 / + cor0.col2 AS col1 FROM tab0 AS cor0
----
0
0
35

query I rowsort
SELECT DISTINCT + 70 + + 78 FROM tab1 AS cor0
----
148

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col0 * col1 * col2 col0 FROM tab2 cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 85 + 63 col2 FROM tab1 AS cor0
----
148
148
148

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

query I rowsort
SELECT - + ( + 63 ) * col2 + 11 + 96 FROM tab2 AS cor0
----
-1531
-1594
-2287

query I rowsort
SELECT + - col1 * - col2 + + col0 + 8 FROM tab1 cor0
----
1336
1415
642

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

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 + col0 * - 77 AS col2 FROM tab1 AS cor0
----
-309
-5568
-7200

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1312
SELECT ALL - col1 DIV + ( - cor0.col0 + 53 ) AS col0 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-1312
SELECT ALL - col1 / + ( - cor0.col0 + 53 ) AS col0 FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 86 + col2 col1 FROM tab1 AS cor0
----
140
143
182

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

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

query I rowsort
SELECT DISTINCT + + 51 + + 36 * col1 FROM tab2 cor0
----
1167
2175
663

onlyif mysql # use DIV operator for integer division
query I rowsort label-1316
SELECT ALL 12 + col2 DIV + col0 + ( col0 * - cor0.col0 ) FROM tab2 AS cor0
----
-34
-6072
-6229

skipif mysql # not compatible
query I rowsort label-1316
SELECT ALL 12 + col2 / + col0 + ( col0 * - cor0.col0 ) FROM tab2 AS cor0
----
-34
-6072
-6229

onlyif mysql # use DIV operator for integer division
query I rowsort label-1317
SELECT DISTINCT col1 - 70 DIV 52 AS col1 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-1317
SELECT DISTINCT col1 - 70 / 52 AS col1 FROM tab2
----
16
30
58

query I rowsort
SELECT DISTINCT + 76 + + 82 + + col2 FROM tab1 AS cor0
----
212
215
254

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

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

query I rowsort
SELECT - - 66 AS col1 FROM tab1 AS cor0
----
66
66
66

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 16 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab2, tab2 cor2
----
-16

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

query I rowsort
SELECT + 17 AS col0 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to 71801088bb30ca6eac036729ebfbbace

query I rowsort
SELECT 82 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

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

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

query I rowsort
SELECT + 3 * tab2.col2 AS col1 FROM tab2
----
114
78
81

query I rowsort
SELECT - 81 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query I rowsort
SELECT + col2 * col2 * col0 AS col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - col1 * + col1 + 95 * 14 AS col2 FROM tab0 cor0
----
-6066
-6951
-8079

query I rowsort
SELECT - col2 * cor0.col1 * 26 + - col2 + col0 FROM tab0 AS cor0
----
-194005
-2488
-73797

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( ( - col1 ) ) + 60 * 90 + + col2 * - 7 col2 FROM tab2
----
5117
5159
5180

query I rowsort
SELECT tab0.col0 * + col0 + - tab0.col2 * - 18 + + col1 AS col1 FROM tab0
----
1256
1340
9488

query I rowsort
SELECT DISTINCT - tab2.col1 + 91 AS col2 FROM tab2
----
32
60
74

query I rowsort
SELECT + 70 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT ALL - col0 * col0 * 75 AS col0 FROM tab2
----
-3675
-456300
-468075

query I rowsort
SELECT DISTINCT + 6 AS col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
6

query I rowsort
SELECT ALL + ( - 92 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT - - 21 + col0 AS col1 FROM tab0 cor0
----
110
45
56

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

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

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

query I rowsort
SELECT DISTINCT - 25 AS col2 FROM tab1 cor0
----
-25

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

query I rowsort
SELECT - - col1 + - col1 * 27 FROM tab1 AS cor0
----
-260
-338
-676

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

query I rowsort
SELECT DISTINCT 32 + - col0 FROM tab1 AS cor0
----
-32
-48
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-1352
SELECT ALL 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-1352
SELECT ALL tab2.col2 / col1 col2 FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT ( cor0.col1 ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT ALL - cor0.col0 * + col0 * - cor0.col0 FROM tab1 AS cor0
----
262144
27
512000

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * col0 + - col1 + col2 * + 55 * cor0.col1 col1 FROM tab0 AS cor0
----
1147328
333508
334553

onlyif mysql # use DIV operator for integer division
query I rowsort label-1357
SELECT DISTINCT + + col2 + ( - col0 ) + col0 DIV ( col1 + - col0 ) FROM tab2 AS cor0
----
-42
-56
20

skipif mysql # not compatible
query I rowsort label-1357
SELECT DISTINCT + + col2 + ( - col0 ) + col0 / ( col1 + - col0 ) FROM tab2 AS cor0
----
-42
-56
20

query I rowsort
SELECT + col2 * - 8 + - col0 + cor0.col0 FROM tab0 AS cor0
----
-264
-656
-8

query I rowsort
SELECT + col0 * 65 AS col0 FROM tab1 cor0
----
195
4160
5200

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1364
SELECT - + CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-1364
SELECT - + CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

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

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

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

query I rowsort
SELECT + 21 + + col0 FROM tab1 AS cor0
----
101
24
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1368
SELECT + col1 + col0 DIV - ( col0 ) col0 FROM tab2 AS cor0
----
16
30
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1368
SELECT + col1 + col0 / - ( col0 ) col0 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT 99 + col1 AS col2 FROM tab0 AS cor0
----
185
190
196

query I rowsort
SELECT + 36 + + col0 FROM tab2 AS cor0
----
114
115
43

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

query I rowsort
SELECT + 71 * - col0 + - col0 FROM tab0
----
-1728
-2520
-6408

query I rowsort
SELECT DISTINCT col0 + + 48 FROM tab0
----
137
72
83

query I rowsort
SELECT ALL col2 * 99 + 75 FROM tab2
----
2649
2748
3837

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

skipif mysql # not compatible
query I rowsort label-1375
SELECT col2 / - 94 AS col0 FROM tab0 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT ALL col1 + - 59 FROM tab2
----
-28
-42
0

query I rowsort
SELECT ALL ( col0 ) + + col0 * ( 22 ) FROM tab2 AS cor0
----
161
1794
1817

query I rowsort
SELECT DISTINCT - - 5 + 77 FROM tab1 AS cor0
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1380
SELECT + - col0 + col1 DIV col2 col2 FROM tab0 AS cor0
----
-22
-88
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1380
SELECT + - col0 + col1 / col2 col2 FROM tab0 AS cor0
----
-22
-88
62

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

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

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

query I rowsort
SELECT ALL - + ( + col0 ) * col2 + - ( - 75 ) FROM tab1 AS cor0
----
-3573
-7605
-87

query I rowsort
SELECT DISTINCT - 31 + ( - cor0.col2 ) AS col2 FROM tab0 AS cor0
----
-113
-32
-64

query I rowsort
SELECT ALL + 30 * - col2 AS col0 FROM tab0 AS cor0
----
-2460
-30
-990

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

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

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

query I rowsort
SELECT DISTINCT 14 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1548
660
851

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

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

query I rowsort
SELECT ALL + + 42 + col1 FROM tab0 AS cor0
----
128
133
139

query I rowsort
SELECT DISTINCT + col2 * col2 + col2 + ( - col2 ) FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT + + 77 * + cor0.col0 AS col2 FROM tab0 cor0
----
1848
2695
6853

query I rowsort
SELECT ALL - 27 * - col1 FROM tab1 cor0
----
270
351
702

query I rowsort
SELECT DISTINCT - col2 * - col1 + - 84 * 11 * tab0.col2 FROM tab0
----
-27654
-68306
-827

query I rowsort
SELECT - tab1.col1 + col0 * - col2 + - col0 AS col2 FROM tab1
----
-191
-3722
-7773

query I rowsort
SELECT - 65 * col0 + col1 FROM tab2 AS cor0
----
-424
-5011
-5118

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

skipif mysql # not compatible
query I rowsort label-1398
SELECT ALL col0 / - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + + 47 AS col2 FROM tab2 AS cor0
----
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 15 * col1 + cor0.col2 col2 FROM tab2 AS cor0
----
293
492
911

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

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

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

query I rowsort
SELECT 51 + col2 AS col1 FROM tab1 AS cor0
----
105
108
147

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

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

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

query I rowsort
SELECT 9 * ( cor0.col2 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 443e87dcdcb61f29c7ca3ce0be4e83d5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1409
SELECT ALL - col0 DIV - 27 FROM tab0 cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-1409
SELECT ALL - col0 / - 27 FROM tab0 cor0
----
0
1
3

query I rowsort
SELECT DISTINCT + - col0 * + col0 + col0 * col2 FROM tab1 AS cor0
----
-448
1280
153

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

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

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

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

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

query I rowsort
SELECT col1 + 75 FROM tab1 AS cor0
----
101
85
88

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

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

query I rowsort
SELECT + col0 * 49 + - 72 FROM tab2 AS cor0
----
271
3750
3799

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1417
SELECT + col2 * - ( - col2 ) * - cor0.col0 + - CAST ( + col0 AS INTEGER ) col0 FROM tab1 AS cor0
----
-208000
-737360
-8751

query I rowsort
SELECT DISTINCT + + col1 * 60 AS col0 FROM tab2 AS cor0
----
1020
1860
3540

query I rowsort
SELECT - - col1 + col2 * 37 AS col2 FROM tab1 cor0
----
2024
2119
3565

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

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

query I rowsort
SELECT - col0 + + 50 * col2 FROM tab2 AS cor0
----
1222
1343
1821

onlyif mysql # use DIV operator for integer division
query I rowsort label-1423
SELECT DISTINCT col2 - - col0 DIV ( tab0.col1 ) FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1423
SELECT DISTINCT col2 - - col0 / ( tab0.col1 ) FROM tab0
----
1
33
82

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

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

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

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

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

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

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

query I rowsort
SELECT + col1 * col1 + + 34 AS col2 FROM tab2 AS cor0
----
323
3515
995

query I rowsort
SELECT - cor0.col0 * col0 + - ( - col2 ) FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT - col2 * ( - 49 ) + col2 FROM tab0
----
1650
4100
50

query I rowsort
SELECT - col0 * - 65 + - col2 AS col2 FROM tab1 AS cor0
----
141
4103
5104

query I rowsort
SELECT - 14 AS col0 FROM tab2 AS cor0
----
-14
-14
-14

query I rowsort
SELECT tab2.col1 + col2 * - 22 AS col2 FROM tab2
----
-513
-563
-819

onlyif mysql # use DIV operator for integer division
query I rowsort label-1434
SELECT DISTINCT col0 DIV + 89 + - 43 * col2 AS col1 FROM tab0
----
-1419
-3525
-43

skipif mysql # not compatible
query I rowsort label-1434
SELECT DISTINCT col0 / + 89 + - 43 * col2 AS col1 FROM tab0
----
-1419
-3525
-43

query I rowsort
SELECT - col0 - col0 * + col1 * + col2 FROM tab2
----
-119730
-51113
-5866

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( + tab2.col0 + - col2 * col2 ) col2 FROM tab2
----
-15548
-19494
-51870

query I rowsort
SELECT DISTINCT + 77 * - col0 FROM tab1 cor0
----
-231
-4928
-6160

query I rowsort
SELECT col0 * tab1.col0 + - col2 FROM tab1
----
-45
4039
6304

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

query I rowsort
SELECT + 13 - col1 FROM tab1
----
-13
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1441
SELECT ALL col0 * - col0 DIV col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1441
SELECT ALL col0 * - col0 / col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL - 36 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 3bcd07d22b62d2042b499253b1c13d9e

query I rowsort
SELECT ALL + 71 + col2 FROM tab1
----
125
128
167

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

query I rowsort
SELECT DISTINCT col2 + col2 + + col1 AS col0 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT + 44 + col0 AS col2 FROM tab2
----
122
123
51

query I rowsort
SELECT + col2 * col1 + - col0 + + col2 * col2 AS col2 FROM tab1
----
10384
3755
4317

query I rowsort
SELECT ALL - tab1.col1 * 68 + cor1.col2 * - 1 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to b90680fd691a59005c8fa41052999a80

query I rowsort
SELECT DISTINCT ( col1 * tab0.col0 ) + - tab0.col2 + + col2 * col1 FROM tab0
----
15479
3491
4869

query I rowsort
SELECT 28 + cor0.col2 FROM tab0 cor0
----
110
29
61

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

query I rowsort
SELECT DISTINCT - - 85 * col2 AS col2 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT DISTINCT + cor1.col2 * - 0 FROM tab2, tab1 cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
0

query I rowsort
SELECT - col1 * col2 + - ( col2 + col0 ) * col1 AS col2 FROM tab1 AS cor0
----
-1780
-2886
-3536

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

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

query I rowsort
SELECT + 4 * col2 FROM tab0
----
132
328
4

query I rowsort
SELECT ALL + 2 + - col2 AS col1 FROM tab1 AS cor0
----
-52
-55
-94

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

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

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

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

query I rowsort
SELECT ALL + 97 * col1 FROM tab2 AS cor0
----
1649
3007
5723

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

query I rowsort
SELECT DISTINCT - col2 + - col0 + + 29 * 10 FROM tab1 AS cor0
----
114
169
233

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + col2 ) + + col0 + 86 col0 FROM tab2 AS cor0
----
120
190
203

query I rowsort
SELECT - cor0.col2 * - col0 + ( 80 ) FROM tab0 AS cor0
----
115
7378
872

query I rowsort
SELECT - + col1 + col0 * 98 FROM tab2 AS cor0
----
655
7585
7725

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

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

query I rowsort
SELECT ALL 16 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

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

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

query I rowsort
SELECT + - 72 + + 14 FROM tab0 AS cor0
----
-58
-58
-58

query I rowsort
SELECT - 75 + 71 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

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

query I rowsort
SELECT col0 * tab0.col0 + col2 AS col1 FROM tab0
----
1226
609
8003

query I rowsort
SELECT + col0 + 99 * col2 AS col1 FROM tab2 AS cor0
----
2652
2680
3841

query I rowsort
SELECT - + ( 70 ) - col0 FROM tab2 cor0
----
-148
-149
-77

query I rowsort
SELECT 33 + + 44 FROM tab0 AS cor0
----
77
77
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1481
SELECT + CAST( - 37 AS SIGNED ) + + col0 AS col2 FROM tab2 cor0
----
-30
41
42

skipif mysql # not compatible
query I rowsort label-1481
SELECT + CAST ( - 37 AS INTEGER ) + + col0 AS col2 FROM tab2 cor0
----
-30
41
42

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1483
SELECT col0 + - col1 * + col1 * + col0 + - col2 DIV - ( + tab1.col1 ) AS col0 FROM tab1
----
-13433
-2023
-6331

skipif mysql # not compatible
query I rowsort label-1483
SELECT col0 + - col1 * + col1 * + col0 + - col2 / - ( + tab1.col1 ) AS col0 FROM tab1
----
-13433
-2023
-6331

query I rowsort
SELECT tab0.col1 + + 60 FROM tab0
----
146
151
157

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

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

query I rowsort
SELECT DISTINCT - - 43 + col1 AS col0 FROM tab0 cor0
----
129
134
140

query I rowsort
SELECT - cor1.col0 FROM tab2, tab0, tab0 AS cor0, tab0 AS cor1
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

query I rowsort
SELECT tab1.col2 + + 32 + col0 FROM tab1
----
153
208
89

query I rowsort
SELECT 63 AS col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1492
SELECT DISTINCT - tab0.col1 DIV + 1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1492
SELECT DISTINCT - tab0.col1 / + 1 FROM tab0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1493
SELECT + col0 DIV - 13 FROM tab0 AS cor0
----
-1
-2
-6

skipif mysql # not compatible
query I rowsort label-1493
SELECT + col0 / - 13 FROM tab0 AS cor0
----
-1
-2
-6

query I rowsort
SELECT cor0.col2 + col0 * - 91 AS col0 FROM tab1 AS cor0
----
-219
-5767
-7184

query I rowsort
SELECT + + col1 * col0 + + col0 * col0 AS col2 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT + + cor0.col0 * - 23 * 35 AS col1 FROM tab1 AS cor0
----
-2415
-51520
-64400

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

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

skipif mysql # not compatible
query I rowsort label-1498
SELECT col2 * + CAST ( + col1 * - col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT - cor0.col0 * - 78 AS col2 FROM tab0 AS cor0
----
1872
2730
6942

query I rowsort
SELECT 67 * + col1 AS col2 FROM tab2
----
1139
2077
3953

query I rowsort
SELECT 56 * col0 AS col1 FROM tab1
----
168
3584
4480

query I rowsort
SELECT ALL + 94 + + col0 * col0 FROM tab0 AS cor0
----
1319
670
8015

query I rowsort
SELECT + 79 * col1 AS col0 FROM tab0 AS cor0
----
6794
7189
7663

query I rowsort
SELECT - col1 + col0 + - col1 FROM tab0 AS cor0
----
-148
-159
-93

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

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

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

query I rowsort
SELECT DISTINCT col1 * + col0 + + col1 + col0 * col0 * col1 FROM tab2
----
107457
1767
363617

onlyif mysql # use DIV operator for integer division
query I rowsort label-1509
SELECT + col2 DIV + 87 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1509
SELECT + col2 / + 87 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col0 AS REAL ) * col2 + - col1 * - col1 AS col2 FROM tab0
----
6604
9374
983

query I rowsort
SELECT col1 * 28 FROM tab0
----
2408
2548
2716

query I rowsort
SELECT 46 + - col1 * - col0 FROM tab0
----
2110
3441
8145

query I rowsort
SELECT + col2 + + 82 AS col2 FROM tab1
----
136
139
178

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT DISTINCT + col2 * col0 + col0 + + col0 AS col1 FROM tab2
----
203
2184
3160

query I rowsort
SELECT + tab0.col2 * col1 * + col2 + + col2 FROM tab0
----
611966
93687
98

query I rowsort
SELECT - 25 * + tab0.col2 AS col0 FROM tab0
----
-2050
-25
-825

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

query I rowsort
SELECT - 84 + + col0 * col0 FROM tab1
----
-75
4012
6316

query I rowsort
SELECT col2 + col0 * + col1 + col2 FROM tab0 cor0
----
2130
3397
8263

query I rowsort
SELECT DISTINCT 53 * + col0 AS col2 FROM tab2 AS cor0
----
371
4134
4187

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

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

query I rowsort
SELECT ( col2 ) + - col1 + col2 FROM tab0 cor0
----
-20
-95
73

query I rowsort
SELECT col0 * - 47 - col1 FROM tab0
----
-1214
-1742
-4274

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * cor0.col1 col1 FROM tab0 cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 76 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

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

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

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

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

query I rowsort
SELECT - 27 * cor0.col0 + col0 + + col2 * - col1 FROM tab0 AS cor0
----
-1007
-3462
-9776

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

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

query I rowsort
SELECT + 30 * - col0 + + col1 + + col2 AS col0 FROM tab0 cor0
----
-2497
-601
-952

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

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

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

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

query I rowsort
SELECT ALL - col2 * - cor0.col2 + col0 * col1 + col0 FROM tab2 AS cor0
----
2866
5356
953

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

query I rowsort
SELECT ALL - - col0 * + col0 + + col0 * col1 AS col2 FROM tab2 AS cor0
----
10686
266
7584

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col0 col0 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL col0 * col0 + col1 + - col1 FROM tab0 AS cor0
----
1225
576
7921

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col2 * col2 + + col1 col2 FROM tab1 AS cor0
----
2945
3323
9309

query I rowsort
SELECT - col0 * col1 + + col0 * + col0 FROM tab1 AS cor0
----
-69
3456
5360

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

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

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

skipif mysql # not compatible
query I rowsort label-1550
SELECT - col2 / + col1 + - col0 AS col1 FROM tab1 AS cor0
----
-5
-69
-87

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1552
SELECT DISTINCT + col0 * col1 + - cor0.col0 DIV - col2 FROM tab0 AS cor0
----
2064
3430
8100

skipif mysql # not compatible
query I rowsort label-1552
SELECT DISTINCT + col0 * col1 + - cor0.col0 / - col2 FROM tab0 AS cor0
----
2064
3430
8100

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

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

query IIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2 WHERE NOT NULL > NULL
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1556
SELECT ALL - - col0 / col0 col0 FROM tab1 AS cor0
----
1
1
1

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

query I rowsort
SELECT - col0 - col0 * col1 * - tab1.col2 FROM tab1
----
36416
4209
99760

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

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

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

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

query I rowsort
SELECT col2 * tab1.col1 + col2 * col0 * + col1 FROM tab1
----
101088
37050
5616

query I rowsort
SELECT - + col1 * 2 + ( col1 ) FROM tab1 AS cor0
----
-10
-13
-26

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

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

query I rowsort
SELECT DISTINCT col2 + - 77 AS col0 FROM tab1 AS cor0
----
-20
-23
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - + 65 col2 FROM tab0 AS cor0
----
-151
-156
-162

query I rowsort
SELECT ALL + 85 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT + col0 * ( + 89 + - col2 ) AS col0 FROM tab0
----
1344
3080
623

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

query I rowsort
SELECT + cor0.col0 + + cor0.col1 * 8 * - col1 FROM tab0 AS cor0
----
-59144
-66159
-75237

query I rowsort
SELECT + col0 + - 59 FROM tab0 AS cor0
----
-24
-35
30

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

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

query I rowsort
SELECT DISTINCT - + cor0.col1 * + 60 + col0 * ( - col1 ) FROM tab1 AS cor0
----
-1240
-1638
-1820

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

query I rowsort
SELECT ALL col2 * - col2 + col0 + - 86 * col2 * + 53 FROM tab2 AS cor0
----
-119106
-123788
-174569

query I rowsort
SELECT ALL - - col0 + + col1 * - col0 + - 56 AS col2 FROM tab0 AS cor0
----
-2096
-3416
-8066

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

query I rowsort
SELECT ALL col0 + - col1 + - col0 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + 69 * + tab2.col1 * col2 + + 9 FROM tab2
----
105855
44583
57762

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1583
SELECT - col1 + col2 DIV ( - col0 + - col2 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1583
SELECT - col1 + col2 / ( - col0 + - col2 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

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

query I rowsort
SELECT 60 - col0 * col0 * 30 FROM tab1
----
-122820
-191940
-210

query I rowsort
SELECT ALL 10 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

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

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

query I rowsort
SELECT ALL - col1 + - col0 * col1 FROM tab0 cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-1590
SELECT ALL col2 - 27 DIV + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1590
SELECT ALL col2 - 27 / + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

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

skipif mysql # not compatible
query I rowsort label-1591
SELECT DISTINCT col1 / 62 AS col0 FROM tab0 AS cor0
----
1

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

query I rowsort
SELECT ALL + col0 + + 88 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
135070
56927
73663

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

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

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

query I rowsort
SELECT - + 42 + cor0.col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 47beccf0483c03942308acd39dee3c33

query I rowsort
SELECT ALL - - 55 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT - 2 * col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * + 20 + col0 col0 FROM tab0 AS cor0
----
1729
55
684

query I rowsort
SELECT - 18 + cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
1325
199
4584

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

query I rowsort
SELECT - + col2 + 17 * - col0 AS col0 FROM tab1 AS cor0
----
-105
-1145
-1456

query I rowsort
SELECT ALL - col0 * - 8 FROM tab0
----
192
280
712

query I rowsort
SELECT + 58 * 16 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ccb8523b52430060b02de9635b398e13

query I rowsort
SELECT ALL 60 + cor0.col1 * + tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 79503095c1b2eee2772a8c6a09c1d539

query I rowsort
SELECT ALL col2 * + 39 FROM tab1
----
2106
2223
3744

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

query I rowsort
SELECT ( 93 ) - - col0 * - cor0.col1 * ( - col2 ) AS col2 FROM tab2 AS cor0
----
119745
51127
5952

query I rowsort
SELECT tab1.col0 AS col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

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

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

query I rowsort
SELECT col0 * 96 AS col0 FROM tab1
----
288
6144
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1614
SELECT - col0 + + cor0.col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-1614
SELECT - col0 + + cor0.col0 / + col0 AS col0 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT DISTINCT - 95 + + col2 AS col0 FROM tab0 AS cor0
----
-13
-62
-94

query I rowsort
SELECT DISTINCT 26 * ( - col0 ) + col0 AS col2 FROM tab2
----
-175
-1950
-1975

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

query I rowsort
SELECT DISTINCT - + 59 + col0 + cor0.col1 * cor0.col1 FROM tab0 AS cor0
----
7361
8311
9385

query I rowsort
SELECT + cor1.col1 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-1620
SELECT ALL + ( + col2 ) + col1 * col2 DIV col0 FROM tab0 cor0
----
151
165
3

skipif mysql # not compatible
query I rowsort label-1620
SELECT ALL + ( + col2 ) + col1 * col2 / col0 FROM tab0 cor0
----
151
165
3

query I rowsort
SELECT ALL + 61 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT ALL - ( col0 ) * + col2 + - col0 * + 59 FROM tab2 AS cor0
----
-602
-6630
-7663

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

query I rowsort
SELECT ALL + 65 FROM tab1, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT - 6 + col2 * + col2 * col2 FROM tab2 AS cor0
----
17570
19677
54866

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

query I rowsort
SELECT DISTINCT + 80 * - col1 + col1 AS col2 FROM tab2 cor0
----
-1343
-2449
-4661

query I rowsort
SELECT ALL + col0 + 47 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1144
-1262
-1707

query I rowsort
SELECT ( - 96 ) + col2 * col0 * + 67 AS col2 FROM tab0 AS cor0
----
2249
488870
52968

query I rowsort
SELECT DISTINCT + col2 + col0 + ( 65 + + col0 ) * ( cor0.col2 * - col1 ) AS col0 FROM tab2 AS cor0
----
-219258
-60230
-92907

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1633
SELECT ALL + + col0 + cor0.col0 * - CAST( + 38 AS SIGNED ) AS col1 FROM tab0 cor0
----
-1295
-3293
-888

skipif mysql # not compatible
query I rowsort label-1633
SELECT ALL + + col0 + cor0.col0 * - CAST ( + 38 AS INTEGER ) AS col1 FROM tab0 cor0
----
-1295
-3293
-888

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

skipif mysql # not compatible
query I rowsort label-1634
SELECT + ( - cor0.col0 ) + + CAST ( - ( - col2 ) AS INTEGER ) FROM tab0 AS cor0
----
-34
-7
9

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

query I rowsort
SELECT DISTINCT col1 + cor0.col0 - - col0 * + 56 AS col0 FROM tab0 AS cor0
----
1454
2092
5164

onlyif mysql # use DIV operator for integer division
query I rowsort label-1637
SELECT ALL - ( col2 ) * col0 + col1 DIV + col1 FROM tab2
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-1637
SELECT ALL - ( col2 ) * col0 + col1 / + col1 FROM tab2
----
-188
-2027
-3001

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

query I rowsort
SELECT + 8 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

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

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

query I rowsort
SELECT + ( col2 ) * col1 * 14 FROM tab0
----
104468
1358
39732

query I rowsort
SELECT col0 * + 42 FROM tab2 AS cor0
----
294
3276
3318

onlyif mysql # use DIV operator for integer division
query I rowsort label-1643
SELECT DISTINCT - col2 DIV 49 AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1643
SELECT DISTINCT - col2 / 49 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + col0 * ( - col0 ) * - col0 AS col1 FROM tab2 AS cor0
----
343
474552
493039

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

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

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

query I rowsort
SELECT ALL + col0 * - col1 + + 28 * - 32 FROM tab1
----
-1536
-1936
-974

query I rowsort
SELECT ALL + 49 * - tab2.col1 + col2 FROM tab2
----
-1492
-2865
-795

onlyif mysql # use DIV operator for integer division
query I rowsort label-1649
SELECT col0 - col2 DIV ( col0 ) FROM tab2
----
4
78
79

skipif mysql # not compatible
query I rowsort label-1649
SELECT col0 - col2 / ( col0 ) FROM tab2
----
4
78
79

query I rowsort
SELECT ALL cor0.col0 * 18 + - col1 * col2 * col2 FROM tab1 AS cor0
----
-118368
-31338
-75762

query I rowsort
SELECT ALL - col1 + col2 * cor0.col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT - col0 + 43 * - col0 FROM tab2 cor0
----
-308
-3432
-3476

query I rowsort
SELECT DISTINCT + col0 * 39 AS col0 FROM tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT - tab0.col2 * col2 + ( col1 * col0 ) FROM tab0
----
1375
3394
975

query I rowsort
SELECT + col1 + 8 AS col2 FROM tab1
----
18
21
34

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

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

skipif mysql # not compatible
query I rowsort label-1657
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 1 FROM tab1, tab0 AS cor0
----
NULL

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1659
SELECT DISTINCT CAST ( col0 AS INTEGER ) col0 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT ( + col1 ) * col1 * - 47 AS col0 FROM tab0 AS cor0
----
-347612
-389207
-442223

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

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

query I rowsort
SELECT 82 * - col1 * - col0 FROM tab1 AS cor0
----
52480
6396
85280

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 84 + cor0.col0 col2 FROM tab1 AS cor0
----
148
164
87

query I rowsort
SELECT - cor0.col2 * 41 FROM tab2 AS cor0
----
-1066
-1107
-1558

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

query I rowsort
SELECT DISTINCT + 76 * 77 + + col1 AS col2 FROM tab1 AS cor0
----
5862
5865
5878

query I rowsort
SELECT DISTINCT - col1 * + col0 + 87 AS col0 FROM tab0
----
-1977
-3308
-8012

query I rowsort
SELECT ALL - - 66 * col1 FROM tab2 AS cor0
----
1122
2046
3894

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 92 + col0 col0 FROM tab0 AS cor0
----
-3
-57
-68

query I rowsort
SELECT DISTINCT - + 39 + - col2 + cor0.col1 * + col0 FROM tab2 AS cor0
----
1266
151
4537

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

skipif mysql # not compatible
query I rowsort label-1674
SELECT DISTINCT + col2 / cor0.col2 FROM tab0 cor0
----
1

query I rowsort
SELECT DISTINCT - + ( col2 ) + 6 FROM tab1 AS cor0
----
-48
-51
-90

query I rowsort
SELECT ALL - col2 * 82 * + col1 FROM tab1 AS cor0
----
-102336
-115128
-46740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + - 62 col1 FROM tab0 AS cor0
----
-29
-61
20

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

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

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

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

query I rowsort
SELECT DISTINCT + + col1 + + 59 AS col0 FROM tab1 cor0
----
69
72
85

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

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

query I rowsort
SELECT + 76 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT ALL 71 * + 83 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5015fe910b10b4c748f1eb92a8cc5c51

query I rowsort
SELECT - - 37 * + col1 FROM tab2 AS cor0
----
1147
2183
629

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1687
SELECT ALL + CAST( + 88 + col2 AS SIGNED ) FROM tab0
----
121
170
89

skipif mysql # not compatible
query I rowsort label-1687
SELECT ALL + CAST ( + 88 + col2 AS INTEGER ) FROM tab0
----
121
170
89

query I rowsort
SELECT ALL + + 1 + 18 AS col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT - col2 + - 48 FROM tab2
----
-74
-75
-86

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

query I rowsort
SELECT DISTINCT 35 AS col2 FROM tab1, tab1 cor0
----
35

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

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

query I rowsort
SELECT DISTINCT 46 FROM tab0, tab2 cor0
----
46

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

query I rowsort
SELECT + 43 AS col0 FROM tab0
----
43
43
43

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

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

query I rowsort
SELECT + 2 * cor0.col1 - 73 FROM tab2, tab1 AS cor0
----
9 values hashing to 366d01110709aa0cb83f0217a73f949d

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

query I rowsort
SELECT + col0 + col0 * cor0.col0 + col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
6838
7764
785

onlyif mysql # use DIV operator for integer division
query I rowsort label-1701
SELECT + col0 + col0 DIV col2 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-1
-27
-62

skipif mysql # not compatible
query I rowsort label-1701
SELECT + col0 + col0 / col2 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-1
-27
-62

query I rowsort
SELECT ALL col0 * + 51 + col2 AS col0 FROM tab1
----
207
3321
4176

query I rowsort
SELECT ( - 2 ) + - col0 AS col0 FROM tab0
----
-26
-37
-91

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 23 * col2 col2 FROM tab2 AS cor0
----
-598
-621
-874

query I rowsort
SELECT col2 + 42 - ( col1 ) FROM tab0
----
-11
-54
33

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

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

skipif mysql # not compatible
query I rowsort
SELECT + col1 * - CAST ( + 61 AS REAL ) AS col2 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT ALL + 97 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT - + 73 + + 20 AS col0 FROM tab2 AS cor0
----
-53
-53
-53

query I rowsort
SELECT - 79 * - col0 AS col2 FROM tab2 AS cor0
----
553
6162
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 86 + 65 * + col1 + - col2 col2 FROM tab2 AS cor0
----
1153
2074
3895

query I rowsort
SELECT ALL + 30 + + 65 AS col1 FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT col2 + 1 + - col2 * + 72 FROM tab1 cor0
----
-3833
-4046
-6815

query I rowsort
SELECT - + col1 * cor0.col2 - - cor0.col2 * + 22 FROM tab1 AS cor0
----
-216
684
864

query I rowsort
SELECT + col1 * - col1 * + col0 + ( + col0 ) + col2 FROM tab0 AS cor0
----
-177447
-329279
-736838

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1721
SELECT ALL - col1 DIV 6 FROM tab0
----
-14
-15
-16

skipif mysql # not compatible
query I rowsort label-1721
SELECT ALL - col1 / 6 FROM tab0
----
-14
-15
-16

query I rowsort
SELECT - 49 + - col1 * - col0 FROM tab1 AS cor0
----
29
591
991

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

skipif mysql # not compatible
query I rowsort label-1723
SELECT DISTINCT + 48 * col0 - col2 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL tab0.col2 * - 32 FROM tab0, tab2 AS cor0
----
9 values hashing to a71b7d462076286f67108a2c40fcd61d

query I rowsort
SELECT - 19 * col0 * 99 FROM tab0 AS cor0
----
-167409
-45144
-65835

query I rowsort
SELECT - col1 * col0 - ( - 63 ) FROM tab0
----
-2001
-3332
-8036

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1727
SELECT CAST( NULL AS SIGNED ) + - 49 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1727
SELECT CAST ( NULL AS INTEGER ) + - 49 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

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

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

skipif mysql # not compatible
query I rowsort label-1729
SELECT + cor0.col0 / + 93 + + cor0.col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + col0 * col0 + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-168
1482
4898

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1732
SELECT DISTINCT + col2 + + col2 DIV - cor0.col1 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1732
SELECT DISTINCT + col2 + + col2 / - cor0.col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - col2 * col2 - - col1 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1735
SELECT - + col2 + + 25 DIV col0 AS col0 FROM tab2 cor0
----
-24
-26
-38

skipif mysql # not compatible
query I rowsort label-1735
SELECT - + col2 + + 25 / col0 AS col0 FROM tab2 cor0
----
-24
-26
-38

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

query I rowsort
SELECT DISTINCT col0 * ( 14 ) AS col1 FROM tab0 AS cor0
----
1246
336
490

query I rowsort
SELECT DISTINCT + col1 + 14 FROM tab1 AS cor0
----
24
27
40

query I rowsort
SELECT DISTINCT - + col2 + + 90 FROM tab2 AS cor0
----
52
63
64

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1742
SELECT DISTINCT + col2 + ( col0 ) DIV - cor0.col1 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1742
SELECT DISTINCT + col2 + ( col0 ) / - cor0.col1 AS col2 FROM tab0 AS cor0
----
1
33
82

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1745
SELECT - col1 DIV - 59 + col0 DIV + 14 FROM tab2 cor0
----
0
5
6

skipif mysql # not compatible
query I rowsort label-1745
SELECT - col1 / - 59 + col0 / + 14 FROM tab2 cor0
----
0
5
6

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

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

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

skipif mysql # not compatible
query I rowsort label-1748
SELECT - - CAST ( - col1 AS INTEGER ) * - col1 + - ( - col1 * col0 ) + col2 AS col1 FROM tab2 AS cor0
----
1205
1670
8109

query I rowsort
SELECT ALL col0 + - 35 AS col0 FROM tab1 AS cor0
----
-32
29
45

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

query I rowsort
SELECT ALL + - col2 + 44 * + cor0.col1 * - col1 FROM tab2 AS cor0
----
-12754
-153190
-42311

onlyif mysql # use DIV operator for integer division
query I rowsort label-1752
SELECT col0 DIV col0 - col1 FROM tab2
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-1752
SELECT col0 / col0 - col1 FROM tab2
----
-16
-30
-58

query I rowsort
SELECT DISTINCT + col0 * col1 * + col1 + - 59 FROM tab0 AS cor0
----
177445
329256
736950

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

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

query I rowsort
SELECT ALL 1 AS col2 FROM tab1, tab0 cor0, tab0, tab1 AS cor1
----
81 values hashing to 2a004dce2d308bae163576f54ee1a3fc

query I rowsort
SELECT DISTINCT 95 * + col2 * - tab1.col2 + - col1 FROM tab1
----
-277046
-308665
-875533

query I rowsort
SELECT 27 AS col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 31 + - col2 col2 FROM tab1 AS cor0
----
-127
-85
-88

query I rowsort
SELECT col1 * col2 + - col2 + - col0 * col1 AS col0 FROM tab2 AS cor0
----
-3094
-735
593

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 66 + col2 * - ( - cor0.col1 ) col2 FROM tab2 AS cor0
----
1600
712
903

query I rowsort
SELECT ALL - + 10 + col1 FROM tab1 cor0
----
0
16
3

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

query I rowsort
SELECT DISTINCT - - 32 + cor0.col2 * - col2 AS col1 FROM tab1 AS cor0
----
-2884
-3217
-9184

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

query I rowsort
SELECT ALL - col2 * + ( - col1 ) + + col0 * 74 FROM tab1
----
1626
5306
7168

query I rowsort
SELECT ALL col1 + col2 + + tab2.col2 FROM tab2
----
111
85
93

query I rowsort
SELECT ALL - 59 + - col2 AS col2 FROM tab1 AS cor0
----
-113
-116
-155

query I rowsort
SELECT ALL + col1 * - col0 + - ( - col0 + - col2 ) * ( - col1 ) FROM tab2 AS cor0
----
-10738
-1271
-3332

query I rowsort
SELECT DISTINCT 35 - - col1 * 46 AS col2 FROM tab2 AS cor0
----
1461
2749
817

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

query I rowsort
SELECT DISTINCT - 85 * + col1 * - col2 FROM tab1 AS cor0
----
106080
119340
48450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col1 + - col0 * - col1 col2 FROM tab1
----
1210
1482
2288

query I rowsort
SELECT ALL + col2 - 9 FROM tab1
----
45
48
87

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

query I rowsort
SELECT - col2 * - 84 * + ( - tab0.col0 ) AS col0 FROM tab0
----
-2940
-613032
-66528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * - col1 * col2 + col1 col2 FROM tab2 cor0
----
119711
51051
5890

onlyif mysql # use DIV operator for integer division
query I rowsort label-1778
SELECT + cor0.col2 DIV 15 + cor0.col0 col0 FROM tab0 AS cor0
----
26
35
94

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

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

query I rowsort
SELECT DISTINCT - 32 * - cor0.col0 FROM tab0 AS cor0
----
1120
2848
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-1781
SELECT + - col1 DIV - col1 - cor0.col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-1781
SELECT + - col1 / - col1 - cor0.col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT + + cor0.col1 + + ( + col0 ) * - ( col0 ) * cor0.col2 FROM tab0 AS cor0
----
-1128
-18922
-649431

query I rowsort
SELECT - ( + col1 ) * - col1 + + col2 AS col2 FROM tab1 AS cor0
----
157
265
730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1784
SELECT + CAST( NULL AS SIGNED ) col2 FROM tab1, tab1 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1784
SELECT + CAST ( NULL AS INTEGER ) col2 FROM tab1, tab1 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1785
SELECT DISTINCT + CAST( + col1 AS SIGNED ) + + col2 + ( col0 ) AS col0 FROM tab0 AS cor0
----
133
143
262

skipif mysql # not compatible
query I rowsort label-1785
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) + + col2 + ( col0 ) AS col0 FROM tab0 AS cor0
----
133
143
262

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1786
SELECT CAST( cor0.col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1786
SELECT CAST ( cor0.col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + - 17 * 65 * col2 FROM tab0 AS cor0
----
-1105
-36465
-90610

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - 39 col0 FROM tab1 AS cor0
----
-36
25
41

query I rowsort
SELECT ALL + - col2 + + ( col2 ) + col2 * - ( 93 ) AS col2 FROM tab0 AS cor0
----
-3069
-7626
-93

query I rowsort
SELECT + + col1 * col2 * + col1 + + cor0.col0 FROM tab0 AS cor0
----
244092
679131
9444

query I rowsort
SELECT col0 + 30 * col0 AS col0 FROM tab2 cor0
----
217
2418
2449

query I rowsort
SELECT + + cor0.col1 * - 64 FROM tab2 AS cor0
----
-1088
-1984
-3776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 * - 96 col2 FROM tab2 cor0
----
-2574
-2599
-3727

query I rowsort
SELECT - ( 19 ) AS col1 FROM tab2 AS cor0
----
-19
-19
-19

query I rowsort
SELECT + ( - 81 ) FROM tab1 AS cor0
----
-81
-81
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1797
SELECT col1 * 98 + + col0 DIV col0 FROM tab0
----
8429
8919
9507

skipif mysql # not compatible
query I rowsort label-1797
SELECT col1 * 98 + + col0 / col0 FROM tab0
----
8429
8919
9507

query I rowsort
SELECT + cor0.col2 * + col0 - 32 AS col2 FROM tab1 cor0
----
130
3616
7648

query I rowsort
SELECT ALL + 39 * - col0 + ( ( col1 ) ) FROM tab2 AS cor0
----
-242
-2983
-3064

query I rowsort
SELECT cor0.col0 - - cor0.col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT ALL - 30 + tab1.col1 FROM tab1
----
-17
-20
-4

query I rowsort
SELECT + 73 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT ALL - 56 * col1 FROM tab0
----
-4816
-5096
-5432

query I rowsort
SELECT 70 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT ALL col0 * col2 + 53 FROM tab2
----
2081
242
3055

onlyif mysql # use DIV operator for integer division
query I rowsort label-1806
SELECT ALL + 5 DIV col1 + - ( + 68 + + col2 * col0 ) FROM tab0
----
-103
-7366
-860

skipif mysql # not compatible
query I rowsort label-1806
SELECT ALL + 5 / col1 + - ( + 68 + + col2 * col0 ) FROM tab0
----
-103
-7366
-860

query I rowsort
SELECT DISTINCT + col2 * col2 + 98 AS col0 FROM tab2 AS cor0
----
1542
774
827

query I rowsort
SELECT + - col2 + col1 * - cor0.col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT 27 * col2 FROM tab1
----
1458
1539
2592

query I rowsort
SELECT ALL 96 * ( tab2.col2 * 27 ) + cor0.col0 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 81d9b4f53fcd6bcca56cc34ebb65e387

query I rowsort
SELECT + - col0 * col1 * + col1 AS col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT DISTINCT - col0 + 21 * - col1 FROM tab2 cor0
----
-1317
-436
-658

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1813
SELECT ALL col1 * - CAST( 37 AS SIGNED ) * col2 AS col0 FROM tab1 AS cor0
----
-21090
-46176
-51948

skipif mysql # not compatible
query I rowsort label-1813
SELECT ALL col1 * - CAST ( 37 AS INTEGER ) * col2 AS col0 FROM tab1 AS cor0
----
-21090
-46176
-51948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1814
SELECT - + col1 * CAST( NULL AS SIGNED ) - + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1814
SELECT - + col1 * CAST ( NULL AS INTEGER ) - + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor1.col1 + cor0.col0 AS col1 FROM tab0, tab1 AS cor0, tab1, tab1 cor1
----
106
13
16
29
74
77
90
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1816
SELECT - col1 + 76 - col2 DIV + tab1.col0 col2 FROM tab1
----
32
62
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1816
SELECT - col1 + 76 - col2 / + tab1.col0 col2 FROM tab1
----
32
62
66

query I rowsort
SELECT + col1 + col1 * col0 FROM tab2
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 72 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT + col2 - + ( col0 ) * tab2.col2 AS col0 FROM tab2
----
-162
-2002
-2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1820
SELECT + col1 - + CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1820
SELECT + col1 - + CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 + - col2 * + ( + col2 + - col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1822
SELECT - cor0.col0 - col2 * cor0.col1 DIV + col2 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-1822
SELECT - cor0.col0 - col2 * cor0.col1 / + col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + 53 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT + ( col0 ) * col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-1825
SELECT DISTINCT - 32 DIV + col1 FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-1825
SELECT DISTINCT - 32 / + col1 FROM tab1
----
-1
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1826
SELECT ( col1 ) DIV 20 AS col0 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1826
SELECT ( col1 ) / 20 AS col0 FROM tab1 cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1827
SELECT - - col1 * col0 * + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1827
SELECT - - col1 * col0 * + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 86 - col1 AS col1 FROM tab0
----
-172
-177
-183

onlyif mysql # use DIV operator for integer division
query I rowsort label-1829
SELECT + - col1 DIV + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-1829
SELECT + - col1 / + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT + 77 * - col2 FROM tab0 AS cor0
----
-2541
-6314
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) * col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - 86 AS col0 FROM tab2 cor0
----
-86
-86
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 + + col1 * + col2 + - tab0.col0 col2 FROM tab0
----
15472
3457
4878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 + ( + tab2.col1 ) col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT + col1 - ( col0 ) AS col1 FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT col2 + - col0 + - col0 FROM tab0
----
-15
-69
-96

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab2, tab0 cor1, tab1 AS cor2
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

query I rowsort
SELECT ( col2 * col1 ) + + col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT tab0.col2 * + 9 FROM tab0
----
297
738
9

query I rowsort
SELECT - col1 * + ( - col0 ) FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + col0 + + tab2.col1 * + tab2.col0 AS col1 FROM tab2
----
1422
224
4680

query I rowsort
SELECT 97 * - col1 + col1 FROM tab0
----
-8256
-8736
-9312

query I rowsort
SELECT ALL - 33 AS col1 FROM tab0
----
-33
-33
-33

query I rowsort
SELECT 72 + + 15 FROM tab2 AS cor0
----
87
87
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1845
SELECT DISTINCT + CAST( NULL AS SIGNED ) / + 3 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1845
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / + 3 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL 25 + + ( cor0.col0 ) FROM tab2 AS cor0
----
103
104
32

query I rowsort
SELECT ALL + + ( + col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 64 * 79 AS col2 FROM tab0 AS cor0
----
5056

query I rowsort
SELECT - col1 + + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT DISTINCT ( col1 ) + + col1 * col0 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-1851
SELECT ALL - 70 DIV + col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1851
SELECT ALL - 70 / + col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1852
SELECT DISTINCT col2 + + tab0.col2 + - CAST( NULL AS DECIMAL ) col2 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1852
SELECT DISTINCT col2 + + tab0.col2 + - CAST ( NULL AS REAL ) col2 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col0 + - col0 col1 FROM tab1
----
-165
-3712
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-1854
SELECT col2 + col2 DIV - col2 + col2 FROM tab1
----
107
113
191

skipif mysql # not compatible
query I rowsort label-1854
SELECT col2 + col2 / - col2 + col2 FROM tab1
----
107
113
191

query I rowsort
SELECT DISTINCT col1 + + tab1.col0 - - col2 AS col1 FROM tab1
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1856
SELECT DISTINCT tab0.col1 * col0 + col2 DIV col2 AS col1 FROM tab0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-1856
SELECT DISTINCT tab0.col1 * col0 + col2 / col2 AS col1 FROM tab0
----
2065
3396
8100

query I rowsort
SELECT DISTINCT cor0.col0 + - col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1858
SELECT col2 + col2 DIV cor0.col1 + - cor0.col2 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1858
SELECT col2 + col2 / cor0.col1 + - cor0.col2 FROM tab1 cor0
----
2
5
7

query I rowsort
SELECT col0 * col0 - + col1 AS col2 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT ALL + 74 + col2 FROM tab1
----
128
131
170

query I rowsort
SELECT DISTINCT col1 + + col2 * tab1.col1 FROM tab1
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-1862
SELECT + - ( col1 ) DIV - ( ( - col0 ) ) + col1 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-1862
SELECT + - ( col1 ) / - ( ( - col0 ) ) + col1 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT + cor0.col0 + - 44 AS col1 FROM tab2 AS cor0
----
-37
34
35

query I rowsort
SELECT ALL + col1 * + cor0.col0 * col0 FROM tab1 AS cor0
----
234
40960
83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-1865
SELECT ALL - - col1 * col2 + col1 * col1 DIV col0 AS col0 FROM tab0 AS cor0
----
3146
365
7555

skipif mysql # not compatible
query I rowsort label-1865
SELECT ALL - - col1 * col2 + col1 * col1 / col0 AS col0 FROM tab0 AS cor0
----
3146
365
7555

query I rowsort
SELECT - + cor0.col2 + - col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL - + col2 + - col0 * + 8 FROM tab0 AS cor0
----
-225
-281
-794

query I rowsort
SELECT + + col1 * + col0 + col2 * - col2 + col1 FROM tab2 AS cor0
----
-481
-84
3985

query I rowsort
SELECT - cor0.col2 * 34 + + col0 * col0 AS col0 FROM tab0 AS cor0
----
-546
1191
5133

query I rowsort
SELECT - ( + col1 + + col0 ) AS col2 FROM tab1
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1871
SELECT 99 DIV + col0 col2 FROM tab0
----
1
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1871
SELECT 99 / + col0 col2 FROM tab0
----
1
2
4

query I rowsort
SELECT ALL col1 * col0 * col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - ( + col2 ) - col2 * 31 AS col0 FROM tab0
----
-1056
-2624
-32

query I rowsort
SELECT DISTINCT col0 + col2 + col2 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT + - col2 + 0 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1876
SELECT + col1 DIV col0 + col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-1876
SELECT + col1 / col0 + col0 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT ALL col2 * - col0 + + col0 * + col1 AS col2 FROM tab1 AS cor0
----
-3008
-6640
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-1878
SELECT ALL col2 DIV - col0 - col2 FROM tab0 AS cor0
----
-1
-34
-82

skipif mysql # not compatible
query I rowsort label-1878
SELECT ALL col2 / - col0 - col2 FROM tab0 AS cor0
----
-1
-34
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1879
SELECT DISTINCT + - col1 + col2 - col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
-33
-4
23

skipif mysql # not compatible
query I rowsort label-1879
SELECT DISTINCT + - col1 + col2 - col2 / - col1 AS col2 FROM tab2 AS cor0
----
-33
-4
23

query I rowsort
SELECT + - col2 + col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT + col0 * + col1 + - col2 AS col2 FROM tab2 AS cor0
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 col2 FROM tab2 AS cor0 WHERE NOT ( + col2 ) IN ( + col1 ) OR - col2 * col1 NOT IN ( col1 )
----
1534
646
837

query I rowsort
SELECT - - col0 + - cor0.col1 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col0 * - col2 * + col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT col0 * + col2 + - col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT ALL col0 + + col0 * + tab1.col0 * + col0 FROM tab1
----
262208
30
512080

query I rowsort
SELECT DISTINCT - + 78 + col1 FROM tab1 AS cor0
----
-52
-65
-68

query I rowsort
SELECT ALL - + 28 * + col2 - - col1 * col2 AS col0 FROM tab2 AS cor0
----
-418
806
81

query I rowsort
SELECT DISTINCT 20 + cor0.col0 AS col0 FROM tab2 cor0
----
27
98
99

query I rowsort
SELECT ALL + col1 + - col2 AS col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - 60 - col1 AS col0 FROM tab0 AS cor0
----
-146
-151
-157

query I rowsort
SELECT ALL - + 29 + - col1 FROM tab2 cor0
----
-46
-60
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-1893
SELECT DISTINCT - col0 DIV + col1 + col0 * - col2 FROM tab1 AS cor0
----
-162
-3654
-7686

skipif mysql # not compatible
query I rowsort label-1893
SELECT DISTINCT - col0 / + col1 + col0 * - col2 FROM tab1 AS cor0
----
-162
-3654
-7686

onlyif mysql # use DIV operator for integer division
query I rowsort label-1894
SELECT DISTINCT - 46 * col2 - col0 DIV col1 AS col0 FROM tab0 AS cor0
----
-1518
-3772
-46

skipif mysql # not compatible
query I rowsort label-1894
SELECT DISTINCT - 46 * col2 - col0 / col1 AS col0 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT DISTINCT + col1 + col1 + - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL tab1.col1 + tab1.col1 * col0 AS col2 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL - ( col1 ) * col0 + + col0 * + col2 AS col2 FROM tab1
----
3008
6640
84

query I rowsort
SELECT DISTINCT cor0.col0 + col1 * cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT - 30 AS col0 FROM tab0 AS cor0
----
-30
-30
-30

query I rowsort
SELECT DISTINCT - + col1 * cor0.col2 + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + col1 + tab1.col1 * - col1 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT ALL + col2 * - 83 AS col1 FROM tab2
----
-2158
-2241
-3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-1903
SELECT - ( col0 ) DIV col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-1903
SELECT - ( col0 ) / col1 FROM tab2
----
-1
-4
0

query I rowsort
SELECT - - col0 * cor0.col1 + + col1 * - col2 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT ALL + + 55 FROM tab2 AS cor0
----
55
55
55

query I rowsort
SELECT - 31 * col2 FROM tab0
----
-1023
-2542
-31

onlyif mysql # use DIV operator for integer division
query I rowsort label-1907
SELECT ALL ( ( + col2 ) ) DIV - 62 AS col0 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1907
SELECT ALL ( ( + col2 ) ) / - 62 AS col0 FROM tab1
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1908
SELECT CAST( + col0 + + col1 * - 23 AS SIGNED ) FROM tab2
----
-1279
-312
-706

skipif mysql # not compatible
query I rowsort label-1908
SELECT CAST ( + col0 + + col1 * - 23 AS INTEGER ) FROM tab2
----
-1279
-312
-706

onlyif mysql # use DIV operator for integer division
query I rowsort label-1909
SELECT - + col1 DIV + col1 + col0 FROM tab0 cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-1909
SELECT - + col1 / + col1 + col0 FROM tab0 cor0
----
23
34
88

query I rowsort
SELECT ALL + 67 FROM tab0, tab1 cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

onlyif mysql # use DIV operator for integer division
query I rowsort label-1911
SELECT DISTINCT ( col0 ) DIV - col1 AS col2 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-1911
SELECT DISTINCT ( col0 ) / - col1 AS col2 FROM tab2
----
-1
-4
0

query I rowsort
SELECT - - ( - cor0.col0 ) + + col2 + - col0 AS col2 FROM tab1 AS cor0
----
-64
-71
48

query I rowsort
SELECT cor0.col0 * - col2 + col0 * col0 * col1 FROM tab2 AS cor0
----
103095
1330
356928

query I rowsort
SELECT + - ( + cor0.col0 ) + ( 14 * + col2 ) FROM tab2 AS cor0
----
286
371
453

query I rowsort
SELECT - cor0.col2 + - cor0.col1 + cor0.col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT cor0.col1 + - col2 * 9 FROM tab0 cor0
----
-211
-647
88

query I rowsort
SELECT col1 + + ( col1 ) AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + - col2 + 47 FROM tab0 AS cor0
----
-35
14
46

query I rowsort
SELECT DISTINCT - col2 + - col2 * + 20 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT ALL - 83 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT cor0.col0 + cor0.col2 FROM tab0, tab1 cor0
----
9 values hashing to 8733ba2dd568938e338b27ad757d3e3b

query I rowsort
SELECT - + col0 * - 46 AS col0 FROM tab2 AS cor0
----
322
3588
3634

skipif mysql # not compatible
query I rowsort
SELECT - + col0 * - CAST ( + col0 AS REAL ) AS col1 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT + + cor0.col2 + + ( ( col0 ) ) AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT 65 + col1 * col1 FROM tab2 AS cor0
----
1026
354
3546

query I rowsort
SELECT + col0 + col1 + + col0 AS col1 FROM tab0 AS cor0
----
134
167
269

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2, tab1 AS cor3
----
3645 values hashing to 9b60cb1db2fb2fa5700b0e572b4b6546

query I rowsort
SELECT - + cor0.col1 + + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - col0 + cor0.col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - 51 + 48 FROM tab1 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT - + col1 * col2 * - col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT + 54 + 90 AS col0 FROM tab0 AS cor0
----
144

query I rowsort
SELECT ALL - 9 AS col0 FROM tab0 cor0
----
-9
-9
-9

query I rowsort
SELECT + 44 + - 25 FROM tab2 AS cor0
----
19
19
19

query I rowsort
SELECT DISTINCT 13 AS col2 FROM tab0, tab0 AS cor0
----
13

query I rowsort
SELECT DISTINCT col0 - - col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + ( - col1 ) * - col1 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - - col0 + + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + + 47 * - col0 * - cor0.col0 - ( - ( + col1 ) ) FROM tab0 AS cor0
----
27158
372378
57672

onlyif mysql # use DIV operator for integer division
query I rowsort label-1940
SELECT ALL cor0.col1 DIV ( col2 * col0 ) AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1940
SELECT ALL cor0.col1 / ( col2 * col0 ) AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1941
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * col0 + col0 AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1941
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * col0 + col0 AS col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL - 98 + + col2 AS col2 FROM tab0 AS cor0
----
-16
-65
-97

query I rowsort
SELECT - cor1.col0 * - 52 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 064a0a3374c503b28491a45b55423f96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1944
SELECT - + col1 + - cor0.col0 * CAST( NULL AS SIGNED ) * 42 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1944
SELECT - + col1 + - cor0.col0 * CAST ( NULL AS INTEGER ) * 42 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 - col1 * + col1 * - ( - col0 ) FROM tab1 AS cor0
----
-13533
-2054
-6410

query I rowsort
SELECT ALL - + ( col2 ) + - 61 FROM tab1 AS cor0
----
-115
-118
-157

query I rowsort
SELECT ALL - ( col2 ) * col0 * col1 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT col1 + ( col2 ) AS col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1949
SELECT DISTINCT - cor0.col1 * col1 DIV + col1 + - col2 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-1949
SELECT DISTINCT - cor0.col1 * col1 / + col1 + - col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT 26 * col0 * ( col2 ) FROM tab0
----
189748
20592
910

query I rowsort
SELECT - 0 AS col2 FROM tab1, tab0, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1952
SELECT - col2 + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1952
SELECT - col2 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - 20 * 21 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-22626
-23883
-40224

query I rowsort
SELECT - - col0 * + ( col0 ) + + col1 AS col1 FROM tab0 AS cor0
----
1322
662
8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * - cor0.col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col1 - 86 FROM tab1 AS cor0
----
-60
-73
-76

query I rowsort
SELECT ALL + + cor0.col2 - col0 AS col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT + cor1.col2 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT 68 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1960
SELECT ALL + 49 * col0 - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1960
SELECT ALL + 49 * col0 - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - 88 AS col2 FROM tab1
----
-1144
-2288
-880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + 53 col2 FROM tab0
----
139
144
150

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + + 98 col0 FROM tab0 AS cor0
----
63
74
9

query I rowsort
SELECT DISTINCT - + col0 * col0 + cor0.col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL col0 - - ( + col0 ) AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT 75 AS col2 FROM tab2, tab0 cor0
----
75

query I rowsort
SELECT + col0 + 99 * col0 AS col2 FROM tab0
----
2400
3500
8900

onlyif mysql # use DIV operator for integer division
query I rowsort label-1968
SELECT ALL col0 * col2 DIV - col1 FROM tab2
----
-176
-34
-6

skipif mysql # not compatible
query I rowsort label-1968
SELECT ALL col0 * col2 / - col1 FROM tab2
----
-176
-34
-6

query I rowsort
SELECT col0 + 81 AS col2 FROM tab1
----
145
161
84

query I rowsort
SELECT - - ( + col1 ) * col1 * 39 + col0 AS col2 FROM tab2 AS cor0
----
11350
135837
37486

query I rowsort
SELECT 49 + + 47 * + col2 FROM tab1
----
2587
2728
4561

query I rowsort
SELECT DISTINCT - cor0.col1 + + cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
1475
629
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) - - col0 col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT col2 - col2 * + col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + 61 FROM tab1 cor0
----
61

query I rowsort
SELECT ALL + col1 * + col0 * + 60 AS col1 FROM tab1 AS cor0
----
38400
4680
62400

query I rowsort
SELECT - 81 * col0 + + 49 AS col0 FROM tab1 AS cor0
----
-194
-5135
-6431

onlyif mysql # use DIV operator for integer division
query I rowsort label-1978
SELECT ALL + col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1978
SELECT ALL + col0 / - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT cor0.col1 - - col0 * 53 FROM tab1 cor0
----
185
3402
4253

query I rowsort
SELECT DISTINCT - 24 + col1 AS col2 FROM tab2 AS cor0
----
-7
35
7

query I rowsort
SELECT DISTINCT 94 * cor0.col1 AS col0 FROM tab2 AS cor0
----
1598
2914
5546

query I rowsort
SELECT + col2 * - col1 + 10 * 34 AS col2 FROM tab2 AS cor0
----
-1194
-306
-497

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - col0 - - col2 * - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL - + col2 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * + col2 * + col2 + + col0 FROM tab2 AS cor0
----
17654
19690
54951

query I rowsort
SELECT DISTINCT 94 + + tab2.col0 FROM tab2
----
101
172
173

onlyif mysql # use DIV operator for integer division
query I rowsort label-1988
SELECT DISTINCT + col1 + col2 DIV ( + tab0.col2 ) + col2 * col0 AS col1 FROM tab0
----
133
7390
879

skipif mysql # not compatible
query I rowsort label-1988
SELECT DISTINCT + col1 + col2 / ( + tab0.col2 ) + col2 * col0 AS col1 FROM tab0
----
133
7390
879

skipif mysql # not compatible
query I rowsort
SELECT 56 * + col2 * + CAST ( tab2.col2 AS REAL ) + tab2.col2 FROM tab2
----
37882
40851
80902

query I rowsort
SELECT DISTINCT tab0.col0 + tab0.col0 FROM tab0
----
178
48
70

query I rowsort
SELECT - 45 * - col1 AS col2 FROM tab2
----
1395
2655
765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1992
SELECT - cor0.col1 + cor0.col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1992
SELECT - cor0.col1 + cor0.col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1993
SELECT + 6 DIV col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1993
SELECT + 6 / col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col2 ) * + col0 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - cor0.col1 + col2 * col2 AS col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) + - 58 * + col1 FROM tab2 AS cor0
----
-1771
-3396
-948

query I rowsort
SELECT ALL - 41 AS col1 FROM tab0
----
-41
-41
-41

query I rowsort
SELECT ALL 47 AS col2 FROM tab1
----
47
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - cor0.col1 + + col2 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
104
179
82

query I rowsort
SELECT DISTINCT + col2 + - 41 * col0 FROM tab1 AS cor0
----
-2567
-3184
-69

query I rowsort
SELECT col1 * + col2 - col2 * cor0.col2 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT - col2 + + 2 + 17 FROM tab1 AS cor0
----
-35
-38
-77

query I rowsort
SELECT + col2 * + col0 * col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - col2 + + ( col0 ) * - col1 FROM tab2 AS cor0
----
-1381
-244
-4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * - ( + 76 ) col2 FROM tab1 cor0
----
4104
4332
7296

query I rowsort
SELECT col1 + - col0 * 45 * col1 FROM tab0 AS cor0
----
-152678
-364364
-92794

query I rowsort
SELECT col0 + - col0 * 60 * col2 FROM tab0 AS cor0
----
-2065
-437791
-47496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2009
SELECT + col2 DIV col2 + col1 AS col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2009
SELECT + col2 / col2 + col1 AS col1 FROM tab1
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-2010
SELECT - ( col0 ) DIV col1 AS col0 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-2010
SELECT - ( col0 ) / col1 AS col0 FROM tab1
----
-6
-6
0

query I rowsort
SELECT col1 * col2 + + 32 FROM tab2
----
1566
678
869

onlyif mysql # use DIV operator for integer division
query I rowsort label-2012
SELECT + col2 * - col2 - - col1 DIV + col0 FROM tab1 AS cor0
----
-2908
-3249
-9216

skipif mysql # not compatible
query I rowsort label-2012
SELECT + col2 * - col2 - - col1 / + col0 FROM tab1 AS cor0
----
-2908
-3249
-9216

query I rowsort
SELECT col1 * 0 - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col0 + - ( col1 ) FROM tab0 cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2015
SELECT ALL - ( + cor0.col1 ) DIV col0 + ( - col1 ) FROM tab0 AS cor0
----
-89
-92
-99

skipif mysql # not compatible
query I rowsort label-2015
SELECT ALL - ( + cor0.col1 ) / col0 + ( - col1 ) FROM tab0 AS cor0
----
-89
-92
-99

query I rowsort
SELECT ALL col2 * col0 + + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - ( col2 ) + col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2018
SELECT ALL + ( col1 ) DIV col0 + + 72 * - col0 FROM tab1 AS cor0
----
-208
-4608
-5760

skipif mysql # not compatible
query I rowsort label-2018
SELECT ALL + ( col1 ) / col0 + + 72 * - col0 FROM tab1 AS cor0
----
-208
-4608
-5760

query I rowsort
SELECT ALL + ( - 70 ) * - col0 AS col0 FROM tab0 cor0
----
1680
2450
6230

query I rowsort
SELECT DISTINCT col2 + + 67 + col1 FROM tab0 AS cor0
----
165
186
240

query I rowsort
SELECT DISTINCT + + cor0.col1 + col2 + + col2 * 97 * + 74 FROM tab2 AS cor0
----
186713
193864
272819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2022
SELECT DISTINCT + + CAST( NULL AS DECIMAL ) * col0 + + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2022
SELECT DISTINCT + + CAST ( NULL AS REAL ) * col0 + + col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - 73 + + 17 FROM tab0 AS cor0
----
-56
-56
-56

query I rowsort
SELECT + + ( + ( - col0 ) ) * cor0.col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + - cor0.col2 * - ( - col1 ) + ( + col1 * cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-774
3298
637

onlyif mysql # use DIV operator for integer division
query I rowsort label-2026
SELECT ALL - - ( - col2 ) * cor0.col1 - col0 DIV cor0.col0 FROM tab1 AS cor0
----
-1249
-1405
-571

skipif mysql # not compatible
query I rowsort label-2026
SELECT ALL - - ( - col2 ) * cor0.col1 - col0 / cor0.col0 FROM tab1 AS cor0
----
-1249
-1405
-571

query I rowsort
SELECT 43 FROM tab0 cor0
----
43
43
43

query I rowsort
SELECT ALL ( 72 ) AS col1 FROM tab2 AS cor0
----
72
72
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2029
SELECT ALL - CAST( NULL AS SIGNED ) + - col2 * cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2029
SELECT ALL - CAST ( NULL AS INTEGER ) + - col2 * cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 38 * + ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT DISTINCT + col0 * - col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT DISTINCT - - cor0.col1 * 30 AS col2 FROM tab0 AS cor0
----
2580
2730
2910

query I rowsort
SELECT DISTINCT + + 58 AS col1 FROM tab0 AS cor0
----
58

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 AS REAL ) FROM tab1 cor0
----
54
57
96

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab0 cor1, tab1 AS cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

query I rowsort
SELECT DISTINCT 32 + col2 FROM tab2 AS cor0
----
58
59
70

query I rowsort
SELECT DISTINCT - 49 + cor0.col1 AS col0 FROM tab0, tab1 AS cor0
----
-23
-36
-39

query III rowsort
SELECT * FROM tab0 WHERE ( col1 ) BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT tab0.col0 - col0 * - col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT tab0.col2 - - col2 AS col2 FROM tab0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 + col0 * col1 col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL col2 + col2 * - tab1.col0 AS col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT - tab1.col2 * - col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - col2 + - col1 * col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT tab0.col0 + col0 * - col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT - col0 FROM tab2 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT tab1.col1 * - col2 + - col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT ALL + col2 + col0 * - col0 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT col1 * col1 + + col1 * + col0 AS col1 FROM tab0
----
12804
16380
9460

query I rowsort
SELECT - col0 + - col2 * col0 AS col0 FROM tab2
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-2051
SELECT col0 * col2 DIV + tab1.col0 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2051
SELECT col0 * col2 / + tab1.col0 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT tab1.col0 + col2 + + tab1.col2 AS col0 FROM tab1
----
111
178
272

query I rowsort
SELECT col2 * - col2 * col0 AS col1 FROM tab1
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-2054
SELECT + col1 * col0 DIV col2 + - col2 DIV - col2 FROM tab0
----
3396
63
99

skipif mysql # not compatible
query I rowsort label-2054
SELECT + col1 * col0 / col2 + - col2 / - col2 FROM tab0
----
3396
63
99

query I rowsort
SELECT tab1.col2 AS col1 FROM tab1 WHERE NULL IN ( tab1.col1 + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2056
SELECT DISTINCT - col2 * col0 DIV tab1.col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2056
SELECT DISTINCT - col2 * col0 / tab1.col0 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2057
SELECT - col2 + + col1 DIV col0 AS col0 FROM tab1
----
-46
-57
-96

skipif mysql # not compatible
query I rowsort label-2057
SELECT - col2 + + col1 / col0 AS col0 FROM tab1
----
-46
-57
-96

query I rowsort
SELECT DISTINCT - col0 + + col1 * - col2 + + tab0.col0 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2059
SELECT tab2.col1 DIV + col1 AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2059
SELECT tab2.col1 / + col1 AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT col1 * col1 * col2 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2061
SELECT ALL + col2 * col0 DIV + col1 col2 FROM tab1
----
364
590
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2061
SELECT ALL + col2 * col0 / + col1 col2 FROM tab1
----
364
590
6

query I rowsort
SELECT ALL col0 + col1 + col1 * - col1 FROM tab1
----
-26
-647
-76

query I rowsort
SELECT ALL col2 + col2 + col2 FROM tab1 WHERE ( NULL ) < + col1
----

query I rowsort
SELECT ALL - + col0 * col2 * col2 AS col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT col2 + - col1 AS col0 FROM tab1 AS cor0 WHERE col0 < NULL
----

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab0 AS cor0 WHERE col1 >= NULL
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT - col1 IN ( col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT ALL col2 * col0 AS col1 FROM tab1 WHERE NOT NULL > col0 + col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2069
SELECT ALL col0 + col2 DIV col0 AS col0 FROM tab2
----
10
78
79

skipif mysql # not compatible
query I rowsort label-2069
SELECT ALL col0 + col2 / col0 AS col0 FROM tab2
----
10
78
79

query I rowsort
SELECT col1 + col2 * - tab0.col2 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT col1 * col0 * + col1 AS col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT col0 FROM tab0 AS cor0 WHERE NULL IN ( - col2 )
----

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NULL NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2075
SELECT - col0 * col0 DIV + col1 FROM tab2 AS cor0
----
-1
-103
-367

skipif mysql # not compatible
query I rowsort label-2075
SELECT - col0 * col0 / + col1 FROM tab2 AS cor0
----
-1
-103
-367

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2077
SELECT DISTINCT - col0 DIV - tab2.col0 col1 FROM tab2
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2077
SELECT DISTINCT - col0 / - tab2.col0 col1 FROM tab2
----
1

query I rowsort
SELECT + + col2 * + 70 AS col1 FROM tab1 AS cor0
----
3780
3990
6720

query I rowsort
SELECT ALL + cor0.col1 + col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT + col0 + 85 AS col2 FROM tab1 AS cor0
----
149
165
88

query I rowsort
SELECT - col0 + - ( + col1 + col1 ) * - 69 FROM tab0 AS cor0
----
11844
12469
13351

query I rowsort
SELECT ALL 4 + + col0 FROM tab1 AS cor0
----
68
7
84

query I rowsort
SELECT ALL + 82 + + col1 * - cor0.col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-10900
-25865
-90424

query I rowsort
SELECT DISTINCT + - 8 * + col0 * + col2 FROM tab1 AS cor0
----
-1296
-29184
-61440

query I rowsort
SELECT - + ( col0 ) + ( 18 ) FROM tab2 AS cor0
----
-60
-61
11

query III rowsort
SELECT * FROM tab1 WHERE ( col1 ) > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 * + col1 col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL + cor0.col2 * - col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 + + CAST ( col1 AS REAL ) AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL + cor0.col2 * 54 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT col1 + + 8 FROM tab0 AS cor0
----
105
94
99

query I rowsort
SELECT ALL + + col1 * 77 + - col1 + col1 AS col1 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT ( + col1 ) * tab1.col1 + + col1 * + col2 + + 0 * + 99 AS col0 FROM tab1
----
1417
2080
670

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 col1 FROM tab0
----
60
60
60

query I rowsort
SELECT ALL - 6 AS col2 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT + 39 + col1 AS col2 FROM tab1 AS cor0
----
49
52
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + cor0.col0 col2 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col1 col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT cor0.col0 * - 2 + - col2 FROM tab1 AS cor0
----
-185
-256
-60

query I rowsort
SELECT DISTINCT col2 * + 20 + col1 + + col1 * 37 * col2 FROM tab2 AS cor0
----
24679
31540
57337

query I rowsort
SELECT + ( + ( col0 ) ) * 16 AS col2 FROM tab2 AS cor0
----
112
1248
1264

query I rowsort
SELECT - 66 * col0 FROM tab2 AS cor0
----
-462
-5148
-5214

query I rowsort
SELECT DISTINCT - 60 * cor0.col1 FROM tab1 AS cor0
----
-1560
-600
-780

query I rowsort
SELECT cor0.col1 - col1 * col0 * + ( col1 ) FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT + 7 FROM tab2 cor0
----
7
7
7

query I rowsort
SELECT - + col0 * 90 - col2 * col0 FROM tab1 AS cor0
----
-14880
-432
-9408

query I rowsort
SELECT DISTINCT + ( col0 ) * col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT DISTINCT + ( col2 ) - - col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col0 - - 50 AS col2 FROM tab2 AS cor0
----
128
129
57

query I rowsort
SELECT ALL - ( - col1 ) + col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - col2 * + col2 + + cor0.col0 * - ( + 32 * col2 ) FROM tab1 AS cor0
----
-119985
-254976
-8100

query I rowsort
SELECT ALL 84 + col2 * 14 * + col2 FROM tab2 cor0
----
10290
20300
9548

query I rowsort
SELECT + + 57 - + col2 FROM tab0 AS cor0
----
-25
24
56

query I rowsort
SELECT DISTINCT - + col0 + - col0 * + col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT 17 * 99 AS col0 FROM tab1, tab0 cor0 CROSS JOIN tab2
----
27 values hashing to 83645e2983c222441623807b989b8782

onlyif mysql # use DIV operator for integer division
query I rowsort label-2116
SELECT ALL col0 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2116
SELECT ALL col0 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col2 * 19 + 80 AS col0 FROM tab1 AS cor0
----
-1003
-1744
-946

query I rowsort
SELECT DISTINCT 61 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
61

query I rowsort
SELECT - col2 * - tab1.col2 - - col1 FROM tab1
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-2120
SELECT ALL + col2 * col1 * - cor0.col0 + - col0 DIV - col0 FROM tab2 AS cor0
----
-119651
-51033
-5858

skipif mysql # not compatible
query I rowsort label-2120
SELECT ALL + col2 * col1 * - cor0.col0 + - col0 / - col0 FROM tab2 AS cor0
----
-119651
-51033
-5858

query I rowsort
SELECT + - col2 * - ( - 51 ) AS col1 FROM tab0 cor0
----
-1683
-4182
-51

query I rowsort
SELECT ALL + cor0.col2 + + col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2123
SELECT - + CAST( NULL AS SIGNED ) + 60 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2123
SELECT - + CAST ( NULL AS INTEGER ) + 60 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col1 * + 8 FROM tab0 AS cor0
----
-688
-728
-776

onlyif mysql # use DIV operator for integer division
query I rowsort label-2125
SELECT + tab0.col1 + ( 88 ) DIV + col1 col0 FROM tab0
----
87
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2125
SELECT + tab0.col1 + ( 88 ) / + col1 col0 FROM tab0
----
87
91
97

query I rowsort
SELECT DISTINCT + 92 * 62 + - col0 * - cor0.col0 FROM tab2 AS cor0
----
11788
11945
5753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2127
SELECT + CAST( NULL AS SIGNED ) * - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2127
SELECT + CAST ( NULL AS INTEGER ) * - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 81 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab2, tab1, tab2 cor0, tab2 AS cor1
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * tab1.col1 + col2 col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT - col1 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 97 + - col0 col2 FROM tab0 cor0
----
62
73
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2133
SELECT col0 + tab1.col0 DIV ( col2 + col0 ) AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2133
SELECT col0 + tab1.col0 / ( col2 + col0 ) AS col2 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col2 col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT col2 * 10 AS col1 FROM tab0 cor0
----
10
330
820

query I rowsort
SELECT + ( col1 + + col2 ) AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT + - ( col1 ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 * + col1 * - 18 + + 65 AS col0 FROM tab2
----
-24109
-3841
-82771

query I rowsort
SELECT ALL - 26 + - col0 * - 76 AS col1 FROM tab0
----
1798
2634
6738

query I rowsort
SELECT - 92 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

query I rowsort
SELECT DISTINCT 33 * + col1 FROM tab1 AS cor0
----
330
429
858

query I rowsort
SELECT ALL - col0 * col1 + - col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT - col2 + - col1 + 35 AS col0 FROM tab1 AS cor0
----
-32
-45
-74

query I rowsort
SELECT col1 + col2 + - 96 AS col1 FROM tab2
----
-11
-38
-41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col2 * col2 col0 FROM tab2
----
22599
24548
39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2146
SELECT - cor0.col2 + + CAST( - col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-2146
SELECT - cor0.col2 + + CAST ( - col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + col0 * 71 FROM tab0 AS cor0
----
1704
2485
6319

query I rowsort
SELECT + cor0.col1 * 93 AS col0 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT + col1 + col0 + col1 FROM tab2 cor0
----
113
196
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2150
SELECT - col0 * - CAST( NULL AS SIGNED ) + - col1 * col2 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2150
SELECT - col0 * - CAST ( NULL AS INTEGER ) + - col1 * col2 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2151
SELECT + cor0.col0 DIV 35 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2151
SELECT + cor0.col0 / 35 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT - - col2 + col1 + col1 * - col1 * + 94 FROM tab2 AS cor0
----
-27111
-327129
-90276

query I rowsort
SELECT col1 * ( 11 * - col0 ) + col0 + + col0 * + col1 AS col2 FROM tab0 AS cor0
----
-20616
-33915
-80901

query I rowsort
SELECT ALL col2 + ( + col0 ) AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + ( - col0 + 91 ) FROM tab2
----
12
13
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-2156
SELECT col0 + + ( col1 ) DIV + col0 AS col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-2156
SELECT col0 + + ( col1 ) / + col0 AS col0 FROM tab2 AS cor0
----
11
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * cor0.col1 * + col2 col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-2158
SELECT DISTINCT + + col2 DIV - 3 AS col2 FROM tab0 AS cor0
----
-11
-27
0

skipif mysql # not compatible
query I rowsort label-2158
SELECT DISTINCT + + col2 / - 3 AS col2 FROM tab0 AS cor0
----
-11
-27
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2159
SELECT - col2 + + cor0.col1 DIV col1 AS col1 FROM tab0 cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-2159
SELECT - col2 + + cor0.col1 / col1 AS col1 FROM tab0 cor0
----
-32
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 15 col2 FROM tab2
----
15
15
15

query I rowsort
SELECT + 53 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT DISTINCT 65 FROM tab1, tab2, tab0 AS cor0
----
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 57 col1 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT - - 95 * 46 FROM tab1 AS cor0
----
4370
4370
4370

onlyif mysql # use DIV operator for integer division
query I rowsort label-2165
SELECT + - 45 DIV col0 + col2 FROM tab0 AS cor0
----
0
32
82

skipif mysql # not compatible
query I rowsort label-2165
SELECT + - 45 / col0 + col2 FROM tab0 AS cor0
----
0
32
82

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - col2 AS REAL ) + - col0 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + ( 65 ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) + col0 col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL 74 FROM tab2, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT - 59 + + ( col0 + col1 ) AS col0 FROM tab1 AS cor0
----
-30
15
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2172
SELECT DISTINCT cor0.col0 DIV + col2 + + col0 col0 FROM tab0 AS cor0
----
24
70
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2172
SELECT DISTINCT cor0.col0 / + col2 + + col0 col0 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT ALL + - 9 * - col0 * + col1 - col0 FROM tab0 AS cor0
----
18552
30520
72802

query I rowsort
SELECT DISTINCT + - cor0.col2 + - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT 21 * - ( - col0 ) + col2 + col1 FROM tab1
----
1411
143
1789

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col0 col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT 9 + col2 AS col2 FROM tab2
----
35
36
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2178
SELECT ALL + 72 + - col2 * col1 * - CAST( - col0 AS SIGNED ) AS col1 FROM tab0
----
-3323
-664046
-68040

skipif mysql # not compatible
query I rowsort label-2178
SELECT ALL + 72 + - col2 * col1 * - CAST ( - col0 AS INTEGER ) AS col1 FROM tab0
----
-3323
-664046
-68040

query I rowsort
SELECT + col0 * - col0 + tab1.col2 + col2 * tab1.col2 * col2 AS col0 FROM tab1
----
157509
181154
878432

query I rowsort
SELECT col1 + col2 * col0 - 29 FROM tab1
----
159
3629
7664

query I rowsort
SELECT - 90 * + tab0.col0 + + col1 AS col1 FROM tab0
----
-2074
-3053
-7919

onlyif mysql # use DIV operator for integer division
query I rowsort label-2182
SELECT - 54 * col2 DIV - col1 + - 74 AS col1 FROM tab1
----
233
324
38

skipif mysql # not compatible
query I rowsort label-2182
SELECT - 54 * col2 / - col1 + - 74 AS col1 FROM tab1
----
233
324
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2183
SELECT - CAST( NULL AS SIGNED ) + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2183
SELECT - CAST ( NULL AS INTEGER ) + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col0 + tab1.col0 * col0 AS col1 FROM tab1
----
12
4160
6480

query I rowsort
SELECT - - col0 * col1 * col2 + col1 AS col1 FROM tab1 AS cor0
----
36490
4238
99853

query I rowsort
SELECT ALL + + col0 + + col0 * ( - col2 ) AS col2 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2187
SELECT DISTINCT + - 88 DIV + col0 - + col2 * + ( cor0.col2 ) FROM tab1 AS cor0
----
-2945
-3250
-9217

skipif mysql # not compatible
query I rowsort label-2187
SELECT DISTINCT + - 88 / + col0 - + col2 * + ( cor0.col2 ) FROM tab1 AS cor0
----
-2945
-3250
-9217

query I rowsort
SELECT - col2 + cor0.col1 * 71 AS col1 FROM tab2 AS cor0
----
1169
2174
4163

query I rowsort
SELECT - - cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - - col1 + - cor0.col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2191
SELECT DISTINCT - + ( col0 ) + - col0 DIV col0 AS col2 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-2191
SELECT DISTINCT - + ( col0 ) + - col0 / col0 AS col2 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT ALL cor0.col0 + + col2 AS col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2193
SELECT + cor0.col0 + + col0 / - CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2193
SELECT + cor0.col0 + + col0 / - CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 49 FROM tab1 AS cor0
----
-49

query I rowsort
SELECT tab2.col2 - col0 * col0 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT ALL tab2.col2 - col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT DISTINCT - tab1.col0 - col2 AS col1 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + 21 AS col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
21

query I rowsort
SELECT + - cor0.col0 + 38 * + 53 AS col1 FROM tab0 AS cor0
----
1925
1979
1990

query I rowsort
SELECT + col1 + 60 FROM tab2
----
119
77
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2201
SELECT col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2201
SELECT col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 66 + col2 col0 FROM tab2 AS cor0
----
1160
2073
3920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2203
SELECT - CAST( NULL AS DECIMAL ) / 38 + col2 * 59 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2203
SELECT - CAST ( NULL AS REAL ) / 38 + col2 * 59 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * - col1 + - col0 * - cor0.col0 + + cor0.col1 * cor0.col0 AS col2 FROM tab0 cor0
----
-198
4523
8558

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col0 col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL + + 53 + + col2 * col0 FROM tab0 AS cor0
----
7351
845
88

query I rowsort
SELECT DISTINCT ( 89 ) FROM tab2 AS cor0
----
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2208
SELECT DISTINCT 15 DIV col1 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-2208
SELECT DISTINCT 15 / col1 FROM tab1
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * cor0.col2 + col2 col2 FROM tab1 AS cor0
----
2970
3306
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 30 * col2 col0 FROM tab0 AS cor0
----
2460
30
990

query I rowsort
SELECT ALL + - col0 + + col0 + 34 AS col0 FROM tab1 cor0
----
34
34
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * + col1 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT cor0.col1 * + col1 AS col2 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT ALL 93 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT DISTINCT + 87 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2216
SELECT col0 + + CAST( NULL AS SIGNED ) * 11 * 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-2216
SELECT col0 + + CAST ( NULL AS INTEGER ) * 11 * col1 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor1.col0 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT - col0 * + 65 + - col1 * + col2 + col0 FROM tab2
----
-1285
-5702
-6526

query I rowsort
SELECT + + col2 * + 20 * + col2 AS col0 FROM tab1 AS cor0
----
184320
58320
64980

query I rowsort
SELECT - + cor2.col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
243 values hashing to 3e2b81ca10484cbfc66f186955e0e920

query I rowsort
SELECT DISTINCT - 1 - - 22 AS col1 FROM tab2, tab2 AS cor0
----
21

query I rowsort
SELECT col2 + ( col0 ) AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + + col0 + - ( - col2 ) * col1 * + col1 FROM tab2 AS cor0
----
11061
25954
90584

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col1 AS REAL ) + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT col2 * 46 + cor0.col1 FROM tab1 AS cor0
----
2510
2632
4429

query I rowsort
SELECT DISTINCT cor1.col1 * 31 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
2666
2821
3007

query I rowsort
SELECT DISTINCT - 55 + col2 AS col2 FROM tab2 cor0
----
-17
-28
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-2228
SELECT - 45 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2228
SELECT - 45 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col2 * + col1 + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT 30 * + col0 AS col1 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT ALL - col1 + + ( - cor0.col0 + + col0 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2232
SELECT DISTINCT - cor0.col0 DIV col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-2232
SELECT DISTINCT - cor0.col0 / col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2233
SELECT DISTINCT + + 12 DIV + 81 - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2233
SELECT DISTINCT + + 12 / + 81 - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col1 + col2 * ( + col1 ) AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - - col1 + - col1 * 58 AS col1 FROM tab1 AS cor0
----
-1482
-570
-741

query I rowsort
SELECT ALL 74 * cor0.col1 FROM tab0 AS cor0
----
6364
6734
7178

onlyif mysql # use DIV operator for integer division
query I rowsort label-2237
SELECT DISTINCT - 3 DIV col2 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2237
SELECT DISTINCT - 3 / col2 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - cor0.col2 * + col1 + cor0.col2 * cor0.col0 * col2 FROM tab1 AS cor0
----
10152
208506
738528

query I rowsort
SELECT ALL - - cor0.col1 + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - col2 + - col0 * ( col1 ) AS col1 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2241
SELECT - col2 + col1 * - CAST( NULL AS SIGNED ) * - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2241
SELECT - col2 + col1 * - CAST ( NULL AS INTEGER ) * - col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 col0 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 48 + col1 * ( col2 ) col1 FROM tab1 AS cor0
----
1296
1452
618

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 93 * + col2 * + tab2.col1 col1 FROM tab2
----
142662
60078
77841

onlyif mysql # use DIV operator for integer division
query I rowsort label-2245
SELECT ALL + col0 + - col2 DIV - tab1.col0 FROM tab1
----
21
64
81

skipif mysql # not compatible
query I rowsort label-2245
SELECT ALL + col0 + - col2 / - tab1.col0 FROM tab1
----
21
64
81

query I rowsort
SELECT ALL - 65 + col2 AS col0 FROM tab1 AS cor0
----
-11
-8
31

query I rowsort
SELECT - - 17 + col2 * col0 FROM tab1 AS cor0
----
179
3665
7697

query I rowsort
SELECT DISTINCT col1 * cor0.col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + + col0 * - col0 + ( + col2 ) * cor0.col1 FROM tab2 AS cor0
----
-4550
-5595
788

query I rowsort
SELECT + + 36 * col1 FROM tab1 AS cor0
----
360
468
936

query I rowsort
SELECT - col0 * - 45 FROM tab1 AS cor0
----
135
2880
3600

query I rowsort
SELECT - ( - tab1.col2 ) AS col0 FROM tab1
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2253
SELECT col1 * - col2 + + CAST( + 35 AS SIGNED ) FROM tab1
----
-1213
-1369
-535

skipif mysql # not compatible
query I rowsort label-2253
SELECT col1 * - col2 + + CAST ( + 35 AS INTEGER ) FROM tab1
----
-1213
-1369
-535

onlyif mysql # use DIV operator for integer division
query I rowsort label-2254
SELECT - 37 + + col0 DIV col1 AS col0 FROM tab1
----
-31
-31
-37

skipif mysql # not compatible
query I rowsort label-2254
SELECT - 37 + + col0 / col1 AS col0 FROM tab1
----
-31
-31
-37

query I rowsort
SELECT DISTINCT + 39 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
39

query I rowsort
SELECT + col2 + 45 + - 97 FROM tab2
----
-14
-25
-26

query I rowsort
SELECT tab1.col0 * - ( 36 ) FROM tab1
----
-108
-2304
-2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2258
SELECT - CAST( + col2 AS SIGNED ) * col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-2258
SELECT - CAST ( + col2 AS INTEGER ) * col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2259
SELECT cor0.col1 DIV cor0.col1 - - col0 AS col0 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2259
SELECT cor0.col1 / cor0.col1 - - col0 AS col0 FROM tab0 cor0
----
25
36
90

query I rowsort
SELECT + + ( 43 ) * col0 * + col0 AS col1 FROM tab0 AS cor0
----
24768
340603
52675

query I rowsort
SELECT ALL col0 * col1 + 61 AS col2 FROM tab1
----
1101
139
701

query I rowsort
SELECT ALL col0 + - ( - col2 ) FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT - col0 + col0 + col1 AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT col2 * - ( col0 * col1 ) + - 31 FROM tab2
----
-119683
-51065
-5890

query I rowsort
SELECT tab0.col0 * tab0.col2 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT + 47 * - 34 AS col1 FROM tab0
----
-1598
-1598
-1598

query I rowsort
SELECT 90 * + 79 FROM tab0
----
7110
7110
7110

onlyif mysql # use DIV operator for integer division
query I rowsort label-2268
SELECT DISTINCT - col2 DIV - cor0.col2 + - col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
2

skipif mysql # not compatible
query I rowsort label-2268
SELECT DISTINCT - col2 / - cor0.col2 + - col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
2

query I rowsort
SELECT 75 * 64 + - cor0.col0 FROM tab2 AS cor0
----
4721
4722
4793

onlyif mysql # use DIV operator for integer division
query I rowsort label-2270
SELECT ALL + + col2 DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2270
SELECT ALL + + col2 / col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + 15 * - ( col2 ) + - 93 FROM tab2 AS cor0
----
-483
-498
-663

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2272
SELECT + CAST( NULL AS DECIMAL ) * col2 + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2272
SELECT + CAST ( NULL AS REAL ) * col2 + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 92 + - col2 AS col0 FROM tab0 AS cor0
----
10
59
91

query I rowsort
SELECT ALL + 67 * cor0.col2 FROM tab1 AS cor0
----
3618
3819
6432

query I rowsort
SELECT ALL + - ( col0 ) * col1 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2276
SELECT DISTINCT + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2276
SELECT DISTINCT + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2277
SELECT - col1 * + CAST( NULL AS SIGNED ) col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2277
SELECT - col1 * + CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 44 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

query I rowsort
SELECT - col1 * + col2 + 66 FROM tab0 AS cor0
----
-2772
-31
-7396

query I rowsort
SELECT DISTINCT + 25 AS col1 FROM tab0, tab0 AS cor0
----
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 12 col0 FROM tab2 cor0
----
-14
-15
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2282
SELECT + 11 DIV + 95 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2282
SELECT + 11 / + 95 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT + - ( - col0 ) + + col0 * CAST ( - 29 * col0 AS REAL ) AS col0 FROM tab2 AS cor0
----
-1414
-176358
-180910

query I rowsort
SELECT DISTINCT - - col2 + + ( col1 ) * col2 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2285
SELECT ALL col2 DIV 21 AS col1 FROM tab0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-2285
SELECT ALL col2 / 21 AS col1 FROM tab0
----
0
1
3

query I rowsort
SELECT DISTINCT - - 73 + col0 + col1 FROM tab1 AS cor0
----
102
147
166

query I rowsort
SELECT DISTINCT 67 * col0 FROM tab2 AS cor0
----
469
5226
5293

onlyif mysql # use DIV operator for integer division
query I rowsort label-2288
SELECT DISTINCT - col0 * - col0 + - col0 + col2 DIV cor0.col1 FROM tab1 AS cor0
----
4037
6327
8

skipif mysql # not compatible
query I rowsort label-2288
SELECT DISTINCT - col0 * - col0 + - col0 + col2 / cor0.col1 FROM tab1 AS cor0
----
4037
6327
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 + col0 col2 FROM tab1 AS cor0
----
-4
57
73

query I rowsort
SELECT + col1 * - col0 + ( cor0.col0 ) * + cor0.col2 AS col1 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT + col1 - + col2 * col1 * cor0.col0 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT col1 + ( + col1 + 15 ) FROM tab1
----
35
41
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2293
SELECT + col1 * col0 - col1 DIV col0 col1 FROM tab0 AS cor0
----
2061
3393
8098

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2293
SELECT + col1 * col0 - col1 / col0 col1 FROM tab0 AS cor0
----
2061
3393
8098

query I rowsort
SELECT + col0 - - col0 * col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - col0 + - col1 + + col0 * - col2 * - col2 FROM tab0 AS cor0
----
-97
26026
598256

onlyif mysql # use DIV operator for integer division
query I rowsort label-2296
SELECT - col0 * - CAST( col1 AS SIGNED ) DIV + cor0.col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2296
SELECT - col0 * - CAST ( col1 AS INTEGER ) / + cor0.col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL col2 * + col0 * 62 FROM tab2
----
11718
125736
186124

query I rowsort
SELECT DISTINCT - + col1 * col2 - + col2 AS col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + col1 * col2 - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL + + col1 + - col1 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + col1 * - col2 + - col0 AS col2 FROM tab1 AS cor0
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col0 + 90 * cor0.col2 * 96 col0 FROM tab0 AS cor0
----
285912
715778
8675

query I rowsort
SELECT ALL + col2 + 53 - 33 AS col0 FROM tab1 AS cor0
----
116
74
77

query I rowsort
SELECT + col2 + + 79 FROM tab0 AS cor0
----
112
161
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2305
SELECT DISTINCT + cor0.col2 DIV - 20 - cor0.col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-2305
SELECT DISTINCT + cor0.col2 / - 20 - cor0.col1 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT + col0 - + 57 * col2 AS col2 FROM tab0 AS cor0
----
-1857
-22
-4585

query I rowsort
SELECT ALL - - col1 + - 99 FROM tab1 cor0
----
-73
-86
-89

query I rowsort
SELECT DISTINCT - + col2 - cor0.col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT col0 + col0 * - 93 FROM tab0 AS cor0
----
-2208
-3220
-8188

query I rowsort
SELECT + - 40 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT cor0.col0 + ( - 42 ) FROM tab1, tab1 AS cor0
----
9 values hashing to e33306e8edb4cf7d8398ba3a6f72fbc3

query I rowsort
SELECT col0 + tab2.col2 * col1 AS col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - 81 FROM tab1, tab2 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to bab7cb237ee73283089388c330f59598

query I rowsort
SELECT DISTINCT + 82 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2
----
82

query I rowsort
SELECT DISTINCT + + ( col0 ) * - col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - ( ( - col2 ) ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col1 * 67 AS col1 FROM tab0
----
5762
6097
6499

query I rowsort
SELECT ALL + col0 + 89 FROM tab1
----
153
169
92

query I rowsort
SELECT DISTINCT col1 - + col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2321
SELECT DISTINCT ( - 62 ) DIV col2 AS col0 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-2321
SELECT DISTINCT ( - 62 ) / col2 AS col0 FROM tab1
----
-1
0

query I rowsort
SELECT + 28 AS col0 FROM tab2
----
28
28
28

query I rowsort
SELECT DISTINCT - - cor0.col0 + - 4 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-1
60
76

query I rowsort
SELECT + 46 + - tab2.col1 FROM tab2
----
-13
15
29

query I rowsort
SELECT DISTINCT + col0 + + col1 * - 59 + - col2 * - col2 FROM tab1 AS cor0
----
1385
2723
8529

query I rowsort
SELECT DISTINCT 11 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
11

query I rowsort
SELECT ALL + col2 * - col0 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT + + 49 AS col1 FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT 97 * - col2 FROM tab0 AS cor0
----
-3201
-7954
-97

query I rowsort
SELECT - 26 + - cor0.col2 FROM tab1 AS cor0
----
-122
-80
-83

query I rowsort
SELECT ( + col2 ) * 85 AS col0 FROM tab1 AS cor0
----
4590
4845
8160

query I rowsort
SELECT DISTINCT col1 * - col2 + col2 + - col1 FROM tab1 cor0
----
-1165
-1376
-523

query I rowsort
SELECT ALL - col2 * - col1 + - 40 AS col2 FROM tab0 AS cor0
----
2798
57
7422

query I rowsort
SELECT DISTINCT + 61 AS col0 FROM tab1 AS cor0
----
61

query I rowsort
SELECT DISTINCT - - col2 * - cor0.col2 + col0 AS col0 FROM tab1 cor0
----
-2913
-3185
-9136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2336
SELECT ALL - CAST( NULL AS SIGNED ) + - col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2336
SELECT ALL - CAST ( NULL AS INTEGER ) + - col1 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 43 + col2 FROM tab0
----
125
44
76

query I rowsort
SELECT col0 + - 6 * col2 AS col1 FROM tab1
----
-278
-321
-496

query I rowsort
SELECT DISTINCT cor0.col1 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - - col0 + + col2 * cor0.col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT 74 + col0 * ( + 39 ) AS col2 FROM tab0 AS cor0
----
1010
1439
3545

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2342
SELECT ALL - - col2 + + col0 + + CAST( + ( col0 ) AS SIGNED ) * col1 AS col2 FROM tab0 AS cor0
----
2121
3431
8270

skipif mysql # not compatible
query I rowsort label-2342
SELECT ALL - - col2 + + col0 + + CAST ( + ( col0 ) AS INTEGER ) * col1 AS col2 FROM tab0 AS cor0
----
2121
3431
8270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 13 * + col2 * + 86 col1 FROM tab2
----
29068
30186
42484

query I rowsort
SELECT - - 44 + + col1 AS col2 FROM tab1 AS cor0
----
54
57
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - - 91 col2 FROM tab0
----
-6
0
5

query I rowsort
SELECT col2 * - tab2.col1 - col1 AS col1 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT col2 * - ( col2 ) FROM tab0 cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col2 + 85 - + col2 col1 FROM tab2 cor0
----
2087
247
3049

query I rowsort
SELECT ALL - col2 * ( 58 ) FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT ALL - cor0.col0 * + 99 FROM tab0 AS cor0
----
-2376
-3465
-8811

onlyif mysql # use DIV operator for integer division
query I rowsort label-2351
SELECT ALL + col0 * + tab1.col1 + + col1 DIV + tab1.col2 AS col2 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-2351
SELECT ALL + col0 * + tab1.col1 + + col1 / + tab1.col2 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT - cor0.col1 * 82 - col1 FROM tab1 AS cor0
----
-1079
-2158
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2353
SELECT + CAST( NULL AS DECIMAL ) + - col2 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-2353
SELECT + CAST ( NULL AS REAL ) + - col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( ( - cor0.col2 ) ) + ( + col1 ) + + col1 FROM tab2 AS cor0
----
-4
35
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * col0 col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + + 61 * + ( + col0 ) FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT DISTINCT 82 * col2 AS col1 FROM tab0 cor0
----
2706
6724
82

query I rowsort
SELECT DISTINCT + 26 * - col1 AS col1 FROM tab1 cor0
----
-260
-338
-676

query I rowsort
SELECT + ( - cor0.col0 ) * - col2 + ( + col0 ) FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL + - col1 * - col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - + ( + col2 ) AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + 84 * + col2 * col2 AS col1 FROM tab0
----
564816
84
91476

query I rowsort
SELECT + 93 + - 53 AS col0 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT - + 37 * col2 + + col1 * col1 * col2 AS col0 FROM tab1 cor0
----
12672
34506
3591

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2365
SELECT + CAST( NULL AS SIGNED ) * col0 * - col2 - - 55 * col2 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2365
SELECT + CAST ( NULL AS INTEGER ) * col0 * - col2 - - 55 * col2 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 28 FROM tab2, tab1 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT + ( - col2 ) * - col1 * col1 + col0 AS col1 FROM tab1 cor0
----
16304
36507
5764

query I rowsort
SELECT ALL - col2 + + cor0.col0 * + col0 AS col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT ALL col0 * - 61 FROM tab1 AS cor0
----
-183
-3904
-4880

query I rowsort
SELECT + - 59 + - col1 AS col0 FROM tab0 cor0
----
-145
-150
-156

query I rowsort
SELECT + 19 * + tab0.col0 * + col0 AS col1 FROM tab0
----
10944
150499
23275

query I rowsort
SELECT DISTINCT + col0 * + 1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 22 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
22

query I rowsort
SELECT ALL col2 + ( - col0 ) * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL + cor0.col1 + + 94 * 52 FROM tab0 AS cor0
----
4974
4979
4985

query I rowsort
SELECT - col1 + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-2377
SELECT DISTINCT col2 DIV + tab1.col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2377
SELECT DISTINCT col2 / + tab1.col2 FROM tab1
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2378
SELECT - + col2 * - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-2378
SELECT - + col2 * - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 90 * 24 FROM tab2 AS cor0
----
2160
2160
2160

onlyif mysql # use DIV operator for integer division
query I rowsort label-2380
SELECT 78 DIV - col2 FROM tab0 AS cor0
----
-2
-78
0

skipif mysql # not compatible
query I rowsort label-2380
SELECT 78 / - col2 FROM tab0 AS cor0
----
-2
-78
0

query I rowsort
SELECT DISTINCT col1 * - 7 + + 66 + + col1 * col2 * tab1.col2 AS col1 FROM tab1
----
119783
32486
75700

query I rowsort
SELECT + - col2 * - 38 - cor0.col0 * + col2 FROM tab1 AS cor0
----
-1482
-4032
1890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 82 + col0 col1 FROM tab0 AS cor0
----
118
139
253

query I rowsort
SELECT + col2 * 84 * - tab2.col0 FROM tab2
----
-15876
-170352
-252168

query I rowsort
SELECT col0 + + 60 + - 76 * - col0 AS col2 FROM tab2
----
599
6066
6143

query I rowsort
SELECT + col2 * 88 FROM tab0
----
2904
7216
88

query I rowsort
SELECT DISTINCT - col0 + - 95 FROM tab1
----
-159
-175
-98

query I rowsort
SELECT + tab0.col1 + - 30 + col2 FROM tab0
----
143
68
89

query I rowsort
SELECT DISTINCT + col2 - - cor0.col2 * col1 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 NOT IN ( + col1 * col1 )
----

query I rowsort
SELECT DISTINCT + cor0.col0 - cor0.col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT col1 * col1 - - col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query III rowsort
SELECT * FROM tab1 WHERE col1 IN ( col2 * + col0 )
----

query I rowsort
SELECT ALL col0 + + col0 + - col1 * - tab2.col0 AS col0 FROM tab2
----
1501
231
4758

query I rowsort
SELECT + tab0.col2 + col2 * col2 AS col1 FROM tab0
----
1122
2
6806

query I rowsort
SELECT col2 * col1 + + col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT col2 * - tab1.col2 AS col2 FROM tab1
----
-2916
-3249
-9216

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT BETWEEN + col1 + col1 AND col0 / col2
----

query I rowsort
SELECT + col2 * col0 + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL col1 AS col2 FROM tab1 WHERE NOT ( - col0 ) = - col0
----

query I rowsort
SELECT ALL col0 * + tab2.col1 AS col2 FROM tab2 WHERE tab2.col0 + col0 * - col0 <= NULL
----

query I rowsort
SELECT + col1 - - col1 * - col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - tab0.col2 * col2 * - col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL col0 * col0 * col2 FROM tab0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + col1 * col0 col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-2406
SELECT col1 * + col0 + col2 DIV + col0 AS col2 FROM tab1 AS cor0
----
1041
640
96

skipif mysql # not compatible
query I rowsort label-2406
SELECT col1 * + col0 + col2 / + col0 AS col2 FROM tab1 AS cor0
----
1041
640
96

query I rowsort
SELECT col1 - - cor0.col0 * - cor0.col1 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2408
SELECT DISTINCT col2 + - col1 DIV + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2408
SELECT DISTINCT col2 + - col1 / + col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2409
SELECT cor0.col0 + + col0 DIV - cor0.col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-2409
SELECT cor0.col0 + + col0 / - cor0.col0 FROM tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + - col1 col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - col1 * tab2.col0 * col2 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-2412
SELECT DISTINCT - col2 DIV - col1 AS col0 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-2412
SELECT DISTINCT - col2 / - col1 AS col0 FROM tab2
----
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2413
SELECT DISTINCT col0 * col2 DIV - ( - col2 ) FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2413
SELECT DISTINCT col0 * col2 / - ( - col2 ) FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + tab2.col1 ) * col0 + - 15 col1 FROM tab2
----
1328
202
4587

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * col2 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col0 + - col1 * - ( - col0 + col0 ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col0 ) col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 85 * col2 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT ALL col1 + + 22 * col1 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT - col0 * - col1 - col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-2421
SELECT - - cor0.col0 * 7 + - 51 DIV + col2 FROM tab1 AS cor0
----
21
448
560

skipif mysql # not compatible
query I rowsort label-2421
SELECT - - cor0.col0 * 7 + - 51 / + col2 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT + col0 * + col1 + 54 - + cor0.col1 FROM tab1 AS cor0
----
106
1081
684

query I rowsort
SELECT ALL cor0.col2 * col1 AS col1 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2424
SELECT DISTINCT + - col0 DIV + col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2424
SELECT DISTINCT + - col0 / + col1 AS col1 FROM tab2 AS cor0
----
-1
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2425
SELECT - col2 * col1 DIV col1 - - col1 AS col0 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-2425
SELECT - col2 * col1 / col1 - - col1 AS col0 FROM tab0 AS cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 + col0 col2 FROM tab0
----
171
36
57

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT - col0 NOT IN ( - col1 )
----

query I rowsort
SELECT ALL col1 * col1 + - col2 AS col1 FROM tab1
----
43
622
73

query I rowsort
SELECT + tab2.col0 - col1 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL - col1 * col1 FROM tab0 WHERE NULL > NULL
----

query I rowsort
SELECT DISTINCT + col2 * col2 + col0 AS col1 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL + col0 + col1 * - col0 AS col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL col1 + tab0.col2 AS col1 FROM tab0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + tab2.col0 col1 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT - col0 + + tab1.col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT col0 FROM tab2 WHERE NOT NULL > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + tab0.col1 col0 FROM tab0
----
1322
662
8012

query I rowsort
SELECT DISTINCT + col0 * + col1 + + col1 AS col2 FROM tab1
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 col2 FROM tab0 WHERE NOT col2 * + col1 * col2 NOT BETWEEN col2 AND NULL
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( - col2 ) IN ( col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT * FROM tab2 WHERE col1 NOT IN ( - tab2.col2 + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT + + col0 + - col2 * col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT + tab2.col2 + col2 FROM tab2
----
52
54
76

query I rowsort
SELECT - col0 + tab0.col1 + + col0 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT - col1 + - col2 * col0 FROM tab2
----
-2087
-220
-3019

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL = - col2 * col1
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col0 IN ( col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2448
SELECT ALL + col1 * + col0 + + col1 DIV + tab2.col0 FROM tab2
----
1343
221
4602

skipif mysql # not compatible
query I rowsort label-2448
SELECT ALL + col1 * + col0 + + col1 / + tab2.col0 FROM tab2
----
1343
221
4602

query I rowsort
SELECT col0 * col2 + + tab0.col1 + + tab0.col0 AS col0 FROM tab0
----
167
7478
902

onlyif mysql # use DIV operator for integer division
query I rowsort label-2450
SELECT - col1 DIV - ( col0 ) + - col0 AS col2 FROM tab2 cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-2450
SELECT - col1 / - ( col0 ) + - col0 AS col2 FROM tab2 cor0
----
-3
-78
-79

query I rowsort
SELECT DISTINCT + + col1 * 74 + col0 AS col0 FROM tab1 AS cor0
----
1042
1927
804

onlyif mysql # use DIV operator for integer division
query I rowsort label-2452
SELECT ALL cor0.col1 + col2 DIV + 57 AS col2 FROM tab1 cor0
----
11
14
26

skipif mysql # not compatible
query I rowsort label-2452
SELECT ALL cor0.col1 + col2 / + 57 AS col2 FROM tab1 cor0
----
11
14
26

query I rowsort
SELECT ALL - col0 + 74 + - col1 * + col1 AS col1 FROM tab1 cor0
----
-175
-605
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2454
SELECT DISTINCT - col2 * + CAST( - 57 AS SIGNED ) AS col1 FROM tab1 cor0
----
3078
3249
5472

skipif mysql # not compatible
query I rowsort label-2454
SELECT DISTINCT - col2 * + CAST ( - 57 AS INTEGER ) AS col1 FROM tab1 cor0
----
3078
3249
5472

onlyif mysql # use DIV operator for integer division
query I rowsort label-2455
SELECT + + col2 + + col2 DIV - 86 col0 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2455
SELECT + + col2 + + col2 / - 86 col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + cor0.col1 + 36 AS col2 FROM tab1 AS cor0
----
46
49
62

query I rowsort
SELECT DISTINCT + col1 * - col1 + - 60 + col0 FROM tab2 AS cor0
----
-1014
-270
-3463

onlyif mysql # use DIV operator for integer division
query I rowsort label-2458
SELECT DISTINCT col1 DIV - 37 AS col2 FROM tab2 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2458
SELECT DISTINCT col1 / - 37 AS col2 FROM tab2 cor0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2459
SELECT - col2 * + CAST( NULL AS DECIMAL ) + + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2459
SELECT - col2 * + CAST ( NULL AS REAL ) + + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 * - ( col2 ) FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - 63 * col1 - tab0.col1 AS col0 FROM tab0
----
-5504
-5824
-6208

query I rowsort
SELECT - + col0 * - 33 FROM tab1 AS cor0
----
2112
2640
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2463
SELECT ALL - col2 - - col1 DIV col2 AS col0 FROM tab0 AS cor0
----
-31
-81
96

skipif mysql # not compatible
query I rowsort label-2463
SELECT ALL - col2 - - col1 / col2 AS col0 FROM tab0 AS cor0
----
-31
-81
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - ( col0 ) * - col0 col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL - col0 * col2 + 82 AS col1 FROM tab1 AS cor0
----
-3566
-7598
-80

query I rowsort
SELECT ALL cor0.col1 - col2 * col0 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT + col0 + - 85 FROM tab2
----
-6
-7
-78

query I rowsort
SELECT col0 * 59 FROM tab2
----
413
4602
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-2469
SELECT DISTINCT col0 DIV - ( col1 * col1 ) col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2469
SELECT DISTINCT col0 / - ( col1 * col1 ) col1 FROM tab0
----
0

query I rowsort
SELECT - ( 99 ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2471
SELECT DISTINCT + - 11 + col2 + 85 * 74 DIV - col1 FROM tab2 AS cor0
----
-186
-343
-91

skipif mysql # not compatible
query I rowsort label-2471
SELECT DISTINCT + - 11 + col2 + 85 * 74 / - col1 FROM tab2 AS cor0
----
-186
-343
-91

query I rowsort
SELECT DISTINCT + col0 * col1 - + 44 FROM tab0 AS cor0
----
2020
3351
8055

query I rowsort
SELECT DISTINCT + ( col1 ) + - col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - ( col2 ) * + col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - 98 * - col0 - col1 * - col2 FROM tab1 AS cor0
----
1698
6842
9088

query I rowsort
SELECT DISTINCT - + col0 + col1 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT 52 FROM tab1, tab0, tab0 cor0
----
52

query I rowsort
SELECT ALL 83 + + col2 AS col1 FROM tab1
----
137
140
179

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col1 col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT tab2.col2 * - col1 * col1 + col1 AS col1 FROM tab2
----
-10965
-25916
-90447

onlyif mysql # use DIV operator for integer division
query I rowsort label-2481
SELECT cor0.col2 + col0 DIV 43 FROM tab1 AS cor0
----
54
58
97

skipif mysql # not compatible
query I rowsort label-2481
SELECT cor0.col2 + col0 / 43 FROM tab1 AS cor0
----
54
58
97

query I rowsort
SELECT - 7 + tab2.col0 * - col0 + col2 FROM tab2
----
-29
-6065
-6210

query I rowsort
SELECT ALL + 37 AS col2 FROM tab1 cor0
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-2484
SELECT - col0 DIV ( col0 + col2 ) AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2484
SELECT - col0 / ( col0 + col2 ) AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + cor0.col2 * col1 + cor0.col1 * - col1 FROM tab0 AS cor0
----
-4558
-819
-9312

query I rowsort
SELECT DISTINCT - col1 * col0 * - ( col2 ) AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT col2 + 44 FROM tab2 AS cor0
----
70
71
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2488
SELECT + - col1 * col0 * ( cor0.col0 ) + - col1 - - col0 DIV col1 AS col2 FROM tab0 AS cor0
----
-118922
-49622
-720902

skipif mysql # not compatible
query I rowsort label-2488
SELECT + - col1 * col0 * ( cor0.col0 ) + - col1 - - col0 / col1 AS col2 FROM tab0 AS cor0
----
-118922
-49622
-720902

query I rowsort
SELECT + cor0.col0 + + col1 * col2 * col2 AS col1 FROM tab2 AS cor0
----
22606
24627
39962

query I rowsort
SELECT - ( - col1 * - col1 + tab0.col0 ) FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT - tab2.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL ( - col0 ) * col1 + + 19 * col1 AS col1 FROM tab0 AS cor0
----
-1552
-430
-6370

query I rowsort
SELECT DISTINCT + ( + col0 ) * + col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL + - cor0.col2 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT DISTINCT - + col0 - cor0.col1 * col0 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT 59 * - col1 + - col0 FROM tab2 AS cor0
----
-1082
-1836
-3559

query I rowsort
SELECT DISTINCT 86 * - col1 FROM tab0 cor0
----
-7396
-7826
-8342

query I rowsort
SELECT + - col1 + - 26 AS col1 FROM tab2 AS cor0
----
-43
-57
-85

query I rowsort
SELECT - + 22 + col0 * 43 AS col1 FROM tab2 AS cor0
----
279
3332
3375

onlyif mysql # use DIV operator for integer division
query I rowsort label-2500
SELECT + 53 * + col1 DIV col1 AS col1 FROM tab0 AS cor0
----
53
53
53

skipif mysql # not compatible
query I rowsort label-2500
SELECT + 53 * + col1 / col1 AS col1 FROM tab0 AS cor0
----
53
53
53

query I rowsort
SELECT ALL + - ( col1 ) * + col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + ( col1 ) * + 90 FROM tab0 AS cor0
----
7740
8190
8730

query I rowsort
SELECT + + col2 * - col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + 75 FROM tab2
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + + cor0.col2 col1 FROM tab2, tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 489b7b2b5c4980d50e86e51be30361c3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 col0 FROM tab0, tab0 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT ALL - ( - col0 ) * - cor0.col0 + + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT - - 62 - col2 FROM tab2 AS cor0
----
24
35
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2511
SELECT - 53 * col1 + col1 DIV + cor0.col1 + col2 FROM tab2 AS cor0
----
-1615
-3100
-862

skipif mysql # not compatible
query I rowsort label-2511
SELECT - 53 * col1 + col1 / + cor0.col1 + col2 FROM tab2 AS cor0
----
-1615
-3100
-862

query I rowsort
SELECT ( col1 ) * col1 + + col1 - col2 AS col0 FROM tab1
----
53
648
86

query I rowsort
SELECT col0 + + 74 AS col0 FROM tab2
----
152
153
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - 65 * col0 col1 FROM tab0 AS cor0
----
-1527
-2274
-5703

query I rowsort
SELECT - 13 * + tab1.col2 * + col0 FROM tab1
----
-2106
-47424
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col0 ) * tab0.col0 col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT - col2 * 13 AS col0 FROM tab1 AS cor0
----
-1248
-702
-741

query I rowsort
SELECT - + col0 * ( - cor0.col1 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col2 * 65 AS col2 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT + 94 * 83 FROM tab0, tab1 cor0
----
9 values hashing to 2d20dcce6da83a3858f8b85d4682b863

query I rowsort
SELECT - + cor0.col0 * + 19 * cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
-12103
-1428
-19664

onlyif mysql # use DIV operator for integer division
query I rowsort label-2522
SELECT col1 DIV col1 + + 57 * col2 FROM tab2 AS cor0
----
1483
1540
2167

skipif mysql # not compatible
query I rowsort label-2522
SELECT col1 / col1 + + 57 * col2 FROM tab2 AS cor0
----
1483
1540
2167

query I rowsort
SELECT DISTINCT 40 AS col1 FROM tab1 cor0
----
40

query I rowsort
SELECT ALL ( - 39 ) * + col2 AS col2 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT + 25 + col1 * col1 FROM tab0 AS cor0
----
7421
8306
9434

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - 81 * + col0 col0 FROM tab2 cor0
----
-536
-6259
-6382

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 45 col1 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT + - cor0.col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - - cor0.col0 + 95 * col2 AS col0 FROM tab0 AS cor0
----
130
3159
7879

query I rowsort
SELECT DISTINCT + 20 * + col1 AS col0 FROM tab0 AS cor0
----
1720
1820
1940

query I rowsort
SELECT ALL + col1 * col2 - + col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL + 34 FROM tab0 cor0
----
34
34
34

query I rowsort
SELECT DISTINCT 0 * 70 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + + 7 * + col1 FROM tab1 AS cor0
----
182
70
91

query I rowsort
SELECT ALL + + 53 * - 95 - col0 FROM tab1 cor0
----
-5038
-5099
-5115

query I rowsort
SELECT DISTINCT + col2 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - 24 AS col1 FROM tab0 AS cor0
----
-24

query I rowsort
SELECT - 54 * + col2 AS col1 FROM tab2 AS cor0
----
-1404
-1458
-2052

query I rowsort
SELECT ALL 39 * col1 AS col0 FROM tab1 AS cor0
----
1014
390
507

query I rowsort
SELECT cor0.col1 * + col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT ( 24 ) FROM tab2 AS cor0
----
24

query I rowsort
SELECT DISTINCT ( - ( col1 ) ) * + col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-2543
SELECT DISTINCT - col0 * col1 + + 68 + col1 DIV - col2 FROM tab1
----
-10
-572
-972

skipif mysql # not compatible
query I rowsort label-2543
SELECT DISTINCT - col0 * col1 + + 68 + col1 / - col2 FROM tab1
----
-10
-572
-972

query I rowsort
SELECT - col1 * - col0 + + col1 + + col1 AS col2 FROM tab0 AS cor0
----
2236
3589
8281

query I rowsort
SELECT ALL + 84 * col0 * + col1 + ( col1 ) * + 98 FROM tab2
----
114478
21266
392350

query I rowsort
SELECT DISTINCT + col0 + - col0 + col2 * 3 * - col2 AS col2 FROM tab0 AS cor0
----
-20172
-3
-3267

query I rowsort
SELECT ALL - ( + col1 ) + + col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 + col2 * + col0 col0 FROM tab2 cor0
----
1026
3562
3648

query I rowsort
SELECT - col0 + col2 * + col0 AS col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT - col0 * + col0 AS col2 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - cor0.col0 * + cor0.col2 + - col0 * + 73 + - col0 FROM tab2 AS cor0
----
-707
-7800
-8848

query I rowsort
SELECT ALL col2 - + col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT cor0.col2 * + col0 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + col1 - col1 * cor0.col2 * ( col0 ) FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT - col1 - - col2 * - cor0.col0 * 27 FROM tab2 AS cor0
----
-5134
-54815
-81071

query I rowsort
SELECT DISTINCT + col2 * col1 - + col2 * col0 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT ALL - + col1 * + 69 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
510324
571389
649221

query I rowsort
SELECT 40 + 45 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

query I rowsort
SELECT DISTINCT 64 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
64

query I rowsort
SELECT ALL + ( col1 ) + + col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT + ( 89 ) * - tab0.col2 + col1 * - col1 AS col1 FROM tab0
----
-10333
-15579
-9498

query I rowsort
SELECT DISTINCT - 28 AS col1 FROM tab2 cor0
----
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + col2 col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT col2 + + ( col0 ) + ( + col1 ) AS col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT + 93 * col1 FROM tab1 AS cor0
----
1209
2418
930

query I rowsort
SELECT - col2 * + col0 + - col2 AS col1 FROM tab1 AS cor0
----
-216
-3705
-7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - - col1 col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - 64 + cor0.col2 FROM tab0 AS cor0
----
-31
-63
18

query I rowsort
SELECT - col0 * + col0 - + col2 AS col2 FROM tab2 cor0
----
-6110
-6279
-76

query I rowsort
SELECT + + col0 + cor0.col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + + col2 * - col0 + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL - 87 - - col1 * - col0 FROM tab0 AS cor0
----
-2151
-3482
-8186

query I rowsort
SELECT ALL + ( + col0 ) * - ( 63 ) + + col1 FROM tab1 AS cor0
----
-163
-4022
-5027

query I rowsort
SELECT DISTINCT col2 + + col2 + + col1 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT - + 1 * col2 * - col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2576
SELECT - ( tab2.col0 ) DIV col1 AS col2 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2576
SELECT - ( tab2.col0 ) / col1 AS col2 FROM tab2
----
-1
-4
0

query I rowsort
SELECT - + col0 * - col1 + 93 FROM tab0 AS cor0
----
2157
3488
8192

query I rowsort
SELECT + col1 * - col0 * col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT ALL - col2 * + 30 FROM tab1 AS cor0
----
-1620
-1710
-2880

query I rowsort
SELECT DISTINCT - + cor0.col1 + cor0.col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + - col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT 62 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT ALL - + col0 * - 6 + + 86 FROM tab2 AS cor0
----
128
554
560

query I rowsort
SELECT DISTINCT + col1 * 14 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT ALL + + col2 * + 86 + col2 FROM tab0 AS cor0
----
2871
7134
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2586
SELECT ALL - col1 * - ( - col1 + col0 ) * CAST( col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-127968
-16198
-210490

skipif mysql # not compatible
query I rowsort label-2586
SELECT ALL - col1 * - ( - col1 + col0 ) * CAST ( col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-127968
-16198
-210490

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2587
SELECT DISTINCT col2 * CAST( col2 + - col0 * - col0 AS SIGNED ) col1 FROM tab0 AS cor0
----
1226
20097
656246

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2587
SELECT DISTINCT col2 * CAST ( col2 + - col0 * - col0 AS INTEGER ) col1 FROM tab0 AS cor0
----
1226
20097
656246

query I rowsort
SELECT + + 16 * 79 FROM tab0 AS cor0
----
1264
1264
1264

query I rowsort
SELECT - 5 FROM tab1, tab0 AS cor0
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2590
SELECT - - CAST( NULL AS SIGNED ) * col2 + col0 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2590
SELECT - - CAST ( NULL AS INTEGER ) * col2 + col0 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 + 13 * + col2 FROM tab1 AS cor0
----
1328
705
805

query I rowsort
SELECT - ( - col0 ) * col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 9 AS col2 FROM tab2 AS cor0
----
9
9
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2594
SELECT ALL + ( col0 ) DIV - col1 col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2594
SELECT ALL + ( col0 ) / - col1 col2 FROM tab0
----
0
0
0

query I rowsort
SELECT - 31 * + col1 FROM tab1
----
-310
-403
-806

query I rowsort
SELECT + cor1.col1 + 62 FROM tab1 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to a04a99974b5b85366b02182f72a9de09

query I rowsort
SELECT 15 AS col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT DISTINCT - 32 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
-32

query I rowsort
SELECT + col2 * + ( 32 ) FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT + cor0.col1 + + 28 * + col2 AS col2 FROM tab1 AS cor0
----
1538
1606
2701

query I rowsort
SELECT DISTINCT - col0 - 74 * - col0 FROM tab2 AS cor0
----
511
5694
5767

query I rowsort
SELECT ALL col1 - col1 * col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT 98 - + col1 * + col2 AS col1 FROM tab0
----
-2740
-7364
1

query I rowsort
SELECT + + cor0.col1 + - col0 * - 10 AS col1 FROM tab1 AS cor0
----
56
650
813

query I rowsort
SELECT ALL - + ( col2 ) AS col2 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2606
SELECT col1 DIV - cor0.col2 + + 15 AS col1 FROM tab1 AS cor0
----
15
15
15

skipif mysql # not compatible
query I rowsort label-2606
SELECT col1 / - cor0.col2 + + 15 AS col1 FROM tab1 AS cor0
----
15
15
15

query I rowsort
SELECT DISTINCT - + 89 * col1 AS col2 FROM tab0 AS cor0
----
-7654
-8099
-8633

onlyif mysql # use DIV operator for integer division
query I rowsort label-2608
SELECT ALL + col0 + - cor0.col0 DIV 49 AS col0 FROM tab1 AS cor0
----
3
63
79

skipif mysql # not compatible
query I rowsort label-2608
SELECT ALL + col0 + - cor0.col0 / 49 AS col0 FROM tab1 AS cor0
----
3
63
79

query I rowsort
SELECT - col2 * - col1 * 84 FROM tab1 AS cor0
----
104832
117936
47880

onlyif mysql # use DIV operator for integer division
query I rowsort label-2610
SELECT ( - cor0.col0 ) DIV - 60 + col0 FROM tab0 AS cor0
----
24
35
90

skipif mysql # not compatible
query I rowsort label-2610
SELECT ( - cor0.col0 ) / - 60 + col0 FROM tab0 AS cor0
----
24
35
90

query I rowsort
SELECT ALL col0 + col2 * - 10 FROM tab2 AS cor0
----
-182
-263
-301

query I rowsort
SELECT 95 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT DISTINCT - + cor0.col0 * ( col2 ) + col1 + ( col2 ) FROM tab2 AS cor0
----
-131
-1943
-2947

query I rowsort
SELECT + - col0 + col1 * + col2 AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL - col1 * - ( - col2 ) + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + col0 * - 38 AS col0 FROM tab1 AS cor0
----
-114
-2432
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-2617
SELECT DISTINCT - col2 DIV - col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2617
SELECT DISTINCT - col2 / - col1 AS col0 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT - + ( col2 ) + - col0 DIV + 14 FROM tab2 AS cor0
----
-27
-31
-43

skipif mysql # not compatible
query I rowsort label-2618
SELECT - + ( col2 ) + - col0 / + 14 FROM tab2 AS cor0
----
-27
-31
-43

query I rowsort
SELECT DISTINCT 16 - cor0.col2 * - col0 * - col1 AS col2 FROM tab2 cor0
----
-119636
-51018
-5843

query I rowsort
SELECT DISTINCT - ( cor1.col0 ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-24
-35
-89

query I rowsort
SELECT + col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col0 ) * cor0.col0 col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2623
SELECT col0 DIV + col1 + + CAST( + col1 AS SIGNED ) * col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-2623
SELECT col0 / + col1 + + CAST ( + col1 AS INTEGER ) * col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + 54 + + col0 FROM tab0 AS cor0
----
143
78
89

query I rowsort
SELECT DISTINCT + 60 * col0 + col0 AS col2 FROM tab1 AS cor0
----
183
3904
4880

query I rowsort
SELECT - cor0.col1 * + col0 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 66 * - tab0.col0 AS col0 FROM tab0
----
-1584
-2310
-5874

query I rowsort
SELECT DISTINCT + - 52 * col0 + + cor0.col2 FROM tab2 AS cor0
----
-337
-4030
-4070

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 28 * col2 col1 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT DISTINCT 68 * cor0.col0 - col1 FROM tab0 AS cor0
----
1546
2283
5961

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 + col1 * CAST ( + col1 AS REAL ) FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2632
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - 9 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2632
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - 9 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2633
SELECT DISTINCT + col0 DIV + col1 + + col1 AS col2 FROM tab1
----
16
19
26

skipif mysql # not compatible
query I rowsort label-2633
SELECT DISTINCT + col0 / + col1 + + col1 AS col2 FROM tab1
----
16
19
26

query I rowsort
SELECT ALL col2 + col1 * - 40 * + col0 + + col0 FROM tab2
----
-183976
-53603
-8646

query I rowsort
SELECT col2 * - col0 - 18 FROM tab0
----
-53
-7316
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * col0 + col0 col1 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - - col1 col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + - col1 + cor0.col2 * col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - 16 * col1 FROM tab2
----
-272
-496
-944

query I rowsort
SELECT + - col0 * col2 + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - col0 * col0 - + col2 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT tab2.col2 * + col2 * col1 + - col2 AS col0 FROM tab2
----
22572
24510
39858

query I rowsort
SELECT DISTINCT ( col2 ) + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + - ( + cor0.col1 ) * + col2 + + 90 * - col0 FROM tab1 AS cor0
----
-1674
-6330
-8448

query I rowsort
SELECT + - 5 * col2 - - col1 * - ( - ( col2 ) ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
10792
25812
90376

query I rowsort
SELECT DISTINCT - 31 * ( - col1 ) FROM tab0 AS cor0
----
2666
2821
3007

query I rowsort
SELECT ALL - - 70 + 23 FROM tab1 AS cor0
----
93
93
93

query I rowsort
SELECT - - 81 - 66 AS col2 FROM tab2 AS cor0
----
15
15
15

query I rowsort
SELECT DISTINCT col1 * col2 * + col2 + + col2 FROM tab2 cor0
----
22626
24586
39910

query I rowsort
SELECT ALL - col0 - - col2 * col2 AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL - col1 * - ( col0 ) AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2652
SELECT DISTINCT + col1 * - 17 + col0 * + CAST( 36 * + cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
-118
147286
230179

skipif mysql # not compatible
query I rowsort label-2652
SELECT DISTINCT + col1 * - 17 + col0 * + CAST ( 36 * + cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
-118
147286
230179

onlyif mysql # use DIV operator for integer division
query I rowsort label-2653
SELECT ALL ( + col1 ) DIV cor0.col0 + ( - col2 ) - col2 AS col0 FROM tab2 AS cor0
----
-50
-52
-76

skipif mysql # not compatible
query I rowsort label-2653
SELECT ALL ( + col1 ) / cor0.col0 + ( - col2 ) - col2 AS col0 FROM tab2 AS cor0
----
-50
-52
-76

query I rowsort
SELECT ALL + col0 * cor0.col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT tab1.col2 * + tab1.col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + 93 AS col2 FROM tab0
----
93
93
93

query I rowsort
SELECT + 69 * - col0 + col0 AS col0 FROM tab1
----
-204
-4352
-5440

query I rowsort
SELECT DISTINCT cor1.col0 AS col0 FROM tab2 cor0 CROSS JOIN tab1, tab0 AS cor1
----
24
35
89

query I rowsort
SELECT ALL - col1 * + col0 + 53 AS col2 FROM tab1 AS cor0
----
-25
-587
-987

query I rowsort
SELECT - col0 * + 2 FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2661
SELECT cor0.col0 * CAST( - 2 AS SIGNED ) FROM tab1 AS cor0
----
-128
-160
-6

skipif mysql # not compatible
query I rowsort label-2661
SELECT cor0.col0 * CAST ( - 2 AS INTEGER ) FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT + - col1 + - cor0.col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - col0 * 91 - col1 FROM tab2 AS cor0
----
-668
-7157
-7206

query I rowsort
SELECT DISTINCT + - col2 + - cor0.col2 * 4 AS col2 FROM tab0 AS cor0
----
-165
-410
-5

query I rowsort
SELECT ALL col2 * ( - col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + col0 * - 50 * + tab1.col1 + 56 AS col0 FROM tab1
----
-31944
-3844
-51944

query I rowsort
SELECT DISTINCT col2 * ( - col2 ) AS col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT - 34 AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 5b88331e40da4796cc4826c442aa45f7

query I rowsort
SELECT + 55 * + 91 + col0 AS col2 FROM tab2 AS cor0
----
5012
5083
5084

query I rowsort
SELECT ALL - col1 + + 79 FROM tab1 AS cor0
----
53
66
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-2671
SELECT - - 18 DIV - col2 + - col2 AS col1 FROM tab0 AS cor0
----
-19
-33
-82

skipif mysql # not compatible
query I rowsort label-2671
SELECT - - 18 / - col2 + - col2 AS col1 FROM tab0 AS cor0
----
-19
-33
-82

query I rowsort
SELECT DISTINCT 9 + - ( - col1 ) AS col2 FROM tab0 AS cor0
----
100
106
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2673
SELECT ALL + col2 DIV + 36 FROM tab0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2673
SELECT ALL + col2 / + 36 FROM tab0
----
0
0
2

query I rowsort
SELECT DISTINCT + 89 + col2 * + cor0.col2 AS col1 FROM tab0 cor0
----
1178
6813
90

query I rowsort
SELECT ALL + - 78 AS col1 FROM tab0 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2676
SELECT DISTINCT 28 DIV + 27 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2676
SELECT DISTINCT 28 / + 27 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2677
SELECT ALL ( col0 ) + + col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2677
SELECT ALL ( col0 ) + + col0 / - col1 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - cor0.col0 + - col1 * - ( - col0 ) * - col2 FROM tab2 cor0
----
119574
50955
5852

onlyif mysql # use DIV operator for integer division
query I rowsort label-2679
SELECT ALL - ( + col1 ) DIV - 57 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2679
SELECT ALL - ( + col1 ) / - 57 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col2 - col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + col0 * col0 * + ( cor0.col1 * col2 ) AS col0 FROM tab1 AS cor0
----
12636
2334720
7987200

onlyif mysql # use DIV operator for integer division
query I rowsort label-2682
SELECT DISTINCT + cor0.col0 DIV col1 FROM tab1 cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-2682
SELECT DISTINCT + cor0.col0 / col1 FROM tab1 cor0
----
0
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 31 + - col0 col0 FROM tab2
----
-47
-48
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2684
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 48 FROM tab1, tab2 cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2684
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 48 FROM tab1, tab2 cor0, tab1 AS cor1
----
NULL

query I rowsort
SELECT 29 * - col2 + col2 FROM tab2 cor0
----
-1064
-728
-756

query I rowsort
SELECT col0 + col1 * - col2 * + col2 FROM tab0 AS cor0
----
-611795
-62
-93630

query I rowsort
SELECT - col2 * - col1 + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2688
SELECT - CAST( NULL AS SIGNED ) + 71 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2688
SELECT - CAST ( NULL AS INTEGER ) + 71 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor1.col1 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + 96 + col2 AS col2 FROM tab1 AS cor0
----
150
153
192

query I rowsort
SELECT - ( + 78 ) - cor0.col2 * col0 FROM tab0 AS cor0
----
-113
-7376
-870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 49 col2 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT + ( col0 ) * col1 + + col1 + col2 AS col1 FROM tab1 AS cor0
----
1149
158
707

query I rowsort
SELECT ALL 38 + col1 * - col1 FROM tab0
----
-7358
-8243
-9371

query I rowsort
SELECT DISTINCT col0 + - ( col1 ) FROM tab0
----
-2
-62

query I rowsort
SELECT - 43 * - col1 FROM tab1
----
1118
430
559

query I rowsort
SELECT DISTINCT + col0 * - col0 * + cor0.col2 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-233529
-540
-614496

query I rowsort
SELECT - ( + col0 ) * col0 * col0 - - col0 FROM tab2 AS cor0
----
-336
-474474
-492960

query I rowsort
SELECT - cor0.col1 * - col1 + col2 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2700
SELECT - CAST( NULL AS DECIMAL ) * col1 / col2 col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2700
SELECT - CAST ( NULL AS REAL ) * col1 / col2 col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - + col1 + ( + 7 ) * - col0 FROM tab1 AS cor0
----
-458
-47
-573

query I rowsort
SELECT DISTINCT col0 + 59 + - col2 FROM tab2
----
100
111
39

query I rowsort
SELECT + + 22 AS col2 FROM tab1 cor0
----
22
22
22

query I rowsort
SELECT 27 * + col2 AS col2 FROM tab0 AS cor0
----
2214
27
891

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 + + ( + cor0.col1 ) col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col1 - - col1 * tab1.col2 AS col1 FROM tab1
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-2708
SELECT DISTINCT + col0 DIV col1 + + 51 - col1 * col2 FROM tab1
----
-1191
-1353
-513

skipif mysql # not compatible
query I rowsort label-2708
SELECT DISTINCT + col0 / col1 + + 51 - col1 * col2 FROM tab1
----
-1191
-1353
-513

query I rowsort
SELECT ALL + 20 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT 69 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT + 72 + cor0.col2 FROM tab2 cor0
----
110
98
99

query I rowsort
SELECT + col2 * col2 - col1 AS col1 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-2713
SELECT - + cor0.col1 DIV + col2 + col1 AS col0 FROM tab0 AS cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-2713
SELECT - + cor0.col1 / + col2 + col1 AS col0 FROM tab0 AS cor0
----
0
84
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2714
SELECT ALL - col2 * col1 DIV - col1 col1 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2714
SELECT ALL - col2 * col1 / - col1 col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col2 + + cor0.col1 * col0 AS col0 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + cor0.col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 + + ( ( col0 ) ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col2 * 54 + - col2 FROM tab1 cor0
----
2862
3021
5088

query I rowsort
SELECT - - col2 + ( col0 ) + col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT - col1 * + col1 * - col2 + + col0 AS col2 FROM tab0 AS cor0
----
244092
679131
9444

query I rowsort
SELECT ALL col2 + col1 * 47 AS col0 FROM tab1 AS cor0
----
1276
527
707

query I rowsort
SELECT col1 - cor0.col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT col2 + - col1 * col0 * + col2 + + ( ( + col2 ) ) AS col0 FROM tab0 AS cor0
----
-3393
-663954
-68046

query I rowsort
SELECT ALL + - col2 * 90 * + col0 + col2 AS col0 FROM tab2 AS cor0
----
-16983
-182494
-270142

query I rowsort
SELECT - + col2 + + 29 + - col1 * - cor0.col1 FROM tab2 AS cor0
----
280
3484
963

query I rowsort
SELECT DISTINCT - col0 + 30 * + 67 AS col2 FROM tab0 AS cor0
----
1921
1975
1986

query I rowsort
SELECT ALL + col2 * - col2 * col2 - col2 AS col1 FROM tab0 cor0
----
-2
-35970
-551450

query I rowsort
SELECT ALL + - col0 * + 9 FROM tab0 AS cor0
----
-216
-315
-801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2729
SELECT DISTINCT + col0 * + CAST( NULL AS SIGNED ) * + col2 + - col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2729
SELECT DISTINCT + col0 * + CAST ( NULL AS INTEGER ) * + col2 + - col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 - cor0.col2 * col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL - + col2 + + ( + col1 ) + + cor0.col0 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT DISTINCT + col2 * + col1 + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT col2 + - 89 * tab1.col2 * + col1 AS col0 FROM tab1
----
-110976
-124902
-50673

query I rowsort
SELECT ALL col2 + - 60 * 17 FROM tab1
----
-924
-963
-966

query I rowsort
SELECT + col1 + col1 + col2 AS col0 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT ALL + + 66 * cor0.col2 + + col2 FROM tab0 AS cor0
----
2211
5494
67

query I rowsort
SELECT DISTINCT - ( 72 ) * col2 FROM tab0 AS cor0
----
-2376
-5904
-72

query I rowsort
SELECT ALL ( 71 ) AS col2 FROM tab1 AS cor0
----
71
71
71

query I rowsort
SELECT ALL 55 + cor0.col0 FROM tab0 AS cor0
----
144
79
90

query I rowsort
SELECT DISTINCT - tab2.col1 + col0 * tab2.col1 FROM tab2
----
1326
186
4543

query I rowsort
SELECT - col0 - - col0 * col2 AS col0 FROM tab1
----
159
3584
7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2742
SELECT - col1 * col1 + ( + col0 ) * - CAST( + 37 * + col0 AS SIGNED ) + col0 AS col2 FROM tab2
----
-228511
-231127
-2767

skipif mysql # not compatible
query I rowsort label-2742
SELECT - col1 * col1 + ( + col0 ) * - CAST ( + 37 * + col0 AS INTEGER ) + col0 AS col2 FROM tab2
----
-228511
-231127
-2767

query I rowsort
SELECT DISTINCT + col1 + col1 * 81 FROM tab2
----
1394
2542
4838

query I rowsort
SELECT + 67 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

onlyif mysql # use DIV operator for integer division
query I rowsort label-2745
SELECT DISTINCT - col2 DIV col0 + col1 AS col0 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-2745
SELECT DISTINCT - col2 / col0 + col1 AS col0 FROM tab0 AS cor0
----
85
91
97

query I rowsort
SELECT + + 71 AS col1 FROM tab2 cor0
----
71
71
71

query I rowsort
SELECT ALL col2 * + col0 + col2 * + col1 AS col1 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT - + ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + - col2 * + cor0.col0 * 91 + 10 FROM tab2 AS cor0
----
-17189
-184538
-273172

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + col2 * + col2 * col2 FROM tab2 AS cor0
----
16042
18846
54226

query I rowsort
SELECT - + ( + col2 ) * + cor0.col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2752
SELECT DISTINCT - - col2 * - col1 + - CAST( + col2 AS SIGNED ) * col1 AS col1 FROM tab1 cor0
----
-1140
-2496
-2808

skipif mysql # not compatible
query I rowsort label-2752
SELECT DISTINCT - - col2 * - col1 + - CAST ( + col2 AS INTEGER ) * col1 AS col1 FROM tab1 cor0
----
-1140
-2496
-2808

query I rowsort
SELECT ALL + + col1 + + cor0.col0 * - col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL 91 * col1 AS col1 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT ALL col0 + col2 * - cor0.col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ( - 42 ) - - tab2.col2 FROM tab2
----
-15
-16
-4

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab1, tab0, tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - 61 + 86 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT DISTINCT - + col1 * + col2 - col1 * cor0.col1 FROM tab1 AS cor0
----
-1417
-2080
-670

query I rowsort
SELECT + col2 * col0 + ( + col1 ) AS col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT ALL + ( - col1 ) AS col0 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL - cor0.col2 * + cor0.col2 FROM tab0, tab2 cor0
----
9 values hashing to 309d8ba6d1ea89e6795c82dda466e1ce

query I rowsort
SELECT + ( 49 ) * + cor0.col1 * 82 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to edc07cc5c7e26205c3ffe8dc6ab84a1c

query I rowsort
SELECT ALL 89 * - col2 AS col1 FROM tab0
----
-2937
-7298
-89

query I rowsort
SELECT - 62 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

query I rowsort
SELECT col1 * col1 + - col2 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT tab0.col1 + ( col0 ) + - col2 AS col1 FROM tab0
----
131
77
98

query I rowsort
SELECT - col1 + - col2 * + 84 FROM tab2
----
-2243
-2299
-3209

query I rowsort
SELECT + - 87 + 97 FROM tab0 AS cor0
----
10
10
10

query I rowsort
SELECT - 21 + - col1 FROM tab2 AS cor0
----
-38
-52
-80

query I rowsort
SELECT - 6 + 69 * col2 AS col2 FROM tab1 AS cor0
----
3720
3927
6618

query I rowsort
SELECT + 3 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT DISTINCT - 50 FROM tab1, tab2, tab2 AS cor0, tab2 AS cor1
----
-50

query I rowsort
SELECT DISTINCT col2 + + col0 * + ( col2 ) FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col2 + 11 FROM tab0
----
-22
-71
10

query I rowsort
SELECT col0 * - 16 FROM tab2
----
-112
-1248
-1264

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( cor0.col2 ) * col1 * + col0 col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 2 + cor0.col2 col0 FROM tab2 AS cor0
----
24
25
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * cor0.col0 + - col1 col2 FROM tab1 cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT + 33 - - 30 FROM tab0 AS cor0
----
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( 33 ) * col2 + + ( + 77 * - cor0.col1 ) col0 FROM tab0 AS cor0
----
-7502
-7711
-9713

query I rowsort
SELECT ALL col0 * + col1 + + col1 * col0 AS col2 FROM tab2 AS cor0
----
2686
434
9204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col1 + - tab2.col0 ) col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL - ( + col2 ) * col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - 5 * col0 + + col0 * 8 AS col0 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT ALL + 24 * col2 AS col2 FROM tab0 AS cor0
----
1968
24
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2787
SELECT CAST( col1 + col1 AS SIGNED ) * col1 FROM tab0
----
14792
16562
18818

skipif mysql # not compatible
query I rowsort label-2787
SELECT CAST ( col1 + col1 AS INTEGER ) * col1 FROM tab0
----
14792
16562
18818

query I rowsort
SELECT - col0 + + col0 - - col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL - 72 * + 1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT ALL - ( col1 * col2 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + ( 33 + - col1 ) * ( + 29 ) FROM tab0
----
-1537
-1682
-1856

query I rowsort
SELECT DISTINCT + + ( cor0.col1 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
10
13
26

query I rowsort
SELECT - col2 + col0 * + 73 FROM tab2 AS cor0
----
484
5668
5729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - 88 * + col0 FROM tab2 AS cor0
----
-616
-6864
-6952

query I rowsort
SELECT + + col1 + col1 * 4 FROM tab2 AS cor0
----
155
295
85

query I rowsort
SELECT DISTINCT col0 + + col0 * col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT col1 * + col1 + col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT - 24 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1558
-670
-861

query I rowsort
SELECT cor1.col1 * + cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 116454f2268e21c1351daf3f5803c987

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2801
SELECT - + col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2801
SELECT - + col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 * - col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT col1 * cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + cor0.col1 + col1 * col1 FROM tab1 cor0
----
110
182
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2805
SELECT CAST( NULL AS SIGNED ) - col0 / cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2805
SELECT CAST ( NULL AS INTEGER ) - col0 / cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2806
SELECT 21 DIV - ( col1 ) + col1 * col1 FROM tab1 AS cor0
----
168
676
98

skipif mysql # not compatible
query I rowsort label-2806
SELECT 21 / - ( col1 ) + col1 * col1 FROM tab1 AS cor0
----
168
676
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2807
SELECT - CAST( NULL AS SIGNED ) - - 30 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2807
SELECT - CAST ( NULL AS INTEGER ) - - 30 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 + - ( - cor0.col1 ) * 1 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT 4 * cor0.col2 FROM tab2, tab1 cor0
----
9 values hashing to f4078de312e4f2ca27f2fa4a703df416

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab2 cor1, tab0, tab0 AS cor2
----
3645 values hashing to b223aa53e3aafe0f3f3f59048cc7a0d2

query I rowsort
SELECT - 13 - 95 FROM tab1 AS cor0
----
-108
-108
-108

query I rowsort
SELECT - col2 + + 56 + 62 AS col2 FROM tab0 AS cor0
----
117
36
85

query I rowsort
SELECT ALL + cor0.col1 * - 98 + col0 FROM tab1 AS cor0
----
-1194
-2545
-916

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 * 2 AS col1 FROM tab2 AS cor0
----
-1292
-1674
-3068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 0 col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - col2 * 48 AS col1 FROM tab1 AS cor0
----
-2592
-2736
-4608

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 + CAST ( + col1 AS REAL ) / - col1 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT ALL - col0 + col0 * + 92 AS col2 FROM tab1 AS cor0
----
273
5824
7280

query I rowsort
SELECT + + col2 + - 22 AS col1 FROM tab0 AS cor0
----
-21
11
60

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col1 + col0 + - col1 AS col1 FROM tab1 AS cor0
----
154
236
653

query I rowsort
SELECT ALL - + col2 - + ( - col1 ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + col0 * cor0.col2 * + ( col2 ) + + col0 * col2 FROM tab0 AS cor0
----
26928
605734
70

query I rowsort
SELECT ALL col0 + col1 * col0 * col2 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT - col1 * 30 FROM tab1 AS cor0
----
-300
-390
-780

query I rowsort
SELECT - col0 + 9 * - col0 AS col0 FROM tab1 AS cor0
----
-30
-640
-800

query I rowsort
SELECT + - cor0.col2 + ( - col2 ) * col2 + col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col1 - + col1 * col2 AS col0 FROM tab1
----
-1235
-1378
-560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2828
SELECT ALL + col0 * CAST( - col2 AS SIGNED ) col0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2828
SELECT ALL + col0 * CAST ( - col2 AS INTEGER ) col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + - cor0.col0 + + 69 FROM tab0 AS cor0
----
-20
34
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + 60 col0 FROM tab0
----
-22
27
59

query I rowsort
SELECT ALL - 66 * - 8 FROM tab0 AS cor0
----
528
528
528

onlyif mysql # use DIV operator for integer division
query I rowsort label-2832
SELECT + col0 DIV + col1 + - col0 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-2832
SELECT + col0 / + col1 + - col0 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT cor0.col2 + col0 * - 29 FROM tab1 AS cor0
----
-1799
-2224
-33

query I rowsort
SELECT 17 * col2 - col1 FROM tab0
----
-80
1303
475

query I rowsort
SELECT ALL + 0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT - cor0.col2 + col0 + 63 FROM tab2 AS cor0
----
104
115
43

query I rowsort
SELECT DISTINCT col1 + col2 * col1 + - col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + + col0 * col0 * 86 + + col1 FROM tab0 AS cor0
----
105447
49622
681297

query I rowsort
SELECT ALL - 21 - col2 FROM tab1 cor0
----
-117
-75
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 ) + col0 col2 FROM tab0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 77 col2 FROM tab0 AS cor0
----
77
77
77

query I rowsort
SELECT ALL - - col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-2843
SELECT - 6 DIV col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2843
SELECT - 6 / col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 43 + - col0 col2 FROM tab2 AS cor0
----
-121
-122
-50

query I rowsort
SELECT DISTINCT - 87 AS col2 FROM tab1 AS cor0
----
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-2846
SELECT DISTINCT - + col2 DIV col1 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1534
644
837

skipif mysql # not compatible
query I rowsort label-2846
SELECT DISTINCT - + col2 / col1 + col2 * col1 AS col1 FROM tab2 AS cor0
----
1534
644
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + - col1 + CAST ( + col0 * col2 AS REAL ) col2 FROM tab1 cor0
----
136
3638
7667

query I rowsort
SELECT + 26 * 95 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to ba769a9ff69d847d9feffde98b837afb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 94 * col1 col1 FROM tab2 AS cor0
----
144196
60724
78678

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2850
SELECT ALL col1 * - CAST( NULL AS SIGNED ) + + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2850
SELECT ALL col1 * - CAST ( NULL AS INTEGER ) + + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * - ( cor0.col1 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col1 * col0 - + col2 * + col1 FROM tab2 AS cor0
----
-1054
-1989
-6136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 47 * - 17 col0 FROM tab0 AS cor0
----
-799

query I rowsort
SELECT - tab1.col2 + + col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * + 22 FROM tab1 AS cor0
----
-1408
-1760
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2856
SELECT col2 DIV + cor0.col1 AS col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2856
SELECT col2 / + cor0.col1 AS col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT ALL - - 46 * col2 * col1 AS col1 FROM tab1 AS cor0
----
26220
57408
64584

query I rowsort
SELECT DISTINCT + - 57 + 61 * col2 FROM tab0 AS cor0
----
1956
4
4945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2859
SELECT ALL CAST( 76 AS SIGNED ) + - cor0.col1 * 14 FROM tab0 AS cor0
----
-1128
-1198
-1282

skipif mysql # not compatible
query I rowsort label-2859
SELECT ALL CAST ( 76 AS INTEGER ) + - cor0.col1 * 14 FROM tab0 AS cor0
----
-1128
-1198
-1282

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2860
SELECT - CAST( NULL AS SIGNED ) * - 21 + col2 + - ( col0 * + cor0.col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2860
SELECT - CAST ( NULL AS INTEGER ) * - 21 + col2 + - ( col0 * + cor0.col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col1 + - cor0.col1 * 7 * col2 AS col0 FROM tab2 AS cor0
----
-10679
-4505
-5828

query I rowsort
SELECT - - ( col1 ) * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + + col1 * col1 + ( col0 ) AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT - col1 * col2 - + col2 * + 75 AS col0 FROM tab2 cor0
----
-2862
-3484
-3496

query I rowsort
SELECT ALL - - 93 * col1 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT col0 + col0 * tab1.col2 AS col1 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL 88 FROM tab1, tab2 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT tab1.col1 + 89 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a5fbc60290203ed4a48d8011c9e8d362

query I rowsort
SELECT DISTINCT - 46 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-46

query I rowsort
SELECT ALL col2 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2871
SELECT CAST( NULL AS SIGNED ) / + 87 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2871
SELECT CAST ( NULL AS INTEGER ) / + 87 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col2 col0 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - - col0 * 39 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT DISTINCT + col1 * ( col0 ) + + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - col0 + 50 + + col2 FROM tab0 AS cor0
----
16
43
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2876
SELECT - col1 DIV + cor0.col1 + + cor0.col0 + col0 * col1 FROM tab1 cor0
----
1119
703
80

skipif mysql # not compatible
query I rowsort label-2876
SELECT - col1 / + cor0.col1 + + cor0.col0 + col0 * col1 FROM tab1 cor0
----
1119
703
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col0 ) col1 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2878
SELECT - - col2 DIV + cor0.col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2878
SELECT - - col2 / + cor0.col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + col0 + - ( + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2880
SELECT + + CAST( col0 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-2880
SELECT + + CAST ( col0 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + 12 + - ( - col1 ) AS col2 FROM tab1 cor0
----
22
25
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 18 ) * col1 + col1 col0 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT DISTINCT + col2 + - col1 AS col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT - col2 + + 75 * col0 AS col0 FROM tab2
----
498
5824
5887

query I rowsort
SELECT ALL - col1 * + 61 * - col1 FROM tab1
----
10309
41236
6100

query I rowsort
SELECT ALL 73 + col1 FROM tab0 AS cor0
----
159
164
170

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 * col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + 25 * - col2 AS col0 FROM tab1 AS cor0
----
-1350
-1425
-2400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 col2 FROM tab0 AS cor0
----
34
34
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 77 col2 FROM tab0 AS cor0
----
77
77
77

query I rowsort
SELECT DISTINCT + cor0.col2 * - col0 * col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL ( col2 ) + 70 * col0 FROM tab0 AS cor0
----
1713
2451
6312

onlyif mysql # use DIV operator for integer division
query I rowsort label-2893
SELECT col0 + - cor0.col1 DIV - col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-2893
SELECT col0 + - cor0.col1 / - col0 FROM tab2 AS cor0
----
11
78
79

query I rowsort
SELECT ALL - + col2 * col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + - 61 * + col1 + + 78 FROM tab2 AS cor0
----
-1813
-3521
-959

query I rowsort
SELECT 23 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2897
SELECT + + col1 DIV col1 + - 8 AS col2 FROM tab0 AS cor0
----
-7
-7
-7

skipif mysql # not compatible
query I rowsort label-2897
SELECT + + col1 / col1 + - 8 AS col2 FROM tab0 AS cor0
----
-7
-7
-7

query I rowsort
SELECT DISTINCT + - cor0.col0 * col2 + ( - col2 ) * - cor0.col2 + ( - col0 ) AS col2 FROM tab2 cor0
----
-1430
-1637
533

onlyif mysql # use DIV operator for integer division
query I rowsort label-2899
SELECT DISTINCT - 85 DIV - col1 + + col2 FROM tab1
----
102
57
65

skipif mysql # not compatible
query I rowsort label-2899
SELECT DISTINCT - 85 / - col1 + + col2 FROM tab1
----
102
57
65

query I rowsort
SELECT col1 - + col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 + - 27 AS col1 FROM tab2 AS cor0
----
-105
-106
-34

query I rowsort
SELECT + col1 * + ( - cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL col2 + + ( - col1 ) * - cor0.col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT cor0.col0 - + col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - col2 * cor0.col2 + 65 FROM tab0 AS cor0
----
-1024
-6659
64

query I rowsort
SELECT ( - 18 ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT DISTINCT + tab2.col2 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2908
SELECT + col1 + - col2 DIV 87 FROM tab1 cor0
----
10
12
26

skipif mysql # not compatible
query I rowsort label-2908
SELECT + col1 + - col2 / 87 FROM tab1 cor0
----
10
12
26

query I rowsort
SELECT col1 * + col2 * - col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT + col1 * + 33 FROM tab0 AS cor0
----
2838
3003
3201

query I rowsort
SELECT + 75 * cor0.col2 AS col0 FROM tab1 AS cor0
----
4050
4275
7200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - cor0.col1 + - col2 col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + - col1 * + 4 FROM tab1 AS cor0
----
-104
-40
-52

query I rowsort
SELECT DISTINCT 21 + col2 AS col0 FROM tab1 AS cor0
----
117
75
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 + col1 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 77 + - col1 * + col0 AS col0 FROM tab0 AS cor0
----
-1987
-3318
-8022

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( - col0 ) * ( col0 ) col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT 75 * + col0 AS col2 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT + - col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - - 35 + - col0 * - col1 * col2 FROM tab2 cor0
----
119687
51069
5894

query I rowsort
SELECT ALL - col1 + 47 FROM tab2 cor0
----
-12
16
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-2922
SELECT DISTINCT + ( col1 ) DIV col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2922
SELECT DISTINCT + ( col1 ) / col0 AS col1 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - ( col1 ) * - col0 + + col0 AS col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT - - 47 AS col1 FROM tab1 AS cor0
----
47

query I rowsort
SELECT ALL + + col2 * + 30 + - col1 FROM tab2 cor0
----
1123
721
779

query I rowsort
SELECT ALL ( 53 ) * + col2 FROM tab1 AS cor0
----
2862
3021
5088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - col2 * col1 col0 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + + col0 - + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 + cor0.col2 * - ( 39 ) AS col2 FROM tab1 AS cor0
----
-2109
-2287
-3824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 * + col2 - + col0 col0 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT ALL - col1 + 27 * cor0.col0 + cor0.col0 AS col2 FROM tab0 AS cor0
----
2401
586
883

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * - 82 col0 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT DISTINCT + col1 * + ( + cor0.col0 ) FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2934
SELECT cor0.col0 DIV 7 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d08ae3d93d1bbc0baccaed9a6f9195a2

skipif mysql # not compatible
query I rowsort label-2934
SELECT cor0.col0 / 7 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d08ae3d93d1bbc0baccaed9a6f9195a2

query I rowsort
SELECT 48 AS col1 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT DISTINCT + tab2.col0 - - 66 FROM tab2, tab0 AS cor0
----
144
145
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-2937
SELECT DISTINCT col0 * tab0.col0 DIV + 47 FROM tab0
----
12
168
26

skipif mysql # not compatible
query I rowsort label-2937
SELECT DISTINCT col0 * tab0.col0 / + 47 FROM tab0
----
12
168
26

query I rowsort
SELECT 60 FROM tab0, tab1 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT DISTINCT col2 * 68 * 58 FROM tab2
----
102544
106488
149872

query I rowsort
SELECT col2 + - 82 AS col2 FROM tab0
----
-49
-81
0

query I rowsort
SELECT ALL tab0.col0 + + 30 FROM tab0
----
119
54
65

query I rowsort
SELECT + ( + col2 ) + cor0.col0 AS col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - 88 + ( + col0 ) FROM tab0 AS cor0
----
-53
-64
1

query I rowsort
SELECT ALL ( - col2 ) * col0 AS col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT ( 56 + + col1 ) AS col1 FROM tab1
----
66
69
82

query I rowsort
SELECT ALL - 77 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2947
SELECT - CAST( 75 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-75
-75
-75

skipif mysql # not compatible
query I rowsort label-2947
SELECT - CAST ( 75 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-75
-75
-75

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab2 cor1, tab0 cor2
----
972 values hashing to 380241bbc503a31e70494611a87ffd99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2949
SELECT ALL + - col0 + col0 DIV col1 AS col0 FROM tab2 AS cor0
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-2949
SELECT ALL + - col0 + col0 / col1 AS col0 FROM tab2 AS cor0
----
-7
-75
-77

query I rowsort
SELECT DISTINCT + - 58 + - 73 FROM tab0 AS cor0
----
-131

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1, tab2 cor0, tab1 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT + - col1 + + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-6143
-6258
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2953
SELECT ALL + + col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2953
SELECT ALL + + col0 / + col0 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - tab1.col0 * col1 + + 0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - 55 + col1 FROM tab2
----
-24
-38
4

query I rowsort
SELECT ALL - tab0.col1 * + 99 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 29f4b52236e6cacaf6a6faa5ea4f8343

onlyif mysql # use DIV operator for integer division
query I rowsort label-2957
SELECT DISTINCT col0 * col0 DIV 28 + + col0 FROM tab0
----
371
44
78

skipif mysql # not compatible
query I rowsort label-2957
SELECT DISTINCT col0 * col0 / 28 + + col0 FROM tab0
----
371
44
78

query I rowsort
SELECT col0 * - col1 + col0 + + col1 AS col0 FROM tab2
----
-1247
-179
-4465

query I rowsort
SELECT col2 * + col0 + - tab1.col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT - col2 * col0 + 95 * - 67 FROM tab2
----
-6554
-8393
-9367

query I rowsort
SELECT DISTINCT - - 33 * - col1 AS col1 FROM tab1 AS cor0
----
-330
-429
-858

query I rowsort
SELECT ALL + ( - cor0.col0 ) * col0 + + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT + + col0 * cor0.col0 - + col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT 30 * col0 + 83 FROM tab0
----
1133
2753
803

query I rowsort
SELECT DISTINCT + col0 * - col2 + + 15 AS col0 FROM tab1
----
-147
-3633
-7665

query I rowsort
SELECT ALL - tab1.col0 + + col1 + + col1 FROM tab1
----
-44
-54
49

query I rowsort
SELECT + col2 * col0 + - col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL - + col0 * - 99 - + col1 * + col0 FROM tab0 AS cor0
----
312
70
712

query I rowsort
SELECT DISTINCT - col2 - ( col1 ) FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2970
SELECT DISTINCT + col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2970
SELECT DISTINCT + col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2971
SELECT DISTINCT col1 DIV 95 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2971
SELECT DISTINCT col1 / 95 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + col0 * col2 + - col1 - cor0.col1 * - ( col2 ) AS col0 FROM tab0 AS cor0
----
14669
35
3544

query I rowsort
SELECT col0 + 47 AS col1 FROM tab2 cor0
----
125
126
54

query I rowsort
SELECT - col2 + - col0 + col2 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2975
SELECT DISTINCT + cor0.col1 DIV + col1 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2975
SELECT DISTINCT + cor0.col1 / + col1 FROM tab2 cor0
----
1

query I rowsort
SELECT - 74 * + cor0.col2 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 0df32fd13ea208cfde2055729493ece9

query I rowsort
SELECT DISTINCT + 36 + + col0 * col1 * col0 AS col0 FROM tab1
----
270
40996
83236

onlyif mysql # use DIV operator for integer division
query I rowsort label-2978
SELECT ALL col1 DIV 48 col2 FROM tab0 AS cor0
----
1
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2978
SELECT ALL col1 / 48 col2 FROM tab0 AS cor0
----
1
1
2

query I rowsort
SELECT + col2 * - col0 + 37 + - col1 AS col1 FROM tab1 cor0
----
-151
-3621
-7656

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2980
SELECT DISTINCT col0 * - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2980
SELECT DISTINCT col0 * - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col1 * ( col1 ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + + col1 * col0 + - ( col2 ) FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL 39 + 14 FROM tab1
----
53
53
53

query I rowsort
SELECT + cor0.col0 * - col2 + ( col2 ) AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL tab1.col0 + - ( tab1.col2 * + 2 ) + 77 AS col1 FROM tab1
----
-28
-35
27

query I rowsort
SELECT - col1 + + 76 AS col2 FROM tab1 AS cor0
----
50
63
66

query I rowsort
SELECT DISTINCT + - 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-2988
SELECT + col2 * - col2 + CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
-1065
-6635
34

skipif mysql # not compatible
query I rowsort label-2988
SELECT + col2 * - col2 + CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT - 85 + + 1 AS col0 FROM tab2, tab1 cor0, tab1 cor1
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 - col0 col2 FROM tab1 AS cor0
----
-153
-169
-92

query I rowsort
SELECT col1 - - col1 * + 3 * + 77 AS col0 FROM tab0 AS cor0
----
19952
21112
22504

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2992
SELECT + + col1 - col1 * CAST( + col2 AS SIGNED ) * - col1 AS col2 FROM tab1 AS cor0
----
16237
36530
5710

skipif mysql # not compatible
query I rowsort label-2992
SELECT + + col1 - col1 * CAST ( + col2 AS INTEGER ) * - col1 AS col2 FROM tab1 AS cor0
----
16237
36530
5710

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 83 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT ALL 45 + 80 FROM tab0, tab0 cor0
----
9 values hashing to 2973878398e469d83385e7e06bd5af99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - ( - cor0.col0 ) ) + 1 * + ( cor0.col0 ) col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 10977325261681ddca962e0a5d2b348b

query I rowsort
SELECT DISTINCT - cor0.col1 * 88 FROM tab2 AS cor0
----
-1496
-2728
-5192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2997
SELECT DISTINCT + + col1 + - col0 DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-2997
SELECT DISTINCT + + col1 + - col0 / + cor0.col1 AS col1 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT ALL - 12 FROM tab1 cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - ( - col2 ) * col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - ( 15 ) * + col2 FROM tab2 AS cor0
----
-390
-405
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 72 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

query I rowsort
SELECT + - 7 AS col1 FROM tab2 AS cor0
----
-7
-7
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3003
SELECT CAST( NULL AS SIGNED ) * ( col1 ) - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3003
SELECT CAST ( NULL AS INTEGER ) * ( col1 ) - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 44 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT ALL - col0 + - 3 AS col1 FROM tab1 cor0
----
-6
-67
-83

query I rowsort
SELECT DISTINCT + 59 + + cor0.col0 * col2 AS col0 FROM tab0 AS cor0
----
7357
851
94

query I rowsort
SELECT + col1 + col2 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + ( + col1 ) + - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3009
SELECT + CAST( NULL AS SIGNED ) * cor0.col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3009
SELECT + CAST ( NULL AS INTEGER ) * cor0.col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + col0 + col2 - - cor0.col1 * col1 FROM tab2 AS cor0
----
1205
1670
8109

query I rowsort
SELECT DISTINCT + col1 + - col1 + cor0.col1 * col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col1 + + col0 * cor0.col1 * + col1 FROM tab2 AS cor0
----
22848
271577
6758

query I rowsort
SELECT + - col2 * + col0 * - col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT DISTINCT 12 * + col0 FROM tab0 cor0
----
1068
288
420

query I rowsort
SELECT + - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + + col2 * + cor0.col1 + col1 * col2 + col1 AS col1 FROM tab2 AS cor0
----
1309
1705
3127

query I rowsort
SELECT - ( col2 + col0 ) FROM tab2
----
-104
-117
-34

query I rowsort
SELECT DISTINCT tab1.col1 * - col0 * col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT col0 * ( - ( col1 ) ) * - col0 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT - col0 * col0 + - col2 FROM tab2 AS cor0
----
-6110
-6279
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3021
SELECT col1 DIV col0 + col2 AS col2 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-3021
SELECT col1 / col0 + col2 AS col2 FROM tab2 AS cor0
----
26
31
38

query I rowsort
SELECT DISTINCT + - 60 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-60

query I rowsort
SELECT - col0 * - cor0.col0 + col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT - - col0 + - ( - ( + col2 ) ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col2 + + col2 * - 66 FROM tab1 AS cor0
----
-3510
-3705
-6240

query I rowsort
SELECT - 68 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6fbba7db5bccb533a35aa5125a231f88

query I rowsort
SELECT ALL - - col0 + - ( col0 ) * + col2 FROM tab1 cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-3028
SELECT DISTINCT - cor0.col2 DIV + ( + col0 + col2 ) AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3028
SELECT DISTINCT - cor0.col2 / + ( + col0 + col2 ) AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col2 * + col1 * 92 FROM tab1 cor0
----
-114816
-129168
-52440

onlyif mysql # use DIV operator for integer division
query I rowsort label-3030
SELECT DISTINCT cor0.col2 DIV + col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3030
SELECT DISTINCT cor0.col2 / + col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT - cor0.col0 * + ( ( col2 ) ) + - col1 AS col2 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + cor0.col2 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - + cor0.col0 * col2 * + col1 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - col0 * 32 + cor0.col2 FROM tab0 AS cor0
----
-1119
-2766
-735

query I rowsort
SELECT DISTINCT + + cor0.col1 + - 44 FROM tab0 AS cor0
----
42
47
53

query I rowsort
SELECT - cor0.col2 + 61 * + col1 AS col2 FROM tab0 cor0
----
5213
5469
5916

query IIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0 cor1
----
243 values hashing to 2ba47a833971d4c4b0287e849fb0cfb8

query I rowsort
SELECT ALL ( - col0 ) * col1 + - col1 * - 61 + - tab0.col0 AS col1 FROM tab0
----
-2637
2487
3158

query I rowsort
SELECT - cor0.col2 * + ( - col0 + col2 ) AS col0 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT ALL + 63 AS col1 FROM tab2 AS cor0
----
63
63
63

query I rowsort
SELECT - - col0 + ( col1 ) + col0 * col2 AS col0 FROM tab1 AS cor0
----
191
3722
7773

query I rowsort
SELECT ALL - - ( col0 ) * - col1 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3043
SELECT DISTINCT - col0 + - col1 DIV col1 AS col2 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-3043
SELECT DISTINCT - col0 + - col1 / col1 AS col2 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT ALL ( + 34 ) FROM tab1 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3045
SELECT - col0 DIV col0 + - col1 + col1 * + col2 * col0 FROM tab2 cor0
----
119592
51016
5827

skipif mysql # not compatible
query I rowsort label-3045
SELECT - col0 / col0 + - col1 + col1 * + col2 * col0 FROM tab2 cor0
----
119592
51016
5827

query I rowsort
SELECT ALL - + 37 + 17 FROM tab1 cor0
----
-20
-20
-20

query I rowsort
SELECT DISTINCT - 52 * + col1 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT - cor0.col0 + - col0 + cor0.col0 AS col0 FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3049
SELECT 57 - + col2 DIV + col0 FROM tab2 AS cor0
----
54
57
57

skipif mysql # not compatible
query I rowsort label-3049
SELECT 57 - + col2 / + col0 FROM tab2 AS cor0
----
54
57
57

query I rowsort
SELECT DISTINCT - ( col0 ) * - cor0.col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + ( + col0 ) + col1 * + col2 + - col2 AS col2 FROM tab2 cor0
----
1586
687
817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3052
SELECT DISTINCT + 45 + + col0 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3052
SELECT DISTINCT + 45 + + col0 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col0 * + cor0.col1 col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL - col0 * - cor0.col2 + ( col2 ) * - cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 * + col0 * col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + + col1 * cor0.col2 + - 58 FROM tab2 AS cor0
----
1476
588
779

query I rowsort
SELECT ALL - - ( + col0 ) * col1 * + ( col0 ) FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + + 86 FROM tab1 AS cor0
----
86

query I rowsort
SELECT + + 67 * col0 FROM tab0 cor0
----
1608
2345
5963

query I rowsort
SELECT ALL - - col2 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 48 * - col1 FROM tab2
----
1488
2832
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-3062
SELECT ALL - + 91 DIV col0 + ( col2 ) * col2 AS col1 FROM tab2 AS cor0
----
1443
675
716

skipif mysql # not compatible
query I rowsort label-3062
SELECT ALL - + 91 / col0 + ( col2 ) * col2 AS col1 FROM tab2 AS cor0
----
1443
675
716

query I rowsort
SELECT ALL - cor0.col1 * + col2 + col2 + col0 * cor0.col1 FROM tab1 AS cor0
----
-112
-1272
127

query I rowsort
SELECT DISTINCT ( - cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3065
SELECT ALL - 3 * + col2 * CAST( col1 AS SIGNED ) AS col0 FROM tab0 cor0
----
-22386
-291
-8514

skipif mysql # not compatible
query I rowsort label-3065
SELECT ALL - 3 * + col2 * CAST ( col1 AS INTEGER ) AS col0 FROM tab0 cor0
----
-22386
-291
-8514

query I rowsort
SELECT ( + col2 ) + - col1 + ( + col1 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - 84 - col2 AS col1 FROM tab0 AS cor0
----
-117
-166
-85

query I rowsort
SELECT + 3 * - cor0.col2 + + col1 AS col1 FROM tab2 AS cor0
----
-19
-50
-97

query I rowsort
SELECT + col1 + + 30 AS col2 FROM tab1
----
40
43
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3070
SELECT DISTINCT - - cor0.col0 * - col1 * + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3070
SELECT DISTINCT - - cor0.col0 * - col1 * + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-3072
SELECT - + col2 + + CAST( col0 AS SIGNED ) DIV + col0 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-3072
SELECT - + col2 + + CAST ( col0 AS INTEGER ) / + col0 FROM tab2 AS cor0
----
-25
-26
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-3073
SELECT col0 DIV CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-3073
SELECT col0 / CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT - 6 FROM tab2
----
-6
-6
-6

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 AS cor1, tab1, tab1 cor2
----
3645 values hashing to 08000767d0a951e4a7a7f8edda07fb64

query I rowsort
SELECT ALL + col1 * + col1 + + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + col0 - 77 FROM tab1 AS cor0
----
-13
-74
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col0 * + col1 col1 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT ( - 89 + tab2.col0 ) AS col0 FROM tab2
----
-10
-11
-82

query I rowsort
SELECT ( + 40 ) + col2 FROM tab1
----
136
94
97

query I rowsort
SELECT ALL + col0 + - ( tab1.col2 ) AS col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - - 67 + col2 AS col2 FROM tab2 cor0
----
105
93
94

query I rowsort
SELECT DISTINCT - col1 * col1 + col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT + cor0.col1 + - 18 FROM tab1 AS cor0
----
-5
-8
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 - col1 col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT DISTINCT cor0.col2 * + cor0.col1 * col1 + col0 * 93 AS col2 FROM tab1 AS cor0
----
11652
23664
36783

query I rowsort
SELECT ALL + + col1 + + ( + col0 ) AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + 98 + col0 + - col1 FROM tab1
----
152
165
75

query I rowsort
SELECT ALL + - ( col2 ) * + col2 + 88 * - col2 FROM tab0 AS cor0
----
-13940
-3993
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3090
SELECT - + CAST( NULL AS SIGNED ) * cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3090
SELECT - + CAST ( NULL AS INTEGER ) * cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( - 35 ) * col2 FROM tab2
----
-1330
-910
-945

query I rowsort
SELECT DISTINCT ( col0 ) + + col0 * 17 * - ( - col2 ) AS col1 FROM tab2
----
3220
34554
51113

query I rowsort
SELECT ALL - 61 * col2 * + cor0.col0 FROM tab0 AS cor0
----
-2135
-445178
-48312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 col2 FROM tab1
----
50
50
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3095
SELECT ALL - CAST( NULL AS SIGNED ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3095
SELECT ALL - CAST ( NULL AS INTEGER ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( col0 * ( tab2.col1 ) ) FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3097
SELECT + col1 * CAST( NULL AS SIGNED ) + col0 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3097
SELECT + col1 * CAST ( NULL AS INTEGER ) + col0 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 77 AS col1 FROM tab0
----
-77
-77
-77

query I rowsort
SELECT + col1 * col2 + + col1 * col1 * + col0 FROM tab0
----
180342
329412
744471

query I rowsort
SELECT + 5 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT DISTINCT - + col2 + - col2 * col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3102
SELECT ALL + ( col1 ) DIV col1 AS col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3102
SELECT ALL + ( col1 ) / col1 AS col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL + ( col0 ) * col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - cor0.col1 * - 68 FROM tab1, tab0 cor0
----
9 values hashing to 62f4b061af2572801934deb01f0cbe37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 7 col2 FROM tab0
----
7

query I rowsort
SELECT ALL col2 * + col0 + 11 * - col2 FROM tab0 AS cor0
----
24
429
6396

query I rowsort
SELECT ALL col0 + + 76 FROM tab0 AS cor0
----
100
111
165

query I rowsort
SELECT DISTINCT - - col2 * ( - col0 ) + + col2 - 77 FROM tab1 AS cor0
----
-185
-3668
-7661

query I rowsort
SELECT col0 * + 34 + - 90 FROM tab0 AS cor0
----
1100
2936
726

query I rowsort
SELECT ALL - col1 * - col1 + col1 + col2 * col0 FROM tab2 cor0
----
1181
3308
5568

query I rowsort
SELECT ALL - tab0.col1 * + col1 * - 35 AS col2 FROM tab0
----
258860
289835
329315

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + ( 74 + cor0.col2 ) * ( + col2 ) * cor0.col1 col2 FROM tab0 AS cor0
----
1163981
303580
7178

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 97 col0 FROM tab2 AS cor0
----
1649
3007
5723

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3114
SELECT - col1 + + CAST( NULL AS SIGNED ) * tab1.col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3114
SELECT - col1 + + CAST ( NULL AS INTEGER ) * tab1.col1 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 + 60 * + 31 * col1 + col1 FROM tab1 AS cor0
----
18674
24273
48389

query I rowsort
SELECT DISTINCT col0 * col1 * - tab1.col2 + col1 AS col0 FROM tab1
----
-36470
-4186
-99827

query I rowsort
SELECT col0 * col0 + - col2 AS col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT - ( - 35 ) * - col0 AS col1 FROM tab1 AS cor0
----
-105
-2240
-2800

query I rowsort
SELECT - - 25 * col2 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT + ( 2 ) * col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT - col2 + + col2 * cor0.col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT + col1 + 2 AS col0 FROM tab1 AS cor0
----
12
15
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3123
SELECT ALL + - CAST( col2 AS SIGNED ) * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-3123
SELECT ALL + - CAST ( col2 AS INTEGER ) * col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3124
SELECT - col2 * ( - col0 ) * CAST( cor0.col0 * col0 AS SIGNED ) FROM tab2 AS cor0
----
12338352
18735482
9261

skipif mysql # not compatible
query I rowsort label-3124
SELECT - col2 * ( - col0 ) * CAST ( cor0.col0 * col0 AS INTEGER ) FROM tab2 AS cor0
----
12338352
18735482
9261

query I rowsort
SELECT - + col0 * - col1 AS col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - ( - col2 ) * - ( ( col1 ) + + col1 ) FROM tab2 AS cor0
----
-1292
-1674
-3068

query I rowsort
SELECT - + cor0.col1 * col1 * 90 FROM tab1 cor0
----
-15210
-60840
-9000

query I rowsort
SELECT + + col0 - - col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3129
SELECT DISTINCT tab0.col0 * + tab0.col1 * col1 + - CAST( col1 * col2 AS SIGNED ) FROM tab0
----
174666
329218
729547

skipif mysql # not compatible
query I rowsort label-3129
SELECT DISTINCT tab0.col0 * + tab0.col1 * col1 + - CAST ( col1 * col2 AS INTEGER ) FROM tab0
----
174666
329218
729547

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1, tab1 AS cor0 WHERE NOT ( NULL ) NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3131
SELECT + col2 + - col0 DIV + col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3131
SELECT + col2 + - col0 / + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col1 * col1 - col1 AS col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT cor0.col2 * + col2 + col1 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT - col2 + + cor0.col0 * - col0 * col1 FROM tab1 AS cor0
----
-288
-41017
-83296

query I rowsort
SELECT ALL tab2.col2 * cor0.col0 + + tab2.col1 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to c4b98e7a09ae0ffa0e4de9ae3a92c011

query I rowsort
SELECT + ( cor0.col2 ) + cor0.col0 AS col0 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 0a9ba7ddbb78279db2d78308414e03c9

query I rowsort
SELECT + ( + tab1.col0 ) * col1 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * tab2.col0 * ( - 71 * col0 ) col1 FROM tab2
----
-24353
-33693192
-35005769

query I rowsort
SELECT ALL col0 + + col0 * col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + - col0 + - col1 + col2 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT DISTINCT col1 * - col0 * + col1 - col0 AS col0 FROM tab1 AS cor0
----
-13600
-2031
-6464

query I rowsort
SELECT - + col1 + col1 * - col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 * col0 AS col2 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT col0 * col0 * col1 + - col0 FROM tab1
----
231
40896
83120

query I rowsort
SELECT + col1 + + col2 + - col0 AS col2 FROM tab1
----
29
3
77

query I rowsort
SELECT DISTINCT col0 + col2 * + col1 * col2 AS col2 FROM tab2
----
22606
24627
39962

query I rowsort
SELECT DISTINCT col0 * - col0 + tab2.col2 FROM tab2
----
-22
-6058
-6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * + col2 + col1 col2 FROM tab2
----
1619
701
895

query I rowsort
SELECT DISTINCT tab2.col0 * col2 * - col2 + col2 AS col1 FROM tab2
----
-114038
-5076
-52702

query I rowsort
SELECT col2 + col2 - col1 FROM tab0
----
-20
-95
73

query I rowsort
SELECT DISTINCT tab1.col1 * + col2 + + col1 * tab1.col0 * col0 FROM tab1
----
1638
41530
84448

onlyif mysql # use DIV operator for integer division
query I rowsort label-3152
SELECT - col0 DIV col1 + col1 col1 FROM tab1
----
26
4
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3152
SELECT - col0 / col1 + col1 col1 FROM tab1
----
26
4
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3153
SELECT col0 DIV - col2 - col1 * tab0.col1 * - col0 FROM tab0
----
177504
329280
737008

skipif mysql # not compatible
query I rowsort label-3153
SELECT col0 / - col2 - col1 * tab0.col1 * - col0 FROM tab0
----
177504
329280
737008

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2 cor0 CROSS JOIN tab1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3155
SELECT + col1 DIV col0 + - tab0.col1 FROM tab0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-3155
SELECT + col1 / col0 + - tab0.col1 FROM tab0
----
-83
-90
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3156
SELECT ALL col0 * col2 * cor0.col0 + + col0 + col1 DIV + col2 AS col2 FROM tab1 cor0
----
233536
489
614480

skipif mysql # not compatible
query I rowsort label-3156
SELECT ALL col0 * col2 * cor0.col0 + + col0 + col1 / + col2 AS col2 FROM tab1 cor0
----
233536
489
614480

query I rowsort
SELECT - col0 * + col2 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL + + col1 + + col2 * + cor0.col1 * col0 FROM tab0 AS cor0
----
3492
664209
68198

query I rowsort
SELECT DISTINCT - - col2 * col1 + - col2 AS col1 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT + + col2 * col2 + col0 * cor0.col1 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT - col2 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - - col1 * col0 * - col1 - + col0 * + col1 FROM tab2 AS cor0
----
-24174
-276120
-6944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 + cor0.col2 col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + tab1.col2 * col0 + col2 AS col1 FROM tab1
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col2 col1 FROM tab0 WHERE ( col1 * + col0 + col1 * + col0 * col1 ) NOT IN ( - col2 )
----
119
173
98

query I rowsort
SELECT - col1 * col1 * + col2 AS col0 FROM tab1
----
-16224
-36504
-5700

query III rowsort
SELECT * FROM tab0 WHERE ( - col2 ) <= NULL
----

query I rowsort
SELECT - col2 * tab0.col1 + - col0 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT ALL - col1 + col2 * - col2 FROM tab1
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-3170
SELECT col1 DIV - col1 + col0 AS col0 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-3170
SELECT col1 / - col1 + col0 AS col0 FROM tab0
----
23
34
88

query I rowsort
SELECT DISTINCT tab0.col1 * - col0 FROM tab0 WHERE NOT NULL BETWEEN col2 AND NULL
----

query I rowsort
SELECT ALL - col1 * col1 + col1 AS col0 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT col1 AS col1 FROM tab0 WHERE NOT ( NULL ) < col1 + + col2 - col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3174
SELECT ALL col1 + col0 DIV + tab1.col1 FROM tab1
----
16
19
26

skipif mysql # not compatible
query I rowsort label-3174
SELECT ALL col1 + col0 / + tab1.col1 FROM tab1
----
16
19
26

query I rowsort
SELECT DISTINCT col0 + - tab2.col2 AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL + + col0 * cor0.col1 - col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT col1 + + col2 * - 81 FROM tab1 AS cor0
----
-4348
-4607
-7763

query I rowsort
SELECT ALL col0 + col2 + + tab0.col1 FROM tab0
----
133
143
262

query I rowsort
SELECT tab1.col2 - + col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL tab0.col0 + - tab0.col2 + tab0.col2 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT + col2 * - col1 + + col0 * + col2 + + col0 * tab1.col2 AS col0 FROM tab1
----
-1080
14112
6726

query I rowsort
SELECT col2 + + col1 - col2 * col2 AS col1 FROM tab1
----
-2836
-3182
-9107

query I rowsort
SELECT ALL + col0 * - col0 * - tab0.col2 AS col1 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT ALL - tab2.col0 AS col0 FROM tab2 WHERE NULL NOT IN ( col2 * col1 + - col1 )
----

query I rowsort
SELECT DISTINCT - col2 * tab2.col0 + col0 + col2 AS col2 FROM tab2 WHERE + col2 * + col0 + + col1 NOT IN ( + col2 - + col2 )
----
-155
-1924
-2885

query I rowsort
SELECT col0 + - col1 + + col0 * col0 AS col2 FROM tab1
----
-14
4150
6467

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + col0 col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - col1 * col0 AS col0 FROM tab2 AS cor0 WHERE NOT col0 * col2 > + col0
----

query I rowsort
SELECT DISTINCT col0 + col1 + col0 AS col0 FROM tab1 AS cor0
----
138
173
32

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT NULL = - col0
----

query I rowsort
SELECT ALL + col1 FROM tab1 WHERE - col0 * col1 < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col2 col1 FROM tab0 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT - tab2.col0 * - tab2.col1 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT col0 AS col0 FROM tab2 WHERE NULL NOT BETWEEN col2 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * col1 col1 FROM tab2
----
327
3507
988

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND + col0
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT IN ( - col1 )
----

query I rowsort
SELECT - col2 AS col1 FROM tab2 WHERE + col0 * col0 NOT IN ( + col1 )
----
-26
-27
-38

query I rowsort
SELECT ALL + tab1.col1 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + 25 + + col2 * col1 * col2 AS col2 FROM tab0 AS cor0
----
122
611909
93679

query I rowsort
SELECT + cor0.col0 + - col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + 6 + + col0 + col2 * ( col2 + 52 ) FROM tab0 AS cor0
----
11083
2835
94

query I rowsort
SELECT - col0 + col2 * - 4 AS col1 FROM tab2 AS cor0
----
-115
-182
-231

query I rowsort
SELECT + cor0.col0 * cor0.col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + - col1 + col1 * - 5 * + 91 AS col0 FROM tab2 AS cor0
----
-14136
-26904
-7752

onlyif mysql # use DIV operator for integer division
query I rowsort label-3206
SELECT - - col1 + - col0 + + cor0.col0 DIV + col2 col0 FROM tab0 AS cor0
----
3
62
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3206
SELECT - - col1 + - col0 + + cor0.col0 / + col2 col0 FROM tab0 AS cor0
----
3
62
97

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT col1 * - col0 * col2 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3209
SELECT ALL col0 * + col0 DIV cor0.col0 + col2 * ( - col1 ) FROM tab2 AS cor0
----
-1456
-567
-830

skipif mysql # not compatible
query I rowsort label-3209
SELECT ALL col0 * + col0 / cor0.col0 + col2 * ( - col1 ) FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + col2 + - col0 * 16 AS col1 FROM tab0 AS cor0
----
-1342
-351
-559

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 + col2 * - col1 col1 FROM tab0 AS cor0
----
-1749
-738
-96

query I rowsort
SELECT DISTINCT 21 * col0 FROM tab2
----
147
1638
1659

query I rowsort
SELECT DISTINCT + 92 AS col0 FROM tab2, tab2 cor0, tab1 AS cor1, tab1 cor2
----
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3214
SELECT + 60 * + 15 - col0 * CAST( NULL AS SIGNED ) * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3214
SELECT + 60 * + 15 - col0 * CAST ( NULL AS INTEGER ) * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 48 - cor0.col2 * col2 FROM tab2 AS cor0
----
-1492
-724
-777

query I rowsort
SELECT DISTINCT - tab0.col0 FROM tab0, tab1, tab2 cor0
----
-24
-35
-89

query I rowsort
SELECT col1 * + col0 + - col2 FROM tab0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-3218
SELECT ALL col2 * 98 DIV col0 AS col0 FROM tab2
----
32
378
47

skipif mysql # not compatible
query I rowsort label-3218
SELECT ALL col2 * 98 / col0 AS col0 FROM tab2
----
32
378
47

query I rowsort
SELECT tab0.col2 * - tab0.col1 * + 91 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 64b3c16b21b16dc36a4a3b396e9c4f22

query I rowsort
SELECT ALL 87 * - 78 AS col0 FROM tab2
----
-6786
-6786
-6786

query I rowsort
SELECT DISTINCT - + 53 * col0 FROM tab1 AS cor0
----
-159
-3392
-4240

query I rowsort
SELECT col1 + 16 + + cor0.col1 * - col1 * col1 AS col0 FROM tab2 AS cor0
----
-205304
-29744
-4880

query I rowsort
SELECT - tab2.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col1 * col0 col0 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3225
SELECT ALL - cor0.col0 * - cor0.col1 + + col1 DIV col0 AS col2 FROM tab1 cor0
----
1040
640
86

skipif mysql # not compatible
query I rowsort label-3225
SELECT ALL - cor0.col0 * - cor0.col1 + + col1 / col0 AS col2 FROM tab1 cor0
----
1040
640
86

query I rowsort
SELECT DISTINCT - 13 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-12
20
69

query I rowsort
SELECT ALL 28 - - col1 AS col2 FROM tab1 AS cor0
----
38
41
54

query I rowsort
SELECT ALL 68 + col0 AS col0 FROM tab1 AS cor0
----
132
148
71

query I rowsort
SELECT - cor1.col1 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

query I rowsort
SELECT DISTINCT 84 + + col2 * - tab1.col0 AS col1 FROM tab1
----
-3564
-7596
-78

query I rowsort
SELECT + 62 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT DISTINCT - ( - col2 ) + + 67 AS col2 FROM tab2
----
105
93
94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3233
SELECT 77 + - col1 * + CAST( NULL AS DECIMAL ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3233
SELECT 77 + - col1 * + CAST ( NULL AS REAL ) col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * + col2 * col0 + - ( - col1 ) FROM tab0
----
-3298
-664027
-68026

query I rowsort
SELECT ALL - 12 * + col1 AS col0 FROM tab2 AS cor0
----
-204
-372
-708

query I rowsort
SELECT - + 63 + + col2 FROM tab1 AS cor0
----
-6
-9
33

query I rowsort
SELECT DISTINCT + tab1.col2 + col0 + + ( col0 ) FROM tab1
----
185
256
60

query I rowsort
SELECT - + col0 + - col1 * - col0 AS col2 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT 92 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT DISTINCT - col1 * ( col0 ) AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + col2 - - col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + - 60 + col0 AS col2 FROM tab1 AS cor0
----
-57
20
4

query I rowsort
SELECT + + col1 + ( - col2 ) FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - 86 + + cor1.col1 AS col1 FROM tab1, tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-60
-73
-76

query I rowsort
SELECT + + ( 74 ) + col2 FROM tab1 AS cor0
----
128
131
170

query I rowsort
SELECT DISTINCT + ( col2 ) * + col2 - + 20 * + col1 * - col1 FROM tab1 cor0
----
12596
16436
5249

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) + col2 + col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col2 * col0 * - 61 AS col0 FROM tab2
----
-11529
-123708
-183122

query I rowsort
SELECT + 48 - 11 AS col2 FROM tab2 AS cor0
----
37
37
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 21 + col2 col2 FROM tab2 AS cor0
----
1664
1697
174

query I rowsort
SELECT ALL - col0 + ( - col1 ) AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT col0 + col2 * - 16 FROM tab2 AS cor0
----
-338
-425
-529

query I rowsort
SELECT col0 - 36 AS col0 FROM tab1 AS cor0
----
-33
28
44

query I rowsort
SELECT DISTINCT col1 * ( col1 ) + + col0 * col2 * 82 AS col2 FROM tab2
----
16459
169777
246453

query I rowsort
SELECT ALL col0 * 32 AS col0 FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT - col0 + 90 AS col2 FROM tab2 AS cor0
----
11
12
83

query I rowsort
SELECT + col1 * - 68 - 67 FROM tab2 cor0
----
-1223
-2175
-4079

query I rowsort
SELECT ALL + col1 + - 73 FROM tab2 AS cor0
----
-14
-42
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-3259
SELECT + col1 DIV col2 + - col1 * col0 FROM tab0 AS cor0
----
-2062
-3298
-8098

skipif mysql # not compatible
query I rowsort label-3259
SELECT + col1 / col2 + - col1 * col0 FROM tab0 AS cor0
----
-2062
-3298
-8098

query I rowsort
SELECT DISTINCT col1 + ( + col0 ) AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT col0 * - 22 FROM tab0
----
-1958
-528
-770

query I rowsort
SELECT ALL col2 * ( - col0 ) + - col2 FROM tab1
----
-216
-3705
-7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3263
SELECT - 83 * col2 + col0 + CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3263
SELECT - 83 * col2 + col0 + CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + cor0.col0 + - col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + - col1 + + col0 AS col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT cor0.col1 + - col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - col2 * 50 + + col1 FROM tab1 AS cor0
----
-2674
-2840
-4787

onlyif mysql # use DIV operator for integer division
query I rowsort label-3268
SELECT DISTINCT col2 DIV + col2 + col1 * col1 AS col1 FROM tab1
----
101
170
677

skipif mysql # not compatible
query I rowsort label-3268
SELECT DISTINCT col2 / + col2 + col1 * col1 AS col1 FROM tab1
----
101
170
677

query I rowsort
SELECT col0 + 39 * col1 FROM tab0
----
3378
3638
3818

query I rowsort
SELECT - col0 * col1 * 97 AS col2 FROM tab0
----
-200208
-329315
-785603

query I rowsort
SELECT + col2 + + col2 + col1 * - tab0.col0 FROM tab0
----
-1998
-3393
-7935

query I rowsort
SELECT col1 * 32 + tab0.col0 + col0 * col0 * col0 FROM tab0
----
16600
46014
707970

query I rowsort
SELECT DISTINCT + cor0.col1 * col1 + col2 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-3274
SELECT ALL col1 DIV - cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3274
SELECT ALL col1 / - cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col1 * col2 * col1 - col1 FROM tab2 cor0
----
-10999
-25978
-90565

query I rowsort
SELECT DISTINCT + + col2 + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - - col0 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + 71 * col0 FROM tab2
----
497
5538
5609

onlyif mysql # use DIV operator for integer division
query I rowsort label-3279
SELECT DISTINCT ( 56 ) * col1 DIV - col2 AS col1 FROM tab0
----
-145
-5432
-62

skipif mysql # not compatible
query I rowsort label-3279
SELECT DISTINCT ( 56 ) * col1 / - col2 AS col1 FROM tab0
----
-145
-5432
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3280
SELECT + CAST( NULL AS SIGNED ) * 89 * + col2 + - 44 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3280
SELECT + CAST ( NULL AS INTEGER ) * 89 * + col2 + - 44 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col0 + tab0.col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT - 36 * - col0 + - 3 * col2 * col1 AS col0 FROM tab1
----
-4104
-864
594

query I rowsort
SELECT ALL + cor0.col1 * col2 + 35 FROM tab2 AS cor0
----
1569
681
872

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + ( + cor0.col2 ) * col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col1 * 45 col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3a7fa0e00bc72391fc4753e3301af1a9

query I rowsort
SELECT DISTINCT cor1.col1 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT 43 + col0 FROM tab2
----
121
122
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-3289
SELECT - col0 * + col1 + - ( - col2 ) DIV col1 AS col1 FROM tab1
----
-1033
-635
-76

skipif mysql # not compatible
query I rowsort label-3289
SELECT - col0 * + col1 + - ( - col2 ) / col1 AS col1 FROM tab1
----
-1033
-635
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3290
SELECT ALL + - col2 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3290
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-3291
SELECT - + col0 * col2 DIV - cor0.col1 AS col2 FROM tab1 AS cor0
----
364
590
6

skipif mysql # not compatible
query I rowsort label-3291
SELECT - + col0 * col2 / - cor0.col1 AS col2 FROM tab1 AS cor0
----
364
590
6

query I rowsort
SELECT - 42 AS col2 FROM tab1, tab2 AS cor0, tab1 cor1
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

query I rowsort
SELECT - cor0.col1 * - col2 + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + col2 + - 39 FROM tab1 AS cor0
----
15
18
57

query I rowsort
SELECT DISTINCT + col2 * ( - cor0.col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3296
SELECT ALL cor0.col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3296
SELECT ALL cor0.col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3297
SELECT - col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3297
SELECT - col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - cor0.col1 * 63 AS col2 FROM tab2 AS cor0
----
-1071
-1953
-3717

query I rowsort
SELECT DISTINCT - col0 + + 14 FROM tab2 AS cor0
----
-64
-65
7

query I rowsort
SELECT DISTINCT + col2 * cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT - col1 * col1 + - col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT + 1 * - col1 * + col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + ( 19 + + tab1.col2 ) FROM tab1
----
115
73
76

query I rowsort
SELECT DISTINCT + 50 * tab2.col0 FROM tab2, tab1 cor0
----
350
3900
3950

query I rowsort
SELECT ( + col1 ) + - col1 + + col1 * cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + 51 AS col2 FROM tab2 AS cor0
----
51
51
51

query I rowsort
SELECT ALL - 52 + - 24 AS col2 FROM tab0 cor0
----
-76
-76
-76

query I rowsort
SELECT + col0 * 78 + col0 AS col0 FROM tab2 AS cor0
----
553
6162
6241

query I rowsort
SELECT ALL + 54 * cor0.col1 FROM tab1 AS cor0
----
1404
540
702

query I rowsort
SELECT ALL - col0 * ( cor0.col2 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - 68 * - col0 + col1 AS col1 FROM tab0 AS cor0
----
1718
2477
6143

query I rowsort
SELECT DISTINCT cor0.col1 + - 95 - + col1 AS col0 FROM tab1 AS cor0
----
-95

query I rowsort
SELECT DISTINCT cor0.col2 * 77 + - col0 * + cor0.col0 - + col1 FROM tab0 AS cor0
----
-1245
-1698
1879

query I rowsort
SELECT 5 * - col0 FROM tab1 AS cor0
----
-15
-320
-400

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab1 AS cor0
----
-76

query I rowsort
SELECT DISTINCT + - cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
-24
-35
-89

query I rowsort
SELECT - + col0 * + col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3319
SELECT DISTINCT 45 DIV - col1 col1 FROM tab2 cor0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3319
SELECT DISTINCT 45 / - col1 col1 FROM tab2 cor0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * cor0.col2 col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3321
SELECT 75 - - ( - col1 ) DIV col0 FROM tab0
----
72
73
74

skipif mysql # not compatible
query I rowsort label-3321
SELECT 75 - - ( - col1 ) / col0 FROM tab0
----
72
73
74

query I rowsort
SELECT col0 * 9 FROM tab0 AS cor0
----
216
315
801

query I rowsort
SELECT + 95 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3324
SELECT + col1 + CAST( + cor0.col0 + col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
133
143
262

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3324
SELECT + col1 + CAST ( + cor0.col0 + col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT + col2 * + 79 FROM tab2 cor0
----
2054
2133
3002

query I rowsort
SELECT - col0 * - col1 + - col1 + col1 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-624
530
858

query I rowsort
SELECT - - 56 + 88 * - col0 AS col2 FROM tab0 AS cor0
----
-2056
-3024
-7776

query I rowsort
SELECT + col0 * + 51 + + col0 AS col2 FROM tab0 cor0
----
1248
1820
4628

query I rowsort
SELECT DISTINCT 15 + ( col0 ) AS col1 FROM tab2
----
22
93
94

query I rowsort
SELECT ( - 14 ) * col0 + + col2 FROM tab0 AS cor0
----
-1164
-303
-489

query I rowsort
SELECT col0 * col1 + col0 + - col1 FROM tab1 AS cor0
----
1107
55
694

query I rowsort
SELECT - 59 AS col2 FROM tab2 cor0
----
-59
-59
-59

query I rowsort
SELECT - + 34 + col2 * col0 FROM tab0 AS cor0
----
1
7264
758

query I rowsort
SELECT ALL - cor0.col2 - 70 FROM tab2, tab1 cor0
----
9 values hashing to 92a602622138e800e7fb3aeecad7d103

query I rowsort
SELECT cor0.col0 + + 1 FROM tab1, tab1 AS cor0
----
9 values hashing to 5e068ef952ed56550cc6520d5d49d8e7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) + col2 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT ( col2 ) + - col2 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - 91 AS col2 FROM tab0 cor0
----
-91
-91
-91

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT - ( col0 ) + 5 * 91 AS col2 FROM tab1 AS cor0
----
375
391
452

query I rowsort
SELECT + - cor0.col1 - col0 * col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT 37 * col2 * tab1.col0 + 99 FROM tab1
----
135075
284259
6093

query I rowsort
SELECT + + col0 + + ( + 60 ) * col2 FROM tab0 AS cor0
----
2004
5009
95

query I rowsort
SELECT col0 * + 25 - col1 AS col2 FROM tab2 AS cor0
----
144
1891
1958

query I rowsort
SELECT + 91 * + col0 AS col2 FROM tab0
----
2184
3185
8099

query I rowsort
SELECT + 50 + tab2.col1 FROM tab2
----
109
67
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3347
SELECT ( col2 + 28 ) DIV col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3347
SELECT ( col2 + 28 ) / col1 FROM tab0
----
0
0
1

query I rowsort
SELECT DISTINCT col1 * + col1 + ( col2 ) * + col0 AS col0 FROM tab1
----
3748
7849
838

query I rowsort
SELECT DISTINCT col0 * col0 * - col2 + col0 * - col1 AS col2 FROM tab0
----
-21072
-4620
-657621

query I rowsort
SELECT - - col1 * - 83 FROM tab0 AS cor0
----
-7138
-7553
-8051

query I rowsort
SELECT ALL + col2 * col2 + col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL ( tab1.col1 ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - col2 * 32 AS col0 FROM tab1
----
-1728
-1824
-3072

query I rowsort
SELECT ALL - col1 * 82 AS col0 FROM tab2
----
-1394
-2542
-4838

query I rowsort
SELECT DISTINCT 32 AS col1 FROM tab0, tab1 AS cor0
----
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-3356
SELECT ALL 40 DIV - 11 col1 FROM tab1 AS cor0
----
-3
-3
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3356
SELECT ALL 40 / - 11 col1 FROM tab1 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT + + col2 * - col1 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 30 col1 FROM tab2 AS cor0
----
30
30
30

query I rowsort
SELECT - col2 * col1 + - col2 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT tab2.col1 + - 33 - - ( - tab2.col1 ) * - col0 AS col2 FROM tab2
----
1327
215
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 - - col0 * - tab1.col2 col2 FROM tab1
----
-3748
-7849
-838

onlyif mysql # use DIV operator for integer division
query I rowsort label-3362
SELECT DISTINCT - col0 DIV 80 - col1 AS col2 FROM tab0
----
-86
-92
-97

skipif mysql # not compatible
query I rowsort label-3362
SELECT DISTINCT - col0 / 80 - col1 AS col2 FROM tab0
----
-86
-92
-97

query I rowsort
SELECT ALL - cor0.col1 * cor0.col1 + 34 AS col0 FROM tab2 AS cor0
----
-255
-3447
-927

query I rowsort
SELECT DISTINCT - col0 - col2 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + ( - 85 ) * + col0 AS col0 FROM tab0
----
-2040
-2975
-7565

query I rowsort
SELECT DISTINCT + 21 AS col0 FROM tab2
----
21

query I rowsort
SELECT 51 * col0 * + col0 FROM tab1
----
208896
326400
459

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3368
SELECT - CAST( + col0 + col0 AS SIGNED ) AS col1 FROM tab1
----
-128
-160
-6

skipif mysql # not compatible
query I rowsort label-3368
SELECT - CAST ( + col0 + col0 AS INTEGER ) AS col1 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT + 31 + col0 * - col1 FROM tab0 AS cor0
----
-2033
-3364
-8068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT DISTINCT cor0.col1 AS col1 FROM tab2, tab1, tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3372
SELECT DISTINCT - CAST( col1 AS SIGNED ) * col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3372
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL - 73 AS col0 FROM tab2 AS cor0
----
-73
-73
-73

query I rowsort
SELECT ALL + + 25 + - 12 AS col1 FROM tab0 AS cor0
----
13
13
13

query I rowsort
SELECT - ( - 76 ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
6536
6916
7372

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col2 * 75 AS col1 FROM tab0 AS cor0
----
-2475
-6150
-75

query I rowsort
SELECT DISTINCT + + 93 * + col0 FROM tab0 AS cor0
----
2232
3255
8277

query I rowsort
SELECT 70 * + 14 FROM tab2 cor0
----
980
980
980

query I rowsort
SELECT ALL + + cor0.col1 * - col1 AS col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 94 AS col1 FROM tab0 AS cor0
----
-94
-94
-94

query I rowsort
SELECT 97 * - col2 - + col1 * + 23 AS col2 FROM tab1 AS cor0
----
-5759
-5836
-9611

query I rowsort
SELECT DISTINCT col0 + - cor0.col1 * + col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - - 75 * - cor0.col0 - + col1 AS col1 FROM tab0 AS cor0
----
-1886
-2722
-6766

query I rowsort
SELECT DISTINCT - 14 * - col1 + + col0 * + col0 AS col1 FROM tab2 AS cor0
----
483
6479
6910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3386
SELECT ALL - col2 / - col2 - - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3386
SELECT ALL - col2 / - col2 - - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 5 + col1 AS col1 FROM tab1 AS cor0
----
21
5
8

query I rowsort
SELECT + 59 + col1 AS col2 FROM tab0 AS cor0
----
145
150
156

query I rowsort
SELECT DISTINCT + col0 * col0 * - 29 AS col2 FROM tab0 AS cor0
----
-16704
-229709
-35525

query I rowsort
SELECT DISTINCT - ( - col1 ) + - 16 AS col1 FROM tab1 AS cor0
----
-3
-6
10

query I rowsort
SELECT + col0 - - col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 + - col1 * + col1 col1 FROM tab0 AS cor0
----
-7306
-8191
-9319

query I rowsort
SELECT ALL ( + col2 ) * + col2 AS col1 FROM tab0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + + col0 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col1 * col1 * 75 + + 86 AS col0 FROM tab0 AS cor0
----
554786
621161
705761

query I rowsort
SELECT ALL + 87 - + col1 AS col2 FROM tab1
----
61
74
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3397
SELECT ALL col0 + CAST( col2 * - col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-3397
SELECT ALL col0 + CAST ( col2 * - col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - tab2.col2 * 78 + col2 FROM tab2
----
-2002
-2079
-2926

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * col2 + col2 col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + cor0.col2 + cor0.col1 * 89 FROM tab2 AS cor0
----
1551
2786
5277

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3401
SELECT ALL - col1 * CAST( NULL AS SIGNED ) + + ( col0 + 85 ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3401
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) + + ( col0 + 85 ) FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3402
SELECT + + col0 + + col1 DIV col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3402
SELECT + + col0 + + col1 / col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + - cor0.col2 + 43 * col0 FROM tab2 AS cor0
----
274
3328
3359

query I rowsort
SELECT DISTINCT - - col2 * 56 + col0 * + col2 FROM tab2 AS cor0
----
1701
3484
5130

query I rowsort
SELECT DISTINCT - 22 AS col2 FROM tab1, tab1 AS cor0
----
-22

query I rowsort
SELECT DISTINCT + + ( cor1.col0 ) FROM tab0, tab1 AS cor0, tab2, tab2 cor1
----
7
78
79

query I rowsort
SELECT ( + col2 ) * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col0 * ( + col0 ) AS col2 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3409
SELECT - 60 DIV cor0.col1 FROM tab1 AS cor0
----
-2
-4
-6

skipif mysql # not compatible
query I rowsort label-3409
SELECT - 60 / cor0.col1 FROM tab1 AS cor0
----
-2
-4
-6

query I rowsort
SELECT DISTINCT + - col0 * cor0.col2 + col1 FROM tab1 cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * + ( + 61 ) col2 FROM tab2
----
427
4758
4819

onlyif mysql # use DIV operator for integer division
query I rowsort label-3412
SELECT + ( col1 ) * col1 + 92 DIV + 56 FROM tab1 AS cor0
----
101
170
677

skipif mysql # not compatible
query I rowsort label-3412
SELECT + ( col1 ) * col1 + 92 / + 56 FROM tab1 AS cor0
----
101
170
677

onlyif mysql # use DIV operator for integer division
query I rowsort label-3413
SELECT ALL - col2 * col1 DIV - col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3413
SELECT ALL - col2 * col1 / - col1 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT - 16 AS col1 FROM tab0
----
-16

query I rowsort
SELECT col2 * + col2 * + col1 + col2 AS col2 FROM tab2
----
22626
24586
39910

query I rowsort
SELECT DISTINCT + 19 + - col0 FROM tab1 AS cor0
----
-45
-61
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 18 * cor0.col1 col0 FROM tab0 cor0
----
1548
1638
1746

query I rowsort
SELECT ALL + - 54 * + cor0.col0 + + cor0.col2 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1215
-4912
-5746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3419
SELECT DISTINCT - CAST( + cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3419
SELECT DISTINCT - CAST ( + cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + col1 + + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + tab2.col0 * 92 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 6ce06b2ccbd8a8fbeab1648af4dac2f1

query I rowsort
SELECT DISTINCT + col2 * - col1 + - 43 AS col0 FROM tab0
----
-140
-2881
-7505

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3423
SELECT - - col1 * + CAST( NULL AS SIGNED ) - + col2 / col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3423
SELECT - - col1 * + CAST ( NULL AS INTEGER ) - + col2 / col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 9 * col1 AS col0 FROM tab2
----
-153
-279
-531

query I rowsort
SELECT ALL - 40 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT DISTINCT 17 AS col1 FROM tab0, tab1 AS cor0
----
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + col1 * + col2 col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT cor0.col1 FROM tab1, tab0, tab2 AS cor0 WHERE NOT ( NULL ) <> ( NULL )
----

query I rowsort
SELECT ALL + 3 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT DISTINCT + + col1 * + ( + col1 ) * + col0 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT - - col1 * cor0.col0 + 36 FROM tab2 cor0
----
1379
253
4638

query I rowsort
SELECT + 83 FROM tab1, tab1 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT DISTINCT - col0 * - 62 * 8 + + col1 AS col1 FROM tab1 AS cor0
----
1514
31754
39693

query I rowsort
SELECT ALL + + col0 + + col2 * cor0.col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL - cor0.col2 + + col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT cor0.col0 - + 17 FROM tab0 cor0
----
18
7
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * col2 - - col0 * + col1 col1 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT + - col1 * + 44 + col1 * + col0 FROM tab2 AS cor0
----
-1147
2006
595

query I rowsort
SELECT - col0 * 58 - - col1 * col2 FROM tab2 AS cor0
----
-2990
-3936
431

query I rowsort
SELECT col0 * + 62 FROM tab0
----
1488
2170
5518

query I rowsort
SELECT - + col2 * - col0 - 96 * + col2 FROM tab0 AS cor0
----
-2376
-574
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-3442
SELECT - col1 DIV + col0 + 92 + + col0 AS col0 FROM tab2 AS cor0
----
170
171
95

skipif mysql # not compatible
query I rowsort label-3442
SELECT - col1 / + col0 + 92 + + col0 AS col0 FROM tab2 AS cor0
----
170
171
95

query I rowsort
SELECT col1 + col2 * col1 FROM tab2
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col1 * col2 + - col2 col1 FROM tab2
----
1508
608
810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 col0 FROM tab2 WHERE NULL BETWEEN + col0 AND NULL
----

query I rowsort
SELECT DISTINCT + col2 + + tab0.col1 FROM tab0
----
119
173
98

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( col2 ) <= ( + col0 )
----
35
97
1
89
91
82

query I rowsort
SELECT + col0 + + col2 * + tab0.col0 * col2 FROM tab0
----
26160
598525
70

query I rowsort
SELECT col1 FROM tab2 WHERE NULL <= NULL
----

query I rowsort
SELECT - col1 + - col2 * col1 AS col2 FROM tab2
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT - col2 * - col1 + + col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL col0 * col2 * col2 + - col1 FROM tab0
----
-62
26050
598345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + tab0.col1 * col1 col2 FROM tab0
----
7372
8192
9374

query I rowsort
SELECT ALL col2 FROM tab2 WHERE NULL BETWEEN col0 AND NULL
----

query I rowsort
SELECT - col1 + col0 * - 23 AS col0 FROM tab1 AS cor0
----
-1482
-1853
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col0 col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + col1 * col1 * 54 - - col2 * + tab1.col0 FROM tab1
----
16806
36666
9048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + cor0.col1 ) col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3459
SELECT col0 - tab1.col1 DIV + col1 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3459
SELECT col0 - tab1.col1 / + col1 FROM tab1
----
2
63
79

query I rowsort
SELECT + - cor0.col0 + - col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + ( + col1 ) * - 73 AS col2 FROM tab1 AS cor0
----
-1898
-730
-949

onlyif mysql # use DIV operator for integer division
query I rowsort label-3462
SELECT DISTINCT - col2 DIV col0 AS col2 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-3462
SELECT DISTINCT - col2 / col0 AS col2 FROM tab0 AS cor0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3463
SELECT ALL - - col1 * col0 * CAST( - cor0.col2 + - col2 AS SIGNED ) FROM tab2 cor0
----
-102068
-11718
-239304

skipif mysql # not compatible
query I rowsort label-3463
SELECT ALL - - col1 * col0 * CAST ( - cor0.col2 + - col2 AS INTEGER ) FROM tab2 cor0
----
-102068
-11718
-239304

query I rowsort
SELECT + - cor0.col1 * col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + 57 + - col1 * + ( cor0.col1 ) FROM tab0 AS cor0
----
-7339
-8224
-9352

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3466
SELECT ALL + cor0.col0 * - CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3466
SELECT ALL + cor0.col0 * - CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + col0 * + 15 FROM tab2 AS cor0
----
105
1170
1185

query I rowsort
SELECT ALL + col1 + 84 * + col0 FROM tab2 AS cor0
----
619
6611
6653

query I rowsort
SELECT ALL + col0 * ( col1 ) + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + col2 - + 81 * + 90 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
189594
72957
94866

query I rowsort
SELECT - 2 + + col1 + + col0 AS col1 FROM tab2 AS cor0
----
135
36
94

query I rowsort
SELECT col2 + ( col0 ) * col1 AS col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT 7 FROM tab1, tab2 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT DISTINCT 16 + - 87 * + col2 FROM tab0
----
-2855
-71
-7118

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3475
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col1 * + col0 + + 18 + - col2 col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3475
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col1 * + col0 + + 18 + - col2 col2 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3476
SELECT + + CAST( - 16 AS SIGNED ) DIV - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3476
SELECT + + CAST ( - 16 AS INTEGER ) / - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 3 + + col2 AS col1 FROM tab1 AS cor0
----
51
54
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3478
SELECT DISTINCT - + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3478
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3479
SELECT + col2 DIV col2 + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3479
SELECT + col2 / col2 + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT col2 + 86 FROM tab0 AS cor0
----
119
168
87

query I rowsort
SELECT ALL col1 * 21 AS col0 FROM tab0
----
1806
1911
2037

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3482
SELECT DISTINCT CAST( col0 AS SIGNED ) col0 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3482
SELECT DISTINCT CAST ( col0 AS INTEGER ) col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + + 45 * col2 + - 75 FROM tab2 AS cor0
----
1095
1140
1635

query I rowsort
SELECT DISTINCT 83 * col1 FROM tab1 AS cor0
----
1079
2158
830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 54 * - cor0.col2 col2 FROM tab1 AS cor0
----
-2916
-3078
-5184

query I rowsort
SELECT ALL - 85 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 8ebc8ffafb1517ea04e3a6fc4059d88a

query I rowsort
SELECT ALL col2 * 35 FROM tab0
----
1155
2870
35

query I rowsort
SELECT ALL + tab2.col2 * - 88 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 3e56dbf641de9ee54df61dcd44495d20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3489
SELECT DISTINCT - - col1 * + cor0.col1 + cor0.col2 + col0 DIV col0 FROM tab2 AS cor0
----
328
3508
989

skipif mysql # not compatible
query I rowsort label-3489
SELECT DISTINCT - - col1 * + cor0.col1 + cor0.col2 + col0 / col0 FROM tab2 AS cor0
----
328
3508
989

query I rowsort
SELECT 27 * col1 AS col1 FROM tab2
----
1593
459
837

query I rowsort
SELECT 37 * + col1 AS col2 FROM tab1
----
370
481
962

query I rowsort
SELECT col0 + + col2 * - col0 AS col2 FROM tab2
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-3493
SELECT - col2 + - col2 DIV tab1.col0 FROM tab1
----
-57
-72
-97

skipif mysql # not compatible
query I rowsort label-3493
SELECT - col2 + - col2 / tab1.col0 FROM tab1
----
-57
-72
-97

query I rowsort
SELECT DISTINCT + + cor0.col2 + col2 AS col2 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT + col2 * + col0 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + 5 + col2 FROM tab1
----
101
59
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 49 * - col2 col1 FROM tab1
----
2646
2793
4704

query I rowsort
SELECT DISTINCT tab0.col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
24
35
89

query I rowsort
SELECT + col2 + + 22 + + tab2.col2 * col2 FROM tab2
----
1504
724
778

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3500
SELECT ALL + - CAST( NULL AS SIGNED ) * col1 - cor0.col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3500
SELECT ALL + - CAST ( NULL AS INTEGER ) * col1 - cor0.col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( col0 ) + - col0 * - col1 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT + - 61 - col1 FROM tab1 AS cor0
----
-71
-74
-87

query I rowsort
SELECT - + col2 - 0 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + 23 + + 97 AS col0 FROM tab2
----
120
120
120

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - 58 * - col2 AS REAL ) + col2 + - tab1.col0 AS col2 FROM tab1
----
-3081
-3313
-5552

query I rowsort
SELECT DISTINCT col2 + col2 + col1 * + col1 FROM tab1 AS cor0
----
214
361
784

onlyif mysql # use DIV operator for integer division
query I rowsort label-3507
SELECT DISTINCT - 77 * col1 - - col1 DIV + col0 AS col2 FROM tab1 AS cor0
----
-1001
-1994
-770

skipif mysql # not compatible
query I rowsort label-3507
SELECT DISTINCT - 77 * col1 - - col1 / + col0 AS col2 FROM tab1 AS cor0
----
-1001
-1994
-770

query I rowsort
SELECT ALL - 88 + + col1 FROM tab2 AS cor0
----
-29
-57
-71

query I rowsort
SELECT ALL - + cor0.col2 * cor0.col1 + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT col0 * col1 - - col2 FROM tab1 AS cor0
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col0 + + col2 + col2 col0 FROM tab2 cor0
----
103
6136
6317

query I rowsort
SELECT + + col2 + col2 * col0 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT + + ( col0 ) + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col2 - col0 * col2 * col2 FROM tab1
----
-207993
-737376
-8802

onlyif mysql # use DIV operator for integer division
query I rowsort label-3515
SELECT DISTINCT 50 * ( + col0 ) + - col1 DIV + col2 AS col2 FROM tab0
----
1198
1653
4449

skipif mysql # not compatible
query I rowsort label-3515
SELECT DISTINCT 50 * ( + col0 ) + - col1 / + col2 AS col2 FROM tab0
----
1198
1653
4449

query I rowsort
SELECT DISTINCT - - col1 * cor0.col1 + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + 99 * - col0 + - col0 AS col0 FROM tab2 AS cor0
----
-700
-7800
-7900

query I rowsort
SELECT ALL + - 34 * - col1 AS col1 FROM tab2 cor0
----
1054
2006
578

onlyif mysql # use DIV operator for integer division
query I rowsort label-3519
SELECT DISTINCT col2 + col1 DIV - col0 FROM tab1 AS cor0
----
46
57
96

skipif mysql # not compatible
query I rowsort label-3519
SELECT DISTINCT col2 + col1 / - col0 FROM tab1 AS cor0
----
46
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col1 col1 FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3521
SELECT DISTINCT - col2 + + tab0.col0 DIV col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3521
SELECT DISTINCT - col2 + + tab0.col0 / col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT col1 + + tab1.col1 + col1 FROM tab1 WHERE NOT col1 * - col0 * - col2 BETWEEN ( col0 * - col1 ) AND ( col0 )
----
30
39
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT ALL col0 + col1 DIV + col1 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-3523
SELECT ALL col0 + col1 / + col1 FROM tab2
----
79
8
80

query I rowsort
SELECT col0 + - col0 * tab2.col0 FROM tab2
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-3525
SELECT ALL - col0 + + col1 DIV col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3525
SELECT ALL - col0 + + col1 / col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + cor0.col1 col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT col2 - col1 * - col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + col0 * + col0 + + col1 AS col2 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT + col1 * + col0 * col1 FROM tab0
----
177504
329315
737009

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN ( col0 ) AND NULL
----

query I rowsort
SELECT DISTINCT + col1 + - col1 * tab0.col0 * - col2 FROM tab0
----
3492
664209
68198

query I rowsort
SELECT - col2 + + col2 * - col0 - - tab0.col0 * col1 FROM tab0
----
1239
3359
719

query I rowsort
SELECT DISTINCT - tab0.col2 * col1 * col2 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT col2 AS col2 FROM tab0 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT col2 - - col0 * col0 AS col1 FROM tab0
----
1226
609
8003

query I rowsort
SELECT - col0 * - col0 AS col0 FROM tab1 WHERE - col1 BETWEEN col0 AND + col1
----

query I rowsort
SELECT col2 * - tab1.col1 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL col1 * - col1 + - tab1.col1 FROM tab1
----
-110
-182
-702

query I rowsort
SELECT col0 * col0 + col2 * - col2 * - col2 FROM tab2
----
19732
23660
61113

query I rowsort
SELECT DISTINCT col0 * tab1.col0 * col0 FROM tab1 WHERE col1 * tab1.col1 NOT BETWEEN NULL AND - col1
----
262144
27
512000

query I rowsort
SELECT DISTINCT col1 FROM tab1 WHERE NOT NULL NOT BETWEEN ( col1 ) AND NULL
----

query I rowsort
SELECT ALL + col1 * col0 * col0 + col1 FROM tab1
----
260
40970
83213

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col0 + - col0 <= col1 * + col1
----

query III rowsort
SELECT * FROM tab0 WHERE ( + col1 ) = ( NULL )
----

query I rowsort
SELECT tab0.col0 * + col1 + - col1 * + col1 * - col1 AS col0 FROM tab0
----
638120
761670
916068

query I rowsort
SELECT DISTINCT tab1.col1 * - col0 + + tab1.col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT - + col1 * - col1 - - col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL + col2 * + col0 * - col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT col0 * col0 * - col0 AS col1 FROM tab2 AS cor0
----
-343
-474552
-493039

query I rowsort
SELECT - cor0.col1 - col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3551
SELECT DISTINCT - col1 + col2 DIV col2 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3551
SELECT DISTINCT - col1 + col2 / col2 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT DISTINCT + col1 + - col2 + col1 AS col2 FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT - col0 * - col0 AS col1 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL col1 * + col1 + - col1 AS col1 FROM tab0
----
7310
8190
9312

query I rowsort
SELECT col2 - - cor0.col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col1 * tab0.col0 col2 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT - tab0.col2 FROM tab0 WHERE NOT ( - col1 ) < col1
----

query I rowsort
SELECT + cor0.col1 * col0 - col2 * col2 FROM tab0 AS cor0
----
1375
3394
975

query I rowsort
SELECT ALL + tab0.col1 + tab0.col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT + ( - cor0.col0 ) + - col0 * col2 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3561
SELECT - - CAST( NULL AS SIGNED ) + + col1 * + col1 / col2 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3561
SELECT - - CAST ( NULL AS INTEGER ) + + col1 * + col1 / col2 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3562
SELECT + CAST( - col2 AS SIGNED ) * col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-3562
SELECT + CAST ( - col2 AS INTEGER ) * col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - cor0.col2 + + 13 FROM tab0, tab1 AS cor0
----
-41
-44
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 42 * cor0.col2 col2 FROM tab2 AS cor0
----
-1092
-1134
-1596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + col1 col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + 13 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT + ( + col0 ) * + 81 * + col2 AS col0 FROM tab0 AS cor0
----
2835
591138
64152

query I rowsort
SELECT + - ( cor0.col1 ) * - col1 * + col2 AS col1 FROM tab1 cor0
----
16224
36504
5700

query I rowsort
SELECT col1 + - col0 * + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL - + 71 + + 6 AS col2 FROM tab1 AS cor0
----
-65
-65
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col0 * + tab2.col0 col2 FROM tab2
----
22
6058
6203

query I rowsort
SELECT - - col1 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT col1 * - 56 AS col0 FROM tab1
----
-1456
-560
-728

query I rowsort
SELECT tab0.col2 * - 43 AS col2 FROM tab0
----
-1419
-3526
-43

query I rowsort
SELECT - 89 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-25
-86
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - - col2 col2 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3577
SELECT DISTINCT col1 DIV - 43 + col1 AS col1 FROM tab2 AS cor0
----
17
31
58

skipif mysql # not compatible
query I rowsort label-3577
SELECT DISTINCT col1 / - 43 + col1 AS col1 FROM tab2 AS cor0
----
17
31
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3578
SELECT + - CAST( NULL AS SIGNED ) * + 3 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3578
SELECT + - CAST ( NULL AS INTEGER ) * + 3 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col2 ) * - col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - cor0.col1 * 76 AS col1 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 4e097ad9c091ee388424ea3f52c8befd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3581
SELECT ALL CAST( col2 AS SIGNED ) + cor0.col1 col2 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3581
SELECT ALL CAST ( col2 AS INTEGER ) + cor0.col1 col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3582
SELECT - ( col0 ) + col0 DIV - cor0.col0 FROM tab2 cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-3582
SELECT - ( col0 ) + col0 / - cor0.col0 FROM tab2 cor0
----
-79
-8
-80

query I rowsort
SELECT ALL - 19 AS col2 FROM tab1
----
-19
-19
-19

query I rowsort
SELECT - cor0.col2 * 63 FROM tab1, tab0 AS cor0
----
9 values hashing to 2e066f77ad23665daf259815c7024318

query I rowsort
SELECT + - cor0.col0 - col2 AS col0 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3586
SELECT col0 * col2 - col0 DIV 94 AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-3586
SELECT col0 * col2 - col0 / 94 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - col0 + ( + col2 + - col2 ) * - 59 AS col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - col0 + 78 AS col0 FROM tab1 AS cor0
----
-2
14
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3589
SELECT + + cor0.col0 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3589
SELECT + + cor0.col0 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL + + col2 * ( col2 + col0 * 8 ) AS col0 FROM tab0 AS cor0
----
281
65108
7425

query I rowsort
SELECT ALL + - col1 + col2 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT cor0.col1 + ( col0 ) * - cor0.col2 * - col0 AS col1 FROM tab0 AS cor0
----
1322
19094
649613

query I rowsort
SELECT col0 * - col1 + - col0 + + col2 FROM tab1 AS cor0
----
-1024
-27
-647

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 col2 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3596
SELECT + CAST( NULL AS DECIMAL ) * + 23 AS col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3596
SELECT + CAST ( NULL AS REAL ) * + 23 AS col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + col1 - - col2 * col0 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT cor0.col0 * 24 + + col2 FROM tab1 AS cor0
----
126
1593
2016

query I rowsort
SELECT ALL - - col1 * col0 - col0 AS col2 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3600
SELECT DISTINCT - col2 + col2 DIV - col2 FROM tab1 cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-3600
SELECT DISTINCT - col2 + col2 / - col2 FROM tab1 cor0
----
-55
-58
-97

query I rowsort
SELECT DISTINCT - - col0 * + col2 - col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL + col0 * - col2 + + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + + ( col1 ) + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - + col2 * col2 + col0 * col2 + - col2 FROM tab2 AS cor0
----
-567
1326
1520

query I rowsort
SELECT ALL + col2 + 2 AS col0 FROM tab0
----
3
35
84

query I rowsort
SELECT ALL - 90 + + col2 FROM tab1
----
-33
-36
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3607
SELECT - col0 DIV cor0.col1 AS col2 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-3607
SELECT - col0 / cor0.col1 AS col2 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT - cor0.col2 + - 91 * 8 AS col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 47680bc69191229926d2207d5fb94dae

query I rowsort
SELECT col0 * + col2 + + col0 * - col2 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 * cor0.col2 + + col2 * - col2 AS col1 FROM tab0 AS cor0
----
-297
34
574

query I rowsort
SELECT ALL + 67 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT - col0 * col1 * ( ( + col2 ) ) + 78 AS col0 FROM tab0
----
-3317
-664040
-68034

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 14 col1 FROM tab0
----
14
14
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-3614
SELECT - - col2 DIV - col1 + + col2 AS col1 FROM tab1 AS cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-3614
SELECT - - col2 / - col1 + + col2 AS col1 FROM tab1 AS cor0
----
52
52
89

query I rowsort
SELECT ALL col0 * - col0 * col0 AS col2 FROM tab1 AS cor0
----
-262144
-27
-512000

query I rowsort
SELECT + 74 * col1 + col2 + + 77 * - col0 FROM tab0 AS cor0
----
-37
4484
4549

query I rowsort
SELECT + - 93 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to ea79c61f7a02d25805171f5e85229fba

query I rowsort
SELECT ALL - col1 - 66 FROM tab1
----
-76
-79
-92

query I rowsort
SELECT ALL + col0 * - col0 - col1 AS col1 FROM tab1
----
-35
-4106
-6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-3620
SELECT + col0 DIV CAST( + col2 AS SIGNED ) AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3620
SELECT + col0 / CAST ( + col2 AS INTEGER ) AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT ALL + - 59 + - 12 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1211
-707
-743

query I rowsort
SELECT 38 * - col2 + cor0.col0 * col1 FROM tab2 AS cor0
----
-101
-809
3614

query I rowsort
SELECT ALL + ( cor0.col1 ) + - col1 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 30 * - 91 - col0 col0 FROM tab2 AS cor0
----
2651
2652
2723

query I rowsort
SELECT + - 41 + col1 * col1 * ( - col2 ) AS col0 FROM tab1 AS cor0
----
-16265
-36545
-5741

query I rowsort
SELECT DISTINCT cor0.col0 + - col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3627
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col1 * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3627
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col1 * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + + col2 * - col2 + + col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT + 53 FROM tab2, tab2 AS cor0
----
53

query I rowsort
SELECT ALL col2 * 9 - + 63 AS col0 FROM tab2
----
171
180
279

query I rowsort
SELECT DISTINCT col1 + + 59 * col0 - cor0.col1 FROM tab1 AS cor0
----
177
3776
4720

query I rowsort
SELECT - col0 + - col1 + + col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col0 + + tab2.col0 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ( - cor0.col0 ) - col2 FROM tab1 cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 64 col0 FROM tab1 AS cor0
----
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3636
SELECT + - CAST( NULL AS SIGNED ) + col0 * - cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3636
SELECT + - CAST ( NULL AS INTEGER ) + col0 * - cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3637
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col0 + + col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3637
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col0 + + col0 AS col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3638
SELECT ALL + + CAST( NULL AS SIGNED ) + col2 * - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3638
SELECT ALL + + CAST ( NULL AS INTEGER ) + col2 * - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3639
SELECT ALL + ( + ( - col1 ) ) * col0 + ( - col2 ) * CAST( + col2 * + col2 AS SIGNED ) FROM tab0 cor0
----
-3396
-38001
-559467

skipif mysql # not compatible
query I rowsort label-3639
SELECT ALL + ( + ( - col1 ) ) * col0 + ( - col2 ) * CAST ( + col2 * + col2 AS INTEGER ) FROM tab0 cor0
----
-3396
-38001
-559467

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 53 + ( + col0 ) col0 FROM tab2
----
-46
25
26

query I rowsort
SELECT ALL - ( col1 ) + + col1 + - col0 FROM tab1
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 + + col1 col2 FROM tab1
----
104
88
91

query I rowsort
SELECT DISTINCT tab0.col2 * + col0 + + col2 AS col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT 25 * cor0.col2 FROM tab1, tab0 AS cor0
----
2050
25
825

query I rowsort
SELECT - col2 + 78 FROM tab1
----
-18
21
24

query I rowsort
SELECT 88 * col2 AS col1 FROM tab2
----
2288
2376
3344

query I rowsort
SELECT ALL + ( cor0.col1 ) + col0 * 36 AS col1 FROM tab1 AS cor0
----
134
2314
2893

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3648
SELECT ALL CAST( col2 AS SIGNED ) + - col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3648
SELECT ALL CAST ( col2 AS INTEGER ) + - col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT col0 * 19 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT DISTINCT + col0 * col2 + + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT - ( tab0.col1 ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + 7 + - 83 FROM tab1 AS cor0
----
-76
-76
-76

query I rowsort
SELECT DISTINCT + - 63 + col0 * col2 FROM tab0 cor0
----
-28
7235
729

query I rowsort
SELECT ALL - col2 - col0 * 51 AS col0 FROM tab2 cor0
----
-384
-4004
-4067

query I rowsort
SELECT DISTINCT - + col0 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL 36 + col0 * - col2 AS col1 FROM tab1 AS cor0
----
-126
-3612
-7644

onlyif mysql # use DIV operator for integer division
query I rowsort label-3657
SELECT DISTINCT ( - col2 ) * ( col0 ) + col1 DIV 29 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3657
SELECT DISTINCT ( - col2 ) * ( col0 ) + col1 / 29 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT 81 - + cor0.col1 AS col0 FROM tab1 cor0
----
55
68
71

query I rowsort
SELECT DISTINCT ( col2 ) + col1 AS col1 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3660
SELECT ALL + ( tab2.col2 ) + tab2.col2 DIV - 95 col0 FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3660
SELECT ALL + ( tab2.col2 ) + tab2.col2 / - 95 col0 FROM tab2
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3661
SELECT DISTINCT - + col1 DIV + cor0.col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3661
SELECT DISTINCT - + col1 / + cor0.col1 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - 62 FROM tab0, tab2 cor0
----
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3663
SELECT ALL + - col1 / - CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3663
SELECT ALL + - col1 / - CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 * - 41 FROM tab2 AS cor0
----
287
3198
3239

query I rowsort
SELECT ALL - col2 + ( + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + + col1 * + ( - col0 * col1 + col0 ) FROM tab0 AS cor0
----
-175440
-325920
-728910

query I rowsort
SELECT + + col0 * col0 * col2 FROM tab2 AS cor0
----
1323
158184
237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 70 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT DISTINCT ( + col0 ) * cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - - 9 * col2 FROM tab1 AS cor0
----
486
513
864

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 8bda8b9cf32f196464e0ee0b41a5162d

query I rowsort
SELECT DISTINCT + col1 * + ( 63 ) FROM tab0
----
5418
5733
6111

query I rowsort
SELECT DISTINCT ( - col2 ) * col2 * col1 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT tab2.col0 * - col1 + - 55 AS col1 FROM tab2
----
-1398
-272
-4657

query I rowsort
SELECT - 88 + col0 * ( - 93 + col0 * + 98 ) AS col0 FROM tab2 AS cor0
----
4063
588890
604183

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2, tab1 cor3
----
3645 values hashing to 25b7fe296c05e1a753085cc7e649d673

query I rowsort
SELECT ALL col1 * - col1 * col0 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT DISTINCT 40 - + 33 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
7

query I rowsort
SELECT ALL col0 * - 35 FROM tab2 AS cor0
----
-245
-2730
-2765

query I rowsort
SELECT - + 81 + 34 AS col2 FROM tab2 cor0
----
-47
-47
-47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3681
SELECT DISTINCT col1 * ( - col1 ) + CAST( + 94 AS SIGNED ) - col2 * + ( 78 * tab2.col0 + - col0 ) col1 FROM tab2
----
-15420
-159543
-231349

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3681
SELECT DISTINCT col1 * ( - col1 ) + CAST ( + 94 AS INTEGER ) - col2 * + ( 78 * tab2.col0 + - col0 ) col1 FROM tab2
----
-15420
-159543
-231349

query I rowsort
SELECT ( + cor0.col0 ) * col0 + - col0 * + 91 AS col1 FROM tab1 AS cor0
----
-1728
-264
-880

onlyif mysql # use DIV operator for integer division
query I rowsort label-3683
SELECT 43 * col0 + cor0.col1 DIV 17 + + cor0.col2 FROM tab1 AS cor0
----
184
2809
3536

skipif mysql # not compatible
query I rowsort label-3683
SELECT 43 * col0 + cor0.col1 / 17 + + cor0.col2 FROM tab1 AS cor0
----
184
2809
3536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3684
SELECT + col0 * col0 - col0 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3684
SELECT + col0 * col0 - col0 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 74 * 23 + + col1 AS col2 FROM tab1 AS cor0
----
1712
1715
1728

query I rowsort
SELECT ALL - cor0.col2 * + col2 * + 77 AS col2 FROM tab1 AS cor0
----
-224532
-250173
-709632

query I rowsort
SELECT + + 80 * - col0 * - col1 + col1 * col1 FROM tab2 AS cor0
----
107729
18321
371641

query I rowsort
SELECT - 72 * cor0.col1 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5d5ef1574947049fb8562a7412c6d88b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 * 23 * - col0 col1 FROM tab1
----
142784
178480
6693

query I rowsort
SELECT ALL + ( col0 ) + ( 0 ) FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3691
SELECT - + col0 DIV - cor0.col1 - 53 FROM tab1 AS cor0
----
-47
-47
-53

skipif mysql # not compatible
query I rowsort label-3691
SELECT - + col0 / - cor0.col1 - 53 FROM tab1 AS cor0
----
-47
-47
-53

query I rowsort
SELECT DISTINCT + 19 + + col2 FROM tab0 AS cor0
----
101
20
52

query I rowsort
SELECT DISTINCT + col1 + - col2 + col0 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT ALL 3 * col1 AS col1 FROM tab1 AS cor0
----
30
39
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3695
SELECT - + col1 * col0 DIV + 17 - + col1 AS col0 FROM tab0 AS cor0
----
-207
-296
-567

skipif mysql # not compatible
query I rowsort label-3695
SELECT - + col1 * col0 / + 17 - + col1 AS col0 FROM tab0 AS cor0
----
-207
-296
-567

query I rowsort
SELECT + col1 + col1 * + ( - col1 ) FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT - 26 AS col1 FROM tab0 AS cor0
----
-26

query I rowsort
SELECT ALL + ( - col2 ) * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3699
SELECT ALL 22 DIV col2 AS col1 FROM tab0 AS cor0
----
0
0
22

skipif mysql # not compatible
query I rowsort label-3699
SELECT ALL 22 / col2 AS col1 FROM tab0 AS cor0
----
0
0
22

query I rowsort
SELECT ALL 3 * + 32 AS col0 FROM tab2
----
96
96
96

query I rowsort
SELECT DISTINCT - col1 * - col0 + - 87 AS col2 FROM tab1 AS cor0
----
-9
553
953

onlyif mysql # use DIV operator for integer division
query I rowsort label-3702
SELECT ALL - cor0.col0 DIV - cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3702
SELECT ALL - cor0.col0 / - cor0.col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3703
SELECT CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3703
SELECT CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - - 45 + + 37 * - cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to e6a9f9c22c44cd08b5be269c0bef4076

query I rowsort
SELECT + 65 + col1 * 46 FROM tab0 AS cor0
----
4021
4251
4527

onlyif mysql # use DIV operator for integer division
query I rowsort label-3706
SELECT ALL + + 7 + col2 DIV col0 FROM tab2 AS cor0
----
10
7
7

skipif mysql # not compatible
query I rowsort label-3706
SELECT ALL + + 7 + col2 / col0 FROM tab2 AS cor0
----
10
7
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3707
SELECT DISTINCT + CAST( NULL AS SIGNED ) * cor0.col1 + col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3707
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * cor0.col1 + col1 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + ( + cor0.col0 ) + + col0 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3709
SELECT tab0.col1 * CAST( col1 AS SIGNED ) - tab0.col2 * + ( - col0 * col0 ) AS col2 FROM tab0
----
10634
26404
657803

skipif mysql # not compatible
query I rowsort label-3709
SELECT tab0.col1 * CAST ( col1 AS INTEGER ) - tab0.col2 * + ( - col0 * col0 ) AS col2 FROM tab0
----
10634
26404
657803

onlyif mysql # use DIV operator for integer division
query I rowsort label-3710
SELECT DISTINCT col1 DIV col1 - col1 AS col1 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3710
SELECT DISTINCT col1 / col1 - col1 AS col1 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT + ( - 68 ) + + tab0.col2 * col0 + col0 * - col0 FROM tab0
----
-1258
-691
148

query I rowsort
SELECT ALL col1 - - col1 AS col2 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT + col1 * 36 - col1 FROM tab0
----
3010
3185
3395

query I rowsort
SELECT ALL + 5 - + col1 FROM tab0
----
-81
-86
-92

query I rowsort
SELECT DISTINCT + 45 FROM tab2, tab1 AS cor0
----
45

query I rowsort
SELECT col0 * 11 FROM tab2 AS cor0
----
77
858
869

query I rowsort
SELECT ALL + + ( col0 ) + - col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 + + 72 AS col2 FROM tab2 AS cor0
----
103
131
89

query I rowsort
SELECT DISTINCT + col2 * 38 * + col1 AS col1 FROM tab2 AS cor0
----
24548
31806
58292

query I rowsort
SELECT ALL col2 + col0 * + col2 * col1 AS col1 FROM tab2
----
119678
51072
5886

query I rowsort
SELECT ALL + + cor0.col2 + - cor0.col2 * col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3722
SELECT ALL + col1 * + CAST( NULL AS DECIMAL ) - - 1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3722
SELECT ALL + col1 * + CAST ( NULL AS REAL ) - - 1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * 50 FROM tab0 AS cor0
----
-1650
-4100
-50

query I rowsort
SELECT DISTINCT - col2 - - col1 FROM tab2 cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * col1 - col1 col1 FROM tab1 AS cor0
----
1027
52
630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 - cor0.col2 col0 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3727
SELECT ALL + - col2 * - CAST( + cor0.col2 + col1 AS SIGNED ) FROM tab0 AS cor0
----
14186
3927
98

skipif mysql # not compatible
query I rowsort label-3727
SELECT ALL + - col2 * - CAST ( + cor0.col2 + col1 AS INTEGER ) FROM tab0 AS cor0
----
14186
3927
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3728
SELECT DISTINCT + col0 DIV + cor0.col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3728
SELECT DISTINCT + col0 / + cor0.col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - - col2 * 9 AS col1 FROM tab1 AS cor0
----
486
513
864

query I rowsort
SELECT DISTINCT + + col0 + - ( col0 ) AS col2 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3731
SELECT + col1 DIV ( col0 ) FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-3731
SELECT + col1 / ( col0 ) FROM tab2 cor0
----
0
0
4

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-3733
SELECT ALL + col0 DIV + ( col0 ) AS col2 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3733
SELECT ALL + col0 / + ( col0 ) AS col2 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - - col1 * ( col2 ) * + col2 + + col2 * 32 FROM tab2 AS cor0
----
23463
25764
40716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3735
SELECT CAST( 9 AS SIGNED ) * - col0 FROM tab2 AS cor0
----
-63
-702
-711

skipif mysql # not compatible
query I rowsort label-3735
SELECT CAST ( 9 AS INTEGER ) * - col0 FROM tab2 AS cor0
----
-63
-702
-711

query I rowsort
SELECT - col0 * + 15 AS col2 FROM tab1 cor0
----
-1200
-45
-960

query I rowsort
SELECT DISTINCT - + col1 - 49 FROM tab0 AS cor0
----
-135
-140
-146

query I rowsort
SELECT - - col0 + + col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL 91 * + cor0.col2 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 45ffe4033e4383b977f8da60b77dd9de

query I rowsort
SELECT DISTINCT - 87 * + col1 * col0 - - col2 FROM tab2 cor0
----
-116803
-18852
-400348

query I rowsort
SELECT ALL 48 AS col0 FROM tab1 AS cor0
----
48
48
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 50 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT + + 19 * 35 AS col2 FROM tab2 AS cor0
----
665
665
665

query I rowsort
SELECT - - cor0.col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col2 * - ( col1 ) col1 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + + col1 + col2 * - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( cor0.col2 + cor0.col2 ) col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
108
114
192

query I rowsort
SELECT DISTINCT + 20 * + cor0.col1 FROM tab0 AS cor0
----
1720
1820
1940

query I rowsort
SELECT ALL - - col0 * - col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + 31 AS col2 FROM tab1 cor0
----
31
31
31

query I rowsort
SELECT ALL 62 * ( col1 ) * col2 AS col1 FROM tab1
----
35340
77376
87048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + col0 col2 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3753
SELECT ALL 31 DIV - col1 col1 FROM tab1
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3753
SELECT ALL 31 / - col1 col1 FROM tab1
----
-1
-2
-3

query I rowsort
SELECT col2 + + 37 * cor0.col0 AS col2 FROM tab2 AS cor0
----
286
2912
2961

query I rowsort
SELECT + col1 * - col0 + ( col0 + - col2 ) * - col0 FROM tab0
----
-1848
-4585
-8722

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT - - col0 + 60 AS col0 FROM tab2 AS cor0
----
138
139
67

query I rowsort
SELECT + col0 * - col0 AS col2 FROM tab0 cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3759
SELECT + + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3759
SELECT + + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 + - col1 col0 FROM tab1
----
56
69
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3761
SELECT + col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3761
SELECT + col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col2 * + 8 AS col0 FROM tab2
----
208
216
304

query I rowsort
SELECT DISTINCT - tab2.col1 * + col1 AS col0 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT + col1 + - 84 AS col0 FROM tab0 AS cor0
----
13
2
7

query I rowsort
SELECT + 59 * col2 + col0 FROM tab2
----
1600
1612
2321

query I rowsort
SELECT tab0.col0 + + col0 AS col0 FROM tab0
----
178
48
70

query I rowsort
SELECT col1 * 98 FROM tab0
----
8428
8918
9506

query I rowsort
SELECT DISTINCT + - ( - ( + col2 ) ) * col2 - cor0.col0 AS col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT - + ( ( - col2 ) ) FROM tab0 cor0
----
1
33
82

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-3771
SELECT DISTINCT col1 + + col0 DIV col2 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-3771
SELECT DISTINCT col1 + + col0 / col2 FROM tab0 AS cor0
----
132
86
92

query I rowsort
SELECT ALL + + ( col2 ) + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + col0 + col2 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col0 * col0 + + col2 AS col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL cor0.col1 - col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 * + cor0.col1 + cor0.col1 + cor0.col2 * + col2 AS col1 FROM tab0 AS cor0
----
15096
8571
9507

query I rowsort
SELECT + 56 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

onlyif mysql # use DIV operator for integer division
query I rowsort label-3778
SELECT + + cor0.col1 * - col1 + 20 DIV col0 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-3778
SELECT + + cor0.col1 * - col1 + 20 / col0 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - - 89 FROM tab0 AS cor0
----
89
89
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT col1 + + col2 DIV - 54 AS col0 FROM tab0 AS cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-3780
SELECT col1 + + col2 / - 54 AS col0 FROM tab0 AS cor0
----
86
90
97

query I rowsort
SELECT + + col2 + - col2 * col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - - cor0.col2 AS col0 FROM tab2, tab1, tab2 cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL - col0 * - 26 AS col0 FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT - col2 + + 94 * col2 FROM tab0 AS cor0
----
3069
7626
93

query I rowsort
SELECT ALL - + 63 * + 33 - - col1 AS col0 FROM tab0 AS cor0
----
-1982
-1988
-1993

query I rowsort
SELECT DISTINCT + col0 * 19 * + col2 + col0 * 83 FROM tab2 AS cor0
----
4172
45006
63595

query I rowsort
SELECT + tab1.col1 * + col2 + col2 * col2 - - 20 FROM tab1
----
10484
3839
4340

query I rowsort
SELECT ALL col2 * - col0 - - col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT col0 * ( - col1 * - col2 ) AS col2 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-3790
SELECT ALL + 32 DIV 31 FROM tab2, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-3790
SELECT ALL + 32 / 31 FROM tab2, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( + col2 ) col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 * - 58 + col1 AS col0 FROM tab0 AS cor0
----
-1828
-4665
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-3793
SELECT DISTINCT + + col0 DIV + col1 + - col2 FROM tab1 AS cor0
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-3793
SELECT DISTINCT + + col0 / + col1 + - col2 FROM tab1 AS cor0
----
-51
-54
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3794
SELECT col0 * - col0 + col0 DIV col0 FROM tab2 AS cor0
----
-48
-6083
-6240

skipif mysql # not compatible
query I rowsort label-3794
SELECT col0 * - col0 + col0 / col0 FROM tab2 AS cor0
----
-48
-6083
-6240

query I rowsort
SELECT ALL ( col2 ) * - cor0.col0 + + ( col2 ) AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3796
SELECT CAST( - col2 AS SIGNED ) + - col0 * col2 col1 FROM tab2 AS cor0
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3796
SELECT CAST ( - col2 AS INTEGER ) + - col0 * col2 col1 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-3797
SELECT + col1 DIV 12 FROM tab0 AS cor0
----
7
7
8

skipif mysql # not compatible
query I rowsort label-3797
SELECT + col1 / 12 FROM tab0 AS cor0
----
7
7
8

query I rowsort
SELECT ALL + tab0.col1 FROM tab0, tab1 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL col0 * col1 * 18 FROM tab2
----
24174
3906
82836

query I rowsort
SELECT + 48 * + col0 FROM tab0 AS cor0
----
1152
1680
4272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 60 col2 FROM tab2 AS cor0
----
-60
-60
-60

query I rowsort
SELECT + 63 AS col0 FROM tab1 cor0
----
63
63
63

query I rowsort
SELECT + + col1 + + col1 AS col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT 26 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
26

query I rowsort
SELECT - col0 + 67 FROM tab2 AS cor0
----
-11
-12
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3806
SELECT - col2 DIV 40 + + col0 - col1 FROM tab1 AS cor0
----
-24
53
65

skipif mysql # not compatible
query I rowsort label-3806
SELECT - col2 / 40 + + col0 - col1 FROM tab1 AS cor0
----
-24
53
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3807
SELECT - - col1 * CAST( - col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-3807
SELECT - - col1 * CAST ( - col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col2 * - col1 + - col0 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-3809
SELECT ALL + col0 * col2 - + col2 * col2 DIV 43 AS col0 FROM tab2 AS cor0
----
173
2013
2969

skipif mysql # not compatible
query I rowsort label-3809
SELECT ALL + col0 * col2 - + col2 * col2 / 43 AS col0 FROM tab2 AS cor0
----
173
2013
2969

onlyif mysql # use DIV operator for integer division
query I rowsort label-3810
SELECT ALL + cor0.col2 * 70 DIV col1 AS col0 FROM tab1 AS cor0
----
145
399
516

skipif mysql # not compatible
query I rowsort label-3810
SELECT ALL + cor0.col2 * 70 / col1 AS col0 FROM tab1 AS cor0
----
145
399
516

query I rowsort
SELECT DISTINCT col0 + 58 * col2 FROM tab0 cor0
----
1938
4845
93

skipif mysql # not compatible
query I rowsort
SELECT col1 * + CAST ( col1 * col2 + - col2 AS REAL ) AS col0 FROM tab1 cor0
----
14976
35100
5130

query I rowsort
SELECT DISTINCT + cor0.col1 + + col0 - col1 AS col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL + - cor0.col1 * - 7 FROM tab0 AS cor0
----
602
637
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-3815
SELECT col0 DIV 62 AS col1 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3815
SELECT col0 / 62 AS col1 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT ALL ( cor0.col2 ) * col2 * col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT ( col0 ) * + col1 - + col2 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3818
SELECT DISTINCT CAST( - col2 AS SIGNED ) * col0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-3818
SELECT DISTINCT CAST ( - col2 AS INTEGER ) * col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + col1 - + 64 * - tab1.col2 FROM tab1
----
3482
3658
6157

query I rowsort
SELECT - col2 - - 67 FROM tab1
----
-29
10
13

query I rowsort
SELECT - 6 + cor0.col2 AS col0 FROM tab0 cor0
----
-5
27
76

query I rowsort
SELECT DISTINCT - 14 + col2 AS col1 FROM tab2 AS cor0
----
12
13
24

query I rowsort
SELECT ALL + - col1 * - col2 + col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL 30 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT ALL - - 22 + col0 + + 82 FROM tab1 AS cor0
----
107
168
184

query I rowsort
SELECT DISTINCT cor0.col2 * + col2 * + col1 FROM tab0 AS cor0
----
611884
93654
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 84 col0 FROM tab2
----
84
84
84

query I rowsort
SELECT ALL - tab0.col0 * - col1 * 10 AS col2 FROM tab0
----
20640
33950
80990

query I rowsort
SELECT - 60 * col2 + col0 AS col0 FROM tab1
----
-3237
-3356
-5680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab0 cor1
----
81 values hashing to 1654646feeae82f39d2f564fe4ea26c2

query I rowsort
SELECT ALL tab1.col1 AS col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3833
SELECT ALL - CAST( col0 AS SIGNED ) AS col1 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3833
SELECT ALL - CAST ( col0 AS INTEGER ) AS col1 FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3834
SELECT ALL - col1 + 48 DIV - col1 + - col1 FROM tab2 cor0
----
-118
-36
-63

skipif mysql # not compatible
query I rowsort label-3834
SELECT ALL - col1 + 48 / - col1 + - col1 FROM tab2 cor0
----
-118
-36
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 39 * - col2 col1 FROM tab2 AS cor0
----
1014
1053
1482

onlyif mysql # use DIV operator for integer division
query I rowsort label-3836
SELECT ALL - 43 DIV col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-3836
SELECT ALL - 43 / col1 FROM tab1 AS cor0
----
-1
-3
-4

query I rowsort
SELECT DISTINCT + col1 + 45 AS col0 FROM tab2 AS cor0
----
104
62
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3838
SELECT ALL + ( - col1 ) * col0 + 44 DIV col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-3838
SELECT ALL + ( - col1 ) * col0 + 44 / col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - + col1 * - col1 + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT + 45 + - col0 AS col1 FROM tab2 AS cor0
----
-33
-34
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3841
SELECT col1 * col1 / + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3841
SELECT col1 * col1 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + ( + col1 ) * - 31 FROM tab2 cor0
----
1829
527
961

query I rowsort
SELECT ALL + col2 + col0 + col0 FROM tab2 cor0
----
182
196
41

query I rowsort
SELECT ALL col0 * 23 AS col2 FROM tab1
----
1472
1840
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-3845
SELECT DISTINCT col0 DIV ( + col2 ) AS col1 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3845
SELECT DISTINCT col0 / ( + col2 ) AS col1 FROM tab1 AS cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3846
SELECT - col2 + CAST( NULL AS SIGNED ) / + col1 + - cor0.col0 * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3846
SELECT - col2 + CAST ( NULL AS INTEGER ) / + col1 + - cor0.col0 * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * 49 AS col2 FROM tab2
----
-1519
-2891
-833

query I rowsort
SELECT DISTINCT - 34 FROM tab2, tab1 AS cor0
----
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * ( + col0 ) + + col2 * col0 col0 FROM tab2 AS cor0
----
-3239
-4056
140

query I rowsort
SELECT + cor0.col1 + 6 AS col2 FROM tab0 AS cor0
----
103
92
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3851
SELECT ALL - col0 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3851
SELECT ALL - col0 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * - ( col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + col2 * - ( + 33 ) + col0 FROM tab2 AS cor0
----
-1175
-780
-884

query I rowsort
SELECT DISTINCT col1 - ( col1 ) * col0 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3855
SELECT ALL + col2 DIV 43 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3855
SELECT ALL + col2 / 43 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT col2 + col2 * 3 AS col0 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT DISTINCT - 58 * + col1 AS col0 FROM tab2 AS cor0
----
-1798
-3422
-986

query I rowsort
SELECT - ( - col1 ) * col2 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col2 + - 33 AS col2 FROM tab2 AS cor0
----
-6
-7
5

query I rowsort
SELECT + 91 * col0 AS col1 FROM tab1 AS cor0
----
273
5824
7280

query I rowsort
SELECT col0 + + 56 FROM tab2 cor0
----
134
135
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3862
SELECT DISTINCT CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3862
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3863
SELECT ALL + 62 DIV col0 FROM tab1 AS cor0
----
0
0
20

skipif mysql # not compatible
query I rowsort label-3863
SELECT ALL + 62 / col0 FROM tab1 AS cor0
----
0
0
20

query I rowsort
SELECT + + col2 + + 36 * col1 AS col0 FROM tab1 AS cor0
----
417
564
990

query I rowsort
SELECT + ( - col1 ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) * col1 + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + col2 - + 70 FROM tab2 AS cor0
----
-32
-43
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 42 * + col2 - - col0 col2 FROM tab1 AS cor0
----
2271
2458
4112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3869
SELECT ALL + CAST( + 76 AS SIGNED ) + col2 FROM tab2 AS cor0
----
102
103
114

skipif mysql # not compatible
query I rowsort label-3869
SELECT ALL + CAST ( + 76 AS INTEGER ) + col2 FROM tab2 AS cor0
----
102
103
114

query I rowsort
SELECT + col1 - + col1 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT tab2.col0 + 18 AS col1 FROM tab2
----
25
96
97

query I rowsort
SELECT col2 * 83 * cor0.col0 AS col1 FROM tab0 cor0
----
2905
605734
65736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3873
SELECT + CAST( - ( - col0 ) AS SIGNED ) + CAST( NULL AS SIGNED ) / + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3873
SELECT + CAST ( - ( - col0 ) AS INTEGER ) + CAST ( NULL AS INTEGER ) / + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 53 FROM tab0, tab0 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
17
31
59

query I rowsort
SELECT ALL + col1 + + col2 * + col0 AS col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3877
SELECT DISTINCT + col1 + col2 DIV - col1 AS col0 FROM tab2 cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-3877
SELECT DISTINCT + col1 + col2 / - col1 AS col0 FROM tab2 cor0
----
15
31
59

query I rowsort
SELECT + - ( col1 ) * + col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - + 91 + col2 * - cor0.col0 FROM tab0 AS cor0
----
-126
-7389
-883

query I rowsort
SELECT ALL col1 * - 95 FROM tab2
----
-1615
-2945
-5605

query I rowsort
SELECT - 7 + + col1 * - col1 AS col0 FROM tab0 AS cor0
----
-7403
-8288
-9416

onlyif mysql # use DIV operator for integer division
query I rowsort label-3882
SELECT + col0 + col0 DIV + col0 AS col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3882
SELECT + col0 + col0 / + col0 AS col0 FROM tab1
----
4
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 9 * col2 col1 FROM tab1
----
486
513
864

query I rowsort
SELECT + + cor0.col1 + col2 * col1 * col1 AS col2 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT DISTINCT + col2 * 56 AS col1 FROM tab2
----
1456
1512
2128

query I rowsort
SELECT ALL col1 + + tab1.col2 AS col0 FROM tab1
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 2 col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT - + col0 * 49 + col0 FROM tab0 AS cor0
----
-1152
-1680
-4272

onlyif mysql # use DIV operator for integer division
query I rowsort label-3889
SELECT + + col2 DIV col0 + + col0 DIV col1 FROM tab2 AS cor0
----
1
3
4

skipif mysql # not compatible
query I rowsort label-3889
SELECT + + col2 / col0 + + col0 / col1 FROM tab2 AS cor0
----
1
3
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3890
SELECT DISTINCT 49 + - col1 DIV tab1.col1 FROM tab1
----
48

skipif mysql # not compatible
query I rowsort label-3890
SELECT DISTINCT 49 + - col1 / tab1.col1 FROM tab1
----
48

query I rowsort
SELECT - col1 + col2 * col1 FROM tab0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - 87 + col2 AS col1 FROM tab1
----
-30
-33
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3893
SELECT + tab0.col2 * + col0 * - col0 + col0 DIV col0 + - ( col0 + col1 ) col2 FROM tab0
----
-1356
-19117
-649701

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3893
SELECT + tab0.col2 * + col0 * - col0 + col0 / col0 + - ( col0 + col1 ) col2 FROM tab0
----
-1356
-19117
-649701

query I rowsort
SELECT ( col2 ) * ( col1 ) * - col1 AS col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT + + col0 + + col2 * + 41 + col2 AS col2 FROM tab0 AS cor0
----
1410
3533
77

query I rowsort
SELECT DISTINCT + + col0 * - 66 + 38 AS col1 FROM tab1 AS cor0
----
-160
-4186
-5242

query I rowsort
SELECT - col1 + + cor0.col2 * 40 + cor0.col0 FROM tab2 AS cor0
----
1056
1059
1582

query I rowsort
SELECT DISTINCT col1 * 26 * col1 FROM tab1
----
17576
2600
4394

query I rowsort
SELECT ALL - col0 + + col2 * ( - col2 ) FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3900
SELECT ALL + cor0.col0 * CAST( - col0 AS SIGNED ) col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3900
SELECT ALL + cor0.col0 * CAST ( - col0 AS INTEGER ) col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col0 * 84 + - col2 * col2 * 88 + col2 AS col1 FROM tab2 AS cor0
----
-133670
-64713
-66014

query I rowsort
SELECT DISTINCT col1 + col0 * col0 AS col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT cor0.col1 * 59 - + col1 * + col1 AS col1 FROM tab1 AS cor0
----
490
598
858

query I rowsort
SELECT ALL + - col2 * 83 + + col2 + col2 AS col0 FROM tab1 AS cor0
----
-4374
-4617
-7776

query I rowsort
SELECT col1 + + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT col1 * col1 * 93 - col1 AS col2 FROM tab2 AS cor0
----
26860
323674
89342

query I rowsort
SELECT col2 * ( ( - col0 ) * - col1 ) AS col1 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-3908
SELECT ALL tab0.col0 DIV tab0.col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 1637c01c1103272666b1cc3d663ead40

skipif mysql # not compatible
query I rowsort label-3908
SELECT ALL tab0.col0 / tab0.col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 1637c01c1103272666b1cc3d663ead40

onlyif mysql # use DIV operator for integer division
query I rowsort label-3909
SELECT + 1 * col0 - + col2 DIV + CAST( - col2 * - col0 + col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3909
SELECT + 1 * col0 - + col2 / + CAST ( - col2 * - col0 + col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 11 + col1 * - col0 FROM tab0 AS cor0
----
-2053
-3384
-8088

query I rowsort
SELECT ALL - - col0 * col2 * + col1 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col2 - - 19 * 72 AS col2 FROM tab0
----
1369
1401
1450

query I rowsort
SELECT - col2 - tab1.col2 FROM tab1
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-3914
SELECT - col2 DIV + 86 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3914
SELECT - col2 / + 86 FROM tab2
----
0
0
0

query I rowsort
SELECT + 23 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT ALL - col1 * col0 * - tab2.col1 - + col1 * col2 FROM tab2
----
22185
269984
5890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3917
SELECT - CAST( 55 AS SIGNED ) FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

skipif mysql # not compatible
query I rowsort label-3917
SELECT - CAST ( 55 AS INTEGER ) FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 77 col2 FROM tab1 AS cor0
----
-77
-77
-77

query I rowsort
SELECT DISTINCT + + col1 * - col2 + - col0 AS col0 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT + 66 * 44 FROM tab0
----
2904
2904
2904

onlyif mysql # use DIV operator for integer division
query I rowsort label-3921
SELECT DISTINCT col0 DIV 50 AS col0 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-3921
SELECT DISTINCT col0 / 50 AS col0 FROM tab2
----
0
1

query I rowsort
SELECT + 37 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT - 11 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - col1 + col1 AS REAL ) col1 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3925
SELECT CAST( col1 + col0 AS SIGNED ) AS col2 FROM tab0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-3925
SELECT CAST ( col1 + col0 AS INTEGER ) AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT ( col0 ) + - col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT 61 AS col1 FROM tab0 AS cor0
----
61
61
61

query I rowsort
SELECT col0 * col0 + col1 * + col2 FROM tab1 AS cor0
----
1413
4666
7648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 0 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT - 88 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to eb8cbefa7d831e1a0183e919e2caef32

query I rowsort
SELECT - 78 * tab0.col0 AS col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to e60fc34518a0ae53f07f2224a0e2af55

query I rowsort
SELECT col2 * col1 + ( col1 ) FROM tab1
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + cor1.col0 ) col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + 15 * + tab1.col0 - ( col2 + - tab1.col1 ) * 28 AS col0 FROM tab1
----
-1124
-356
-739

query I rowsort
SELECT col0 * - col0 - col1 FROM tab0
----
-1322
-662
-8012

query I rowsort
SELECT + 21 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( + col0 ) col2 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL ( + col2 ) * - ( - col2 ) AS col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT ALL + col1 * 29 + cor0.col0 AS col1 FROM tab0 AS cor0
----
2518
2728
2848

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3940
SELECT DISTINCT - col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3940
SELECT DISTINCT - col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to dd5ce24448edb4b3ab62c251475d6548

query I rowsort
SELECT ALL - col0 * col2 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - - cor0.col2 * + cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col1 * - col1 + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - col1 * ( col0 ) + cor0.col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT - col0 + ( + col1 ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - + col1 * 61 + col2 FROM tab0 cor0
----
-5213
-5469
-5916

query I rowsort
SELECT ALL - - col0 + col0 * cor0.col1 * + col0 AS col0 FROM tab0 AS cor0
----
118860
49560
720900

query I rowsort
SELECT - 72 * + col1 AS col2 FROM tab2 cor0
----
-1224
-2232
-4248

query I rowsort
SELECT + + 95 AS col1 FROM tab2 AS cor0
----
95
95
95

query I rowsort
SELECT ALL - - cor0.col1 + ( cor0.col1 ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT + 91 * - 96 + - col1 AS col2 FROM tab1 AS cor0
----
-8746
-8749
-8762

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 - col2 col0 FROM tab2 cor0
----
1406
650
702

query I rowsort
SELECT ALL + col1 + col2 + col2 FROM tab0 AS cor0
----
152
255
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3955
SELECT ALL col1 * - col1 * cor0.col2 - CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3955
SELECT ALL col1 * - col1 * cor0.col2 - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 * 20 FROM tab0 AS cor0
----
-1780
-480
-700

query I rowsort
SELECT ALL + + ( col2 ) * - cor0.col2 - + col1 AS col2 FROM tab2 cor0
----
-1461
-735
-760

query I rowsort
SELECT + ( 51 ) + col1 FROM tab1 AS cor0
----
61
64
77

query I rowsort
SELECT DISTINCT + cor0.col0 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + col2 + col2 * 0 AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - ( + col0 ) * + 80 FROM tab2 AS cor0
----
-560
-6240
-6320

query I rowsort
SELECT ALL cor0.col1 + + 90 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 339e89cec952b702712e9f447d16f6f5

query I rowsort
SELECT ALL + - 34 * col0 FROM tab0 AS cor0
----
-1190
-3026
-816

query I rowsort
SELECT + 61 * - 88 * + col2 FROM tab1 AS cor0
----
-289872
-305976
-515328

onlyif mysql # use DIV operator for integer division
query I rowsort label-3965
SELECT 68 DIV col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3965
SELECT 68 / col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT - + 35 * - col2 AS col1 FROM tab1 AS cor0
----
1890
1995
3360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 84 * col2 col2 FROM tab2 AS cor0
----
-2184
-2268
-3192

onlyif mysql # use DIV operator for integer division
query I rowsort label-3968
SELECT - CAST( col1 AS SIGNED ) + + col0 * col2 DIV - col1 col2 FROM tab2 AS cor0
----
-193
-37
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3968
SELECT - CAST ( col1 AS INTEGER ) + + col0 * col2 / - col1 col2 FROM tab2 AS cor0
----
-193
-37
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( + col0 ) + + col2 * - col1 * + col2 col2 FROM tab2 AS cor0
----
-22606
-24627
-39962

query I rowsort
SELECT + col2 * + col0 * col1 AS col2 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT ALL ( col0 * - ( - 91 ) ) + - col1 * 91 AS col1 FROM tab1
----
-2093
4914
6097

query I rowsort
SELECT col0 * - 33 AS col0 FROM tab0 AS cor0
----
-1155
-2937
-792

query I rowsort
SELECT ( col2 ) + col2 AS col1 FROM tab0
----
164
2
66

query I rowsort
SELECT + 0 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - col2 * - tab0.col0 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + col2 * - col0 * 98 + col1 AS col2 FROM tab0 AS cor0
----
-3333
-715113
-77530

query I rowsort
SELECT DISTINCT + 35 AS col0 FROM tab0 cor0 CROSS JOIN tab1 cor1
----
35

query I rowsort
SELECT ALL 56 + + col2 + + col1 AS col2 FROM tab0
----
154
175
229

query I rowsort
SELECT ALL cor0.col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3980
SELECT DISTINCT - + col1 * CAST( NULL AS SIGNED ) * col0 + - col1 + cor0.col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3980
SELECT DISTINCT - + col1 * CAST ( NULL AS INTEGER ) * col0 + - col1 + cor0.col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 + ( - col0 ) FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3982
SELECT + + col0 + + CAST( NULL AS DECIMAL ) / + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3982
SELECT + + col0 + + CAST ( NULL AS REAL ) / + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * 89 + 5 AS col1 FROM tab0 cor0
----
-2932
-7293
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 * + col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 + - 53 AS col0 FROM tab0 AS cor0
----
33
38
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 + cor0.col2 col1 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT + col2 * + ( - col0 * + col2 ) FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT col1 * 10 AS col2 FROM tab2 AS cor0
----
170
310
590

query I rowsort
SELECT ALL + cor0.col0 * col2 + - 6 AS col2 FROM tab0 cor0
----
29
7292
786

query I rowsort
SELECT 27 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3991
SELECT + CAST( NULL AS DECIMAL ) - - col2 * col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3991
SELECT + CAST ( NULL AS REAL ) - - col2 * col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * + col1 + col0 AS col1 FROM tab1 cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3994
SELECT + - cor0.col1 DIV ( + col2 ) AS col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-3994
SELECT + - cor0.col1 / ( + col2 ) AS col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT ALL col1 * + col2 * + col0 AS col0 FROM tab1 cor0
----
36480
4212
99840

query I rowsort
SELECT ALL + - col0 * - cor0.col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * col2 + col1 col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + - 81 * col2 AS col2 FROM tab2 AS cor0
----
-2106
-2187
-3078

query I rowsort
SELECT - col1 * 92 - ( col2 + col1 ) FROM tab1 AS cor0
----
-1305
-2472
-987

query I rowsort
SELECT + + col2 * col2 - 15 FROM tab0 AS cor0
----
-14
1074
6709

query I rowsort
SELECT col0 * ( 13 ) + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7708
9438
9864

query I rowsort
SELECT DISTINCT - tab2.col1 + ( cor0.col1 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 17894375c29631326d468821c0c61127

onlyif mysql # use DIV operator for integer division
query I rowsort label-4003
SELECT + 65 * col0 DIV + col1 FROM tab0
----
18
23
63

skipif mysql # not compatible
query I rowsort label-4003
SELECT + 65 * col0 / + col1 FROM tab0
----
18
23
63

query I rowsort
SELECT + + 85 * cor0.col2 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7451b903722942eecea03711573ee144

query I rowsort
SELECT DISTINCT + tab1.col2 + tab1.col1 AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT + + 86 * cor0.col2 FROM tab1 AS cor0
----
4644
4902
8256

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 42e69ecdafb3c81046bc5cb4c98b1666

query I rowsort
SELECT 96 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT 64 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL col2 * col1 + ( col1 ) FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL ( col0 ) * col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - 44 FROM tab1 cor0
----
-44

query I rowsort
SELECT + + ( + col2 ) * - 73 FROM tab0 AS cor0
----
-2409
-5986
-73

query I rowsort
SELECT + 22 + col1 FROM tab1 AS cor0
----
32
35
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + col0 * col0 + - 47 FROM tab2 AS cor0
----
2
6037
6194

onlyif mysql # use DIV operator for integer division
query I rowsort label-4017
SELECT DISTINCT - 24 DIV + col2 + col1 AS col0 FROM tab0 AS cor0
----
73
86
91

skipif mysql # not compatible
query I rowsort label-4017
SELECT DISTINCT - 24 / + col2 + col1 AS col0 FROM tab0 AS cor0
----
73
86
91

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 FROM tab1 cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4019
SELECT col2 + cor0.col2 DIV col2 + col2 FROM tab1 AS cor0
----
109
115
193

skipif mysql # not compatible
query I rowsort label-4019
SELECT col2 + cor0.col2 / col2 + col2 FROM tab1 AS cor0
----
109
115
193

query I rowsort
SELECT - col0 + - ( ( + col2 ) + 39 * 42 ) FROM tab0 cor0
----
-1674
-1695
-1809

query I rowsort
SELECT col0 * - ( col0 ) + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4022
SELECT - + col0 + col0 DIV + cor0.col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-4022
SELECT - + col0 + col0 / + cor0.col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4023
SELECT ALL tab1.col2 DIV col0 AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4023
SELECT ALL tab1.col2 / col0 AS col2 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT + - cor0.col2 * - col0 + col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL + col2 + ( 37 ) + + col0 * col2 AS col1 FROM tab1
----
253
3742
7813

query I rowsort
SELECT DISTINCT + - 35 FROM tab1, tab1 AS cor0, tab0, tab0 AS cor1
----
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-4027
SELECT + col0 DIV - col0 + 93 * col1 * - CAST( + col2 * col1 AS SIGNED ) col2 FROM tab0
----
-22698325
-63150907
-875038

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4027
SELECT + col0 / - col0 + 93 * col1 * - CAST ( + col2 * col1 AS INTEGER ) col2 FROM tab0
----
-22698325
-63150907
-875038

query I rowsort
SELECT DISTINCT - - ( - 90 ) * col2 AS col2 FROM tab1 AS cor0
----
-4860
-5130
-8640

query I rowsort
SELECT ALL + + 95 * + col2 FROM tab1 cor0
----
5130
5415
9120

query I rowsort
SELECT + - col0 + + cor0.col1 * - col1 AS col2 FROM tab0 cor0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL - col2 + - 8 FROM tab0 AS cor0
----
-41
-9
-90

query I rowsort
SELECT - ( - 16 ) AS col1 FROM tab2 AS cor0
----
16
16
16

query I rowsort
SELECT ALL 88 * - col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-2229
-2345
-3327

query I rowsort
SELECT DISTINCT - ( - col2 ) + + col1 * 29 * + col0 FROM tab1 AS cor0
----
18617
2316
30256

query I rowsort
SELECT col0 * col2 * + 91 + - col2 * + tab0.col0 * col0 FROM tab0
----
14596
1960
53064

onlyif mysql # use DIV operator for integer division
query I rowsort label-4036
SELECT DISTINCT - col2 DIV tab1.col2 + + col2 AS col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-4036
SELECT DISTINCT - col2 / tab1.col2 + + col2 AS col2 FROM tab1
----
53
56
95

query I rowsort
SELECT - col2 + ( col0 ) FROM tab2
----
-20
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + 77 col2 FROM tab2
----
108
136
94

query I rowsort
SELECT DISTINCT + col0 + - ( + col1 ) AS col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT col2 + - col1 * 22 AS col1 FROM tab2
----
-1272
-336
-655

query I rowsort
SELECT + col1 + 81 * - col0 * ( 46 ) FROM tab0
----
-130313
-331523
-89338

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4042
SELECT DISTINCT - + CAST( NULL AS SIGNED ) + col0 * + cor0.col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4042
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) + col0 * + cor0.col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - 58 * cor0.col0 FROM tab0 cor0
----
1392
2030
5162

query I rowsort
SELECT + + ( col0 ) + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - ( - col1 ) + - cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + col1 * col0 * + col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4047
SELECT - CAST( NULL AS SIGNED ) + 29 * col0 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4047
SELECT - CAST ( NULL AS INTEGER ) + 29 * col0 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 85 * - col2 * cor0.col2 FROM tab0 AS cor0
----
571540
85
92565

query I rowsort
SELECT DISTINCT - 56 * ( - col2 * + 26 ) + col0 AS col1 FROM tab0 AS cor0
----
119481
1491
48072

query I rowsort
SELECT + + cor0.col2 * + col2 * + col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT DISTINCT ( + col2 ) AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT cor0.col0 * + 60 AS col2 FROM tab1 AS cor0
----
180
3840
4800

query I rowsort
SELECT 15 * cor0.col2 AS col2 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT ALL + + ( - cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + col0 * - col1 + - tab2.col0 FROM tab2
----
-1422
-224
-4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 - col1 * col1 col2 FROM tab1
----
-157
-265
-730

query I rowsort
SELECT DISTINCT - 72 + 52 AS col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
-20

query I rowsort
SELECT ALL + cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT cor0.col0 - col1 AS col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT 72 * + col2 FROM tab0
----
2376
5904
72

query I rowsort
SELECT DISTINCT col0 + 24 * + col1 - col0 FROM tab1 AS cor0
----
240
312
624

query I rowsort
SELECT DISTINCT - cor0.col1 - 94 FROM tab0 AS cor0
----
-180
-185
-191

query I rowsort
SELECT + tab1.col0 * 53 FROM tab1
----
159
3392
4240

query I rowsort
SELECT col0 + col0 * col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT col0 + 83 AS col0 FROM tab1 AS cor0
----
147
163
86

query I rowsort
SELECT DISTINCT col2 + - ( + ( + col2 ) ) FROM tab2 cor0
----
0

query I rowsort
SELECT 51 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT + - cor0.col0 - + col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT + col1 - col1 * col1 * col1 AS col0 FROM tab0 AS cor0
----
-635970
-753480
-912576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * col2 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - - 37 + col0 + + 77 FROM tab2 cor0
----
121
192
193

query I rowsort
SELECT + + 59 + - col0 + col2 * col2 AS col2 FROM tab0 AS cor0
----
1124
25
6694

query I rowsort
SELECT + col2 * - col0 + + col1 + - col0 * col2 FROM tab2 cor0
----
-347
-3997
-5987

query I rowsort
SELECT - col1 * + col0 * col0 AS col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 13 col0 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT 79 + - col1 AS col1 FROM tab1 AS cor0
----
53
66
69

query I rowsort
SELECT - col2 + tab1.col1 * + col2 + + tab1.col1 * + 74 FROM tab1
----
1253
2114
3274

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 + - col2 col0 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT ALL - - 85 FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT - col0 + - cor0.col1 + - cor0.col0 * - col2 AS col0 FROM tab2 cor0
----
151
1891
2906

query I rowsort
SELECT - - col0 + col1 * cor0.col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - cor0.col2 * + 4 * - col1 AS col2 FROM tab1 AS cor0
----
2280
4992
5616

query I rowsort
SELECT ALL col0 * tab0.col0 * 12 FROM tab0
----
14700
6912
95052

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4084
SELECT DISTINCT + CAST( - col1 AS SIGNED ) + - cor0.col2 col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4084
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) + - cor0.col2 col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4085
SELECT col1 * col1 + - col2 DIV - 6 FROM tab0 AS cor0
----
7401
8294
9409

skipif mysql # not compatible
query I rowsort label-4085
SELECT col1 * col1 + - col2 / - 6 FROM tab0 AS cor0
----
7401
8294
9409

query I rowsort
SELECT + + 31 - 25 AS col1 FROM tab0 AS cor0
----
6
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4087
SELECT ALL + 79 DIV - 26 FROM tab1 AS cor0
----
-3
-3
-3

skipif mysql # not compatible
query I rowsort label-4087
SELECT ALL + 79 / - 26 FROM tab1 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT + 71 AS col2 FROM tab1, tab0 AS cor0
----
71

query I rowsort
SELECT DISTINCT + col0 * col1 + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT 87 - col1 * col0 FROM tab0 AS cor0
----
-1977
-3308
-8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 3 * - cor0.col1 col1 FROM tab1, tab1 cor0
----
-30
-39
-78

query I rowsort
SELECT DISTINCT tab0.col0 + + col2 + + col1 * - 24 FROM tab0
----
-2007
-2013
-2292

query I rowsort
SELECT DISTINCT - 87 * - col1 + - col0 FROM tab0
----
7458
7828
8404

query I rowsort
SELECT DISTINCT ( col2 ) * col0 * - col0 + 67 AS col2 FROM tab0
----
-1158
-18941
-649455

query I rowsort
SELECT DISTINCT - 30 * - 50 + col2 FROM tab2
----
1526
1527
1538

query I rowsort
SELECT + 86 * - cor0.col1 + col2 + 30 AS col2 FROM tab1 AS cor0
----
-2152
-773
-992

query I rowsort
SELECT + 73 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( - col1 AS REAL ) + + col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - cor0.col0 * col0 + + col1 + + col2 * - ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-438
1293
179

query I rowsort
SELECT ALL + 9 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4101
SELECT DISTINCT - col2 DIV + 54 AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4101
SELECT DISTINCT - col2 / + 54 AS col0 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 + - col0 col2 FROM tab0
----
2
62
62

query I rowsort
SELECT + + 3 FROM tab0, tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 39 col2 FROM tab0, tab2 AS cor0
----
39

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
3645 values hashing to c3f17e238f07c9d20c4ee001084f26c7

query I rowsort
SELECT + col1 + - col1 * + ( - 79 ) * col2 FROM tab1
----
110942
45040
98605

query I rowsort
SELECT + col2 * col0 * col0 + + 63 * col0 * - 88 AS col0 FROM tab1 AS cor0
----
-121344
-16146
170880

query I rowsort
SELECT + 7 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT - col0 + + col0 - + col2 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT 49 * - cor0.col2 - + 87 FROM tab0 AS cor0
----
-136
-1704
-4105

query I rowsort
SELECT - col2 + - col2 + - col0 FROM tab1 AS cor0
----
-111
-178
-272

query I rowsort
SELECT 2 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT 48 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT ALL - tab2.col0 AS col1 FROM tab2, tab0, tab2 cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ( + tab0.col1 ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + col1 col1 FROM tab2 AS cor0
----
-21
33
4

query IIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 WHERE NOT ( NULL ) NOT IN ( cor0.col2 * cor0.col2 )
----

query I rowsort
SELECT DISTINCT - 82 * + 27 AS col0 FROM tab0, tab0 AS cor0
----
-2214

query I rowsort
SELECT DISTINCT ( 31 ) FROM tab2, tab2 AS cor0
----
31

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab2, tab0 AS cor0, tab1 cor1, tab1 cor2
----
-54
-57
-96

query I rowsort
SELECT 27 * cor0.col0 FROM tab0 AS cor0
----
2403
648
945

query I rowsort
SELECT - + 64 AS col0 FROM tab2 AS cor0
----
-64
-64
-64

query I rowsort
SELECT DISTINCT + col0 + col1 + + col1 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT DISTINCT + 82 * 36 * col0 FROM tab0 AS cor0
----
103320
262728
70848

query I rowsort
SELECT - ( 7 ) AS col1 FROM tab2 AS cor0
----
-7
-7
-7

query I rowsort
SELECT ALL - 51 - cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 9d09bc4faf34d5ab8cd000ddcf249376

query I rowsort
SELECT + col0 * - ( cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - + col2 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 * - col2 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4131
SELECT DISTINCT + col0 DIV 86 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4131
SELECT DISTINCT + col0 / 86 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL 33 + + col2 FROM tab1
----
129
87
90

query I rowsort
SELECT - col1 * - col1 + ( tab1.col2 ) * - col0 AS col2 FROM tab1
----
-3548
-7511
514

query I rowsort
SELECT col0 + - 55 FROM tab2
----
-48
23
24

query I rowsort
SELECT tab2.col2 - - col2 * ( + tab2.col1 ) AS col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT tab1.col2 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4137
SELECT ALL col1 DIV - ( ( col1 ) ) FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4137
SELECT ALL col1 / - ( ( col1 ) ) FROM tab1
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4138
SELECT ALL + CAST( NULL AS SIGNED ) + + 72 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4138
SELECT ALL + CAST ( NULL AS INTEGER ) + + 72 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - cor0.col2 * + col2 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT - cor0.col2 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col2 * + col1 - - col0 AS col1 FROM tab2
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-4142
SELECT ALL ( col2 ) * + col1 * col0 - col0 DIV col0 AS col1 FROM tab0
----
3394
664117
68111

skipif mysql # not compatible
query I rowsort label-4142
SELECT ALL ( col2 ) * + col1 * col0 - col0 / col0 AS col1 FROM tab0
----
3394
664117
68111

query I rowsort
SELECT DISTINCT 64 * col2 - col2 FROM tab1
----
3402
3591
6048

query I rowsort
SELECT tab0.col1 + + col2 * + col1 AS col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT col2 + 67 * col0 AS col0 FROM tab1 AS cor0
----
255
4345
5456

query I rowsort
SELECT cor0.col2 - + 55 AS col0 FROM tab2 cor0
----
-17
-28
-29

query I rowsort
SELECT - 76 * col1 + col1 AS col2 FROM tab0 AS cor0
----
-6450
-6825
-7275

query I rowsort
SELECT + + ( + col2 ) - + col0 AS col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col2 col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT ALL + col2 * col2 + col0 * - col2 * - col2 AS col0 FROM tab0 cor0
----
27225
36
605160

query I rowsort
SELECT ALL + 39 + col0 * + col2 * - col0 AS col0 FROM tab1 AS cor0
----
-233433
-447
-614361

query I rowsort
SELECT ALL - 42 - col1 AS col1 FROM tab2 AS cor0
----
-101
-59
-73

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT - 47 * col1 + + 94 FROM tab1 AS cor0
----
-1128
-376
-517

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col0 - 52 col1 FROM tab1 AS cor0
----
-43
4044
6348

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4156
SELECT ALL + + col1 + col2 * CAST( NULL AS SIGNED ) / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4156
SELECT ALL + + col1 + col2 * CAST ( NULL AS INTEGER ) / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT col2 + cor0.col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col0 + col1 AS col1 FROM tab0 cor0
----
2
62

query I rowsort
SELECT - ( - col1 ) * - 99 + + col2 AS col0 FROM tab1 AS cor0
----
-1191
-2520
-933

query I rowsort
SELECT + col1 + col2 * 96 FROM tab1 cor0
----
5210
5482
9229

query I rowsort
SELECT DISTINCT + 23 + - col0 FROM tab1
----
-41
-57
20

query I rowsort
SELECT + - 79 * cor0.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to ea7034a53082e9402edd943c9fdc7020

onlyif mysql # use DIV operator for integer division
query I rowsort label-4164
SELECT + col2 + - col1 DIV col1 + 97 AS col1 FROM tab2
----
122
123
134

skipif mysql # not compatible
query I rowsort label-4164
SELECT + col2 + - col1 / col1 + 97 AS col1 FROM tab2
----
122
123
134

query I rowsort
SELECT DISTINCT + 5 * + col2 AS col0 FROM tab0 cor0
----
165
410
5

query I rowsort
SELECT + col2 * + col1 + 16 FROM tab2 AS cor0
----
1550
662
853

query I rowsort
SELECT + ( col1 ) + + col0 * + col0 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT ALL cor0.col1 + + col0 * cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + 78 - col1 AS col0 FROM tab2
----
19
47
61

query I rowsort
SELECT + - col1 * - col2 - - 1 AS col1 FROM tab0 AS cor0
----
2839
7463
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 27 + + col2 col2 FROM tab0 cor0
----
109
28
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-4172
SELECT - + col2 DIV cor0.col0 + col2 AS col1 FROM tab2 AS cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-4172
SELECT - + col2 / cor0.col0 + col2 AS col1 FROM tab2 AS cor0
----
24
26
38

query I rowsort
SELECT - - col1 * + ( - 0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - tab1.col2 * cor0.col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c1a4ef6aeb30ab7efaf02c815e264690

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4175
SELECT DISTINCT + col1 + 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-4175
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) * cor0.col0 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT col1 + CAST ( - 63 AS REAL ) * col0 col0 FROM tab1 AS cor0
----
-163
-4022
-5027

query I rowsort
SELECT DISTINCT col1 - col2 * 44 AS col0 FROM tab0 AS cor0
----
-1366
-3517
53

query I rowsort
SELECT + col0 * + col1 + col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT 79 * + col0 + col1 AS col1 FROM tab1
----
263
5066
6333

query I rowsort
SELECT 23 * col1 + col2 + col0 AS col1 FROM tab2
----
1461
508
747

query I rowsort
SELECT ALL 77 + tab1.col0 FROM tab1
----
141
157
80

query I rowsort
SELECT ALL tab0.col0 * col1 + col0 * col2 FROM tab0
----
15397
2856
3430

query I rowsort
SELECT - 66 + tab1.col1 AS col0 FROM tab1
----
-40
-53
-56

query I rowsort
SELECT DISTINCT + col2 + + col1 + - col0 FROM tab1
----
29
3
77

query I rowsort
SELECT + 28 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 73 col1 FROM tab0 AS cor0
----
73

query I rowsort
SELECT ( - col1 ) * cor0.col0 * col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4188
SELECT ALL CAST( col0 AS SIGNED ) + + col0 + + 68 FROM tab2 AS cor0
----
224
226
82

skipif mysql # not compatible
query I rowsort label-4188
SELECT ALL CAST ( col0 AS INTEGER ) + + col0 + + 68 FROM tab2 AS cor0
----
224
226
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * 17 col1 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT ALL + col0 + - cor0.col2 * - col1 * - ( 93 ) + col0 AS col1 FROM tab1 AS cor0
----
-115904
-130566
-52882

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4191
SELECT CAST( NULL AS SIGNED ) * 64 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4191
SELECT CAST ( NULL AS INTEGER ) * 64 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + - 61 * - col1 AS col2 FROM tab2 AS cor0
----
1116
1898
3677

query I rowsort
SELECT + col1 * - col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT ALL - + ( + col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + + ( 97 ) * - col0 FROM tab1 AS cor0
----
-291
-6208
-7760

query I rowsort
SELECT DISTINCT + ( col2 ) + col0 * col1 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - col2 * - col1 * - col1 + - col2 FROM tab2
----
-11020
-25974
-90532

query I rowsort
SELECT DISTINCT col1 * - ( ( + col1 ) ) FROM tab1
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + + 54 AS col1 FROM tab1 AS cor0
----
54

query I rowsort
SELECT - 1 * + 37 FROM tab2
----
-37
-37
-37

query I rowsort
SELECT col2 * + col2 + col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL + + col0 + - col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 64 * col1 AS col2 FROM tab2 AS cor0
----
1088
1984
3776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4204
SELECT CAST( col1 AS SIGNED ) + - col0 FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-4204
SELECT CAST ( col1 AS INTEGER ) + - col0 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + 5 * col1 col2 FROM tab0 cor0
----
454
520
544

query I rowsort
SELECT + 65 + + 95 FROM tab0
----
160
160
160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 42 * 98 col1 FROM tab1
----
4116
4116
4116

query I rowsort
SELECT 86 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT col2 * 49 FROM tab2
----
1274
1323
1862

onlyif mysql # use DIV operator for integer division
query I rowsort label-4210
SELECT col0 DIV 18 FROM tab0
----
1
1
4

skipif mysql # not compatible
query I rowsort label-4210
SELECT col0 / 18 FROM tab0
----
1
1
4

query I rowsort
SELECT + col2 * - 70 FROM tab2
----
-1820
-1890
-2660

query I rowsort
SELECT ALL - col1 + + col1 * col2 FROM tab2
----
1475
629
806

query I rowsort
SELECT ALL + col1 + - 35 FROM tab2
----
-18
-4
24

query I rowsort
SELECT - col2 + 31 FROM tab0
----
-2
-51
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4215
SELECT CAST( 7 AS SIGNED ) FROM tab1, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

skipif mysql # not compatible
query I rowsort label-4215
SELECT CAST ( 7 AS INTEGER ) FROM tab1, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT DISTINCT col2 * tab0.col2 + col0 * + col0 AS col2 FROM tab0
----
1226
14645
1665

onlyif mysql # use DIV operator for integer division
query I rowsort label-4217
SELECT col2 * col2 DIV - col1 AS col0 FROM tab1
----
-112
-324
-708

skipif mysql # not compatible
query I rowsort label-4217
SELECT col2 * col2 / - col1 AS col0 FROM tab1
----
-112
-324
-708

query I rowsort
SELECT col0 + col1 * 78 * - col1 FROM tab1
----
-13102
-52725
-7736

query I rowsort
SELECT DISTINCT col0 + - ( - col2 ) * + col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4220
SELECT cor0.col1 * - CAST( + col0 AS SIGNED ) - - col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-4220
SELECT cor0.col1 * - CAST ( + col0 AS INTEGER ) - - col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + + col1 * - 49 FROM tab1 AS cor0
----
-1274
-490
-637

query I rowsort
SELECT DISTINCT - col0 * - 86 + col2 FROM tab1 AS cor0
----
312
5561
6976

query I rowsort
SELECT DISTINCT + col1 * + ( - col2 ) AS col2 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 5 - col0 * - col0 col2 FROM tab2 AS cor0
----
44
6079
6236

query I rowsort
SELECT - ( 10 ) + col1 AS col2 FROM tab1 cor0
----
0
16
3

query I rowsort
SELECT DISTINCT + 77 AS col1 FROM tab0 cor0
----
77

query I rowsort
SELECT + 75 + + col2 * col2 AS col2 FROM tab1 AS cor0
----
2991
3324
9291

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4228
SELECT CAST( NULL AS SIGNED ) / + col2 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4228
SELECT CAST ( NULL AS INTEGER ) / + col2 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4229
SELECT ALL - 80 DIV cor0.col2 + - col2 + ( ( col1 ) ) col2 FROM tab1 AS cor0
----
-29
-48
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4229
SELECT ALL - 80 / cor0.col2 + - col2 + ( ( col1 ) ) col2 FROM tab1 AS cor0
----
-29
-48
-83

query I rowsort
SELECT DISTINCT - ( - col1 ) + - col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + col1 * + 83 + + col0 + col0 FROM tab0 AS cor0
----
7186
7731
8121

onlyif mysql # use DIV operator for integer division
query I rowsort label-4232
SELECT - col2 * 75 DIV col0 FROM tab1
----
-1350
-66
-90

skipif mysql # not compatible
query I rowsort label-4232
SELECT - col2 * 75 / col0 FROM tab1
----
-1350
-66
-90

query I rowsort
SELECT col2 * cor0.col2 + cor0.col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT cor0.col1 + + 89 AS col0 FROM tab2 AS cor0
----
106
120
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-4235
SELECT DISTINCT - col0 DIV + col1 - - col2 FROM tab1 AS cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-4235
SELECT DISTINCT - col0 / + col1 - - col2 FROM tab1 AS cor0
----
51
54
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4236
SELECT DISTINCT col2 * cor0.col1 DIV + ( 31 ) AS col1 FROM tab1 AS cor0
----
18
40
45

skipif mysql # not compatible
query I rowsort label-4236
SELECT DISTINCT col2 * cor0.col1 / + ( 31 ) AS col1 FROM tab1 AS cor0
----
18
40
45

query I rowsort
SELECT ALL + 11 - + col2 * - 31 AS col1 FROM tab0 AS cor0
----
1034
2553
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 15 * + cor0.col2 col1 FROM tab1 AS cor0
----
-1440
-810
-855

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 39 col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query I rowsort
SELECT ( + cor0.col0 ) FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - cor0.col0 * - col1 * - 59 AS col2 FROM tab0 AS cor0
----
-121776
-200305
-477841

query I rowsort
SELECT ALL - col1 + cor0.col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + 23 + + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1271
1427
593

query I rowsort
SELECT - 63 + - tab1.col1 FROM tab1
----
-73
-76
-89

query I rowsort
SELECT ALL tab0.col0 FROM tab0, tab1 cor0, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT col2 + + col0 * cor0.col2 * col2 FROM tab1 AS cor0
----
207993
737376
8802

query I rowsort
SELECT ALL - 96 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1, tab1 AS cor2, tab1 cor3
----
243 values hashing to c29202883a4ff88a622bd7f05a35e059

query I rowsort
SELECT - col2 + + ( 45 ) * - col0 AS col2 FROM tab0 AS cor0
----
-1113
-1576
-4087

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4249
SELECT ALL + col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4249
SELECT ALL + col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4250
SELECT col0 * 57 DIV col2 AS col2 FROM tab0 AS cor0
----
1995
41
61

skipif mysql # not compatible
query I rowsort label-4250
SELECT col0 * 57 / col2 AS col2 FROM tab0 AS cor0
----
1995
41
61

query I rowsort
SELECT ALL + 12 AS col1 FROM tab0
----
12
12
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4252
SELECT + + col2 + + CAST( + 4 AS SIGNED ) FROM tab2 AS cor0
----
30
31
42

skipif mysql # not compatible
query I rowsort label-4252
SELECT + + col2 + + CAST ( + 4 AS INTEGER ) FROM tab2 AS cor0
----
30
31
42

query I rowsort
SELECT - 49 * col2 - col1 FROM tab1 AS cor0
----
-2672
-2803
-4717

onlyif mysql # use DIV operator for integer division
query I rowsort label-4254
SELECT DISTINCT 35 + col0 DIV - col1 AS col2 FROM tab0 cor0
----
35

skipif mysql # not compatible
query I rowsort label-4254
SELECT DISTINCT 35 + col0 / - col1 AS col2 FROM tab0 cor0
----
35

query I rowsort
SELECT ALL col2 * 31 - col2 FROM tab0 AS cor0
----
2460
30
990

query I rowsort
SELECT ALL - - 56 FROM tab1 AS cor0
----
56
56
56

query I rowsort
SELECT + 21 - + col2 AS col0 FROM tab0 AS cor0
----
-12
-61
20

query I rowsort
SELECT ALL ( + cor0.col1 ) FROM tab1, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT + + ( + ( + col0 - + col0 ) ) * - col1 * col1 + - col1 * 8 - col2 FROM tab2 AS cor0
----
-174
-275
-498

query I rowsort
SELECT ALL + col1 * + col1 AS col1 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4261
SELECT + cor0.col2 * + CAST( 94 AS SIGNED ) AS col2 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to c130acda07bba9f98c9880f227d5f242

skipif mysql # not compatible
query I rowsort label-4261
SELECT + cor0.col2 * + CAST ( 94 AS INTEGER ) AS col2 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to c130acda07bba9f98c9880f227d5f242

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4262
SELECT ALL - CAST( NULL AS SIGNED ) * - col0 col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4262
SELECT ALL - CAST ( NULL AS INTEGER ) * - col0 col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ( - ( col1 ) ) * - 38 AS col0 FROM tab2
----
1178
2242
646

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4264
SELECT CAST( - 77 AS SIGNED ) * col0 FROM tab1
----
-231
-4928
-6160

skipif mysql # not compatible
query I rowsort label-4264
SELECT CAST ( - 77 AS INTEGER ) * col0 FROM tab1
----
-231
-4928
-6160

query I rowsort
SELECT ALL 39 * 50 + cor0.col0 AS col2 FROM tab1, tab1 cor0, tab2 cor1
----
27 values hashing to 9f037d44ec584c16b265e8fa4b4e8519

query I rowsort
SELECT + 77 + tab2.col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 694bb0cc4138ef482de6a85dffc59c07

query I rowsort
SELECT ALL - 27 * col1 FROM tab0
----
-2322
-2457
-2619

query I rowsort
SELECT + - 99 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-3267
-8118
-99

query I rowsort
SELECT + col1 * - tab0.col0 + + col2 AS col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + + 11 AS col1 FROM tab0 AS cor0
----
11
11
11

query I rowsort
SELECT tab2.col1 - + col1 AS col1 FROM tab2 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - tab0.col1 * + col1 * col0 + col2 + - col2 AS col0 FROM tab0
----
-177504
-329315
-737009

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4274
SELECT DISTINCT + col2 * tab1.col2 DIV tab1.col0 FROM tab1
----
115
50
972

skipif mysql # not compatible
query I rowsort label-4274
SELECT DISTINCT + col2 * tab1.col2 / tab1.col0 FROM tab1
----
115
50
972

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col1 - col0 >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4276
SELECT ALL col2 * col0 DIV - col1 FROM tab2
----
-176
-34
-6

skipif mysql # not compatible
query I rowsort label-4276
SELECT ALL col2 * col0 / - col1 FROM tab2
----
-176
-34
-6

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( col0 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4278
SELECT - col1 * col0 DIV col2 AS col2 FROM tab0
----
-3395
-62
-98

skipif mysql # not compatible
query I rowsort label-4278
SELECT - col1 * col0 / col2 AS col2 FROM tab0
----
-3395
-62
-98

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( col1 * col0 * col0 + col2 * tab2.col1 )
----

query I rowsort
SELECT tab0.col2 * - col1 + + col1 * - col1 FROM tab0
----
-10234
-15743
-9506

query I rowsort
SELECT + 61 + + col0 FROM tab2
----
139
140
68

query I rowsort
SELECT DISTINCT 25 + col1 FROM tab0
----
111
116
122

onlyif mysql # use DIV operator for integer division
query I rowsort label-4283
SELECT DISTINCT col1 + col2 DIV - col1 + + col2 AS col1 FROM tab1
----
102
62
78

skipif mysql # not compatible
query I rowsort label-4283
SELECT DISTINCT col1 + col2 / - col1 + + col2 AS col1 FROM tab1
----
102
62
78

query I rowsort
SELECT ALL col2 + col1 * - col2 + + ( col0 ) AS col0 FROM tab1
----
-1072
-1347
-449

query I rowsort
SELECT DISTINCT col2 + - tab0.col1 + - col0 * 6 AS col0 FROM tab0
----
-197
-306
-543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4286
SELECT - col0 + + col0 / - CAST( col1 * - col1 AS SIGNED ) + + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4286
SELECT - col0 + + col0 / - CAST ( col1 * - col1 AS INTEGER ) + + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + + col2 + + cor0.col0 * col0 * cor0.col1 AS col2 FROM tab2 cor0
----
106056
1539
358904

query I rowsort
SELECT + 59 + col2 - - tab2.col1 FROM tab2
----
114
117
144

query I rowsort
SELECT 93 + - col1 AS col2 FROM tab1 AS cor0
----
67
80
83

query I rowsort
SELECT + col0 - - tab0.col2 * + col2 AS col2 FROM tab0
----
1113
36
6813

query I rowsort
SELECT - col0 + - col0 - - col1 / - col2 FROM tab1 WHERE - col2 <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4292
SELECT DISTINCT col1 DIV - col2 + col1 AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4292
SELECT DISTINCT col1 / - col2 + col1 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL col0 * col1 - + col1 * col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col0 + tab1.col2 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL + tab2.col1 + + col0 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT + tab1.col2 + - col2 FROM tab1
----
0

query I rowsort
SELECT col1 * + col1 + col0 AS col2 FROM tab2 WHERE NOT col2 IN ( + tab2.col2 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT - col1 IN ( col0 * - col2 * + col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT + col2 - - col1 AS col0 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4300
SELECT ALL col2 DIV + tab1.col2 + col2 * + col1 AS col0 FROM tab1
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-4300
SELECT ALL col2 / + tab1.col2 + col2 * + col1 AS col0 FROM tab1
----
1249
1405
571

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col1 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT col1 FROM tab1 WHERE NULL = NULL
----

query I rowsort
SELECT + col1 - col2 * col0 AS col2 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT col0 + + col2 * + col0 + col2 * + col1 FROM tab1
----
1569
4282
9008

query I rowsort
SELECT DISTINCT col2 + col2 * col1 + - col0 * - tab2.col1 AS col0 FROM tab2
----
1081
2027
6162

query I rowsort
SELECT + col1 * tab0.col1 * col1 AS col0 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT DISTINCT col0 + col0 AS col2 FROM tab0 WHERE NULL IN ( + tab0.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4308
SELECT DISTINCT - col2 * col1 DIV - col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4308
SELECT DISTINCT - col2 * col1 / - col1 FROM tab1
----
54
57
96

query I rowsort
SELECT tab0.col2 * col2 + col2 AS col2 FROM tab0 WHERE NOT - col1 - col1 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col0 + + col1 * col1 + col2 FROM tab2
----
3585
406
995

query I rowsort
SELECT col0 * col0 + - col1 FROM tab0
----
1128
490
7830

query I rowsort
SELECT ALL col1 * - col2 / col0 AS col0 FROM tab2 WHERE NULL = ( NULL )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col0 * + col0 * col2 + - col0 >= NULL
----

query I rowsort
SELECT ALL col1 + col1 * tab2.col1 AS col0 FROM tab2
----
306
3540
992

query I rowsort
SELECT ALL tab1.col0 * - tab1.col2 * col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT - tab2.col0 + - tab2.col2 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT + col2 * col0 + - col1 + col2 * col2 AS col1 FROM tab2
----
2645
4429
887

query I rowsort
SELECT DISTINCT + col2 + - col2 + col1 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col2 / tab2.col2 + col0 FROM tab2 WHERE NOT NULL IN ( col2 / col1 )
----

query I rowsort
SELECT ALL col2 * + tab1.col0 + col0 AS col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT + ( col0 ) * + col1 + 9 AS col1 FROM tab2
----
1352
226
4611

query I rowsort
SELECT ALL - col1 * ( - col1 ) - tab0.col0 FROM tab0
----
7372
8192
9374

query I rowsort
SELECT ALL + col2 + col2 + + col1 FROM tab2 cor0
----
111
85
93

query I rowsort
SELECT DISTINCT - col1 + + col2 + col2 AS col2 FROM tab1 cor0
----
104
179
82

query I rowsort
SELECT DISTINCT + ( + col1 ) + + col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ( ( col2 ) ) * + ( cor0.col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col0 + - cor0.col2 * + col0 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + ( 96 ) * + cor0.col1 AS col0 FROM tab0, tab1 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to e465a754a1da186b3e4dc94771178bca

query I rowsort
SELECT DISTINCT + - 21 + col1 * + col1 AS col0 FROM tab0 AS cor0
----
7375
8260
9388

query I rowsort
SELECT - 24 * - cor0.col1 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT DISTINCT + - 49 + - col2 AS col1 FROM tab2 AS cor0
----
-75
-76
-87

skipif mysql # not compatible
query I rowsort
SELECT ALL 9 + + col0 * - CAST ( - col1 * col0 + col0 AS REAL ) FROM tab0 AS cor0
----
117609
48969
712899

query I rowsort
SELECT col2 * col1 * 42 - cor0.col0 FROM tab0 AS cor0
----
119172
313315
4039

query I rowsort
SELECT ALL + col2 + - cor0.col2 * + col2 * - col1 AS col2 FROM tab1 AS cor0
----
119904
32547
75870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4335
SELECT DISTINCT + col2 * - cor0.col0 - CAST( - ( col0 ) AS SIGNED ) * + CAST( cor0.col1 AS SIGNED ) FROM tab2 AS cor0
----
-1659
2574
28

skipif mysql # not compatible
query I rowsort label-4335
SELECT DISTINCT + col2 * - cor0.col0 - CAST ( - ( col0 ) AS INTEGER ) * + CAST ( cor0.col1 AS INTEGER ) FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT col2 * - col0 + col1 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + cor0.col0 + - col2 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + 41 + col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1302
-176
-4561

onlyif mysql # use DIV operator for integer division
query I rowsort label-4339
SELECT ALL col2 + + cor0.col1 DIV 47 FROM tab0 AS cor0
----
3
34
83

skipif mysql # not compatible
query I rowsort label-4339
SELECT ALL col2 + + cor0.col1 / 47 FROM tab0 AS cor0
----
3
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4340
SELECT - + col1 DIV + col0 + + cor0.col2 col2 FROM tab2 AS cor0
----
23
26
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4340
SELECT - + col1 / + col0 + + cor0.col2 col2 FROM tab2 AS cor0
----
23
26
38

query I rowsort
SELECT DISTINCT + 44 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
126
45
77

query I rowsort
SELECT - ( 65 ) - + tab1.col1 AS col2 FROM tab1
----
-75
-78
-91

query I rowsort
SELECT ALL + col0 * + 38 - col0 AS col2 FROM tab2
----
259
2886
2923

query I rowsort
SELECT DISTINCT cor1.col0 * + tab0.col2 AS col1 FROM tab0, tab2 AS cor0, tab0 cor1
----
9 values hashing to 54522441dbf7fb56e19a888572d1f6e3

query I rowsort
SELECT col0 - - col2 * - ( 39 ) AS col0 FROM tab1 AS cor0
----
-2103
-2159
-3664

query I rowsort
SELECT - col2 - + col2 * + ( - 59 ) * + col1 AS col0 FROM tab0 AS cor0
----
167409
440176
5722

query I rowsort
SELECT ALL + col1 + + col0 * col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + col2 * + 67 FROM tab0 AS cor0
----
2211
5494
67

query I rowsort
SELECT DISTINCT - col0 * - 66 AS col0 FROM tab2 AS cor0
----
462
5148
5214

query I rowsort
SELECT DISTINCT + col2 * - 87 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
16443
176436
261174

query I rowsort
SELECT ALL + + col2 + + ( - col2 ) FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4352
SELECT ALL col2 + cor0.col0 DIV + col2 AS col0 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-4352
SELECT ALL col2 + cor0.col0 / + col2 AS col0 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT + + col0 + 15 * + 46 * col0 AS col0 FROM tab1 AS cor0
----
2073
44224
55280

query I rowsort
SELECT - col0 * 0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + ( - col0 ) - + cor0.col0 col1 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT - - col1 + + 1 AS col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT ALL + - col1 + + col1 + + 65 * - col2 AS col0 FROM tab2 AS cor0
----
-1690
-1755
-2470

query I rowsort
SELECT DISTINCT - - col1 * - 38 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT ALL + col0 * cor0.col0 - cor0.col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + + 63 * - col0 AS col0 FROM tab2 AS cor0
----
-441
-4914
-4977

query I rowsort
SELECT ALL + - col0 * - col0 - + col2 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT + cor0.col0 * cor0.col2 FROM tab2, tab0 cor0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT - ( - col2 ) * - col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4364
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-4364
SELECT + col1 / col2 col1 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4366
SELECT DISTINCT CAST( - 40 * col2 AS SIGNED ) AS col0 FROM tab2
----
-1040
-1080
-1520

skipif mysql # not compatible
query I rowsort label-4366
SELECT DISTINCT CAST ( - 40 * col2 AS INTEGER ) AS col0 FROM tab2
----
-1040
-1080
-1520

query I rowsort
SELECT ALL tab2.col2 * + col1 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT ( col1 * - col0 ) AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - 35 AS col2 FROM tab2
----
-35

query I rowsort
SELECT col2 * col0 + col1 FROM tab2 cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-4371
SELECT - + 96 DIV col1 AS col1 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4371
SELECT - + 96 / col1 AS col1 FROM tab0 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 95 col2 FROM tab0 AS cor0
----
-95
-95
-95

query I rowsort
SELECT DISTINCT - - 67 * + cor0.col2 FROM tab1 AS cor0
----
3618
3819
6432

query I rowsort
SELECT + 8 + col1 AS col2 FROM tab1 AS cor0
----
18
21
34

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - + col1 * - col1 + cor0.col2 FROM tab1 AS cor0
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-4377
SELECT ALL + col1 DIV + cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-4377
SELECT ALL + col1 / + cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( 86 ) + col2 col0 FROM tab0
----
2097
3011
7736

query I rowsort
SELECT DISTINCT - + col1 - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - col1 * ( - ( - col2 ) * col0 ) FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + + col1 + ( + ( col1 ) ) * - col0 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL col1 + ( cor0.col2 ) * col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - col0 + - ( col2 ) AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - cor0.col2 * 36 FROM tab2 AS cor0
----
-1368
-936
-972

query I rowsort
SELECT col0 + col1 + col1 AS col0 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT DISTINCT - - 3 + + col0 FROM tab0 cor0
----
27
38
92

query I rowsort
SELECT - + 46 AS col2 FROM tab0 AS cor0
----
-46
-46
-46

query I rowsort
SELECT + 6 * col1 FROM tab1 AS cor0
----
156
60
78

query I rowsort
SELECT DISTINCT + col2 + + col1 * col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + 97 * - col2 + - col2 FROM tab0 AS cor0
----
-3234
-8036
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4391
SELECT ALL - + 76 DIV + 51 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4391
SELECT ALL - + 76 / + 51 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - - ( ( - cor0.col0 ) ) + - col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 * col1 col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col2 FROM tab2 AS cor0 WHERE NULL >= NULL
----

query I rowsort
SELECT DISTINCT col1 * col2 * cor0.col1 - - col2 FROM tab0 AS cor0
----
244101
679124
9410

query I rowsort
SELECT DISTINCT - col2 + - col2 * col0 FROM tab0 cor0
----
-36
-7380
-825

query I rowsort
SELECT col1 * - col2 * col1 AS col0 FROM tab0
----
-244068
-679042
-9409

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL IN ( - tab1.col2 )
----

query I rowsort
SELECT - col2 * - col1 + col1 + - col0 FROM tab1 AS cor0
----
1181
1427
516

query I rowsort
SELECT - - col1 * + col0 - - col1 * col2 FROM tab2 AS cor0
----
1054
1989
6136

onlyif mysql # use DIV operator for integer division
query I rowsort label-4402
SELECT + col0 + + col2 DIV - col0 AS col0 FROM tab0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-4402
SELECT + col0 + + col2 / - col0 AS col0 FROM tab0
----
23
35
89

query I rowsort
SELECT + col0 + tab0.col0 * col2 FROM tab0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col2 * - ( + col1 ) FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - - col1 * - col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT + col0 + 96 * + 27 AS col1 FROM tab0 AS cor0
----
2616
2627
2681

query I rowsort
SELECT ALL + - col0 * - 10 AS col1 FROM tab0 AS cor0
----
240
350
890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4408
SELECT + + col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4408
SELECT + + col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * - 51 AS col1 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT DISTINCT - col1 - + 46 AS col0 FROM tab0 AS cor0
----
-132
-137
-143

query I rowsort
SELECT col0 + 65 FROM tab1 cor0
----
129
145
68

query I rowsort
SELECT ALL + cor0.col1 * + 49 AS col2 FROM tab0 AS cor0
----
4214
4459
4753

query I rowsort
SELECT ALL - - cor0.col1 * - ( 57 ) FROM tab0 AS cor0
----
-4902
-5187
-5529

query I rowsort
SELECT DISTINCT + + col0 * + ( - 72 ) AS col2 FROM tab0 AS cor0
----
-1728
-2520
-6408

query I rowsort
SELECT + col0 * - 76 AS col2 FROM tab0 AS cor0
----
-1824
-2660
-6764

query I rowsort
SELECT col0 + cor0.col0 * 65 * cor0.col2 FROM tab1 AS cor0
----
10533
237184
499280

onlyif mysql # use DIV operator for integer division
query I rowsort label-4417
SELECT DISTINCT 99 DIV 66 AS col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4417
SELECT DISTINCT 99 / 66 AS col0 FROM tab2 AS cor0
----
1

query I rowsort
SELECT DISTINCT + - col1 * - col1 + - col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT + 53 + - cor0.col0 * col0 * cor0.col2 FROM tab2 AS cor0
----
-1270
-158131
-237105

onlyif mysql # use DIV operator for integer division
query I rowsort label-4420
SELECT ALL - col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4420
SELECT ALL - col1 / + col1 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL 28 - col1 AS col2 FROM tab0 AS cor0
----
-58
-63
-69

query I rowsort
SELECT - col2 + - col1 * 26 AS col0 FROM tab2 AS cor0
----
-1560
-480
-833

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-4424
SELECT DISTINCT - 33 + + col0 DIV 91 AS col1 FROM tab2 AS cor0
----
-33

skipif mysql # not compatible
query I rowsort label-4424
SELECT DISTINCT - 33 + + col0 / 91 AS col1 FROM tab2 AS cor0
----
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-4425
SELECT DISTINCT + col0 DIV - 37 AS col2 FROM tab2
----
-2
0

skipif mysql # not compatible
query I rowsort label-4425
SELECT DISTINCT + col0 / - 37 AS col2 FROM tab2
----
-2
0

query I rowsort
SELECT DISTINCT - ( + col0 ) AS col0 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT 4 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT + col0 * - col0 + col1 AS col2 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT ALL + 38 * col1 FROM tab2
----
1178
2242
646

query I rowsort
SELECT ALL 7 * col0 AS col1 FROM tab0
----
168
245
623

query I rowsort
SELECT ALL + col1 * + 22 AS col0 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT DISTINCT + 2 FROM tab2, tab0 AS cor0
----
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4433
SELECT - - col2 + 71 DIV + col0 FROM tab0 AS cor0
----
3
35
82

skipif mysql # not compatible
query I rowsort label-4433
SELECT - - col2 + 71 / + col0 FROM tab0 AS cor0
----
3
35
82

query I rowsort
SELECT cor0.col1 * 33 FROM tab2 AS cor0
----
1023
1947
561

query I rowsort
SELECT + + 45 AS col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT DISTINCT - col2 * - col1 * - col0 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT cor0.col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4438
SELECT ALL - col1 * CAST( NULL AS SIGNED ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4438
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT col1 * + ( - col0 ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT tab0.col2 + 94 AS col2 FROM tab0
----
127
176
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4442
SELECT DISTINCT + col1 DIV col0 + col2 FROM tab0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-4442
SELECT DISTINCT + col1 / col0 + col2 FROM tab0
----
3
36
83

query I rowsort
SELECT DISTINCT 80 + 68 * col0 AS col2 FROM tab2
----
5384
5452
556

query I rowsort
SELECT + 83 + col0 FROM tab1
----
147
163
86

query I rowsort
SELECT col1 + col1 - - col1 FROM tab1
----
30
39
78

query I rowsort
SELECT + 72 + col2 AS col0 FROM tab1
----
126
129
168

query I rowsort
SELECT - + ( - ( - col0 ) ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab1 cor1, tab0, tab2 AS cor2
----
3645 values hashing to da83d3eeaeb9e24a3cb14bb7058757dd

query I rowsort
SELECT ALL + 82 * - col1 - - col1 FROM tab1 AS cor0
----
-1053
-2106
-810

query I rowsort
SELECT 7 - col1 FROM tab2 cor0
----
-10
-24
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * ( - col1 ) + ( + col1 ) col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT - ( + 43 ) * cor0.col2 + col1 * col2 AS col0 FROM tab0 AS cor0
----
1419
3936
54

query I rowsort
SELECT DISTINCT - tab0.col1 * col1 + - col0 AS col0 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT col0 + + col0 * - col0 AS col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT + cor0.col2 + cor0.col0 * - col1 * + 48 FROM tab2 AS cor0
----
-10389
-220870
-64426

query I rowsort
SELECT DISTINCT + 22 + - ( col2 ) * + col2 FROM tab2
----
-1422
-654
-707

query I rowsort
SELECT DISTINCT - - cor0.col0 * col1 + + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL 53 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

onlyif mysql # use DIV operator for integer division
query I rowsort label-4459
SELECT col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4459
SELECT col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + - col0 * - cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col1 col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - + col0 + + col0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + cor0.col1 + + col1 * + col0 AS col2 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL + + col1 + - col1 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4465
SELECT - cor0.col0 DIV col0 + + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-4465
SELECT - cor0.col0 / col0 + + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT DISTINCT col0 + - col2 * - col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT - ( col1 ) * - col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + + col0 * + col2 - ( 20 ) * col0 * col2 AS col1 FROM tab2 AS cor0
----
-3591
-38532
-57038

onlyif mysql # use DIV operator for integer division
query I rowsort label-4469
SELECT DISTINCT - + col1 DIV col0 + - 3 FROM tab2 cor0
----
-3
-7

skipif mysql # not compatible
query I rowsort label-4469
SELECT DISTINCT - + col1 / col0 + - 3 FROM tab2 cor0
----
-3
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4470
SELECT - col0 DIV col2 - col2 * col0 FROM tab1
----
-162
-3649
-7680

skipif mysql # not compatible
query I rowsort label-4470
SELECT - col0 / col2 - col2 * col0 FROM tab1
----
-162
-3649
-7680

query I rowsort
SELECT DISTINCT + 48 * + col1 FROM tab0 AS cor0
----
4128
4368
4656

query I rowsort
SELECT DISTINCT - - col2 * + col1 * col2 + col0 * - col0 AS col1 FROM tab2 cor0
----
18307
22550
33800

query I rowsort
SELECT ( col2 ) + col0 * col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT + col1 * - col1 + - ( col1 ) AS col0 FROM tab2 AS cor0
----
-306
-3540
-992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + col2 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - + 19 + + col0 * col2 FROM tab1 AS cor0
----
143
3629
7661

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + + col2 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query IIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 WHERE NULL > NULL
----

query I rowsort
SELECT ALL 37 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4481
SELECT - 53 * col1 DIV col0 FROM tab0 cor0
----
-146
-189
-54

skipif mysql # not compatible
query I rowsort label-4481
SELECT - 53 * col1 / col0 FROM tab0 cor0
----
-146
-189
-54

query I rowsort
SELECT + + 46 + col2 FROM tab0 AS cor0
----
128
47
79

query I rowsort
SELECT ALL ( + 43 ) AS col0 FROM tab2
----
43
43
43

query I rowsort
SELECT ALL 83 * cor0.col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 47b3125ded3146df5efc7431bb751acb

query I rowsort
SELECT ALL - 29 * + col1 AS col1 FROM tab1
----
-290
-377
-754

query I rowsort
SELECT - col2 * - 23 - ( col2 ) FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT - col2 * col1 + - 35 * col1 * - cor0.col1 + col1 FROM tab1 AS cor0
----
22282
2940
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4488
SELECT + col0 DIV + cor0.col2 + 61 + col1 FROM tab0 AS cor0
----
147
153
193

skipif mysql # not compatible
query I rowsort label-4488
SELECT + col0 / + cor0.col2 + 61 + col1 FROM tab0 AS cor0
----
147
153
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-4489
SELECT ALL - col0 + col1 DIV col1 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4489
SELECT ALL - col0 + col1 / col1 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab0, tab1, tab1 AS cor0, tab2 AS cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT + - col1 + - col1 AS col2 FROM tab2 cor0
----
-118
-34
-62

query I rowsort
SELECT - col2 + col1 + + col1 AS col1 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT + 67 * + col1 AS col0 FROM tab0
----
5762
6097
6499

query I rowsort
SELECT + col1 + 68 AS col1 FROM tab0
----
154
159
165

query I rowsort
SELECT ALL + col1 + + 13 * 95 FROM tab0 AS cor0
----
1321
1326
1332

query I rowsort
SELECT ALL - col2 + col2 * ( cor0.col0 ) FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - col0 + 33 FROM tab2 AS cor0
----
-45
-46
26

query I rowsort
SELECT + col2 + + ( + 72 ) FROM tab0 AS cor0
----
105
154
73

query I rowsort
SELECT ALL + cor0.col2 * - ( - ( col2 ) ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + + col2 * 72 FROM tab0 AS cor0
----
2376
5904
72

query I rowsort
SELECT + col2 * - 17 AS col0 FROM tab2
----
-442
-459
-646

query I rowsort
SELECT ALL + - 42 * - col2 AS col2 FROM tab0 AS cor0
----
1386
3444
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4503
SELECT + CAST( + 6 AS SIGNED ) + col1 FROM tab2 cor0
----
23
37
65

skipif mysql # not compatible
query I rowsort label-4503
SELECT + CAST ( + 6 AS INTEGER ) + col1 FROM tab2 cor0
----
23
37
65

query I rowsort
SELECT ALL ( - 61 ) FROM tab2 AS cor0
----
-61
-61
-61

query I rowsort
SELECT 15 + + col2 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT + + col1 + cor0.col1 AS col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT - 88 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-4752
-5016
-8448

onlyif mysql # use DIV operator for integer division
query I rowsort label-4508
SELECT + - 11 DIV - 29 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4508
SELECT + - 11 / - 29 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + ( + col2 ) + - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - ( col0 ) + + cor0.col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - 97 + ( + col0 ) * col1 FROM tab0 cor0
----
2161
3492
8196

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - - col0 + - cor0.col1 * col2 + - 25 FROM tab1 AS cor0
----
-1193
-1426
-531

query I rowsort
SELECT + col0 * col1 + col1 * + col0 FROM tab1 AS cor0
----
1280
156
2080

query I rowsort
SELECT - - 97 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT 97 * + col0 FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT - col1 + + col1 * ( col2 ) AS col2 FROM tab1 cor0
----
1235
1378
560

query I rowsort
SELECT col1 * - col1 - - 54 AS col1 FROM tab2 AS cor0
----
-235
-3427
-907

query I rowsort
SELECT - col1 * + col0 + - cor0.col0 * - col2 * + col1 AS col1 FROM tab1 AS cor0
----
35840
4134
98800

query I rowsort
SELECT - - cor0.col2 - col1 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col0 AS col0 FROM tab0, tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL col1 * ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + ( col1 + col2 ) AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT - col0 * 8 AS col1 FROM tab1 AS cor0
----
-24
-512
-640

onlyif mysql # use DIV operator for integer division
query I rowsort label-4525
SELECT ALL - cor0.col2 DIV cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4525
SELECT ALL - cor0.col2 / cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + 94 + + cor0.col1 FROM tab0 cor0
----
180
185
191

query I rowsort
SELECT ALL - 20 * 91 * col0 + + ( - col0 * + col2 ) FROM tab2 AS cor0
----
-12929
-143988
-146782

query I rowsort
SELECT + - 46 * - col2 FROM tab2 cor0
----
1196
1242
1748

query I rowsort
SELECT ALL + 97 + + 27 FROM tab1 AS cor0
----
124
124
124

query I rowsort
SELECT - - col2 + - cor0.col1 * + col2 AS col0 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT + + ( col1 ) + - col1 * 84 AS col1 FROM tab1 AS cor0
----
-1079
-2158
-830

query I rowsort
SELECT - 28 * col0 + - col0 * col0 FROM tab1 AS cor0
----
-5888
-8640
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4533
SELECT ALL col2 DIV - col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-4533
SELECT ALL col2 / - col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT DISTINCT + - col1 * - col1 + 92 FROM tab1 AS cor0
----
192
261
768

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 * ( + col0 ) + col1 FROM tab2 AS cor0
----
-114059
-5072
-52669

query I rowsort
SELECT DISTINCT + col2 * - col0 + col1 * col2 FROM tab0 AS cor0
----
164
2046
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4537
SELECT + 24 DIV - col1 AS col2 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4537
SELECT + 24 / - col1 AS col2 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT 9 * cor0.col1 AS col1 FROM tab2 AS cor0
----
153
279
531

query I rowsort
SELECT ALL + ( + col2 * + col0 ) FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT - 47 + col1 AS col1 FROM tab1 AS cor0
----
-21
-34
-37

query I rowsort
SELECT DISTINCT ( 75 * cor1.col0 ) AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
225
4800
6000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4542
SELECT ALL + col2 * + col0 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4542
SELECT ALL + col2 * + col0 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + cor0.col1 + - col0 + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1553
-708
-813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - cor0.col2 * + cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 760e91273f37834612f88abef6e165f8

query I rowsort
SELECT - col2 + + 86 FROM tab0 AS cor0
----
4
53
85

query I rowsort
SELECT - 32 + 81 AS col2 FROM tab2 cor0
----
49
49
49

query I rowsort
SELECT ALL col2 * + col0 * + col2 + - 50 * - col1 FROM tab2 AS cor0
----
114926
55678
6653

query I rowsort
SELECT - 71 + + col2 AS col1 FROM tab1 AS cor0
----
-14
-17
25

query I rowsort
SELECT DISTINCT - 0 * + 53 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + - ( - col2 ) + col2 + + col2 * + col0 FROM tab1 AS cor0
----
270
3762
7872

onlyif mysql # use DIV operator for integer division
query I rowsort label-4552
SELECT DISTINCT + col0 DIV - 25 FROM tab1 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-4552
SELECT DISTINCT + col0 / - 25 FROM tab1 AS cor0
----
-2
-3
0

query I rowsort
SELECT ALL col2 * - col2 + col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT col1 - + 5 AS col2 FROM tab0 cor0
----
81
86
92

query I rowsort
SELECT ALL + ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT 90 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
90

query I rowsort
SELECT col2 - + col1 * + 70 FROM tab1
----
-1766
-643
-814

query I rowsort
SELECT + col2 + - 14 * col2 AS col2 FROM tab0
----
-1066
-13
-429

query I rowsort
SELECT + col0 - col0 * + col1 AS col2 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4560
SELECT + col1 + 71 + col0 * + CAST( - col1 AS SIGNED ) AS col2 FROM tab2 cor0
----
-115
-1255
-4472

skipif mysql # not compatible
query I rowsort label-4560
SELECT + col1 + 71 + col0 * + CAST ( - col1 AS INTEGER ) AS col2 FROM tab2 cor0
----
-115
-1255
-4472

query I rowsort
SELECT DISTINCT + + 22 * col2 AS col0 FROM tab2 AS cor0
----
572
594
836

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4562
SELECT ALL + + CAST( + col2 AS SIGNED ) * col2 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-4562
SELECT ALL + + CAST ( + col2 AS INTEGER ) * col2 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-4563
SELECT + 40 DIV col2 AS col1 FROM tab0 AS cor0
----
0
1
40

skipif mysql # not compatible
query I rowsort label-4563
SELECT + 40 / col2 AS col1 FROM tab0 AS cor0
----
0
1
40

query I rowsort
SELECT ALL - - 85 * col1 FROM tab0 cor0
----
7310
7735
8245

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - 18 col1 FROM tab2 AS cor0
----
1062
306
558

query I rowsort
SELECT col0 * - 39 AS col1 FROM tab2 cor0
----
-273
-3042
-3081

query I rowsort
SELECT ALL - cor0.col1 + + cor0.col0 AS col0 FROM tab1 cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to b4cba4f278386334ce9a7cc0fa9e286a

query I rowsort
SELECT 57 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT - 33 FROM tab2, tab1, tab1 cor0
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

query I rowsort
SELECT ALL + 96 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT + ( - col0 ) * col0 FROM tab2
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) * + col2 col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - - 15 + 70 * col1 FROM tab0 AS cor0
----
6035
6385
6805

query I rowsort
SELECT ALL - - 63 AS col1 FROM tab0 AS cor0
----
63
63
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 + col0 - col2 col2 FROM tab0
----
15
69
96

query I rowsort
SELECT ALL 61 - + col0 * - 93 AS col1 FROM tab1
----
340
6013
7501

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4577
SELECT ALL - - cor0.col0 + + 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-4577
SELECT ALL - - cor0.col0 + + CAST ( NULL AS INTEGER ) / - col1 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - ( col0 ) AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col0 + + 76 * col1 FROM tab1 AS cor0
----
1068
1979
824

onlyif mysql # use DIV operator for integer division
query I rowsort label-4580
SELECT + 53 DIV - col1 AS col0 FROM tab1
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-4580
SELECT + 53 / - col1 AS col0 FROM tab1
----
-2
-4
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4581
SELECT col0 * + col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4581
SELECT col0 * + col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 3 AS col2 FROM tab2, tab0 AS cor0
----
-3

query I rowsort
SELECT - col1 * col2 + cor0.col1 * col1 + ( + col1 + col0 ) FROM tab2 cor0
----
-261
162
2084

query I rowsort
SELECT DISTINCT + + cor0.col1 + col0 FROM tab1 AS cor0
----
29
74
93

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to c3f17e238f07c9d20c4ee001084f26c7

query I rowsort
SELECT + col2 * col2 - col2 AS col0 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4587
SELECT ALL - col0 + + CAST( cor0.col1 AS SIGNED ) DIV col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4587
SELECT ALL - col0 + + CAST ( cor0.col1 AS INTEGER ) / col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - cor0.col1 + col0 * col0 FROM tab2 AS cor0
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-4589
SELECT cor0.col2 + ( col0 ) + col1 DIV + 6 AS col0 FROM tab1 AS cor0
----
122
178
61

skipif mysql # not compatible
query I rowsort label-4589
SELECT cor0.col2 + ( col0 ) + col1 / + 6 AS col0 FROM tab1 AS cor0
----
122
178
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL col2 + + col0 + 78 FROM tab1 AS cor0
----
135
199
254

query I rowsort
SELECT DISTINCT + cor0.col2 * - 16 AS col1 FROM tab2 cor0
----
-416
-432
-608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * col2 + 21 * col2 col0 FROM tab2 AS cor0
----
2574
3800
756

query I rowsort
SELECT ALL + col1 - col0 * - col0 AS col0 FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4595
SELECT - CAST( + 70 AS SIGNED ) AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c2a2994a4e94583683ccda2cc098c58f

skipif mysql # not compatible
query I rowsort label-4595
SELECT - CAST ( + 70 AS INTEGER ) AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c2a2994a4e94583683ccda2cc098c58f

query I rowsort
SELECT - cor0.col0 + - cor0.col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT ALL - 20 + + col0 FROM tab0 AS cor0
----
15
4
69

query I rowsort
SELECT DISTINCT + col2 - + col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + - col0 * + cor0.col2 AS col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4600
SELECT - + cor0.col0 + CAST( col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-4600
SELECT - + cor0.col0 + CAST ( col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT 98 FROM tab0, tab2 cor0, tab1 cor1
----
98

query I rowsort
SELECT DISTINCT - 81 AS col1 FROM tab0, tab1, tab2 AS cor0
----
-81

query I rowsort
SELECT col0 * col1 + - ( - col1 + col1 ) * + col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + 90 + + 71 AS col0 FROM tab2 cor0
----
161
161
161

query I rowsort
SELECT + + ( + 76 ) + + col2 FROM tab0 AS cor0
----
109
158
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4606
SELECT 38 * col1 DIV col1 FROM tab1 AS cor0
----
38
38
38

skipif mysql # not compatible
query I rowsort label-4606
SELECT 38 * col1 / col1 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT col2 + col1 * - col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT - col0 - 76 * - col0 AS col2 FROM tab2 AS cor0
----
525
5850
5925

query I rowsort
SELECT 79 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT DISTINCT 86 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
86

query I rowsort
SELECT + col0 + 2 - col2 FROM tab0 AS cor0
----
-7
36
9

query I rowsort
SELECT DISTINCT - 55 AS col0 FROM tab0, tab1 AS cor0, tab1, tab2 cor1
----
-55

query I rowsort
SELECT col1 - + col1 * 85 * col0 AS col1 FROM tab1 AS cor0
----
-54390
-6604
-88387

query I rowsort
SELECT DISTINCT + tab2.col0 * 91 + - col1 FROM tab2
----
606
7039
7172

onlyif mysql # use DIV operator for integer division
query I rowsort label-4615
SELECT ALL - + CAST( col0 AS SIGNED ) * + col0 + - col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-4615
SELECT ALL - + CAST ( col0 AS INTEGER ) * + col0 + - col0 / - col1 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + col1 * + col1 - + col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT DISTINCT col1 * - col1 + cor0.col2 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT ALL - + 72 * - col1 * col0 AS col1 FROM tab0 AS cor0
----
148608
244440
583128

query I rowsort
SELECT 7 * col0 * 49 AS col2 FROM tab0 AS cor0
----
12005
30527
8232

onlyif mysql # use DIV operator for integer division
query I rowsort label-4620
SELECT col0 - cor0.col1 DIV col2 AS col2 FROM tab0 AS cor0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-4620
SELECT col0 - cor0.col1 / col2 AS col2 FROM tab0 AS cor0
----
-62
22
88

query I rowsort
SELECT DISTINCT - 71 FROM tab1
----
-71

query I rowsort
SELECT ( ( col2 ) + ( + col2 ) ) AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL - ( col0 ) * col1 + + 94 * col2 FROM tab0
----
-3301
-391
1038

query I rowsort
SELECT - 41 * + col2 + - col0 + ( tab0.col0 ) FROM tab0
----
-1353
-3362
-41

onlyif mysql # use DIV operator for integer division
query I rowsort label-4625
SELECT DISTINCT - 52 DIV col1 FROM tab1
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-4625
SELECT DISTINCT - 52 / col1 FROM tab1
----
-2
-4
-5

query I rowsort
SELECT 26 * col1 FROM tab0
----
2236
2366
2522

query I rowsort
SELECT + ( - 65 ) AS col2 FROM tab2
----
-65
-65
-65

query I rowsort
SELECT 40 * + col1 * col2 FROM tab2
----
25840
33480
61360

query I rowsort
SELECT - cor0.col1 * 72 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a2271746de2f822c2e7478dd6681881e

query I rowsort
SELECT DISTINCT 37 + - col0 - ( - col0 ) AS col1 FROM tab1
----
37

query I rowsort
SELECT ALL + - col0 + 45 * + col1 FROM tab1 AS cor0
----
1167
386
505

query I rowsort
SELECT DISTINCT - col2 + - 53 FROM tab2 AS cor0
----
-79
-80
-91

query I rowsort
SELECT + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + + col2 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4635
SELECT ALL - col0 DIV 57 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4635
SELECT ALL - col0 / 57 FROM tab2
----
-1
-1
0

query I rowsort
SELECT 82 FROM tab1, tab1 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + tab2.col1 * - tab2.col1 * col1 col1 FROM tab2
----
-205438
-29822
-4930

query I rowsort
SELECT ALL col1 * col1 + col1 + - col1 * + tab2.col0 AS col2 FROM tab2
----
-1037
-1062
775

query I rowsort
SELECT - col1 FROM tab1 WHERE NULL <= NULL
----

query I rowsort
SELECT ALL + col0 + col1 * tab0.col2 AS col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT col1 * + col1 - col2 * - col0 FROM tab1
----
3748
7849
838

query I rowsort
SELECT col2 + + col2 FROM tab2 WHERE ( NULL ) <> ( col2 * tab2.col0 )
----

query I rowsort
SELECT DISTINCT col0 * + col1 * col0 AS col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT - col0 FROM tab2 WHERE ( col1 + col1 + + col2 ) < col2 * - col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + tab1.col0 + - col1 col1 FROM tab1
----
111
163
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 + col2 col1 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT tab0.col1 + col1 + + tab0.col2 * + col0 AS col1 FROM tab0
----
229
7480
964

query I rowsort
SELECT col2 AS col0 FROM tab0 WHERE col0 NOT IN ( col2 + col2 )
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4649
SELECT ALL col0 DIV col0 + - col2 AS col0 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-4649
SELECT ALL col0 / col0 + - col2 AS col0 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT col0 + + tab2.col2 AS col1 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 col1 FROM tab0 WHERE NOT NULL <> - col2
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( + col0 ) <> ( NULL )
----

query I rowsort
SELECT + col2 + + tab0.col1 FROM tab0
----
119
173
98

query I rowsort
SELECT col1 * + col0 + tab0.col0 AS col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT tab1.col0 - + col0 * col1 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + col0 * col0 - col2 * + col1 FROM tab2
----
-788
4550
5595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - col1 col1 FROM tab0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4658
SELECT - + col1 * col0 DIV - col1 + cor0.col2 * col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

skipif mysql # not compatible
query I rowsort label-4658
SELECT - + col1 * col0 / - col1 + cor0.col2 * col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT + cor0.col2 + - col2 + cor0.col2 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4660
SELECT col1 * + cor0.col1 DIV - cor0.col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-4660
SELECT col1 * + cor0.col1 / - cor0.col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col0 + - col1 + - cor0.col2 FROM tab0 cor0
----
-133
-143
-262

query I rowsort
SELECT col1 + - cor0.col0 + + cor0.col1 FROM tab2 AS cor0
----
-45
40
55

query I rowsort
SELECT ALL - col0 FROM tab2 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col1 col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-4665
SELECT - cor0.col1 DIV - cor0.col0 FROM tab1, tab2 cor0
----
9 values hashing to d7f03813050fab0932763694116f69ed

skipif mysql # not compatible
query I rowsort label-4665
SELECT - cor0.col1 / - cor0.col0 FROM tab1, tab2 cor0
----
9 values hashing to d7f03813050fab0932763694116f69ed

query IIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1 WHERE NOT NULL = cor1.col0
----

query I rowsort
SELECT + col0 * - ( + 87 ) FROM tab1
----
-261
-5568
-6960

onlyif mysql # use DIV operator for integer division
query I rowsort label-4668
SELECT ALL 55 DIV 54 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-4668
SELECT ALL 55 / 54 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 AS cor2, tab1 AS cor3
----
3645 values hashing to a87c024a0045fd44371c9b28640799d7

query I rowsort
SELECT + - col1 * col0 - col1 FROM tab0 cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - 64 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + + col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT + cor0.col1 + + col0 * 80 FROM tab0 cor0
----
2006
2897
7211

onlyif mysql # use DIV operator for integer division
query I rowsort label-4674
SELECT DISTINCT + - col2 DIV col0 + - col2 * - col0 AS col2 FROM tab1 AS cor0
----
144
3648
7679

skipif mysql # not compatible
query I rowsort label-4674
SELECT DISTINCT + - col2 / col0 + - col2 * - col0 AS col2 FROM tab1 AS cor0
----
144
3648
7679

query I rowsort
SELECT DISTINCT + - col2 * col2 + - cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
-2704
-4446
-918

query I rowsort
SELECT + col0 - 64 AS col0 FROM tab2 AS cor0
----
-57
14
15

query I rowsort
SELECT - + 96 * + col0 + + col1 * 84 AS col0 FROM tab2 AS cor0
----
-2532
-6156
1932

query I rowsort
SELECT cor2.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT - + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT DISTINCT 75 * col1 * cor0.col0 AS col1 FROM tab1 AS cor0
----
48000
5850
78000

onlyif mysql # use DIV operator for integer division
query I rowsort label-4681
SELECT ALL + col1 * col0 DIV col2 + col1 + col0 FROM tab1 AS cor0
----
103
30
85

skipif mysql # not compatible
query I rowsort label-4681
SELECT ALL + col1 * col0 / col2 + col1 + col0 FROM tab1 AS cor0
----
103
30
85

query I rowsort
SELECT ALL - - 19 - - col1 AS col0 FROM tab2 AS cor0
----
36
50
78

query I rowsort
SELECT ALL + 3 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT DISTINCT - ( col2 ) * - col0 * col2 + col2 * - col2 FROM tab1 AS cor0
----
204687
5832
728064

query I rowsort
SELECT - col2 * col2 + + col2 AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT - col2 * + col2 + col2 * + col2 * - col1 FROM tab1
----
-129024
-35739
-78732

query I rowsort
SELECT + col2 + + col2 * - col1 - col0 AS col0 FROM tab1
----
-1232
-1353
-577

query I rowsort
SELECT ALL - tab1.col0 * col1 + col0 AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL ( 97 ) AS col0 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4690
SELECT DISTINCT - ( - col0 ) + CAST( NULL AS SIGNED ) / col0 col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4690
SELECT DISTINCT - ( - col0 ) + CAST ( NULL AS INTEGER ) / col0 col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - 36 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT - tab0.col0 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT ALL col0 - col1 * col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT col0 - 27 * col1 AS col0 FROM tab0 AS cor0
----
-2298
-2368
-2584

onlyif mysql # use DIV operator for integer division
query I rowsort label-4695
SELECT - cor0.col2 DIV + 88 + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4695
SELECT - cor0.col2 / + 88 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + - col0 + - 26 FROM tab2 AS cor0
----
-104
-105
-33

query I rowsort
SELECT ALL col2 * col1 * tab1.col0 AS col2 FROM tab1
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4698
SELECT ( col1 + + CAST( NULL AS SIGNED ) * 17 ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4698
SELECT ( col1 + + CAST ( NULL AS INTEGER ) * 17 ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + 2 * col1 + - col0 AS col1 FROM tab0
----
14768
16473
18783

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4700
SELECT - + CAST( 37 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-37
-37
-37

skipif mysql # not compatible
query I rowsort label-4700
SELECT - + CAST ( 37 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-37
-37
-37

query I rowsort
SELECT - + cor0.col2 - - col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT + - col1 * - 47 AS col1 FROM tab1 AS cor0
----
1222
470
611

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 149298fc0224e93f3bc2df24a3ebeeb8

query I rowsort
SELECT DISTINCT - 29 + - cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
-118
-53
-64

query I rowsort
SELECT cor0.col1 + - col1 + + col0 * - col0 * col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT + 41 FROM tab2, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL 72 AS col2 FROM tab0
----
72
72
72

query I rowsort
SELECT - 91 * 42 FROM tab0 AS cor0
----
-3822
-3822
-3822

query I rowsort
SELECT - - 13 - + cor0.col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1235
-1391
-557

query I rowsort
SELECT + col1 * + col2 - + cor0.col2 AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT + col1 + + col0 * col2 + - col2 FROM tab0 AS cor0
----
131
7307
845

query I rowsort
SELECT 34 AS col1 FROM tab2
----
34
34
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col2 col2 FROM tab2, tab0, tab0 AS cor0, tab1
----
54
57
96

query I rowsort
SELECT DISTINCT + - col1 + col2 * - col2 AS col1 FROM tab0 cor0
----
-1175
-6815
-98

query I rowsort
SELECT DISTINCT - 49 FROM tab1, tab1 cor0, tab2 AS cor1
----
-49

query I rowsort
SELECT ALL col0 * col1 - - 90 AS col2 FROM tab0 AS cor0
----
2154
3485
8189

query I rowsort
SELECT ( col1 ) * + col0 + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - + col0 + ( col1 ) * col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT - col0 * col0 * + col1 FROM tab0 cor0
----
-118825
-49536
-720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-4720
SELECT DISTINCT col2 + + col1 DIV - ( + col0 + col2 ) FROM tab0 AS cor0
----
-1
32
82

skipif mysql # not compatible
query I rowsort label-4720
SELECT DISTINCT col2 + + col1 / - ( + col0 + col2 ) FROM tab0 AS cor0
----
-1
32
82

query I rowsort
SELECT col0 * 54 * - col1 FROM tab0 cor0
----
-111456
-183330
-437346

query I rowsort
SELECT + - col1 * - 9 AS col0 FROM tab2 AS cor0
----
153
279
531

query I rowsort
SELECT - - col0 + + ( - col0 ) * + col1 * + col0 FROM tab1 cor0
----
-231
-40896
-83120

query I rowsort
SELECT col1 * cor0.col1 FROM tab0 cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 * + 58 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 168732a85214a1c891da89f67daedbc0

query I rowsort
SELECT col0 * tab0.col1 + + col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL + col0 + cor0.col1 * col2 AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + col2 + col2 * col1 + - col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - col1 * col0 + col2 + col2 * + col2 AS col2 FROM tab2 AS cor0
----
-3900
139
539

query I rowsort
SELECT - col1 * + col0 + col2 * + col0 AS col0 FROM tab1 cor0
----
3008
6640
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col2 + cor0.col2 col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT col1 * + tab2.col0 - - col0 * col1 FROM tab2
----
2686
434
9204

query I rowsort
SELECT + col2 * col2 - - col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT + + col0 * col1 + - col2 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT col1 + + col2 * cor0.col1 + col0 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT + + col1 * col2 + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4737
SELECT - CAST( NULL AS SIGNED ) * col2 * + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4737
SELECT - CAST ( NULL AS INTEGER ) * col2 * + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col2 AS REAL ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - 67 * + col2 FROM tab0 AS cor0
----
-2211
-5494
-67

query I rowsort
SELECT ALL - 68 + col2 AS col2 FROM tab0 AS cor0
----
-35
-67
14

query I rowsort
SELECT - col1 * + 27 AS col0 FROM tab1
----
-270
-351
-702

query I rowsort
SELECT ( - col1 ) * col0 * col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT - - cor0.col0 * cor0.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 col0 FROM tab1
----
-71
-71
-71

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NOT NULL IN ( - col0 ) ) AND NOT ( NULL ) IN ( - tab1.col1 )
----

query I rowsort
SELECT ALL - col0 + tab2.col1 AS col1 FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-4747
SELECT DISTINCT - + col2 DIV + col2 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4747
SELECT DISTINCT - + col2 / + col2 FROM tab1 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 * + cor0.col1 * col1 + col0 + + cor0.col1 col1 FROM tab0 AS cor0
----
532622
596412
677580

query I rowsort
SELECT ALL + + col2 * cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + + 59 * - col0 * col0 FROM tab0 AS cor0
----
-33984
-467339
-72275

query I rowsort
SELECT 71 + col2 AS col1 FROM tab1 AS cor0
----
125
128
167

query I rowsort
SELECT DISTINCT 31 * + col1 + + col1 FROM tab0 AS cor0
----
2752
2912
3104

query I rowsort
SELECT + cor0.col2 + col0 * 95 * col0 FROM tab0 AS cor0
----
116376
54753
752577

query I rowsort
SELECT ALL + 59 - - col1 FROM tab1 AS cor0
----
69
72
85

query I rowsort
SELECT DISTINCT - 63 - col1 * - col1 AS col0 FROM tab0 AS cor0
----
7333
8218
9346

onlyif mysql # use DIV operator for integer division
query I rowsort label-4756
SELECT ALL col2 + cor0.col1 * col2 + - col0 * col0 DIV col0 FROM tab0 AS cor0
----
2847
63
7455

skipif mysql # not compatible
query I rowsort label-4756
SELECT ALL col2 + cor0.col1 * col2 + - col0 * col0 / col0 FROM tab0 AS cor0
----
2847
63
7455

query I rowsort
SELECT ALL + 18 * - col0 * + col2 + col2 FROM tab1 AS cor0
----
-138144
-2862
-65607

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 15 * col2 col0 FROM tab0 AS cor0
----
1230
15
495

query I rowsort
SELECT DISTINCT - - col2 - - col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col2 * - col2 * col2 AS col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4761
SELECT - col1 * - cor0.col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4761
SELECT - col1 * - cor0.col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 25 col1 FROM tab0 AS cor0
----
-25
-25
-25

query I rowsort
SELECT - col2 * col0 + + col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL - 86 + 69 - - col2 AS col2 FROM tab0
----
-16
16
65

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + 31 * col2 AS col1 FROM tab0 AS cor0
----
1023
2542
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-4767
SELECT ALL + - 63 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4767
SELECT ALL + - 63 / + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 2 * col1 FROM tab2 cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col0 * - col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT col0 * col0 + - col1 FROM tab0
----
1128
490
7830

query I rowsort
SELECT + + ( col1 ) + ( - col1 ) * - cor0.col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT 28 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT ALL + 63 + col1 * + col0 AS col2 FROM tab1
----
1103
141
703

query I rowsort
SELECT - col0 + 98 * col0 FROM tab0 AS cor0
----
2328
3395
8633

query I rowsort
SELECT ALL - - 72 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT cor1.col0 AS col2 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + + 90 * col1 FROM tab0 AS cor0
----
7740
8190
8730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col2 + + tab1.col1 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1fa18cbfcccda263f7b810e83e3d150c

query I rowsort
SELECT tab2.col0 - - tab2.col2 * col2 * - col1 AS col2 FROM tab2
----
-22592
-24469
-39806

query I rowsort
SELECT DISTINCT + ( col1 ) - col2 AS col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT + ( 10 ) * - col1 FROM tab2
----
-170
-310
-590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 56 * 50 * col2 + ( col2 ) col2 FROM tab2
----
106438
72826
75627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL + 52 - - col0 FROM tab0
----
141
76
87

query I rowsort
SELECT + + ( 85 ) FROM tab2 AS cor0
----
85
85
85

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1 cor1, tab0, tab1 AS cor2
----
3645 values hashing to 73edaf471aef3f42e9a0b0be98b79374

onlyif mysql # use DIV operator for integer division
query I rowsort label-4787
SELECT - - col1 DIV + col0 - col1 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-4787
SELECT - - col1 / + col0 - col1 FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT ALL + cor0.col0 + 35 AS col2 FROM tab0 AS cor0
----
124
59
70

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - 42 AS REAL ) FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

query I rowsort
SELECT DISTINCT + 88 * + col0 - - col2 * col0 * - 98 AS col0 FROM tab1 AS cor0
----
-15612
-351872
-745600

query I rowsort
SELECT ALL - ( + cor0.col0 ) + col0 * col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT - 33 * col0 + col2 AS col1 FROM tab2 AS cor0
----
-204
-2548
-2569

onlyif mysql # use DIV operator for integer division
query I rowsort label-4793
SELECT ALL + col2 DIV + 87 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4793
SELECT ALL + col2 / + 87 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 47 * - col1 + col1 FROM tab0 AS cor0
----
-3956
-4186
-4462

query I rowsort
SELECT ALL + ( - col1 ) + col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 80 col0 FROM tab0
----
80
80
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4797
SELECT - + col0 * col2 DIV - col1 - + 28 FROM tab1 cor0
----
-22
336
562

skipif mysql # not compatible
query I rowsort label-4797
SELECT - + col0 * col2 / - col1 - + 28 FROM tab1 cor0
----
-22
336
562

query I rowsort
SELECT ALL - - 15 * col2 * ( 82 + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
212790
2685
83160

onlyif mysql # use DIV operator for integer division
query I rowsort label-4799
SELECT DISTINCT + col2 + - col0 DIV col0 AS col1 FROM tab2 cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-4799
SELECT DISTINCT + col2 + - col0 / col0 AS col1 FROM tab2 cor0
----
25
26
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT + col1 * + col1 + 32 DIV + col0 FROM tab1 cor0
----
100
169
686

skipif mysql # not compatible
query I rowsort label-4800
SELECT + col1 * + col1 + 32 / + col0 FROM tab1 cor0
----
100
169
686

query I rowsort
SELECT DISTINCT - - col1 + - col1 * + col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL cor1.col2 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4803
SELECT - + cor0.col2 * ( - col0 ) DIV + col1 + + CAST( - 92 AS SIGNED ) FROM tab1 AS cor0
----
-86
272
498

skipif mysql # not compatible
query I rowsort label-4803
SELECT - + cor0.col2 * ( - col0 ) / + col1 + + CAST ( - 92 AS INTEGER ) FROM tab1 AS cor0
----
-86
272
498

query I rowsort
SELECT DISTINCT - ( - tab2.col2 ) FROM tab2, tab1 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4805
SELECT ALL col1 * + CAST( - col1 AS SIGNED ) * + col1 AS col2 FROM tab1 cor0
----
-1000
-17576
-2197

skipif mysql # not compatible
query I rowsort label-4805
SELECT ALL col1 * + CAST ( - col1 AS INTEGER ) * + col1 AS col2 FROM tab1 cor0
----
-1000
-17576
-2197

query I rowsort
SELECT ALL col1 - + 4 AS col2 FROM tab1 AS cor0
----
22
6
9

query I rowsort
SELECT ( + ( col0 ) ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col0 * - 30 AS col1 FROM tab1 AS cor0
----
-1920
-2400
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4809
SELECT + - CAST( col2 AS SIGNED ) * - col1 FROM tab1 cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-4809
SELECT + - CAST ( col2 AS INTEGER ) * - col1 FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 78 col1 FROM tab2 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4811
SELECT - + 53 DIV + col1 FROM tab1 AS cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-4811
SELECT - + 53 / + col1 FROM tab1 AS cor0
----
-2
-4
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4812
SELECT DISTINCT + CAST( - col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4812
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col0 AS REAL ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - 38 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT col1 * - col1 + col2 FROM tab1 AS cor0
----
-43
-622
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4816
SELECT - + col0 DIV col2 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-4816
SELECT - + col0 / col2 FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT + 6 FROM tab2, tab2 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4818
SELECT + - col1 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4818
SELECT + - col1 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 70 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT + col1 * - col2 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 74 * - cor0.col1 AS col2 FROM tab2, tab0 AS cor0
----
-6364
-6734
-7178

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4822
SELECT CAST( 14 AS SIGNED ) FROM tab1, tab2 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

skipif mysql # not compatible
query I rowsort label-4822
SELECT CAST ( 14 AS INTEGER ) FROM tab1, tab2 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT col0 + + col2 * col0 AS col0 FROM tab0 cor0
----
70
7387
816

skipif mysql # not compatible
query I rowsort
SELECT + col2 + - CAST ( cor0.col1 AS REAL ) AS col2 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4825
SELECT tab0.col2 DIV - ( col2 + col0 * - tab0.col1 ) AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4825
SELECT tab0.col2 / - ( col2 + col0 * - tab0.col1 ) AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 43 + cor0.col2 col0 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to aeedcb8b10d19fae1a0ec120af9a332f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 + - col1 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - col2 + col0 * + col1 * col0 AS col1 FROM tab1
----
180
40903
83104

query I rowsort
SELECT - 62 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4830
SELECT - cor0.col0 * + ( - 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-4830
SELECT - cor0.col0 * + ( - col2 ) + CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 80 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT DISTINCT - - cor0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
26
27
38

query I rowsort
SELECT ALL + 86 * cor0.col1 * ( col2 ) FROM tab0 AS cor0
----
244068
641732
8342

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 * + cor0.col0 col0 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 * col0 * col1 + col1 col2 FROM tab2 AS cor0
----
-12338
-262255
-76534

query I rowsort
SELECT DISTINCT + col1 + - col1 * col1 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT 99 + col1 FROM tab0
----
185
190
196

query I rowsort
SELECT + col2 - col1 * + col0 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT tab0.col2 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT col0 * col2 + 12 AS col1 FROM tab1 cor0
----
174
3660
7692

query I rowsort
SELECT + ( - col2 ) * + col2 * - col1 AS col1 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT + col0 * + col2 + 62 AS col2 FROM tab2
----
2090
251
3064

query I rowsort
SELECT - + 78 + + col0 FROM tab0 AS cor0
----
-43
-54
11

query I rowsort
SELECT DISTINCT - col0 * - 92 AS col1 FROM tab0 AS cor0
----
2208
3220
8188

query I rowsort
SELECT ALL - col1 + 8 + col1 AS col2 FROM tab1 AS cor0
----
8
8
8

query I rowsort
SELECT cor0.col2 * col1 AS col0 FROM tab2 cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT - col2 DIV 53 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4847
SELECT - col2 / 53 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT col2 * - col1 + - col2 + - col1 AS col2 FROM tab2 AS cor0
----
-1619
-701
-895

query I rowsort
SELECT ALL - tab0.col1 AS col0 FROM tab0, tab1, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

query I rowsort
SELECT ALL col0 + col0 * + col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT ALL - - cor0.col1 * + 76 + + col0 FROM tab1 AS cor0
----
1068
1979
824

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4852
SELECT DISTINCT - + col2 + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-4852
SELECT DISTINCT - + col2 + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + col0 + col0 + 92 * + col0 AS col2 FROM tab2 cor0
----
658
7332
7426

query I rowsort
SELECT + ( - col1 ) + col0 * 23 AS col2 FROM tab1 AS cor0
----
1462
1827
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4855
SELECT - - CAST( NULL AS SIGNED ) + 73 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4855
SELECT - - CAST ( NULL AS INTEGER ) + 73 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + + col1 * + cor0.col2 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4857
SELECT col1 - - col1 DIV col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-4857
SELECT col1 - - col1 / col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT 54 * col1 + col1 AS col1 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT + - ( + ( - cor0.col0 ) ) * + cor0.col0 - - 68 AS col1 FROM tab0 AS cor0
----
1293
644
7989

query I rowsort
SELECT + + 46 * col0 FROM tab1 AS cor0
----
138
2944
3680

query I rowsort
SELECT ALL - 93 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to ea79c61f7a02d25805171f5e85229fba

query I rowsort
SELECT DISTINCT - tab1.col2 + col1 + 14 * col2 AS col1 FROM tab1
----
1261
728
751

query I rowsort
SELECT DISTINCT + col1 + - col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - 16 * ( - col0 ) * + col1 col1 FROM tab0 AS cor0
----
129495
33000
54285

query I rowsort
SELECT ALL - col1 + - 12 * + col0 AS col0 FROM tab2 AS cor0
----
-115
-965
-995

query I rowsort
SELECT ALL + col1 + - 41 * - 8 AS col0 FROM tab1 cor0
----
338
341
354

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col0 * 84 col2 FROM tab2 AS cor0
----
595
6630
6715

query I rowsort
SELECT 82 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT ALL - col1 + 26 * cor0.col1 AS col2 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT - col0 - - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * + 70 * + col1 col0 FROM tab0 AS cor0
----
-198660
-522340
-6790

query I rowsort
SELECT DISTINCT col1 * + col1 + + cor0.col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT - ( col0 ) * + col1 - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-4874
SELECT DISTINCT - - col2 * col1 DIV col1 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4874
SELECT DISTINCT - - col2 * col1 / col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL cor0.col1 * + 73 + - col2 * - 54 AS col1 FROM tab2 AS cor0
----
3293
3721
5711

onlyif mysql # use DIV operator for integer division
query I rowsort label-4876
SELECT - - col2 DIV - col2 + + col1 + 29 AS col2 FROM tab0 AS cor0
----
114
119
125

skipif mysql # not compatible
query I rowsort label-4876
SELECT - - col2 / - col2 + + col1 + 29 AS col2 FROM tab0 AS cor0
----
114
119
125

query I rowsort
SELECT DISTINCT + 44 + col1 FROM tab1 AS cor0
----
54
57
70

query I rowsort
SELECT - 11 + - col1 FROM tab0 AS cor0
----
-102
-108
-97

query I rowsort
SELECT ALL - - col1 * + cor0.col0 * cor0.col1 AS col0 FROM tab2 AS cor0
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-4880
SELECT DISTINCT + col2 DIV 7 + col2 + col2 AS col2 FROM tab1 AS cor0
----
115
122
205

skipif mysql # not compatible
query I rowsort label-4880
SELECT DISTINCT + col2 / 7 + col2 + col2 AS col2 FROM tab1 AS cor0
----
115
122
205

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( col1 ) col2 FROM tab1 cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4882
SELECT - + CAST( - col1 AS SIGNED ) - - col1 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
110
182
702

skipif mysql # not compatible
query I rowsort label-4882
SELECT - + CAST ( - col1 AS INTEGER ) - - col1 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4883
SELECT ALL - + col2 + + 13 * + cor0.col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
-20
-69
12

skipif mysql # not compatible
query I rowsort label-4883
SELECT ALL - + col2 + + 13 * + cor0.col0 / + col0 AS col0 FROM tab0 AS cor0
----
-20
-69
12

query I rowsort
SELECT ALL col2 - ( 32 ) * col0 FROM tab2
----
-197
-2470
-2490

query I rowsort
SELECT DISTINCT col0 - + col2 * col2 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT + 38 + col0 * col2 FROM tab1 AS cor0
----
200
3686
7718

query I rowsort
SELECT + col1 * col0 * - cor0.col0 + - col2 FROM tab2 AS cor0
----
-106135
-1546
-358982

query I rowsort
SELECT + col1 + 5 AS col2 FROM tab1 AS cor0
----
15
18
31

query I rowsort
SELECT - ( - cor0.col0 ) * ( cor0.col1 ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 * - 63 + + 18 * + col0 col2 FROM tab0 AS cor0
----
-129600
-213255
-508635

query I rowsort
SELECT ALL + col2 * - cor0.col0 + - 71 FROM tab2 AS cor0
----
-2099
-260
-3073

query I rowsort
SELECT DISTINCT - - col0 - + cor0.col1 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4893
SELECT DISTINCT - + 8 DIV + col2 + ( + col2 * col1 ) FROM tab0 AS cor0
----
2838
7462
89

skipif mysql # not compatible
query I rowsort label-4893
SELECT DISTINCT - + 8 / + col2 + ( + col2 * col1 ) FROM tab0 AS cor0
----
2838
7462
89

query I rowsort
SELECT ALL col0 * + col2 * - col1 AS col0 FROM tab1 cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4895
SELECT ALL cor0.col1 + - col2 DIV + ( col1 * + cor0.col1 + col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4895
SELECT ALL cor0.col1 + - col2 / + ( col1 * + cor0.col1 + col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 59 * col0 * ( - 60 ) AS col0 FROM tab2 AS cor0
----
24780
276120
279660

query I rowsort
SELECT DISTINCT - 49 AS col2 FROM tab0 AS cor0
----
-49

query I rowsort
SELECT ALL - - ( - col0 ) * - col2 AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + + col0 * + col2 - col0 * col2 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + + 99 - col2 AS col1 FROM tab1 cor0
----
3
42
45

query I rowsort
SELECT + + 26 * col0 FROM tab1 AS cor0
----
1664
2080
78

query I rowsort
SELECT ALL col1 + - 63 * + 5 FROM tab0 AS cor0
----
-218
-224
-229

onlyif mysql # use DIV operator for integer division
query I rowsort label-4904
SELECT DISTINCT col2 DIV col1 - - col1 * + col2 AS col2 FROM tab0 cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4904
SELECT DISTINCT col2 / col1 - - col1 * + col2 AS col2 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4905
SELECT ALL + - col2 + + col0 DIV col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-4905
SELECT ALL + - col2 + + col0 / col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT + col1 * ( - cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + col0 * ( + 17 ) FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT ALL - col0 + + ( + col2 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + 69 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + ( col2 ) col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + 60 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT DISTINCT + col0 * col2 * + 33 FROM tab2 AS cor0
----
6237
66924
99066

query I rowsort
SELECT col1 + + col2 * - 21 FROM tab2 AS cor0
----
-487
-536
-781

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4914
SELECT ALL + + cor0.col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4914
SELECT ALL + + cor0.col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + ( col0 ) AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL 34 AS col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

query I rowsort
SELECT ALL - tab0.col1 + + col0 AS col0 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT ALL 26 + col0 AS col1 FROM tab0 AS cor0
----
115
50
61

query I rowsort
SELECT + 61 * + col0 AS col0 FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT ALL - col1 + - ( col2 ) + - ( col0 ) AS col2 FROM tab1
----
-131
-189
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4921
SELECT - 72 + col1 DIV col1 + + 45 DIV col0 AS col0 FROM tab1 AS cor0
----
-56
-71
-71

skipif mysql # not compatible
query I rowsort label-4921
SELECT - 72 + col1 / col1 + + 45 / col0 AS col0 FROM tab1 AS cor0
----
-56
-71
-71

query I rowsort
SELECT 44 + col2 AS col1 FROM tab2
----
70
71
82

query I rowsort
SELECT col2 * + cor0.col2 + ( 63 ) AS col1 FROM tab1 AS cor0
----
2979
3312
9279

query I rowsort
SELECT ALL 37 * + col0 FROM tab2 AS cor0
----
259
2886
2923

query I rowsort
SELECT DISTINCT - - 57 + col0 * + 35 FROM tab2 AS cor0
----
2787
2822
302

query I rowsort
SELECT ALL + 46 AS col0 FROM tab1 cor0
----
46
46
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4927
SELECT - CAST( + col1 AS SIGNED ) AS col2 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4927
SELECT - CAST ( + col1 AS INTEGER ) AS col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT - - ( - col1 ) * + col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4929
SELECT - CAST( col2 AS SIGNED ) + col1 * - col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-4929
SELECT - CAST ( col2 AS INTEGER ) + col1 * - col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - - col1 + col0 * col2 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL + ( cor0.col2 ) + + col2 FROM tab2 AS cor0
----
52
54
76

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1, tab0 cor2
----
3645 values hashing to 6a63085e8cab6f97591fd0a6b6ffff07

query I rowsort
SELECT ALL 81 + col1 * ( 62 ) + + col2 FROM tab0 cor0
----
5446
5805
6096

query I rowsort
SELECT DISTINCT + col1 * + col1 * + ( + col0 * cor0.col0 ) FROM tab0 AS cor0
----
11526025
4260096
65593801

query I rowsort
SELECT ALL + cor1.col1 AS col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + col2 * + cor0.col2 + + 76 FROM tab1 AS cor0
----
2992
3325
9292

query I rowsort
SELECT + col0 * - col2 * ( + col0 ) + + col2 AS col0 FROM tab2
----
-1296
-158158
-237120

query I rowsort
SELECT DISTINCT 61 * col0 + col2 AS col1 FROM tab1
----
237
3961
4976

query I rowsort
SELECT + col0 * tab0.col0 + + col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT 84 + col1 AS col0 FROM tab0 AS cor0
----
170
175
181

query I rowsort
SELECT DISTINCT - - col0 * - col0 - - col1 AS col2 FROM tab2 cor0
----
-18
-6025
-6224

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4942
SELECT - CAST( NULL AS SIGNED ) * col2 + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4942
SELECT - CAST ( NULL AS INTEGER ) * col2 + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 65 + + col2 FROM tab1 cor0
----
119
122
161

onlyif mysql # use DIV operator for integer division
query I rowsort label-4944
SELECT + col2 DIV + col2 + col2 * tab0.col2 DIV + col0 AS col1 FROM tab0
----
1
46
76

skipif mysql # not compatible
query I rowsort label-4944
SELECT + col2 / + col2 + col2 * tab0.col2 / + col0 AS col1 FROM tab0
----
1
46
76

query I rowsort
SELECT col1 * + 43 AS col2 FROM tab1
----
1118
430
559

query I rowsort
SELECT ALL - col0 + - col1 AS col2 FROM tab2
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4947
SELECT - ( + col0 ) DIV col1 + tab1.col1 * - col1 col2 FROM tab1
----
-106
-175
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4947
SELECT - ( + col0 ) / col1 + tab1.col1 * - col1 col2 FROM tab1
----
-106
-175
-676

query I rowsort
SELECT DISTINCT ( - tab0.col2 ) + - tab0.col2 FROM tab0
----
-164
-2
-66

query I rowsort
SELECT col2 + - 39 FROM tab1
----
15
18
57

query I rowsort
SELECT DISTINCT ( + ( col0 ) ) + + col0 * col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT ( - 55 ) * col2 + 9 FROM tab0 AS cor0
----
-1806
-4501
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( + col2 ) * - col1 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ( col1 ) * - col1 + + tab1.col0 * - col0 + + col0 AS col2 FROM tab1
----
-4132
-6489
-682

query I rowsort
SELECT + 28 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT - 10 * - cor0.col2 FROM tab0 AS cor0
----
10
330
820

onlyif mysql # use DIV operator for integer division
query I rowsort label-4956
SELECT DISTINCT 6 DIV col1 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4956
SELECT DISTINCT 6 / col1 AS col0 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( tab0.col0 ) col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 * col0 - tab0.col2 col0 FROM tab0
----
1698
447
699

query I rowsort
SELECT - col0 * + col0 - cor0.col1 * cor0.col1 * - ( - ( - col2 ) ) FROM tab1 AS cor0
----
1604
36495
9824

query I rowsort
SELECT + - col2 + ( + col2 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + cor0.col2 + 28 * ( - col0 ) + - col0 AS col1 FROM tab1 AS cor0
----
-1799
-2224
-33

query I rowsort
SELECT + - col0 * col1 - ( + col2 + col2 ) * cor0.col1 FROM tab1 AS cor0
----
-1780
-2886
-3536

query I rowsort
SELECT - + col0 * 61 * + col0 AS col2 FROM tab1 AS cor0
----
-249856
-390400
-549

query I rowsort
SELECT ALL - cor0.col0 * - 68 * col1 + - col0 FROM tab2 AS cor0
----
14749
312858
91245

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * + col0 col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT col2 + 21 AS col2 FROM tab2 AS cor0
----
47
48
59

query I rowsort
SELECT DISTINCT col1 * - 97 FROM tab0 cor0
----
-8342
-8827
-9409

query I rowsort
SELECT - + cor0.col0 - + 83 FROM tab1 cor0
----
-147
-163
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4969
SELECT + + cor0.col1 * 24 + - 2 * + col1 + + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4969
SELECT + + cor0.col1 * 24 + - 2 * + col1 + + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 13 * 46 AS col2 FROM tab2
----
598

query I rowsort
SELECT - ( ( + col2 ) ) AS col1 FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 * - 34 col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 8acd96c6a7f1daa61157ac5567c916f5

query I rowsort
SELECT + 21 + 26 AS col1 FROM tab0
----
47
47
47

query I rowsort
SELECT DISTINCT tab1.col0 * 17 AS col1 FROM tab1
----
1088
1360
51

query I rowsort
SELECT DISTINCT ( + ( - col2 ) * + col0 ) FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 50 AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT DISTINCT 33 AS col0 FROM tab1 cor0
----
33

query I rowsort
SELECT cor0.col0 + col2 * + col1 AS col1 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - + 0 + - col0 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT 13 FROM tab1 cor0
----
13

query I rowsort
SELECT DISTINCT 55 * cor0.col0 AS col1 FROM tab2 AS cor0
----
385
4290
4345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + cor0.col1 col1 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4983
SELECT - 40 + - col1 * CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4983
SELECT - 40 + - col1 * CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4984
SELECT DISTINCT col1 DIV - col0 + 11 DIV col0 + - col1 * + col2 FROM tab0 AS cor0
----
-2841
-7463
-99

skipif mysql # not compatible
query I rowsort label-4984
SELECT DISTINCT col1 / - col0 + 11 / col0 + - col1 * + col2 FROM tab0 AS cor0
----
-2841
-7463
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4985
SELECT - cor0.col2 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4985
SELECT - cor0.col2 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4986
SELECT DISTINCT - - 90 + col2 DIV CAST( - col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
88
90

skipif mysql # not compatible
query I rowsort label-4986
SELECT DISTINCT - - 90 + col2 / CAST ( - col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
88
90

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab1 cor0 CROSS JOIN tab1, tab1 cor1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4988
SELECT - - col2 + + ( + col1 ) DIV col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4988
SELECT - - col2 + + ( + col1 ) / col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT - - col0 * col0 - 69 * col2 AS col0 FROM tab0 AS cor0
----
-1701
1156
2263

query I rowsort
SELECT + col2 * ( 54 ) + col2 AS col2 FROM tab2 AS cor0
----
1430
1485
2090

query I rowsort
SELECT ALL col2 * + col0 AS col1 FROM tab1 cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + - col1 * + 77 col2 FROM tab2 AS cor0
----
-1230
-2380
-4465

skipif mysql # not compatible
query I rowsort
SELECT + - col1 + - ( ( col1 ) * - CAST ( - 33 AS REAL ) + - col1 ) AS col1 FROM tab1 AS cor0
----
-330
-429
-858

onlyif mysql # use DIV operator for integer division
query I rowsort label-4994
SELECT DISTINCT - - cor0.col0 + col1 DIV - ( + col0 ) FROM tab2 AS cor0
----
3
78
79

skipif mysql # not compatible
query I rowsort label-4994
SELECT DISTINCT - - cor0.col0 + col1 / - ( + col0 ) FROM tab2 AS cor0
----
3
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4995
SELECT col1 + + col0 * cor0.col0 DIV col1 FROM tab1 AS cor0
----
26
419
505

skipif mysql # not compatible
query I rowsort label-4995
SELECT col1 + + col0 * cor0.col0 / col1 FROM tab1 AS cor0
----
26
419
505

onlyif mysql # use DIV operator for integer division
query I rowsort label-4996
SELECT ALL + - cor0.col1 + 33 DIV 47 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4996
SELECT ALL + - cor0.col1 + 33 / 47 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + + col1 - cor0.col2 * col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT col1 * - 72 FROM tab0 AS cor0
----
-6192
-6552
-6984

query I rowsort
SELECT DISTINCT 52 * col2 FROM tab2 AS cor0
----
1352
1404
1976

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5000
SELECT ALL - - CAST( NULL AS SIGNED ) + - 97 * col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5000
SELECT ALL - - CAST ( NULL AS INTEGER ) + - 97 * col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * - col0 col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + cor1.col1 * cor0.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 819d50aeaf27d8e4e8dec203fb8f53ce

query I rowsort
SELECT col2 + + ( - 84 + col1 * - col0 ) AS col1 FROM tab0
----
-2115
-3478
-8101

onlyif mysql # use DIV operator for integer division
query I rowsort label-5004
SELECT ALL col0 * cor0.col0 + + col2 DIV + 60 + 58 AS col0 FROM tab0 AS cor0
----
1283
634
7980

skipif mysql # not compatible
query I rowsort label-5004
SELECT ALL col0 * cor0.col0 + + col2 / + 60 + 58 AS col0 FROM tab0 AS cor0
----
1283
634
7980

query I rowsort
SELECT ALL + col0 * + col2 + + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + + 23 + - 47 FROM tab2 AS cor0
----
-24
-24
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 54 - - col0 col2 FROM tab2 AS cor0
----
1465
1482
2131

query I rowsort
SELECT ALL - 73 * 91 AS col0 FROM tab1 AS cor0
----
-6643
-6643
-6643

onlyif mysql # use DIV operator for integer division
query I rowsort label-5009
SELECT DISTINCT - + CAST( - ( + col2 ) AS SIGNED ) * 62 + + col2 DIV - col0 AS col1 FROM tab1 AS cor0
----
3330
3534
5951

skipif mysql # not compatible
query I rowsort label-5009
SELECT DISTINCT - + CAST ( - ( + col2 ) AS INTEGER ) * 62 + + col2 / - col0 AS col1 FROM tab1 AS cor0
----
3330
3534
5951

query I rowsort
SELECT DISTINCT + cor0.col2 + 47 AS col1 FROM tab2 AS cor0
----
73
74
85

query I rowsort
SELECT ALL cor0.col2 + col2 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT + ( cor0.col0 ) + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 77 col1 FROM tab0 AS cor0
----
77

query I rowsort
SELECT ALL + ( - 96 ) * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-2496
-2592
-3648

query I rowsort
SELECT + col2 + col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT + + ( - col2 ) + + col1 + ( col2 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL tab1.col1 * - 61 + - 40 * + col1 FROM tab1
----
-1010
-1313
-2626

query I rowsort
SELECT DISTINCT + ( col1 ) * col2 + col2 + + col0 AS col2 FROM tab1 AS cor0
----
1424
1461
691

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5019
SELECT ALL - CAST( col0 AS SIGNED ) * + col0 - + col1 FROM tab1 cor0
----
-35
-4106
-6413

skipif mysql # not compatible
query I rowsort label-5019
SELECT ALL - CAST ( col0 AS INTEGER ) * + col0 - + col1 FROM tab1 cor0
----
-35
-4106
-6413

query I rowsort
SELECT - + ( 80 ) FROM tab1 AS cor0
----
-80
-80
-80

query I rowsort
SELECT - col0 * 21 AS col1 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT DISTINCT 61 * col1 * col1 AS col0 FROM tab1
----
10309
41236
6100

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5023
SELECT DISTINCT + col0 * CAST( col2 AS SIGNED ) - col1 col2 FROM tab0 AS cor0
----
-62
706
7207

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5023
SELECT DISTINCT + col0 * CAST ( col2 AS INTEGER ) - col1 col2 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-5024
SELECT cor0.col0 * - col2 - col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
-190
-2029
-3003

skipif mysql # not compatible
query I rowsort label-5024
SELECT cor0.col0 * - col2 - col0 / + col0 AS col2 FROM tab2 AS cor0
----
-190
-2029
-3003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col0 - col2 col0 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT + col2 + + col0 + - 72 * - tab1.col0 FROM tab1
----
273
4729
5936

query I rowsort
SELECT DISTINCT + col0 + + col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT col1 * ( ( + col2 ) ) FROM tab2
----
1534
646
837

query I rowsort
SELECT + col2 + col0 * ( tab1.col2 ) FROM tab1
----
216
3705
7776

query I rowsort
SELECT col2 + - 78 + + col0 AS col2 FROM tab1
----
-21
43
98

query I rowsort
SELECT - cor0.col1 * + ( 58 * cor0.col2 ) + + 51 * - col1 AS col0 FROM tab2 AS cor0
----
-38335
-50127
-91981

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + - col1 col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col1 * col0 - + cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
-2609
-2838
-8176

query I rowsort
SELECT DISTINCT 79 * col1 FROM tab1
----
1027
2054
790

query I rowsort
SELECT + 85 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5036
SELECT - cor0.col1 DIV cor0.col0 + cor0.col1 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-5036
SELECT - cor0.col1 / cor0.col0 + cor0.col1 FROM tab2 AS cor0
----
17
27
59

query I rowsort
SELECT - 80 + col1 + + 84 FROM tab2
----
21
35
63

query I rowsort
SELECT - + cor0.col2 * - 63 AS col0 FROM tab1 AS cor0
----
3402
3591
6048

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 * - col2 col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT + col1 + + col1 * col2 FROM tab0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-5041
SELECT col2 * col0 + - col0 * col2 DIV col2 col1 FROM tab1
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5041
SELECT col2 * col0 + - col0 * col2 / col2 col1 FROM tab1
----
159
3584
7600

query I rowsort
SELECT DISTINCT col0 * + col0 + 79 FROM tab1 AS cor0
----
4175
6479
88

query I rowsort
SELECT + cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5044
SELECT ALL CAST( NULL AS DECIMAL ) + + 86 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5044
SELECT ALL CAST ( NULL AS REAL ) + + 86 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + col1 * col1 FROM tab0 cor0
----
7420
8370
9444

query I rowsort
SELECT - cor0.col1 * + cor0.col2 + - col1 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - ( + 42 ) FROM tab2
----
-42
-42
-42

query I rowsort
SELECT + 70 * col0 * + tab2.col1 FROM tab2
----
15190
322140
94010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5049
SELECT ( - 47 ) DIV + col1 col1 FROM tab2
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5049
SELECT ( - 47 ) / + col1 col1 FROM tab2
----
-1
-2
0

query I rowsort
SELECT DISTINCT - col0 + - 81 FROM tab1
----
-145
-161
-84

query I rowsort
SELECT DISTINCT - col1 * + tab1.col0 * col1 + ( + col1 ) * col0 AS col2 FROM tab1
----
-12480
-1950
-5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5052
SELECT ALL - col0 DIV + col0 + col2 * - col0 FROM tab2
----
-190
-2029
-3003

skipif mysql # not compatible
query I rowsort label-5052
SELECT ALL - col0 / + col0 + col2 * - col0 FROM tab2
----
-190
-2029
-3003

query I rowsort
SELECT + col2 * col1 * + tab0.col2 FROM tab0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5054
SELECT - col2 + col1 DIV + 85 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5054
SELECT - col2 + col1 / + 85 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + 72 * col1 + + 61 AS col2 FROM tab2 AS cor0
----
1285
2293
4309

query I rowsort
SELECT ALL col0 * col0 + 75 AS col2 FROM tab1 AS cor0
----
4171
6475
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 64 - + col2 col1 FROM tab1 AS cor0
----
-32
10
7

query I rowsort
SELECT + col0 * - col0 * 9 AS col0 FROM tab2 AS cor0
----
-441
-54756
-56169

query I rowsort
SELECT ALL + cor1.col2 * cor1.col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to f8894e3f33962cda5901e1c2ce65d5b0

query I rowsort
SELECT + 41 + + col0 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT - col0 * + col0 - + col2 * - 98 FROM tab2 AS cor0
----
-2517
-3536
2597

query I rowsort
SELECT col2 * col2 * col1 AS col1 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5063
SELECT ( tab0.col0 ) DIV - 18 FROM tab0
----
-1
-1
-4

skipif mysql # not compatible
query I rowsort label-5063
SELECT ( tab0.col0 ) / - 18 FROM tab0
----
-1
-1
-4

query I rowsort
SELECT DISTINCT col1 * cor0.col1 AS col1 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT + col2 + col0 * + col0 AS col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL col2 + 85 * - col2 AS col2 FROM tab2 AS cor0
----
-2184
-2268
-3192

onlyif mysql # use DIV operator for integer division
query I rowsort label-5067
SELECT DISTINCT cor0.col2 + 69 DIV + col0 AS col2 FROM tab2 AS cor0
----
26
36
38

skipif mysql # not compatible
query I rowsort label-5067
SELECT DISTINCT cor0.col2 + 69 / + col0 AS col2 FROM tab2 AS cor0
----
26
36
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5068
SELECT + col1 + + CAST( + col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-5068
SELECT + col1 + + CAST ( + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col2 - col2 col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col2 * col1 * - 85 - - col2 AS col1 FROM tab1
----
106176
119394
48507

query I rowsort
SELECT - 1 * col2 + + col0 - tab1.col0 AS col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL 99 * col0 - - col1 AS col1 FROM tab2
----
724
7781
7838

query I rowsort
SELECT ( tab2.col2 ) * ( + col2 ) - col1 * col1 AS col1 FROM tab2
----
-232
-2805
1155

query I rowsort
SELECT col1 * + 5 * + col0 AS col1 FROM tab1 AS cor0
----
3200
390
5200

query I rowsort
SELECT - col1 + - col1 * cor0.col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT + 19 * - col0 AS col2 FROM tab1 AS cor0
----
-1216
-1520
-57

query I rowsort
SELECT ALL + col0 * - 61 FROM tab0 AS cor0
----
-1464
-2135
-5429

query I rowsort
SELECT DISTINCT + col0 + + col0 * col1 * + col2 AS col0 FROM tab1
----
36544
4215
99920

query I rowsort
SELECT DISTINCT - col2 * col1 * + col0 AS col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5080
SELECT CAST( - 91 AS SIGNED ) FROM tab1, tab2 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

skipif mysql # not compatible
query I rowsort label-5080
SELECT CAST ( - 91 AS INTEGER ) FROM tab1, tab2 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

onlyif mysql # use DIV operator for integer division
query I rowsort label-5081
SELECT ALL col1 DIV + ( + 8 + col0 ) AS col2 FROM tab1
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5081
SELECT ALL col1 / + ( + 8 + col0 ) AS col2 FROM tab1
----
0
0
2

query I rowsort
SELECT - - ( + col1 ) * col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-5083
SELECT + col1 + col2 DIV - col2 AS col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-5083
SELECT + col1 + col2 / - col2 AS col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - ( + col2 ) * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 18 * col0 * + col1 AS col0 FROM tab2 cor0
----
24174
3906
82836

query I rowsort
SELECT - + 81 AS col2 FROM tab0 cor0
----
-81
-81
-81

query I rowsort
SELECT - col1 * - cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 58 * col0 col2 FROM tab0 cor0
----
1392
2030
5162

query I rowsort
SELECT ALL ( 94 ) AS col2 FROM tab2 AS cor0
----
94
94
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + ( - col1 * + col2 ) col2 FROM tab0
----
-611884
-93654
-97

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) + - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 15 + tab1.col0 FROM tab1
----
18
79
95

query I rowsort
SELECT DISTINCT - 10 * 9 * col0 AS col0 FROM tab2
----
-630
-7020
-7110

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5094
SELECT CAST( + ( + col0 ) * - ( - ( + col1 ) ) AS SIGNED ) FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5094
SELECT CAST ( + ( + col0 ) * - ( - ( + col1 ) ) AS INTEGER ) FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5095
SELECT DISTINCT - ( 87 ) * col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5095
SELECT DISTINCT - ( 87 ) * col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL

query I rowsort
SELECT - ( 56 ) FROM tab2 AS cor0
----
-56
-56
-56

query I rowsort
SELECT DISTINCT ( ( cor0.col2 ) ) * col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col1 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ( cor0.col1 ) + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - + ( col1 ) + + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - 37 + - 31 * col0 * - col0 FROM tab1
----
126939
198363
242

query I rowsort
SELECT ALL - col0 * - col1 - col2 AS col1 FROM tab2
----
1305
190
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col0 FROM tab2, tab1, tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5104
SELECT ALL - col2 DIV - col1 + + 51 * col1 - col2 * - ( - col1 ) FROM tab1
----
-55
-578
-76

skipif mysql # not compatible
query I rowsort label-5104
SELECT ALL - col2 / - col1 + + 51 * col1 - col2 * - ( - col1 ) FROM tab1
----
-55
-578
-76

query I rowsort
SELECT - cor0.col0 - 30 FROM tab2 AS cor0
----
-108
-109
-37

query I rowsort
SELECT DISTINCT col0 + 85 FROM tab0 AS cor0
----
109
120
174

query I rowsort
SELECT col0 + col1 + - col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - - col2 * ( col1 ) + - cor0.col0 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL - col1 * ( col2 ) + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - tab1.col2 * cor0.col1 + - tab1.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 786c04feb034b96d7b4f48a7a4cd6beb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 16 col2 FROM tab2 AS cor0
----
272
496
944

query I rowsort
SELECT - + col0 * + col2 - - 71 FROM tab1 AS cor0
----
-3577
-7609
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-5114
SELECT ALL + col2 DIV col1 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5114
SELECT ALL + col2 / col1 FROM tab2 cor0
----
0
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5115
SELECT col2 DIV col2 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5115
SELECT col2 / col2 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT DISTINCT - col0 * - col0 * col1 AS col0 FROM tab1 AS cor0
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + 51 col0 FROM tab2 AS cor0
----
77
78
89

query I rowsort
SELECT - col0 + + col1 + col0 * + col2 * ( col0 * - col2 ) AS col0 FROM tab2 AS cor0
----
-35697
-4112803
-9012066

query I rowsort
SELECT + + col2 + - col1 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + col1 * col0 * - col1 AS col0 FROM tab1
----
-13520
-2028
-6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-5121
SELECT DISTINCT + col1 DIV + col1 AS col1 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-5121
SELECT DISTINCT + col1 / + col1 AS col1 FROM tab0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5122
SELECT col0 * CAST( NULL AS SIGNED ) + + tab1.col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5122
SELECT col0 * CAST ( NULL AS INTEGER ) + + tab1.col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 + + 98 * + 32 AS col0 FROM tab1 AS cor0
----
3110
3123
3126

query I rowsort
SELECT ALL - col0 + cor0.col1 + col1 FROM tab0 cor0
----
148
159
93

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab0, tab2 AS cor0
----
92

query I rowsort
SELECT DISTINCT - - cor0.col2 + col1 * + col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT + 59 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT - 50 + col1 + col2 FROM tab1 AS cor0
----
17
30
59

query I rowsort
SELECT + 0 + + cor0.col2 * col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + + 23 * col1 + - col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT 27 * + 76 * col1 AS col0 FROM tab1
----
20520
26676
53352

query I rowsort
SELECT ALL + tab2.col1 * 53 + 66 FROM tab2
----
1709
3193
967

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * ( + cor0.col0 ) + col2 + col1 col0 FROM tab1 AS cor0
----
1149
158
707

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col2 col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + col0 * - col2 + + col2 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT 63 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5137
SELECT ALL - CAST( NULL AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5137
SELECT ALL - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - - 70 AS col2 FROM tab1 cor0
----
70
70
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5139
SELECT ALL + cor0.col0 + col0 DIV + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5139
SELECT ALL + cor0.col0 + col0 / + col0 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5140
SELECT DISTINCT + + 14 * col1 + CAST( col1 + - col2 AS SIGNED ) AS col1 FROM tab0 cor0
----
1257
1283
1454

skipif mysql # not compatible
query I rowsort label-5140
SELECT DISTINCT + + 14 * col1 + CAST ( col1 + - col2 AS INTEGER ) AS col1 FROM tab0 cor0
----
1257
1283
1454

query I rowsort
SELECT DISTINCT + cor0.col1 + + col2 * col0 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + 78 * col0 AS col1 FROM tab2 AS cor0
----
546
6084
6162

query I rowsort
SELECT + col2 - - 71 FROM tab2 AS cor0
----
109
97
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5144
SELECT + cor0.col1 - - CAST( col2 AS SIGNED ) * - col2 col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5144
SELECT + cor0.col1 - - CAST ( col2 AS INTEGER ) * - col2 col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT - col1 * col0 + col0 * col0 FROM tab0 cor0
----
-1488
-178
-2170

onlyif mysql # use DIV operator for integer division
query I rowsort label-5146
SELECT col2 + + col2 DIV - cor0.col0 FROM tab2 cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-5146
SELECT col2 + + col2 / - cor0.col0 FROM tab2 cor0
----
24
26
38

query I rowsort
SELECT ALL + - col0 * + col0 * 23 FROM tab0 AS cor0
----
-13248
-182183
-28175

query I rowsort
SELECT DISTINCT + 23 + - cor0.col2 * ( - cor0.col1 ) FROM tab1 cor0
----
1271
1427
593

onlyif mysql # use DIV operator for integer division
query I rowsort label-5149
SELECT DISTINCT + + col1 + col0 DIV + col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-5149
SELECT DISTINCT + + col1 + col0 / + col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT + 42 * + cor0.col1 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT ALL - col0 - cor0.col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - 76 + - col0 AS col0 FROM tab2 AS cor0
----
-154
-155
-83

query I rowsort
SELECT + col0 * - col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - 79 * + col1 AS col0 FROM tab1
----
-1027
-2054
-790

query I rowsort
SELECT DISTINCT + 69 FROM tab1, tab2 cor0
----
69

query I rowsort
SELECT DISTINCT 71 * - col1 AS col2 FROM tab0
----
-6106
-6461
-6887

query I rowsort
SELECT - ( tab0.col0 * col2 ) FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 + 50 ) col1 FROM tab1
----
60
63
76

query I rowsort
SELECT DISTINCT - tab2.col1 FROM tab2, tab0 cor0
----
-17
-31
-59

query I rowsort
SELECT 20 - col0 FROM tab1 AS cor0
----
-44
-60
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + cor0.col2 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col2 * - 49 AS col0 FROM tab0
----
1617
4018
49

query I rowsort
SELECT ALL + - col2 * - 18 + + col0 FROM tab2 AS cor0
----
493
546
763

onlyif mysql # use DIV operator for integer division
query I rowsort label-5164
SELECT + col2 DIV + 37 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5164
SELECT + col2 / + 37 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT 95 * + col2 FROM tab1 cor0
----
5130
5415
9120

query I rowsort
SELECT + ( + 22 ) * col1 * - col2 AS col2 FROM tab1 AS cor0
----
-12540
-27456
-30888

query I rowsort
SELECT DISTINCT ( - 86 ) * - col2 + col0 FROM tab0 cor0
----
121
2862
7141

query I rowsort
SELECT DISTINCT + col1 * - col1 * col0 + - ( - col2 ) FROM tab1 AS cor0
----
-13424
-1974
-6343

query I rowsort
SELECT DISTINCT col0 + col1 * col1 + + col2 * col0 AS col2 FROM tab2 AS cor0
----
1157
3370
5587

query I rowsort
SELECT ALL + col0 - - col0 * - col0 AS col1 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT - - 67 AS col2 FROM tab1 cor0
----
67
67
67

query I rowsort
SELECT DISTINCT + 80 FROM tab2 AS cor0
----
80

query I rowsort
SELECT DISTINCT 7 AS col2 FROM tab0 AS cor0
----
7

query I rowsort
SELECT 87 * - col2 + col2 FROM tab2 AS cor0
----
-2236
-2322
-3268

query I rowsort
SELECT DISTINCT + 91 + - col2 FROM tab1 AS cor0
----
-5
34
37

query I rowsort
SELECT DISTINCT col1 + + col2 * + 62 FROM tab2 AS cor0
----
1671
1705
2373

query I rowsort
SELECT ALL - - col1 * + col0 + - cor0.col0 * cor0.col2 FROM tab0 AS cor0
----
1272
3360
801

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * + col1 + + 37 col1 FROM tab0 AS cor0
----
-2801
-60
-7425

query I rowsort
SELECT DISTINCT col2 + + col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT tab1.col1 + + 78 FROM tab1
----
104
88
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-5181
SELECT - tab0.col0 DIV - col2 + - col1 AS col2 FROM tab0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-5181
SELECT - tab0.col0 / - col2 + - col1 AS col2 FROM tab0
----
-62
-86
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5182
SELECT DISTINCT - - col2 - + ( col0 ) DIV col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5182
SELECT DISTINCT - - col2 - + ( col0 ) / col0 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT ALL + + col1 + - col0 * + col1 + - col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + col1 * + 1 + col0 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5185
SELECT DISTINCT - ( + col0 ) * + col2 + + CAST( col0 AS SIGNED ) * + col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5185
SELECT DISTINCT - ( + col0 ) * + col2 + + CAST ( col0 AS INTEGER ) * + col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + cor0.col2 col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + 54 FROM tab2, tab0 cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT ALL + + 32 * ( col0 ) AS col2 FROM tab1 AS cor0
----
2048
2560
96

query I rowsort
SELECT DISTINCT ( ( col1 ) ) + col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL - ( - col0 ) + - cor0.col0 * col2 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - + 72 AS col0 FROM tab0 AS cor0
----
-72
-72
-72

query I rowsort
SELECT DISTINCT + col1 * col0 + + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 53 ) * cor0.col1 col1 FROM tab1 AS cor0
----
-1378
-530
-689

onlyif mysql # use DIV operator for integer division
query I rowsort label-5194
SELECT col0 DIV - ( - col0 * - ( + col1 ) ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5194
SELECT col0 / - ( - col0 * - ( + col1 ) ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 + 87 * + col2 FROM tab0 AS cor0
----
122
2895
7223

query I rowsort
SELECT ALL - col0 + + 65 FROM tab1
----
-15
1
62

query I rowsort
SELECT - col2 - col1 * 30 AS col0 FROM tab0
----
-2613
-2812
-2911

onlyif mysql # use DIV operator for integer division
query I rowsort label-5198
SELECT DISTINCT ( col1 ) + col0 DIV + 66 FROM tab0 AS cor0
----
86
92
97

skipif mysql # not compatible
query I rowsort label-5198
SELECT DISTINCT ( col1 ) + col0 / + 66 FROM tab0 AS cor0
----
86
92
97

query I rowsort
SELECT ALL + + col1 * col1 + - col0 * - col2 AS col2 FROM tab2 AS cor0
----
1150
3291
5509

onlyif mysql # use DIV operator for integer division
query I rowsort label-5200
SELECT - 78 DIV + 66 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-5200
SELECT - 78 / + 66 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT DISTINCT tab2.col1 + - col0 * - 54 AS col1 FROM tab2
----
409
4271
4283

query I rowsort
SELECT + col2 + - col1 * + tab2.col0 * col2 AS col1 FROM tab2
----
-119626
-50996
-5832

query I rowsort
SELECT DISTINCT + + col0 + + col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + ( + cor0.col1 ) + - col2 * - 77 FROM tab0 AS cor0
----
174
2627
6405

query I rowsort
SELECT ALL - 90 * col0 - col2 AS col1 FROM tab2 AS cor0
----
-657
-7046
-7148

query I rowsort
SELECT DISTINCT col0 * col0 - - 1 FROM tab0 cor0
----
1226
577
7922

query I rowsort
SELECT - - 26 + cor0.col2 AS col2 FROM tab0 AS cor0
----
108
27
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5208
SELECT - col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5208
SELECT - col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5209
SELECT DISTINCT col2 DIV + tab1.col0 + - ( + ( col1 ) + - 35 ) FROM tab1
----
23
25
27

skipif mysql # not compatible
query I rowsort label-5209
SELECT DISTINCT col2 / + tab1.col0 + - ( + ( col1 ) + - 35 ) FROM tab1
----
23
25
27

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 * ( col2 ) + col2 * - CAST ( ( col2 ) * + 13 AS REAL ) AS col2 FROM tab0 cor0
----
-110
-16995
-94874

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5211
SELECT - col2 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5211
SELECT - col2 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5212
SELECT ALL cor0.col1 DIV - col0 + - ( col0 ) + + col2 AS col2 FROM tab1 AS cor0
----
-7
16
43

skipif mysql # not compatible
query I rowsort label-5212
SELECT ALL cor0.col1 / - col0 + - ( col0 ) + + col2 AS col2 FROM tab1 AS cor0
----
-7
16
43

query I rowsort
SELECT DISTINCT - 78 + - col0 AS col0 FROM tab1
----
-142
-158
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col2 col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # use DIV operator for integer division
query I rowsort label-5215
SELECT col0 DIV col2 + - col2 FROM tab0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-5215
SELECT col0 / col2 + - col2 FROM tab0
----
-33
-81
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5216
SELECT ALL ( col0 ) DIV + col2 + 93 FROM tab0
----
128
93
94

skipif mysql # not compatible
query I rowsort label-5216
SELECT ALL ( col0 ) / + col2 + 93 FROM tab0
----
128
93
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + 84 * + col1 col0 FROM tab2 cor0
----
1445
2635
5015

query I rowsort
SELECT + 12 * + 17 AS col2 FROM tab1 AS cor0
----
204
204
204

query I rowsort
SELECT DISTINCT 97 + 52 AS col0 FROM tab0 AS cor0
----
149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 80 col2 FROM tab2 AS cor0
----
80
80
80

query I rowsort
SELECT ALL 79 * + col0 - cor0.col1 AS col2 FROM tab1 AS cor0
----
211
5046
6307

query I rowsort
SELECT + - col0 + cor0.col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + 81 * - cor0.col2 - col2 FROM tab2 AS cor0
----
-2132
-2214
-3116

query I rowsort
SELECT + + 23 * 59 AS col0 FROM tab0 AS cor0
----
1357
1357
1357

query I rowsort
SELECT ALL + 74 * 53 FROM tab2 AS cor0
----
3922
3922
3922

query I rowsort
SELECT - ( - cor0.col2 ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - 47 + - col2 * col1 FROM tab1 cor0
----
-1295
-1451
-617

query I rowsort
SELECT + col2 + - 23 AS col0 FROM tab2 AS cor0
----
15
3
4

query I rowsort
SELECT ALL - col2 * - 24 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT ALL tab0.col0 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - tab1.col1 * - col0 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT - col2 * - ( - col0 ) AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - 92 * + col1 FROM tab2 AS cor0
----
-1564
-2852
-5428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5234
SELECT DISTINCT + ( - col2 ) - - col1 * + CAST( NULL AS DECIMAL ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5234
SELECT DISTINCT + ( - col2 ) - - col1 * + CAST ( NULL AS REAL ) FROM tab0
----
NULL

query I rowsort
SELECT 36 + tab0.col2 AS col1 FROM tab0
----
118
37
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5236
SELECT + + CAST( - 96 AS SIGNED ) FROM tab1 AS cor0
----
-96
-96
-96

skipif mysql # not compatible
query I rowsort label-5236
SELECT + + CAST ( - 96 AS INTEGER ) FROM tab1 AS cor0
----
-96
-96
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 72 ) * + cor0.col2 col2 FROM tab2 AS cor0
----
-1872
-1944
-2736

query I rowsort
SELECT ALL 20 + - col0 * col0 AS col0 FROM tab0 cor0
----
-1205
-556
-7901

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5239
SELECT DISTINCT + + CAST( + cor0.col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5239
SELECT DISTINCT + + CAST ( + cor0.col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5240
SELECT ALL - ( col0 ) DIV - col0 col2 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5240
SELECT ALL - ( col0 ) / - col0 col2 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 39 ) * + col0 col1 FROM tab1 AS cor0
----
117
2496
3120

query I rowsort
SELECT DISTINCT - 78 + tab1.col2 * + tab1.col1 AS col0 FROM tab1
----
1170
1326
492

query I rowsort
SELECT - col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + 64 * col2 AS col2 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT ALL - 99 * - ( col0 ) FROM tab1
----
297
6336
7920

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to f7e57a354e4e5925116b9650d1011609

query I rowsort
SELECT DISTINCT 82 AS col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
82

query I rowsort
SELECT DISTINCT 84 * col0 AS col1 FROM tab1
----
252
5376
6720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5249
SELECT - CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5249
SELECT - CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + - col1 * col2 + - col1 * - 17 AS col0 FROM tab0 AS cor0
----
-1376
-5915
1552

query I rowsort
SELECT + col2 + col0 * + col2 * 82 - + col2 AS col0 FROM tab2 AS cor0
----
15498
166296
246164

query I rowsort
SELECT - 92 * + col0 FROM tab2 cor0
----
-644
-7176
-7268

query I rowsort
SELECT ALL - 42 * - col2 AS col0 FROM tab1 cor0
----
2268
2394
4032

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 95 * col0 * col2 - - col1 col2 FROM tab0 AS cor0
----
-3228
-693219
-75154

query I rowsort
SELECT ALL - col1 * col1 + col0 AS col0 FROM tab2 AS cor0
----
-210
-3403
-954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + - col0 * + col1 col2 FROM tab1 AS cor0
----
-545
-945
17

query I rowsort
SELECT DISTINCT 37 + + col0 FROM tab2 AS cor0
----
115
116
44

query I rowsort
SELECT - 88 + 73 FROM tab1, tab2 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5259
SELECT - col2 DIV cor0.col0 + col2 FROM tab0 AS cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-5259
SELECT - col2 / cor0.col0 + col2 FROM tab0 AS cor0
----
1
32
82

query I rowsort
SELECT DISTINCT - col2 + - 63 FROM tab2 AS cor0
----
-101
-89
-90

query I rowsort
SELECT DISTINCT col2 + + col2 AS col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + + col0 * - col2 * - 71 + col0 * + ( cor0.col1 ) + - cor0.col0 AS col2 FROM tab0 AS cor0
----
526168
58272
5845

query I rowsort
SELECT ALL + col1 - + 13 AS col2 FROM tab0 cor0
----
73
78
84

query I rowsort
SELECT ALL - cor0.col2 * 26 * + col1 AS col2 FROM tab0 AS cor0
----
-194012
-2522
-73788

query I rowsort
SELECT DISTINCT - col2 + cor0.col1 * col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT - - col1 * - col0 + - col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT + col2 + - ( + col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT + col0 + cor0.col0 * 66 * col1 FROM tab1 AS cor0
----
42304
5151
68720

query I rowsort
SELECT ALL + - col2 + + 45 AS col2 FROM tab0 AS cor0
----
-37
12
44

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 - 96 * - col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
128928
20832
441792

query I rowsort
SELECT 82 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + ( cor0.col0 ) + cor0.col1 * + col1 AS col2 FROM tab2 AS cor0
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 93 col0 FROM tab1 AS cor0
----
-93
-93
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col2 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col0 + + 2 FROM tab2 AS cor0
----
80
81
9

query I rowsort
SELECT DISTINCT - - col2 + + col2 AS col1 FROM tab1 cor0
----
108
114
192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5278
SELECT + cor0.col1 - + 89 * ( cor0.col1 * CAST( + 82 AS SIGNED ) ) col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ca7f4d84fa1f1fa2e92782ee62ebdf70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5278
SELECT + cor0.col1 - + 89 * ( cor0.col1 * CAST ( + 82 AS INTEGER ) ) col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ca7f4d84fa1f1fa2e92782ee62ebdf70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5279
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) * cor0.col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5279
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) * cor0.col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col0 * 98 * + ( + col0 * - col1 ) FROM tab0 AS cor0
----
-11644850
-4854528
-70639478

query I rowsort
SELECT ALL + col1 * 40 - ( cor0.col2 * + col2 + - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-2995
2375
3914

query I rowsort
SELECT + 76 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT DISTINCT - ( - col0 ) - + col0 FROM tab0 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 6 + cor0.col0 col0 FROM tab2 AS cor0
----
1
72
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5285
SELECT - ( + col0 ) * col2 - + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5285
SELECT - ( + col0 ) * col2 - + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 55 + - col0 AS col0 FROM tab0 AS cor0
----
-34
20
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col0 + col1 col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT col0 * - tab2.col1 - 59 FROM tab2
----
-1402
-276
-4661

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5290
SELECT - 75 DIV col1 AS col0 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-5290
SELECT - 75 / col1 AS col0 FROM tab2 AS cor0
----
-1
-2
-4

query I rowsort
SELECT ALL + ( - 77 ) * - cor1.col0 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to a6f8fefb781d297b2edd0462b31c8162

query I rowsort
SELECT 40 * - col2 AS col0 FROM tab1 AS cor0
----
-2160
-2280
-3840

query I rowsort
SELECT + 8 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT + 25 * col1 + 3 FROM tab1
----
253
328
653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5295
SELECT ALL - - col2 + + CAST( col1 AS SIGNED ) * + col1 FROM tab1 AS cor0
----
157
265
730

skipif mysql # not compatible
query I rowsort label-5295
SELECT ALL - - col2 + + CAST ( col1 AS INTEGER ) * + col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL 23 + + tab2.col0 FROM tab2
----
101
102
30

query I rowsort
SELECT tab0.col2 + - 2 FROM tab0
----
-1
31
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5298
SELECT cor0.col2 DIV - ( + ( - col1 ) * - 70 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5298
SELECT cor0.col2 / - ( + ( - col1 ) * - 70 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * 64 AS col1 FROM tab2 AS cor0
----
-1664
-1728
-2432

onlyif mysql # use DIV operator for integer division
query I rowsort label-5300
SELECT + + cor0.col0 DIV cor0.col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5300
SELECT + + cor0.col0 / cor0.col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col0 * - 10 * + col1 FROM tab1 AS cor0
----
10400
6400
780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5302
SELECT DISTINCT + col1 * CAST( col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-5302
SELECT DISTINCT + col1 * CAST ( col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - cor0.col0 * + col2 * + col2 AS col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-5304
SELECT + cor0.col0 DIV ( 43 * cor0.col2 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5304
SELECT + cor0.col0 / ( 43 * cor0.col2 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5305
SELECT ALL col2 - + col0 DIV col1 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5305
SELECT ALL col2 - + col0 / col1 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT + - cor0.col2 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5307
SELECT - CAST( - 32 AS SIGNED ) - col1 * - 67 AS col0 FROM tab1 cor0
----
1774
702
903

skipif mysql # not compatible
query I rowsort label-5307
SELECT - CAST ( - 32 AS INTEGER ) - col1 * - 67 AS col0 FROM tab1 cor0
----
1774
702
903

query I rowsort
SELECT - + 37 + - 5 * + col1 FROM tab0 AS cor0
----
-467
-492
-522

query I rowsort
SELECT + + 40 - 62 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT 77 + col1 AS col0 FROM tab0 AS cor0
----
163
168
174

query I rowsort
SELECT DISTINCT - + 32 + - col2 FROM tab1 AS cor0
----
-128
-86
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5312
SELECT - col0 DIV - col1 AS col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5312
SELECT - col0 / - col1 AS col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL + + col1 * col2 * + ( 27 ) FROM tab1 cor0
----
15390
33696
37908

query I rowsort
SELECT col1 * - col0 + ( - cor0.col0 ) + col2 FROM tab0 AS cor0
----
-2055
-3429
-8106

query I rowsort
SELECT DISTINCT + 39 AS col0 FROM tab0, tab2 AS cor0
----
39

query I rowsort
SELECT + 25 * + col1 FROM tab1
----
250
325
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-5317
SELECT + ( col2 ) DIV + col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5317
SELECT + ( col2 ) / + col0 FROM tab1
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 24 + cor0.col0 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to ebca1877f4de90b0ca7747d24c989e70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5319
SELECT - - ( - col0 ) DIV ( 8 ) + + col2 * cor0.col1 + + cor0.col2 FROM tab2 cor0
----
1551
675
864

skipif mysql # not compatible
query I rowsort label-5319
SELECT - - ( - col0 ) / ( 8 ) + + col2 * cor0.col1 + + cor0.col2 FROM tab2 cor0
----
1551
675
864

query I rowsort
SELECT DISTINCT + col1 * col0 + + col2 + - col0 FROM tab0 AS cor0
----
2073
3361
8092

skipif mysql # not compatible
query I rowsort
SELECT + 5 * col0 + - CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
34
354
78

query I rowsort
SELECT 65 * cor0.col0 + + cor0.col1 * col0 + col0 AS col1 FROM tab2 AS cor0
----
6557
679
9750

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5323
SELECT DISTINCT + CAST( NULL AS SIGNED ) + 13 col2 FROM tab2, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5323
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 13 col2 FROM tab2, tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5324
SELECT tab2.col0 DIV 75 + col2 AS col0 FROM tab2
----
27
27
39

skipif mysql # not compatible
query I rowsort label-5324
SELECT tab2.col0 / 75 + col2 AS col0 FROM tab2
----
27
27
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5325
SELECT col1 * + CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5325
SELECT col1 * + CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col2 * - col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT DISTINCT col0 + col0 + cor0.col0 FROM tab2 AS cor0
----
21
234
237

onlyif mysql # use DIV operator for integer division
query I rowsort label-5328
SELECT col2 + cor0.col1 DIV + cor0.col1 AS col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-5328
SELECT col2 + cor0.col1 / + cor0.col1 AS col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT DISTINCT + col1 + + ( col1 ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL col2 * + 20 FROM tab2 AS cor0
----
520
540
760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5331
SELECT + - col2 * CAST( NULL AS SIGNED ) * - cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5331
SELECT + - col2 * CAST ( NULL AS INTEGER ) * - cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 6 AS col1 FROM tab1, tab1 cor0
----
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5333
SELECT + ( + col1 ) - cor0.col0 * CAST( NULL AS SIGNED ) * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5333
SELECT + ( + col1 ) - cor0.col0 * CAST ( NULL AS INTEGER ) * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * + col2 + - col0 * col0 + - col0 AS col0 FROM tab2 AS cor0
----
-4628
-5674
781

query I rowsort
SELECT DISTINCT - + col0 * ( - col1 ) - - 83 FROM tab2 AS cor0
----
1426
300
4685

query I rowsort
SELECT - col2 * 52 + col0 FROM tab1 AS cor0
----
-2805
-2900
-4912

query I rowsort
SELECT DISTINCT col2 * - col2 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + ( - col2 ) col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5339
SELECT - ( + 66 + col1 ) DIV CAST( col1 AS SIGNED ) FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5339
SELECT - ( + 66 + col1 ) / CAST ( col1 AS INTEGER ) FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT 21 * 70 FROM tab2
----
1470

query I rowsort
SELECT DISTINCT + ( col0 ) * - col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 23 * + col2 FROM tab0 AS cor0
----
1886
23
759

query I rowsort
SELECT - cor0.col2 - - col1 FROM tab0 cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5344
SELECT ALL + 71 DIV - col0 AS col2 FROM tab0
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-5344
SELECT ALL + 71 / - col0 AS col2 FROM tab0
----
-2
-2
0

query I rowsort
SELECT - cor0.col1 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 56 * col0 col2 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT col1 + + tab2.col1 FROM tab2
----
118
34
62

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5349
SELECT col0 + col0 DIV + col1 AS col2 FROM tab1
----
3
70
86

skipif mysql # not compatible
query I rowsort label-5349
SELECT col0 + col0 / + col1 AS col2 FROM tab1
----
3
70
86

query I rowsort
SELECT + + 44 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT + col1 + cor0.col2 * - 21 FROM tab0 AS cor0
----
-1631
-607
76

query I rowsort
SELECT DISTINCT + 94 * + cor0.col0 + col0 * - col1 AS col1 FROM tab1 AS cor0
----
204
5376
6480

query I rowsort
SELECT - col1 * - col2 * + col2 AS col0 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5354
SELECT ALL - col0 * 84 DIV col2 FROM tab0 AS cor0
----
-2940
-61
-91

skipif mysql # not compatible
query I rowsort label-5354
SELECT ALL - col0 * 84 / col2 FROM tab0 AS cor0
----
-2940
-61
-91

query I rowsort
SELECT DISTINCT + col0 * + col0 + - col2 AS col1 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT 20 + - col1 FROM tab1
----
-6
10
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 10 * + col0 + 29 col1 FROM tab1
----
59
669
829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 + - col1 * tab2.col1 col1 FROM tab2
----
-244
-3436
-916

query I rowsort
SELECT DISTINCT - ( + col2 ) * col2 AS col0 FROM tab0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort
SELECT - col1 * CAST ( col1 AS REAL ) FROM tab1 AS cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5361
SELECT ALL + cor0.col2 DIV col0 AS col1 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5361
SELECT ALL + cor0.col2 / col0 AS col1 FROM tab0 cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT + col1 * ( + col1 * + col2 ) FROM tab2
----
10982
25947
90506

query I rowsort
SELECT ALL - col0 * - ( + col0 ) FROM tab2
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5365
SELECT - CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5365
SELECT - CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT + 5 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT DISTINCT - tab2.col1 FROM tab2, tab1, tab0 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col2 * - 21 FROM tab0
----
-1722
-21
-693

query I rowsort
SELECT + + ( + cor0.col0 ) + + col1 + col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - col0 * - col0 + - 58 * col2 + col1 AS col1 FROM tab0 cor0
----
-1252
1264
3256

query I rowsort
SELECT - col0 * - col0 * ( cor0.col2 ) FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - cor0.col0 * col2 + col1 col0 FROM tab1 AS cor0
----
-139
-3702
-7747

query I rowsort
SELECT 20 * 41 FROM tab1
----
820
820
820

query I rowsort
SELECT DISTINCT col1 * col1 * - col1 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT ALL 90 + 25 FROM tab0
----
115
115
115

query I rowsort
SELECT 30 * + 7 AS col0 FROM tab2
----
210
210
210

query I rowsort
SELECT - cor0.col0 + 79 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 0989a5d5e7c3b2e0bc513a1cfadb6e89

query I rowsort
SELECT ALL - 29 AS col0 FROM tab1
----
-29
-29
-29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 27 * col1 + - tab2.col1 col1 FROM tab2
----
1534
442
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + + col0 - + 45 col0 FROM tab2 AS cor0
----
-45
-45
-45

query I rowsort
SELECT - 98 * - col1 + + ( - 43 ) AS col0 FROM tab2 AS cor0
----
1623
2995
5739

onlyif mysql # use DIV operator for integer division
query I rowsort label-5383
SELECT ALL + - col1 + col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-5383
SELECT ALL + - col1 + col0 / - col2 AS col1 FROM tab0 AS cor0
----
-132
-86
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5384
SELECT ALL + col2 DIV col1 AS col2 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5384
SELECT ALL + col2 / col1 AS col2 FROM tab2
----
0
0
2

query I rowsort
SELECT ALL ( + 64 ) AS col0 FROM tab2
----
64
64
64

query I rowsort
SELECT DISTINCT - 40 FROM tab2, tab0 AS cor0
----
-40

query I rowsort
SELECT DISTINCT 71 + + 30 FROM tab0
----
101

query I rowsort
SELECT - tab2.col0 * - col0 - col1 FROM tab2
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + tab0.col0 col1 FROM tab0
----
178
48
70

query I rowsort
SELECT + + 91 AS col0 FROM tab2 AS cor0
----
91
91
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col2 FROM tab2 AS cor0
----
67

query I rowsort
SELECT ALL 96 * - col1 AS col2 FROM tab2 AS cor0
----
-1632
-2976
-5664

onlyif mysql # use DIV operator for integer division
query I rowsort label-5393
SELECT cor0.col0 + col0 DIV col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-5393
SELECT cor0.col0 + col0 / col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT - 51 + col0 * + 17 AS col1 FROM tab0 AS cor0
----
1462
357
544

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5395
SELECT DISTINCT col0 + + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5395
SELECT DISTINCT col0 + + col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 91 * col2 FROM tab0 AS cor0
----
3003
7462
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 * col1 col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT ( col1 ) * col1 + - col1 FROM tab2 AS cor0
----
272
3422
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5399
SELECT col2 DIV - ( col1 * - col1 ) col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5399
SELECT col2 / - ( col1 * - col1 ) col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5400
SELECT col2 DIV + ( - col2 ) + - col0 * - 64 AS col1 FROM tab1 AS cor0
----
191
4095
5119

skipif mysql # not compatible
query I rowsort label-5400
SELECT col2 / + ( - col2 ) + - col0 * - 64 AS col1 FROM tab1 AS cor0
----
191
4095
5119

query I rowsort
SELECT + col0 * + 70 FROM tab2 AS cor0
----
490
5460
5530

query I rowsort
SELECT - - col0 - + col2 * col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - col2 + + 63 * col1 + col1 AS col2 FROM tab1
----
1610
583
736

query I rowsort
SELECT ALL - 45 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 63e2b488a204f83ec8c063dafdfd4371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5405
SELECT col1 + + CAST( col2 + - col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5405
SELECT col1 + + CAST ( col2 + - col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col0 * ( 82 ) + col1 AS col2 FROM tab0 AS cor0
----
2054
2967
7389

query I rowsort
SELECT - col0 * - col2 + - 63 * col0 AS col2 FROM tab1 AS cor0
----
-27
-384
2640

query I rowsort
SELECT ALL - col1 + col2 * col0 AS col0 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-5409
SELECT DISTINCT + + cor0.col0 DIV + 18 + + col2 AS col0 FROM tab1 AS cor0
----
100
54
60

skipif mysql # not compatible
query I rowsort label-5409
SELECT DISTINCT + + cor0.col0 / + 18 + + col2 AS col0 FROM tab1 AS cor0
----
100
54
60

query I rowsort
SELECT + + col1 * + cor0.col2 + ( + col1 * 23 ) FROM tab0 AS cor0
----
2328
4816
9555

query I rowsort
SELECT cor0.col0 - + col1 * 42 AS col2 FROM tab1 AS cor0
----
-1089
-356
-466

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5412
SELECT ALL - CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5412
SELECT ALL - CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * ( - col0 ) AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5414
SELECT - col2 DIV 21 FROM tab1 AS cor0
----
-2
-2
-4

skipif mysql # not compatible
query I rowsort label-5414
SELECT - col2 / 21 FROM tab1 AS cor0
----
-2
-2
-4

query I rowsort
SELECT - col0 * ( + ( + col2 ) * col1 + - col1 * + col1 ) FROM tab2
----
-28203
151866
868

query I rowsort
SELECT ( col2 ) * col0 + col0 AS col1 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL + ( - col1 ) * + col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col0 * + 95 + - col1 FROM tab0 AS cor0
----
2194
3228
8364

query I rowsort
SELECT ALL col1 * col0 + - col1 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT 37 + + col1 AS col2 FROM tab0 AS cor0
----
123
128
134

query I rowsort
SELECT DISTINCT 70 + cor0.col1 FROM tab1 AS cor0
----
80
83
96

query I rowsort
SELECT DISTINCT + + cor0.col2 * 6 AS col1 FROM tab0 AS cor0
----
198
492
6

query I rowsort
SELECT ALL 90 + col1 FROM tab2 AS cor0
----
107
121
149

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5424
SELECT - CAST( NULL AS SIGNED ) + - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5424
SELECT - CAST ( NULL AS INTEGER ) + - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 13 + + 44 * col1 FROM tab2 AS cor0
----
1377
2609
761

query I rowsort
SELECT DISTINCT - + 82 * col2 * col2 FROM tab1 AS cor0
----
-239112
-266418
-755712

query I rowsort
SELECT + col0 + + ( col1 ) * - col0 AS col2 FROM tab0 cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 24 * - cor0.col0 col1 FROM tab1 AS cor0
----
-1536
-1920
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5429
SELECT DISTINCT col1 DIV + 93 AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5429
SELECT DISTINCT col1 / + 93 AS col0 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5430
SELECT + tab2.col2 DIV 14 FROM tab2, tab2 AS cor0
----
9 values hashing to c08e3956186780709ba0eab5eede7b9c

skipif mysql # not compatible
query I rowsort label-5430
SELECT + tab2.col2 / 14 FROM tab2, tab2 AS cor0
----
9 values hashing to c08e3956186780709ba0eab5eede7b9c

query I rowsort
SELECT + tab1.col2 + col2 * - col0 + tab1.col1 * + ( col2 ) FROM tab1
----
-3021
-6336
1296

query I rowsort
SELECT + col0 * col1 + + 54 * + col1 - - tab1.col0 AS col0 FROM tab1
----
1244
1485
1822

onlyif mysql # use DIV operator for integer division
query I rowsort label-5433
SELECT ALL col2 DIV + CAST( + 49 * + col0 AS SIGNED ) - tab1.col0 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5433
SELECT ALL col2 / + CAST ( + 49 * + col0 AS INTEGER ) - tab1.col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL - - col1 * ( col2 * cor0.col2 ) + 46 * col2 FROM tab1 AS cor0
----
124224
35112
78300

query I rowsort
SELECT ALL - 35 + col1 AS col2 FROM tab2 AS cor0
----
-18
-4
24

query I rowsort
SELECT ALL + 18 AS col1 FROM tab0 AS cor0
----
18
18
18

query I rowsort
SELECT + ( col2 ) * + col1 - ( ( + col1 ) ) FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT - + col0 - col1 * cor0.col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT col1 * 3 AS col2 FROM tab1
----
30
39
78

query I rowsort
SELECT + tab0.col1 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5441
SELECT - ( + col2 ) DIV + col2 + - col1 AS col0 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-5441
SELECT - ( + col2 ) / + col2 + - col1 AS col0 FROM tab1
----
-11
-14
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5442
SELECT DISTINCT - - 77 - - 83 DIV col2 FROM tab1 AS cor0
----
77
78

skipif mysql # not compatible
query I rowsort label-5442
SELECT DISTINCT - - 77 - - 83 / col2 FROM tab1 AS cor0
----
77
78

query I rowsort
SELECT 12 + cor0.col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
2076
3407
8111

onlyif mysql # use DIV operator for integer division
query I rowsort label-5444
SELECT - - col2 DIV + col0 AS col2 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-5444
SELECT - - col2 / + col0 AS col2 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * 29 FROM tab2 AS cor0
----
1652
476
868

query I rowsort
SELECT ALL + col0 * - col1 AS col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT 23 - tab1.col1 AS col0 FROM tab1
----
-3
10
13

query I rowsort
SELECT ALL 84 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5449
SELECT tab2.col2 DIV - col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-5449
SELECT tab2.col2 / - col0 FROM tab2
----
-3
0
0

query I rowsort
SELECT ALL col2 * col2 - col2 AS col0 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT ALL - col2 + col0 + col2 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT - col0 + 64 + col2 * col2 AS col0 FROM tab2
----
1429
662
786

query I rowsort
SELECT + + col0 + cor0.col2 * - col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * ( + 78 ) - + col1 col0 FROM tab2 AS cor0
----
1969
2075
2947

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5455
SELECT + col1 * + CAST( col1 AS SIGNED ) - col0 FROM tab0 AS cor0
----
7372
8192
9374

skipif mysql # not compatible
query I rowsort label-5455
SELECT + col1 * + CAST ( col1 AS INTEGER ) - col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT DISTINCT + col0 + + ( - 77 ) FROM tab0 AS cor0
----
-42
-53
12

query I rowsort
SELECT col2 - - col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + col1 + - ( col1 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + tab0.col0 * tab0.col2 FROM tab2 AS cor0 CROSS JOIN tab0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT ALL col1 * - tab2.col0 AS col0 FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5461
SELECT ALL - col0 * col2 DIV - col1 FROM tab0 AS cor0
----
0
80
9

skipif mysql # not compatible
query I rowsort label-5461
SELECT ALL - col0 * col2 / - col1 FROM tab0 AS cor0
----
0
80
9

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NULL IN ( + col2 + col2 + - col2 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL BETWEEN col0 * col0 AND NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NULL IN ( col0 + col1 * tab0.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL col0 * col0 * tab0.col1 FROM tab0 WHERE NOT col0 <> ( col1 + - col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL BETWEEN - col1 AND col1
----

query I rowsort
SELECT col0 + - col0 * - col1 FROM tab0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col0 col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT col1 FROM tab0 WHERE NULL NOT BETWEEN - col1 * col0 AND ( NULL )
----

query III rowsort
SELECT ALL * FROM tab1 cor0 WHERE NOT NULL NOT IN ( - col0 * col2 )
----

query I rowsort
SELECT col2 * cor0.col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + col1 * cor0.col0 + - cor0.col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-5474
SELECT ALL + col2 * col1 DIV col1 + + col1 * + tab1.col1 AS col1 FROM tab1
----
157
265
730

skipif mysql # not compatible
query I rowsort label-5474
SELECT ALL + col2 * col1 / col1 + + col1 * + tab1.col1 AS col1 FROM tab1
----
157
265
730

query I rowsort
SELECT - col1 + + tab1.col0 * - col0 + col2 AS col0 FROM tab1
----
-4049
-6317
19

query I rowsort
SELECT DISTINCT + col2 + tab0.col2 * col2 FROM tab0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5477
SELECT DISTINCT tab0.col1 DIV col2 + + col2 + - col1 AS col0 FROM tab0
----
-51
-8
1

skipif mysql # not compatible
query I rowsort label-5477
SELECT DISTINCT tab0.col1 / col2 + + col2 + - col1 AS col0 FROM tab0
----
-51
-8
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5478
SELECT ALL col2 DIV tab1.col2 + + col0 AS col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5478
SELECT ALL col2 / tab1.col2 + + col0 AS col0 FROM tab1
----
4
65
81

query I rowsort
SELECT DISTINCT - col2 * - col0 + + tab2.col0 * col2 FROM tab2
----
378
4056
6004

onlyif mysql # use DIV operator for integer division
query I rowsort label-5480
SELECT ALL col1 DIV col0 + cor0.col2 + col1 * - cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
16320
36566
5757

skipif mysql # not compatible
query I rowsort label-5480
SELECT ALL col1 / col0 + cor0.col2 + col1 * - cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
16320
36566
5757

query I rowsort
SELECT col0 + col2 + col1 FROM tab1
----
131
189
83

query I rowsort
SELECT ALL col0 + col2 * + col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT - cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-5484
SELECT DISTINCT + col0 DIV - cor0.col1 AS col2 FROM tab1 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-5484
SELECT DISTINCT + col0 / - cor0.col1 AS col2 FROM tab1 AS cor0
----
-6
0

query I rowsort
SELECT + cor0.col2 * + cor0.col1 + - col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT cor0.col0 + + col2 * + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT col1 + col0 * + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + col1 * col1 + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL - col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - tab2.col2 + + tab2.col0 * - col0 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT - col2 * + col2 * col2 AS col1 FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT col2 * + col2 + - col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT + 30 * tab2.col0 AS col2 FROM tab2
----
210
2340
2370

query I rowsort
SELECT 50 * col1 FROM tab2
----
1550
2950
850

query I rowsort
SELECT - - 27 FROM tab2, tab1 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT cor0.col0 * - ( + col0 * cor0.col2 + col2 ) AS col0 FROM tab0 AS cor0
----
-1260
-19800
-656820

query I rowsort
SELECT + + col2 * 77 FROM tab1 AS cor0
----
4158
4389
7392

query I rowsort
SELECT col1 * tab0.col2 + - 70 AS col0 FROM tab0
----
27
2768
7392

query I rowsort
SELECT 60 * + col0 AS col2 FROM tab1
----
180
3840
4800

query I rowsort
SELECT 81 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT ( col1 ) + col1 * - 8 AS col2 FROM tab2
----
-119
-217
-413

query I rowsort
SELECT ALL col1 + col1 * - col1 * - col1 AS col0 FROM tab2
----
205438
29822
4930

query I rowsort
SELECT DISTINCT - col1 / col0 AS col0 FROM tab2 WHERE tab2.col1 - col1 > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5504
SELECT ALL col0 DIV col0 col1 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5504
SELECT ALL col0 / col0 col1 FROM tab0
----
1
1
1

query I rowsort
SELECT col0 * col2 * - col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + tab2.col1 - - col0 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT col2 * col0 * - col2 - - col1 FROM tab2 WHERE NOT NULL <> col1
----

query I rowsort
SELECT tab1.col1 + col1 * + col1 AS col1 FROM tab1
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-5509
SELECT - col2 DIV col1 + col2 * col1 FROM tab1
----
1241
1402
565

skipif mysql # not compatible
query I rowsort label-5509
SELECT - col2 / col1 + col2 * col1 FROM tab1
----
1241
1402
565

query I rowsort
SELECT + col0 * col0 FROM tab1 WHERE ( NULL ) NOT BETWEEN col1 AND NULL
----

query I rowsort
SELECT DISTINCT col1 * - col2 + + col0 + + col2 FROM tab2
----
-1430
-529
-803

query I rowsort
SELECT ALL col1 * + col1 + col2 + - col0 FROM tab1
----
185
727
93

query I rowsort
SELECT - col0 - col0 * col0 AS col1 FROM tab2
----
-56
-6162
-6320

query I rowsort
SELECT - col2 + col2 * col1 AS col2 FROM tab0
----
2805
7380
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5515
SELECT DISTINCT + col0 DIV col0 AS col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-5515
SELECT DISTINCT + col0 / col0 AS col2 FROM tab0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5516
SELECT col1 * tab2.col1 DIV + col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-5516
SELECT col1 * tab2.col1 / + col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5517
SELECT DISTINCT + col0 DIV col1 + tab1.col0 + tab1.col1 FROM tab1
----
29
80
99

skipif mysql # not compatible
query I rowsort label-5517
SELECT DISTINCT + col0 / col1 + tab1.col0 + tab1.col1 FROM tab1
----
29
80
99

query I rowsort
SELECT DISTINCT tab1.col1 + + col2 * + col2 AS col2 FROM tab1
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT tab2.col1 * col0 + + tab2.col2 + col2 AS col2 FROM tab2
----
1419
271
4654

query I rowsort
SELECT ALL col2 * - col2 + col1 AS col1 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT tab1.col0 AS col1 FROM tab1 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT ALL tab1.col2 * + col0 + tab1.col2 FROM tab1
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 + col0 col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT + + 5 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT - col1 + cor0.col2 + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + - col2 * 94 * col0 AS col1 FROM tab2 AS cor0
----
-17766
-190632
-282188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5528
SELECT DISTINCT + - col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5528
SELECT DISTINCT + - col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col1 + - col2 AS col2 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5530
SELECT + cor0.col2 + + CAST( cor0.col1 AS SIGNED ) + - cor0.col1 AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5530
SELECT + cor0.col2 + + CAST ( cor0.col1 AS INTEGER ) + - cor0.col1 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + 58 * + tab0.col0 * - ( ( - col1 ) ) AS col0 FROM tab0
----
119712
196910
469742

query I rowsort
SELECT DISTINCT + col2 * tab2.col2 * col1 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT DISTINCT 95 FROM tab1, tab2 cor0, tab1 AS cor1
----
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5534
SELECT - 93 - col0 DIV + 85 AS col1 FROM tab0
----
-93
-93
-94

skipif mysql # not compatible
query I rowsort label-5534
SELECT - 93 - col0 / + 85 AS col1 FROM tab0
----
-93
-93
-94

query I rowsort
SELECT + - cor0.col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT tab0.col0 * + 4 FROM tab0, tab1 AS cor0
----
140
356
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5537
SELECT - cor0.col1 * CAST( 51 AS SIGNED ) + col2 * col2 AS col0 FROM tab1 AS cor0
----
1590
2739
8553

skipif mysql # not compatible
query I rowsort label-5537
SELECT - cor0.col1 * CAST ( 51 AS INTEGER ) + col2 * col2 AS col0 FROM tab1 AS cor0
----
1590
2739
8553

query I rowsort
SELECT ALL - col0 + + col2 AS col0 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5539
SELECT + col1 + 21 DIV + cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-5539
SELECT + col1 + 21 / + cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - col1 + + 19 FROM tab0 AS cor0
----
-67
-72
-78

query I rowsort
SELECT col2 - - 73 * - col0 AS col2 FROM tab0
----
-1719
-2554
-6415

onlyif mysql # use DIV operator for integer division
query I rowsort label-5542
SELECT - col0 DIV cor0.col2 - col1 AS col1 FROM tab1 cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-5542
SELECT - col0 / cor0.col2 - col1 AS col1 FROM tab1 cor0
----
-11
-13
-26

query I rowsort
SELECT + col1 * - col2 + 49 + - col2 FROM tab2 AS cor0
----
-1511
-635
-815

query I rowsort
SELECT 37 * + col2 - + col1 FROM tab1 cor0
----
1972
2099
3539

onlyif mysql # use DIV operator for integer division
query I rowsort label-5545
SELECT + col2 - + col2 DIV col0 FROM tab0 cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-5545
SELECT + col2 - + col2 / col0 FROM tab0 cor0
----
1
32
82

query I rowsort
SELECT + + 48 * - col1 * + 32 + - cor0.col0 * + col0 AS col0 FROM tab0 cor0
----
-132672
-147697
-150217

query I rowsort
SELECT - + col2 * - cor0.col0 * + col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT col1 * - col1 - - col2 FROM tab1 cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT - 81 * col1 + + col1 + cor0.col2 FROM tab1 AS cor0
----
-2026
-743
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5550
SELECT ALL 62 + col0 * col1 DIV + col2 + col2 FROM tab0 AS cor0
----
157
242
3458

skipif mysql # not compatible
query I rowsort label-5550
SELECT ALL 62 + col0 * col1 / + col2 + col2 FROM tab0 AS cor0
----
157
242
3458

query I rowsort
SELECT DISTINCT - - col0 * col2 * - col1 + - col0 FROM tab1 AS cor0
----
-36544
-4215
-99920

query I rowsort
SELECT ALL - col2 + + col1 + col2 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + + 11 - + col2 FROM tab1 AS cor0
----
-43
-46
-85

query I rowsort
SELECT DISTINCT - 96 FROM tab0 cor0
----
-96

query I rowsort
SELECT ALL - 89 * col0 + col2 AS col0 FROM tab1 AS cor0
----
-213
-5639
-7024

query I rowsort
SELECT DISTINCT + + col2 * + col0 * col0 FROM tab0 cor0
----
1225
19008
649522

query I rowsort
SELECT - col0 + - col2 - - col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT cor0.col2 * - cor0.col2 FROM tab1, tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT col0 * - col0 * + col0 + + col0 FROM tab1 AS cor0
----
-24
-262080
-511920

query I rowsort
SELECT 52 + col2 * col1 AS col1 FROM tab0
----
149
2890
7514

query I rowsort
SELECT + - 77 + col2 AS col1 FROM tab0 AS cor0
----
-44
-76
5

query I rowsort
SELECT ALL + + col0 + 58 FROM tab2 AS cor0
----
136
137
65

query I rowsort
SELECT DISTINCT - col2 * col1 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - col2 * col1 + cor0.col1 FROM tab0 cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5565
SELECT ALL + CAST( col0 AS SIGNED ) * + col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5565
SELECT ALL + CAST ( col0 AS INTEGER ) * + col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - - 37 + col2 AS col0 FROM tab1 AS cor0
----
133
91
94

query I rowsort
SELECT DISTINCT col2 - - 0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - tab0.col1 * col2 * col2 + tab0.col0 FROM tab0
----
-611795
-62
-93630

query I rowsort
SELECT ALL - 38 + col1 * col1 * col0 AS col1 FROM tab1 AS cor0
----
13482
1990
6362

onlyif mysql # use DIV operator for integer division
query I rowsort label-5570
SELECT ALL - 77 + col0 * col1 DIV + col0 AS col1 FROM tab2 AS cor0
----
-18
-46
-60

skipif mysql # not compatible
query I rowsort label-5570
SELECT ALL - 77 + col0 * col1 / + col0 AS col1 FROM tab2 AS cor0
----
-18
-46
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-5571
SELECT 54 - col2 DIV tab0.col1 AS col2 FROM tab0
----
54
54
54

skipif mysql # not compatible
query I rowsort label-5571
SELECT 54 - col2 / tab0.col1 AS col2 FROM tab0
----
54
54
54

query I rowsort
SELECT ( col0 ) + + col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT + + col0 * col0 - col2 FROM tab1 cor0
----
-45
4039
6304

query I rowsort
SELECT - 91 + + 2 AS col1 FROM tab2 cor0
----
-89
-89
-89

query I rowsort
SELECT ALL ( - cor0.col0 ) + col2 + - ( - 63 ) FROM tab1 AS cor0
----
114
56
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5576
SELECT ALL + CAST( - col2 AS SIGNED ) * cor0.col2 + col2 + - col0 FROM tab2 AS cor0
----
-1485
-709
-728

skipif mysql # not compatible
query I rowsort label-5576
SELECT ALL + CAST ( - col2 AS INTEGER ) * cor0.col2 + col2 + - col0 FROM tab2 AS cor0
----
-1485
-709
-728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5577
SELECT + CAST( 44 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
44
44
44

skipif mysql # not compatible
query I rowsort label-5577
SELECT + CAST ( 44 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
44
44
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-5578
SELECT ALL - col1 + - col1 DIV col1 FROM tab2 cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-5578
SELECT ALL - col1 + - col1 / col1 FROM tab2 cor0
----
-18
-32
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-5579
SELECT - 87 DIV - col0 FROM tab0 cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-5579
SELECT - 87 / - col0 FROM tab0 cor0
----
0
2
3

query I rowsort
SELECT DISTINCT + ( 36 ) * col0 FROM tab2 AS cor0
----
252
2808
2844

query I rowsort
SELECT - ( - 80 * - tab2.col2 ) FROM tab2
----
-2080
-2160
-3040

query I rowsort
SELECT ALL + cor0.col2 + 16 AS col1 FROM tab2 AS cor0
----
42
43
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-5583
SELECT ALL - 36 DIV cor0.col0 - - col1 AS col2 FROM tab2 AS cor0
----
17
26
59

skipif mysql # not compatible
query I rowsort label-5583
SELECT ALL - 36 / cor0.col0 - - col1 AS col2 FROM tab2 AS cor0
----
17
26
59

query I rowsort
SELECT DISTINCT - col1 + + 41 FROM tab2 AS cor0
----
-18
10
24

query I rowsort
SELECT + ( + col1 ) * col1 + col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + 65 AS col1 FROM tab2 cor0
----
65
65
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5587
SELECT ALL + 76 DIV - tab2.col0 FROM tab2
----
-10
0
0

skipif mysql # not compatible
query I rowsort label-5587
SELECT ALL + 76 / - tab2.col0 FROM tab2
----
-10
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5588
SELECT DISTINCT + col2 DIV 89 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-5588
SELECT DISTINCT + col2 / 89 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 74 - col0 col0 FROM tab1 AS cor0
----
3993
4154
7024

query I rowsort
SELECT ALL - + cor0.col2 - - col0 * col0 FROM tab1 AS cor0
----
-45
4039
6304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5591
SELECT ALL - col0 - - CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-5591
SELECT ALL - col0 - - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT col1 * 64 FROM tab2 AS cor0
----
1088
1984
3776

query I rowsort
SELECT + - col0 * - 57 AS col0 FROM tab1 AS cor0
----
171
3648
4560

query I rowsort
SELECT DISTINCT - + 67 * cor0.col1 FROM tab1, tab0 AS cor0
----
-5762
-6097
-6499

onlyif mysql # use DIV operator for integer division
query I rowsort label-5595
SELECT DISTINCT + cor0.col2 * col1 DIV + col2 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5595
SELECT DISTINCT + cor0.col2 * col1 / + col2 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 31 * 25 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b83c15e437873371475ea750c4711478

query I rowsort
SELECT cor1.col1 + 33 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 2a55a555d82952c1c5c9ac242dd1aa99

query I rowsort
SELECT 58 + - tab0.col1 AS col2 FROM tab0
----
-28
-33
-39

query I rowsort
SELECT cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT col2 + + 35 * + col2 + + col1 * col0 * col1 AS col0 FROM tab2
----
24199
272454
7699

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 + - col1 col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - - col2 * col2 + 19 FROM tab0 AS cor0
----
1108
20
6743

query I rowsort
SELECT + cor0.col1 + + 89 FROM tab1 AS cor0
----
102
115
99

query I rowsort
SELECT + + cor0.col1 * col0 + col2 * - cor0.col0 AS col0 FROM tab0 cor0
----
1272
3360
801

query I rowsort
SELECT DISTINCT - - col1 * - col1 + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL + col0 * col0 - - cor0.col0 * col0 * 52 FROM tab2 AS cor0
----
2597
322452
330773

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - col2 * col2 col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT - 4 + cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 000e54bcb4bb4fe2e97bd113abd24b00

onlyif mysql # use DIV operator for integer division
query I rowsort label-5609
SELECT ALL 47 DIV cor0.col1 FROM tab2, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5609
SELECT ALL 47 / cor0.col1 FROM tab2, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT tab2.col0 * + tab2.col1 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT col1 * + 29 + col0 FROM tab0 AS cor0
----
2518
2728
2848

query I rowsort
SELECT - - cor0.col1 * ( col1 ) - + ( + 8 * - col2 ) FROM tab1 AS cor0
----
1108
556
937

query I rowsort
SELECT ALL + 90 AS col0 FROM tab0
----
90
90
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 66 col1 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT + col2 + col1 * - col1 AS col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-5616
SELECT - - col1 DIV 12 AS col2 FROM tab0 AS cor0
----
7
7
8

skipif mysql # not compatible
query I rowsort label-5616
SELECT - - col1 / 12 AS col2 FROM tab0 AS cor0
----
7
7
8

query I rowsort
SELECT + col1 * 28 AS col2 FROM tab0 cor0
----
2408
2548
2716

query I rowsort
SELECT + col0 * + ( 63 ) + col0 FROM tab0 cor0
----
1536
2240
5696

query I rowsort
SELECT - col1 * 82 + col2 * col1 * + col2 FROM tab0 AS cor0
----
-7857
604422
86602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5620
SELECT cor0.col1 DIV - 70 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5620
SELECT cor0.col1 / - 70 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * - 45 FROM tab0 cor0
----
1485
3690
45

query I rowsort
SELECT - - col1 + 5 * col1 AS col1 FROM tab0 cor0
----
516
546
582

query I rowsort
SELECT 14 * col1 - 90 FROM tab0 AS cor0
----
1114
1184
1268

query I rowsort
SELECT DISTINCT - + cor0.col2 + col0 * col1 - col1 AS col2 FROM tab2 AS cor0
----
1288
159
4517

onlyif mysql # use DIV operator for integer division
query I rowsort label-5625
SELECT ALL col0 DIV + col2 + - cor0.col1 + cor0.col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5625
SELECT ALL col0 / + col2 + - cor0.col1 + cor0.col1 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT ALL + + col2 + col2 FROM tab0 cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5627
SELECT - 96 - col0 DIV - 81 AS col1 FROM tab2 AS cor0
----
-96
-96
-96

skipif mysql # not compatible
query I rowsort label-5627
SELECT - 96 - col0 / - 81 AS col1 FROM tab2 AS cor0
----
-96
-96
-96

query I rowsort
SELECT + 43 AS col1 FROM tab0 AS cor0
----
43
43
43

query I rowsort
SELECT + + ( - cor0.col0 ) - - 90 FROM tab1 AS cor0
----
10
26
87

query I rowsort
SELECT DISTINCT - + cor0.col2 + col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5631
SELECT DISTINCT + - col1 DIV + col1 + - ( col0 ) * - cor0.col0 FROM tab1 AS cor0
----
4095
6399
8

skipif mysql # not compatible
query I rowsort label-5631
SELECT DISTINCT + - col1 / + col1 + - ( col0 ) * - cor0.col0 FROM tab1 AS cor0
----
4095
6399
8

query I rowsort
SELECT 87 * + col2 AS col0 FROM tab0
----
2871
7134
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 94 - col2 * + tab1.col0 col0 FROM tab1
----
-3554
-68
-7586

query I rowsort
SELECT ALL + col2 + ( - 82 ) FROM tab1 AS cor0
----
-25
-28
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-5635
SELECT DISTINCT + + cor0.col2 * col2 DIV - col1 AS col0 FROM tab2 cor0
----
-11
-23
-84

skipif mysql # not compatible
query I rowsort label-5635
SELECT DISTINCT + + cor0.col2 * col2 / - col1 AS col0 FROM tab2 cor0
----
-11
-23
-84

query I rowsort
SELECT + + col1 + 56 FROM tab0 AS cor0
----
142
147
153

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5637
SELECT DISTINCT col1 + CAST( col0 AS SIGNED ) * + col2 FROM tab1 AS cor0
----
188
3658
7693

skipif mysql # not compatible
query I rowsort label-5637
SELECT DISTINCT col1 + CAST ( col0 AS INTEGER ) * + col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL + tab2.col1 * col2 + - ( + 37 ) * - col1 * ( col1 ) AS col2 FROM tab2
----
11339
130331
36394

query I rowsort
SELECT ALL ( col2 ) * - tab1.col0 + tab1.col1 AS col1 FROM tab1
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5640
SELECT ALL - col1 * - col0 + + CAST( NULL AS SIGNED ) * ( - col1 ) * - col0 col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5640
SELECT ALL - col1 * - col0 + + CAST ( NULL AS INTEGER ) * ( - col1 ) * - col0 col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5641
SELECT ALL - - CAST( NULL AS SIGNED ) + - col1 / col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5641
SELECT ALL - - CAST ( NULL AS INTEGER ) + - col1 / col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5642
SELECT DISTINCT CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5642
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - col1 ) * - col2 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT 79 + + col2 FROM tab0 cor0
----
112
161
80

query I rowsort
SELECT ALL - ( + col1 ) + col1 AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 34 + - col2 AS col2 FROM tab2 AS cor0
----
-60
-61
-72

query I rowsort
SELECT ALL + col0 * - 56 FROM tab1
----
-168
-3584
-4480

query I rowsort
SELECT DISTINCT - col2 + - ( col2 + + col0 ) FROM tab2
----
-130
-155
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5649
SELECT ALL CAST( NULL AS SIGNED ) * + 47 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5649
SELECT ALL CAST ( NULL AS INTEGER ) * + 47 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - col1 * ( - col2 + - col0 ) FROM tab1
----
1210
1482
2288

query I rowsort
SELECT col1 * + 73 * col0 FROM tab0 AS cor0
----
150672
247835
591227

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5652
SELECT ALL - + CAST( col2 AS SIGNED ) + - cor0.col1 * CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5652
SELECT ALL - + CAST ( col2 AS INTEGER ) + - cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 3 * 9 AS col0 FROM tab1
----
27

query I rowsort
SELECT ALL - + ( - col2 ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT 17 * + col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT ALL 43 * col0 AS col2 FROM tab2 AS cor0
----
301
3354
3397

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5657
SELECT ALL + ( + col2 ) * - ( - col0 * col0 ) + CAST( col2 + - col0 AS SIGNED ) * + col1 * + col0 AS col1 FROM tab1 AS cor0
----
228992
4464
631040

skipif mysql # not compatible
query I rowsort label-5657
SELECT ALL + ( + col2 ) * - ( - col0 * col0 ) + CAST ( col2 + - col0 AS INTEGER ) * + col1 * + col0 AS col1 FROM tab1 AS cor0
----
228992
4464
631040

query I rowsort
SELECT ALL + - 37 - cor0.col0 AS col2 FROM tab2 cor0
----
-115
-116
-44

query I rowsort
SELECT DISTINCT 1 + col2 AS col0 FROM tab0
----
2
34
83

query I rowsort
SELECT - + col2 * col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - col0 * + col1 * col0 FROM tab0 cor0
----
-118825
-49536
-720811

query I rowsort
SELECT - col0 * + col0 + 85 * - 36 FROM tab1 AS cor0
----
-3069
-7156
-9460

query I rowsort
SELECT ALL - col0 * col0 + col1 + - col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 - ( + col0 * col0 ) AS col2 FROM tab2 cor0
----
-2603
-5952
912

query I rowsort
SELECT + 83 * col2 * - col2 FROM tab1 AS cor0
----
-242028
-269667
-764928

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

onlyif mysql # use DIV operator for integer division
query I rowsort label-5667
SELECT + + col2 DIV 66 + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5667
SELECT + + col2 / 66 + col0 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + cor0.col0 col1 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5669
SELECT ALL - - col2 * - col2 + col0 + - col2 DIV 49 FROM tab1 AS cor0
----
-2914
-3186
-9137

skipif mysql # not compatible
query I rowsort label-5669
SELECT ALL - - col2 * - col2 + col0 + - col2 / 49 FROM tab1 AS cor0
----
-2914
-3186
-9137

query I rowsort
SELECT ALL - col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + + col1 + + 73 AS col1 FROM tab2 AS cor0
----
104
132
90

query I rowsort
SELECT col0 + - col1 * - col2 + col2 * + col0 * + 39 AS col0 FROM tab0 cor0
----
1497
292173
33750

query I rowsort
SELECT + col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col1 * + 52 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT + cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + - 50 * + col1 * + cor0.col2 FROM tab2 AS cor0
----
-32300
-41850
-76700

query I rowsort
SELECT DISTINCT + col0 + col2 + col2 AS col0 FROM tab1
----
111
178
272

query I rowsort
SELECT DISTINCT + 93 AS col1 FROM tab2, tab1 AS cor0
----
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5679
SELECT - col2 * col2 DIV 62 + 41 AS col1 FROM tab2 AS cor0
----
18
30
31

skipif mysql # not compatible
query I rowsort label-5679
SELECT - col2 * col2 / 62 + 41 AS col1 FROM tab2 AS cor0
----
18
30
31

query I rowsort
SELECT DISTINCT + + cor0.col1 + - col2 * ( - col2 ) AS col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL - 90 + + cor0.col2 * ( - col2 * - col1 ) + cor0.col2 FROM tab2 AS cor0
----
22536
24496
39820

query I rowsort
SELECT DISTINCT - col1 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - col1 - + col0 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - - col2 + - col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT 13 + - col1 - - 7 FROM tab1 AS cor0
----
-6
10
7

query I rowsort
SELECT - 22 * col0 * col0 + col1 * col2 + col1 FROM tab0 AS cor0
----
-166709
-26756
-9748

query I rowsort
SELECT DISTINCT + + 28 + col2 * col0 AS col0 FROM tab2 AS cor0
----
2056
217
3030

onlyif mysql # use DIV operator for integer division
query I rowsort label-5688
SELECT DISTINCT - cor0.col1 + col2 DIV cor0.col1 FROM tab1 AS cor0
----
-24
-5
-6

skipif mysql # not compatible
query I rowsort label-5688
SELECT DISTINCT - cor0.col1 + col2 / cor0.col1 FROM tab1 AS cor0
----
-24
-5
-6

query I rowsort
SELECT ALL - cor0.col2 + - col1 FROM tab2 cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 55 col1 FROM tab2 cor0
----
55
55
55

query I rowsort
SELECT + col1 * - col0 + + ( + col0 ) AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - - col2 + cor0.col2 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
253
37
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 76 + + col0 col0 FROM tab2 AS cor0
----
138
52
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5694
SELECT DISTINCT + - col0 + - col2 DIV - 54 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5694
SELECT DISTINCT + - col0 + - col2 / - 54 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - - col1 * + col2 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5696
SELECT DISTINCT - CAST( 74 AS SIGNED ) + col2 FROM tab1 AS cor0
----
-17
-20
22

skipif mysql # not compatible
query I rowsort label-5696
SELECT DISTINCT - CAST ( 74 AS INTEGER ) + col2 FROM tab1 AS cor0
----
-17
-20
22

query I rowsort
SELECT - - col2 * 22 FROM tab0 AS cor0
----
1804
22
726

onlyif mysql # use DIV operator for integer division
query I rowsort label-5698
SELECT DISTINCT + - 24 DIV col0 + - col1 * col2 DIV - col0 col2 FROM tab0 cor0
----
117
2
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5698
SELECT DISTINCT + - 24 / col0 + - col1 * col2 / - col0 col2 FROM tab0 cor0
----
117
2
83

query I rowsort
SELECT ( - 80 ) AS col2 FROM tab1 cor0
----
-80
-80
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5700
SELECT ALL ( - 3 ) DIV cor0.col2 + - col1 * + col0 FROM tab0 AS cor0
----
-2064
-3398
-8099

skipif mysql # not compatible
query I rowsort label-5700
SELECT ALL ( - 3 ) / cor0.col2 + - col1 * + col0 FROM tab0 AS cor0
----
-2064
-3398
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5701
SELECT ALL + CAST( NULL AS SIGNED ) + col2 * + col2 + cor0.col1 * - 1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5701
SELECT ALL + CAST ( NULL AS INTEGER ) + col2 * + col2 + cor0.col1 * - 1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT DISTINCT col0 * - 31 + col2 FROM tab1 AS cor0
----
-1927
-2384
-39

query I rowsort
SELECT DISTINCT + 38 + col2 FROM tab0 AS cor0
----
120
39
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - tab1.col0 - - col2 col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - col2 * col2 - 3 AS col1 FROM tab1 AS cor0
----
-2919
-3252
-9219

query I rowsort
SELECT - 91 - col2 FROM tab2 AS cor0
----
-117
-118
-129

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5708
SELECT + - 38 - col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5708
SELECT + - 38 - col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( col0 * + col0 + 85 * col1 ) FROM tab0
----
-15656
-7886
-9470

query I rowsort
SELECT ( + col2 * col1 + + ( col0 ) ) FROM tab0
----
132
2862
7551

query I rowsort
SELECT + cor1.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to ee8b23a58dda2d92e14ed437e06ed8d2

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
-10
-13
-26

query I rowsort
SELECT + 16 * + col1 FROM tab1
----
160
208
416

query I rowsort
SELECT - 77 + col2 * col1 FROM tab1 AS cor0
----
1171
1327
493

query I rowsort
SELECT + col0 + - ( 56 ) AS col2 FROM tab1
----
-53
24
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 81 * + col2 col0 FROM tab0 cor0
----
2673
6642
81

query I rowsort
SELECT + 90 FROM tab1, tab0 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

onlyif mysql # use DIV operator for integer division
query I rowsort label-5718
SELECT + col0 * + tab0.col0 * + col2 + col1 DIV col0 FROM tab0
----
1227
19011
649523

skipif mysql # not compatible
query I rowsort label-5718
SELECT + col0 * + tab0.col0 * + col2 + col1 / col0 FROM tab0
----
1227
19011
649523

query I rowsort
SELECT tab2.col1 + - 96 * col1 AS col2 FROM tab2
----
-1615
-2945
-5605

query I rowsort
SELECT DISTINCT - + col0 * + 82 AS col0 FROM tab2 cor0
----
-574
-6396
-6478

query I rowsort
SELECT ALL tab0.col0 * + ( 64 ) FROM tab0
----
1536
2240
5696

query I rowsort
SELECT DISTINCT - col1 - - col0 * - col0 FROM tab0 cor0
----
-1322
-662
-8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( + col1 ) col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ( + col0 ) * + col2 * 39 AS col1 FROM tab1 AS cor0
----
142272
299520
6318

query I rowsort
SELECT 14 + - col1 AS col2 FROM tab0 AS cor0
----
-72
-77
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 96 col0 FROM tab0 AS cor0
----
96
96
96

query I rowsort
SELECT DISTINCT + 77 AS col1 FROM tab1, tab0 cor0
----
77

query I rowsort
SELECT ALL cor0.col2 + + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-5729
SELECT ALL + cor0.col0 + col2 DIV - cor0.col2 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-5729
SELECT ALL + cor0.col0 + col2 / - cor0.col2 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT DISTINCT + col2 * - ( cor0.col2 + 65 ) FROM tab2 AS cor0
----
-2366
-2484
-3914

query I rowsort
SELECT + col1 - 33 * cor0.col2 FROM tab0 cor0
----
-1003
-2615
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5732
SELECT DISTINCT + CAST( NULL AS SIGNED ) col0 FROM tab2 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5732
SELECT DISTINCT + CAST ( NULL AS INTEGER ) col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT + cor0.col2 + col2 + col2 * - 94 FROM tab2 AS cor0
----
-2392
-2484
-3496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5734
SELECT ALL - CAST( + cor0.col0 AS SIGNED ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-5734
SELECT ALL - CAST ( + cor0.col0 AS INTEGER ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5735
SELECT ALL CAST( NULL AS DECIMAL ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5735
SELECT ALL CAST ( NULL AS REAL ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 98 + col2 FROM tab2 AS cor0
----
124
125
136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5737
SELECT - CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5737
SELECT - CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 98 * + 61 FROM tab2 AS cor0
----
-5978
-5978
-5978

query I rowsort
SELECT + - col0 * col1 - + cor0.col1 FROM tab1 AS cor0
----
-104
-1053
-650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 1 + - ( col2 ) col0 FROM tab0 AS cor0
----
-32
-81
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5741
SELECT CAST( NULL AS SIGNED ) + + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5741
SELECT CAST ( NULL AS INTEGER ) + + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5742
SELECT DISTINCT - col2 DIV 40 FROM tab1
----
-1
-2

skipif mysql # not compatible
query I rowsort label-5742
SELECT DISTINCT - col2 / 40 FROM tab1
----
-1
-2

query I rowsort
SELECT - col0 - - ( col0 * col1 ) FROM tab0
----
2040
3360
8010

query I rowsort
SELECT ALL tab0.col0 * + 20 FROM tab0
----
1780
480
700

query I rowsort
SELECT + 12 AS col0 FROM tab0 cor0
----
12
12
12

query I rowsort
SELECT ALL - - cor0.col1 + col0 * col2 AS col2 FROM tab0 cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col0 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ( + ( col1 ) + + 66 ) * 46 FROM tab1
----
3496
3634
4232

query I rowsort
SELECT DISTINCT + 39 * + col2 AS col1 FROM tab0
----
1287
3198
39

query I rowsort
SELECT DISTINCT 0 + - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5751
SELECT ALL col1 + col2 DIV col2 + col1 DIV + col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5751
SELECT ALL col1 + col2 / col2 + col1 / + col2 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 col0 FROM tab0 AS cor0
----
-83
-83
-83

query I rowsort
SELECT DISTINCT - + col1 * cor0.col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - 61 * col0 * + 53 + 49 * - cor0.col1 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-117908
-216654
-653375

query I rowsort
SELECT ALL + cor1.col2 + + 50 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b2174eaf3756478def762f6e243f6669

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 + col2 col2 FROM tab0
----
130
49
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5757
SELECT col1 - - col1 DIV 24 FROM tab1
----
10
13
27

skipif mysql # not compatible
query I rowsort label-5757
SELECT col1 - - col1 / 24 FROM tab1
----
10
13
27

query I rowsort
SELECT ALL - - col2 * - col2 + ( + col2 ) AS col1 FROM tab0 AS cor0
----
-1056
-6642
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col2 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - cor0.col2 + 63 AS col2 FROM tab0 cor0
----
-19
30
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + 92 col2 FROM tab1 AS cor0
----
146
149
188

query I rowsort
SELECT DISTINCT col0 * ( - col1 ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 + 23 * 11 AS col1 FROM tab0 cor0
----
339
344
350

query I rowsort
SELECT ALL - - col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + + col2 * cor0.col2 + + col2 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT + col2 * + col0 + + 33 AS col1 FROM tab2
----
2061
222
3035

onlyif mysql # use DIV operator for integer division
query I rowsort label-5767
SELECT DISTINCT + 14 + tab1.col2 DIV col0 FROM tab1
----
14
15
32

skipif mysql # not compatible
query I rowsort label-5767
SELECT DISTINCT + 14 + tab1.col2 / col0 FROM tab1
----
14
15
32

query I rowsort
SELECT ALL - ( + col0 * + tab1.col0 ) + col2 + col2 FROM tab1
----
-3982
-6208
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col0 * 65 col0 FROM tab0
----
-1536
-2240
-5696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5770
SELECT ALL + CAST( NULL AS DECIMAL ) AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5770
SELECT ALL + CAST ( NULL AS REAL ) AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - + col2 - + 20 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
1687
1738
1939

query I rowsort
SELECT ALL + - col1 * + col1 * - 55 + + col2 FROM tab0 AS cor0
----
406813
455537
517496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5773
SELECT DISTINCT col2 + - CAST( col2 + + col0 * col0 AS SIGNED ) FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-5773
SELECT DISTINCT col2 + - CAST ( col2 + + col0 * col0 AS INTEGER ) FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - col2 - cor0.col0 * + 99 AS col2 FROM tab1 AS cor0
----
-351
-6393
-8016

query I rowsort
SELECT DISTINCT col2 + ( col1 ) AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL - col2 - 54 * + col2 AS col0 FROM tab1 AS cor0
----
-2970
-3135
-5280

query I rowsort
SELECT ALL tab0.col1 AS col0 FROM tab1, tab0 cor0 CROSS JOIN tab0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT 84 * - 25 AS col1 FROM tab2 AS cor0
----
-2100
-2100
-2100

query I rowsort
SELECT - - col0 * col1 + - col1 * 48 AS col0 FROM tab2 AS cor0
----
-1271
1770
527

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5780
SELECT DISTINCT + ( col0 ) - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-5780
SELECT DISTINCT + ( col0 ) - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + 6 + tab0.col0 * col1 AS col1 FROM tab0
----
2070
3401
8105

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 + + col0 col1 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL + + ( + col1 ) * - 31 FROM tab0 AS cor0
----
-2666
-2821
-3007

query I rowsort
SELECT ALL - + ( col1 ) FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT col1 + col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col2 + col2 >= NULL
----

query I rowsort
SELECT + tab0.col1 AS col1 FROM tab0 WHERE NOT NULL NOT IN ( - tab0.col2 * col0 )
----

query I rowsort
SELECT col2 + col2 FROM tab1 WHERE ( col2 + col0 ) NOT BETWEEN NULL AND + col0
----
108
114
192

query I rowsort
SELECT - + cor0.col0 - + col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5790
SELECT col1 + - col2 DIV col0 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-5790
SELECT col1 + - col2 / col0 FROM tab2 AS cor0
----
17
28
59

query I rowsort
SELECT col2 * - cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * cor0.col1 + - col1 col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT - - col2 * + col2 - - cor0.col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL cor0.col2 + col0 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT + ( + col0 ) * col0 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5797
SELECT ALL 21 DIV col2 AS col1 FROM tab0
----
0
0
21

skipif mysql # not compatible
query I rowsort label-5797
SELECT ALL 21 / col2 AS col1 FROM tab0
----
0
0
21

query I rowsort
SELECT ALL - col1 + - col1 * col0 * col2 AS col2 FROM tab0 AS cor0
----
-3492
-664209
-68198

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 + + col1 col1 FROM tab2 AS cor0
----
104
118
146

onlyif mysql # use DIV operator for integer division
query I rowsort label-5800
SELECT + + col1 * col0 DIV col1 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5800
SELECT + + col1 * col0 / col1 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 70 * + col0 col2 FROM tab1 AS cor0
----
210
4480
5600

query I rowsort
SELECT col0 * - cor0.col2 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + - 13 * col2 FROM tab2 AS cor0
----
-338
-351
-494

onlyif mysql # use DIV operator for integer division
query I rowsort label-5804
SELECT col0 + cor0.col1 DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-5804
SELECT col0 + cor0.col1 / - cor0.col0 AS col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT ALL + + col1 * + cor0.col1 FROM tab1 AS cor0
----
100
169
676

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT - col1 * tab2.col1 FROM tab2 WHERE NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT + tab2.col1 + col0 AS col2 FROM tab2
----
137
38
96

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( col1 / - tab1.col0 )
----

query I rowsort
SELECT col0 + tab2.col0 - - tab2.col0 AS col1 FROM tab2
----
21
234
237

query I rowsort
SELECT DISTINCT - col0 + + tab2.col1 * col1 FROM tab2
----
210
3403
954

query I rowsort
SELECT col0 + col1 * col1 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT - col2 + col1 * - col2 FROM tab2
----
-1560
-684
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 col1 FROM tab1
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col0 col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT + col0 FROM tab0 WHERE NULL NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5817
SELECT + col1 DIV tab0.col1 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5817
SELECT + col1 / tab0.col1 AS col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col1 col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 / col1 + + col0 * + col2 + + col1 FROM tab0 WHERE NOT NULL IN ( col1 / + col2 )
----

query III rowsort
SELECT * FROM tab1 WHERE NOT + col0 * - col0 <= NULL
----

query I rowsort
SELECT DISTINCT col0 + + tab1.col1 FROM tab1 WHERE NULL NOT IN ( col1 * + col1 * col2 + - tab1.col0 * col1 * col1 )
----

query I rowsort
SELECT + col1 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
132
7389
878

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 * + col0 * col0 IN ( col0 / col1 + col0 + col0 / - col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col2 + col0 * - col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT + col0 + + col0 * + cor0.col1 AS col0 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT - cor0.col0 + col1 * col0 FROM tab1 cor0
----
576
75
960

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT ( col0 ) NOT IN ( col2 - - cor0.col2 )
----

query I rowsort
SELECT - col1 * - col0 + tab0.col2 AS col0 FROM tab0
----
2097
3396
8181

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col1 BETWEEN NULL AND col1
----

query I rowsort
SELECT DISTINCT + col0 * + tab1.col2 + col2 * col0 AS col1 FROM tab1
----
15360
324
7296

query I rowsort
SELECT DISTINCT + col0 + + col2 * tab2.col1 AS col2 FROM tab2
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 + col0 col2 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT DISTINCT + col2 + + col1 * col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL col0 * col1 + col2 * - col1 FROM tab1
----
-1326
-208
70

query I rowsort
SELECT DISTINCT col2 * col0 + col2 FROM tab1
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5836
SELECT ( 70 ) * col1 - col0 DIV - ( - col0 ) AS col1 FROM tab1
----
1819
699
909

skipif mysql # not compatible
query I rowsort label-5836
SELECT ( 70 ) * col1 - col0 / - ( - col0 ) AS col1 FROM tab1
----
1819
699
909

query I rowsort
SELECT ALL + - cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5838
SELECT - col0 * col0 + col1 DIV + 88 AS col2 FROM tab1
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-5838
SELECT - col0 * col0 + col1 / + 88 AS col2 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + 58 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1306
1462
628

query I rowsort
SELECT - cor0.col1 + col2 * col1 AS col0 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - col0 * + tab2.col0 + col1 AS col2 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT + 62 + - col2 AS col2 FROM tab0
----
-20
29
61

query I rowsort
SELECT ALL + ( - col2 ) * col0 - - col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5844
SELECT ALL cor0.col0 DIV col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5844
SELECT ALL cor0.col0 / col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5845
SELECT DISTINCT + 20 * + col2 + - CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5845
SELECT DISTINCT + 20 * + col2 + - CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5846
SELECT ALL col0 DIV + col0 + + tab0.col1 * - col2 FROM tab0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-5846
SELECT ALL col0 / + col0 + + tab0.col1 * - col2 FROM tab0
----
-2837
-7461
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 40 col1 FROM tab2, tab2 cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT ALL col2 - ( tab1.col2 ) FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 * col0 col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + col0 * - 45 * - tab2.col0 FROM tab2
----
2205
273780
280845

query I rowsort
SELECT - + col1 - ( + ( - col1 ) ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * 31 + + col0 * col0 + col1 AS col0 FROM tab2 AS cor0
----
297
8561
8707

query I rowsort
SELECT - - cor0.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT col1 * 88 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
7601
8090
8537

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 70 + col0 * col1 * + ( col1 ) + col1 col1 FROM tab2 AS cor0
----
25508
273397
8648

query I rowsort
SELECT DISTINCT - + 21 AS col2 FROM tab0 cor0
----
-21

query I rowsort
SELECT ALL + + 71 AS col2 FROM tab1 AS cor0
----
71
71
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 + col0 col0 FROM tab0 cor0
----
-2
-62

query I rowsort
SELECT ALL - - col2 + cor0.col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + - col1 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - - 93 * + col2 + + col1 AS col2 FROM tab1 AS cor0
----
5048
5311
8941

query I rowsort
SELECT DISTINCT ( - col2 ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5863
SELECT - col2 * + CAST( 71 AS SIGNED ) col1 FROM tab1
----
-3834
-4047
-6816

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5863
SELECT - col2 * + CAST ( 71 AS INTEGER ) col1 FROM tab1
----
-3834
-4047
-6816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5864
SELECT ALL - tab0.col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5864
SELECT ALL - tab0.col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - col0 * ( - col1 ) FROM tab0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5866
SELECT col2 * CAST( 35 + - col2 AS SIGNED ) AS col1 FROM tab1
----
-1026
-1254
-5856

skipif mysql # not compatible
query I rowsort label-5866
SELECT col2 * CAST ( 35 + - col2 AS INTEGER ) AS col1 FROM tab1
----
-1026
-1254
-5856

query I rowsort
SELECT ALL - - ( - 74 ) * col2 AS col2 FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT - cor0.col1 * 60 + + col0 AS col1 FROM tab1 AS cor0
----
-1557
-536
-700

query I rowsort
SELECT ALL + col1 * 13 AS col2 FROM tab1 AS cor0
----
130
169
338

query I rowsort
SELECT DISTINCT ( 80 ) * col0 AS col0 FROM tab1 AS cor0
----
240
5120
6400

query I rowsort
SELECT + 3 + cor0.col2 FROM tab0 AS cor0
----
36
4
85

query I rowsort
SELECT DISTINCT + + col0 * + col2 + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5873
SELECT DISTINCT CAST( + col1 AS SIGNED ) + - col2 + col0 FROM tab2 AS cor0
----
11
111
58

skipif mysql # not compatible
query I rowsort label-5873
SELECT DISTINCT CAST ( + col1 AS INTEGER ) + - col2 + col0 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT - 63 + + col2 FROM tab0 AS cor0
----
-30
-62
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-5875
SELECT + col2 DIV - 28 + col1 AS col0 FROM tab2 AS cor0
----
16
31
59

skipif mysql # not compatible
query I rowsort label-5875
SELECT + col2 / - 28 + col1 AS col0 FROM tab2 AS cor0
----
16
31
59

query I rowsort
SELECT DISTINCT + + 70 + - col1 AS col1 FROM tab0 AS cor0
----
-16
-21
-27

query I rowsort
SELECT ALL + 74 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
105
133
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 31 col2 FROM tab2
----
31

query I rowsort
SELECT + 73 + col1 * + col1 + col1 AS col0 FROM tab0 AS cor0
----
7555
8445
9579

query I rowsort
SELECT - 88 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5881
SELECT ALL + CAST( NULL AS DECIMAL ) * col1 * - col0 + - tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5881
SELECT ALL + CAST ( NULL AS REAL ) * col1 * - col0 + - tab1.col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5882
SELECT ALL ( col1 ) * col1 DIV col0 + tab2.col2 FROM tab2
----
164
41
70

skipif mysql # not compatible
query I rowsort label-5882
SELECT ALL ( col1 ) * col1 / col0 + tab2.col2 FROM tab2
----
164
41
70

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 * + col2 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5884
SELECT DISTINCT col1 DIV - cor0.col1 FROM tab0 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5884
SELECT DISTINCT col1 / - cor0.col1 FROM tab0 cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5885
SELECT - col1 DIV - col0 FROM tab1 cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5885
SELECT - col1 / - col0 FROM tab1 cor0
----
0
0
8

query I rowsort
SELECT - 6 * cor0.col1 + - col1 * + col2 + + col2 AS col2 FROM tab0 AS cor0
----
-3321
-678
-7926

onlyif mysql # use DIV operator for integer division
query I rowsort label-5887
SELECT DISTINCT col2 * + col2 + + col2 + + col0 DIV + col1 AS col0 FROM tab2
----
1486
703
756

skipif mysql # not compatible
query I rowsort label-5887
SELECT DISTINCT col2 * + col2 + + col2 + + col0 / + col1 AS col0 FROM tab2
----
1486
703
756

query I rowsort
SELECT DISTINCT ( + col2 ) + + col2 + - col1 * + col0 FROM tab0
----
-1998
-3393
-7935

query I rowsort
SELECT DISTINCT + col2 + col2 + col2 AS col2 FROM tab1
----
162
171
288

query I rowsort
SELECT + tab2.col1 + 58 + col2 FROM tab2
----
113
116
143

query I rowsort
SELECT ALL - col2 + + 81 FROM tab2
----
43
54
55

query I rowsort
SELECT - cor0.col1 + - 87 FROM tab1 AS cor0
----
-100
-113
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5893
SELECT DISTINCT + - col1 + + CAST( + col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5893
SELECT DISTINCT + - col1 + + CAST ( + col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + col1 * - col1 - + col2 AS col0 FROM tab0 cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT col2 * - ( + col0 + - col0 ) FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5896
SELECT DISTINCT + - col2 DIV col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-5896
SELECT DISTINCT + - col2 / col0 FROM tab2 AS cor0
----
-3
0

query I rowsort
SELECT DISTINCT + col2 * ( - cor0.col0 ) - + col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL - col2 + col1 + - col2 FROM tab1 AS cor0
----
-104
-179
-82

query I rowsort
SELECT DISTINCT + col0 + ( + cor0.col1 ) + + col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT + col0 * - col0 - col1 * col0 FROM tab1
----
-4736
-7440
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5901
SELECT DISTINCT + col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5901
SELECT DISTINCT + col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - ( - col0 ) AS col0 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + tab1.col0 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT cor1.col2 + - cor1.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 09528da19a66d24504ef639e7bf26d5b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5905
SELECT ALL + + cor0.col2 + ( 29 ) DIV - cor0.col0 FROM tab0 cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-5905
SELECT ALL + + cor0.col2 + ( 29 ) / - cor0.col0 FROM tab0 cor0
----
1
32
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5906
SELECT col1 DIV - col0 + + col2 FROM tab2 cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-5906
SELECT col1 / - col0 + + col2 FROM tab2 cor0
----
23
26
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5907
SELECT ALL col2 + + CAST( + 15 AS SIGNED ) + + col2 AS col2 FROM tab2 AS cor0
----
67
69
91

skipif mysql # not compatible
query I rowsort label-5907
SELECT ALL col2 + + CAST ( + 15 AS INTEGER ) + + col2 AS col2 FROM tab2 AS cor0
----
67
69
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5908
SELECT - + col2 + CAST( NULL AS SIGNED ) / col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5908
SELECT - + col2 + CAST ( NULL AS INTEGER ) / col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 + + col2 col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col0 * 31 + 57 AS col2 FROM tab0
----
1142
2816
801

query I rowsort
SELECT DISTINCT col1 + ( col1 ) * col2 FROM tab2
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 46 * + cor0.col0 col0 FROM tab1 cor0
----
192
3001
3776

query I rowsort
SELECT DISTINCT tab0.col2 FROM tab0, tab1, tab2 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 27 col2 FROM tab0
----
27

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to d47b3f87370e79c6978209440a41fac4

query I rowsort
SELECT col1 + 71 FROM tab1
----
81
84
97

query I rowsort
SELECT ALL - - col0 * - col1 * + col2 + + cor0.col2 FROM tab1 cor0
----
-36423
-4158
-99744

query I rowsort
SELECT DISTINCT - col0 * + 24 AS col2 FROM tab1 AS cor0
----
-1536
-1920
-72

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab2 cor1, tab2 AS cor2
----
3645 values hashing to db428ec66bce13149e3129b417b0fe94

query I rowsort
SELECT ALL + 93 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT DISTINCT + + col1 + - col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT 79 AS col1 FROM tab2 cor0
----
79
79
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5923
SELECT ALL CAST( NULL AS SIGNED ) FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5923
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 49 FROM tab1, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5925
SELECT ALL + CAST( + 28 AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

skipif mysql # not compatible
query I rowsort label-5925
SELECT ALL + CAST ( + 28 AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT ALL 72 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT col0 + + col1 * ( - 71 + col0 ) FROM tab1 AS cor0
----
-1765
-6
197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 + + col1 + + col1 * - 42 col2 FROM tab0
----
-3493
-3649
-3976

query I rowsort
SELECT DISTINCT 16 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
16

query I rowsort
SELECT - cor0.col1 * - col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5931
SELECT col1 * CAST( col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5931
SELECT col1 * CAST ( col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT cor0.col0 + 67 * - 12 FROM tab0 AS cor0
----
-715
-769
-780

query I rowsort
SELECT + cor0.col2 * + ( cor0.col2 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 8a9dbff4c424879f0bb94abfbb1a134b

query I rowsort
SELECT ALL - 41 FROM tab2, tab0 AS cor0
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

query I rowsort
SELECT DISTINCT - ( + 50 ) + - col1 * col0 + - col2 FROM tab1 cor0
----
-1186
-182
-747

query I rowsort
SELECT - - 76 * 53 + cor0.col1 FROM tab2 cor0
----
4045
4059
4087

query I rowsort
SELECT DISTINCT ( cor0.col2 ) * col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-5938
SELECT col0 + - 90 DIV - col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-5938
SELECT col0 + - 90 / - col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT + - col0 * + ( col1 * cor0.col2 ) + 86 * cor0.col2 + col1 FROM tab1 AS cor0
----
-31568
-91571
458

query I rowsort
SELECT ( - col2 ) * - tab2.col1 * col2 AS col0 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT - ( cor0.col2 ) + - col0 * col0 * col1 + col0 * 29 FROM tab0 cor0
----
-117811
-48873
-718312

query I rowsort
SELECT + + col0 + + cor0.col2 + ( col1 ) FROM tab2 AS cor0
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5943
SELECT - cor0.col0 * cor0.col0 DIV + cor0.col0 + + 15 AS col2 FROM tab0 AS cor0
----
-20
-74
-9

skipif mysql # not compatible
query I rowsort label-5943
SELECT - cor0.col0 * cor0.col0 / + cor0.col0 + + 15 AS col2 FROM tab0 AS cor0
----
-20
-74
-9

query I rowsort
SELECT 89 * 81 * col0 FROM tab1
----
21627
461376
576720

query I rowsort
SELECT + 22 * 69 AS col1 FROM tab0
----
1518
1518
1518

onlyif mysql # use DIV operator for integer division
query I rowsort label-5946
SELECT DISTINCT - col1 DIV 71 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-5946
SELECT DISTINCT - col1 / 71 FROM tab1
----
0

query I rowsort
SELECT - 16 - + tab2.col0 * + 45 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 32eafcd4bcd36b4e1a6f25657ed416d2

query I rowsort
SELECT col0 * 30 * col0 FROM tab2
----
1470
182520
187230

onlyif mysql # use DIV operator for integer division
query I rowsort label-5949
SELECT 46 DIV + 27 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5949
SELECT 46 / + 27 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5950
SELECT - col1 DIV 32 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5950
SELECT - col1 / 32 FROM tab2
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + - cor0.col1 col2 FROM tab2, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + + col0 + + 91 * col2 * col0 FROM tab2 AS cor0
----
17206
184626
273261

query I rowsort
SELECT ALL + - col0 * col2 - col0 AS col0 FROM tab0 AS cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 52 * + col2 col0 FROM tab1 cor0
----
-2808
-2964
-4992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 34 * + ( - col2 ) col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT + - 0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5957
SELECT - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5957
SELECT - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 11 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

onlyif mysql # use DIV operator for integer division
query I rowsort label-5959
SELECT DISTINCT + 99 + tab0.col2 DIV col0 col1 FROM tab0
----
100
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5959
SELECT DISTINCT + 99 + tab0.col2 / col0 col1 FROM tab0
----
100
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5960
SELECT DISTINCT - col0 + col1 DIV col0 AS col1 FROM tab0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-5960
SELECT DISTINCT - col0 + col1 / col0 AS col1 FROM tab0
----
-21
-33
-88

query I rowsort
SELECT 91 * + 82 * + col0 FROM tab1
----
22386
477568
596960

query I rowsort
SELECT ALL - tab2.col0 + + col2 * + col0 FROM tab2
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5963
SELECT col0 DIV - col0 + + col1 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-5963
SELECT col0 / - col0 + + col1 FROM tab2
----
16
30
58

query I rowsort
SELECT - 57 + cor0.col2 * - col2 * ( 40 * col1 ) AS col2 FROM tab2 cor0
----
-1595417
-904017
-981977

onlyif mysql # use DIV operator for integer division
query I rowsort label-5965
SELECT DISTINCT tab0.col0 + - col0 DIV - col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-5965
SELECT DISTINCT tab0.col0 + - col0 / - col2 FROM tab0
----
24
70
90

query I rowsort
SELECT DISTINCT col1 * - col1 + + col2 AS col0 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT + ( 7 * col2 ) + + col0 * + 52 AS col0 FROM tab1
----
3727
4832
534

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5968
SELECT DISTINCT CAST( - col1 AS SIGNED ) + col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-5968
SELECT DISTINCT CAST ( - col1 AS INTEGER ) + col1 FROM tab1
----
0

query I rowsort
SELECT - col2 * col0 + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 36 * col2 col0 FROM tab2
----
-1368
-936
-972

query I rowsort
SELECT ALL - + col2 * col0 * + col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT col0 * col0 + + 35 * - col0 AS col2 FROM tab1
----
-96
1856
3600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5973
SELECT ( + col2 ) DIV col0 - ( col2 * + col0 ) FROM tab1
----
-144
-3648
-7679

skipif mysql # not compatible
query I rowsort label-5973
SELECT ( + col2 ) / col0 - ( col2 * + col0 ) FROM tab1
----
-144
-3648
-7679

query I rowsort
SELECT ( - col2 ) - 61 * col1 AS col0 FROM tab0
----
-5279
-5633
-5918

query I rowsort
SELECT - tab1.col0 - tab1.col0 AS col1 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT + col0 * + cor0.col0 - - cor0.col0 FROM tab2 cor0
----
56
6162
6320

query I rowsort
SELECT col2 * + ( col0 + col1 ) FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT + + col1 + 65 * + ( cor0.col1 + - 5 ) FROM tab1 cor0
----
1391
335
533

query I rowsort
SELECT ALL cor0.col0 + + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - cor0.col2 * 60 + 13 * - col1 FROM tab0 AS cor0
----
-1321
-3098
-6103

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5981
SELECT DISTINCT col1 * + CAST( col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5981
SELECT DISTINCT col1 * + CAST ( col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5982
SELECT ALL col2 DIV - ( + col1 * col0 ) + + 95 DIV + col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5982
SELECT ALL col2 / - ( + col1 * col0 ) + + 95 / + col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL - col0 * 9 + 52 FROM tab2 AS cor0
----
-11
-650
-659

query I rowsort
SELECT + cor0.col0 * - 24 * + 20 FROM tab2 AS cor0
----
-3360
-37440
-37920

query I rowsort
SELECT DISTINCT + col1 - col2 * + col2 AS col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT col1 + - 85 * col1 FROM tab1 AS cor0
----
-1092
-2184
-840

query I rowsort
SELECT ALL + col0 + - col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT 22 * cor1.col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
572
594
836

onlyif mysql # use DIV operator for integer division
query I rowsort label-5989
SELECT ALL - col2 + tab0.col1 + col1 DIV col0 FROM tab0
----
10
56
98

skipif mysql # not compatible
query I rowsort label-5989
SELECT ALL - col2 + tab0.col1 + col1 / col0 FROM tab0
----
10
56
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5990
SELECT - col2 + + 99 * col1 DIV cor0.col0 FROM tab0 AS cor0
----
19
273
321

skipif mysql # not compatible
query I rowsort label-5990
SELECT - col2 + + 99 * col1 / cor0.col0 FROM tab0 AS cor0
----
19
273
321

onlyif mysql # use DIV operator for integer division
query I rowsort label-5991
SELECT DISTINCT col2 + ( col0 ) DIV ( - col1 * col0 + col2 ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5991
SELECT DISTINCT col2 + ( col0 ) / ( - col1 * col0 + col2 ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - ( col1 ) + + cor0.col0 * col0 AS col2 FROM tab0 cor0
----
1128
490
7830

query I rowsort
SELECT ALL + - col1 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + 70 * col0 + col2 + + ( + col2 ) AS col0 FROM tab1 cor0
----
318
4594
5792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 48 * + col0 col0 FROM tab1 AS cor0
----
-30720
-3744
-49920

query I rowsort
SELECT ALL + col0 * col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT + - 71 * - col2 + col2 AS col0 FROM tab1 AS cor0
----
3888
4104
6912

onlyif mysql # use DIV operator for integer division
query I rowsort label-5998
SELECT ALL CAST( col1 AS SIGNED ) DIV col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5998
SELECT ALL CAST ( col1 AS INTEGER ) / col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - col0 + 92 FROM tab1 AS cor0
----
12
28
89

query I rowsort
SELECT + ( - 34 ) * col1 * 68 + + ( - col2 ) FROM tab0 AS cor0
----
-198865
-210474
-224265

query I rowsort
SELECT DISTINCT + + cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ( ( + cor0.col0 ) ) * col2 + 55 + + col0 * ( col0 + + col1 ) * col1 AS col2 FROM tab0 AS cor0
----
1465173
227887
448230

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 3 * - cor0.col1 col0 FROM tab0 AS cor0
----
-258
-273
-291

query I rowsort
SELECT - - 7 + col0 + + col2 FROM tab1 cor0
----
128
183
64

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + col2 * tab1.col2 + col2 + + col1 AS col2 FROM tab1
----
2996
3316
9325

query I rowsort
SELECT tab0.col2 + 75 FROM tab0
----
108
157
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6008
SELECT - cor0.col0 DIV ( cor0.col2 * col2 ) + col1 FROM tab0 AS cor0
----
62
86
91

skipif mysql # not compatible
query I rowsort label-6008
SELECT - cor0.col0 / ( cor0.col2 * col2 ) + col1 FROM tab0 AS cor0
----
62
86
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6009
SELECT - CAST( - 50 AS SIGNED ) col1 FROM tab2 AS cor0
----
50
50
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6009
SELECT - CAST ( - 50 AS INTEGER ) col1 FROM tab2 AS cor0
----
50
50
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6010
SELECT ALL + col0 DIV col0 + - col0 - col0 FROM tab2 AS cor0
----
-13
-155
-157

skipif mysql # not compatible
query I rowsort label-6010
SELECT ALL + col0 / col0 + - col0 - col0 FROM tab2 AS cor0
----
-13
-155
-157

query I rowsort
SELECT ALL 77 * col0 + - 45 FROM tab2 AS cor0
----
494
5961
6038

query I rowsort
SELECT ALL 47 + cor0.col2 * - 21 AS col2 FROM tab1 AS cor0
----
-1087
-1150
-1969

onlyif mysql # use DIV operator for integer division
query I rowsort label-6013
SELECT ALL - - 43 + + col2 DIV 34 AS col0 FROM tab1 AS cor0
----
44
44
45

skipif mysql # not compatible
query I rowsort label-6013
SELECT ALL - - 43 + + col2 / 34 AS col0 FROM tab1 AS cor0
----
44
44
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6014
SELECT DISTINCT + col0 DIV col0 - 56 * - col0 AS col2 FROM tab0 AS cor0
----
1345
1961
4985

skipif mysql # not compatible
query I rowsort label-6014
SELECT DISTINCT + col0 / col0 - 56 * - col0 AS col2 FROM tab0 AS cor0
----
1345
1961
4985

query I rowsort
SELECT DISTINCT 32 * col2 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT ALL + + 6 + col1 * col0 FROM tab2 AS cor0
----
1349
223
4608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * col1 col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - col2 + cor0.col2 * col2 FROM tab1 AS cor0
----
2862
3192
9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 35 + - col0 col2 FROM tab1 AS cor0
----
-29
-45
32

query I rowsort
SELECT DISTINCT + 34 + + col0 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1
-7264
-758

query I rowsort
SELECT - 93 FROM tab1, tab0 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6022
SELECT ALL col1 + - col2 * - CAST( 40 AS SIGNED ) * cor0.col2 + ( col1 ) DIV col1 AS col0 FROM tab1 AS cor0
----
116667
129971
368654

skipif mysql # not compatible
query I rowsort label-6022
SELECT ALL col1 + - col2 * - CAST ( 40 AS INTEGER ) * cor0.col2 + ( col1 ) / col1 AS col0 FROM tab1 AS cor0
----
116667
129971
368654

query I rowsort
SELECT ALL - 2 AS col2 FROM tab1 AS cor0
----
-2
-2
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col2 col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL 93 + col1 FROM tab1 AS cor0
----
103
106
119

query I rowsort
SELECT DISTINCT - col2 + - cor0.col2 + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-14
-23
568

query I rowsort
SELECT DISTINCT + col0 * cor0.col2 + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + + col0 + ( ( - col0 ) ) * col2 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-6029
SELECT ALL + col2 DIV 95 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6029
SELECT ALL + col2 / 95 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - 85 * col2 FROM tab1
----
-4590
-4845
-8160

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6032
SELECT + col1 DIV 77 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6032
SELECT + col1 / 77 AS col0 FROM tab0 AS cor0
----
1
1
1

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab0 AS cor1, tab2, tab0 cor2
----
3645 values hashing to c8e4a9d810c83d17322e338b2adc95b6

query I rowsort
SELECT + + col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT col1 + col2 DIV 53 AS col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6035
SELECT col1 + col2 / 53 AS col2 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT col1 + - col1 * - col0 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-106080
-1488
-358897

query I rowsort
SELECT ALL - tab0.col1 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT 58 AS col0 FROM tab0
----
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6039
SELECT ALL - tab0.col1 + CAST( NULL AS SIGNED ) * - 12 AS col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6039
SELECT ALL - tab0.col1 + CAST ( NULL AS INTEGER ) * - 12 AS col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6040
SELECT + + col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6040
SELECT + + col0 / + col2 AS col0 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - 88 * + cor0.col1 + + 15 * + col0 * col1 AS col0 FROM tab0 cor0
----
113477
23392
42389

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col2 * 83 col2 FROM tab2
----
2158
2241
3154

query I rowsort
SELECT + col1 + - ( cor0.col0 ) FROM tab2 cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6044
SELECT + + col2 + CAST( + col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-6044
SELECT + + col2 + CAST ( + col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - cor0.col0 + 93 FROM tab0 AS cor0
----
4
58
69

query I rowsort
SELECT col2 - - cor0.col0 * + 16 FROM tab2 cor0
----
1274
1302
139

onlyif mysql # use DIV operator for integer division
query I rowsort label-6047
SELECT + - col1 * - ( col2 ) DIV col2 - + cor0.col0 AS col1 FROM tab0 AS cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-6047
SELECT + - col1 * - ( col2 ) / col2 - + cor0.col0 AS col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT - - col0 * col2 + + 1 AS col2 FROM tab2 AS cor0
----
190
2029
3003

query I rowsort
SELECT ALL + 40 + - col1 FROM tab2
----
-19
23
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 63 col2 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT - + col0 + col0 + + col1 * col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + col0 * + col1 * - 16 + - col1 - col2 * + ( - col1 * - col1 ) AS col0 FROM tab0 AS cor0
----
-277178
-63826
-808717

query I rowsort
SELECT - + col0 + + col2 + - col2 * - col0 AS col2 FROM tab1 AS cor0
----
213
3641
7696

query I rowsort
SELECT col0 * ( + 90 ) FROM tab1
----
270
5760
7200

query I rowsort
SELECT cor1.col2 AS col1 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + col1 * ( - 41 + col2 ) * col2 FROM tab1
----
18252
68640
9120

query I rowsort
SELECT ALL 96 FROM tab1, tab0 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT 35 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6059
SELECT CAST( NULL AS SIGNED ) * + 81 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6059
SELECT CAST ( NULL AS INTEGER ) * + 81 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - cor0.col0 col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col0 * + cor0.col2 + + cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT ALL - - 41 * cor0.col0 + + col0 FROM tab0 AS cor0
----
1008
1470
3738

onlyif mysql # use DIV operator for integer division
query I rowsort label-6063
SELECT 81 - col1 DIV col1 AS col2 FROM tab0 AS cor0
----
80
80
80

skipif mysql # not compatible
query I rowsort label-6063
SELECT 81 - col1 / col1 AS col2 FROM tab0 AS cor0
----
80
80
80

query I rowsort
SELECT ALL col0 + col2 * cor0.col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + - ( 81 ) + col0 - col1 FROM tab0 AS cor0
----
-143
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6066
SELECT DISTINCT + 4 DIV - col1 - - col1 FROM tab2 cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6066
SELECT DISTINCT + 4 / - col1 - - col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - col0 * + 72 AS col1 FROM tab1 AS cor0
----
-216
-4608
-5760

query I rowsort
SELECT + 60 + col2 FROM tab1 AS cor0
----
114
117
156

query I rowsort
SELECT - tab2.col2 * - 94 FROM tab2
----
2444
2538
3572

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6070
SELECT + col2 * - CAST( NULL AS DECIMAL ) / + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6070
SELECT + col2 * - CAST ( NULL AS REAL ) / + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - 23 FROM tab1, tab0 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT 16 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
33
47
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6073
SELECT DISTINCT + 86 + - 94 + - tab0.col2 DIV + 97 AS col2 FROM tab0
----
-8

skipif mysql # not compatible
query I rowsort label-6073
SELECT DISTINCT + 86 + - 94 + - tab0.col2 / + 97 AS col2 FROM tab0
----
-8

query I rowsort
SELECT ( col2 ) + col0 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT 84 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

query I rowsort
SELECT ALL + cor0.col2 * - col1 * col2 + cor0.col1 - + col2 AS col1 FROM tab1 AS cor0
----
-119891
-32537
-75844

query I rowsort
SELECT 52 + - col2 AS col1 FROM tab2
----
14
25
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - - 49 * col2 * col2 col2 FROM tab0
----
146
329567
53447

query I rowsort
SELECT + col0 * col0 * - 38 AS col0 FROM tab0
----
-21888
-300998
-46550

query I rowsort
SELECT 86 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT DISTINCT - col0 * col0 - + col0 AS col1 FROM tab1
----
-12
-4160
-6480

query I rowsort
SELECT - col0 + col0 + col1 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT col2 * 27 AS col0 FROM tab2 AS cor0
----
1026
702
729

query I rowsort
SELECT ALL 86 FROM tab1, tab1 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT - col0 * col0 * - ( ( + col1 ) ) FROM tab0
----
118825
49536
720811

query I rowsort
SELECT ALL + col0 + col0 * + ( col2 ) AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - 7 + col0 * cor0.col2 FROM tab1 AS cor0
----
155
3641
7673

onlyif mysql # use DIV operator for integer division
query I rowsort label-6088
SELECT ALL - + cor0.col0 DIV + col1 + 20 DIV 73 AS col0 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-6088
SELECT ALL - + cor0.col0 / + col1 + 20 / 73 AS col0 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT col0 + col1 * - cor0.col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-6090
SELECT + 52 + - col1 DIV + 73 + - 65 AS col0 FROM tab1
----
-13
-13
-13

skipif mysql # not compatible
query I rowsort label-6090
SELECT + 52 + - col1 / + 73 + - 65 AS col0 FROM tab1
----
-13
-13
-13

query I rowsort
SELECT ALL + 23 + + col0 AS col0 FROM tab2 AS cor0
----
101
102
30

query I rowsort
SELECT - 71 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT DISTINCT - - 13 * - cor0.col1 * 22 FROM tab1 AS cor0
----
-2860
-3718
-7436

query I rowsort
SELECT ALL + 17 AS col2 FROM tab2 cor0
----
17
17
17

query I rowsort
SELECT DISTINCT - ( + col1 ) * - col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ( + col0 ) + + 88 * cor0.col1 FROM tab1 AS cor0
----
1224
2291
944

query I rowsort
SELECT ALL + col1 * col0 * col1 + + 19 AS col2 FROM tab0 AS cor0
----
177523
329334
737028

query I rowsort
SELECT ALL 91 + col2 * ( col1 * - col0 ) FROM tab1 AS cor0
----
-36389
-4121
-99749

query I rowsort
SELECT - col2 + col2 * + 52 AS col0 FROM tab2 AS cor0
----
1326
1377
1938

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6100
SELECT - - col2 * - CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6100
SELECT - - col2 * - CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6101
SELECT DISTINCT col1 DIV + 51 AS col0 FROM tab2 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6101
SELECT DISTINCT col1 / + 51 AS col0 FROM tab2 cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6102
SELECT cor0.col0 * - col0 + + 16 DIV col2 + col2 FROM tab1 cor0
----
-4039
-6304
45

skipif mysql # not compatible
query I rowsort label-6102
SELECT cor0.col0 * - col0 + + 16 / col2 + col2 FROM tab1 cor0
----
-4039
-6304
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6103
SELECT - - col0 + + CAST( - 98 AS SIGNED ) * + col2 * - ( col1 ) + + cor0.col2 AS col2 FROM tab2 AS cor0
----
150436
63425
82060

skipif mysql # not compatible
query I rowsort label-6103
SELECT - - col0 + + CAST ( - 98 AS INTEGER ) * + col2 * - ( col1 ) + + cor0.col2 AS col2 FROM tab2 AS cor0
----
150436
63425
82060

query I rowsort
SELECT DISTINCT - col1 + + 87 FROM tab1 AS cor0
----
61
74
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 38 * - col0 + col2 col1 FROM tab0 AS cor0
----
-1329
-3300
-879

query I rowsort
SELECT ALL - col0 * + col0 + col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + + 47 + - col1 AS col0 FROM tab0 AS cor0
----
-39
-44
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6108
SELECT ALL col1 DIV 89 AS col2 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6108
SELECT ALL col1 / 89 AS col2 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT - - 24 * col0 + + cor0.col0 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT DISTINCT 24 AS col2 FROM tab0, tab0 cor0
----
24

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab1 cor1, tab0, tab1 AS cor2
----
3645 values hashing to f464d40c605db608927f2c4d66190a23

query I rowsort
SELECT DISTINCT + + 57 - ( - col2 + + ( - 40 ) ) FROM tab0 AS cor0
----
130
179
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 * + col1 - col1 col1 FROM tab0
----
6020
6370
6790

query I rowsort
SELECT 27 + + 64 FROM tab0
----
91
91
91

query I rowsort
SELECT - 79 - + 54 FROM tab0
----
-133
-133
-133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * + col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col1 * col1 + 84 AS col0 FROM tab2 AS cor0
----
-205
-3397
-877

query I rowsort
SELECT - col2 + - col1 * + col0 AS col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT + 56 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT ALL 64 * col1 + + 91 AS col2 FROM tab2 AS cor0
----
1179
2075
3867

query I rowsort
SELECT - 28 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-1792
-2240
-84

query I rowsort
SELECT DISTINCT - ( + col0 ) + ( + col0 ) + + col0 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + cor0.col1 * - cor0.col2 + - cor0.col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL + 91 * col1 AS col2 FROM tab0 cor0
----
7826
8281
8827

query I rowsort
SELECT DISTINCT ( + col1 ) + col0 * col1 * cor0.col2 + col2 FROM tab0 AS cor0
----
3493
664291
68231

query I rowsort
SELECT 52 FROM tab0, tab1 cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL - 48 + + 96 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6128
SELECT DISTINCT - CAST( col1 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-6128
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - cor0.col2 + + 52 * col0 FROM tab0 AS cor0
----
1215
1819
4546

query I rowsort
SELECT - + col0 + + col0 * cor0.col1 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6131
SELECT ALL + CAST( NULL AS SIGNED ) * 68 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6131
SELECT ALL + CAST ( NULL AS INTEGER ) * 68 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( col0 ) * + col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - ( col0 ) * - cor0.col0 FROM tab2 cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + ( + cor0.col0 ) col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT 16 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT + ( - 7 ) FROM tab2 cor0
----
-7
-7
-7

query I rowsort
SELECT DISTINCT tab1.col2 * + col2 + + col1 AS col1 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT - - col0 * + col0 * col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT - col0 * - col0 * col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT - 60 + + 87 AS col0 FROM tab0 cor0
----
27

query I rowsort
SELECT ALL - 8 * col2 FROM tab1 AS cor0
----
-432
-456
-768

query I rowsort
SELECT ALL - + col2 * 88 - col0 FROM tab1 AS cor0
----
-4755
-5080
-8528

query I rowsort
SELECT DISTINCT - + col0 + 82 * - col0 FROM tab2 AS cor0
----
-581
-6474
-6557

query I rowsort
SELECT + col1 + - col1 + + col1 AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - 43 + - ( cor0.col2 ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 951ae35a5de16a9a5f2aabe2213b673b

query I rowsort
SELECT ALL 92 + col1 * - col1 FROM tab2
----
-197
-3389
-869

query I rowsort
SELECT ALL col2 * + col2 * + col0 FROM tab2
----
114076
5103
52728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6148
SELECT CAST( NULL AS SIGNED ) * - cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6148
SELECT CAST ( NULL AS INTEGER ) * - cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 9 col0 FROM tab1 AS cor0
----
-9
-9
-9

query I rowsort
SELECT DISTINCT - 73 AS col1 FROM tab0 AS cor0
----
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6151
SELECT - + col0 DIV col1 + - 95 AS col2 FROM tab1 AS cor0
----
-101
-101
-95

skipif mysql # not compatible
query I rowsort label-6151
SELECT - + col0 / col1 + - 95 AS col2 FROM tab1 AS cor0
----
-101
-101
-95

query I rowsort
SELECT + ( - col1 ) - cor0.col0 FROM tab0 cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-6153
SELECT + col1 DIV - col0 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6153
SELECT + col1 / - col0 FROM tab1
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - 19 + cor1.col0 ) col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
16
5
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6155
SELECT ( tab1.col2 + col2 ) DIV col0 FROM tab1
----
1
2
36

skipif mysql # not compatible
query I rowsort label-6155
SELECT ( tab1.col2 + col2 ) / col0 FROM tab1
----
1
2
36

query I rowsort
SELECT ALL + cor0.col0 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + + col2 * + cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col2 * 61 AS col1 FROM tab2 AS cor0
----
-1586
-1647
-2318

query I rowsort
SELECT + cor0.col1 + - col0 * ( - col0 ) FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT col0 + + ( - cor0.col0 ) AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6161
SELECT - - col2 DIV + 79 - - col0 * cor0.col1 FROM tab1 AS cor0
----
1041
640
78

skipif mysql # not compatible
query I rowsort label-6161
SELECT - - col2 / + 79 - - col0 * cor0.col1 FROM tab1 AS cor0
----
1041
640
78

query I rowsort
SELECT cor0.col2 + + 89 + col1 * - cor0.col0 AS col0 FROM tab1 cor0
----
-494
-855
65

query I rowsort
SELECT ALL - cor0.col2 * - col0 + - col1 * - col0 FROM tab2 AS cor0
----
406
4345
6630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6164
SELECT ALL + CAST( NULL AS SIGNED ) / col1 + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6164
SELECT ALL + CAST ( NULL AS INTEGER ) / col1 + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col1 + + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL 45 + col0 FROM tab1 AS cor0
----
109
125
48

query I rowsort
SELECT - ( + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL - 28 * cor0.col0 FROM tab2 AS cor0
----
-196
-2184
-2212

onlyif mysql # use DIV operator for integer division
query I rowsort label-6169
SELECT 31 DIV + ( - cor0.col0 ) FROM tab1 AS cor0
----
-10
0
0

skipif mysql # not compatible
query I rowsort label-6169
SELECT 31 / + ( - cor0.col0 ) FROM tab1 AS cor0
----
-10
0
0

query I rowsort
SELECT DISTINCT + 96 FROM tab2, tab2 cor0, tab1 AS cor1
----
96

query I rowsort
SELECT - + col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6172
SELECT col0 * col2 + CAST( + col1 AS SIGNED ) * col1 FROM tab1 AS cor0
----
3748
7849
838

skipif mysql # not compatible
query I rowsort label-6172
SELECT col0 * col2 + CAST ( + col1 AS INTEGER ) * col1 FROM tab1 AS cor0
----
3748
7849
838

query I rowsort
SELECT cor0.col0 - - col2 AS col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6174
SELECT ALL - cor0.col1 * col2 + ( - col2 ) DIV col0 FROM tab0 AS cor0
----
-2839
-7462
-97

skipif mysql # not compatible
query I rowsort label-6174
SELECT ALL - cor0.col1 * col2 + ( - col2 ) / col0 FROM tab0 AS cor0
----
-2839
-7462
-97

query I rowsort
SELECT DISTINCT col1 + + col1 * - 3 AS col1 FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT - 21 AS col0 FROM tab1 AS cor0
----
-21

query I rowsort
SELECT DISTINCT col0 + col2 * - 4 FROM tab2 AS cor0
----
-101
-26
-73

query I rowsort
SELECT ALL - - 89 * - col0 + col1 FROM tab2 AS cor0
----
-592
-6883
-7014

onlyif mysql # use DIV operator for integer division
query I rowsort label-6179
SELECT col0 - - col2 DIV 95 FROM tab1 AS cor0
----
3
64
81

skipif mysql # not compatible
query I rowsort label-6179
SELECT col0 - - col2 / 95 FROM tab1 AS cor0
----
3
64
81

query I rowsort
SELECT - col2 - + cor0.col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + + col2 * + col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - + col0 * col1 + - col0 AS col2 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT ALL - col1 + ( col1 * col2 + + col1 ) FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - col1 - ( col0 ) FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - tab1.col2 * - 85 AS col1 FROM tab1, tab1 AS cor0
----
4590
4845
8160

query I rowsort
SELECT ALL - 48 + - cor0.col0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 4e0f9cbcd69df86b4832a3b8398e5693

query I rowsort
SELECT - 59 * - 47 AS col2 FROM tab1 AS cor0
----
2773
2773
2773

query I rowsort
SELECT ALL 12 FROM tab1, tab0 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT ( + col1 * col2 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - ( tab0.col1 + + col1 ) FROM tab0
----
-172
-182
-194

query I rowsort
SELECT - - ( cor0.col0 ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6192
SELECT ALL col1 + + CAST( - col2 AS SIGNED ) * - cor0.col2 col2 FROM tab1 AS cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6192
SELECT ALL col1 + + CAST ( - col2 AS INTEGER ) * - cor0.col2 col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT - + col1 * 9 FROM tab0 AS cor0
----
-774
-819
-873

onlyif mysql # use DIV operator for integer division
query I rowsort label-6194
SELECT + - col2 + + col2 DIV col0 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-6194
SELECT + - col2 + + col2 / col0 FROM tab1 AS cor0
----
-36
-57
-95

query I rowsort
SELECT DISTINCT - - col2 * ( 1 * - col2 ) AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - col1 * col0 * 51 AS col0 FROM tab0 AS cor0
----
-105264
-173145
-413049

query I rowsort
SELECT + col0 * - cor0.col1 + col2 - ( + col0 ) * col0 FROM tab0 AS cor0
----
-15938
-2607
-4619

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6198
SELECT DISTINCT - ( - ( - col0 ) ) * CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6198
SELECT DISTINCT - ( - ( - col0 ) ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6199
SELECT - CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6199
SELECT - CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + cor0.col1 ) * - cor0.col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL + ( 82 ) + - col1 AS col0 FROM tab2 AS cor0
----
23
51
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 88 + 63 col2 FROM tab1 AS cor0
----
151

onlyif mysql # use DIV operator for integer division
query I rowsort label-6203
SELECT - col1 + + cor0.col1 DIV - col1 FROM tab1 cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-6203
SELECT - col1 + + cor0.col1 / - col1 FROM tab1 cor0
----
-11
-14
-27

query I rowsort
SELECT + + col0 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + 57 + 22 FROM tab0 AS cor0
----
79
79
79

query I rowsort
SELECT - col0 * col0 * + col1 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT + col0 - - col1 * - col0 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-6208
SELECT col2 * - col1 + col2 * - col1 DIV col1 AS col0 FROM tab2 AS cor0
----
-1560
-684
-864

skipif mysql # not compatible
query I rowsort label-6208
SELECT col2 * - col1 + col2 * - col1 / col1 AS col0 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT - 12 * col1 + - tab0.col0 FROM tab0
----
-1056
-1181
-1199

query I rowsort
SELECT DISTINCT 0 * tab1.col2 AS col1 FROM tab1, tab0, tab0 AS cor0
----
0

query I rowsort
SELECT + + 28 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0, tab2 cor2
----
243 values hashing to 59af3451da9c1ccd44e1c1e08d77ef8b

query I rowsort
SELECT - + col1 + col2 * col0 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT 7 AS col0 FROM tab2
----
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6214
SELECT ALL - - col0 DIV - ( - col0 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6214
SELECT ALL - - col0 / - ( - col0 ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + - col1 + col2 * - 94 FROM tab0 AS cor0
----
-191
-3188
-7799

query I rowsort
SELECT - - col1 + 5 AS col2 FROM tab0 AS cor0
----
102
91
96

query I rowsort
SELECT - col2 * + 62 AS col1 FROM tab1 cor0
----
-3348
-3534
-5952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col0 col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6219
SELECT DISTINCT - col2 DIV col0 + + col0 AS col0 FROM tab2 cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-6219
SELECT DISTINCT - col2 / col0 + + col0 AS col0 FROM tab2 cor0
----
4
78
79

query I rowsort
SELECT ALL - col2 * + col1 * ( col1 * - tab1.col0 ) + tab1.col2 AS col1 FROM tab1
----
109566
1298016
364857

query I rowsort
SELECT ALL - ( + col2 ) * 41 + 7 AS col0 FROM tab1
----
-2207
-2330
-3929

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6222
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab1, tab2 AS cor0, tab1 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6222
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab1, tab2 AS cor0, tab1 cor1
----
NULL

query I rowsort
SELECT ALL - col2 + col2 * col2 + - col0 FROM tab2 AS cor0
----
1327
572
695

query I rowsort
SELECT + cor0.col0 * + ( + 61 * - col1 ) + - 28 FROM tab1 AS cor0
----
-39068
-4786
-63468

query I rowsort
SELECT DISTINCT col1 * - 75 - tab0.col0 AS col1 FROM tab0
----
-6474
-6914
-7310

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT 49 + tab1.col0 - col2 * - CAST ( + ( tab1.col1 ) * 83 + col2 AS REAL ) FROM tab1
----
112929
119500
50672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6227
SELECT - CAST( NULL AS SIGNED ) + + 62 AS col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6227
SELECT - CAST ( NULL AS INTEGER ) + + 62 AS col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6228
SELECT DISTINCT - - col1 + cor0.col1 DIV ( + col2 ) AS col0 FROM tab0 cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-6228
SELECT DISTINCT - - col1 + cor0.col1 / ( + col2 ) AS col0 FROM tab0 cor0
----
194
88
92

query I rowsort
SELECT 53 * col2 * - 92 FROM tab2 AS cor0
----
-126776
-131652
-185288

query I rowsort
SELECT ALL + - col2 - - col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - - col0 + + col2 * + col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + + 22 * - col1 * 55 FROM tab1 AS cor0
----
-12100
-15730
-31460

query I rowsort
SELECT DISTINCT + col0 * col0 + + 25 FROM tab2 AS cor0
----
6109
6266
74

query I rowsort
SELECT ALL - - 61 * col1 - - 10 * ( col2 ) AS col0 FROM tab2 AS cor0
----
1417
2161
3859

query I rowsort
SELECT ALL ( 32 ) + col1 * col1 FROM tab2
----
321
3513
993

query I rowsort
SELECT + 62 * 82 + - col1 * - tab1.col1 + - tab1.col1 AS col2 FROM tab1
----
5174
5240
5734

query I rowsort
SELECT ALL ( - col2 ) + col2 * + 52 * col0 FROM tab1
----
189639
399264
8370

query I rowsort
SELECT DISTINCT + col0 + - col0 * col1 * 94 FROM tab1
----
-60096
-7329
-97680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col0 + tab1.col2 * ( + col2 ) col2 FROM tab1
----
2913
3185
9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-6240
SELECT - 46 * + col0 + - cor0.col1 DIV + 38 col1 FROM tab1 AS cor0
----
-138
-2944
-3680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6240
SELECT - 46 * + col0 + - cor0.col1 / + 38 col1 FROM tab1 AS cor0
----
-138
-2944
-3680

query I rowsort
SELECT + col0 + cor0.col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + - ( - cor0.col1 ) + + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - - ( col0 ) * cor0.col1 - col2 * col2 AS col0 FROM tab2 AS cor0
----
-101
-512
3926

query I rowsort
SELECT DISTINCT - 85 * col2 FROM tab1 cor0
----
-4590
-4845
-8160

query I rowsort
SELECT 84 * col1 + + col2 FROM tab0 AS cor0
----
7257
7726
8149

query I rowsort
SELECT ALL - + 83 + - col1 AS col1 FROM tab2 AS cor0
----
-100
-114
-142

query I rowsort
SELECT ALL - cor0.col2 + col0 + col1 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT ALL - - ( - col0 ) * + col0 AS col2 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT col1 * - cor0.col2 + - cor0.col2 FROM tab2 AS cor0
----
-1560
-684
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col1 col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT 14 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT ALL cor0.col0 * - 76 FROM tab2, tab2 AS cor0
----
9 values hashing to ca8e051800d63941b6ac2ce7339fd068

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6253
SELECT 80 + - col2 + - CAST( NULL AS SIGNED ) * - 65 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6253
SELECT 80 + - col2 + - CAST ( NULL AS INTEGER ) * - 65 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 72 * tab2.col2 FROM tab2
----
1872
1944
2736

query I rowsort
SELECT + col2 + - col2 + + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT tab0.col0 * - col2 * col1 AS col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + col2 * - ( 84 + - col0 * 6 ) AS col0 FROM tab2
----
-1134
14820
9984

query I rowsort
SELECT - ( - cor0.col0 ) FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT col2 * ( - tab2.col1 ) + col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT - 10 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT ALL + col0 * 21 AS col2 FROM tab2
----
147
1638
1659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + - col2 col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + - col0 * ( - col2 + - col2 ) AS col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT ALL - + cor0.col1 - 7 AS col2 FROM tab0 AS cor0
----
-104
-93
-98

query I rowsort
SELECT + col0 * col0 + cor0.col2 * col1 AS col1 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT DISTINCT tab0.col2 * 18 FROM tab0
----
1476
18
594

query I rowsort
SELECT col1 - col2 * col0 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-6268
SELECT + cor0.col0 DIV + cor0.col0 FROM tab1, tab0 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-6268
SELECT + cor0.col0 / + cor0.col0 FROM tab1, tab0 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT cor0.col1 + 84 * + col0 AS col2 FROM tab0 AS cor0
----
2102
3037
7567

query I rowsort
SELECT cor0.col0 * 36 * col2 AS col2 FROM tab2 AS cor0
----
108072
6804
73008

query I rowsort
SELECT - col0 - + 76 AS col0 FROM tab2
----
-154
-155
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6272
SELECT DISTINCT - 50 DIV + 96 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6272
SELECT DISTINCT - 50 / + 96 FROM tab2
----
0

query I rowsort
SELECT + 34 * - col2 FROM tab2 AS cor0
----
-1292
-884
-918

query I rowsort
SELECT - - 60 AS col0 FROM tab2 AS cor0
----
60
60
60

query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) * - col2 + cor0.col2 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT 32 * - col0 FROM tab0 AS cor0
----
-1120
-2848
-768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 36 col1 FROM tab0 AS cor0
----
36

query I rowsort
SELECT ALL - 40 * col0 * + col2 FROM tab0 AS cor0
----
-1400
-291920
-31680

query I rowsort
SELECT DISTINCT + col0 + col2 + col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT DISTINCT col1 + col2 * - cor0.col1 AS col0 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL + 62 * col1 - - 81 AS col1 FROM tab2 AS cor0
----
1135
2003
3739

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col1 col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - 9 * cor0.col0 * col2 FROM tab2 cor0
----
-1701
-18252
-27018

query I rowsort
SELECT 72 + col2 * cor0.col0 * + col2 AS col1 FROM tab0 AS cor0
----
107
26208
598508

query I rowsort
SELECT DISTINCT + + ( - col2 ) * 18 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT ALL + + 60 + col2 AS col2 FROM tab2 AS cor0
----
86
87
98

query I rowsort
SELECT tab1.col0 + - col2 - col0 FROM tab1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6288
SELECT DISTINCT col2 * + col1 * + col2 + - col2 + + CAST( + col1 AS SIGNED ) FROM tab2
----
22603
24527
39917

skipif mysql # not compatible
query I rowsort label-6288
SELECT DISTINCT col2 * + col1 * + col2 + - col2 + + CAST ( + col1 AS INTEGER ) FROM tab2
----
22603
24527
39917

query I rowsort
SELECT DISTINCT + col0 * col2 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col1 * ( 72 ) + col0 AS col0 FROM tab2 AS cor0
----
1303
2239
4326

query I rowsort
SELECT - - col2 + col1 AS col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL - + 56 + - col1 AS col0 FROM tab2 cor0
----
-115
-73
-87

query I rowsort
SELECT cor1.col1 * 26 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a84859fb4b95c35066fee6e99fcf3ea6

query I rowsort
SELECT - ( 84 ) FROM tab2 AS cor0
----
-84
-84
-84

query I rowsort
SELECT + - ( - col2 ) * cor0.col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - ( - col0 ) * - col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT 5 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT + col1 * - cor0.col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col0 * + col2 + col2 AS col1 FROM tab1 cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + cor0.col1 col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + col2 - 93 AS col2 FROM tab0 AS cor0
----
-11
-60
-92

query I rowsort
SELECT DISTINCT - cor0.col0 + + ( 44 ) AS col1 FROM tab0 AS cor0
----
-45
20
9

query I rowsort
SELECT DISTINCT col0 * col0 + - col1 AS col2 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT col1 + + cor0.col2 * - col2 FROM tab0 cor0
----
-1003
-6633
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + - col1 col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT + cor0.col0 * ( 28 ) FROM tab0 AS cor0
----
2492
672
980

query I rowsort
SELECT + 32 AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT ALL col1 * col0 + col1 AS col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT + col2 + - col2 * col2 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT ALL 32 + + tab2.col1 * + col2 FROM tab2
----
1566
678
869

query I rowsort
SELECT ALL 25 + + col1 AS col0 FROM tab1
----
35
38
51

query I rowsort
SELECT ( 89 + - cor0.col1 ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 69082cf44f6eadcf1913a733758c21f2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6313
SELECT DISTINCT + col1 * - 92 + ( col2 * CAST( NULL AS SIGNED ) ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6313
SELECT DISTINCT + col1 * - 92 + ( col2 * CAST ( NULL AS INTEGER ) ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 + - ( col2 ) FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL col0 * ( + 30 ) FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT DISTINCT + col1 * col1 + ( - col1 ) + col0 FROM tab2 AS cor0
----
3500
351
937

query I rowsort
SELECT ALL col0 * - col1 * col1 + col1 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT DISTINCT - col1 - ( + col2 ) * col2 AS col2 FROM tab1 cor0
----
-2942
-3259
-9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * col0 - - col2 col2 FROM tab1
----
270
3762
7872

query I rowsort
SELECT - tab0.col2 * col1 * col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL col0 + tab0.col1 + col0 * + col2 FROM tab0
----
167
7478
902

query I rowsort
SELECT ALL col2 * - tab1.col2 AS col0 FROM tab1 WHERE - col1 * - col0 NOT BETWEEN NULL AND + col0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT col0 + col2 * + col1 + col0 AS col2 FROM tab1
----
1408
1410
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-6324
SELECT DISTINCT tab1.col1 DIV + col0 FROM tab1
----
0
8

skipif mysql # not compatible
query I rowsort label-6324
SELECT DISTINCT tab1.col1 / + col0 FROM tab1
----
0
8

query I rowsort
SELECT - col0 * col1 * col0 + + col0 FROM tab2
----
-106018
-1512
-358878

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL IN ( - col1 * - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6327
SELECT ALL col0 DIV col1 + - col0 col2 FROM tab0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6327
SELECT ALL col0 / col1 + - col0 col2 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT ALL - col2 * tab1.col1 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col2 / col1 FROM tab1 WHERE NOT ( NULL ) IN ( col0 + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6330
SELECT DISTINCT col0 * - col2 + + col2 DIV tab0.col1 + col1 * col2 * + col1 AS col0 FROM tab0
----
243276
671744
9374

skipif mysql # not compatible
query I rowsort label-6330
SELECT DISTINCT col0 * - col2 + + col2 / tab0.col1 + col1 * col2 * + col1 AS col0 FROM tab0
----
243276
671744
9374

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL IN ( col2 + col0 / col1 )
----

query I rowsort
SELECT ALL + + 56 + col2 - + 79 * 41 FROM tab0 AS cor0
----
-3101
-3150
-3182

query I rowsort
SELECT DISTINCT + 92 * col1 AS col0 FROM tab2 AS cor0
----
1564
2852
5428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6334
SELECT - col1 * - cor0.col2 + - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6334
SELECT - col1 * - cor0.col2 + - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 13 + - tab1.col2 FROM tab1
----
-41
-44
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 45 * + col0 * + col1 col0 FROM tab0 AS cor0
----
152775
364455
92880

query I rowsort
SELECT + cor0.col1 * col2 - col0 * 97 AS col2 FROM tab0 AS cor0
----
-1171
-3298
510

query I rowsort
SELECT ALL - col0 * + col2 * - 89 + col0 FROM tab0 AS cor0
----
3150
649611
70512

query I rowsort
SELECT ALL col2 * - col0 * + ( - tab2.col0 + - col2 ) AS col1 FROM tab2
----
210912
351234
6426

query I rowsort
SELECT ALL + - cor0.col2 + col0 FROM tab2 cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6341
SELECT ALL + 57 DIV + col0 FROM tab2
----
0
0
8

skipif mysql # not compatible
query I rowsort label-6341
SELECT ALL + 57 / + col0 FROM tab2
----
0
0
8

query I rowsort
SELECT DISTINCT + 29 + col2 AS col0 FROM tab1 AS cor0
----
125
83
86

query I rowsort
SELECT + + col2 * cor0.col0 - - cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT 6 + col2 AS col2 FROM tab1 AS cor0
----
102
60
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6345
SELECT cor0.col1 * + CAST( + cor0.col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-6345
SELECT cor0.col1 * + CAST ( + cor0.col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - - col2 * col1 + 41 FROM tab1 AS cor0
----
1289
1445
611

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6347
SELECT + col0 + - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6347
SELECT + col0 + - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6348
SELECT col2 + tab1.col1 * ( col2 ) DIV + col1 FROM tab1
----
108
114
192

skipif mysql # not compatible
query I rowsort label-6348
SELECT col2 + tab1.col1 * ( col2 ) / + col1 FROM tab1
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 1 ) col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT col0 + 0 * - col1 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + 31 + + col0 * + col1 FROM tab1 AS cor0
----
1071
109
671

query I rowsort
SELECT ALL - 35 + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-2063
-224
-3037

query I rowsort
SELECT DISTINCT - col0 * + col1 + - col0 * ( 1 ) AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL - - 41 * + cor0.col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
1125
1138
1575

onlyif mysql # use DIV operator for integer division
query I rowsort label-6355
SELECT + ( col1 ) * + col1 + - col0 DIV - col2 col2 FROM tab0
----
7396
8282
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6355
SELECT + ( col1 ) * + col1 + - col0 / - col2 col2 FROM tab0
----
7396
8282
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 26 + 93 col0 FROM tab2
----
119

query I rowsort
SELECT + + cor0.col0 - col0 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + col1 + col1 col2 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT 86 * + col0 AS col1 FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT ALL col0 * col2 + col1 AS col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT + ( col2 * + col0 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + 56 + cor0.col1 FROM tab2, tab1, tab0 AS cor0
----
142
147
153

query I rowsort
SELECT col0 * - col0 * col2 AS col0 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT ALL 97 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6365
SELECT - cor0.col1 * CAST( col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-6365
SELECT - cor0.col1 * CAST ( col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6366
SELECT col2 * 54 DIV + col0 AS col2 FROM tab0 AS cor0
----
1
49
74

skipif mysql # not compatible
query I rowsort label-6366
SELECT col2 * 54 / + col0 AS col2 FROM tab0 AS cor0
----
1
49
74

query I rowsort
SELECT DISTINCT + 55 * 0 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6368
SELECT 19 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-19
0
0

skipif mysql # not compatible
query I rowsort label-6368
SELECT 19 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-19
0
0

query I rowsort
SELECT ALL + col0 * + col2 + + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + tab1.col2 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT col2 * 46 FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT + 34 * col0 + - col1 * col2 FROM tab0 AS cor0
----
-2022
-4436
1093

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 77 col0 FROM tab0 AS cor0
----
-77
-77
-77

query I rowsort
SELECT + tab1.col0 AS col0 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT + 39 FROM tab0, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 72 col1 FROM tab2
----
504
5616
5688

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6377
SELECT DISTINCT CAST( - 38 AS SIGNED ) col1 FROM tab1
----
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6377
SELECT DISTINCT CAST ( - 38 AS INTEGER ) col1 FROM tab1
----
-38

query I rowsort
SELECT DISTINCT 66 FROM tab1, tab2 AS cor0
----
66

query I rowsort
SELECT col1 + cor0.col0 * 34 FROM tab0 AS cor0
----
1287
3117
902

query I rowsort
SELECT - 79 * cor0.col0 FROM tab2 AS cor0
----
-553
-6162
-6241

query I rowsort
SELECT DISTINCT + + col0 * - col1 + col2 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT + 81 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT DISTINCT col1 * col2 * + tab1.col0 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + col2 - 32 FROM tab1 AS cor0
----
22
25
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-6385
SELECT + - col2 + col0 DIV - col1 FROM tab2 AS cor0
----
-27
-27
-42

skipif mysql # not compatible
query I rowsort label-6385
SELECT + - col2 + col0 / - col1 FROM tab2 AS cor0
----
-27
-27
-42

query I rowsort
SELECT ALL + + col1 + col2 + 44 FROM tab0 AS cor0
----
142
163
217

query I rowsort
SELECT DISTINCT + col2 + - col1 AS col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ALL - + col2 * - 35 - col0 FROM tab0 AS cor0
----
0
1131
2781

query I rowsort
SELECT col1 + ( col1 ) * cor0.col2 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT 9 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

query I rowsort
SELECT - col0 * + 11 AS col2 FROM tab0 AS cor0
----
-264
-385
-979

query I rowsort
SELECT + + col2 * - col1 + - col2 AS col0 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL - cor0.col0 + + 81 AS col0 FROM tab0 AS cor0
----
-8
46
57

query I rowsort
SELECT - col1 + + 57 * + col0 FROM tab0 AS cor0
----
1282
1898
4982

onlyif mysql # use DIV operator for integer division
query I rowsort label-6395
SELECT DISTINCT col0 + col1 + 55 DIV - col0 AS col0 FROM tab2 AS cor0
----
137
31
96

skipif mysql # not compatible
query I rowsort label-6395
SELECT DISTINCT col0 + col1 + 55 / - col0 AS col0 FROM tab2 AS cor0
----
137
31
96

query I rowsort
SELECT 27 * col2 AS col1 FROM tab2
----
1026
702
729

query I rowsort
SELECT + - cor0.col2 + 48 * + col2 FROM tab1 AS cor0
----
2538
2679
4512

query I rowsort
SELECT + ( - col1 ) * col0 * ( ( col0 ) ) AS col2 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT - 96 * 80 - col1 FROM tab1 cor0
----
-7690
-7693
-7706

query I rowsort
SELECT col2 * + 57 AS col2 FROM tab2 AS cor0
----
1482
1539
2166

onlyif mysql # use DIV operator for integer division
query I rowsort label-6401
SELECT - 69 DIV cor0.col1 - 34 FROM tab2 AS cor0
----
-35
-36
-38

skipif mysql # not compatible
query I rowsort label-6401
SELECT - 69 / cor0.col1 - 34 FROM tab2 AS cor0
----
-35
-36
-38

query I rowsort
SELECT + col0 + col2 * 24 * col2 + cor0.col1 * col1 AS col1 FROM tab0 AS cor0
----
169746
33556
9468

query I rowsort
SELECT - - col0 * col0 - + col1 AS col0 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT + col1 * - col1 - + 81 AS col2 FROM tab1 AS cor0
----
-181
-250
-757

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6405
SELECT - CAST( cor0.col0 AS SIGNED ) FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

skipif mysql # not compatible
query I rowsort label-6405
SELECT - CAST ( cor0.col0 AS INTEGER ) FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT + - 63 * - col1 + col2 AS col1 FROM tab2 AS cor0
----
1109
1980
3743

query I rowsort
SELECT DISTINCT + + cor0.col0 + - 85 FROM tab0 AS cor0
----
-50
-61
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6408
SELECT DISTINCT - - col1 DIV - col0 + col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-7
1

skipif mysql # not compatible
query I rowsort label-6408
SELECT DISTINCT - - col1 / - col0 + col0 / col0 AS col2 FROM tab1 AS cor0
----
-7
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6409
SELECT DISTINCT - col2 + col2 - col1 DIV col0 AS col2 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-6409
SELECT DISTINCT - col2 + col2 - col1 / col0 AS col2 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT DISTINCT 65 * col2 * + col0 + + 85 FROM tab0 AS cor0
----
2360
474455
51565

query I rowsort
SELECT + ( 87 ) AS col0 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT col1 * + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT - + 75 + + 76 * col1 AS col1 FROM tab0 AS cor0
----
6461
6841
7297

query I rowsort
SELECT ALL + - ( + col1 ) * - col0 + 70 FROM tab1 AS cor0
----
1110
148
710

query I rowsort
SELECT DISTINCT + 27 * col1 AS col2 FROM tab2 AS cor0
----
1593
459
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6416
SELECT + col1 DIV + tab1.col2 + + 38 + col2 AS col2 FROM tab1
----
134
92
95

skipif mysql # not compatible
query I rowsort label-6416
SELECT + col1 / + tab1.col2 + + 38 + col2 AS col2 FROM tab1
----
134
92
95

query I rowsort
SELECT DISTINCT col2 * 73 + - col2 - - col0 FROM tab1
----
3891
4168
6992

query I rowsort
SELECT ALL + col2 - - 47 AS col2 FROM tab2
----
73
74
85

query I rowsort
SELECT ALL col0 - + col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6420
SELECT ALL CAST( - col0 AS SIGNED ) * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-6420
SELECT ALL CAST ( - col0 AS INTEGER ) * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT + col2 + - col2 * + cor0.col0 * - col0 AS col1 FROM tab1 cor0
----
233529
540
614496

onlyif mysql # use DIV operator for integer division
query I rowsort label-6422
SELECT DISTINCT - ( + col2 ) DIV col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6422
SELECT DISTINCT - ( + col2 ) / col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col1 * - col2 + col1 * 61 FROM tab0 AS cor0
----
-1911
2408
5820

query I rowsort
SELECT - col1 + - ( - col1 ) - + 80 FROM tab1 AS cor0
----
-80
-80
-80

query I rowsort
SELECT ALL col2 + - col0 * + cor0.col0 * - col1 - + col1 * - col0 AS col2 FROM tab0 AS cor0
----
122221
51633
728992

query I rowsort
SELECT ALL 0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 * + 72 AS col1 FROM tab0 cor0
----
-1728
-2520
-6408

query I rowsort
SELECT + + 78 * - 26 + col2 AS col1 FROM tab2 AS cor0
----
-1990
-2001
-2002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6429
SELECT col2 + - col0 DIV col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6429
SELECT col2 + - col0 / col1 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - tab2.col0 * col1 * - col1 + - col0 + col1 AS col2 FROM tab2
----
22769
271499
6751

query I rowsort
SELECT ALL col1 + col2 * - col0 * col1 AS col0 FROM tab1
----
-36470
-4186
-99827

query I rowsort
SELECT tab1.col2 * + ( col2 + + col0 * col0 ) AS col1 FROM tab1
----
236721
3402
623616

query I rowsort
SELECT DISTINCT + - col0 - - ( + cor0.col2 * cor0.col2 + + 51 ) AS col0 FROM tab2 AS cor0
----
1416
649
773

query I rowsort
SELECT ALL + col0 * col1 + - col2 * col1 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT + + col0 - - 93 * 59 AS col1 FROM tab2 AS cor0
----
5494
5565
5566

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6436
SELECT + + cor0.col0 * CAST( NULL AS SIGNED ) - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6436
SELECT + + cor0.col0 * CAST ( NULL AS INTEGER ) - col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + ( col2 ) * col2 + + ( + col0 * - col2 ) FROM tab0 AS cor0
----
-33
-492
330

query I rowsort
SELECT col1 - 4 * col1 FROM tab2 AS cor0
----
-177
-51
-93

query I rowsort
SELECT col0 * col1 + col0 * col1 * + col0 FROM tab0
----
122220
51600
728910

onlyif mysql # use DIV operator for integer division
query I rowsort label-6440
SELECT 22 - - col1 DIV - ( - ( - col1 ) ) AS col0 FROM tab1
----
21
21
21

skipif mysql # not compatible
query I rowsort label-6440
SELECT 22 - - col1 / - ( - ( - col1 ) ) AS col0 FROM tab1
----
21
21
21

query I rowsort
SELECT ALL + ( - 94 ) * tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to afe37441cf632821cf92c0df6d8450cd

query I rowsort
SELECT ALL + col1 * col2 + tab0.col2 AS col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL + col2 + + ( col2 ) FROM tab0
----
164
2
66

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 + col0 col1 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6446
SELECT col1 + + CAST( NULL AS DECIMAL ) / + 5 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6446
SELECT col1 + + CAST ( NULL AS REAL ) / + 5 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * - col1 + col2 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL - col0 * col0 + + col2 * - cor0.col0 FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT ALL + cor0.col1 + col1 * col0 + - col0 * - ( - col1 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + ( 74 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT - cor0.col2 * - 86 + + col0 FROM tab1 AS cor0
----
4647
4966
8336

query I rowsort
SELECT + col0 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - + col0 * 37 + col1 AS col1 FROM tab1 AS cor0
----
-2358
-2947
-85

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to 71d467ba3372dfdd21847af1687c92e7

query I rowsort
SELECT DISTINCT col1 * 51 + col1 AS col1 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT + + col0 + 81 AS col0 FROM tab0 AS cor0
----
105
116
170

query I rowsort
SELECT ALL + - col2 + + 10 * 36 * col2 FROM tab0 AS cor0
----
11847
29438
359

query I rowsort
SELECT tab0.col0 * 56 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to d1295769527fdb3bb68dd06d7a020cfe

query I rowsort
SELECT ALL 30 * col1 * + col2 + + 50 AS col2 FROM tab2 AS cor0
----
19430
25160
46070

query I rowsort
SELECT ALL + - ( - 3 ) - col1 FROM tab2 AS cor0
----
-14
-28
-56

query I rowsort
SELECT cor1.col0 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - + 15 FROM tab2 AS cor0
----
-15

query I rowsort
SELECT DISTINCT ( col2 + col2 ) FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT - 80 * col1 FROM tab0
----
-6880
-7280
-7760

query I rowsort
SELECT DISTINCT + 36 AS col0 FROM tab2
----
36

query I rowsort
SELECT - cor0.col0 * - col1 - + col0 AS col2 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6467
SELECT DISTINCT col0 * + col0 * + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6467
SELECT DISTINCT col0 * + col0 * + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6468
SELECT ALL - 10 DIV - col0 FROM tab1
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6468
SELECT ALL - 10 / - col0 FROM tab1
----
0
0
3

query I rowsort
SELECT ALL - 33 AS col2 FROM tab1 AS cor0
----
-33
-33
-33

query I rowsort
SELECT ALL cor0.col0 * col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 23 * col1 + + tab2.col0 AS col1 FROM tab2
----
1435
470
720

query I rowsort
SELECT ALL - + cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 95 AS col0 FROM tab1 cor0
----
95
95
95

query I rowsort
SELECT DISTINCT + - 18 FROM tab2 cor0
----
-18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6475
SELECT + cor0.col1 * - CAST( NULL AS SIGNED ) / - 16 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6475
SELECT + cor0.col1 * - CAST ( NULL AS INTEGER ) / - 16 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6476
SELECT + col1 * CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6476
SELECT + col1 * CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - cor0.col0 AS col1 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - col2 + 47 FROM tab0 AS cor0
----
-35
14
46

query I rowsort
SELECT ALL + col0 * - 91 FROM tab1 AS cor0
----
-273
-5824
-7280

query I rowsort
SELECT DISTINCT 75 AS col1 FROM tab0
----
75

query I rowsort
SELECT 64 + col1 AS col2 FROM tab2
----
123
81
95

query I rowsort
SELECT + 83 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6483
SELECT - col1 DIV ( cor0.col1 ) FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6483
SELECT - col1 / ( cor0.col1 ) FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col2 * - tab2.col2 * - col2 FROM tab2
----
17576
19683
54872

query I rowsort
SELECT DISTINCT - 78 FROM tab0, tab2 AS cor0
----
-78

query I rowsort
SELECT + + col0 + + col2 * col2 + col2 FROM tab2 AS cor0
----
1561
763
780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( col0 ) + + col2 col0 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6488
SELECT + CAST( NULL AS DECIMAL ) + + col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6488
SELECT + CAST ( NULL AS REAL ) + + col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col2 + - 20 + + col1 FROM tab1 AS cor0
----
47
60
89

query I rowsort
SELECT ALL 74 * - col1 + - ( cor0.col0 ) FROM tab2 AS cor0
----
-1337
-2301
-4444

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6491
SELECT ALL - CAST( NULL AS SIGNED ) + 10 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6491
SELECT ALL - CAST ( NULL AS INTEGER ) + 10 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + + 50 FROM tab0, tab2 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT ALL - - col0 + - col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + col2 * 16 + + cor0.col2 + - col1 AS col2 FROM tab2 AS cor0
----
383
428
629

onlyif mysql # use DIV operator for integer division
query I rowsort label-6495
SELECT col2 DIV 72 AS col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6495
SELECT col2 / 72 AS col1 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6496
SELECT + col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6496
SELECT + col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - 89 + + col2 FROM tab0 AS cor0
----
-7621
-8017
-8632

query I rowsort
SELECT cor0.col0 + col2 * col2 * col2 FROM tab2 AS cor0
----
17654
19690
54951

query I rowsort
SELECT - 7 + - col2 AS col0 FROM tab0 AS cor0
----
-40
-8
-89

query I rowsort
SELECT + ( + cor0.col2 ) * - col2 * col1 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT col2 + 71 FROM tab2 AS cor0
----
109
97
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6502
SELECT + CAST( NULL AS SIGNED ) * 64 + col2 * + CAST( - 30 AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6502
SELECT + CAST ( NULL AS INTEGER ) * 64 + col2 * + CAST ( - 30 AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - cor0.col1 ) + col1 + ( - 11 ) AS col2 FROM tab2 AS cor0
----
107
23
51

query I rowsort
SELECT DISTINCT - col1 * + 67 FROM tab2
----
-1139
-2077
-3953

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + col2 col1 FROM tab1
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6506
SELECT ALL - col2 + - col2 * + col2 + - ( + 21 ) DIV + col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

skipif mysql # not compatible
query I rowsort label-6506
SELECT ALL - col2 + - col2 * + col2 + - ( + 21 ) / + col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT ALL + ( col1 ) + - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + + 20 FROM tab0 AS cor0
----
20
20
20

query I rowsort
SELECT - - 53 * + cor0.col2 - - col2 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT 87 * - 59 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to a73d6a739ed48c56594d4c69aa7134a6

query I rowsort
SELECT DISTINCT - - 80 FROM tab1 cor0
----
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6512
SELECT + col0 - 61 DIV col0 AS col2 FROM tab2 cor0
----
-1
78
79

skipif mysql # not compatible
query I rowsort label-6512
SELECT + col0 - 61 / col0 AS col2 FROM tab2 cor0
----
-1
78
79

query I rowsort
SELECT DISTINCT + 43 * + 56 - + cor0.col1 AS col1 FROM tab2 AS cor0
----
2349
2377
2391

query I rowsort
SELECT - ( col2 + - col1 ) FROM tab1
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6515
SELECT DISTINCT tab1.col0 * - col2 + col1 DIV + col2 - col1 DIV col0 AS col1 FROM tab1
----
-170
-3648
-7680

skipif mysql # not compatible
query I rowsort label-6515
SELECT DISTINCT tab1.col0 * - col2 + col1 / + col2 - col1 / col0 AS col1 FROM tab1
----
-170
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6516
SELECT DISTINCT - 24 DIV col0 FROM tab2 cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-6516
SELECT DISTINCT - 24 / col0 FROM tab2 cor0
----
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6518
SELECT - 75 DIV + col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6518
SELECT - 75 / + col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT DISTINCT col0 * col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL + 27 * col0 AS col2 FROM tab0 AS cor0
----
2403
648
945

query I rowsort
SELECT ALL 60 + col2 AS col1 FROM tab0 AS cor0
----
142
61
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6522
SELECT - col1 + + col1 * - cor0.col2 + 11 DIV - col1 col2 FROM tab2 AS cor0
----
-1593
-663
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6522
SELECT - col1 + + col1 * - cor0.col2 + 11 / - col1 col2 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6523
SELECT ALL col1 DIV - col2 + tab1.col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6523
SELECT ALL col1 / - col2 + tab1.col0 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - tab0.col1 + - col0 col1 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT tab2.col2 + 2 AS col0 FROM tab2
----
28
29
40

query I rowsort
SELECT DISTINCT cor0.col0 + - 85 FROM tab2 AS cor0
----
-6
-7
-78

query I rowsort
SELECT ALL + + col2 * + 14 + - cor0.col1 FROM tab0 AS cor0
----
-83
1057
376

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 * + col1 col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT - col1 * - ( 21 ) AS col2 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT DISTINCT - - col1 + + ( + cor0.col2 ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL - + col1 + 97 AS col1 FROM tab1 cor0
----
71
84
87

query I rowsort
SELECT DISTINCT col1 * - col2 + col1 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + - col1 + + 96 AS col0 FROM tab1 cor0
----
70
83
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-6534
SELECT ALL + + cor0.col0 DIV + 10 FROM tab1 AS cor0
----
0
6
8

skipif mysql # not compatible
query I rowsort label-6534
SELECT ALL + + cor0.col0 / + 10 FROM tab1 AS cor0
----
0
6
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - 22 + col2 col1 FROM tab1 AS cor0
----
-163
-190
-518

query I rowsort
SELECT ALL 10 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2, tab0 AS cor3
----
243 values hashing to 75ac55f1d3b666f2332e2c4bb542aa66

query I rowsort
SELECT ALL 27 + - tab0.col2 FROM tab0
----
-55
-6
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ALL + - 6 + col0 FROM tab2 AS cor0
----
1
72
73

query I rowsort
SELECT DISTINCT 40 + + col1 FROM tab2 AS cor0
----
57
71
99

query I rowsort
SELECT DISTINCT col2 - + cor0.col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT - col1 * - col2 + col0 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT - 40 AS col2 FROM tab0 cor0
----
-40

query I rowsort
SELECT ALL - + cor0.col2 - col2 * + col0 * col1 FROM tab1 cor0
----
-36537
-4266
-99936

query I rowsort
SELECT - + col0 - - 48 * - col0 AS col1 FROM tab1 AS cor0
----
-147
-3136
-3920

query I rowsort
SELECT DISTINCT + + cor0.col2 * col2 + 18 AS col2 FROM tab0 AS cor0
----
1107
19
6742

query I rowsort
SELECT - - col1 * + col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL + col2 - - ( - col2 ) AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - col0 * col1 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 64 + - tab1.col0 * 51 FROM tab1
----
-3200
-4016
-89

query I rowsort
SELECT 5 * + col0 + col2 AS col1 FROM tab0
----
153
176
527

onlyif mysql # use DIV operator for integer division
query I rowsort label-6552
SELECT + col2 + col2 DIV col0 AS col1 FROM tab0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-6552
SELECT + col2 + col2 / col0 AS col1 FROM tab0
----
1
34
82

query I rowsort
SELECT DISTINCT 78 + col2 * - 25 FROM tab1
----
-1272
-1347
-2322

onlyif mysql # use DIV operator for integer division
query I rowsort label-6554
SELECT DISTINCT - col1 * tab0.col2 + ( col2 ) DIV tab0.col1 FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-6554
SELECT DISTINCT - col1 * tab0.col2 + ( col2 ) / tab0.col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - col1 * + cor0.col2 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT + col0 + 23 AS col2 FROM tab0 AS cor0
----
112
47
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 - col0 * - cor0.col0 col2 FROM tab0 AS cor0
----
1322
662
8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( + col1 ) col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + col0 + - 97 AS col2 FROM tab2 AS cor0
----
-18
-19
-90

query I rowsort
SELECT col2 + - tab1.col1 * col1 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL - cor0.col2 + - 25 * col1 AS col0 FROM tab2 AS cor0
----
-1501
-463
-802

query I rowsort
SELECT + - col0 + + col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT DISTINCT - col2 * 68 * col0 FROM tab0 AS cor0
----
-2380
-496264
-53856

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6564
SELECT ALL - CAST( NULL AS SIGNED ) * + col0 + - col0 + - 39 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6564
SELECT ALL - CAST ( NULL AS INTEGER ) * + col0 + - col0 + - 39 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 49 AS col1 FROM tab2 cor0
----
49
49
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + 8 * col2 col2 FROM tab2 AS cor0
----
130
209
225

query I rowsort
SELECT - cor0.col2 * + cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 315ab91f9844de122b0c28cd16e982e4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6568
SELECT DISTINCT - 55 + col2 + col0 DIV col1 AS col1 FROM tab2 AS cor0
----
-13
-28

skipif mysql # not compatible
query I rowsort label-6568
SELECT DISTINCT - 55 + col2 + col0 / col1 AS col1 FROM tab2 AS cor0
----
-13
-28

query I rowsort
SELECT ALL + col2 * - 97 + - col1 * - 97 AS col2 FROM tab0 cor0
----
5141
873
9312

query I rowsort
SELECT DISTINCT + 35 + - ( + col0 ) AS col2 FROM tab2 AS cor0
----
-43
-44
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-6571
SELECT - 57 DIV + col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6571
SELECT - 57 / + col2 AS col0 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT 93 - + col1 AS col2 FROM tab2
----
34
62
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 11 * col0 col0 FROM tab1 cor0
----
33
704
880

query I rowsort
SELECT + + 97 AS col2 FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT DISTINCT 34 FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) col2 FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6577
SELECT + cor0.col1 + - col0 * CAST( + 87 AS SIGNED ) FROM tab2 AS cor0
----
-578
-6727
-6856

skipif mysql # not compatible
query I rowsort label-6577
SELECT + cor0.col1 + - col0 * CAST ( + 87 AS INTEGER ) FROM tab2 AS cor0
----
-578
-6727
-6856

query I rowsort
SELECT DISTINCT - 28 * ( col0 ) FROM tab2
----
-196
-2184
-2212

query I rowsort
SELECT DISTINCT + ( col2 * + col1 ) FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6580
SELECT DISTINCT + 55 DIV - 75 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-6580
SELECT DISTINCT + 55 / - 75 FROM tab1
----
0

query I rowsort
SELECT col0 + col1 * + col2 * ( col0 ) FROM tab2
----
119730
51113
5866

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 99 col0 FROM tab1 AS cor0
----
99

query I rowsort
SELECT + 24 * cor0.col1 * + cor0.col1 FROM tab2 AS cor0
----
23064
6936
83544

query I rowsort
SELECT - col2 * - col2 AS col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT cor0.col2 * - 4 * 48 FROM tab0, tab2 AS cor0
----
-4992
-5184
-7296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6586
SELECT - col2 * - CAST( - 5 + col1 AS SIGNED ) * + 23 FROM tab0
----
162196
2116
61479

skipif mysql # not compatible
query I rowsort label-6586
SELECT - col2 * - CAST ( - 5 + col1 AS INTEGER ) * + 23 FROM tab0
----
162196
2116
61479

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6587
SELECT - tab1.col0 * CAST( NULL AS SIGNED ) * col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6587
SELECT - tab1.col0 * CAST ( NULL AS INTEGER ) * col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 72 AS col0 FROM tab2, tab0 AS cor0
----
-72

query I rowsort
SELECT ALL - col2 * 53 FROM tab1
----
-2862
-3021
-5088

query I rowsort
SELECT DISTINCT - tab0.col2 * + 24 AS col1 FROM tab0
----
-1968
-24
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6591
SELECT - 85 + - ( tab1.col2 ) DIV col1 AS col0 FROM tab1
----
-87
-90
-92

skipif mysql # not compatible
query I rowsort label-6591
SELECT - 85 + - ( tab1.col2 ) / col1 AS col0 FROM tab1
----
-87
-90
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( ( col1 ) ) col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT col2 * col0 + + tab0.col2 * col0 FROM tab0
----
14596
1584
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * - col2 col2 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6595
SELECT DISTINCT - - col1 DIV + col2 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-6595
SELECT DISTINCT - - col1 / + col2 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT col2 * col1 * col1 + col2 * col0 - cor0.col2 AS col0 FROM tab1 AS cor0
----
23808
36612
9291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col0 col1 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT + col0 - col0 * tab1.col1 AS col2 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - - 83 * + col0 FROM tab1 AS cor0
----
249
5312
6640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6600
SELECT - CAST( + col1 AS SIGNED ) FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6600
SELECT - CAST ( + col1 AS INTEGER ) FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL 13 * col2 AS col1 FROM tab2
----
338
351
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 15 col1 FROM tab0
----
15
15
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * - col1 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col2 * col1 - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + - col1 * + col2 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 54 * + tab2.col0 * + col1 col0 FROM tab2
----
11718
248508
72522

query I rowsort
SELECT + ( + 0 ) + - tab2.col0 * tab2.col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - cor0.col0 + - col0 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
-1260
-600
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 + + col0 * col1 col1 FROM tab2 AS cor0
----
1379
253
4638

query I rowsort
SELECT + col1 * + col0 + + cor0.col1 * col0 FROM tab0 cor0
----
16198
4128
6790

query I rowsort
SELECT col0 AS col0 FROM tab1 cor0 WHERE - col1 * col0 NOT IN ( + col2 )
----
3
64
80

query I rowsort
SELECT - col1 AS col0 FROM tab1 WHERE ( NULL ) <= NULL
----

query I rowsort
SELECT tab1.col0 + + col2 * - col1 AS col0 FROM tab1
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 col2 FROM tab1 WHERE NOT ( - col1 / col0 ) NOT IN ( col2 )
----

query I rowsort
SELECT col0 - + col1 FROM tab2 WHERE col0 NOT IN ( + tab2.col0 * col1 + col1 * col1 )
----
-24
19
62

query III rowsort
SELECT DISTINCT * FROM tab0 cor0 WHERE NULL BETWEEN col0 AND col0
----

query I rowsort
SELECT + col0 * col0 * col2 FROM tab1 AS cor0
----
233472
486
614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + cor0.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 4646ed87e8cc5aacb51f9b4e472c3c4b

query I rowsort
SELECT DISTINCT - col0 + - col1 AS col2 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT col2 + + col1 * + col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL + col2 + - col1 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT + tab2.col1 AS col0 FROM tab2 WHERE ( NULL ) = NULL
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( col1 ) IN ( + col2 * col0 )
----

query I rowsort
SELECT ALL - col0 FROM tab0 WHERE NOT ( NULL ) <> + col1
----

query I rowsort
SELECT ALL + col1 + + col0 * col2 AS col1 FROM tab1
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 - col2 col2 FROM tab1
----
-216
-3705
-7776

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) > + col0
----

query I rowsort
SELECT ALL tab2.col2 * - col2 + - col0 FROM tab2
----
-1523
-736
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-6629
SELECT DISTINCT col1 - col2 DIV col2 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-6629
SELECT DISTINCT col1 - col2 / col2 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT + tab2.col0 * tab2.col1 AS col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6631
SELECT DISTINCT + - cor0.col0 DIV col0 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1344
-218
-4603

skipif mysql # not compatible
query I rowsort label-6631
SELECT DISTINCT + - cor0.col0 / col0 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1344
-218
-4603

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT NULL IN ( col2 + cor0.col2 ) OR NOT col1 + + col2 <= NULL
----

query I rowsort
SELECT ALL - - col2 * + col1 - col2 * + cor0.col2 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT - tab1.col0 + tab1.col0 FROM tab1
----
0
0
0

query I rowsort
SELECT tab0.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL - 30 FROM tab1, tab0 AS cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

query I rowsort
SELECT DISTINCT + - cor0.col2 * - cor0.col0 AS col2 FROM tab1, tab2, tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + tab0.col0 + col2 AS col0 FROM tab0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6639
SELECT col0 - - CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6639
SELECT col0 - - CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - ( col1 ) FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ( col0 ) * + col2 + + 47 * + col1 AS col2 FROM tab0 cor0
----
11575
4594
4834

query I rowsort
SELECT DISTINCT + cor0.col0 * 37 * + col2 FROM tab0 AS cor0
----
1295
270026
29304

query I rowsort
SELECT + cor0.col2 * 43 AS col0 FROM tab2 AS cor0
----
1118
1161
1634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col1 col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + cor0.col0 * col0 * - col2 + + col0 FROM tab1 cor0
----
-233408
-483
-614320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 78 * col0 - col1 col1 FROM tab1 AS cor0
----
-260
-5002
-6253

query I rowsort
SELECT DISTINCT + 95 + 79 FROM tab0 AS cor0
----
174

query I rowsort
SELECT - + 46 + col1 FROM tab1 AS cor0
----
-20
-33
-36

query I rowsort
SELECT 46 + + col0 * cor0.col1 FROM tab1 AS cor0
----
1086
124
686

query I rowsort
SELECT col0 * ( tab1.col0 + col1 ) * - col1 FROM tab1
----
-2262
-47360
-96720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - 11 col1 FROM tab1 AS cor0
----
-33
-704
-880

query I rowsort
SELECT ALL - + ( - col1 ) + - cor0.col1 FROM tab2 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6653
SELECT ALL CAST( NULL AS SIGNED ) + ( col1 ) * + 39 - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6653
SELECT ALL CAST ( NULL AS INTEGER ) + ( col1 ) * + 39 - col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 83 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT ALL - col1 * col0 + - 44 FROM tab2 AS cor0
----
-1387
-261
-4646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col0 + + ( 33 ) col2 FROM tab1 cor0
----
-129
-3615
-7647

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL col0 * col1 + + 48 AS col0 FROM tab2 AS cor0
----
1391
265
4650

query I rowsort
SELECT DISTINCT + 35 * - 69 AS col0 FROM tab2, tab1 AS cor0
----
-2415

onlyif mysql # use DIV operator for integer division
query I rowsort label-6660
SELECT ALL + col1 + + col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-6660
SELECT ALL + col1 + + col0 / + col2 AS col0 FROM tab0 AS cor0
----
132
86
92

query I rowsort
SELECT DISTINCT + 51 + col0 AS col1 FROM tab2
----
129
130
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6662
SELECT + col2 * col2 DIV col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6662
SELECT + col2 * col2 / col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - + col2 + col1 * + cor0.col2 FROM tab2 AS cor0
----
1508
608
810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + 27 col2 FROM tab2 AS cor0
----
-1026
-702
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-6665
SELECT - + col0 * 14 DIV 58 + col1 AS col0 FROM tab0 AS cor0
----
70
81
89

skipif mysql # not compatible
query I rowsort label-6665
SELECT - + col0 * 14 / 58 + col1 AS col0 FROM tab0 AS cor0
----
70
81
89

query I rowsort
SELECT DISTINCT + - col1 * ( + cor0.col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col2 * ( + 79 ) AS col1 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT ALL - col2 * 7 AS col1 FROM tab2 cor0
----
-182
-189
-266

onlyif mysql # use DIV operator for integer division
query I rowsort label-6669
SELECT + + col1 DIV + 23 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6669
SELECT + + col1 / + 23 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6670
SELECT col1 + col2 * col2 DIV - col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-6670
SELECT col1 + col2 * col2 / - col2 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col1 * col2 + - 89 AS col1 FROM tab0 AS cor0
----
-186
-2927
-7551

query I rowsort
SELECT + 25 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-650
-675
-950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6673
SELECT - CAST( NULL AS SIGNED ) * 11 * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6673
SELECT - CAST ( NULL AS INTEGER ) * 11 * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor1.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ALL - 95 + - col2 * 48 FROM tab1 AS cor0
----
-2687
-2831
-4703

query I rowsort
SELECT DISTINCT - 11 * col1 + cor0.col1 FROM tab2 cor0
----
-170
-310
-590

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6677
SELECT DISTINCT + + ( cor0.col0 ) * CAST( - col0 AS SIGNED ) col1 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6677
SELECT DISTINCT + + ( cor0.col0 ) * CAST ( - col0 AS INTEGER ) col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - ( + col1 ) - 14 FROM tab1 AS cor0
----
-24
-27
-40

onlyif mysql # use DIV operator for integer division
query I rowsort label-6679
SELECT 41 + col0 DIV - col2 FROM tab1
----
40
41
41

skipif mysql # not compatible
query I rowsort label-6679
SELECT 41 + col0 / - col2 FROM tab1
----
40
41
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) + ( + col2 ) col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT + 68 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT DISTINCT 25 AS col1 FROM tab2, tab0, tab1 AS cor0
----
25

query I rowsort
SELECT DISTINCT + - col0 + - col1 - - 98 * col2 FROM tab0 AS cor0
----
-34
3124
7856

query I rowsort
SELECT ALL col2 * cor0.col2 + col1 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 6 + - col2 * 48 col2 FROM tab2 AS cor0
----
-1242
-1290
-1818

query I rowsort
SELECT ALL - 76 AS col0 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6687
SELECT col1 DIV tab1.col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6687
SELECT col1 / tab1.col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col0 + + cor0.col1 * 75 * cor0.col1 col0 FROM tab1 cor0
----
11635
50622
6860

query I rowsort
SELECT col2 * cor0.col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL ( - col1 ) * - ( + col0 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col1 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT cor0.col1 + + ( col0 ) * col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + col2 - cor0.col2 * - col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + - col2 + - 63 AS col0 FROM tab1 AS cor0
----
-117
-120
-159

query I rowsort
SELECT ALL + 7 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT DISTINCT + 48 * col2 * col0 AS col1 FROM tab2
----
144096
9072
97344

query I rowsort
SELECT ALL 48 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT - - 28 * 93 AS col0 FROM tab1 AS cor0
----
2604
2604
2604

onlyif mysql # use DIV operator for integer division
query I rowsort label-6699
SELECT ALL - ( col0 ) + col2 + cor0.col0 DIV col0 AS col2 FROM tab1 cor0
----
-6
17
52

skipif mysql # not compatible
query I rowsort label-6699
SELECT ALL - ( col0 ) + col2 + cor0.col0 / col0 AS col2 FROM tab1 cor0
----
-6
17
52

query I rowsort
SELECT ALL cor0.col0 + - cor0.col2 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 1c0f12b2ac8c8b522b92205460500f94

query I rowsort
SELECT ALL - 21 * + cor0.col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 20b5bbe97c2e8407f3025bb8755b2ba0

query I rowsort
SELECT - 49 * 26 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 6db5afccf480ed5cfede6859c4734f3c

query I rowsort
SELECT DISTINCT col1 * 17 + + col0 FROM tab0
----
1486
1636
1684

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 18 - cor0.col2 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b5f0c5a4618940b7c0b1c8484283a7c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col1 col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT col1 + + 20 FROM tab2
----
37
51
79

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( ( - col2 ) AS REAL ) * col0 + - col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT 8 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT DISTINCT - 87 * col1 * + col0 + col1 AS col1 FROM tab2 AS cor0
----
-116824
-18848
-400315

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0, tab1 cor0, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

query I rowsort
SELECT ( col0 + col1 ) AS col2 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6712
SELECT ALL - 96 DIV col1 col0 FROM tab0 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6712
SELECT ALL - 96 / col1 col0 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - 98 + - col0 AS col0 FROM tab0 AS cor0
----
-122
-133
-187

query I rowsort
SELECT DISTINCT + ( col0 ) * 89 * ( col1 * col2 ) - 94 AS col0 FROM tab1 AS cor0
----
3246626
374774
8885666

query I rowsort
SELECT ALL 77 * - col0 + 91 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1246
336
490

skipif mysql # not compatible
query I rowsort
SELECT ALL + + cor0.col2 + col2 * CAST ( 69 AS REAL ) AS col1 FROM tab1 cor0
----
3780
3990
6720

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col1 * + col0 * + col0 AS col1 FROM tab1 AS cor0
----
-288
-41017
-83296

query I rowsort
SELECT DISTINCT - col0 * + col2 + col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT 71 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT ALL col2 + + ( + col2 ) FROM tab2
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6721
SELECT DISTINCT tab2.col0 DIV - 21 + col0 FROM tab2
----
7
75
76

skipif mysql # not compatible
query I rowsort label-6721
SELECT DISTINCT tab2.col0 / - 21 + col0 FROM tab2
----
7
75
76

query I rowsort
SELECT - col0 + 39 * 25 FROM tab2
----
896
897
968

query I rowsort
SELECT col0 + + 53 AS col0 FROM tab2 AS cor0
----
131
132
60

query I rowsort
SELECT ALL + col2 * + ( + 41 ) + - col1 AS col1 FROM tab0 AS cor0
----
-56
1267
3271

onlyif mysql # use DIV operator for integer division
query I rowsort label-6725
SELECT col0 DIV + col2 - col0 AS col1 FROM tab1 AS cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-6725
SELECT col0 / + col2 - col0 AS col1 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT DISTINCT - col2 - col0 * col1 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - - cor0.col2 - ( - col2 * col1 ) AS col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-6728
SELECT DISTINCT - cor0.col1 DIV - col2 + col2 AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6728
SELECT DISTINCT - cor0.col1 / - col2 + col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + - col2 * - cor0.col1 - cor0.col1 AS col1 FROM tab1 cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT - col0 + - 35 AS col0 FROM tab0 AS cor0
----
-124
-59
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6731
SELECT ALL + ( col2 ) + + col0 - CAST( NULL AS SIGNED ) * 27 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6731
SELECT ALL + ( col2 ) + + col0 - CAST ( NULL AS INTEGER ) * 27 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 * + 90 FROM tab1 AS cor0
----
270
5760
7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-6733
SELECT + 9 + + col0 DIV + col2 AS col2 FROM tab0 AS cor0
----
10
44
9

skipif mysql # not compatible
query I rowsort label-6733
SELECT + 9 + + col0 / + col2 AS col2 FROM tab0 AS cor0
----
10
44
9

query I rowsort
SELECT DISTINCT + - col1 + + ( - col2 * cor0.col1 ) - cor0.col0 FROM tab2 AS cor0
----
-1671
-742
-875

query I rowsort
SELECT - 93 FROM tab1, tab2 cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT col0 * 98 AS col2 FROM tab2
----
686
7644
7742

query I rowsort
SELECT DISTINCT col0 + ( + col2 ) FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * cor0.col2 + col1 * + col0 col2 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT DISTINCT ( 23 ) AS col1 FROM tab1 AS cor0
----
23

query I rowsort
SELECT col0 + - col0 * - col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + - 96 AS col1 FROM tab1 AS cor0
----
-96
-96
-96

query I rowsort
SELECT + col1 + - col2 + col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - - col2 + col1 * + ( - col2 ) FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + col2 * col2 * col1 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL + col0 * + col1 AS col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL ( 15 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT ALL 14 + 12 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT DISTINCT - col2 * - col2 * col2 AS col1 FROM tab2
----
17576
19683
54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-6749
SELECT DISTINCT col0 DIV + 67 AS col2 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-6749
SELECT DISTINCT col0 / + 67 AS col2 FROM tab2
----
0
1

query I rowsort
SELECT 76 AS col0 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

onlyif mysql # use DIV operator for integer division
query I rowsort label-6751
SELECT DISTINCT tab1.col0 DIV - tab1.col2 AS col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-6751
SELECT DISTINCT tab1.col0 / - tab1.col2 AS col2 FROM tab1
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6752
SELECT - col0 + - col1 DIV 82 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6752
SELECT - col0 + - col1 / 82 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + - 75 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-525
-5850
-5925

query I rowsort
SELECT + ( + col0 ) + col2 * tab2.col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT ALL + ( + col2 ) + col2 FROM tab1
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-6756
SELECT ALL tab0.col0 DIV tab0.col1 + + col0 * - col1 FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-6756
SELECT ALL tab0.col0 / tab0.col1 + + col0 * - col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL col1 + 91 AS col2 FROM tab1
----
101
104
117

query I rowsort
SELECT DISTINCT + col1 + col2 * - col2 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT ALL 89 + col0 AS col2 FROM tab2
----
167
168
96

query I rowsort
SELECT ALL col2 + - col0 * - col2 AS col0 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT - col2 * + cor0.col1 + + cor0.col1 * cor0.col1 FROM tab2 AS cor0
----
-357
124
1947

query I rowsort
SELECT DISTINCT + col2 + col1 + 48 * - col0 AS col1 FROM tab2
----
-278
-3659
-3737

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + - col2 col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL col0 - cor0.col1 * 14 AS col0 FROM tab2 AS cor0
----
-159
-427
-748

query I rowsort
SELECT DISTINCT - 2 - col0 * 28 FROM tab2 AS cor0
----
-198
-2186
-2214

onlyif mysql # use DIV operator for integer division
query I rowsort label-6766
SELECT ALL - 1 - + cor0.col2 DIV - col1 AS col1 FROM tab1 AS cor0
----
1
4
6

skipif mysql # not compatible
query I rowsort label-6766
SELECT ALL - 1 - + cor0.col2 / - col1 AS col1 FROM tab1 AS cor0
----
1
4
6

query I rowsort
SELECT ALL - 53 + col1 FROM tab1 AS cor0
----
-27
-40
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 + - 33 * - 13 col2 FROM tab2 cor0
----
2457
3431
618

query I rowsort
SELECT ALL 59 * - col0 + + 55 FROM tab2 cor0
----
-358
-4547
-4606

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 45 col1 FROM tab2 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT + + cor0.col1 * cor0.col1 * - col1 FROM tab0 AS cor0
----
-636056
-753571
-912673

query I rowsort
SELECT DISTINCT + 88 * col2 + col0 FROM tab1 cor0
----
4755
5080
8528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 33 col1 FROM tab1 AS cor0
----
-33

query I rowsort
SELECT + col0 - - col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + 69 AS col0 FROM tab0
----
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 col0 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + col2 + ( + col1 ) * col1 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-6778
SELECT + cor0.col2 DIV - cor0.col1 + col1 AS col2 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-6778
SELECT + cor0.col2 / - cor0.col1 + col1 AS col2 FROM tab2 AS cor0
----
15
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6779
SELECT + + cor0.col1 + - ( + col2 ) DIV + col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6779
SELECT + + cor0.col1 + - ( + col2 ) / + col2 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - col1 + 72 AS col0 FROM tab0 AS cor0
----
-14
-19
-25

query I rowsort
SELECT col0 + ( - cor0.col1 * col2 ) AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + ( 25 + - col1 ) * ( + col0 ) col0 FROM tab1 AS cor0
----
-9
61440
76800

query I rowsort
SELECT DISTINCT + col1 + - col0 * col0 AS col2 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6784
SELECT DISTINCT CAST( ( - col0 ) AS SIGNED ) * - cor0.col1 col2 FROM tab0 cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6784
SELECT DISTINCT CAST ( ( - col0 ) AS INTEGER ) * - cor0.col1 col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - ( 15 * - col0 ) FROM tab0
----
1335
360
525

query I rowsort
SELECT 76 AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT + - col2 * col2 * col1 AS col0 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT 55 + + col1 * + cor0.col0 * ( + ( - col1 ) ) FROM tab0 AS cor0
----
-177449
-329260
-736954

onlyif mysql # use DIV operator for integer division
query I rowsort label-6789
SELECT - + ( + col2 ) DIV - col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6789
SELECT - + ( + col2 ) / - col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + 39 * cor0.col2 * - col2 FROM tab0 AS cor0
----
-262236
-39
-42471

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + + col0 AS col2 FROM tab0 cor0
----
-2
-62

query I rowsort
SELECT - - ( col0 ) * - col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + + cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col1 * cor0.col0 + col2 * col0 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT - - col1 * + col1 * ( col0 ) AS col0 FROM tab2 AS cor0
----
22831
271518
6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 * cor0.col2 col1 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - 39 * 20 FROM tab0 cor0
----
-780
-780
-780

query I rowsort
SELECT 99 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

onlyif mysql # use DIV operator for integer division
query I rowsort label-6799
SELECT DISTINCT - col2 DIV ( - col0 ) FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-6799
SELECT DISTINCT - col2 / ( - col0 ) FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT + 5 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT + + col1 + + 11 AS col2 FROM tab1 AS cor0
----
21
24
37

query I rowsort
SELECT + col0 * cor0.col1 * col2 FROM tab0 cor0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6803
SELECT + CAST( NULL AS DECIMAL ) col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6803
SELECT + CAST ( NULL AS REAL ) col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + 93 AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT col1 + col0 * ( + 57 ) FROM tab2 AS cor0
----
430
4505
4520

query I rowsort
SELECT 52 + col1 + 76 * col2 FROM tab1 AS cor0
----
4182
4394
7361

onlyif mysql # use DIV operator for integer division
query I rowsort label-6807
SELECT + col2 * - col0 DIV + col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6807
SELECT + col2 * - col0 / + col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT 3 * 50 AS col2 FROM tab0
----
150
150
150

query I rowsort
SELECT cor0.col1 * col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6810
SELECT DISTINCT - col1 * - CAST( ( col2 ) AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-6810
SELECT DISTINCT - col1 * - CAST ( ( col2 ) AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - ( - col2 ) * col0 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT - 92 AS col1 FROM tab0
----
-92
-92
-92

query I rowsort
SELECT DISTINCT + + col1 * + 92 FROM tab2 AS cor0
----
1564
2852
5428

query I rowsort
SELECT - 74 AS col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT - col1 * + 18 AS col1 FROM tab2 cor0
----
-1062
-306
-558

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6816
SELECT ALL - cor0.col0 + - CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6816
SELECT ALL - cor0.col0 + - CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 32 + 68 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 88605988410cd7d6b5c389bf9a3dd418

onlyif mysql # use DIV operator for integer division
query I rowsort label-6818
SELECT ALL col0 DIV col2 + + col0 + tab1.col2 DIV col1 FROM tab1
----
5
70
87

skipif mysql # not compatible
query I rowsort label-6818
SELECT ALL col0 / col2 + + col0 + tab1.col2 / col1 FROM tab1
----
5
70
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6819
SELECT - cor0.col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6819
SELECT - cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 71 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT - col0 + ( - 22 ) * + col2 FROM tab0
----
-1893
-57
-750

query I rowsort
SELECT - 62 * - 71 - - col1 AS col0 FROM tab0
----
4488
4493
4499

onlyif mysql # use DIV operator for integer division
query I rowsort label-6823
SELECT col1 * - col1 + - col0 * - col0 - - 84 DIV col0 AS col1 FROM tab1
----
-639
3997
6232

skipif mysql # not compatible
query I rowsort label-6823
SELECT col1 * - col1 + - col0 * - col0 - - 84 / col0 AS col1 FROM tab1
----
-639
3997
6232

onlyif mysql # use DIV operator for integer division
query I rowsort label-6824
SELECT DISTINCT - 3 DIV - 18 - - col2 DIV 53 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6824
SELECT DISTINCT - 3 / - 18 - - col2 / 53 FROM tab2
----
0

query I rowsort
SELECT DISTINCT - 1 * + cor0.col0 + + col2 AS col2 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-6826
SELECT 2 * col0 DIV + col0 col0 FROM tab0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6826
SELECT 2 * col0 / + col0 col0 FROM tab0
----
2
2
2

query I rowsort
SELECT col0 + 30 * col0 * + 50 FROM tab0
----
133589
36024
52535

onlyif mysql # use DIV operator for integer division
query I rowsort label-6828
SELECT ( 21 ) DIV col1 AS col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6828
SELECT ( 21 ) / col1 AS col1 FROM tab1
----
0
1
2

query I rowsort
SELECT - 74 * col0 - col0 AS col2 FROM tab1
----
-225
-4800
-6000

query I rowsort
SELECT DISTINCT - ( 50 ) * - col2 * tab0.col2 FROM tab0
----
336200
50
54450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 - + col1 * 59 col2 FROM tab1 AS cor0
----
-1537
-654
-847

onlyif mysql # use DIV operator for integer division
query I rowsort label-6832
SELECT + + cor0.col2 * col1 + cor0.col1 DIV cor0.col1 FROM tab1 AS cor0
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-6832
SELECT + + cor0.col2 * col1 + cor0.col1 / cor0.col1 FROM tab1 AS cor0
----
1249
1405
571

query I rowsort
SELECT - - 44 * col1 + - cor0.col1 FROM tab1 AS cor0
----
1118
430
559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6834
SELECT ALL - col0 + col1 / CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6834
SELECT ALL - col0 + col1 / CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + + col1 * + 0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + + col2 + col0 * - col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - 88 + + col2 FROM tab0 AS cor0
----
-55
-6
-87

query I rowsort
SELECT - + col1 * col2 + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col1 * + 73 col0 FROM tab0 AS cor0
----
-150672
-247835
-591227

query I rowsort
SELECT - 62 * + col1 + + col1 AS col0 FROM tab0 AS cor0
----
-5246
-5551
-5917

query I rowsort
SELECT DISTINCT + + tab2.col1 AS col1 FROM tab2, tab1, tab0 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6842
SELECT ALL CAST( NULL AS DECIMAL ) * + 21 * col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6842
SELECT ALL CAST ( NULL AS REAL ) * + 21 * col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + tab2.col2 ) * + tab2.col1 col1 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 37 col1 FROM tab0
----
-37
-37
-37

query I rowsort
SELECT ALL + 39 + + col1 AS col0 FROM tab0 AS cor0
----
125
130
136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col2 ) * - col2 + 45 col2 FROM tab2 AS cor0
----
1489
721
774

query I rowsort
SELECT ALL cor1.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + 78 - ( + col0 ) * ( col1 ) FROM tab2 AS cor0
----
-1265
-139
-4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 35 * 4 col2 FROM tab1 AS cor0
----
-140

query I rowsort
SELECT 86 * col0 + cor0.col0 * col1 FROM tab1 AS cor0
----
336
6144
7920

query I rowsort
SELECT ALL col1 + + 38 FROM tab2
----
55
69
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6852
SELECT DISTINCT - col1 + col1 DIV + col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6852
SELECT DISTINCT - col1 + col1 / + col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 70 * - cor0.col1 + + 41 col1 FROM tab0 AS cor0
----
-5979
-6329
-6749

query I rowsort
SELECT ALL - col1 + - cor0.col2 * + cor0.col1 AS col0 FROM tab1 cor0
----
-1261
-1430
-580

query I rowsort
SELECT + 7 * - col0 FROM tab0 AS cor0
----
-168
-245
-623

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - + col2 col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT col1 * - col1 + 82 AS col2 FROM tab1 AS cor0
----
-18
-594
-87

query I rowsort
SELECT + 8 + col2 * ( col1 * col1 + - col1 ) AS col0 FROM tab0 AS cor0
----
241238
671588
9320

query I rowsort
SELECT DISTINCT - col1 * tab1.col1 + col2 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL + col2 + tab0.col2 + col1 * + col0 FROM tab0
----
2130
3397
8263

query I rowsort
SELECT ALL - cor0.col1 + ( 8 ) * col1 AS col0 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT ALL + col2 * + 16 FROM tab2 AS cor0
----
416
432
608

query I rowsort
SELECT DISTINCT + cor0.col0 * 0 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 AS col0 FROM tab0 cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6865
SELECT DISTINCT + cor0.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-6865
SELECT DISTINCT + cor0.col1 + + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6866
SELECT ALL - cor0.col1 * + CAST( - col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-6866
SELECT ALL - cor0.col1 * + CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col0 - - 75 AS col2 FROM tab2 cor0
----
-3
-4
68

query I rowsort
SELECT DISTINCT - col1 + 87 AS col2 FROM tab0 AS cor0
----
-10
-4
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6869
SELECT + - col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6869
SELECT + - col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6870
SELECT DISTINCT - - col1 * + CAST( col2 AS SIGNED ) * + col0 + - 80 AS col0 FROM tab0 cor0
----
3315
664038
68032

skipif mysql # not compatible
query I rowsort label-6870
SELECT DISTINCT - - col1 * + CAST ( col2 AS INTEGER ) * + col0 + - 80 AS col0 FROM tab0 cor0
----
3315
664038
68032

query I rowsort
SELECT col0 - - tab1.col1 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT - 11 + - col2 * - 75 AS col0 FROM tab2
----
1939
2014
2839

query I rowsort
SELECT col1 * - ( col0 ) AS col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6874
SELECT DISTINCT col2 + + tab1.col2 DIV col1 FROM tab1
----
103
56
62

skipif mysql # not compatible
query I rowsort label-6874
SELECT DISTINCT col2 + + tab1.col2 / col1 FROM tab1
----
103
56
62

query I rowsort
SELECT ALL col2 * - col0 + + tab2.col1 FROM tab2
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-6876
SELECT + + col0 DIV + ( col2 ) + - cor0.col1 * col1 FROM tab0 AS cor0
----
-7396
-8280
-9374

skipif mysql # not compatible
query I rowsort label-6876
SELECT + + col0 / + ( col2 ) + - cor0.col1 * col1 FROM tab0 AS cor0
----
-7396
-8280
-9374

query I rowsort
SELECT + + col0 * - 75 * col1 AS col2 FROM tab0 AS cor0
----
-154800
-254625
-607425

query I rowsort
SELECT col0 - - col0 * col0 * col2 AS col0 FROM tab1 cor0
----
233536
489
614480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6879
SELECT + cor0.col0 * - 20 + + col1 * CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6879
SELECT + cor0.col0 * - 20 + + col1 * CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 27 - - ( - col0 * - 96 ) AS col0 FROM tab1 AS cor0
----
315
6171
7707

query I rowsort
SELECT + ( col0 ) + + cor0.col0 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - col2 AS REAL ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT col0 - - col0 * + col2 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-6884
SELECT + col2 - - ( + col2 ) DIV col2 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-6884
SELECT + col2 - - ( + col2 ) / col2 FROM tab1 cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6885
SELECT + col1 DIV 32 + + col1 + col2 AS col0 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-6885
SELECT + col1 / 32 + + col1 + col2 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + + col0 + + col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL - 25 * + col2 + 85 FROM tab2 AS cor0
----
-565
-590
-865

query I rowsort
SELECT ALL - col2 * - col1 + 52 AS col1 FROM tab1 cor0
----
1300
1456
622

query I rowsort
SELECT ALL - col0 * + col2 - cor0.col0 AS col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL - + col1 - - col1 * + col2 AS col0 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-6891
SELECT DISTINCT 22 DIV cor0.col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6891
SELECT DISTINCT 22 / cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT col0 * - col2 * + col2 + ( + col2 ) AS col1 FROM tab0 AS cor0
----
-26103
-34
-598354

query I rowsort
SELECT DISTINCT - 56 FROM tab1
----
-56

query I rowsort
SELECT - + col1 * + cor0.col2 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + col2 + col2 + - col0 AS col0 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT ALL + - cor0.col0 * - col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6897
SELECT + - col2 * CAST( NULL AS SIGNED ) 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-6897
SELECT + - col2 * CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT 62 AS col0 FROM tab0, tab1 AS cor0
----
62

query I rowsort
SELECT - tab0.col0 * col2 AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col0 * 52 AS col0 FROM tab2
----
364
4056
4108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 * - 18 col1 FROM tab2
----
-468
-486
-684

query I rowsort
SELECT ALL ( col2 ) * cor0.col1 * col2 + col2 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT ALL - col0 + + col1 AS col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT DISTINCT col1 * cor0.col1 * - col0 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT + - col1 + + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL + col1 * + cor0.col0 + col2 AS col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + ( - col1 ) + + col0 + + col1 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL + col0 + col0 * - tab1.col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT col1 + 14 FROM tab0
----
100
105
111

query I rowsort
SELECT 51 + - col1 FROM tab2 AS cor0
----
-8
20
34

query I rowsort
SELECT 48 + col2 FROM tab0
----
130
49
81

query I rowsort
SELECT DISTINCT - 43 + - col1 + col0 * col1 FROM tab0 AS cor0
----
1935
3255
7965

query I rowsort
SELECT - + cor0.col2 * + col0 + + col0 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 * - 9 col1 FROM tab1 AS cor0
----
486
513
864

query I rowsort
SELECT + col1 * 48 * col1 AS col0 FROM tab1 AS cor0
----
32448
4800
8112

query I rowsort
SELECT col2 + - 51 AS col1 FROM tab1 AS cor0
----
3
45
6

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( - col0 AS REAL ) - - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor1.col2 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 col0 FROM tab2 AS cor0
----
23
23
23

query I rowsort
SELECT 18 * - col1 * + col2 + - col2 AS col1 FROM tab1 AS cor0
----
-10317
-22560
-25326

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 10 ) + - col1 * - col2 col1 FROM tab2 AS cor0
----
1524
636
827

query I rowsort
SELECT DISTINCT 97 - cor0.col1 * + col0 * col1 FROM tab0 AS cor0
----
-177407
-329218
-736912

query I rowsort
SELECT ALL - + col2 * 9 FROM tab1 AS cor0
----
-486
-513
-864

query I rowsort
SELECT + - 99 - - col2 * col1 * - col2 FROM tab2 AS cor0
----
-22698
-24647
-39983

query I rowsort
SELECT DISTINCT col2 + 83 + col1 * col0 FROM tab2 cor0
----
1464
327
4711

query I rowsort
SELECT ALL - + cor0.col1 * + 53 * + col1 FROM tab2 AS cor0
----
-15317
-184493
-50933

query I rowsort
SELECT ALL + 55 * 45 FROM tab1 AS cor0
----
2475
2475
2475

query I rowsort
SELECT - + col0 + + cor0.col2 * col0 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
1190
18984
649433

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 - col0 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + - tab2.col0 AS col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT col2 * col0 + col0 + - col0 * tab1.col0 * - col1 AS col0 FROM tab1
----
399
44672
90960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6933
SELECT col0 + - col0 DIV - col0 + col2 FROM tab1
----
122
177
58

skipif mysql # not compatible
query I rowsort label-6933
SELECT col0 + - col0 / - col0 + col2 FROM tab1
----
122
177
58

query I rowsort
SELECT + col1 + + col0 + + col1 AS col1 FROM tab2 AS cor0
----
113
196
69

query I rowsort
SELECT ALL - - cor0.col0 + + col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6936
SELECT - + col0 DIV cor0.col0 + - col2 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-6936
SELECT - + col0 / cor0.col0 + - col2 FROM tab2 AS cor0
----
-27
-28
-39

query I rowsort
SELECT ALL col0 * col1 + - col0 FROM tab2 cor0
----
1264
210
4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-6938
SELECT - - col1 DIV - col2 - col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6938
SELECT - - col1 / - col2 - col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - cor0.col1 - + col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - col0 * + col1 + - col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT ALL col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT col1 * + col2 * + col1 - - col2 AS col1 FROM tab1 AS cor0
----
16320
36558
5757

query I rowsort
SELECT DISTINCT - col2 * col2 - - col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT col1 + col2 * col0 + - col1 * - col1 FROM tab0
----
15670
8274
9541

onlyif mysql # use DIV operator for integer division
query I rowsort label-6945
SELECT ALL - col2 * col2 + col1 * col1 DIV tab2.col1 AS col2 FROM tab2
----
-1427
-617
-698

skipif mysql # not compatible
query I rowsort label-6945
SELECT ALL - col2 * col2 + col1 * col1 / tab2.col1 AS col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT ALL col2 * col1 - - col1 AS col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL tab2.col1 + + tab2.col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL col2 + col2 * col2 AS col2 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT - cor0.col2 + col2 * - col0 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT col2 * - col2 * - col0 FROM tab2 cor0
----
114076
5103
52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT col2 + col1 * col1 * col0 + + col1 FROM tab2 AS cor0
----
22886
271603
6785

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - - col2 col0 FROM tab0
----
171
36
57

query I rowsort
SELECT + col2 * cor0.col2 - + col1 AS col1 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-6955
SELECT col0 DIV + col2 - col2 AS col2 FROM tab0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-6955
SELECT col0 / + col2 - col2 AS col2 FROM tab0
----
-33
-81
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col1 * - col1 * - col2 col0 FROM tab1
----
-16237
-36530
-5710

query I rowsort
SELECT + col2 * + col0 + + col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT - - 19 AS col0 FROM tab1 AS cor0
----
19

query I rowsort
SELECT - 84 * col0 FROM tab2 AS cor0
----
-588
-6552
-6636

query I rowsort
SELECT ALL + col1 + + col2 * col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + 64 * + cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
13888
294528
85952

query I rowsort
SELECT 63 + col1 AS col0 FROM tab1
----
73
76
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * - col1 col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT col1 + - col1 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col0 + ( + col1 ) AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL cor0.col1 + - col2 AS col1 FROM tab0 cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6967
SELECT - col0 DIV 27 - 3 AS col1 FROM tab1 AS cor0
----
-3
-5
-5

skipif mysql # not compatible
query I rowsort label-6967
SELECT - col0 / 27 - 3 AS col1 FROM tab1 AS cor0
----
-3
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6968
SELECT ALL col1 * ( - 80 ) DIV col0 col0 FROM tab0
----
-221
-286
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6968
SELECT ALL col1 * ( - 80 ) / col0 col0 FROM tab0
----
-221
-286
-81

query I rowsort
SELECT + 16 AS col2 FROM tab0, tab2, tab2 AS cor0, tab1
----
81 values hashing to 9ffb4aaf972de606a4957894645b6216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6970
SELECT DISTINCT col0 / + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6970
SELECT DISTINCT col0 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + col2 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - col2 * col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT ALL - 66 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT + ( - 24 ) * + col1 AS col1 FROM tab2 AS cor0
----
-1416
-408
-744

query I rowsort
SELECT ( - col2 ) + + col1 * - col2 * - col2 FROM tab2 AS cor0
----
22572
24510
39858

onlyif mysql # use DIV operator for integer division
query I rowsort label-6976
SELECT ALL - - 69 + + col1 DIV + col2 FROM tab0 AS cor0
----
166
70
71

skipif mysql # not compatible
query I rowsort label-6976
SELECT ALL - - 69 + + col1 / + col2 FROM tab0 AS cor0
----
166
70
71

query I rowsort
SELECT + col0 * col0 * + col2 FROM tab1 cor0
----
233472
486
614400

query I rowsort
SELECT ( 38 ) FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1 cor2
----
81 values hashing to 9124b06d33995d82062026964cce3a38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6979
SELECT DISTINCT + - 88 DIV + col0 FROM tab1 AS cor0
----
-1
-29

skipif mysql # not compatible
query I rowsort label-6979
SELECT DISTINCT + - 88 / + col0 FROM tab1 AS cor0
----
-1
-29

query I rowsort
SELECT ALL 55 + col1 AS col0 FROM tab2 AS cor0
----
114
72
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6981
SELECT DISTINCT - cor0.col2 * - col2 - - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6981
SELECT DISTINCT - cor0.col2 * - col2 - - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL + - 8 * + col0 * col2 AS col0 FROM tab1 AS cor0
----
-1296
-29184
-61440

query I rowsort
SELECT + col2 + - col1 * - col0 AS col2 FROM tab2
----
1381
244
4628

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 19 col2 FROM tab2 AS cor0
----
19
19
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) * col0 + 21 * + 15 * - col0 col1 FROM tab2
----
-2016
-21883
-22542

onlyif mysql # use DIV operator for integer division
query I rowsort label-6986
SELECT ALL - col0 DIV - col2 AS col0 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6986
SELECT ALL - col0 / - col2 AS col0 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL ( - col1 + - col1 ) AS col2 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT 50 AS col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT + - 18 + col1 * - col0 AS col0 FROM tab1 cor0
----
-1058
-658
-96

query I rowsort
SELECT - ( col0 ) * - 65 FROM tab1 cor0
----
195
4160
5200

query I rowsort
SELECT DISTINCT + col0 * + tab2.col1 * 7 FROM tab2
----
1519
32214
9401

query I rowsort
SELECT ALL col0 + cor0.col0 AS col1 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT cor0.col1 + - 70 FROM tab1 cor0
----
-44
-57
-60

query I rowsort
SELECT ALL + - col2 * + col1 + - 83 - col2 AS col0 FROM tab0 AS cor0
----
-181
-2954
-7627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 74 * + col0 col1 FROM tab2
----
518
5772
5846

query I rowsort
SELECT ( col0 + col0 ) AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT - 34 + col2 AS col2 FROM tab2 AS cor0
----
-7
-8
4

query I rowsort
SELECT - + col1 + - ( cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT 51 + ( + col2 + + ( + col2 ) ) AS col2 FROM tab0 AS cor0
----
117
215
53

query I rowsort
SELECT - 5 + col2 FROM tab1 AS cor0
----
49
52
91

query I rowsort
SELECT - + 8 * col0 AS col1 FROM tab0 AS cor0
----
-192
-280
-712

query I rowsort
SELECT 11 + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1029
-629
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7003
SELECT 39 DIV - col0 FROM tab2 AS cor0
----
-5
0
0

skipif mysql # not compatible
query I rowsort label-7003
SELECT 39 / - col0 FROM tab2 AS cor0
----
-5
0
0

query I rowsort
SELECT - 24 * col1 FROM tab0 AS cor0
----
-2064
-2184
-2328

query I rowsort
SELECT DISTINCT col2 + - tab0.col1 * 46 * + col2 AS col0 FROM tab0
----
-130515
-343170
-4461

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
-3
-64
-80

query I rowsort
SELECT + 71 FROM tab0, tab2 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT ALL + col0 * col0 + col2 AS col1 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT + ( 14 ) * - col0 + 93 FROM tab0 cor0
----
-1153
-243
-397

query I rowsort
SELECT DISTINCT + + col0 * 11 * + col1 AS col1 FROM tab2 AS cor0
----
14773
2387
50622

query I rowsort
SELECT - ( col1 ) + col2 * 11 * col2 FROM tab2 cor0
----
15867
7377
7988

query I rowsort
SELECT + 85 + col2 * cor0.col2 - - col1 FROM tab2 AS cor0
----
1546
820
845

query I rowsort
SELECT DISTINCT + 82 * col2 FROM tab0 cor0
----
2706
6724
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7014
SELECT CAST( - col2 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-7014
SELECT CAST ( - col2 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL - + col2 * col0 + - cor0.col2 * - 79 * col1 FROM tab2 AS cor0
----
119158
48032
65934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - col2 col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT col1 + col0 + - col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT cor0.col0 + col1 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT - col1 * + col1 + + col0 - 45 FROM tab2 AS cor0
----
-255
-3448
-999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7020
SELECT DISTINCT CAST( + 43 AS SIGNED ) FROM tab2 AS cor0
----
43

skipif mysql # not compatible
query I rowsort label-7020
SELECT DISTINCT CAST ( + 43 AS INTEGER ) FROM tab2 AS cor0
----
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + ( - col1 ) + + col0 + + col2 col1 FROM tab0 AS cor0
----
133
2895
7633

onlyif mysql # use DIV operator for integer division
query I rowsort label-7022
SELECT DISTINCT col1 DIV - 72 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-7022
SELECT DISTINCT col1 / - 72 FROM tab0
----
-1

query I rowsort
SELECT DISTINCT 4 * cor1.col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
216
228
384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 23 col2 FROM tab0 AS cor0
----
23

query I rowsort
SELECT ALL - ( - col0 ) * - col0 + col2 * col1 * - col1 AS col2 FROM tab1 AS cor0
----
-22624
-36513
-9796

query I rowsort
SELECT 11 - cor1.col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 22b98c73bee0b5a5d2479c7ceaa36953

query I rowsort
SELECT ALL + ( + col0 ) * col0 FROM tab0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7028
SELECT - - col1 / col1 + - col2 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7028
SELECT - - col1 / col1 + - col2 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - 25 ) + - col2 FROM tab2 cor0
----
-1
-13
-2

query I rowsort
SELECT ALL - 31 FROM tab1, tab1 cor0 CROSS JOIN tab0
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 74 * cor1.col0 col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-1776
-2590
-6586

query I rowsort
SELECT DISTINCT - col1 * + 80 AS col2 FROM tab2 AS cor0
----
-1360
-2480
-4720

query I rowsort
SELECT DISTINCT - col1 * + col0 + col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - col0 * 43 - col1 AS col0 FROM tab0 AS cor0
----
-1118
-1602
-3918

query I rowsort
SELECT cor0.col1 + ( - col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT + col1 + - 37 * + col2 AS col2 FROM tab2 cor0
----
-1389
-903
-968

query I rowsort
SELECT + col0 + - col2 * + col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL 41 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT + cor0.col0 * + cor0.col2 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT col2 + ( col1 ) * cor0.col1 FROM tab0 AS cor0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + 60 col1 FROM tab0 cor0
----
-5160
-5460
-5820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7042
SELECT ALL - col0 + + CAST( NULL AS SIGNED ) + - 65 * col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7042
SELECT ALL - col0 + + CAST ( NULL AS INTEGER ) + - 65 * col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + + col2 + + 15 * + col0 AS col2 FROM tab0 AS cor0
----
1506
417
561

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 489b7b2b5c4980d50e86e51be30361c3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7045
SELECT ALL - + col2 * CAST( NULL AS SIGNED ) 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-7045
SELECT ALL - + col2 * CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col0 + 90 FROM tab1 cor0
----
10
26
87

query I rowsort
SELECT DISTINCT ( col2 ) + - col0 * 41 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-229
-3113
-3184

query I rowsort
SELECT 14 - col0 AS col2 FROM tab0 AS cor0
----
-10
-21
-75

query I rowsort
SELECT DISTINCT - + 52 * + 78 - col0 FROM tab1 AS cor0
----
-4059
-4120
-4136

query I rowsort
SELECT + - cor0.col0 * - 55 + - col1 FROM tab0 AS cor0
----
1234
1828
4804

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 * + col0 * 61 col1 FROM tab2 AS cor0
----
13244
280800
82002

query I rowsort
SELECT ALL + - 61 - col0 * cor0.col0 FROM tab0 AS cor0
----
-1286
-637
-7982

query I rowsort
SELECT ALL + ( - col2 ) * + col1 + + 82 * + col2 - - col0 AS col0 FROM tab1 AS cor0
----
3027
4168
6704

query I rowsort
SELECT ALL col1 + - col2 * + ( - col2 * + col1 ) FROM tab1 AS cor0
----
119821
32500
75842

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - tab0.col1 col2 FROM tab0, tab2, tab1 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + 64 * col1 FROM tab0 AS cor0
----
5504
5824
6208

query I rowsort
SELECT + + col0 + - cor0.col2 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT ALL col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7058
SELECT ALL col2 / + col1 AS col2 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT DISTINCT - col2 * 92 + col2 FROM tab1 AS cor0
----
-4914
-5187
-8736

query I rowsort
SELECT DISTINCT + 68 FROM tab1, tab0, tab1 cor0
----
68

query I rowsort
SELECT ALL - tab2.col2 * + col0 AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col2 + col1 * + ( col2 ) FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL + cor0.col0 * - cor0.col0 - + col2 AS col2 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT DISTINCT + col1 - + 41 * col2 FROM tab1 AS cor0
----
-2188
-2327
-3923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7065
SELECT DISTINCT col0 + + CAST( col1 AS SIGNED ) AS col0 FROM tab1 cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-7065
SELECT DISTINCT col0 + + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL - tab0.col2 * tab0.col0 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7067
SELECT - col0 * + col1 + + col2 DIV - tab0.col1 + col0 FROM tab0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort label-7067
SELECT - col0 * + col1 + + col2 / - tab0.col1 + col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - + ( - cor0.col1 ) FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7069
SELECT ALL tab1.col2 DIV col1 + col0 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-7069
SELECT ALL tab1.col2 / col1 + col0 FROM tab1
----
5
69
87

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * tab1.col1 * - col2 col0 FROM tab1
----
-119712
-32433
-75762

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL = + col1
----

query I rowsort
SELECT + tab1.col0 + tab1.col2 AS col0 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7074
SELECT DISTINCT - col0 + col0 DIV + col0 AS col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-7074
SELECT DISTINCT - col0 + col0 / + col0 AS col2 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT 6 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

onlyif mysql # use DIV operator for integer division
query I rowsort label-7076
SELECT ALL + 29 + col0 DIV - col0 + - col1 FROM tab0
----
-58
-63
-69

skipif mysql # not compatible
query I rowsort label-7076
SELECT ALL + 29 + col0 / - col0 + - col1 FROM tab0
----
-58
-63
-69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7077
SELECT DISTINCT - + 85 * col0 + CAST( 28 AS SIGNED ) FROM tab2 AS cor0
----
-567
-6602
-6687

skipif mysql # not compatible
query I rowsort label-7077
SELECT DISTINCT - + 85 * col0 + CAST ( 28 AS INTEGER ) FROM tab2 AS cor0
----
-567
-6602
-6687

onlyif mysql # use DIV operator for integer division
query I rowsort label-7078
SELECT - 84 DIV - cor0.col2 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 3daf191600c64328f2c60722189235c6

skipif mysql # not compatible
query I rowsort label-7078
SELECT - 84 / - cor0.col2 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 3daf191600c64328f2c60722189235c6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 col1 FROM tab0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 * - col1 + col0 col2 FROM tab0
----
-3360
-664029
-68088

query I rowsort
SELECT + col2 * + col1 * - col0 + - tab2.col0 FROM tab2
----
-119730
-51113
-5866

query I rowsort
SELECT DISTINCT col1 * + col2 * col2 FROM tab0
----
611884
93654
97

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL <> ( col0 * - col1 )
----

query I rowsort
SELECT DISTINCT col0 * tab2.col2 + + col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT + tab0.col1 * col1 * + col2 + + col0 FROM tab0
----
244092
679131
9444

query I rowsort
SELECT cor0.col1 * - col0 / col1 + - cor0.col2 / cor0.col0 AS col2 FROM tab1 AS cor0 WHERE col1 = NULL
----

query I rowsort
SELECT ALL col0 + - col2 * - col0 AS col1 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL tab0.col2 * - col0 * tab0.col1 - + tab0.col2 FROM tab0 WHERE ( col2 * - col0 ) < NULL
----

query I rowsort
SELECT col0 * col1 * - col0 + - col1 FROM tab2
----
-106114
-1550
-359015

onlyif mysql # use DIV operator for integer division
query I rowsort label-7090
SELECT DISTINCT - col1 DIV + col1 + col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-7090
SELECT DISTINCT - col1 / + col1 + col2 FROM tab1
----
53
56
95

query I rowsort
SELECT - tab0.col2 * + col0 AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7092
SELECT - col0 * - col0 * - col2 + col2 + col1 DIV - col0 AS col1 FROM tab2 AS cor0
----
-1300
-158158
-237120

skipif mysql # not compatible
query I rowsort label-7092
SELECT - col0 * - col0 * - col2 + col2 + col1 / - col0 AS col1 FROM tab2 AS cor0
----
-1300
-158158
-237120

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col0 ) IN ( col1 )
----

query I rowsort
SELECT ALL + col1 * col1 + col0 AS col2 FROM tab2
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - + col1 col1 FROM tab1 WHERE NOT ( NULL ) <> col0
----

query I rowsort
SELECT DISTINCT - col1 * + col2 + tab2.col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT - col0 + + col2 * col2 AS col0 FROM tab0
----
-34
1065
6635

onlyif mysql # use DIV operator for integer division
query I rowsort label-7098
SELECT ALL + col0 DIV col0 + - col2 AS col0 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-7098
SELECT ALL + col0 / col0 + - col2 AS col0 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT col2 * - tab2.col0 + col2 * col2 + tab2.col2 FROM tab2
----
-1326
-1520
567

query I rowsort
SELECT col2 - + tab0.col0 * tab0.col1 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL col2 * col0 + col2 AS col1 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - col0 + - tab0.col1 * + col1 * col2 FROM tab0
----
-244092
-679131
-9444

query I rowsort
SELECT ALL col2 + col1 * col1 FROM tab1
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-7104
SELECT + col0 DIV - col0 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7104
SELECT + col0 / - col0 AS col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT + tab1.col2 * - tab1.col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT + 72 * ( + col2 ) FROM tab1
----
3888
4104
6912

query I rowsort
SELECT - col2 * 84 FROM tab2
----
-2184
-2268
-3192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7108
SELECT - - CAST( NULL AS SIGNED ) + - col1 + col2 * + col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7108
SELECT - - CAST ( NULL AS INTEGER ) + - col1 + col2 * + col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * + col1 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + ( ( col1 ) ) FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7111
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7111
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col1 FROM tab0
----
NULL

query I rowsort
SELECT + col2 * col0 * - tab0.col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT col2 * + col2 * + 46 FROM tab0 AS cor0
----
309304
46
50094

query I rowsort
SELECT - + col0 + col1 * col1 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT - - col2 + + 34 + + col2 AS col1 FROM tab0 AS cor0
----
100
198
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7116
SELECT - col1 + + CAST( NULL AS SIGNED ) * - col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7116
SELECT - col1 + + CAST ( NULL AS INTEGER ) * - col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7117
SELECT - col1 + + CAST( - col1 AS SIGNED ) + col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7117
SELECT - col1 + + CAST ( - col1 AS INTEGER ) + col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + + col2 * - col0 + + col0 col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + col1 - - col2 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT col1 - 9 * - cor0.col2 FROM tab0 AS cor0
----
106
383
829

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7121
SELECT ALL - tab2.col2 + col0 + CAST( - col1 AS SIGNED ) AS col2 FROM tab2
----
-51
-7
24

skipif mysql # not compatible
query I rowsort label-7121
SELECT ALL - tab2.col2 + col0 + CAST ( - col1 AS INTEGER ) AS col2 FROM tab2
----
-51
-7
24

query I rowsort
SELECT - col1 - ( + cor0.col0 ) FROM tab1 cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7123
SELECT - + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7123
SELECT - + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7125
SELECT DISTINCT + + col1 DIV col2 AS col0 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-7125
SELECT DISTINCT + + col1 / col2 AS col0 FROM tab0 AS cor0
----
1
2
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7126
SELECT ALL - col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7126
SELECT ALL - col0 / col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 20 AS col2 FROM tab2 cor0
----
20
20
20

query I rowsort
SELECT + col0 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + 66 FROM tab2 AS cor0
----
66

query I rowsort
SELECT DISTINCT + col1 * col2 + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT col2 - - ( + 89 ) * + col0 AS col0 FROM tab2 AS cor0
----
650
6968
7069

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7132
SELECT DISTINCT col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7132
SELECT DISTINCT col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 * + col1 * col2 + col1 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT - col2 + ( - cor0.col0 ) * - col0 * col1 FROM tab2 AS cor0
----
106059
1492
358930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + 44 * + 68 col2 FROM tab2 cor0
----
2933
2961
2975

onlyif mysql # use DIV operator for integer division
query I rowsort label-7136
SELECT DISTINCT - col0 DIV 92 AS col2 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7136
SELECT DISTINCT - col0 / 92 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT col0 * - col0 * 56 + cor0.col2 FROM tab0 cor0
----
-32223
-443494
-68599

query I rowsort
SELECT ALL - - col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab1, tab1 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL ( 90 ) FROM tab1 AS cor0
----
90
90
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7141
SELECT - col0 DIV ( col1 * ( - col1 ) ) + + col1 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7141
SELECT - col0 / ( col1 * ( - col1 ) ) + + col1 FROM tab1 cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7142
SELECT + CAST( - col1 AS SIGNED ) * cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-7142
SELECT + CAST ( - col1 AS INTEGER ) * cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ( - 52 ) * col1 FROM tab2 cor0
----
-1612
-3068
-884

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col2 AS REAL ) + col2 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7145
SELECT CAST( col2 AS SIGNED ) + - col0 FROM tab2 AS cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-7145
SELECT CAST ( col2 AS INTEGER ) + - col0 FROM tab2 AS cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 40 col2 FROM tab0
----
1400
3560
960

query I rowsort
SELECT ALL 13 * + 98 FROM tab1 AS cor0
----
1274
1274
1274

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7148
SELECT CAST( NULL AS SIGNED ) * + col2 + cor0.col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7148
SELECT CAST ( NULL AS INTEGER ) * + col2 + cor0.col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7149
SELECT DISTINCT + CAST( - cor0.col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7149
SELECT DISTINCT + CAST ( - cor0.col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT 3 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT - col0 * - ( 88 ) AS col0 FROM tab1
----
264
5632
7040

query I rowsort
SELECT ALL 72 * - col0 FROM tab1
----
-216
-4608
-5760

query I rowsort
SELECT - 59 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7154
SELECT CAST( NULL AS SIGNED ) - 19 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7154
SELECT CAST ( NULL AS INTEGER ) - 19 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 55 * col1 AS col2 FROM tab2 AS cor0
----
-1705
-3245
-935

query I rowsort
SELECT ( + col1 ) * col2 - - 95 FROM tab1
----
1343
1499
665

query I rowsort
SELECT - 9 + col2 FROM tab0 cor0
----
-8
24
73

query I rowsort
SELECT ALL + col2 + - cor0.col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 - col1 AS col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT - col1 + - col0 * - 97 AS col1 FROM tab1 cor0
----
265
6198
7747

query I rowsort
SELECT ALL - 7 FROM tab0, tab2 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7162
SELECT ALL + ( col1 ) + - col2 DIV - col1 AS col1 FROM tab1
----
15
20
28

skipif mysql # not compatible
query I rowsort label-7162
SELECT ALL + ( col1 ) + - col2 / - col1 AS col1 FROM tab1
----
15
20
28

query I rowsort
SELECT ALL - 34 + col1 * col1 FROM tab0
----
7362
8247
9375

query I rowsort
SELECT DISTINCT 13 * - col1 FROM tab1 AS cor0
----
-130
-169
-338

query I rowsort
SELECT ALL - 27 * col0 + + 19 FROM tab1 AS cor0
----
-1709
-2141
-62

query I rowsort
SELECT ( cor0.col1 ) * 67 AS col0 FROM tab0 AS cor0
----
5762
6097
6499

query I rowsort
SELECT ALL - col1 * + col1 + + col2 + col1 AS col1 FROM tab0 AS cor0
----
-7277
-8108
-9311

query I rowsort
SELECT ALL + cor0.col0 * cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - 1 * col2 FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 43 col1 FROM tab1 cor0
----
-43
-43
-43

query I rowsort
SELECT ALL - col1 + - cor0.col2 + 18 AS col0 FROM tab1 AS cor0
----
-49
-62
-91

query I rowsort
SELECT - tab0.col0 * 64 FROM tab0, tab0 AS cor0
----
9 values hashing to a16c7dc75e6969f3fc9d72c896abf583

query I rowsort
SELECT DISTINCT col0 * ( col2 ) * + col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + col2 - - 26 FROM tab1 AS cor0
----
122
80
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7175
SELECT ALL cor1.col1 DIV 15 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-7175
SELECT ALL cor1.col1 / 15 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT DISTINCT - + col1 + + 6 AS col0 FROM tab1 AS cor0
----
-20
-4
-7

query I rowsort
SELECT ALL cor0.col2 * + 22 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 5882b1cc77f7fddcb836ab4ba56964df

query I rowsort
SELECT + ( 87 ) * col2 FROM tab2 AS cor0
----
2262
2349
3306

query I rowsort
SELECT DISTINCT + - 70 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2846
3179
9146

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7180
SELECT ALL + CAST( NULL AS SIGNED ) + 2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7180
SELECT ALL + CAST ( NULL AS INTEGER ) + 2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + - cor0.col1 * col2 * - col1 FROM tab0 cor0
----
243982
678951
9312

query I rowsort
SELECT - col2 + + 59 AS col1 FROM tab0
----
-23
26
58

query I rowsort
SELECT - ( 86 ) AS col1 FROM tab1 AS cor0
----
-86
-86
-86

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab1 AS cor1, tab2, tab2 cor2
----
3645 values hashing to 803a5565701c4ced6bba69940782c17a

onlyif mysql # use DIV operator for integer division
query I rowsort label-7185
SELECT ALL cor0.col2 DIV cor1.col1 FROM tab2, tab1 cor0, tab2 cor1
----
27 values hashing to fc02ba37163e7121e1ec4d8150be1d57

skipif mysql # not compatible
query I rowsort label-7185
SELECT ALL cor0.col2 / cor1.col1 FROM tab2, tab1 cor0, tab2 cor1
----
27 values hashing to fc02ba37163e7121e1ec4d8150be1d57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 26 * col2 col0 FROM tab0 AS cor0
----
-9
2043
834

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 97 * ( col1 ) col2 FROM tab0 AS cor0
----
8342
8827
9409

query I rowsort
SELECT ALL 35 FROM tab2 cor0
----
35
35
35

query I rowsort
SELECT ALL cor0.col0 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - + col0 + - col0 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT - col1 + + 75 * col1 * + col2 FROM tab2 AS cor0
----
114991
48433
62744

query I rowsort
SELECT DISTINCT - + col0 * - 40 AS col1 FROM tab1 AS cor0
----
120
2560
3200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7193
SELECT ALL CAST( 10 AS SIGNED ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

skipif mysql # not compatible
query I rowsort label-7193
SELECT ALL CAST ( 10 AS INTEGER ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # use DIV operator for integer division
query I rowsort label-7194
SELECT DISTINCT cor0.col1 DIV - 56 - 88 * + col0 FROM tab1 AS cor0
----
-264
-5632
-7040

skipif mysql # not compatible
query I rowsort label-7194
SELECT DISTINCT cor0.col1 / - 56 - 88 * + col0 FROM tab1 AS cor0
----
-264
-5632
-7040

onlyif mysql # use DIV operator for integer division
query I rowsort label-7195
SELECT ALL - + cor0.col2 + col0 DIV col0 AS col0 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-7195
SELECT ALL - + cor0.col2 + col0 / col0 AS col0 FROM tab0 AS cor0
----
-32
-81
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7196
SELECT + + col1 DIV col1 AS col2 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7196
SELECT + + col1 / col1 AS col2 FROM tab2 cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7197
SELECT + + col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7197
SELECT + + col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 14 + + col2 * + 41 AS col2 FROM tab2
----
1052
1093
1544

query I rowsort
SELECT + - col2 * ( + col2 ) AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col1 * + 6 FROM tab0 cor0
----
-516
-546
-582

query I rowsort
SELECT + - 52 + - col1 FROM tab0 cor0
----
-138
-143
-149

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7202
SELECT - CAST( col0 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-7202
SELECT - CAST ( col0 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7203
SELECT ALL + + col2 DIV col2 + + 54 AS col2 FROM tab1 AS cor0
----
55
55
55

skipif mysql # not compatible
query I rowsort label-7203
SELECT ALL + + col2 / col2 + + 54 AS col2 FROM tab1 AS cor0
----
55
55
55

query I rowsort
SELECT - - col2 + - col0 + - ( + cor0.col0 + - col0 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - ( + col0 ) + + col0 * + col0 * col0 AS col2 FROM tab2
----
336
474474
492960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col1 + col0 col0 FROM tab2
----
3559
368
968

query I rowsort
SELECT ALL tab1.col0 * col0 * col2 FROM tab1
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-7208
SELECT + + 23 * col0 DIV 62 AS col2 FROM tab1 AS cor0
----
1
23
29

skipif mysql # not compatible
query I rowsort label-7208
SELECT + + 23 * col0 / 62 AS col2 FROM tab1 AS cor0
----
1
23
29

query I rowsort
SELECT col2 + - cor0.col0 + + col2 * col2 AS col0 FROM tab1 AS cor0
----
2967
3242
9232

query I rowsort
SELECT - col1 + + col1 + + ( + col2 ) AS col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT col1 + cor0.col0 + + col2 FROM tab1 cor0
----
131
189
83

query I rowsort
SELECT DISTINCT - + col2 + col1 * + 7 + col1 AS col2 FROM tab2 AS cor0
----
221
446
98

query I rowsort
SELECT ALL 3 * col0 * + col1 AS col1 FROM tab2
----
13806
4029
651

query I rowsort
SELECT ( + 40 ) AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT 26 * col1 AS col0 FROM tab0
----
2236
2366
2522

query I rowsort
SELECT + col2 + col2 * - col0 * col1 FROM tab2 AS cor0
----
-119626
-50996
-5832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + + col0 col1 FROM tab0 cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7218
SELECT CAST( NULL AS SIGNED ) col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7218
SELECT CAST ( NULL AS INTEGER ) col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 * col1 col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT 44 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT col2 * - cor0.col1 * col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT - cor0.col2 + 92 * - col0 FROM tab2 AS cor0
----
-671
-7202
-7306

query I rowsort
SELECT - - 1 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7225
SELECT DISTINCT - col0 * - col1 + + col2 * cor0.col0 DIV col0 AS col1 FROM tab1 AS cor0
----
1136
132
697

skipif mysql # not compatible
query I rowsort label-7225
SELECT DISTINCT - col0 * - col1 + + col2 * cor0.col0 / col0 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - ( - ( col2 ) ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + col1 * - col2 + 94 AS col1 FROM tab1 AS cor0
----
1342
1498
664

query I rowsort
SELECT - ( + col1 ) * col1 - + 41 * col0 * ( - col1 ) FROM tab2 AS cor0
----
185201
54774
7936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) * 65 + - col1 * cor0.col1 * + ( 79 + col0 ) col1 FROM tab1 AS cor0
----
-18005
-33111
-58942

query I rowsort
SELECT - 62 * - col1 AS col0 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT 27 - col0 FROM tab0 AS cor0
----
-62
-8
3

query I rowsort
SELECT 92 * + col1 AS col1 FROM tab1 AS cor0
----
1196
2392
920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col1 ) col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + + 92 FROM tab1, tab2, tab0 AS cor0, tab0
----
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 72 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7236
SELECT col2 + - CAST( - 98 AS SIGNED ) * + col2 AS col1 FROM tab2
----
2574
2673
3762

skipif mysql # not compatible
query I rowsort label-7236
SELECT col2 + - CAST ( - 98 AS INTEGER ) * + col2 AS col1 FROM tab2
----
2574
2673
3762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7237
SELECT DISTINCT + CAST( NULL AS SIGNED ) / - 63 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7237
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / - 63 col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + 90 * + cor0.col2 + col0 AS col2 FROM tab0 AS cor0
----
125
2994
7469

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 43 + - cor0.col2 * + col1 col0 FROM tab2 AS cor0
----
-1577
-689
-880

query I rowsort
SELECT DISTINCT col1 * cor0.col2 * + col1 + ( col2 ) * - col1 FROM tab2 AS cor0
----
10336
25110
88972

query I rowsort
SELECT + + 36 FROM tab0 cor0
----
36
36
36

query I rowsort
SELECT DISTINCT 39 + col0 * + cor0.col1 * cor0.col2 FROM tab2 AS cor0
----
119691
51073
5898

query I rowsort
SELECT - 24 + 1 FROM tab2 AS cor0
----
-23
-23
-23

query I rowsort
SELECT DISTINCT - 49 * - 88 FROM tab0 AS cor0
----
4312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 59 * + 62 + cor0.col1 * - col0 col0 FROM tab0 AS cor0
----
-11757
-5722
-7053

query I rowsort
SELECT DISTINCT + ( - 50 ) - - col2 * col0 AS col0 FROM tab1 AS cor0
----
112
3598
7630

query I rowsort
SELECT DISTINCT + ( 57 ) FROM tab2 cor0
----
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7248
SELECT ALL 79 DIV + 34 AS col1 FROM tab2 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-7248
SELECT ALL 79 / + 34 AS col1 FROM tab2 AS cor0
----
2
2
2

query I rowsort
SELECT ALL + col0 + cor0.col0 * col1 AS col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - + col0 * + col1 + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - + 6 * ( + col0 ) AS col1 FROM tab2 AS cor0
----
-42
-468
-474

query I rowsort
SELECT DISTINCT + - ( cor0.col2 ) - cor0.col0 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7253
SELECT + ( + col1 ) + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7253
SELECT + ( + col1 ) + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * col2 + - 8 + tab2.col0 AS col2 FROM tab2
----
-190
-1958
-2931

query I rowsort
SELECT 22 * - col1 * - 87 + - col2 + col1 FROM tab0 AS cor0
----
164657
174183
185754

query I rowsort
SELECT ALL - 17 + col0 AS col0 FROM tab1 cor0
----
-14
47
63

query I rowsort
SELECT - col1 * + col2 - - col0 * - col2 AS col0 FROM tab2 AS cor0
----
-1026
-3562
-3648

query I rowsort
SELECT DISTINCT + + ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + 19 * col0 AS col1 FROM tab2 AS cor0
----
133
1482
1501

query I rowsort
SELECT col1 + cor0.col0 * - 13 * - col1 + col2 FROM tab1 AS cor0
----
1094
13629
8387

query I rowsort
SELECT + + col2 + col0 * col2 + col1 FROM tab1 AS cor0
----
242
3715
7789

query I rowsort
SELECT ALL - col1 + col1 * + 50 FROM tab1 cor0
----
1274
490
637

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7263
SELECT DISTINCT + col2 + CAST( + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-7263
SELECT DISTINCT + col2 + CAST ( + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT 86 + 9 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ALL + col2 + - col2 + + 4 * col0 * + col0 FROM tab2
----
196
24336
24964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * tab1.col2 col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - + col2 + + col0 * + ( - col0 ) FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT ALL - - col2 + - cor0.col0 * 22 * col0 FROM tab0 AS cor0
----
-12639
-174180
-26949

query I rowsort
SELECT + + cor0.col0 * - cor0.col2 + + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT + col1 + col2 * - 4 FROM tab0 AS cor0
----
-237
-46
93

query I rowsort
SELECT DISTINCT + - col0 * ( - col0 ) AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab0, tab2, tab1 AS cor0, tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7273
SELECT ALL + cor0.col2 DIV + 45 FROM tab1 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-7273
SELECT ALL + cor0.col2 / + 45 FROM tab1 AS cor0
----
1
1
2

query I rowsort
SELECT ALL - + cor0.col2 * cor0.col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT col2 * - 92 + col2 AS col1 FROM tab0 AS cor0
----
-3003
-7462
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-7276
SELECT - col0 DIV + 25 + - col2 * col2 DIV col2 - + 77 FROM tab1 AS cor0
----
-131
-136
-176

skipif mysql # not compatible
query I rowsort label-7276
SELECT - col0 / + 25 + - col2 * col2 / col2 - + 77 FROM tab1 AS cor0
----
-131
-136
-176

query I rowsort
SELECT col1 * + 98 * - col1 + col2 * col1 * col2 AS col1 FROM tab0
----
-199654
-631154
-921985

onlyif mysql # use DIV operator for integer division
query I rowsort label-7278
SELECT + col2 + - 67 + col2 DIV - col1 FROM tab1
----
-15
-15
22

skipif mysql # not compatible
query I rowsort label-7278
SELECT + col2 + - 67 + col2 / - col1 FROM tab1
----
-15
-15
22

query I rowsort
SELECT col0 * 44 * - col2 + + col0 AS col2 FROM tab0 AS cor0
----
-1505
-321023
-34824

query I rowsort
SELECT - 68 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6fbba7db5bccb533a35aa5125a231f88

query I rowsort
SELECT + + cor0.col0 - + col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT - 24 * cor0.col2 + - 42 - + col0 AS col1 FROM tab1 cor0
----
-1341
-1474
-2426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 52 * col2 + ( + ( + cor0.col2 ) ) col1 FROM tab0 AS cor0
----
-1683
-4182
-51

query I rowsort
SELECT - 28 + col1 * col2 AS col2 FROM tab0
----
2810
69
7434

query I rowsort
SELECT col0 - 0 AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT - 40 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT ALL - col1 * col0 + ( col2 ) + - col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - 58 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + 64 col0 FROM tab2
----
142
143
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-7290
SELECT DISTINCT + 61 + col1 DIV ( - col2 ) AS col2 FROM tab0
----
-36
59
60

skipif mysql # not compatible
query I rowsort label-7290
SELECT DISTINCT + 61 + col1 / ( - col2 ) AS col2 FROM tab0
----
-36
59
60

query I rowsort
SELECT DISTINCT - + cor0.col0 + col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col2 ) - ( cor0.col2 + col1 ) col0 FROM tab2 AS cor0
----
-111
-85
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-7293
SELECT ALL ( col0 ) DIV col1 + - ( + col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7293
SELECT ALL ( col0 ) / col1 + - ( + col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + + 58 * col0 + 5 FROM tab2 AS cor0
----
411
4529
4587

query I rowsort
SELECT + 26 * - 92 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1a148dbb758cf07a250fa37ecaeceae8

query I rowsort
SELECT ALL + + col0 * col0 + + col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT - + 34 - col1 AS col1 FROM tab0 AS cor0
----
-120
-125
-131

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7298
SELECT CAST( + 47 AS SIGNED ) * col0 AS col0 FROM tab0
----
1128
1645
4183

skipif mysql # not compatible
query I rowsort label-7298
SELECT CAST ( + 47 AS INTEGER ) * col0 AS col0 FROM tab0
----
1128
1645
4183

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col1 AS REAL ) AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT + col0 + - col1 + col0 * + 0 * + 94 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7301
SELECT ALL - - CAST( NULL AS SIGNED ) + 86 * + cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7301
SELECT ALL - - CAST ( NULL AS INTEGER ) + 86 * + cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 79 + + col0 + col1 * col1 * col2 AS col0 FROM tab1 AS cor0
----
16383
36586
5843

query I rowsort
SELECT ALL - col0 + + col1 * cor0.col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT + cor0.col0 * + 91 FROM tab1 AS cor0
----
273
5824
7280

query I rowsort
SELECT ALL + - 22 + - col1 * + col1 FROM tab2 cor0
----
-311
-3503
-983

query I rowsort
SELECT + ( - ( col2 ) ) - ( + 99 ) * + col0 AS col1 FROM tab0 cor0
----
-2409
-3466
-8893

query I rowsort
SELECT ALL col1 + col1 * + col2 + 22 * col1 AS col0 FROM tab2 AS cor0
----
1037
1550
2891

query I rowsort
SELECT ALL + + 17 FROM tab1 AS cor0
----
17
17
17

query I rowsort
SELECT col2 + + col1 * col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT - - ( col0 ) AS col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT - + cor0.col0 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7312
SELECT DISTINCT - CAST( - 63 AS SIGNED ) * col0 AS col2 FROM tab1
----
189
4032
5040

skipif mysql # not compatible
query I rowsort label-7312
SELECT DISTINCT - CAST ( - 63 AS INTEGER ) * col0 AS col2 FROM tab1
----
189
4032
5040

query I rowsort
SELECT + 92 * - col1 AS col1 FROM tab2 AS cor0
----
-1564
-2852
-5428

query I rowsort
SELECT DISTINCT 9 FROM tab0, tab2 AS cor0
----
9

query I rowsort
SELECT 93 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT ALL + 76 FROM tab0, tab0 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT DISTINCT + - col2 * 59 FROM tab2 AS cor0
----
-1534
-1593
-2242

onlyif mysql # use DIV operator for integer division
query I rowsort label-7318
SELECT ALL + col0 DIV 62 AS col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7318
SELECT ALL + col0 / 62 AS col2 FROM tab1
----
0
1
1

query I rowsort
SELECT ALL - col1 * + 25 - cor0.col0 FROM tab2 AS cor0
----
-1553
-504
-782

query I rowsort
SELECT col0 + col0 * col0 AS col1 FROM tab1 cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col2 col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col1 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT - col0 + ( col2 ) FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7324
SELECT - col1 * ( - col1 * + col2 ) + + col0 DIV - cor0.col1 AS col0 FROM tab2 AS cor0
----
10978
25947
90505

skipif mysql # not compatible
query I rowsort label-7324
SELECT - col1 * ( - col1 * + col2 ) + + col0 / - cor0.col1 AS col0 FROM tab2 AS cor0
----
10978
25947
90505

query I rowsort
SELECT - + ( + col1 ) AS col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT - col2 * col2 + col2 * - col1 FROM tab1 AS cor0
----
-10464
-3819
-4320

query I rowsort
SELECT ALL col1 + + ( + 27 ) FROM tab2
----
44
58
86

query I rowsort
SELECT col2 * - col2 + col2 + + col0 AS col2 FROM tab2
----
-1327
-572
-695

onlyif mysql # use DIV operator for integer division
query I rowsort label-7329
SELECT - col0 DIV - CAST( col1 AS SIGNED ) FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7329
SELECT - col0 / - CAST ( col1 AS INTEGER ) FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 22 AS REAL ) AS col2 FROM tab2, tab0 cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT DISTINCT 48 AS col1 FROM tab0, tab2 cor0
----
48

query I rowsort
SELECT - ( 43 ) - col0 FROM tab1 AS cor0
----
-107
-123
-46

query I rowsort
SELECT - cor0.col0 * col2 - + col1 * col0 * + col1 AS col0 FROM tab1 AS cor0
----
-10048
-21200
-2190

query I rowsort
SELECT + - 15 + col0 AS col1 FROM tab0 AS cor0
----
20
74
9

query I rowsort
SELECT - col1 + + col1 * col1 AS col1 FROM tab0 cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab2, tab2 AS cor2
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7337
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * - col2 * - col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7337
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * - col2 * - col1 FROM tab1 AS cor0
----
NULL

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 cor1, tab0 AS cor2
----
972 values hashing to 380241bbc503a31e70494611a87ffd99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 78 + 86 col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to a1509e33d3aaa01839fa4f2fb69edf25

query I rowsort
SELECT ALL - 95 AS col2 FROM tab2
----
-95
-95
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 0 * - col1 * + col2 col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL tab1.col0 * ( + col1 ) FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7343
SELECT DISTINCT + col1 * - col2 DIV col2 - col2 * 95 AS col1 FROM tab0
----
-192
-3221
-7881

skipif mysql # not compatible
query I rowsort label-7343
SELECT DISTINCT + col1 * - col2 / col2 - col2 * 95 AS col1 FROM tab0
----
-192
-3221
-7881

query I rowsort
SELECT DISTINCT + 53 + 68 - col1 * ( col1 + - col2 ) AS col1 FROM tab1
----
1200
591
849

query I rowsort
SELECT - col0 + 81 + + col2 AS col2 FROM tab1 AS cor0
----
132
74
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 col1 FROM tab0, tab1 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7347
SELECT 41 DIV col2 AS col0 FROM tab0
----
0
1
41

skipif mysql # not compatible
query I rowsort label-7347
SELECT 41 / col2 AS col0 FROM tab0
----
0
1
41

query I rowsort
SELECT col2 * 19 - col0 FROM tab2
----
416
506
643

query I rowsort
SELECT col1 + + col1 - - col0 AS col1 FROM tab1
----
106
55
84

query I rowsort
SELECT DISTINCT ( col2 * col0 ) + 60 - 6 AS col0 FROM tab2
----
2082
243
3056

query I rowsort
SELECT col0 * + col1 + + col0 AS col2 FROM tab2
----
1422
224
4680

query I rowsort
SELECT - ( + col2 + 93 * col0 ) AS col1 FROM tab2
----
-678
-7280
-7385

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7353
SELECT - - cor0.col0 + CAST( NULL AS SIGNED ) * - col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7353
SELECT - - cor0.col0 + CAST ( NULL AS INTEGER ) * - col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7354
SELECT ALL tab2.col0 DIV - tab2.col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-7354
SELECT ALL tab2.col0 / - tab2.col1 FROM tab2
----
-1
-4
0

query I rowsort
SELECT - 0 * - col2 * ( - col0 ) AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + 92 AS col0 FROM tab0
----
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7357
SELECT - + col2 DIV - cor0.col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7357
SELECT - + col2 / - cor0.col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT DISTINCT + - cor0.col1 + - ( ( col2 ) ) * 1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL - col0 * 88 + + ( + col2 ) * cor0.col2 FROM tab1 AS cor0
----
-2383
2176
2652

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 + + col2 col1 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL col0 * + ( 71 + + col2 ) FROM tab2 AS cor0
----
686
7566
8611

query I rowsort
SELECT 23 + cor1.col2 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 5760c94b2d1b82ab5e071a5878ef8882

onlyif mysql # use DIV operator for integer division
query I rowsort label-7363
SELECT DISTINCT - cor0.col1 DIV col2 AS col0 FROM tab0 cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-7363
SELECT DISTINCT - cor0.col1 / col2 AS col0 FROM tab0 cor0
----
-1
-2
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7364
SELECT ALL + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7364
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 70 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT + - 7 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT + ( col0 ) + 28 FROM tab0
----
117
52
63

query I rowsort
SELECT ALL - cor0.col2 * + ( col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col0 * col0 + - col1 * + col2 FROM tab1 cor0
----
-1413
-4666
-7648

query I rowsort
SELECT DISTINCT + cor0.col0 + + col1 * + col2 AS col2 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - 36 col0 FROM tab1 AS cor0
----
-1944
-2052
-3456

query I rowsort
SELECT - col1 + - ( + tab1.col2 ) FROM tab1
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7373
SELECT ALL col2 * col0 DIV col1 AS col2 FROM tab1
----
364
590
6

skipif mysql # not compatible
query I rowsort label-7373
SELECT ALL col2 * col0 / col1 AS col2 FROM tab1
----
364
590
6

query I rowsort
SELECT 56 - + col2 AS col2 FROM tab1
----
-1
-40
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7375
SELECT DISTINCT - + col0 + cor0.col2 * + CAST( + col2 AS SIGNED ) * - col1 + + 7 AS col1 FROM tab2 AS cor0
----
-22599
-24620
-39955

skipif mysql # not compatible
query I rowsort label-7375
SELECT DISTINCT - + col0 + cor0.col2 * + CAST ( + col2 AS INTEGER ) * - col1 + + 7 AS col1 FROM tab2 AS cor0
----
-22599
-24620
-39955

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 7 + col2 col1 FROM tab1 AS cor0
----
47
50
89

query I rowsort
SELECT - 78 - + col2 AS col0 FROM tab1 AS cor0
----
-132
-135
-174

query I rowsort
SELECT ALL 33 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

query I rowsort
SELECT col1 * ( tab0.col0 * 49 ) FROM tab0
----
101136
166355
396851

query I rowsort
SELECT ( col2 ) + + col0 * - col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT col2 + - col1 + tab1.col1 AS col2 FROM tab1
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7382
SELECT + CAST( + col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-7382
SELECT + CAST ( + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT 18 + + tab1.col2 FROM tab1
----
114
72
75

query I rowsort
SELECT - tab0.col0 + col1 AS col2 FROM tab0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - ( col2 + - col2 ) col0 FROM tab0
----
24
35
89

query I rowsort
SELECT - 95 + col2 * 44 FROM tab1 AS cor0
----
2281
2413
4129

query I rowsort
SELECT + col1 * - col0 + + 1 + - 84 AS col1 FROM tab0 cor0
----
-2147
-3478
-8182

onlyif mysql # use DIV operator for integer division
query I rowsort label-7388
SELECT 8 * col1 DIV + col2 FROM tab0
----
20
776
8

skipif mysql # not compatible
query I rowsort label-7388
SELECT 8 * col1 / + col2 FROM tab0
----
20
776
8

query I rowsort
SELECT ALL - - col2 * - cor0.col1 + + ( - cor0.col1 ) + col2 FROM tab2 AS cor0
----
-1567
-625
-841

query I rowsort
SELECT DISTINCT + + col2 * col1 + + 66 AS col2 FROM tab2 AS cor0
----
1600
712
903

query I rowsort
SELECT ALL + 55 * col0 AS col2 FROM tab1 AS cor0
----
165
3520
4400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL + - 89 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
-10
-11
-82

query I rowsort
SELECT - - col0 + cor0.col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT 91 AS col2 FROM tab2 AS cor0
----
91
91
91

query I rowsort
SELECT ALL - - 13 + cor0.col1 * - 85 + + col2 FROM tab1 AS cor0
----
-2143
-780
-996

query I rowsort
SELECT ALL ( - col2 ) + col1 AS col1 FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7398
SELECT ALL + col0 + + col1 DIV 11 FROM tab0
----
31
43
97

skipif mysql # not compatible
query I rowsort label-7398
SELECT ALL + col0 + + col1 / 11 FROM tab0
----
31
43
97

query I rowsort
SELECT ALL - tab2.col1 + + col2 AS col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL ( - tab0.col0 ) + - col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT ALL - ( col2 ) + + 25 * col2 FROM tab0
----
1968
24
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7402
SELECT ALL CAST( NULL AS DECIMAL ) AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7402
SELECT ALL CAST ( NULL AS REAL ) AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7403
SELECT ALL - 20 - - cor0.col0 DIV 80 FROM tab0 AS cor0
----
-19
-20
-20

skipif mysql # not compatible
query I rowsort label-7403
SELECT ALL - 20 - - cor0.col0 / 80 FROM tab0 AS cor0
----
-19
-20
-20

query I rowsort
SELECT DISTINCT + 23 * - cor0.col1 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT DISTINCT - col0 + + col2 * - 66 AS col1 FROM tab0 AS cor0
----
-101
-2202
-5501

query I rowsort
SELECT + 3 + + col1 AS col2 FROM tab0 cor0
----
100
89
94

query I rowsort
SELECT ALL + ( + cor0.col2 ) + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + col1 + col2 * + 8 * col2 AS col0 FROM tab2 AS cor0
----
11569
5467
5863

query I rowsort
SELECT + col0 - ( - cor0.col1 + - col2 ) FROM tab1 AS cor0
----
131
189
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7410
SELECT DISTINCT - + col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7410
SELECT DISTINCT - + col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col1 + + 4 AS col1 FROM tab0 AS cor0
----
101
90
95

query I rowsort
SELECT ALL + + col2 + - col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + + col2 * - col1 + cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + col0 - col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7415
SELECT 44 DIV + col1 + - ( + tab1.col0 ) * + col0 AS col1 FROM tab1
----
-4092
-6397
-8

skipif mysql # not compatible
query I rowsort label-7415
SELECT 44 / + col1 + - ( + tab1.col0 ) * + col0 AS col1 FROM tab1
----
-4092
-6397
-8

query I rowsort
SELECT + 21 + col0 + col0 FROM tab0
----
199
69
91

query I rowsort
SELECT DISTINCT + + 84 * col2 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT - ( - col2 ) * col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( + 89 AS REAL ) + col2 - - col0 FROM tab2 AS cor0
----
-55
15
28

query I rowsort
SELECT ALL + + 64 AS col1 FROM tab2 AS cor0
----
64
64
64

query I rowsort
SELECT + - 29 * - col0 FROM tab1 AS cor0
----
1856
2320
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 col1 FROM tab2, tab0 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT DISTINCT + col1 + + 23 * col0 FROM tab2 AS cor0
----
1834
1853
192

query I rowsort
SELECT - + ( 6 ) * col0 * + col0 FROM tab1 AS cor0
----
-24576
-38400
-54

query I rowsort
SELECT ALL + ( - col1 ) * col2 + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * ( - col1 ) - 66 FROM tab2 cor0
----
-1409
-283
-4668

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col2 ) * col1 col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7428
SELECT - - CAST( - 68 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-68
-68
-68

skipif mysql # not compatible
query I rowsort label-7428
SELECT - - CAST ( - 68 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-68
-68
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7429
SELECT ALL - + CAST( NULL AS SIGNED ) * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7429
SELECT ALL - + CAST ( NULL AS INTEGER ) * + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 44 * col2 * col1 FROM tab2 cor0
----
28424
36828
67496

query I rowsort
SELECT DISTINCT - - col1 + cor0.col2 * + col2 AS col2 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT - 90 * - 31 * + col1 AS col1 FROM tab2 AS cor0
----
164610
47430
86490

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) + col1 col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT ALL - - 95 AS col1 FROM tab2 AS cor0
----
95
95
95

query I rowsort
SELECT DISTINCT + - ( col1 ) * - cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7436
SELECT ALL + - ( + col0 ) DIV - col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7436
SELECT ALL + - ( + col0 ) / - col2 FROM tab0 AS cor0
----
0
1
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7437
SELECT ALL - + CAST( col2 AS SIGNED ) + - cor0.col1 FROM tab1 AS cor0
----
-109
-67
-80

skipif mysql # not compatible
query I rowsort label-7437
SELECT ALL - + CAST ( col2 AS INTEGER ) + - cor0.col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - cor0.col2 * + col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - col0 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col2 * cor0.col0 * + ( + col1 + + col0 ) AS col2 FROM tab0 AS cor0
----
1313640
4620
87120

onlyif mysql # use DIV operator for integer division
query I rowsort label-7441
SELECT + ( tab0.col1 * - tab0.col0 ) + 72 DIV col1 AS col0 FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-7441
SELECT + ( tab0.col1 * - tab0.col0 ) + 72 / col1 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col1 * - tab1.col2 AS col2 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7443
SELECT col1 DIV - tab2.col0 + col2 AS col2 FROM tab2
----
23
26
38

skipif mysql # not compatible
query I rowsort label-7443
SELECT col1 / - tab2.col0 + col2 AS col2 FROM tab2
----
23
26
38

query I rowsort
SELECT col2 AS col1 FROM tab2 WHERE ( NULL ) BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT col2 * col2 * tab1.col0 FROM tab1
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col0 * col2 + col0 + col0 col0 FROM tab0
----
-3325
-663940
-68064

query I rowsort
SELECT + col1 * + col2 * tab0.col2 AS col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - col0 FROM tab1 WHERE NULL BETWEEN ( col2 ) AND NULL
----

query I rowsort
SELECT DISTINCT - col2 + - col1 + - col1 AS col1 FROM tab2
----
-144
-72
-89

query I rowsort
SELECT col1 * - col0 + col0 - col2 FROM tab0
----
-2073
-3361
-8092

query I rowsort
SELECT col2 FROM tab2 WHERE NOT NULL < ( col1 )
----

query I rowsort
SELECT ALL col1 * tab1.col1 * col0 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT ALL + col2 AS col1 FROM tab0 WHERE NOT + tab0.col2 <> + col0 * + col2
----

query I rowsort
SELECT ALL col2 * tab2.col2 + col0 * - col2 AS col1 FROM tab2
----
-1352
-1558
540

query I rowsort
SELECT - col1 FROM tab0 WHERE NOT col0 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + col0 - - col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT col0 * col1 + - col1 FROM tab2
----
1326
186
4543

query I rowsort
SELECT col2 * tab2.col2 * - col0 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT ALL - col2 * + col1 * - col0 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-7460
SELECT col1 DIV + col1 + - col2 AS col0 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-7460
SELECT col1 / + col1 + - col2 AS col0 FROM tab0
----
-32
-81
0

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 * col2 <= col0 * col0 * - col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT col0 * + col0 + col0 FROM tab0
----
1260
600
8010

query I rowsort
SELECT ALL + col1 AS col2 FROM tab2 WHERE NOT NULL NOT BETWEEN - col0 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 col1 FROM tab2 WHERE NOT NULL NOT BETWEEN + col0 AND NULL
----

query I rowsort
SELECT + col1 * - col0 * col1 + + col0 FROM tab1
----
-13440
-2025
-6336

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL < col0 * col1
----

query I rowsort
SELECT DISTINCT col2 + + col0 + - col2 FROM tab1
----
3
64
80

query I rowsort
SELECT - col0 * - col2 * + tab2.col2 AS col1 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT tab1.col1 * + col2 - col2 * col2 AS col0 FROM tab1
----
-1512
-2679
-7968

query I rowsort
SELECT ALL col1 + col2 + col0 AS col1 FROM tab2
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-7471
SELECT DISTINCT col0 * col2 DIV - col0 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-7471
SELECT DISTINCT col0 * col2 / - col0 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7472
SELECT + col1 * - col2 DIV - col2 AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7472
SELECT + col1 * - col2 / - col2 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT - col1 * col2 + col2 + - col1 FROM tab0
----
-193
-2891
-7471

onlyif mysql # use DIV operator for integer division
query I rowsort label-7474
SELECT ALL + col2 DIV col1 AS col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-7474
SELECT ALL + col2 / col1 AS col1 FROM tab1
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7475
SELECT ALL - + col2 DIV + cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7475
SELECT ALL - + col2 / + cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * + col1 + col0 * cor0.col1 FROM tab0 cor0
----
15561
3492
4902

onlyif mysql # use DIV operator for integer division
query I rowsort label-7477
SELECT DISTINCT + col2 DIV col1 + - col2 FROM tab1 AS cor0
----
-52
-89

skipif mysql # not compatible
query I rowsort label-7477
SELECT DISTINCT + col2 / col1 + - col2 FROM tab1 AS cor0
----
-52
-89

query I rowsort
SELECT ALL - cor0.col0 * col2 - + col0 * - col0 FROM tab1 AS cor0
----
-1280
-153
448

query I rowsort
SELECT DISTINCT + cor0.col1 * - col2 + - cor0.col2 FROM tab0 AS cor0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7480
SELECT DISTINCT - col0 DIV col0 + col2 * col2 FROM tab0 cor0
----
0
1088
6723

skipif mysql # not compatible
query I rowsort label-7480
SELECT DISTINCT - col0 / col0 + col2 * col2 FROM tab0 cor0
----
0
1088
6723

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 - + col2 * col1 AS col2 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT - tab0.col0 + - col0 * - col1 * - col2 FROM tab0
----
-3430
-664207
-68136

query I rowsort
SELECT ALL + col2 - col2 AS col1 FROM tab1
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( + col0 + - col2 )
----

query I rowsort
SELECT + 82 + cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 015da8b7a41d887846ee4c137f2901ba

query I rowsort
SELECT + col2 + ( col2 ) FROM tab2 cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT ( - col0 ) * col2 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab2 cor1, tab0 cor2
----
972 values hashing to 58757c5bbbd4217c03cf2ac0b6126e55

query I rowsort
SELECT ALL col0 * + 11 + + col1 AS col0 FROM tab2 AS cor0
----
108
886
917

query I rowsort
SELECT ALL + col0 + col1 + col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL - col1 - col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + col0 * - tab0.col0 + col1 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT ALL + col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + - 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 + + col1 col2 FROM tab2
----
55
58
85

query I rowsort
SELECT tab1.col1 + - tab1.col1 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT - 20 + col2 + 84 * - col2 FROM tab1
----
-4502
-4751
-7988

query I rowsort
SELECT + 33 * + col2 FROM tab2
----
1254
858
891

query I rowsort
SELECT - ( + 81 ) * col1 FROM tab1 AS cor0
----
-1053
-2106
-810

query I rowsort
SELECT + 57 + col0 FROM tab2 AS cor0
----
135
136
64

query I rowsort
SELECT ALL 95 * - col2 AS col1 FROM tab2 AS cor0
----
-2470
-2565
-3610

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7503
SELECT + - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-7503
SELECT + - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 col0 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7505
SELECT DISTINCT + CAST( ( col2 ) AS DECIMAL ) + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7505
SELECT DISTINCT + CAST ( ( col2 ) AS REAL ) + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT 37 - + col2 FROM tab2 AS cor0
----
-1
10
11

query I rowsort
SELECT - col1 * col1 + - tab2.col1 - + 22 AS col2 FROM tab2
----
-1014
-328
-3562

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 94 * tab2.col1 col1 FROM tab2, tab1 AS cor0
----
1598
2914
5546

query I rowsort
SELECT DISTINCT col2 + - col2 * col0 AS col2 FROM tab0 cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-7510
SELECT ALL + - col2 DIV col0 + 61 - col0 FROM tab0 AS cor0
----
-28
26
36

skipif mysql # not compatible
query I rowsort label-7510
SELECT ALL + - col2 / col0 + 61 - col0 FROM tab0 AS cor0
----
-28
26
36

query I rowsort
SELECT + col2 + col0 * col2 * col2 AS col1 FROM tab2 AS cor0
----
114114
5130
52754

query I rowsort
SELECT ALL tab1.col0 * 27 + + col2 AS col1 FROM tab1
----
135
1785
2256

query I rowsort
SELECT ALL 71 + + 32 * + tab1.col2 + + col2 AS col2 FROM tab1
----
1853
1952
3239

query I rowsort
SELECT + col0 + col1 + + tab0.col0 AS col0 FROM tab0
----
134
167
269

query I rowsort
SELECT - ( - col0 ) + col2 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + col2 + - col0 + - col2 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL + + col2 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-7518
SELECT + cor0.col2 DIV - cor0.col1 col1 FROM tab1 cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7518
SELECT + cor0.col2 / - cor0.col1 col1 FROM tab1 cor0
----
-2
-5
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7519
SELECT DISTINCT - cor0.col2 * - CAST( NULL AS SIGNED ) / + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7519
SELECT DISTINCT - cor0.col2 * - CAST ( NULL AS INTEGER ) / + col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7520
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7520
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col2 * 27 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT ALL - cor0.col1 * - col0 + col0 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-7523
SELECT ALL - + cor0.col2 DIV 33 + cor0.col0 * col2 DIV col1 FROM tab2 AS cor0
----
175
34
6

skipif mysql # not compatible
query I rowsort label-7523
SELECT ALL - + cor0.col2 / 33 + cor0.col0 * col2 / col1 FROM tab2 AS cor0
----
175
34
6

query I rowsort
SELECT - tab0.col2 * - col0 * col2 + + col0 AS col2 FROM tab0
----
26160
598525
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 col0 FROM tab2
----
97
97
97

query I rowsort
SELECT ALL 59 * tab1.col1 FROM tab1
----
1534
590
767

query I rowsort
SELECT ALL + + cor0.col0 + + 24 AS col2 FROM tab1 cor0
----
104
27
88

skipif mysql # not compatible
query I rowsort
SELECT + - col1 + CAST ( + 82 AS REAL ) * col1 FROM tab2 AS cor0
----
1377
2511
4779

query I rowsort
SELECT - col2 + + 14 AS col1 FROM tab1 AS cor0
----
-40
-43
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7530
SELECT DISTINCT col2 DIV 2 FROM tab1
----
27
28
48

skipif mysql # not compatible
query I rowsort label-7530
SELECT DISTINCT col2 / 2 FROM tab1
----
27
28
48

query I rowsort
SELECT ALL + col0 * ( + col2 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col1 * - col2 + - tab0.col1 AS col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT ALL ( col2 ) + + col2 AS col2 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT + ( 88 ) * col0 + - col0 * 61 + + col1 FROM tab1 AS cor0
----
107
1738
2173

query I rowsort
SELECT DISTINCT col1 * + 5 AS col1 FROM tab1
----
130
50
65

query I rowsort
SELECT ALL + - 75 * - col0 AS col1 FROM tab0 AS cor0
----
1800
2625
6675

onlyif mysql # use DIV operator for integer division
query I rowsort label-7537
SELECT ALL - col2 + col0 DIV col0 AS col0 FROM tab1 cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-7537
SELECT ALL - col2 + col0 / col0 AS col0 FROM tab1 cor0
----
-53
-56
-95

query I rowsort
SELECT - 83 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT ALL - 87 + col2 * col1 AS col1 FROM tab1 cor0
----
1161
1317
483

onlyif mysql # use DIV operator for integer division
query I rowsort label-7540
SELECT DISTINCT ( - col1 ) DIV col2 + - 39 FROM tab1 AS cor0
----
-39

skipif mysql # not compatible
query I rowsort label-7540
SELECT DISTINCT ( - col1 ) / col2 + - 39 FROM tab1 AS cor0
----
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7541
SELECT - + 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-7541
SELECT - + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( 93 ) FROM tab2 AS cor0
----
93
93
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-7543
SELECT ALL + + 85 + col2 DIV col0 FROM tab0 AS cor0
----
85
85
86

skipif mysql # not compatible
query I rowsort label-7543
SELECT ALL + + 85 + col2 / col0 FROM tab0 AS cor0
----
85
85
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7544
SELECT + col2 * col0 + cor0.col2 DIV + cor0.col2 FROM tab1 AS cor0
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-7544
SELECT + col2 * col0 + cor0.col2 / + cor0.col2 FROM tab1 AS cor0
----
163
3649
7681

query I rowsort
SELECT DISTINCT + 20 * cor0.col0 * cor0.col0 FROM tab0 AS cor0
----
11520
158420
24500

query I rowsort
SELECT DISTINCT - - col2 * 68 FROM tab2 AS cor0
----
1768
1836
2584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7547
SELECT CAST( 16 AS SIGNED ) FROM tab1 AS cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-7547
SELECT CAST ( 16 AS INTEGER ) FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT ALL + ( 11 ) * cor0.col2 + col1 + col1 * col1 FROM tab0 AS cor0
----
7845
9274
9517

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 9 col1 FROM tab2
----
-9
-9
-9

query I rowsort
SELECT ALL + col2 * + cor0.col1 - - col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + cor0.col2 * col0 + col0 * + 2 AS col1 FROM tab2 AS cor0
----
203
2184
3160

query I rowsort
SELECT ALL - - col2 + - cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + col2 * + col0 + - col2 AS col1 FROM tab2 cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-7554
SELECT DISTINCT - cor0.col0 * col0 + 67 * col0 DIV col0 - - 38 AS col2 FROM tab0 AS cor0
----
-1120
-471
-7816

skipif mysql # not compatible
query I rowsort label-7554
SELECT DISTINCT - cor0.col0 * col0 + 67 * col0 / col0 - - 38 AS col2 FROM tab0 AS cor0
----
-1120
-471
-7816

query I rowsort
SELECT ALL col1 * cor0.col2 + + 62 * col2 AS col0 FROM tab2 AS cor0
----
2511
3002
3146

query I rowsort
SELECT DISTINCT - - col2 * col2 + + 40 AS col2 FROM tab0 AS cor0
----
1129
41
6764

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7557
SELECT DISTINCT cor0.col2 * + col2 * - col1 + cor0.col1 * CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7557
SELECT DISTINCT cor0.col2 * + col2 * - col1 + cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7558
SELECT DISTINCT + col2 DIV ( + col1 ) + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7558
SELECT DISTINCT + col2 / ( + col1 ) + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + cor1.col0 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT + col1 * - col0 + + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - col1 + - col2 * - col2 FROM tab0 AS cor0
----
-96
1003
6633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col1 col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col2 * + col1 - col1 * - 36 AS col2 FROM tab0
----
10738
3589
5934

query I rowsort
SELECT ALL col1 * - col1 * col2 + + col2 * col1 FROM tab1 AS cor0
----
-14976
-35100
-5130

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 10 col0 FROM tab2 AS cor0
----
10
10
10

query I rowsort
SELECT + ( tab2.col0 ) * + col2 + + col2 * tab2.col1 * + col0 FROM tab2
----
121680
54036
6048

query I rowsort
SELECT 4 * - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 538d9a4b08d168be144ea2eeb9562483

query I rowsort
SELECT DISTINCT col1 * - col0 * col0 AS col2 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT ( + col1 ) AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT 25 * - col2 FROM tab2 AS cor0
----
-650
-675
-950

query I rowsort
SELECT + col0 + - 70 - + col2 FROM tab2 AS cor0
----
-18
-29
-90

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + + col1 * col0 + - 77 AS col0 FROM tab2 AS cor0
----
1266
140
4525

query I rowsort
SELECT col0 * + 85 FROM tab2
----
595
6630
6715

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7575
SELECT DISTINCT + col1 / CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7575
SELECT DISTINCT + col1 / CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL

query I rowsort
SELECT 73 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 9f0f371d979e70a792c8597c6559f0e2

query I rowsort
SELECT ( 41 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT + 97 AS col1 FROM tab2
----
97

query I rowsort
SELECT ALL + 32 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT + 68 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col0 AS REAL ) * cor0.col1 + - col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL ( + 16 * - col1 ) FROM tab0
----
-1376
-1456
-1552

query I rowsort
SELECT ( col1 * + col2 ) + + col0 * ( - col1 + col0 ) FROM tab0
----
-2073
1350
7284

query I rowsort
SELECT DISTINCT - ( + col2 ) + - col0 AS col2 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7585
SELECT DISTINCT col0 + col0 DIV - col1 + col2 * + col2 FROM tab0 AS cor0
----
1113
36
6813

skipif mysql # not compatible
query I rowsort label-7585
SELECT DISTINCT col0 + col0 / - col1 + col2 * + col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT 2 * + col1 AS col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7587
SELECT ALL + 34 * cor0.col1 + CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1085
2065
595

skipif mysql # not compatible
query I rowsort label-7587
SELECT ALL + 34 * cor0.col1 + CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1085
2065
595

query I rowsort
SELECT col1 - - col0 * + col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT col0 * ( - col1 ) - col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT ALL 13 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT + col0 + 31 * - col2 FROM tab2 AS cor0
----
-1099
-728
-830

query I rowsort
SELECT - col2 * - col0 - - cor0.col2 * + col0 AS col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT + col1 + 77 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT ALL ( + col0 ) + - col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + col1 * - 77 FROM tab0 AS cor0
----
-6622
-7007
-7469

query I rowsort
SELECT + + col0 + + col2 * - cor0.col1 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7597
SELECT + - CAST( + 82 AS SIGNED ) + col0 AS col2 FROM tab0 AS cor0
----
-47
-58
7

skipif mysql # not compatible
query I rowsort label-7597
SELECT + - CAST ( + 82 AS INTEGER ) + col0 AS col2 FROM tab0 AS cor0
----
-47
-58
7

query I rowsort
SELECT + col1 * 11 FROM tab0 AS cor0
----
1001
1067
946

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 64 col1 FROM tab2 cor0
----
-64
-64
-64

query I rowsort
SELECT + + cor0.col0 * cor0.col2 + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT - + ( col1 ) + - col2 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT col2 * ( - col2 * col1 ) AS col0 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + cor0.col0 * - col1 - col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT - 5 FROM tab1, tab1 AS cor0, tab0 cor1
----
-5

query I rowsort
SELECT ALL ( - 62 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT ALL + 42 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT + ( + 35 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT ALL - + col0 * + col1 + col0 * - col2 + col1 AS col1 FROM tab1 AS cor0
----
-214
-4278
-8707

query I rowsort
SELECT DISTINCT - col0 + col1 * ( + col2 ) AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT - 39 + col1 * 14 * cor0.col1 FROM tab1 AS cor0
----
1361
2327
9425

query I rowsort
SELECT DISTINCT col1 * + col1 - - 48 * col1 AS col1 FROM tab0 AS cor0
----
11524
12649
14065

query I rowsort
SELECT DISTINCT - col0 * - col2 + - col2 * + 48 * col1 AS col0 FROM tab1 AS cor0
----
-23712
-52224
-67230

query I rowsort
SELECT + 68 AS col1 FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT ALL - + col0 * - 50 + col1 FROM tab2 AS cor0
----
381
3959
3967

query I rowsort
SELECT ALL + + cor0.col1 + + col2 * + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT 7 AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7617
SELECT DISTINCT col2 * + CAST( col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7617
SELECT DISTINCT col2 * + CAST ( col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col1 + col2 * col0 + + col2 FROM tab2 AS cor0
----
2113
247
3057

query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 + - col2 AS col0 FROM tab0 cor0
----
-1226
-609
-8003

query I rowsort
SELECT 41 + 96 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 63adbd6174340773af6070e9f82b685e

query I rowsort
SELECT ALL - col0 + - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7622
SELECT ALL + - cor0.col2 * CAST( NULL AS SIGNED ) + col2 + + col1 * - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7622
SELECT ALL + - cor0.col2 * CAST ( NULL AS INTEGER ) + col2 + + col1 * - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7623
SELECT ALL - - col0 + CAST( NULL AS SIGNED ) * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7623
SELECT ALL - - col0 + 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-7624
SELECT ALL CAST( + 9 AS SIGNED ) FROM tab0 AS cor0
----
9
9
9

skipif mysql # not compatible
query I rowsort label-7624
SELECT ALL CAST ( + 9 AS INTEGER ) FROM tab0 AS cor0
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - tab1.col1 ) col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT ALL 11 * 58 AS col1 FROM tab0
----
638
638
638

query I rowsort
SELECT ALL + - col1 + 20 * + col2 FROM tab0 AS cor0
----
-77
1549
574

query I rowsort
SELECT DISTINCT + col1 * + ( + col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col1 * + 65 * + cor0.col1 AS col0 FROM tab0 cor0
----
480740
538265
611585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 56 * + 46 col1 FROM tab2 AS cor0
----
2576

onlyif mysql # use DIV operator for integer division
query I rowsort label-7631
SELECT DISTINCT + + ( + col0 ) DIV - col0 + + ( - col2 ) * col0 AS col0 FROM tab1 AS cor0
----
-163
-3649
-7681

skipif mysql # not compatible
query I rowsort label-7631
SELECT DISTINCT + + ( + col0 ) / - col0 + + ( - col2 ) * col0 AS col0 FROM tab1 AS cor0
----
-163
-3649
-7681

query I rowsort
SELECT ALL - 62 * col1 * col2 + col1 FROM tab0 AS cor0
----
-175870
-462553
-5917

query I rowsort
SELECT DISTINCT + 76 + - 8 FROM tab0 cor0
----
68

query I rowsort
SELECT ALL - - 27 AS col1 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT + 97 * + cor0.col0 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT DISTINCT col0 + - cor0.col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL + + col0 * col1 * cor0.col2 + + ( col1 ) AS col0 FROM tab1 AS cor0
----
36490
4238
99853

query I rowsort
SELECT DISTINCT - + 25 * - col1 AS col0 FROM tab1 cor0
----
250
325
650

query I rowsort
SELECT ALL col0 + + col2 * - cor0.col1 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT col0 + cor0.col1 + + col2 AS col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL + + col1 - + col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + col1 * cor0.col0 * + 10 AS col1 FROM tab0 AS cor0
----
20640
33950
80990

query I rowsort
SELECT - 88 + cor0.col1 * 77 AS col1 FROM tab2 AS cor0
----
1221
2299
4455

query I rowsort
SELECT DISTINCT col0 * col1 + cor0.col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + 82 AS col1 FROM tab2 cor0
----
82
82
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 67 col1 FROM tab1
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7647
SELECT - col0 DIV - ( col0 ) + - 16 FROM tab1
----
-15
-15
-15

skipif mysql # not compatible
query I rowsort label-7647
SELECT - col0 / - ( col0 ) + - 16 FROM tab1
----
-15
-15
-15

query I rowsort
SELECT ALL - - 94 * col2 AS col2 FROM tab2 AS cor0
----
2444
2538
3572

query I rowsort
SELECT ALL 88 * + col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
16632
178464
264176

query I rowsort
SELECT col2 * - col0 * - col2 AS col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT 32 * - col1 AS col0 FROM tab0 AS cor0
----
-2752
-2912
-3104

query I rowsort
SELECT - + cor0.col2 + + cor0.col2 * - col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT cor1.col0 AS col2 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 64 ) + col2 + ( 5 * col1 ) col1 FROM tab1
----
120
43
97

query I rowsort
SELECT 29 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 40739d223aa019bd2dfe2db99d596302

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7656
SELECT + ( col1 * - CAST( col2 AS SIGNED ) ) AS col2 FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-7656
SELECT + ( col1 * - CAST ( col2 AS INTEGER ) ) AS col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + col1 * col0 * col0 AS col1 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT - + col2 * - 28 * ( col1 ) AS col1 FROM tab1 AS cor0
----
15960
34944
39312

query I rowsort
SELECT - 66 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT col0 + col2 * + ( col2 + + tab0.col2 * - tab0.col1 ) AS col2 FROM tab0
----
-605071
-61
-92541

query I rowsort
SELECT - - 19 + + cor0.col1 FROM tab2 AS cor0
----
36
50
78

query I rowsort
SELECT DISTINCT col2 + + 87 + col0 AS col1 FROM tab0
----
123
144
258

query I rowsort
SELECT DISTINCT + col2 + - ( 65 + col2 ) AS col0 FROM tab1
----
-65

query I rowsort
SELECT - col1 * col1 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT - + 21 * - cor0.col1 + cor0.col1 FROM tab0 cor0
----
1892
2002
2134

query I rowsort
SELECT ALL + ( col2 ) * - col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ( - col0 ) * - col1 + - 52 FROM tab2 AS cor0
----
1291
165
4550

query I rowsort
SELECT - col0 * - ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT col0 * - tab0.col1 + col0 * - col0 AS col0 FROM tab0
----
-16020
-2640
-4620

query I rowsort
SELECT col1 + + ( col2 ) FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7671
SELECT DISTINCT col1 + ( ( + tab1.col0 ) ) DIV 81 AS col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7671
SELECT DISTINCT col1 + ( ( + tab1.col0 ) ) / 81 AS col1 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - col2 * - ( col0 ) * col0 + - 97 * - tab1.col1 FROM tab1
----
234442
3008
615661

query I rowsort
SELECT DISTINCT - col1 + + tab0.col0 + + 28 AS col2 FROM tab0
----
-34
26

query I rowsort
SELECT DISTINCT ( + 96 ) AS col2 FROM tab0, tab2 cor0
----
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7675
SELECT DISTINCT col0 + + CAST( + col1 AS SIGNED ) + tab1.col1 * col0 AS col1 FROM tab1
----
107
1133
714

skipif mysql # not compatible
query I rowsort label-7675
SELECT DISTINCT col0 + + CAST ( + col1 AS INTEGER ) + tab1.col1 * col0 AS col1 FROM tab1
----
107
1133
714

query I rowsort
SELECT - tab2.col2 + col2 * ( - col1 ) * 71 + + col1 AS col0 FROM tab2
----
-108881
-45887
-59423

query I rowsort
SELECT ALL - 37 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 395d44ccbce08828bc493e93ec3d9207

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 col2 FROM tab1, tab2 cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL tab2.col0 * - tab2.col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT ALL - 46 FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
81 values hashing to ae4d442ff589a18fe7c7777464d5970c

onlyif mysql # use DIV operator for integer division
query I rowsort label-7681
SELECT DISTINCT col2 DIV - 21 FROM tab0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-7681
SELECT DISTINCT col2 / - 21 FROM tab0
----
-1
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7682
SELECT 14 * col2 DIV col2 + col1 + 46 col1 FROM tab0
----
146
151
157

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7682
SELECT 14 * col2 / col2 + col1 + 46 col1 FROM tab0
----
146
151
157

query I rowsort
SELECT ALL - 51 + + col1 FROM tab1 AS cor0
----
-25
-38
-41

query I rowsort
SELECT ALL - + col2 + + 37 * + col0 AS col2 FROM tab1 AS cor0
----
2311
2864
57

query I rowsort
SELECT - col1 + - 2 + - col1 FROM tab2 cor0
----
-120
-36
-64

query I rowsort
SELECT DISTINCT col0 + - col0 + + col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL + + 21 * - 87 AS col1 FROM tab0 AS cor0
----
-1827
-1827
-1827

onlyif mysql # use DIV operator for integer division
query I rowsort label-7688
SELECT - 49 DIV + 66 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-7688
SELECT - 49 / + 66 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 46 * col2 FROM tab2 AS cor0
----
-1196
-1242
-1748

query I rowsort
SELECT DISTINCT + + 87 * col0 AS col0 FROM tab2 AS cor0
----
609
6786
6873

query I rowsort
SELECT DISTINCT - - col1 + + col1 * col2 * - col1 FROM tab0 cor0
----
-243982
-678951
-9312

query I rowsort
SELECT col2 - 83 FROM tab1
----
-26
-29
13

query I rowsort
SELECT + + col1 + + 56 AS col1 FROM tab1 AS cor0
----
66
69
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7694
SELECT DISTINCT CAST( + 18 AS SIGNED ) FROM tab1, tab1 AS cor0
----
18

skipif mysql # not compatible
query I rowsort label-7694
SELECT DISTINCT CAST ( + 18 AS INTEGER ) FROM tab1, tab1 AS cor0
----
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - 23 col2 FROM tab2 cor0
----
-6
36
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7696
SELECT + CAST( + col1 AS SIGNED ) + + col0 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-7696
SELECT + CAST ( + col1 AS INTEGER ) + + col0 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + + col1 col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + col0 * - cor0.col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - ( col1 ) + col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + 75 AS col0 FROM tab1, tab0 AS cor0
----
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7701
SELECT + col2 + col2 DIV ( ( + col2 ) ) col1 FROM tab1 AS cor0
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7701
SELECT + col2 + col2 / ( ( + col2 ) ) col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT - col1 * + cor0.col0 * - col0 - 55 FROM tab0 AS cor0
----
118770
49481
720756

onlyif mysql # use DIV operator for integer division
query I rowsort label-7703
SELECT DISTINCT - - 76 DIV col1 AS col0 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-7703
SELECT DISTINCT - - 76 / col1 AS col0 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + - 45 * - col1 FROM tab2 AS cor0
----
1395
2655
765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7705
SELECT col1 - cor0.col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7705
SELECT col1 - cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * col1 * col2 - + 69 AS col2 FROM tab1 AS cor0
----
-119877
-32559
-75885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 87 col2 FROM tab1
----
100
113
97

query I rowsort
SELECT DISTINCT + ( col1 ) + + tab0.col2 AS col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7709
SELECT DISTINCT + tab1.col2 + col1 DIV - col2 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7709
SELECT DISTINCT + tab1.col2 + col1 / - col2 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT col2 * col1 + 84 * - ( tab0.col2 ) AS col2 FROM tab0
----
13
574
66

query I rowsort
SELECT ALL - - 21 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7712
SELECT cor0.col0 DIV + ( + col0 ) + - col0 * + col2 AS col2 FROM tab2 AS cor0
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-7712
SELECT cor0.col0 / + ( + col0 ) + - col0 * + col2 AS col2 FROM tab2 AS cor0
----
-188
-2027
-3001

query I rowsort
SELECT ALL + col2 * ( + cor0.col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - tab2.col0 * - col0 AS col0 FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-7715
SELECT ALL col2 DIV + col2 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7715
SELECT ALL col2 / + col2 AS col0 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7716
SELECT ALL + col1 DIV 34 FROM tab0 cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-7716
SELECT ALL + col1 / 34 FROM tab0 cor0
----
2
2
2

query I rowsort
SELECT DISTINCT tab1.col1 * - col2 + - col0 FROM tab1
----
-1328
-1407
-634

onlyif mysql # use DIV operator for integer division
query I rowsort label-7718
SELECT col0 + ( col2 ) DIV col0 col0 FROM tab0 AS cor0
----
25
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7718
SELECT col0 + ( col2 ) / col0 col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT - col2 + - 49 + - 10 * - col1 FROM tab0 AS cor0
----
778
779
920

query I rowsort
SELECT - col1 + col0 * cor0.col2 * col2 AS col2 FROM tab2 cor0
----
114059
5072
52669

query I rowsort
SELECT - col2 + + col2 * + col1 + - col1 * 61 AS col1 FROM tab0
----
-2441
-5821
1829

query I rowsort
SELECT ( + 66 ) FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT DISTINCT 71 FROM tab1, tab0 AS cor0
----
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-7724
SELECT + col2 * tab1.col2 + 64 DIV tab1.col1 AS col2 FROM tab1
----
2918
3255
9220

skipif mysql # not compatible
query I rowsort label-7724
SELECT + col2 * tab1.col2 + 64 / tab1.col1 AS col2 FROM tab1
----
2918
3255
9220

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7725
SELECT - col1 * + col1 * + CAST( NULL AS SIGNED ) + col2 + col0 * cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7725
SELECT - col1 * + col1 * + CAST ( NULL AS INTEGER ) + col2 + col0 * cor0.col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7726
SELECT 79 DIV + col1 AS col0 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-7726
SELECT 79 / + col1 AS col0 FROM tab2
----
1
2
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-7727
SELECT DISTINCT tab1.col0 DIV - col1 - 22 * col2 AS col0 FROM tab1
----
-1188
-1260
-2118

skipif mysql # not compatible
query I rowsort label-7727
SELECT DISTINCT tab1.col0 / - col1 - 22 * col2 AS col0 FROM tab1
----
-1188
-1260
-2118

query I rowsort
SELECT DISTINCT col2 + col2 * 47 * col2 AS col1 FROM tab2 AS cor0
----
31798
34290
67906

query I rowsort
SELECT DISTINCT + 47 FROM tab0, tab1 AS cor0
----
47

query I rowsort
SELECT ALL + col2 + - col2 + col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - 62 + col0 AS col0 FROM tab1 AS cor0
----
-59
18
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col0 + + col0 col2 FROM tab0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 * col2 ) col0 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 3 col1 FROM tab2
----
3
3
3

query I rowsort
SELECT DISTINCT - ( - col1 ) * col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - - 92 FROM tab2 AS cor0
----
92
92
92

query I rowsort
SELECT cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col0 ) col1 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT col0 * + tab0.col0 + col1 AS col2 FROM tab0
----
1322
662
8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 47 col1 FROM tab1
----
47
47
47

query I rowsort
SELECT DISTINCT col2 + 62 FROM tab2 AS cor0
----
100
88
89

query I rowsort
SELECT DISTINCT + + col0 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col2 col1 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT col0 + + col0 * + 39 AS col2 FROM tab0
----
1400
3560
960

query I rowsort
SELECT DISTINCT 0 * - col1 + 82 AS col2 FROM tab0
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7747
SELECT + col2 DIV + col2 + col1 * 85 AS col2 FROM tab1
----
1106
2211
851

skipif mysql # not compatible
query I rowsort label-7747
SELECT + col2 / + col2 + col1 * 85 AS col2 FROM tab1
----
1106
2211
851

query I rowsort
SELECT 47 - - col2 FROM tab1
----
101
104
143

query I rowsort
SELECT 91 + - col2 - + 89 FROM tab0
----
-31
-80
1

query I rowsort
SELECT ALL 69 + col2 FROM tab2
----
107
95
96

query I rowsort
SELECT ALL 50 * - tab0.col2 + - col1 FROM tab0
----
-147
-1736
-4191

query I rowsort
SELECT ALL col2 - - col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT col1 + - col0 * - col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + col0 * col1 + 33 AS col2 FROM tab1 AS cor0
----
1073
111
673

query I rowsort
SELECT - col2 * col0 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-3748
-7849
-838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * ( col0 ) + + col1 col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - + col0 + col2 * col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT - - col1 + ( - col0 + + col0 ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + cor0.col1 * 62 + - col1 FROM tab1 AS cor0
----
1586
610
793

query I rowsort
SELECT DISTINCT col1 * col2 + col0 - + col2 FROM tab0 AS cor0
----
131
2829
7469

query I rowsort
SELECT - col2 + 73 * + ( cor0.col0 ) AS col1 FROM tab2 AS cor0
----
484
5668
5729

query I rowsort
SELECT DISTINCT + col2 + col0 + col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT ALL col2 * 4 AS col2 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - col0 * - 72 + col2 AS col0 FROM tab0 AS cor0
----
1761
2521
6490

query I rowsort
SELECT ALL + - cor0.col0 * - 75 AS col2 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT col0 + 25 * + col0 AS col1 FROM tab1 cor0
----
1664
2080
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7769
SELECT - cor0.col2 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7769
SELECT - cor0.col2 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col2 + + col2 * col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL - col1 - col0 * col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - col1 * + tab2.col2 * + tab2.col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT + - col1 - - col0 * col2 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - col1 * col1 + + cor0.col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT col2 * col2 * + col1 + + col1 AS col1 FROM tab0 AS cor0
----
194
611975
93740

query I rowsort
SELECT col2 * col1 + + col1 * - col1 + + col0 FROM tab0 AS cor0
----
-4534
-730
-9277

query I rowsort
SELECT ALL col0 * - tab0.col0 * - col0 FROM tab0
----
13824
42875
704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-7778
SELECT + col0 + col1 DIV col1 AS col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7778
SELECT + col0 + col1 / col1 AS col0 FROM tab0
----
25
36
90

query I rowsort
SELECT + col2 + - col1 * col2 * col0 AS col1 FROM tab2
----
-119626
-50996
-5832

query I rowsort
SELECT col0 * col2 * - col0 AS col2 FROM tab0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-7781
SELECT - col2 DIV col0 + col0 DIV col1 AS col0 FROM tab1
----
-18
5
6

skipif mysql # not compatible
query I rowsort label-7781
SELECT - col2 / col0 + col0 / col1 AS col0 FROM tab1
----
-18
5
6

query I rowsort
SELECT ALL - col2 + + col2 * col1 AS col0 FROM tab0
----
2805
7380
96

query I rowsort
SELECT ALL - - col2 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-7784
SELECT - 77 + col0 DIV - col0 AS col1 FROM tab2 AS cor0
----
-78
-78
-78

skipif mysql # not compatible
query I rowsort label-7784
SELECT - 77 + col0 / - col0 AS col1 FROM tab2 AS cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7785
SELECT DISTINCT - col1 DIV col1 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-7785
SELECT DISTINCT - col1 / col1 FROM tab1 cor0
----
-1

query I rowsort
SELECT - + col1 + + col0 * col1 * col1 FROM tab1 AS cor0
----
13507
2002
6390

query I rowsort
SELECT col0 * col2 * + col0 AS col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT ALL - 90 + col1 AS col2 FROM tab2 AS cor0
----
-31
-59
-73

query I rowsort
SELECT DISTINCT - 89 + - col1 * - col2 AS col1 FROM tab2 AS cor0
----
1445
557
748

query I rowsort
SELECT + + 40 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
1040
400
520

query I rowsort
SELECT DISTINCT 67 * - col1 AS col2 FROM tab0 cor0
----
-5762
-6097
-6499

query I rowsort
SELECT + 86 + - col0 * - col2 FROM tab1
----
248
3734
7766

onlyif mysql # use DIV operator for integer division
query I rowsort label-7793
SELECT DISTINCT + 8 DIV + col0 AS col0 FROM tab1
----
0
2

skipif mysql # not compatible
query I rowsort label-7793
SELECT DISTINCT + 8 / + col0 AS col0 FROM tab1
----
0
2

query I rowsort
SELECT - 8 * col1 AS col1 FROM tab2 cor0
----
-136
-248
-472

query I rowsort
SELECT DISTINCT + 75 * col0 + - col2 AS col2 FROM tab0
----
1767
2624
6593

query I rowsort
SELECT + col1 + cor0.col2 + + col1 * col1 FROM tab2 AS cor0
----
1019
344
3566

query I rowsort
SELECT DISTINCT - cor0.col2 + - col1 AS col0 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT - + col2 + - col2 + + col1 FROM tab0 AS cor0
----
-73
20
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 64 * col2 * col2 + cor0.col1 col2 FROM tab2 cor0
----
-43205
-46625
-92399

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - ( col1 ) + - col0 AS col2 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT col2 * - col1 + + tab1.col1 * - tab1.col1 AS col2 FROM tab1
----
-1417
-2080
-670

query I rowsort
SELECT col0 + col2 + col1 FROM tab2
----
134
163
65

query I rowsort
SELECT - ( + col2 ) + col0 + col1 AS col1 FROM tab2
----
11
111
58

query I rowsort
SELECT 31 FROM tab0, tab1, tab2 cor0
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7806
SELECT - CAST( NULL AS SIGNED ) * 95 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7806
SELECT - CAST ( NULL AS INTEGER ) * 95 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7807
SELECT ALL - 31 DIV col0 AS col1 FROM tab1
----
-10
0
0

skipif mysql # not compatible
query I rowsort label-7807
SELECT ALL - 31 / col0 AS col1 FROM tab1
----
-10
0
0

query I rowsort
SELECT ALL ( + ( col0 ) * ( + 78 ) ) FROM tab1
----
234
4992
6240

query I rowsort
SELECT DISTINCT 16 FROM tab1, tab0 AS cor0
----
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7810
SELECT + + cor0.col1 * + ( col2 ) - CAST( - col2 AS SIGNED ) FROM tab2 cor0
----
1560
684
864

skipif mysql # not compatible
query I rowsort label-7810
SELECT + + cor0.col1 * + ( col2 ) - CAST ( - col2 AS INTEGER ) FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT ALL - - col2 + - ( col0 ) AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT + col2 * + 65 AS col0 FROM tab0
----
2145
5330
65

query I rowsort
SELECT ( + cor0.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7814
SELECT - 43 + - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7814
SELECT - 43 + - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col2 * 33 ) - - col1 * + col1 FROM tab1
----
-1106
-1781
-2999

query I rowsort
SELECT - 27 + + col2 FROM tab0 AS cor0
----
-26
55
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7817
SELECT 1 DIV + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7817
SELECT 1 / + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 + - col1 AS col0 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT + 93 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT - - col2 + 39 * + col2 FROM tab0 AS cor0
----
1320
3280
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-7821
SELECT ALL - col2 * col0 - ( - col2 ) DIV ( + col2 ) FROM tab0 AS cor0
----
-34
-7297
-791

skipif mysql # not compatible
query I rowsort label-7821
SELECT ALL - col2 * col0 - ( - col2 ) / ( + col2 ) FROM tab0 AS cor0
----
-34
-7297
-791

query I rowsort
SELECT cor0.col2 * 24 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT col1 + 73 FROM tab1 AS cor0
----
83
86
99

query I rowsort
SELECT - + col2 * cor0.col0 * col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT + col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col2 * + 19 + + col0 * cor0.col2 + - col0 * col0 FROM tab1 AS cor0
----
-1531
-544
-873

query I rowsort
SELECT - - col1 * - 54 - + col2 FROM tab0 AS cor0
----
-4677
-4996
-5239

query I rowsort
SELECT + col2 - - col1 * col0 * 71 AS col2 FROM tab2 AS cor0
----
15434
326768
95391

query I rowsort
SELECT DISTINCT - col1 + ( col2 ) FROM tab2
----
-33
-4
21

query I rowsort
SELECT + 33 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT ALL + col0 + + ( + col2 ) FROM tab0
----
171
36
57

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 cor2, tab1 AS cor3
----
3645 values hashing to 974a92f740f5f08d18564d29c05f7692

query I rowsort
SELECT 38 * cor0.col0 AS col2 FROM tab2 AS cor0
----
266
2964
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( - col1 ) + + col1 - col1 col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - 41 + + cor0.col1 AS col0 FROM tab2 cor0
----
-10
-24
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7836
SELECT ALL - CAST( + col2 AS SIGNED ) * col2 + - col0 FROM tab0 cor0
----
-1113
-36
-6813

skipif mysql # not compatible
query I rowsort label-7836
SELECT ALL - CAST ( + col2 AS INTEGER ) * col2 + - col0 FROM tab0 cor0
----
-1113
-36
-6813

query I rowsort
SELECT ALL tab0.col2 * 52 FROM tab0
----
1716
4264
52

query I rowsort
SELECT + + col2 * + col1 + - col0 AS col0 FROM tab0 AS cor0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 52 col0 FROM tab2 AS cor0
----
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7840
SELECT ALL ( col2 ) DIV col1 AS col0 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7840
SELECT ALL ( col2 ) / col1 AS col0 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT + ( col1 ) + ( 69 ) AS col2 FROM tab1 AS cor0
----
79
82
95

query I rowsort
SELECT + 0 + - col0 * ( col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col0 * col2 - - 10 AS col2 FROM tab1 cor0
----
-152
-3638
-7670

query I rowsort
SELECT DISTINCT + col0 + + cor0.col1 FROM tab0 cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * - col2 col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col2 + col0 * col0 * + col1 AS col1 FROM tab2 AS cor0
----
106135
1546
358982

query I rowsort
SELECT col0 * + 30 * + cor0.col1 + - col1 * 43 + col2 FROM tab1 AS cor0
----
1276
18827
30737

query I rowsort
SELECT ALL - col0 * 90 FROM tab0 cor0
----
-2160
-3150
-8010

query I rowsort
SELECT col1 + ( col0 ) * - col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - col1 * - col2 + - 41 + col2 AS col1 FROM tab0 AS cor0
----
2830
57
7503

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * + 73 + + col0 * - col0 + 70 col0 FROM tab1 AS cor0
----
135
4003
678

query I rowsort
SELECT DISTINCT - col2 + ( ( col1 ) * cor0.col2 ) AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT col0 + 7 FROM tab1 AS cor0
----
10
71
87

query I rowsort
SELECT DISTINCT - + col0 * - 19 FROM tab1 AS cor0
----
1216
1520
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7855
SELECT ALL - + col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7855
SELECT ALL - + col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7856
SELECT DISTINCT + - cor0.col2 + - CAST( + col0 AS SIGNED ) FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-7856
SELECT DISTINCT + - cor0.col2 + - CAST ( + col0 AS INTEGER ) FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7857
SELECT col1 + + col1 DIV - CAST( col2 AS SIGNED ) - col1 * + 33 FROM tab1
----
-320
-416
-832

skipif mysql # not compatible
query I rowsort label-7857
SELECT col1 + + col1 / - CAST ( col2 AS INTEGER ) - col1 * + 33 FROM tab1
----
-320
-416
-832

query I rowsort
SELECT DISTINCT + tab1.col2 + + tab1.col1 AS col1 FROM tab1, tab0, tab2 AS cor0
----
109
67
80

query I rowsort
SELECT 16 * - col0 * + ( col1 ) FROM tab0
----
-129584
-33024
-54320

query I rowsort
SELECT + 19 - - col2 FROM tab2
----
45
46
57

query I rowsort
SELECT DISTINCT col0 + - col0 * 93 AS col0 FROM tab2
----
-644
-7176
-7268

query I rowsort
SELECT ALL + + col1 + - 29 AS col1 FROM tab0 AS cor0
----
57
62
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-7863
SELECT ALL - col2 DIV + col0 - + 76 FROM tab2 AS cor0
----
-76
-76
-79

skipif mysql # not compatible
query I rowsort label-7863
SELECT ALL - col2 / + col0 - + 76 FROM tab2 AS cor0
----
-76
-76
-79

query I rowsort
SELECT DISTINCT + - col2 + 73 - - col2 AS col1 FROM tab1 AS cor0
----
73

query I rowsort
SELECT + col0 + - 47 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT col0 * 57 * + col1 FROM tab1
----
36480
4446
59280

onlyif mysql # use DIV operator for integer division
query I rowsort label-7867
SELECT 11 DIV 97 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7867
SELECT 11 / 97 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 + - 45 AS col0 FROM tab1 AS cor0
----
-145
-214
-721

query I rowsort
SELECT - col2 * col1 + + col2 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + col0 + col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + + col0 * - col0 * col0 AS col1 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT ALL - 16 * 84 AS col2 FROM tab0
----
-1344
-1344
-1344

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + + cor0.col0 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd2e899bd918e152608d478dba2a0416

query I rowsort
SELECT ( + 30 ) AS col0 FROM tab0, tab2 cor0 CROSS JOIN tab1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT ( + tab0.col1 * - col1 ) + 58 AS col0 FROM tab0
----
-7338
-8223
-9351

query I rowsort
SELECT ALL + col0 + + col2 * col1 + + col1 FROM tab2
----
1671
742
875

query I rowsort
SELECT 61 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT DISTINCT - col0 * col2 + 65 + col1 * col2 AS col0 FROM tab0
----
127
2111
229

query I rowsort
SELECT + + 11 + + col2 * - cor0.col0 * + 48 + col1 * 30 AS col0 FROM tab0 AS cor0
----
-347563
-35425
1241

query I rowsort
SELECT - col2 * col1 - col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT + col2 * col2 + ( 26 ) + - col0 FROM tab2 cor0
----
1391
624
748

query I rowsort
SELECT DISTINCT - - col2 + - col2 * - 31 FROM tab0 cor0
----
1056
2624
32

query I rowsort
SELECT DISTINCT + 46 * col0 FROM tab1 AS cor0
----
138
2944
3680

query I rowsort
SELECT DISTINCT - tab2.col2 * col1 + 6 AS col2 FROM tab2
----
-1528
-640
-831

query I rowsort
SELECT DISTINCT + 17 * - col0 + - col2 AS col0 FROM tab0
----
-1595
-441
-596

query I rowsort
SELECT ALL - ( + 32 ) FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

query I rowsort
SELECT DISTINCT + col0 + + col0 * + col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + - 31 * + col0 + ( + col2 ) FROM tab2 AS cor0
----
-190
-2392
-2411

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7889
SELECT DISTINCT col1 * col1 + - CAST( col1 AS SIGNED ) AS col2 FROM tab2 cor0
----
272
3422
930

skipif mysql # not compatible
query I rowsort label-7889
SELECT DISTINCT col1 * col1 + - CAST ( col1 AS INTEGER ) AS col2 FROM tab2 cor0
----
272
3422
930

query I rowsort
SELECT + col1 - + col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - + cor0.col1 * - col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + col1 + - col2 * + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL 58 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT - col2 * col0 + col2 + - col2 * + col2 FROM tab0 AS cor0
----
-13940
-1848
-35

query I rowsort
SELECT + - 93 FROM tab1, tab0 cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT col1 + + col1 * cor0.col1 AS col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT col0 * ( 1 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col1 + + 46 AS col0 FROM tab1 cor0
----
56
59
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * + col0 col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT cor0.col0 * 46 + + 97 - col2 FROM tab0 AS cor0
----
1168
1706
4109

query I rowsort
SELECT ALL - + 21 + 96 AS col2 FROM tab2 cor0
----
75
75
75

query I rowsort
SELECT DISTINCT + cor0.col2 + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * - col1 FROM tab1 AS cor0
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7905
SELECT + col1 DIV + cor0.col1 AS col2 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7905
SELECT + col1 / + cor0.col1 AS col2 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7906
SELECT + col1 DIV cor0.col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-7906
SELECT + col1 / cor0.col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 + + col1 * CAST ( + 8 AS REAL ) FROM tab2 cor0
----
153
279
531

query I rowsort
SELECT - tab0.col0 * ( col0 ) + col2 * - col0 FROM tab0
----
-1260
-1368
-15219

query I rowsort
SELECT DISTINCT + col2 + col0 - col2 * - col2 FROM tab0 AS cor0
----
1146
37
6895

query I rowsort
SELECT col0 * - col0 * col1 - col1 FROM tab2 AS cor0
----
-106114
-1550
-359015

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 * col1 * ( - cor0.col0 ) col2 FROM tab1 AS cor0
----
180
40903
83104

onlyif mysql # use DIV operator for integer division
query I rowsort label-7912
SELECT ALL - cor0.col1 DIV - 48 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c08e3956186780709ba0eab5eede7b9c

skipif mysql # not compatible
query I rowsort label-7912
SELECT ALL - cor0.col1 / - 48 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c08e3956186780709ba0eab5eede7b9c

query I rowsort
SELECT - - 96 * col2 * col0 FROM tab2 AS cor0
----
18144
194688
288192

query I rowsort
SELECT ALL + + 64 + col2 FROM tab1 AS cor0
----
118
121
160

query I rowsort
SELECT - col2 - 75 * tab1.col2 FROM tab1
----
-4104
-4332
-7296

query I rowsort
SELECT DISTINCT 34 - 6 * - col0 AS col2 FROM tab2
----
502
508
76

query I rowsort
SELECT DISTINCT tab0.col0 - - tab0.col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT - + col0 + - 97 * col1 FROM tab1 AS cor0
----
-1034
-1341
-2525

query I rowsort
SELECT DISTINCT - cor1.col0 + 42 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
-47
18
7

query I rowsort
SELECT - 0 + 1 + + col2 AS col1 FROM tab0
----
2
34
83

query I rowsort
SELECT ALL - 71 * col1 - + col2 FROM tab1
----
-1019
-1900
-767

query I rowsort
SELECT col2 * + col0 * col0 + + 54 + col2 AS col0 FROM tab0
----
1280
19095
649658

query I rowsort
SELECT - ( col2 ) * - col1 * + tab1.col1 + + tab1.col2 FROM tab1
----
16320
36558
5757

query I rowsort
SELECT - + cor0.col2 + col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7925
SELECT cor0.col0 + - col0 DIV - 38 FROM tab0 cor0
----
24
35
91

skipif mysql # not compatible
query I rowsort label-7925
SELECT cor0.col0 + - col0 / - 38 FROM tab0 cor0
----
24
35
91

query I rowsort
SELECT 46 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT DISTINCT - col1 * tab2.col0 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + - cor0.col2 + ( col1 ) FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7929
SELECT - cor0.col0 DIV - 79 AS col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7929
SELECT - cor0.col0 / - 79 AS col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + col0 * - col0 * - 27 AS col2 FROM tab0 AS cor0
----
15552
213867
33075

query I rowsort
SELECT + col2 * - 40 AS col1 FROM tab0 AS cor0
----
-1320
-3280
-40

query I rowsort
SELECT 87 AS col2 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT 36 * - col1 + + col0 FROM tab2 cor0
----
-1109
-2046
-533

onlyif mysql # use DIV operator for integer division
query I rowsort label-7934
SELECT ALL - + col0 DIV - 71 AS col1 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7934
SELECT ALL - + col0 / - 71 AS col1 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT + - ( - col0 ) * - cor0.col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col2 * col0 + - col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT 3 + - col0 AS col0 FROM tab2 AS cor0
----
-4
-75
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 4 col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT DISTINCT + col0 + ( cor0.col2 ) * - col2 AS col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL 49 AS col0 FROM tab2 AS cor0
----
49
49
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-7941
SELECT + + col2 DIV 20 col2 FROM tab1 AS cor0
----
2
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7941
SELECT + + col2 / 20 col2 FROM tab1 AS cor0
----
2
2
4

query I rowsort
SELECT - cor0.col2 + col1 * - col1 FROM tab2 AS cor0
----
-327
-3507
-988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7943
SELECT - col0 + cor0.col1 * - CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
-1612
-725
-844

skipif mysql # not compatible
query I rowsort label-7943
SELECT - col0 + cor0.col1 * - CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT + cor0.col0 * + col1 * + col0 + - cor0.col2 AS col0 FROM tab2 cor0
----
106059
1492
358930

query I rowsort
SELECT 6 * col2 AS col2 FROM tab1
----
324
342
576

query I rowsort
SELECT ALL - + col2 * cor0.col2 - col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-14186
-3927
-98

query I rowsort
SELECT ALL - + 54 * - col2 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT DISTINCT + + ( col2 ) + + col2 + col0 FROM tab2 cor0
----
130
155
61

query I rowsort
SELECT DISTINCT 80 AS col0 FROM tab1 AS cor0
----
80

query I rowsort
SELECT + + col1 * - col2 + + ( + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT - col0 * cor0.col0 + - 7 FROM tab0 AS cor0
----
-1232
-583
-7928

query I rowsort
SELECT - 23 + + col2 AS col2 FROM tab2 AS cor0
----
15
3
4

query I rowsort
SELECT ALL + col0 + + 41 * ( + col1 + + ( col1 ) ) FROM tab2 cor0
----
1473
2549
4916

query I rowsort
SELECT DISTINCT col1 - 50 * 94 AS col0 FROM tab0 AS cor0
----
-4603
-4609
-4614

query I rowsort
SELECT ALL + col1 + 40 AS col0 FROM tab2 cor0
----
57
71
99

skipif mysql # not compatible
query I rowsort
SELECT - col1 * CAST ( col1 AS REAL ) AS col1 FROM tab1 AS cor0
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 - 11 col0 FROM tab0 AS cor0
----
-10
22
71

query I rowsort
SELECT ALL - cor0.col2 + col2 * - col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT + - 30 * cor0.col2 FROM tab2 AS cor0
----
-1140
-780
-810

query I rowsort
SELECT - - cor0.col1 * - col2 + col0 * + col2 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT DISTINCT - + col2 + + col0 * col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT tab2.col0 + 98 FROM tab2
----
105
176
177

query I rowsort
SELECT + 73 + col2 AS col1 FROM tab1 AS cor0
----
127
130
169

query I rowsort
SELECT DISTINCT - 90 + col2 * - col0 FROM tab0 AS cor0
----
-125
-7388
-882

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7965
SELECT ALL CAST( NULL AS SIGNED ) + + 91 - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7965
SELECT ALL CAST ( NULL AS INTEGER ) + + 91 - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + col2 ) * col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-7967
SELECT DISTINCT + + col2 DIV col0 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-7967
SELECT DISTINCT + + col2 / col0 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col0 ) * col1 + col2 * col1 col0 FROM tab1 AS cor0
----
-70
1326
208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - 41 ) col2 FROM tab0 cor0
----
41
41
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7970
SELECT + + CAST( col1 AS SIGNED ) AS col1 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7970
SELECT + + CAST ( col1 AS INTEGER ) AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - 92 - col1 FROM tab0 cor0
----
-178
-183
-189

query I rowsort
SELECT DISTINCT - ( + col0 ) + cor0.col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - + col2 * - col2 - - col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL - + col0 + + col1 - col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + - col1 + - 19 * - col0 * - 40 FROM tab1 AS cor0
----
-2306
-48650
-60813

onlyif mysql # use DIV operator for integer division
query I rowsort label-7976
SELECT ALL - col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-7976
SELECT ALL - col0 / + col2 AS col0 FROM tab0 AS cor0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7977
SELECT DISTINCT + col1 + + cor0.col1 DIV - col2 FROM tab0 AS cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-7977
SELECT DISTINCT + col1 + + cor0.col1 / - col2 FROM tab0 AS cor0
----
0
84
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + cor0.col2 ) * - col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + col2 + + col1 + + col2 FROM tab1 AS cor0
----
124
134
205

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col0 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + col0 + col2 + + col1 AS col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT - 35 * cor0.col2 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 0be47d113262ddff34eb5a85968d4ced

query I rowsort
SELECT col1 + 20 AS col2 FROM tab1
----
30
33
46

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab2, tab1 cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL - 11 + col2 FROM tab1
----
43
46
85

query I rowsort
SELECT DISTINCT - col1 + - col2 * - 43 FROM tab0 cor0
----
-54
1333
3435

query I rowsort
SELECT cor0.col0 + + col1 * cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL cor0.col0 * 46 * col0 FROM tab2 AS cor0
----
2254
279864
287086

query I rowsort
SELECT DISTINCT + - 19 AS col1 FROM tab1 AS cor0
----
-19

query I rowsort
SELECT ALL + - 79 AS col0 FROM tab1 AS cor0
----
-79
-79
-79

query I rowsort
SELECT - cor0.col1 + col1 * + col1 FROM tab0 AS cor0
----
7310
8190
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7992
SELECT + col2 * + CAST( NULL AS DECIMAL ) + - col1 - + col2 col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7992
SELECT + col2 * + CAST ( NULL AS REAL ) + - col1 - + col2 col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7993
SELECT DISTINCT - col2 + + col2 * + col1 - + col2 DIV 68 FROM tab2
----
1508
608
810

skipif mysql # not compatible
query I rowsort label-7993
SELECT DISTINCT - col2 + + col2 * + col1 - + col2 / 68 FROM tab2
----
1508
608
810

query I rowsort
SELECT DISTINCT + tab2.col0 * - 90 FROM tab2, tab1 AS cor0
----
-630
-7020
-7110

onlyif mysql # use DIV operator for integer division
query I rowsort label-7995
SELECT - col1 * col1 - col0 DIV + tab0.col2 FROM tab0
----
-7396
-8282
-9444

skipif mysql # not compatible
query I rowsort label-7995
SELECT - col1 * col1 - col0 / + tab0.col2 FROM tab0
----
-7396
-8282
-9444

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7996
SELECT col0 * + CAST( + col1 AS SIGNED ) + col2 FROM tab1
----
1136
132
697

skipif mysql # not compatible
query I rowsort label-7996
SELECT col0 * + CAST ( + col1 AS INTEGER ) + col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT - 42 + col2 FROM tab0 AS cor0
----
-41
-9
40

query I rowsort
SELECT ALL + cor1.col2 * + cor0.col2 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 994244f565b077d9bfe0a9efd8b9bf4b

query I rowsort
SELECT cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2, tab1 AS cor3
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT + 95 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 60 * - 91 col1 FROM tab2
----
-5460

query I rowsort
SELECT + 45 + - col0 + col1 AS col1 FROM tab0
----
107
107
47

query I rowsort
SELECT 69 * ( - col2 ) FROM tab2
----
-1794
-1863
-2622

query I rowsort
SELECT + 19 FROM tab2 cor0
----
19
19
19

query I rowsort
SELECT ALL + 38 AS col0 FROM tab1
----
38
38
38

query I rowsort
SELECT ALL + 48 + col2 * col2 FROM tab1 AS cor0
----
2964
3297
9264

query I rowsort
SELECT 59 AS col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT ALL + 11 * col0 AS col2 FROM tab1 AS cor0
----
33
704
880

query I rowsort
SELECT 55 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT ALL + col2 * col2 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT DISTINCT col2 + 6 FROM tab2 AS cor0
----
32
33
44

query I rowsort
SELECT DISTINCT + - col2 * + 6 AS col0 FROM tab0 AS cor0
----
-198
-492
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8013
SELECT DISTINCT - col2 DIV - cor0.col1 AS col1 FROM tab2 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-8013
SELECT DISTINCT - col2 / - cor0.col1 AS col1 FROM tab2 AS cor0
----
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-8014
SELECT + col2 DIV - 67 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8014
SELECT + col2 / - 67 AS col2 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8015
SELECT + - col0 DIV 9 FROM tab2 AS cor0
----
-8
-8
0

skipif mysql # not compatible
query I rowsort label-8015
SELECT + - col0 / 9 FROM tab2 AS cor0
----
-8
-8
0

query I rowsort
SELECT DISTINCT - col2 * 17 + + col0 * - col2 AS col2 FROM tab0 AS cor0
----
-1353
-52
-8692

query I rowsort
SELECT col2 * + 56 AS col0 FROM tab2 cor0
----
1456
1512
2128

onlyif mysql # use DIV operator for integer division
query I rowsort label-8018
SELECT + cor0.col0 DIV col1 AS col2 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-8018
SELECT + cor0.col0 / col1 AS col2 FROM tab1 AS cor0
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 57 col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT DISTINCT - - 68 AS col2 FROM tab2 cor0
----
68

query I rowsort
SELECT - cor0.col2 * + 6 FROM tab0 AS cor0
----
-198
-492
-6

query I rowsort
SELECT DISTINCT - col0 * + ( 72 ) FROM tab1 AS cor0
----
-216
-4608
-5760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8023
SELECT col1 + - CAST( - 0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-8023
SELECT col1 + - CAST ( - 0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + + col1 * ( 66 ) FROM tab2 AS cor0
----
1122
2046
3894

query I rowsort
SELECT - col1 + + cor0.col1 * + 3 AS col0 FROM tab1 AS cor0
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col1 - ( - cor0.col0 ) col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 - + 64 * col0 AS col1 FROM tab2 cor0
----
-637
-7020
-8058

query I rowsort
SELECT ALL + - cor0.col1 * ( - ( col1 ) ) + + col0 AS col2 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL + ( + col1 ) AS col0 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8030
SELECT + CAST( - 63 AS SIGNED ) DIV + col2 + - ( col0 ) FROM tab0 AS cor0
----
-25
-89
-98

skipif mysql # not compatible
query I rowsort label-8030
SELECT + CAST ( - 63 AS INTEGER ) / + col2 + - ( col0 ) FROM tab0 AS cor0
----
-25
-89
-98

query I rowsort
SELECT - col2 + ( col0 ) * - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8032
SELECT - + CAST( NULL AS DECIMAL ) + - cor0.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-8032
SELECT - + CAST ( NULL AS REAL ) + - cor0.col1 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8033
SELECT - 93 DIV col0 FROM tab1 AS cor0
----
-1
-1
-31

skipif mysql # not compatible
query I rowsort label-8033
SELECT - 93 / col0 FROM tab1 AS cor0
----
-1
-1
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8034
SELECT DISTINCT CAST( NULL AS SIGNED ) * tab1.col0 AS col1 FROM tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8034
SELECT DISTINCT CAST ( NULL AS INTEGER ) * tab1.col0 AS col1 FROM tab1, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( - col0 ) * - col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT 23 + 10 FROM tab0 AS cor0
----
33
33
33

query I rowsort
SELECT + - col0 * - 92 FROM tab0 AS cor0
----
2208
3220
8188

query I rowsort
SELECT - col1 * - col1 + cor0.col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT - col2 * 41 FROM tab1
----
-2214
-2337
-3936

query I rowsort
SELECT + - col1 * + col1 * col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL - + cor0.col0 AS col2 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT - ( + tab0.col2 ) * + col0 AS col2 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8043
SELECT CAST( 12 + col0 AS SIGNED ) FROM tab2
----
19
90
91

skipif mysql # not compatible
query I rowsort label-8043
SELECT CAST ( 12 + col0 AS INTEGER ) FROM tab2
----
19
90
91

query I rowsort
SELECT - 60 + - col1 * col0 FROM tab2 AS cor0
----
-1403
-277
-4662

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + col1 * - cor0.col2 * CAST ( col2 AS REAL ) + col0 AS col1 FROM tab2 cor0
----
-22592
-24469
-39806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8046
SELECT DISTINCT - col1 * + col1 + + CAST( 24 AS SIGNED ) FROM tab2 AS cor0
----
-265
-3457
-937

skipif mysql # not compatible
query I rowsort label-8046
SELECT DISTINCT - col1 * + col1 + + CAST ( 24 AS INTEGER ) FROM tab2 AS cor0
----
-265
-3457
-937

query I rowsort
SELECT DISTINCT ( - col0 ) + + ( + 49 + col1 ) AS col0 FROM tab1 AS cor0
----
-18
-5
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - tab0.col1 * + col0 col0 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL ( tab1.col0 ) + - col0 * 24 AS col1 FROM tab1
----
-1472
-1840
-69

query I rowsort
SELECT ALL + 42 + ( col0 ) FROM tab2
----
120
121
49

query I rowsort
SELECT + ( + tab0.col0 ) AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT + - ( + cor0.col1 ) * col2 + + ( col0 ) FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + 45 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1395
2655
765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 84 + + col2 * col1 col0 FROM tab2 AS cor0
----
1618
730
921

query I rowsort
SELECT ALL + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col1 - 84 col2 FROM tab0 AS cor0
----
-7480
-8365
-9493

query I rowsort
SELECT - - col2 + + ( - col2 ) AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col1 + ( col2 ) FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8059
SELECT DISTINCT - - cor0.col0 DIV - col0 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8059
SELECT DISTINCT - - cor0.col0 / - col0 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT ALL - - 13 * + ( col0 ) + 68 FROM tab2 AS cor0
----
1082
1095
159

onlyif mysql # use DIV operator for integer division
query I rowsort label-8061
SELECT - col2 DIV ( + col0 ) FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8061
SELECT - col2 / ( + col0 ) FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 + col1 col1 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT - 37 * col2 FROM tab0
----
-1221
-3034
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-8064
SELECT col2 DIV 45 + - col2 FROM tab0 AS cor0
----
-1
-33
-81

skipif mysql # not compatible
query I rowsort label-8064
SELECT col2 / 45 + - col2 FROM tab0 AS cor0
----
-1
-33
-81

query I rowsort
SELECT col0 * col1 - - col2 * col2 AS col0 FROM tab0 AS cor0
----
14823
3153
3396

query I rowsort
SELECT DISTINCT - col1 + + 54 AS col1 FROM tab1 AS cor0
----
28
41
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + ( 81 ) col0 FROM tab2 AS cor0
----
22
50
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8068
SELECT ALL - col2 * CAST( NULL AS SIGNED ) + tab2.col1 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8068
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) + tab2.col1 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + - 63 + + col0 AS col2 FROM tab2
----
-29
41
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - 38 col0 FROM tab2 AS cor0
----
-1026
-1444
-988

query I rowsort
SELECT - col2 + 54 FROM tab1 AS cor0
----
-3
-42
0

query I rowsort
SELECT ALL + col2 * ( 74 + + col0 ) FROM tab0 AS cor0
----
109
13366
3234

query I rowsort
SELECT + col0 * - 78 * 35 FROM tab1 cor0
----
-174720
-218400
-8190

query I rowsort
SELECT ALL + col2 * 57 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT + col0 - - 38 AS col0 FROM tab0 AS cor0
----
127
62
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8076
SELECT CAST( col0 AS SIGNED ) + col2 AS col0 FROM tab2
----
104
117
34

skipif mysql # not compatible
query I rowsort label-8076
SELECT CAST ( col0 AS INTEGER ) + col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT - 32 * col2 * tab0.col2 FROM tab0
----
-215168
-32
-34848

query I rowsort
SELECT col0 * col1 + - col0 * col2 AS col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT ALL ( 92 ) FROM tab1 AS cor0
----
92
92
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8080
SELECT + - CAST( NULL AS SIGNED ) * 8 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8080
SELECT + - CAST ( NULL AS INTEGER ) * 8 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 31 + col2 AS col2 FROM tab2 AS cor0
----
57
58
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8082
SELECT DISTINCT + CAST( col0 AS SIGNED ) * col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-8082
SELECT DISTINCT + CAST ( col0 AS INTEGER ) * col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + 64 * 36 AS col1 FROM tab2 AS cor0
----
2304
2304
2304

query I rowsort
SELECT DISTINCT - ( + col2 ) + + col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + col2 * 33 FROM tab2 AS cor0
----
1254
858
891

query I rowsort
SELECT - + col1 + - col0 + - col2 FROM tab1 AS cor0
----
-131
-189
-83

query I rowsort
SELECT DISTINCT + - ( 51 ) FROM tab0 AS cor0
----
-51

query I rowsort
SELECT DISTINCT - 68 + col2 AS col1 FROM tab0 AS cor0
----
-35
-67
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-8089
SELECT DISTINCT - - col0 * - 10 + col2 DIV + col1 + col1 FROM tab2 AS cor0
----
-39
-721
-771

skipif mysql # not compatible
query I rowsort label-8089
SELECT DISTINCT - - col0 * - 10 + col2 / + col1 + col1 FROM tab2 AS cor0
----
-39
-721
-771

query I rowsort
SELECT ALL 71 + 12 FROM tab1 cor0
----
83
83
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8091
SELECT DISTINCT + col1 DIV col0 + + col2 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-8091
SELECT DISTINCT + col1 / col0 + + col2 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT - cor0.col0 + + cor0.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3b143560120db39ddcee311b43b28291

query I rowsort
SELECT ALL + - cor0.col2 + + col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 82 AS col2 FROM tab1 cor0
----
82

query I rowsort
SELECT col1 * + ( - col1 ) * + 67 + 83 * col0 AS col0 FROM tab0
----
-493540
-547440
-627498

onlyif mysql # use DIV operator for integer division
query I rowsort label-8096
SELECT + col0 DIV + col0 col1 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8096
SELECT + col0 / + col0 col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col0 * col2 * - 17 AS col0 FROM tab2 AS cor0
----
-3213
-34476
-51034

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 90 * cor0.col1 - cor0.col1 AS col0 FROM tab2 AS cor0
----
1513
2759
5251

query I rowsort
SELECT ALL 86 AS col2 FROM tab0 AS cor0
----
86
86
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-8101
SELECT + ( col0 ) + + cor0.col1 DIV col2 AS col2 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-8101
SELECT + ( col0 ) + + cor0.col1 / col2 AS col2 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT + 44 + col0 FROM tab2 AS cor0
----
122
123
51

query I rowsort
SELECT - col1 * + col2 + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + 81 * cor0.col1 + col1 FROM tab1 cor0
----
1066
2132
820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * cor0.col0 + col2 col0 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT - 64 - col2 FROM tab0 AS cor0
----
-146
-65
-97

query I rowsort
SELECT + - col2 * - 38 * + col1 FROM tab2 AS cor0
----
24548
31806
58292

query I rowsort
SELECT DISTINCT 58 AS col2 FROM tab1 cor0
----
58

query I rowsort
SELECT + + ( - 2 ) FROM tab1 AS cor0
----
-2
-2
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8110
SELECT ALL + col2 * CAST( NULL AS SIGNED ) + - col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8110
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) + - col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8111
SELECT ALL CAST( NULL AS SIGNED ) * col0 col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8111
SELECT ALL CAST ( NULL AS INTEGER ) * col0 col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + ( + col1 ) ) col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col1 * - col1 * col2 AS col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL - 1 * 86 * col0 FROM tab1
----
-258
-5504
-6880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * + ( - cor0.col1 * - col1 ) + - col0 * col2 - - cor0.col1 col2 FROM tab2 AS cor0
----
25789
7997
88537

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8116
SELECT - + CAST( - ( - col1 ) AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8116
SELECT - + CAST ( - ( - col1 ) AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + 48 * + 75 FROM tab1 AS cor0
----
3600
3600
3600

query I rowsort
SELECT ALL - ( + 55 * col0 ) AS col2 FROM tab2
----
-385
-4290
-4345

query I rowsort
SELECT DISTINCT + ( 19 + + col1 ) FROM tab0
----
105
110
116

query I rowsort
SELECT - 94 * col0 AS col0 FROM tab1
----
-282
-6016
-7520

query I rowsort
SELECT + 75 * - 27 * col2 FROM tab0
----
-166050
-2025
-66825

query I rowsort
SELECT cor0.col2 * - 31 FROM tab0 AS cor0
----
-1023
-2542
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8123
SELECT + col0 + CAST( col1 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
1422
224
4680

skipif mysql # not compatible
query I rowsort label-8123
SELECT + col0 + CAST ( col1 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8124
SELECT - col1 DIV - 73 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8124
SELECT - col1 / - 73 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - tab0.col0 * 82 AS col0 FROM tab0
----
-1968
-2870
-7298

query I rowsort
SELECT cor0.col0 * cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 4829ede06f586935ff95a5b0dfdb9199

query I rowsort
SELECT 68 * col2 FROM tab0 AS cor0
----
2244
5576
68

query I rowsort
SELECT ALL - col2 * + 74 AS col1 FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
-17
-31
-59

query I rowsort
SELECT - + ( + col2 ) * + col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + + col1 * 76 AS col0 FROM tab0 AS cor0
----
6536
6916
7372

query I rowsort
SELECT ( + col0 ) + ( col0 ) + col2 FROM tab2
----
182
196
41

query I rowsort
SELECT - + col1 * col0 * + ( col2 ) - cor0.col1 AS col0 FROM tab2 AS cor0
----
-119711
-51051
-5890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 97 col0 FROM tab0 AS cor0
----
0
11
6

query I rowsort
SELECT col1 + ( 7 * - col0 ) FROM tab2 AS cor0
----
-18
-487
-536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col2 * col2 col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL col0 * - col0 + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + col0 * + col2 + col1 + col1 AS col0 FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT ALL - col1 + col0 * col2 AS col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - cor0.col0 * - cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT col1 * - 60 FROM tab2 AS cor0
----
-1020
-1860
-3540

query I rowsort
SELECT col1 * col2 + 36 * col1 FROM tab2 AS cor0
----
1258
1953
3658

query I rowsort
SELECT - - cor0.col0 * col0 + col2 AS col1 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - col1 + - 3 FROM tab2 AS cor0
----
-20
-34
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 0 col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8147
SELECT - col1 + 97 DIV + col0 AS col1 FROM tab0 AS cor0
----
-82
-90
-95

skipif mysql # not compatible
query I rowsort label-8147
SELECT - col1 + 97 / + col0 AS col1 FROM tab0 AS cor0
----
-82
-90
-95

query I rowsort
SELECT + col1 + col2 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - cor0.col0 * + col0 - cor0.col2 col0 FROM tab2 AS cor0
----
-106135
-1546
-358982

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 59 * 73 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d3c3c50762e2698a774e1d4f7a3926b9

query I rowsort
SELECT ALL - + col1 + col0 * col0 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT - - cor0.col2 - - ( 93 ) * - col2 FROM tab2 AS cor0
----
-2392
-2484
-3496

onlyif mysql # use DIV operator for integer division
query I rowsort label-8153
SELECT ALL - col2 DIV + 19 AS col1 FROM tab2 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-8153
SELECT ALL - col2 / + 19 AS col1 FROM tab2 AS cor0
----
-1
-1
-2

query I rowsort
SELECT DISTINCT + col1 - ( col1 ) * - cor0.col1 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT - ( col1 ) + - col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-8156
SELECT DISTINCT - 70 DIV - 53 + - col2 + - col0 * col2 FROM tab2 AS cor0
----
-2053
-215
-3039

skipif mysql # not compatible
query I rowsort label-8156
SELECT DISTINCT - 70 / - 53 + - col2 + - col0 * col2 FROM tab2 AS cor0
----
-2053
-215
-3039

query I rowsort
SELECT col0 - - 43 AS col2 FROM tab2
----
121
122
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col2 * tab0.col0 + col2 * col1 col0 FROM tab0
----
-3298
-65274
-656656

query I rowsort
SELECT 7 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - ( + col0 ) col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - + col1 + - cor0.col1 + col2 FROM tab2 cor0
----
-35
-92
4

query I rowsort
SELECT + + col0 * col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8163
SELECT ALL - CAST( NULL AS SIGNED ) * + cor0.col1 + col1 * ( + 46 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8163
SELECT ALL - CAST ( NULL AS INTEGER ) * + cor0.col1 + col1 * ( + 46 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8164
SELECT DISTINCT + 46 * col0 - col1 * + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8164
SELECT DISTINCT + 46 * col0 - col1 * + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * - tab2.col2 + 39 * col2 FROM tab2
----
-520
216
836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col0 + - tab2.col1 col0 FROM tab2
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - ( col0 ) * tab2.col2 col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL + col2 + 67 * col1 FROM tab1
----
1796
727
967

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - tab2.col0 * col2 * - col2 col1 FROM tab2
----
114059
5072
52669

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 66 * 0 - - col1 col1 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT tab1.col2 * + col2 + col2 AS col0 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT + col0 + col1 * + col2 * + col1 + tab2.col1 FROM tab2
----
11078
25985
90643

query I rowsort
SELECT DISTINCT + 49 * + col1 AS col2 FROM tab2 AS cor0
----
1519
2891
833

query I rowsort
SELECT + col1 + + col1 * ( - col0 ) FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-8175
SELECT - 94 * col1 DIV ( - 39 ) AS col0 FROM tab2 AS cor0
----
142
40
74

skipif mysql # not compatible
query I rowsort label-8175
SELECT - 94 * col1 / ( - 39 ) AS col0 FROM tab2 AS cor0
----
142
40
74

query I rowsort
SELECT DISTINCT col2 + col0 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT + 13 * + col1 FROM tab1 AS cor0
----
130
169
338

onlyif mysql # use DIV operator for integer division
query I rowsort label-8178
SELECT DISTINCT col2 DIV col1 col2 FROM tab2 AS cor0
----
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8178
SELECT DISTINCT col2 / col1 col2 FROM tab2 AS cor0
----
0
2

query I rowsort
SELECT - 64 * + col0 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT ALL 87 * col2 AS col2 FROM tab1
----
4698
4959
8352

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8181
SELECT ALL CAST( col0 AS SIGNED ) col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8181
SELECT ALL CAST ( col0 AS INTEGER ) col1 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8182
SELECT DISTINCT col0 * col1 DIV col1 - col1 FROM tab2
----
-24
19
62

skipif mysql # not compatible
query I rowsort label-8182
SELECT DISTINCT col0 * col1 / col1 - col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL + 68 - + col1 FROM tab1
----
42
55
58

query I rowsort
SELECT - - col1 + col2 * - 0 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8185
SELECT col2 + + col1 DIV + cor0.col1 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-8185
SELECT col2 + + col1 / + cor0.col1 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT ALL - ( + col0 ) AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL 57 * - cor0.col0 FROM tab0 AS cor0
----
-1368
-1995
-5073

query I rowsort
SELECT ALL + col1 * cor0.col1 * col1 FROM tab1 AS cor0
----
1000
17576
2197

onlyif mysql # use DIV operator for integer division
query I rowsort label-8189
SELECT DISTINCT - + cor0.col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8189
SELECT DISTINCT - + cor0.col2 / + col2 AS col1 FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8190
SELECT - 43 DIV col1 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-8190
SELECT - 43 / col1 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL - 14 * + col2 FROM tab0
----
-1148
-14
-462

query I rowsort
SELECT ALL ( + ( - col2 ) * col0 ) AS col0 FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8193
SELECT CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8193
SELECT CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 31 + - 86 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-55

query I rowsort
SELECT - 84 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

onlyif mysql # use DIV operator for integer division
query I rowsort label-8196
SELECT ALL col2 + - col0 DIV 73 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-8196
SELECT ALL col2 + - col0 / 73 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT cor0.col2 * cor0.col0 AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + + cor0.col2 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + - col2 * - col0 AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + col0 + 34 FROM tab0 AS cor0
----
123
58
69

query I rowsort
SELECT col1 - col2 * 39 * + col1 AS col0 FROM tab2 AS cor0
----
-25177
-32612
-59767

query I rowsort
SELECT DISTINCT + - col1 + + col0 * col1 * + col1 FROM tab0 AS cor0
----
177418
329218
736918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8204
SELECT - col1 * - CAST( NULL AS SIGNED ) - col1 * - col1 * 55 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8204
SELECT - col1 * - CAST ( NULL AS INTEGER ) - col1 * - col1 * 55 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8205
SELECT DISTINCT col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8205
SELECT DISTINCT col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 5 * 29 + col2 col1 FROM tab2 AS cor0
----
-107
-118
-119

query I rowsort
SELECT DISTINCT col1 * 58 FROM tab2
----
1798
3422
986

query I rowsort
SELECT - ( 92 + col1 ) FROM tab2
----
-109
-123
-151

onlyif mysql # use DIV operator for integer division
query I rowsort label-8209
SELECT DISTINCT + ( + col2 ) DIV + cor0.col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8209
SELECT DISTINCT + ( + col2 ) / + cor0.col2 FROM tab0 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-8210
SELECT + 26 + + col2 DIV col2 FROM tab1 AS cor0
----
27
27
27

skipif mysql # not compatible
query I rowsort label-8210
SELECT + 26 + + col2 / col2 FROM tab1 AS cor0
----
27
27
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-8211
SELECT + + 69 DIV + col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-8211
SELECT + + 69 / + col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT cor0.col2 + col1 * col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col1 col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + 5 + col2 * - col0 FROM tab2 AS cor0
----
-184
-2023
-2997

query I rowsort
SELECT - ( 29 ) * - col0 FROM tab0 AS cor0
----
1015
2581
696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8216
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8216
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col2 FROM tab2 AS cor0
----
NULL

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0 CROSS JOIN tab1, tab0 AS cor1
----
972 values hashing to 5e655b1287771868a8f868574a94d749

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8218
SELECT - ( - col0 + col1 ) * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8218
SELECT - ( - col0 + col1 ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 52 * + col0 + + col2 AS col2 FROM tab2 AS cor0
----
391
4082
4146

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) * cor0.col0 + - col2 AS col1 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT - - ( cor1.col0 ) AS col2 FROM tab1, tab0 cor0 CROSS JOIN tab1 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT - + ( + ( cor0.col2 ) ) + - cor0.col2 AS col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - ( - col0 ) + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - col0 * - col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT + col2 * col0 * + col0 + 63 AS col0 FROM tab2
----
1386
158247
237221

query I rowsort
SELECT ALL - 29 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 56a8aa9e4c5d3c934d1853afeb22653e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8227
SELECT + 17 + col2 DIV ( + col1 ) FROM tab0 AS cor0
----
17
17
17

skipif mysql # not compatible
query I rowsort label-8227
SELECT + 17 + col2 / ( + col1 ) FROM tab0 AS cor0
----
17
17
17

query I rowsort
SELECT 43 + + col0 AS col1 FROM tab2 AS cor0
----
121
122
50

query I rowsort
SELECT - col1 + - 60 * - col2 FROM tab1 AS cor0
----
3214
3410
5747

onlyif mysql # use DIV operator for integer division
query I rowsort label-8230
SELECT DISTINCT + - col1 DIV + col0 - - col2 AS col1 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-8230
SELECT DISTINCT + - col1 / + col0 - - col2 AS col1 FROM tab0 AS cor0
----
-1
30
81

query I rowsort
SELECT + + cor0.col1 * + 93 FROM tab1 AS cor0
----
1209
2418
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 + ( col1 ) col1 FROM tab1 cor0
----
36
39
52

query I rowsort
SELECT - tab2.col2 + 20 * - col2 FROM tab2
----
-546
-567
-798

query I rowsort
SELECT + col1 - - 69 FROM tab2 AS cor0
----
100
128
86

query I rowsort
SELECT - col1 * + col1 * - col1 + ( col0 ) * col1 AS col1 FROM tab1 AS cor0
----
1640
17654
3237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col0 col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + + cor0.col1 * 55 + + col0 AS col1 FROM tab2 AS cor0
----
1014
1712
3323

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8238
SELECT DISTINCT + col0 + + CAST( ( col1 ) AS SIGNED ) * col1 * col1 FROM tab1
----
1064
17579
2277

skipif mysql # not compatible
query I rowsort label-8238
SELECT DISTINCT + col0 + + CAST ( ( col1 ) AS INTEGER ) * col1 * col1 FROM tab1
----
1064
17579
2277

onlyif mysql # use DIV operator for integer division
query I rowsort label-8239
SELECT + col0 DIV + 84 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8239
SELECT + col0 / + 84 FROM tab2
----
0
0
0

query I rowsort
SELECT col0 + tab0.col0 * + col0 AS col2 FROM tab0
----
1260
600
8010

query I rowsort
SELECT + col2 FROM tab0 AS cor0 WHERE ( col2 ) NOT BETWEEN NULL AND NULL
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col1 + col1 IN ( col1 + + col2 / - col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col0 * tab1.col1 * col0 AS col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT col1 + tab1.col2 AS col0 FROM tab1 WHERE NOT NULL NOT IN ( - col2 * col1 + col1 )
----

query I rowsort
SELECT col2 * - tab2.col0 + col2 AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT + tab2.col0 * - col2 + + col1 AS col2 FROM tab2
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 col2 FROM tab2 WHERE NULL BETWEEN ( col0 ) AND - col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 + col2 * - col0 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT col1 + col1 * - tab0.col2 + tab0.col2 FROM tab0
----
-2719
-7289
1

query I rowsort
SELECT ALL + tab2.col0 * tab2.col0 AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT col2 * col0 + col0 * col2 * - col2 FROM tab2
----
-111074
-4914
-50700

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) NOT BETWEEN + col2 * col1 AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col0 * + col1 - + col1 col0 FROM tab0
----
1945
3297
7926

query I rowsort
SELECT DISTINCT - tab2.col1 AS col0 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col1 * col2 - col2 )
----

query I rowsort
SELECT - col1 + cor0.col0 * cor0.col1 + - col1 AS col0 FROM tab0 AS cor0
----
1892
3201
7917

query I rowsort
SELECT - tab0.col2 / + col2 + col0 * - col0 + + col2 FROM tab0 WHERE ( col1 ) = NULL AND NULL NOT IN ( - tab0.col1 * col0 + col1 * col1 )
----

query I rowsort
SELECT col2 - col2 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + col2 + + col1 - + col2 * - col1 FROM tab0
----
195
2957
7635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * col0 + + col2 col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - col2 * + cor0.col2 + - col1 * col1 FROM tab0 AS cor0
----
-15005
-8485
-9410

query I rowsort
SELECT DISTINCT - col1 + + col2 * col2 AS col2 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-8262
SELECT tab0.col0 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8262
SELECT tab0.col0 / - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col2 + - col0 + col1 FROM tab0
----
63
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8264
SELECT col1 - col1 DIV col0 AS col1 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-8264
SELECT col1 - col1 / col0 AS col1 FROM tab2 AS cor0
----
17
27
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8265
SELECT 64 * + tab2.col2 + CAST( - col1 AS SIGNED ) FROM tab2
----
1605
1697
2415

skipif mysql # not compatible
query I rowsort label-8265
SELECT 64 * + tab2.col2 + CAST ( - col1 AS INTEGER ) FROM tab2
----
1605
1697
2415

query I rowsort
SELECT - 23 + col2 + - ( col2 ) AS col2 FROM tab2
----
-23
-23
-23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 3 - + col2 col2 FROM tab2
----
-23
-24
-35

query I rowsort
SELECT DISTINCT - col1 - tab0.col0 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT 77 - col1 FROM tab0
----
-14
-20
-9

query I rowsort
SELECT col2 * col1 - + 55 AS col2 FROM tab2
----
1479
591
782

query I rowsort
SELECT ALL + col1 + col2 * + ( + 29 ) + - col0 FROM tab2 AS cor0
----
1040
735
807

query I rowsort
SELECT ALL + 77 + col2 FROM tab2 AS cor0
----
103
104
115

query I rowsort
SELECT DISTINCT - cor0.col0 - - col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - 79 - - cor0.col2 * 5 FROM tab1 AS cor0
----
191
206
401

query I rowsort
SELECT ALL - 60 * col0 + ( - col1 ) * + cor0.col2 FROM tab1 AS cor0
----
-1584
-4410
-6048

query I rowsort
SELECT DISTINCT + 21 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8277
SELECT ALL - col1 * CAST( + 71 AS SIGNED ) - col0 FROM tab0 AS cor0
----
-6130
-6550
-6922

skipif mysql # not compatible
query I rowsort label-8277
SELECT ALL - col1 * CAST ( + 71 AS INTEGER ) - col0 FROM tab0 AS cor0
----
-6130
-6550
-6922

query I rowsort
SELECT - col0 + ( + col0 ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 + 69 * + cor0.col2 * col0 FROM tab0 AS cor0
----
2380
503473
54624

query I rowsort
SELECT ALL col1 * - col1 * + 28 + - col1 * col0 FROM tab2 AS cor0
----
-102070
-27125
-9435

query I rowsort
SELECT ALL - col1 * + 30 + col0 AS col2 FROM tab0 AS cor0
----
-2556
-2641
-2875

query I rowsort
SELECT ALL - - cor0.col0 + 9 * - col2 - col2 AS col2 FROM tab0 AS cor0
----
-306
-731
25

query I rowsort
SELECT DISTINCT + col1 + ( col0 ) AS col1 FROM tab1 cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + cor0.col1 col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + - col2 * 54 + col1 * col0 AS col2 FROM tab0 AS cor0
----
282
3341
3671

query I rowsort
SELECT ALL col0 * + 69 AS col1 FROM tab0 AS cor0
----
1656
2415
6141

query I rowsort
SELECT ALL - col0 + col1 * col1 AS col2 FROM tab2 AS cor0
----
210
3403
954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - 42 col0 FROM tab2 AS cor0
----
-101
-59
-73

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + col1 AS col1 FROM tab2 cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 64 col0 FROM tab0 AS cor0
----
150
155
161

query I rowsort
SELECT ALL - 30 - + col1 AS col0 FROM tab0
----
-116
-121
-127

query I rowsort
SELECT 50 * col0 FROM tab2
----
350
3900
3950

query I rowsort
SELECT ALL + + col1 * cor0.col0 + + cor0.col1 AS col2 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT - col2 * 5 + cor0.col0 + col1 FROM tab2 AS cor0
----
-94
-97
7

query I rowsort
SELECT col2 * + col2 + 73 AS col1 FROM tab0 AS cor0
----
1162
6797
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-8296
SELECT col2 * col0 - col1 DIV - col0 AS col1 FROM tab0
----
37
7299
795

skipif mysql # not compatible
query I rowsort label-8296
SELECT col2 * col0 - col1 / - col0 AS col1 FROM tab0
----
37
7299
795

query III rowsort
SELECT * FROM tab1 WHERE NOT - col0 <> col0
----

query I rowsort
SELECT col2 + - tab2.col1 AS col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col0 FROM tab0 WHERE ( - col0 ) > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 * tab0.col1 col0 FROM tab0
----
2088
3430
8188

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) IN ( col1 * - col2 )
----

query I rowsort
SELECT DISTINCT + col0 + col2 * + col1 * + col2 AS col1 FROM tab1
----
119888
32554
75819

query I rowsort
SELECT + col0 * + col2 * cor0.col2 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT + col2 - - col1 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col1 + - col0 * - col0 AS col0 FROM tab1
----
35
4106
6413

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL IN ( col1 + col1 * - col1 * + tab1.col1 + col0 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE - col0 < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8308
SELECT DISTINCT + col0 + col1 DIV col2 AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8308
SELECT DISTINCT + col0 + col1 / col2 AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT - col0 * col1 + - col2 + col0 FROM tab1
----
-1056
-129
-633

query I rowsort
SELECT DISTINCT - col0 * col0 AS col0 FROM tab0 WHERE ( NULL ) NOT IN ( col2 * + col2 )
----

query I rowsort
SELECT DISTINCT col2 * cor0.col2 - 82 * col1 FROM tab0 cor0
----
-5963
-738
-7953

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8312
SELECT ALL - cor0.col2 - CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8312
SELECT ALL - cor0.col2 - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col2 * + 98 AS col0 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT + col0 + 11 FROM tab1 AS cor0
----
14
75
91

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab2 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 5ec52b92c3c8d78cc0a61df3fc16f18b

query I rowsort
SELECT ALL - col0 + - col1 * col0 AS col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT - ( 81 ) + col1 * 89 FROM tab1 AS cor0
----
1076
2233
809

query I rowsort
SELECT - 9 + - cor0.col1 FROM tab1 AS cor0
----
-19
-22
-35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 + + col1 col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + - cor0.col0 + - col0 * col1 * + col1 FROM tab2 AS cor0
----
-22910
-271596
-6734

onlyif mysql # use DIV operator for integer division
query I rowsort label-8321
SELECT ALL + - col1 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8321
SELECT ALL + - col1 / + col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col0 * + col0 + 97 FROM tab2 cor0
----
-5987
-6144
48

query I rowsort
SELECT - col1 * - col0 - ( col2 ) FROM tab2 AS cor0
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-8324
SELECT + + col0 DIV + col2 + - col0 * 68 AS col0 FROM tab0 AS cor0
----
-1632
-2345
-6051

skipif mysql # not compatible
query I rowsort label-8324
SELECT + + col0 / + col2 + - col0 * 68 AS col0 FROM tab0 AS cor0
----
-1632
-2345
-6051

query I rowsort
SELECT DISTINCT + - col0 - col2 AS col0 FROM tab0 cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8326
SELECT DISTINCT - col2 * col1 DIV col1 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-8326
SELECT DISTINCT - col2 * col1 / col1 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - 53 * col2 - - col1 * col1 FROM tab2 cor0
----
-1725
-470
2103

query I rowsort
SELECT cor0.col0 * - col2 - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL + - 89 + - col1 AS col2 FROM tab2 AS cor0
----
-106
-120
-148

query I rowsort
SELECT col2 * col2 + - col1 AS col1 FROM tab2
----
1427
617
698

query I rowsort
SELECT ALL - col0 * - 60 * col1 FROM tab2
----
13020
276120
80580

query I rowsort
SELECT ALL col2 + col2 * ( - 95 ) AS col2 FROM tab0
----
-3102
-7708
-94

query I rowsort
SELECT + - 86 + + col0 * + col0 * + col1 FROM tab2 AS cor0
----
106011
1433
358870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 8 col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT DISTINCT - - 25 * - col0 + col0 * + 96 FROM tab1 AS cor0
----
213
4544
5680

query I rowsort
SELECT ALL 96 * + col0 - - 66 * + col0 AS col2 FROM tab2 cor0
----
1134
12636
12798

onlyif mysql # use DIV operator for integer division
query I rowsort label-8337
SELECT - col2 DIV col0 + tab1.col0 + + col2 AS col1 FROM tab1
----
121
175
39

skipif mysql # not compatible
query I rowsort label-8337
SELECT - col2 / col0 + tab1.col0 + + col2 AS col1 FROM tab1
----
121
175
39

query I rowsort
SELECT - ( tab0.col0 ) * col0 AS col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT + - col0 * 37 * 93 FROM tab1 AS cor0
----
-10323
-220224
-275280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8340
SELECT cor0.col2 - CAST( NULL AS SIGNED ) * + col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8340
SELECT cor0.col2 - CAST ( NULL AS INTEGER ) * + col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 42 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

onlyif mysql # use DIV operator for integer division
query I rowsort label-8342
SELECT + + cor0.col1 DIV col0 + col0 AS col1 FROM tab0 cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-8342
SELECT + + cor0.col1 / col0 + col0 AS col1 FROM tab0 cor0
----
27
37
90

query I rowsort
SELECT col2 * ( 87 ) AS col1 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT - cor0.col0 - cor0.col0 AS col0 FROM tab2 cor0
----
-14
-156
-158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8345
SELECT - + cor0.col2 * + CAST( cor0.col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-8345
SELECT - + cor0.col2 * + CAST ( cor0.col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col0 * - col0 + 49 FROM tab0
----
-1176
-527
-7872

query I rowsort
SELECT DISTINCT + cor0.col1 AS col2 FROM tab2, tab1, tab0 AS cor0, tab2 cor1
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 10 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 AS cor2, tab1
----
13122 values hashing to 9a281a45c09267a5b13548c2b91d7079

query I rowsort
SELECT ALL + tab2.col1 * - col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - col0 * + cor0.col2 - 86 * col2 * - ( col1 ) FROM tab2 AS cor0
----
129896
52554
71793

query I rowsort
SELECT + col1 * - col1 * + col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT + col0 * - 20 + 46 AS col0 FROM tab0 AS cor0
----
-1734
-434
-654

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8354
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8354
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - 97 * - col0 * - col0 FROM tab1 AS cor0
----
-397312
-620800
-873

query I rowsort
SELECT ALL + 46 * col0 + - col0 * col2 AS col2 FROM tab0 AS cor0
----
-3204
1575
312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8357
SELECT ALL - CAST( - col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8357
SELECT ALL - CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + 91 + col0 + col2 FROM tab0 AS cor0
----
127
148
262

query I rowsort
SELECT - ( + col2 ) + col1 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8360
SELECT - - 62 + 64 DIV col1 FROM tab0 cor0
----
62
62
62

skipif mysql # not compatible
query I rowsort label-8360
SELECT - - 62 + 64 / col1 FROM tab0 cor0
----
62
62
62

query I rowsort
SELECT ALL 51 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT ALL - 75 AS col1 FROM tab2 AS cor0
----
-75
-75
-75

query I rowsort
SELECT 37 * col2 AS col1 FROM tab0 AS cor0
----
1221
3034
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8364
SELECT DISTINCT + CAST( NULL AS SIGNED ) / col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8364
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / col2 FROM tab0
----
NULL

query I rowsort
SELECT - 98 + - col1 AS col1 FROM tab2 cor0
----
-115
-129
-157

onlyif mysql # use DIV operator for integer division
query I rowsort label-8366
SELECT - col0 * cor0.col0 + - col2 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1225
-575
-7921

skipif mysql # not compatible
query I rowsort label-8366
SELECT - col0 * cor0.col0 + - col2 / - col0 AS col1 FROM tab0 AS cor0
----
-1225
-575
-7921

query I rowsort
SELECT ( 88 ) * col1 AS col2 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT - 47 + - cor0.col0 FROM tab0 AS cor0
----
-136
-71
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) col1 FROM tab2 cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8370
SELECT ALL - - cor0.col2 DIV + 9 + col0 col1 FROM tab1 cor0
----
70
9
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8370
SELECT ALL - - cor0.col2 / + 9 + col0 col1 FROM tab1 cor0
----
70
9
90

query I rowsort
SELECT ALL + ( - col1 ) * - col2 * col0 + 97 + - col0 * col2 AS col2 FROM tab0 AS cor0
----
3457
656917
67417

query I rowsort
SELECT DISTINCT + ( + col0 ) + + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8373
SELECT ALL - + CAST( + col0 AS SIGNED ) + - col2 * - col2 AS col1 FROM tab0 AS cor0
----
-34
1065
6635

skipif mysql # not compatible
query I rowsort label-8373
SELECT ALL - + CAST ( + col0 AS INTEGER ) + - col2 * - col2 AS col1 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT col0 * + col0 * - col1 FROM tab1 cor0
----
-234
-40960
-83200

query I rowsort
SELECT ( - col2 ) + + col1 * - col2 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT DISTINCT ( - 89 ) FROM tab2
----
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8377
SELECT DISTINCT - 71 DIV col0 col0 FROM tab2 AS cor0
----
-10
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8377
SELECT DISTINCT - 71 / col0 col0 FROM tab2 AS cor0
----
-10
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8378
SELECT ALL - cor0.col1 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8378
SELECT ALL - cor0.col1 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 21 FROM tab1, tab0 cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to 1d381b4ba3c90535da913c6b9acadb5a

query I rowsort
SELECT ALL 43 - col0 FROM tab2
----
-35
-36
36

query I rowsort
SELECT + ( + 85 + col1 ) * + tab2.col0 FROM tab2
----
11232
8058
812

query I rowsort
SELECT DISTINCT + col0 * + ( ( - col1 ) * col0 + + 28 ) FROM tab2 AS cor0
----
-103885
-1323
-356772

query I rowsort
SELECT + + col1 + - col2 * - cor0.col1 * col2 FROM tab0 AS cor0
----
194
611975
93740

query I rowsort
SELECT - - col2 * - 36 AS col1 FROM tab2 cor0
----
-1368
-936
-972

query I rowsort
SELECT + col0 * + ( + col2 * + col1 + col1 ) AS col0 FROM tab0 AS cor0
----
672217
6790
70176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8386
SELECT - col1 * CAST( NULL AS SIGNED ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8386
SELECT - col1 * CAST ( NULL AS INTEGER ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 8 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0, tab2 AS cor2
----
243 values hashing to 166637359c82545ac3371f65af093c5f

query I rowsort
SELECT ALL + col2 * - ( + 87 ) AS col1 FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT DISTINCT 33 AS col2 FROM tab1, tab0 cor0
----
33

query I rowsort
SELECT DISTINCT + 18 + 83 FROM tab2, tab0 AS cor0
----
101

query I rowsort
SELECT DISTINCT - col1 * + 14 FROM tab0
----
-1204
-1274
-1358

query I rowsort
SELECT DISTINCT + - ( - 23 ) AS col1 FROM tab2 AS cor0
----
23

query I rowsort
SELECT - 3 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT DISTINCT 99 + - 7 * + col2 * - col0 AS col0 FROM tab1 AS cor0
----
1233
25635
53859

query I rowsort
SELECT col1 + - 52 * - col0 FROM tab2 AS cor0
----
395
4115
4125

query I rowsort
SELECT col0 + - ( 67 ) AS col1 FROM tab1
----
-3
-64
13

query I rowsort
SELECT 5 * + 6 FROM tab1, tab0 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8398
SELECT + 8 DIV + tab1.col2 + - col1 * col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-8398
SELECT + 8 / + tab1.col2 + - col1 * col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT 94 * - col2 + - col1 * - col1 FROM tab2
----
-1577
-3283
1037

query I rowsort
SELECT + 45 + col2 * + col1 AS col1 FROM tab0 AS cor0
----
142
2883
7507

query I rowsort
SELECT - 91 + 81 * - col2 FROM tab1
----
-4465
-4708
-7867

query I rowsort
SELECT ( 49 ) + col0 FROM tab2
----
127
128
56

query I rowsort
SELECT + col2 + - col0 * + col2 AS col2 FROM tab0
----
-34
-7216
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 88 * - col1 * + col1 col1 FROM tab2 AS cor0
----
25432
306328
84568

query I rowsort
SELECT ALL col0 * - 40 FROM tab0 AS cor0
----
-1400
-3560
-960

query I rowsort
SELECT DISTINCT - 52 AS col0 FROM tab2 AS cor0
----
-52

query I rowsort
SELECT DISTINCT ( + col2 ) + - col2 FROM tab2
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8408
SELECT ALL col1 * + col1 + CAST( col0 AS SIGNED ) AS col2 FROM tab0
----
7420
8370
9444

skipif mysql # not compatible
query I rowsort label-8408
SELECT ALL col1 * + col1 + CAST ( col0 AS INTEGER ) AS col2 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT - ( col2 * col2 ) + + tab1.col2 AS col2 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT + col2 + col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT col2 * - tab1.col1 - col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT + + col2 * - col0 + + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL - + col2 + ( - col0 * - col0 ) FROM tab1 cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT cor0.col2 * col2 * 12 AS col1 FROM tab0 AS cor0
----
12
13068
80688

query I rowsort
SELECT ALL - col2 + 0 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - col1 + - col0 AS col2 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - col0 + ( col2 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT col0 + cor0.col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8419
SELECT DISTINCT col2 + + CAST( - col1 AS SIGNED ) AS col2 FROM tab1 cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-8419
SELECT DISTINCT col2 + + CAST ( - col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8420
SELECT - + col0 DIV + 62 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-8420
SELECT - + col0 / + 62 FROM tab1 AS cor0
----
-1
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8421
SELECT DISTINCT + col1 DIV + col0 AS col0 FROM tab2
----
0
4

skipif mysql # not compatible
query I rowsort label-8421
SELECT DISTINCT + col1 / + col0 AS col0 FROM tab2
----
0
4

query I rowsort
SELECT ALL + - col0 + col1 * + ( col2 ) * + 53 FROM tab2 AS cor0
----
34159
44354
81224

query I rowsort
SELECT col2 + + ( + ( + col2 ) ) * + 3 AS col1 FROM tab1 AS cor0
----
216
228
384

onlyif mysql # use DIV operator for integer division
query I rowsort label-8424
SELECT - - col1 DIV 31 FROM tab0 AS cor0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-8424
SELECT - - col1 / 31 FROM tab0 AS cor0
----
2
2
3

query I rowsort
SELECT DISTINCT col2 * - 96 FROM tab1 cor0
----
-5184
-5472
-9216

query I rowsort
SELECT cor0.col1 AS col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - col2 * + 82 + tab2.col0 AS col1 FROM tab2
----
-2054
-2207
-3037

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8428
SELECT DISTINCT + CAST( NULL AS SIGNED ) / 28 FROM tab2, tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8428
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / 28 FROM tab2, tab1, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL tab0.col0 * col0 + - col1 FROM tab0
----
1128
490
7830

query I rowsort
SELECT DISTINCT + 11 + - 69 * col1 FROM tab2
----
-1162
-2128
-4060

query I rowsort
SELECT col0 + - 47 FROM tab1
----
-44
17
33

query I rowsort
SELECT + 65 * - 69 FROM tab0
----
-4485
-4485
-4485

query I rowsort
SELECT DISTINCT - col2 + 51 AS col0 FROM tab2
----
13
24
25

query I rowsort
SELECT - 40 + col1 * + tab1.col1 FROM tab1
----
129
60
636

query I rowsort
SELECT - 27 - - 59 FROM tab0 AS cor0
----
32
32
32

query I rowsort
SELECT ALL - + col0 + + 6 AS col1 FROM tab0 AS cor0
----
-18
-29
-83

query I rowsort
SELECT - col0 - 48 AS col2 FROM tab2 AS cor0
----
-126
-127
-55

query I rowsort
SELECT ALL - - ( - col0 ) * + col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + + 41 + col1 + + col0 FROM tab2 AS cor0
----
137
178
79

query I rowsort
SELECT DISTINCT col1 + - cor0.col0 * - col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8441
SELECT DISTINCT + cor0.col1 + + col2 * CAST( NULL AS SIGNED ) + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8441
SELECT DISTINCT + cor0.col1 + + col2 * CAST ( NULL AS INTEGER ) + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col0 + + col2 * col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT + 83 * col2 + - 2 AS col2 FROM tab0 AS cor0
----
2737
6804
81

query I rowsort
SELECT ALL - + 94 * - col0 + ( 18 ) + + col1 AS col0 FROM tab1 cor0
----
326
6044
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - cor0.col1 ) + - col1 col2 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-8446
SELECT ( tab0.col0 ) * col2 DIV col1 FROM tab0
----
0
80
9

skipif mysql # not compatible
query I rowsort label-8446
SELECT ( tab0.col0 ) * col2 / col1 FROM tab0
----
0
80
9

query I rowsort
SELECT ALL - cor0.col1 - - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - col2 + - 46 AS col2 FROM tab1 AS cor0
----
11
50
8

query I rowsort
SELECT DISTINCT - col2 * - 87 AS col0 FROM tab2 AS cor0
----
2262
2349
3306

query I rowsort
SELECT DISTINCT - cor0.col1 * - col0 * - cor0.col0 AS col1 FROM tab0 cor0
----
-118825
-49536
-720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-8451
SELECT ALL - + col2 DIV - col1 col0 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8451
SELECT ALL - + col2 / - col1 col0 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + col0 * + ( - 96 ) FROM tab2 AS cor0
----
-672
-7488
-7584

query I rowsort
SELECT DISTINCT - col1 * - 94 + + col0 + col1 FROM tab2 AS cor0
----
1694
2952
5683

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8454
SELECT ALL - + cor0.col2 * CAST( NULL AS SIGNED ) col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8454
SELECT ALL - + cor0.col2 * CAST ( NULL AS INTEGER ) col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + 32 AS col2 FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT ALL col2 * + col1 + - ( col2 ) + 69 FROM tab2 cor0
----
1577
677
879

query I rowsort
SELECT DISTINCT + col2 * - col2 - col0 AS col0 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT cor0.col0 * + 52 AS col0 FROM tab2 AS cor0
----
364
4056
4108

onlyif mysql # use DIV operator for integer division
query I rowsort label-8459
SELECT ALL + col0 + 23 DIV 83 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8459
SELECT ALL + col0 + 23 / 83 AS col1 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8460
SELECT DISTINCT + col2 DIV - col0 AS col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-8460
SELECT DISTINCT + col2 / - col0 AS col0 FROM tab2 AS cor0
----
-3
0

query I rowsort
SELECT cor0.col2 * - 4 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to d2d454c975203da3b6df36fbf09e426a

query I rowsort
SELECT + 15 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT DISTINCT 98 FROM tab1, tab1 AS cor0
----
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8464
SELECT DISTINCT + + 8 DIV + col0 + col2 AS col0 FROM tab1 cor0
----
56
57
96

skipif mysql # not compatible
query I rowsort label-8464
SELECT DISTINCT + + 8 / + col0 + col2 AS col0 FROM tab1 cor0
----
56
57
96

query I rowsort
SELECT DISTINCT - + cor0.col2 + + col2 + - col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + ( + ( col0 ) ) - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - cor1.col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT col0 * + ( 73 ) + - col0 FROM tab0
----
1728
2520
6408

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8469
SELECT - CAST( + 9 AS SIGNED ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

skipif mysql # not compatible
query I rowsort label-8469
SELECT - CAST ( + 9 AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

query I rowsort
SELECT + - ( - 92 ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
4968
5244
8832

query I rowsort
SELECT + col1 + - cor0.col1 * - col0 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT col2 * - tab1.col0 + - tab1.col0 AS col1 FROM tab1
----
-165
-3712
-7760

skipif mysql # not compatible
query I rowsort
SELECT + col0 + - CAST ( - 36 AS REAL ) FROM tab2
----
114
115
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8474
SELECT - + CAST( NULL AS DECIMAL ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8474
SELECT - + CAST ( NULL AS REAL ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + 30 AS col1 FROM tab0
----
116
121
127

query I rowsort
SELECT col0 - - col1 * + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + col1 + - col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT - col1 - ( col2 ) FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + ( cor0.col1 ) + col2 * 81 FROM tab2 AS cor0
----
2165
2218
3095

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 11 ) col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
11

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab1 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 78077727601c056ad0d4f4c11c8daffb

query I rowsort
SELECT DISTINCT + 88 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
88

query I rowsort
SELECT + col2 * + tab0.col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL + cor0.col1 - + cor1.col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to fac199fee49cfb7f8ea6cc57c52dd643

query I rowsort
SELECT DISTINCT - col1 * ( col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - cor0.col2 * + col0 * 39 FROM tab2 AS cor0
----
-117078
-7371
-79092

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8487
SELECT DISTINCT col1 * + CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8487
SELECT DISTINCT col1 * + CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 + col0 * 99 AS col2 FROM tab1 AS cor0
----
271
6326
7907

query I rowsort
SELECT + col0 * - col0 + col1 AS col2 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT + col1 + + col1 * cor0.col2 * + col1 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT 13 - - col1 FROM tab0
----
104
110
99

query I rowsort
SELECT - 76 * cor0.col2 FROM tab2 AS cor0
----
-1976
-2052
-2888

query I rowsort
SELECT DISTINCT + - col2 * - col0 + 0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT - - col2 + - col0 * 9 FROM tab0 cor0
----
-183
-314
-719

query I rowsort
SELECT ALL - + col2 + col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col2 + 75 FROM tab0 AS cor0
----
108
157
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8497
SELECT col0 DIV 94 - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-8497
SELECT col0 / 94 - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + - col1 * + ( col1 ) - + col0 AS col0 FROM tab0 cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + cor0.col1 + - cor0.col2 * cor0.col2 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT ALL - + ( 45 ) FROM tab2 AS cor0
----
-45
-45
-45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8501
SELECT col0 * CAST( NULL AS SIGNED ) + tab1.col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8501
SELECT col0 * CAST ( NULL AS INTEGER ) + tab1.col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col0 * 42 FROM tab1 AS cor0
----
-126
-2688
-3360

query I rowsort
SELECT 95 FROM tab0, tab0 cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ALL + col2 + 45 + col0 FROM tab1 AS cor0
----
102
166
221

query I rowsort
SELECT 56 * + col2 AS col2 FROM tab2
----
1456
1512
2128

query I rowsort
SELECT + 7 * col0 AS col0 FROM tab2 AS cor0
----
49
546
553

query I rowsort
SELECT DISTINCT - col2 * col2 + 23 AS col0 FROM tab0 AS cor0
----
-1066
-6701
22

query I rowsort
SELECT + + 24 AS col0 FROM tab2 AS cor0
----
24
24
24

query I rowsort
SELECT ALL - + 68 * col2 * col0 - - 72 * + col1 FROM tab2 AS cor0
----
-10620
-133656
-202912

onlyif mysql # use DIV operator for integer division
query I rowsort label-8510
SELECT + ( 92 ) DIV - col0 + + col0 AS col0 FROM tab0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-8510
SELECT + ( 92 ) / - col0 + + col0 AS col0 FROM tab0
----
21
33
88

query I rowsort
SELECT 46 * col1 FROM tab1
----
1196
460
598

query I rowsort
SELECT 42 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT + + 98 * col2 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT DISTINCT + 95 AS col0 FROM tab0 cor0
----
95

query I rowsort
SELECT ALL col0 + - 79 AS col1 FROM tab1
----
-15
-76
1

query I rowsort
SELECT DISTINCT col1 * - col0 + col1 AS col0 FROM tab2
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-8517
SELECT DISTINCT + 32 - - col0 DIV ( - col0 * col0 + ( + ( col0 ) ) ) FROM tab2 AS cor0
----
32

skipif mysql # not compatible
query I rowsort label-8517
SELECT DISTINCT + 32 - - col0 / ( - col0 * col0 + ( + ( col0 ) ) ) FROM tab2 AS cor0
----
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * - col0 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + - 81 + - col0 AS col1 FROM tab0 AS cor0
----
-105
-116
-170

query I rowsort
SELECT ALL - cor0.col0 * col0 + ( col0 ) FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT ALL - - 68 FROM tab1 cor0
----
68
68
68

query I rowsort
SELECT DISTINCT + ( - col2 * - ( tab0.col2 ) ) AS col1 FROM tab0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8523
SELECT ALL + col2 - + CAST( NULL AS SIGNED ) / tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8523
SELECT ALL + col2 - + CAST ( NULL AS INTEGER ) / tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col1 ) col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ( - col0 ) * col0 + ( + 89 ) + + col1 * + 88 AS col2 FROM tab1 AS cor0
----
-3127
-5167
2368

onlyif mysql # use DIV operator for integer division
query I rowsort label-8526
SELECT - tab0.col2 DIV col1 + - tab0.col2 + - col0 FROM tab0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-8526
SELECT - tab0.col2 / col1 + - tab0.col2 + - col0 FROM tab0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8527
SELECT - col0 + + 77 * 49 + + col2 DIV + cor0.col1 FROM tab0 cor0
----
3684
3738
3749

skipif mysql # not compatible
query I rowsort label-8527
SELECT - col0 + + 77 * 49 + + col2 / + cor0.col1 FROM tab0 cor0
----
3684
3738
3749

query I rowsort
SELECT - col1 + - ( col2 ) - col2 * - col0 FROM tab1
----
3581
7571
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8529
SELECT DISTINCT + col1 DIV col1 + - col0 - tab1.col1 AS col0 FROM tab1
----
-28
-73
-92

skipif mysql # not compatible
query I rowsort label-8529
SELECT DISTINCT + col1 / col1 + - col0 - tab1.col1 AS col0 FROM tab1
----
-28
-73
-92

query I rowsort
SELECT DISTINCT col1 * col1 - + tab2.col0 FROM tab2
----
210
3403
954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 col2 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT + - col2 * + col0 + + col1 + - 99 AS col0 FROM tab1 AS cor0
----
-235
-3737
-7766

query I rowsort
SELECT ( - col0 ) * + col1 AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - ( ( - col2 ) ) FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - - col2 * - col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT ALL + cor0.col2 * + ( col2 ) + - col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT + + ( - col1 ) * - col1 + + col0 + 71 AS col2 FROM tab0 AS cor0
----
7491
8441
9515

query I rowsort
SELECT col2 - col1 * cor0.col1 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT + + ( col1 ) * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-8540
SELECT 65 + col1 DIV cor0.col1 FROM tab2 AS cor0
----
66
66
66

skipif mysql # not compatible
query I rowsort label-8540
SELECT 65 + col1 / cor0.col1 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT ALL - + col1 * ( + col0 ) * 5 FROM tab1 AS cor0
----
-3200
-390
-5200

query I rowsort
SELECT DISTINCT + + 5 AS col1 FROM tab1 AS cor0
----
5

query I rowsort
SELECT DISTINCT col0 + col1 * - col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT + 30 + + ( cor0.col0 ) + + col1 * ( - col1 ) * 83 AS col0 FROM tab1 AS cor0
----
-13917
-56075
-8206

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col1 col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + 90 + - cor0.col1 FROM tab1 AS cor0
----
64
77
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8547
SELECT DISTINCT + - col1 + 26 DIV col0 col2 FROM tab2 AS cor0
----
-17
-28
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8547
SELECT DISTINCT + - col1 + 26 / col0 col2 FROM tab2 AS cor0
----
-17
-28
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * - 4 col2 FROM tab2 cor0
----
104
108
152

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8549
SELECT + CAST( + ( col0 ) AS SIGNED ) * ( col1 ) FROM tab2 cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-8549
SELECT + CAST ( + ( col0 ) AS INTEGER ) * ( col1 ) FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - 11 * + cor0.col0 FROM tab1, tab0 AS cor0
----
-264
-385
-979

query I rowsort
SELECT cor0.col2 * col0 * col1 FROM tab0 AS cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 31 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 46 col0 FROM tab0
----
132
137
143

onlyif mysql # use DIV operator for integer division
query I rowsort label-8554
SELECT - 40 DIV cor0.col0 col0 FROM tab1, tab2 cor0
----
9 values hashing to 1fcbd8e011d8d5d4cf6550695ff8e6e1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8554
SELECT - 40 / cor0.col0 col0 FROM tab1, tab2 cor0
----
9 values hashing to 1fcbd8e011d8d5d4cf6550695ff8e6e1

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( ( - tab0.col0 ) * ( - 46 ) AS REAL ) AS col1 FROM tab0
----
1104
1610
4094

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8556
SELECT DISTINCT - 61 * cor0.col1 + CAST( cor0.col2 AS SIGNED ) AS col2 FROM tab0, tab1 AS cor0
----
-1532
-553
-697

skipif mysql # not compatible
query I rowsort label-8556
SELECT DISTINCT - 61 * cor0.col1 + CAST ( cor0.col2 AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0
----
-1532
-553
-697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 80 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT DISTINCT 53 + 48 AS col0 FROM tab2
----
101

query I rowsort
SELECT ALL + - col2 + + 0 * col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - ( + 69 ) FROM tab2 cor0
----
-69
-69
-69

query I rowsort
SELECT DISTINCT - col0 * + col0 + col1 * + 31 FROM tab2 AS cor0
----
-4255
-5714
912

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 93 * + col1 - - col1 col2 FROM tab2 AS cor0
----
1598
2914
5546

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( 11 AS REAL ) * + cor0.col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 60626bb30afb1d7b67b5adf4a3bd745a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 88 col2 FROM tab2
----
1496
2728
5192

query I rowsort
SELECT DISTINCT - 82 AS col0 FROM tab0
----
-82

query I rowsort
SELECT ALL - 7 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT ALL + tab2.col0 * tab2.col2 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 24e20ca2b8a28088cc71698417e1f489

query I rowsort
SELECT - 10 + - cor0.col1 FROM tab1 AS cor0
----
-20
-23
-36

query I rowsort
SELECT DISTINCT cor0.col2 + - col2 * 24 FROM tab2 AS cor0
----
-598
-621
-874

query I rowsort
SELECT - tab1.col2 * 46 FROM tab1, tab0 AS cor0
----
9 values hashing to 28b9691d12ef41d93939a40af02f7604

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col0 * + 20 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 39aa8ee8d93475b24dace78bf39d2c42

onlyif mysql # use DIV operator for integer division
query I rowsort label-8572
SELECT DISTINCT - col0 + + col0 DIV - col2 AS col2 FROM tab1 AS cor0
----
-3
-65
-80

skipif mysql # not compatible
query I rowsort label-8572
SELECT DISTINCT - col0 + + col0 / - col2 AS col2 FROM tab1 AS cor0
----
-3
-65
-80

query I rowsort
SELECT col2 + cor0.col1 * + 90 * + col0 FROM tab2 AS cor0
----
120908
19557
414206

query I rowsort
SELECT - - col0 * ( + cor0.col0 ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - - col2 + - cor0.col1 * - col0 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT 49 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT DISTINCT + 72 FROM tab0, tab1 cor0
----
72

query I rowsort
SELECT + col1 * + 92 FROM tab1 AS cor0
----
1196
2392
920

query I rowsort
SELECT ALL 31 FROM tab0, tab1 cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ( 62 ) FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT + col1 * - 69 AS col1 FROM tab2 AS cor0
----
-1173
-2139
-4071

query I rowsort
SELECT - ( + col0 ) * col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-8583
SELECT - col0 + col1 DIV - cor0.col0 FROM tab1 AS cor0
----
-11
-64
-80

skipif mysql # not compatible
query I rowsort label-8583
SELECT - col0 + col1 / - cor0.col0 FROM tab1 AS cor0
----
-11
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8584
SELECT col0 * CAST( NULL AS DECIMAL ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8584
SELECT col0 * CAST ( NULL AS REAL ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * ( + col0 ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL + col2 + 38 + col2 FROM tab2 AS cor0
----
114
90
92

query I rowsort
SELECT + - ( col2 ) + + 64 AS col1 FROM tab0 AS cor0
----
-18
31
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col2 + + col0 col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT + col1 * - col2 + + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT col2 + - cor0.col0 * col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT + + 13 * col0 AS col0 FROM tab1 AS cor0
----
1040
39
832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8592
SELECT - col0 * - col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8592
SELECT - col0 * - col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 45 AS col2 FROM tab1
----
45

query I rowsort
SELECT cor0.col1 - - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 79300974cd337dec3680ee4f303be693

query I rowsort
SELECT + 41 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT col1 * - col0 + col2 * col2 + col0 FROM tab0
----
-1286
-3359
-951

query I rowsort
SELECT DISTINCT col2 * - col2 + + col1 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT DISTINCT - col2 + + col2 + tab1.col2 AS col0 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8599
SELECT ALL tab2.col1 + col1 * col1 DIV + col1 FROM tab2
----
118
34
62

skipif mysql # not compatible
query I rowsort label-8599
SELECT ALL tab2.col1 + col1 * col1 / + col1 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL - col2 + - col0 + + col2 * + col2 FROM tab1
----
2859
3128
9040

query I rowsort
SELECT col1 + col0 * col1 AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL + cor0.col0 - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + - col1 * + col2 * - col1 - - col1 * - col2 AS col2 FROM tab1 AS cor0
----
14976
35100
5130

query I rowsort
SELECT DISTINCT + + col2 + + cor0.col1 * - col1 AS col0 FROM tab0 AS cor0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-8605
SELECT - col0 DIV - col0 + + col0 * + col2 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-8605
SELECT - col0 / - col0 + + col0 * + col2 FROM tab0 AS cor0
----
36
7299
793

onlyif mysql # use DIV operator for integer division
query I rowsort label-8606
SELECT + cor0.col1 DIV col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8606
SELECT + cor0.col1 / col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT - 81 * col1 - - col2 * col1 FROM tab2
----
-1674
-3245
-731

query I rowsort
SELECT DISTINCT col0 - - col0 AS col0 FROM tab1
----
128
160
6

query I rowsort
SELECT ( - col0 ) * tab2.col1 * col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT - col2 + + col1 - + col2 FROM tab0 AS cor0
----
-73
20
95

query I rowsort
SELECT - col2 * col0 + + cor0.col2 + col0 FROM tab0 AS cor0
----
-7127
-735
1

query I rowsort
SELECT - col0 + col0 + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ( - col0 ) - + col1 * cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
119574
50955
5852

query I rowsort
SELECT + 89 * + col1 - - col0 FROM tab1 cor0
----
1237
2317
954

query I rowsort
SELECT + - 48 + + col0 AS col2 FROM tab2 AS cor0
----
-41
30
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - col1 col1 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-8617
SELECT DISTINCT col1 * + col2 + tab1.col2 DIV col0 FROM tab1
----
1249
1422
570

skipif mysql # not compatible
query I rowsort label-8617
SELECT DISTINCT col1 * + col2 + tab1.col2 / col0 FROM tab1
----
1249
1422
570

query I rowsort
SELECT ALL col2 * + col1 + col0 * + col1 FROM tab1
----
1210
1482
2288

query I rowsort
SELECT ALL col1 * col1 + col2 AS col0 FROM tab2
----
327
3507
988

query I rowsort
SELECT - tab0.col0 * + col1 + col0 * col2 AS col2 FROM tab0
----
-1272
-3360
-801

query I rowsort
SELECT DISTINCT + col2 + - tab2.col0 * - col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT - - col2 + + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 99 col1 FROM tab0 cor0
----
99
99
99

query I rowsort
SELECT 23 * - col1 * col1 FROM tab2 AS cor0
----
-22103
-6647
-80063

query I rowsort
SELECT ALL - + 13 * + col1 FROM tab0 cor0
----
-1118
-1183
-1261

query I rowsort
SELECT ALL + + 96 * col2 FROM tab0 AS cor0
----
3168
7872
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8627
SELECT ALL col0 + + cor0.col2 DIV 79 AS col2 FROM tab1 AS cor0
----
3
64
81

skipif mysql # not compatible
query I rowsort label-8627
SELECT ALL col0 + + cor0.col2 / 79 AS col2 FROM tab1 AS cor0
----
3
64
81

query I rowsort
SELECT col0 * + col1 + col0 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT col1 * - col0 * - tab2.col0 AS col2 FROM tab2
----
106097
1519
358956

query III rowsort
SELECT * FROM tab1 WHERE col1 + + col2 < ( NULL )
----

query I rowsort
SELECT - col1 * + col1 * - col1 AS col0 FROM tab1
----
1000
17576
2197

query I rowsort
SELECT DISTINCT - tab1.col2 * + col2 AS col0 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + tab2.col2 * + col1 + col2 FROM tab2 WHERE NOT col1 / - col0 + col1 + - col1 * + col1 <= NULL
----

query I rowsort
SELECT DISTINCT + + 61 AS col1 FROM tab2, tab1 AS cor0
----
61

query I rowsort
SELECT DISTINCT col0 + col2 + + col0 FROM tab0
----
260
71
81

query I rowsort
SELECT - tab2.col0 - + tab2.col0 AS col2 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT DISTINCT + tab2.col0 * col2 AS col2 FROM tab2
----
189
2028
3002

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT NULL < NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NULL NOT IN ( + col2 + - cor0.col2 / cor0.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - - col2 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + col1 + cor0.col1 + + col1 * - col0 FROM tab0 cor0
----
-1892
-3201
-7917

query I rowsort
SELECT DISTINCT col2 + - col0 AS col2 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8643
SELECT DISTINCT - col0 * col1 + col1 DIV + col0 FROM tab0 cor0
----
-2061
-3393
-8098

skipif mysql # not compatible
query I rowsort label-8643
SELECT DISTINCT - col0 * col1 + col1 / + col0 FROM tab0 cor0
----
-2061
-3393
-8098

query I rowsort
SELECT ALL + col2 * - col0 + col0 - col2 AS col1 FROM tab1 AS cor0
----
-213
-3641
-7696

query I rowsort
SELECT DISTINCT col1 + - col1 + - col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT - col2 * tab2.col2 * + col1 AS col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT col2 + col1 + col2 AS col2 FROM tab2
----
111
85
93

query I rowsort
SELECT ALL col1 * + col2 + col1 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT col2 + col2 - + tab2.col1 AS col0 FROM tab2
----
-7
23
59

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) NOT BETWEEN col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8651
SELECT DISTINCT col0 + col1 DIV col0 AS col1 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-8651
SELECT DISTINCT col0 + col1 / col0 AS col1 FROM tab1
----
11
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col0 * col0 + - col1 col1 FROM tab1
----
-14
4150
6467

onlyif mysql # use DIV operator for integer division
query I rowsort label-8653
SELECT tab2.col1 DIV col0 + col2 * col2 + + col1 AS col0 FROM tab2
----
1461
735
764

skipif mysql # not compatible
query I rowsort label-8653
SELECT tab2.col1 / col0 + col2 * col2 + + col1 AS col0 FROM tab2
----
1461
735
764

query I rowsort
SELECT ALL col1 * - tab0.col0 + col0 * tab0.col2 FROM tab0
----
-1272
-3360
-801

query I rowsort
SELECT + tab0.col0 + tab0.col0 * col0 * tab0.col2 FROM tab0
----
1260
19032
649611

onlyif mysql # use DIV operator for integer division
query I rowsort label-8656
SELECT DISTINCT - ( + col1 ) DIV col1 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8656
SELECT DISTINCT - ( + col1 ) / col1 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + - col0 + + col1 * - ( - col2 ) AS col2 FROM tab1 AS cor0
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col1 * + col2 col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT - 97 * col0 AS col1 FROM tab2 AS cor0
----
-679
-7566
-7663

query I rowsort
SELECT + cor0.col0 - + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT col1 * cor0.col0 + - col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT - 77 AS col0 FROM tab2
----
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 60 col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT ( + tab2.col0 + tab2.col2 ) AS col1 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-8665
SELECT + + cor0.col0 + col2 + - col2 DIV + col1 AS col0 FROM tab2 cor0
----
104
115
34

skipif mysql # not compatible
query I rowsort label-8665
SELECT + + cor0.col0 + col2 + - col2 / + col1 AS col0 FROM tab2 cor0
----
104
115
34

query I rowsort
SELECT + tab2.col1 + + 8 FROM tab2
----
25
39
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-8667
SELECT DISTINCT tab1.col0 + + 46 DIV + 33 AS col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-8667
SELECT DISTINCT tab1.col0 + + 46 / + 33 AS col0 FROM tab1
----
4
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - + ( + 85 + col1 ) col1 FROM tab2
----
-118
-64
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8669
SELECT col0 + col2 + 7 DIV col2 AS col0 FROM tab1
----
121
176
57

skipif mysql # not compatible
query I rowsort label-8669
SELECT col0 + col2 + 7 / col2 AS col0 FROM tab1
----
121
176
57

query I rowsort
SELECT 49 + col2 AS col2 FROM tab1 AS cor0
----
103
106
145

query I rowsort
SELECT + cor0.col0 + col2 * cor0.col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - - ( - 68 ) AS col0 FROM tab0 AS cor0
----
-68
-68
-68

query I rowsort
SELECT tab0.col0 + - 67 FROM tab0
----
-32
-43
22

query I rowsort
SELECT DISTINCT col0 * col2 * col2 + + col2 AS col0 FROM tab0
----
26169
36
598518

query I rowsort
SELECT DISTINCT col2 * 49 * + col0 + col2 + ( - col1 ) * + tab0.col2 AS col0 FROM tab0
----
1619
350222
36003

query I rowsort
SELECT col1 * col1 * + 9 FROM tab0
----
66564
74529
84681

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8677
SELECT + col0 + - CAST( + col1 * col0 AS SIGNED ) col1 FROM tab1
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8677
SELECT + col0 + - CAST ( + col1 * col0 AS INTEGER ) col1 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8678
SELECT DISTINCT col2 * + col1 + col1 DIV col1 FROM tab1
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-8678
SELECT DISTINCT col2 * + col1 + col1 / col1 FROM tab1
----
1249
1405
571

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 8 * 66 col0 FROM tab1
----
-528

query I rowsort
SELECT ALL col1 * + ( col1 ) * + col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT - col1 * + 60 FROM tab1
----
-1560
-600
-780

query I rowsort
SELECT DISTINCT - + col2 * + 10 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT ALL - col0 + col0 * + col0 * - col1 FROM tab0 AS cor0
----
-118860
-49560
-720900

query I rowsort
SELECT DISTINCT + col1 + 39 - col1 FROM tab2 AS cor0
----
39

query I rowsort
SELECT - + col1 + 57 AS col2 FROM tab1 AS cor0
----
31
44
47

query I rowsort
SELECT - ( col2 ) * + col0 + - col2 AS col0 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT col1 + col2 * col2 AS col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT + - col1 + - col0 + col0 * + ( col1 ) FROM tab0 AS cor0
----
1954
3263
7919

query I rowsort
SELECT DISTINCT + + cor0.col0 - col0 * - col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + + 71 * - col1 + + col2 FROM tab1 AS cor0
----
-1792
-653
-827

onlyif mysql # use DIV operator for integer division
query I rowsort label-8691
SELECT ALL - 99 DIV + cor0.col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-14

skipif mysql # not compatible
query I rowsort label-8691
SELECT ALL - 99 / + cor0.col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-14

query I rowsort
SELECT 26 * - 9 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 451e0ad0736f230bf619c5934cafd167

onlyif mysql # use DIV operator for integer division
query I rowsort label-8693
SELECT DISTINCT + ( col2 ) * - col2 DIV - col2 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8693
SELECT DISTINCT + ( col2 ) * - col2 / - col2 AS col0 FROM tab0
----
1
33
82

query I rowsort
SELECT col0 + - col2 * col2 AS col0 FROM tab2 cor0
----
-1365
-598
-722

query I rowsort
SELECT - - col1 + cor0.col1 * + cor0.col1 + + ( col0 * + col0 + + 70 ) FROM tab1 AS cor0
----
4276
6652
781

query I rowsort
SELECT ( + 69 * col0 ) AS col2 FROM tab1
----
207
4416
5520

query I rowsort
SELECT - cor0.col2 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-8698
SELECT 77 + - col2 DIV - col2 AS col0 FROM tab1 AS cor0
----
78
78
78

skipif mysql # not compatible
query I rowsort label-8698
SELECT 77 + - col2 / - col2 AS col0 FROM tab1 AS cor0
----
78
78
78

query I rowsort
SELECT ALL - cor1.col2 AS col0 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + - col0 col2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - 89 * - col0 + - ( + cor0.col2 ) FROM tab1 AS cor0
----
213
5639
7024

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * col1 col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-8703
SELECT - 72 * col1 + - col1 DIV - 43 AS col0 FROM tab2 cor0
----
-1224
-2232
-4247

skipif mysql # not compatible
query I rowsort label-8703
SELECT - 72 * col1 + - col1 / - 43 AS col0 FROM tab2 cor0
----
-1224
-2232
-4247

query I rowsort
SELECT ALL + col2 + ( + col1 ) + - col0 * cor0.col1 FROM tab2 AS cor0
----
-1288
-159
-4517

query I rowsort
SELECT ALL + col1 + - col0 * 9 AS col2 FROM tab0 cor0
----
-130
-218
-710

query I rowsort
SELECT DISTINCT + - col1 * col0 * col2 - - col2 AS col2 FROM tab2 cor0
----
-119626
-50996
-5832

query I rowsort
SELECT DISTINCT + col0 * col1 + + 17 * col1 FROM tab0 AS cor0
----
3526
5044
9646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col0 col2 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8709
SELECT DISTINCT col1 - + CAST( + col2 * + col1 AS SIGNED ) FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-8709
SELECT DISTINCT col1 - + CAST ( + col2 * + col1 AS INTEGER ) FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL col0 * + ( - col2 ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8711
SELECT DISTINCT - + col1 * col2 + col1 DIV + col1 FROM tab2 AS cor0
----
-1533
-645
-836

skipif mysql # not compatible
query I rowsort label-8711
SELECT DISTINCT - + col1 * col2 + col1 / + col1 FROM tab2 AS cor0
----
-1533
-645
-836

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8712
SELECT + cor0.col1 * - CAST( 75 AS SIGNED ) FROM tab1 AS cor0
----
-1950
-750
-975

skipif mysql # not compatible
query I rowsort label-8712
SELECT + cor0.col1 * - CAST ( 75 AS INTEGER ) FROM tab1 AS cor0
----
-1950
-750
-975

onlyif mysql # use DIV operator for integer division
query I rowsort label-8713
SELECT + - cor0.col2 + cor0.col2 DIV - 81 FROM tab0, tab0 AS cor0
----
9 values hashing to 4a80871dd55c8ede89a910629bcb20c9

skipif mysql # not compatible
query I rowsort label-8713
SELECT + - cor0.col2 + cor0.col2 / - 81 FROM tab0, tab0 AS cor0
----
9 values hashing to 4a80871dd55c8ede89a910629bcb20c9

query I rowsort
SELECT ALL - 48 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT ALL col1 * cor0.col2 * col0 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-8716
SELECT ALL - col2 DIV + ( col1 * col2 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8716
SELECT ALL - col2 / + ( col1 * col2 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col2 * col1 * col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT + col1 * 89 + + col1 FROM tab2 AS cor0
----
1530
2790
5310

onlyif mysql # use DIV operator for integer division
query I rowsort label-8719
SELECT - col0 * - col2 DIV col2 + col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
105
267
72

skipif mysql # not compatible
query I rowsort label-8719
SELECT - col0 * - col2 / col2 + col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
105
267
72

query I rowsort
SELECT ALL col2 + - 4 FROM tab0 cor0
----
-3
29
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8721
SELECT DISTINCT - col0 + + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-8721
SELECT DISTINCT - col0 + + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - col1 + 1 * - col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + cor0.col2 + - 14 AS col1 FROM tab2 AS cor0
----
12
13
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col1 * - 52 col0 FROM tab2
----
15028
181012
49972

query I rowsort
SELECT col2 + ( + 38 + + col0 ) * col0 * col0 FROM tab2 AS cor0
----
2232
705770
730235

query I rowsort
SELECT cor0.col2 * + ( - col0 ) FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8727
SELECT ALL col1 + CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8727
SELECT ALL col1 + CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8728
SELECT ALL 48 DIV + 16 AS col1 FROM tab0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-8728
SELECT ALL 48 / + 16 AS col1 FROM tab0
----
3
3
3

query I rowsort
SELECT - 1 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT DISTINCT col0 * col1 + col2 - 3 AS col2 FROM tab1
----
1133
129
694

query I rowsort
SELECT DISTINCT tab1.col2 - + col2 AS col1 FROM tab1
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8732
SELECT DISTINCT - col1 * col1 - CAST( col2 AS SIGNED ) AS col0 FROM tab0
----
-7429
-8363
-9410

skipif mysql # not compatible
query I rowsort label-8732
SELECT DISTINCT - col1 * col1 - CAST ( col2 AS INTEGER ) AS col0 FROM tab0
----
-7429
-8363
-9410

query I rowsort
SELECT + ( - col1 ) * + 16 * + 17 + + col1 AS col2 FROM tab0 AS cor0
----
-23306
-24661
-26287

query I rowsort
SELECT + + 46 * + col2 - 92 FROM tab2 AS cor0
----
1104
1150
1656

query I rowsort
SELECT col1 * + col1 - - col1 * 66 AS col2 FROM tab2
----
1411
3007
7375

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 46 col1 FROM tab0 cor0
----
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8737
SELECT ( - cor0.col0 ) + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8737
SELECT ( - cor0.col0 ) + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * col2 * cor0.col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL - 77 * col2 + + cor0.col2 FROM tab2 AS cor0
----
-1976
-2052
-2888

query I rowsort
SELECT ALL + col2 * + col2 * cor0.col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL - - col2 * - ( - 15 ) * col0 AS col0 FROM tab1 cor0
----
115200
2430
54720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8742
SELECT DISTINCT - + col0 + CAST( - 23 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-101
-102
-30

skipif mysql # not compatible
query I rowsort label-8742
SELECT DISTINCT - + col0 + CAST ( - 23 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-101
-102
-30

query I rowsort
SELECT col1 - col2 AS col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL col2 + 60 + - col1 AS col2 FROM tab1
----
107
143
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-8745
SELECT + col0 DIV 67 + 54 * - col1 + 76 AS col0 FROM tab2 AS cor0
----
-1598
-3109
-841

skipif mysql # not compatible
query I rowsort label-8745
SELECT + col0 / 67 + 54 * - col1 + 76 AS col0 FROM tab2 AS cor0
----
-1598
-3109
-841

query I rowsort
SELECT + col1 * + col1 + - cor0.col2 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT DISTINCT - - col1 * col1 + col0 * - col2 FROM tab2 AS cor0
----
-2713
1453
772

query I rowsort
SELECT DISTINCT + + col0 + - ( col0 ) AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - - col1 + + col2 * col2 AS col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL + 20 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT - + 6 FROM tab2 cor0
----
-6
-6
-6

query I rowsort
SELECT - cor0.col0 + 45 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b799d8e7c6a95baa4b526afe6568dc3

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL + ( 36 ) AS col0 FROM tab1 cor0
----
36
36
36

query I rowsort
SELECT - 85 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8ebc8ffafb1517ea04e3a6fc4059d88a

query I rowsort
SELECT + - 74 AS col1 FROM tab0 AS cor0
----
-74
-74
-74

query I rowsort
SELECT + + 72 AS col2 FROM tab2 cor0
----
72
72
72

query I rowsort
SELECT DISTINCT + 41 + col1 AS col1 FROM tab2 AS cor0
----
100
58
72

query I rowsort
SELECT ALL 15 AS col1 FROM tab1 AS cor0
----
15
15
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-8760
SELECT DISTINCT ( col2 ) DIV + col0 + col1 * + 46 AS col2 FROM tab0 cor0
----
3957
4186
4462

skipif mysql # not compatible
query I rowsort label-8760
SELECT DISTINCT ( col2 ) / + col0 + col1 * + 46 AS col2 FROM tab0 cor0
----
3957
4186
4462

query I rowsort
SELECT ( - col1 ) + + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + ( - col1 ) + col0 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + - 59 + col2 * - col0 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-233531
-545
-614459

query I rowsort
SELECT DISTINCT + + 98 * col1 FROM tab1 cor0
----
1274
2548
980

query I rowsort
SELECT DISTINCT - col2 * - cor0.col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8766
SELECT ALL 42 * col2 + + CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
1151
1165
1613

skipif mysql # not compatible
query I rowsort label-8766
SELECT ALL 42 * col2 + + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
1151
1165
1613

query I rowsort
SELECT ALL - - 8 + - col0 * col0 FROM tab1 AS cor0
----
-1
-4088
-6392

query I rowsort
SELECT DISTINCT + - ( col1 ) * - col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL 15 + col1 FROM tab1 AS cor0
----
25
28
41

query I rowsort
SELECT - 18 * col2 + - col0 FROM tab1
----
-1090
-1808
-975

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 cor2
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

query I rowsort
SELECT 24 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT DISTINCT + + 25 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
25

query I rowsort
SELECT + col1 * + 7 + + col2 FROM tab1 AS cor0
----
127
187
236

query I rowsort
SELECT + + col1 + cor0.col2 * - 26 - cor0.col0 FROM tab1 AS cor0
----
-1381
-1536
-2563

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 8 + ( + col0 ) col2 FROM tab2 AS cor0
----
215
255
550

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT + + col0 + - 32 AS col2 FROM tab1 AS cor0
----
-29
32
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-8779
SELECT + col0 DIV - 23 + col0 AS col2 FROM tab0 cor0
----
23
34
86

skipif mysql # not compatible
query I rowsort label-8779
SELECT + col0 / - 23 + col0 AS col2 FROM tab0 cor0
----
23
34
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-8780
SELECT + 90 + ( col0 ) DIV + 45 AS col0 FROM tab0 cor0
----
90
90
91

skipif mysql # not compatible
query I rowsort label-8780
SELECT + 90 + ( col0 ) / + 45 AS col0 FROM tab0 cor0
----
90
90
91

query I rowsort
SELECT ALL + - cor0.col0 * - col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-8782
SELECT + col2 + - col1 DIV 21 FROM tab0
----
-3
29
78

skipif mysql # not compatible
query I rowsort label-8782
SELECT + col2 + - col1 / 21 FROM tab0
----
-3
29
78

query I rowsort
SELECT + 15 FROM tab1, tab1 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT 19 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

onlyif mysql # use DIV operator for integer division
query I rowsort label-8785
SELECT - - col1 DIV + col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8785
SELECT - - col1 / + col0 FROM tab0 cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col1 + col0 col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL - - col2 + col1 * col0 + col0 * col0 FROM tab1 AS cor0
----
141
4793
7536

query I rowsort
SELECT ALL ( + col2 + - 89 ) FROM tab0
----
-56
-7
-88

query I rowsort
SELECT - 43 * + col2 - + 49 FROM tab1 AS cor0
----
-2371
-2500
-4177

query I rowsort
SELECT col2 + col1 * 9 * 86 AS col0 FROM tab2 AS cor0
----
13196
24021
45692

skipif mysql # not compatible
query I rowsort
SELECT + + col0 * col0 - - CAST ( - col1 AS REAL ) AS col2 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT + col0 * - col0 - - 93 * - col2 AS col2 FROM tab0 AS cor0
----
-1318
-15547
-3645

query I rowsort
SELECT col0 + + 44 * + 0 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + 93 + col0 AS col2 FROM tab0
----
117
128
182

query I rowsort
SELECT - 26 * - tab1.col0 AS col0 FROM tab1
----
1664
2080
78

query I rowsort
SELECT - col1 + - 53 + 22 AS col1 FROM tab1 AS cor0
----
-41
-44
-57

query I rowsort
SELECT - col0 * + cor0.col0 * + col1 + - col1 AS col0 FROM tab2 AS cor0
----
-106114
-1550
-359015

query I rowsort
SELECT col0 * col2 + + 54 * cor0.col1 FROM tab1 AS cor0
----
1566
4188
8382

query I rowsort
SELECT ALL ( - col1 ) * - ( 53 ) + col2 * col1 AS col0 FROM tab0
----
12285
5238
7396

query I rowsort
SELECT tab0.col0 * + 70 * - tab0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8d0ec12283be06b82accbd1c19abdce3

query I rowsort
SELECT - 67 * col1 FROM tab2
----
-1139
-2077
-3953

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8802
SELECT - col0 + + col2 + CAST( + tab2.col1 AS SIGNED ) FROM tab2
----
-24
51
7

skipif mysql # not compatible
query I rowsort label-8802
SELECT - col0 + + col2 + CAST ( + tab2.col1 AS INTEGER ) FROM tab2
----
-24
51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8803
SELECT - col0 - 35 DIV 74 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8803
SELECT - col0 - 35 / 74 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - 5 + cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to a791f1a4d7745e253681715daa18079c

query I rowsort
SELECT col0 * - col2 - col1 * - col0 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT + col2 * + 75 + - col2 AS col1 FROM tab2 AS cor0
----
1924
1998
2812

query I rowsort
SELECT - col0 - + cor0.col1 * - 16 * + col2 FROM tab0 AS cor0
----
119303
1517
45384

onlyif mysql # use DIV operator for integer division
query I rowsort label-8808
SELECT DISTINCT + col1 DIV + 71 AS col0 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8808
SELECT DISTINCT + col1 / + 71 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - cor0.col0 * col2 AS col1 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( - col0 ) * col2 + 26 col0 FROM tab1 AS cor0
----
-136
-3622
-7654

onlyif mysql # use DIV operator for integer division
query I rowsort label-8811
SELECT ALL ( + ( col0 ) ) + - col2 * col0 DIV col1 FROM tab1 AS cor0
----
-3
-300
-510

skipif mysql # not compatible
query I rowsort label-8811
SELECT ALL ( + ( col0 ) ) + - col2 * col0 / col1 FROM tab1 AS cor0
----
-3
-300
-510

query I rowsort
SELECT + tab2.col1 - + tab2.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 023677f2362ebf8bd60cb629f4090df4

query I rowsort
SELECT DISTINCT col1 * col1 - col0 FROM tab2
----
210
3403
954

query I rowsort
SELECT ALL 88 * cor0.col1 + 68 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to eecbc268432af231753de8f8f5a64110

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to a5677c50b23f70287df35c2388a1c9bf

query I rowsort
SELECT DISTINCT col1 * + 10 FROM tab2
----
170
310
590

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8817
SELECT col1 + CAST( NULL AS DECIMAL ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8817
SELECT col1 + CAST ( NULL AS REAL ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 59 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT DISTINCT tab2.col1 * - tab2.col0 * + tab2.col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT - ( ( + col2 ) ) FROM tab2
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-8821
SELECT - ( - col2 ) DIV 50 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8821
SELECT - ( - col2 ) / 50 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + 93 * col2 AS col0 FROM tab1 cor0
----
5022
5301
8928

onlyif mysql # use DIV operator for integer division
query I rowsort label-8823
SELECT col0 * col1 DIV + col1 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8823
SELECT col0 * col1 / + col1 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - cor0.col0 + + col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - 34 + 99 FROM tab1
----
65
65
65

query I rowsort
SELECT ALL + 77 + - col2 FROM tab1 AS cor0
----
-19
20
23

query I rowsort
SELECT DISTINCT + 98 * col2 * col2 AS col2 FROM tab2 AS cor0
----
141512
66248
71442

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8828
SELECT DISTINCT + ( col2 ) + + col2 * CAST( + col2 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
1146
37
6895

skipif mysql # not compatible
query I rowsort label-8828
SELECT DISTINCT + ( col2 ) + + col2 * CAST ( + col2 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
1146
37
6895

query I rowsort
SELECT DISTINCT + + col0 * col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT col0 + ( + col2 ) * + 45 AS col1 FROM tab2 AS cor0
----
1222
1248
1789

skipif mysql # not compatible
query I rowsort
SELECT - - col1 + col1 - + CAST ( col2 AS REAL ) FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT ALL - 79 * + col2 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT col0 + col2 + - col2 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 + 44 col0 FROM tab2 AS cor0
----
1005
333
3525

onlyif mysql # use DIV operator for integer division
query I rowsort label-8835
SELECT ALL - col0 DIV - col0 - col0 * col0 AS col2 FROM tab2
----
-48
-6083
-6240

skipif mysql # not compatible
query I rowsort label-8835
SELECT ALL - col0 / - col0 - col0 * col0 AS col2 FROM tab2
----
-48
-6083
-6240

query I rowsort
SELECT DISTINCT 58 + ( - col0 * + col2 ) - - col2 AS col1 FROM tab1
----
-3533
-50
-7526

query I rowsort
SELECT + col2 * cor0.col1 + ( cor0.col1 + - col0 ) FROM tab0 cor0
----
159
2900
7464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 82 * cor0.col0 col0 FROM tab2 cor0
----
-574
-6396
-6478

onlyif mysql # use DIV operator for integer division
query I rowsort label-8839
SELECT DISTINCT + + col2 DIV col1 + col2 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-8839
SELECT DISTINCT + + col2 / col1 + col2 FROM tab2 AS cor0
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 8 - - col0 * + col1 col2 FROM tab0
----
2072
3403
8107

query I rowsort
SELECT DISTINCT col2 - - col1 * 52 AS col1 FROM tab1 AS cor0
----
1406
577
772

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + col1 col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL - - col0 * 0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - cor0.col1 * + col2 + col2 * + col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT ALL - col0 * - col0 - col2 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT ALL col2 * - ( col1 + col1 * col1 ) FROM tab0 AS cor0
----
-246906
-686504
-9506

query I rowsort
SELECT - cor0.col2 + 49 FROM tab0 cor0
----
-33
16
48

query I rowsort
SELECT DISTINCT + col1 * 20 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT DISTINCT - col1 + + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8850
SELECT ALL - CAST( NULL AS SIGNED ) + - 61 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8850
SELECT ALL - CAST ( NULL AS INTEGER ) + - 61 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8851
SELECT col2 * col0 DIV + 42 - col1 * col1 AS col1 FROM tab1
----
-14
-673
13

skipif mysql # not compatible
query I rowsort label-8851
SELECT col2 * col0 / + 42 - col1 * col1 AS col1 FROM tab1
----
-14
-673
13

query I rowsort
SELECT col0 + ( - 70 ) AS col2 FROM tab1
----
-6
-67
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col1 col0 FROM tab2
----
137
38
96

query I rowsort
SELECT + - 70 + 80 AS col2 FROM tab1 cor0
----
10
10
10

query I rowsort
SELECT col2 - 3 FROM tab1
----
51
54
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8856
SELECT ALL col1 - col1 DIV + col1 FROM tab2 cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-8856
SELECT ALL col1 - col1 / + col1 FROM tab2 cor0
----
16
30
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8857
SELECT ALL - CAST( NULL AS SIGNED ) * 91 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8857
SELECT ALL - CAST ( NULL AS INTEGER ) * 91 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + cor0.col0 + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL + col2 - + 78 FROM tab2 AS cor0
----
-40
-51
-52

query I rowsort
SELECT DISTINCT 86 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
86

query I rowsort
SELECT DISTINCT col0 * - 38 AS col2 FROM tab2
----
-266
-2964
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT ALL 5 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT DISTINCT + tab2.col1 * + tab2.col0 + + 16 AS col0 FROM tab2, tab0 AS cor0
----
1359
233
4618

query I rowsort
SELECT - ( + 82 ) * + col2 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT ALL + + col0 * + 45 FROM tab1 AS cor0
----
135
2880
3600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8867
SELECT DISTINCT + col2 + - col2 + col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8867
SELECT DISTINCT + col2 + - col2 + col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * + col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-8869
SELECT tab2.col0 DIV 38 FROM tab2, tab0 cor0
----
9 values hashing to dcf0bdb0a33a97c73a81c5b823899d40

skipif mysql # not compatible
query I rowsort label-8869
SELECT tab2.col0 / 38 FROM tab2, tab0 cor0
----
9 values hashing to dcf0bdb0a33a97c73a81c5b823899d40

query I rowsort
SELECT + 14 * 11 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 7cf925cdea37533e5028b2ea0c580358

onlyif mysql # use DIV operator for integer division
query I rowsort label-8871
SELECT DISTINCT - 57 DIV + col1 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-8871
SELECT DISTINCT - 57 / + col1 FROM tab2 AS cor0
----
-1
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8872
SELECT DISTINCT - col1 * - col0 + col1 DIV col2 AS col2 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-8872
SELECT DISTINCT - col1 * - col0 + col1 / col2 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT - - col2 + col2 - col0 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT ALL 17 + - col2 FROM tab0 cor0
----
-16
-65
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 + 58 * - col1 col2 FROM tab2
----
-1802
-3455
-965

query I rowsort
SELECT col1 * col0 + ( ( tab2.col1 ) ) + + 63 FROM tab2
----
1423
311
4724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 33 col1 FROM tab0 AS cor0
----
2838
3003
3201

query I rowsort
SELECT ALL + col1 * 56 FROM tab1 AS cor0
----
1456
560
728

query I rowsort
SELECT - + col1 + - col2 * + col1 * + col2 AS col2 FROM tab2 AS cor0
----
-22630
-24565
-39943

query I rowsort
SELECT DISTINCT - col2 * - col2 * + col1 AS col1 FROM tab1 cor0
----
119808
32490
75816

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - 11 AS REAL ) FROM tab0, tab2 AS cor0
----
-11

onlyif mysql # use DIV operator for integer division
query I rowsort label-8882
SELECT cor1.col1 DIV + cor1.col1 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8882
SELECT cor1.col1 / + cor1.col1 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8883
SELECT ALL - col1 DIV ( + cor0.col2 ) + - cor0.col1 * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-8883
SELECT ALL - col1 / ( + cor0.col2 ) + - cor0.col1 * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL + col2 + ( + ( - col1 ) ) AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL col0 * + 9 AS col0 FROM tab0 AS cor0
----
216
315
801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8886
SELECT ALL CAST( NULL AS SIGNED ) * + 61 + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8886
SELECT ALL CAST ( NULL AS INTEGER ) * + 61 + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col0 * + col1 col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT - ( - col0 ) * - col1 * + 17 AS col1 FROM tab2
----
-22831
-3689
-78234

query I rowsort
SELECT col2 * + col0 - + col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8890
SELECT ALL - CAST( - col1 AS SIGNED ) * + col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-8890
SELECT ALL - CAST ( - col1 AS INTEGER ) * + col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + col0 + 78 + + col1 * 91 FROM tab2 AS cor0
----
1546
2892
5369

query I rowsort
SELECT ALL + - 56 AS col1 FROM tab0 cor0
----
-56
-56
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-8893
SELECT DISTINCT col1 DIV - ( + col0 ) FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-8893
SELECT DISTINCT col1 / - ( + col0 ) FROM tab0
----
-1
-2
-3

query I rowsort
SELECT - 79 * + 7 FROM tab2
----
-553
-553
-553

query I rowsort
SELECT DISTINCT - 58 FROM tab1, tab1 cor0, tab2 AS cor1
----
-58

query I rowsort
SELECT DISTINCT 44 * tab2.col1 AS col2 FROM tab2
----
1364
2596
748

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8897
SELECT col1 + col2 + + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8897
SELECT col1 + col2 + + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT col1 * col0 + CAST ( + 81 AS REAL ) + + col2 FROM tab2 AS cor0
----
1462
325
4709

query I rowsort
SELECT DISTINCT - col1 * + tab1.col0 * + col0 AS col1 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT + + 28 + - col1 + - col2 FROM tab0 cor0
----
-145
-70
-91

query I rowsort
SELECT DISTINCT + 80 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
80

query I rowsort
SELECT - col0 * + 91 + + col0 * - col1 AS col1 FROM tab2
----
-11700
-8532
-854

query I rowsort
SELECT DISTINCT - col0 * col2 + col2 * + col2 AS col0 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT + col2 * - ( - col1 ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + col1 * ( col2 ) + + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + 2 * + 4 * - col1 AS col2 FROM tab1 AS cor0
----
-104
-208
-80

query I rowsort
SELECT - + col0 + col1 * - col1 FROM tab1 cor0
----
-164
-249
-679

query I rowsort
SELECT + ( ( - col1 ) ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + ( + 88 ) * col2 AS col1 FROM tab1 AS cor0
----
4752
5016
8448

query I rowsort
SELECT col0 * ( - col0 ) AS col2 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT + cor0.col1 * col2 + - col2 + ( col2 ) * col1 AS col1 FROM tab0 AS cor0
----
14842
193
5643

query I rowsort
SELECT DISTINCT - 7 + col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
42
6077
6234

query I rowsort
SELECT + + col2 * - 90 AS col2 FROM tab2 AS cor0
----
-2340
-2430
-3420

query I rowsort
SELECT DISTINCT - 80 * col0 FROM tab0 AS cor0
----
-1920
-2800
-7120

query I rowsort
SELECT - - 31 * col1 FROM tab2 AS cor0
----
1829
527
961

query I rowsort
SELECT ALL - + 67 * + col1 FROM tab1 AS cor0
----
-1742
-670
-871

query I rowsort
SELECT - 10 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8918
SELECT ALL col2 DIV ( + col1 ) AS col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-8918
SELECT ALL col2 / ( + col1 ) AS col0 FROM tab2
----
0
0
2

query I rowsort
SELECT ( + ( col0 ) ) FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8921
SELECT CAST( NULL AS SIGNED ) + + col0 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-8921
SELECT CAST ( NULL AS INTEGER ) + + col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 27 + col2 AS col2 FROM tab1 AS cor0
----
123
81
84

query I rowsort
SELECT 21 * cor0.col0 - - cor0.col0 AS col0 FROM tab2 AS cor0
----
154
1716
1738

query I rowsort
SELECT ALL + 71 + col2 FROM tab1 AS cor0
----
125
128
167

onlyif mysql # use DIV operator for integer division
query I rowsort label-8925
SELECT DISTINCT 76 + - col2 DIV - col0 FROM tab1 AS cor0
----
76
77
94

skipif mysql # not compatible
query I rowsort label-8925
SELECT DISTINCT 76 + - col2 / - col0 FROM tab1 AS cor0
----
76
77
94

query I rowsort
SELECT 38 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT ALL - 28 + cor0.col0 + col1 FROM tab1 AS cor0
----
1
46
65

query I rowsort
SELECT DISTINCT + + 99 * - col0 * + cor0.col0 FROM tab2 cor0
----
-4851
-602316
-617859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 68 + col1 col0 FROM tab0 AS cor0
----
154
159
165

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8930
SELECT ALL CAST( + col1 AS SIGNED ) * - tab1.col1 AS col0 FROM tab1
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-8930
SELECT ALL CAST ( + col1 AS INTEGER ) * - tab1.col1 AS col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT col2 * - 9 AS col2 FROM tab1 AS cor0
----
-486
-513
-864

query I rowsort
SELECT - + col2 * - cor0.col1 + cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-8933
SELECT col2 DIV + col0 + col2 AS col0 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-8933
SELECT col2 / + col0 + col2 AS col0 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT ALL col0 * - col0 * tab0.col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT + cor1.col1 * cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
7396
7826
8281
8342
8827
9409

query I rowsort
SELECT ALL + 97 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col2 FROM tab2, tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8938
SELECT - - col2 + ( 84 + col1 ) DIV col0 col1 FROM tab0 AS cor0
----
40
6
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8938
SELECT - - col2 + ( 84 + col1 ) / col0 col1 FROM tab0 AS cor0
----
40
6
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8939
SELECT ALL 32 * col1 DIV + col0 FROM tab2
----
141
24
6

skipif mysql # not compatible
query I rowsort label-8939
SELECT ALL 32 * col1 / + col0 FROM tab2
----
141
24
6

query I rowsort
SELECT ( - col2 ) - col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL - col0 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT cor0.col1 + - ( col1 ) * col0 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8943
SELECT ALL - col1 * CAST( col2 AS SIGNED ) + + col2 * 25 col0 FROM tab2 cor0
----
-162
-884
304

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8943
SELECT ALL - col1 * CAST ( col2 AS INTEGER ) + + col2 * 25 col0 FROM tab2 cor0
----
-162
-884
304

query I rowsort
SELECT - col0 * 8 FROM tab2 AS cor0
----
-56
-624
-632

query I rowsort
SELECT ALL col2 * + 46 AS col2 FROM tab2 AS cor0
----
1196
1242
1748

query I rowsort
SELECT DISTINCT cor0.col0 + col1 * 28 AS col2 FROM tab1 cor0
----
344
444
731

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col1 col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8948
SELECT col0 * - CAST( + 76 AS SIGNED ) FROM tab1 AS cor0
----
-228
-4864
-6080

skipif mysql # not compatible
query I rowsort label-8948
SELECT col0 * - CAST ( + 76 AS INTEGER ) FROM tab1 AS cor0
----
-228
-4864
-6080

query I rowsort
SELECT DISTINCT - 79 FROM tab1, tab0, tab1 AS cor0
----
-79

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-8951
SELECT ALL + - col2 DIV - col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8951
SELECT ALL + - col2 / - col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + - cor0.col2 * 8 FROM tab0 AS cor0
----
-264
-656
-8

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + col0 * col1 FROM tab0 AS cor0
----
16198
4128
6790

query I rowsort
SELECT - col1 * col2 + - col0 * 82 FROM tab2 AS cor0
----
-1411
-7124
-7930

query I rowsort
SELECT DISTINCT + + 86 + 51 AS col2 FROM tab1 AS cor0
----
137

query I rowsort
SELECT DISTINCT - + 67 AS col1 FROM tab1 AS cor0
----
-67

query I rowsort
SELECT ALL + 25 + col1 * col0 AS col0 FROM tab0 AS cor0
----
2089
3420
8124

query I rowsort
SELECT ( - col0 ) * col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col1 + - col0 * + col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8960
SELECT DISTINCT CAST( col1 AS SIGNED ) + - col1 AS col2 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-8960
SELECT DISTINCT CAST ( col1 AS INTEGER ) + - col1 AS col2 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT ( + 6 ) * + cor0.col2 FROM tab2 AS cor0
----
156
162
228

query I rowsort
SELECT - col2 + + 32 FROM tab1 cor0
----
-22
-25
-64

query I rowsort
SELECT - cor0.col1 * + col2 + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + 24 * col0 * col2 AS col2 FROM tab2 AS cor0
----
4536
48672
72048

query I rowsort
SELECT DISTINCT + + cor0.col2 + col1 + 24 AS col0 FROM tab2 cor0
----
109
79
82

query I rowsort
SELECT 1 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 69 * col0 AS col0 FROM tab2 cor0
----
-483
-5382
-5451

query I rowsort
SELECT ALL - 33 + 61 * col1 FROM tab2
----
1004
1858
3566

query I rowsort
SELECT + cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 3 + col2 * - col2 - 93 col1 FROM tab1 AS cor0
----
-3006
-3339
-9306

query I rowsort
SELECT + cor0.col1 + col0 * + col1 AS col2 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL 1 * col2 + + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + + cor0.col0 + col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - 95 AS col0 FROM tab2 cor0
----
-95
-95
-95

query I rowsort
SELECT + + 90 + + col2 FROM tab2 AS cor0
----
116
117
128

query I rowsort
SELECT 60 * - col2 + + col1 FROM tab2 AS cor0
----
-1501
-1589
-2263

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 col2 FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT 47 + col1 AS col2 FROM tab0
----
133
138
144

query I rowsort
SELECT DISTINCT col2 + 66 AS col0 FROM tab2
----
104
92
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8980
SELECT DISTINCT + 49 * - cor0.col1 + - 27 * col1 + col0 DIV - 27 AS col1 FROM tab0 AS cor0
----
-6536
-6919
-7373

skipif mysql # not compatible
query I rowsort label-8980
SELECT DISTINCT + 49 * - cor0.col1 + - 27 * col1 + col0 / - 27 AS col1 FROM tab0 AS cor0
----
-6536
-6919
-7373

query I rowsort
SELECT ALL - + cor0.col2 + col2 - - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + - 35 AS col2 FROM tab1 AS cor0
----
-35

query I rowsort
SELECT col1 * - col1 + 8 FROM tab2 AS cor0
----
-281
-3473
-953

query I rowsort
SELECT ALL + col0 + - col0 * col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT + - col2 * + col0 - col0 AS col2 FROM tab0 cor0
----
-70
-7387
-816

query I rowsort
SELECT + - ( - 16 ) + - col2 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
113
2854
7478

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8987
SELECT col2 + CAST( + col0 AS SIGNED ) + col0 * tab1.col2 FROM tab1
----
219
3769
7856

skipif mysql # not compatible
query I rowsort label-8987
SELECT col2 + CAST ( + col0 AS INTEGER ) + col0 * tab1.col2 FROM tab1
----
219
3769
7856

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8988
SELECT - col2 * + CAST( 1 AS SIGNED ) AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8988
SELECT - col2 * + CAST ( 1 AS INTEGER ) AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - 90 * tab1.col1 * + col0 AS col0 FROM tab1
----
-57600
-7020
-93600

query I rowsort
SELECT DISTINCT ( col1 * col0 ) + col2 AS col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT + col0 * col1 + col2 + - 82 AS col1 FROM tab0
----
2015
3314
8099

query I rowsort
SELECT - col2 + + col0 + col0 AS col0 FROM tab1
----
-48
64
71

query I rowsort
SELECT DISTINCT - ( - col2 ) + - col2 FROM tab2
----
0

query I rowsort
SELECT ALL + 44 * col2 + - tab0.col1 AS col2 FROM tab0
----
-53
1366
3517

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( - ( col0 ) ) * 22 - col2 col2 FROM tab1 AS cor0
----
-120
-1465
-1856

query I rowsort
SELECT + 44 + col2 AS col0 FROM tab0 AS cor0
----
126
45
77

query I rowsort
SELECT ALL - + 95 + col0 AS col1 FROM tab0 AS cor0
----
-6
-60
-71

query I rowsort
SELECT ALL + 89 + + 29 * + col1 AS col1 FROM tab0
----
2583
2728
2902

query I rowsort
SELECT tab1.col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL col1 * 88 + col2 FROM tab0
----
7601
8090
8537

query I rowsort
SELECT - + cor0.col1 * - cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + 80 * + 28 AS col0 FROM tab1 AS cor0
----
2240
2240
2240

query I rowsort
SELECT - 82 AS col1 FROM tab1 AS cor0
----
-82
-82
-82

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1, tab1 cor0, tab0 AS cor1
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT ALL - col2 * 91 AS col1 FROM tab2
----
-2366
-2457
-3458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 61 + - col2 * col2 col2 FROM tab2 cor0
----
-1383
-615
-668

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col2 + - col0 ) col1 FROM tab0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 24 + - col2 col0 FROM tab2 AS cor0
----
-14
-2
-3

query I rowsort
SELECT + 39 * col0 FROM tab2
----
273
3042
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9010
SELECT CAST( NULL AS SIGNED ) / - 13 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9010
SELECT CAST ( NULL AS INTEGER ) / - 13 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + 70 ) * col0 AS col0 FROM tab1
----
210
4480
5600

query I rowsort
SELECT DISTINCT 7 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9013
SELECT DISTINCT + col2 * + col1 DIV - ( col1 ) FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9013
SELECT DISTINCT + col2 * + col1 / - ( col1 ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT 94 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT - 22 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

query I rowsort
SELECT col2 * 16 FROM tab2 cor0
----
416
432
608

query I rowsort
SELECT col2 * ( - 82 ) AS col2 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT ALL + col1 + - 60 AS col0 FROM tab2 AS cor0
----
-1
-29
-43

query I rowsort
SELECT DISTINCT + - col1 + + 82 AS col1 FROM tab2 AS cor0
----
23
51
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9020
SELECT col1 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9020
SELECT col1 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( 75 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9022
SELECT col2 * + CAST( NULL AS DECIMAL ) + - 86 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9022
SELECT col2 * + CAST ( NULL AS REAL ) + - 86 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * - col2 + col0 * + col0 AS col2 FROM tab0 AS cor0
----
-216
1190
623

query I rowsort
SELECT col1 * 90 AS col0 FROM tab0 AS cor0
----
7740
8190
8730

query I rowsort
SELECT + col2 * ( col2 ) * + ( 64 ) AS col2 FROM tab0 AS cor0
----
430336
64
69696

query I rowsort
SELECT ALL - col2 * col2 * + col1 FROM tab1 cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL ( + col2 ) * col2 + + 69 FROM tab2 AS cor0
----
1513
745
798

query I rowsort
SELECT col0 + col2 - tab0.col2 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9029
SELECT - 86 + + col2 DIV - col0 FROM tab2
----
-86
-86
-89

skipif mysql # not compatible
query I rowsort label-9029
SELECT - 86 + + col2 / - col0 FROM tab2
----
-86
-86
-89

query I rowsort
SELECT - 83 - + col0 FROM tab1 AS cor0
----
-147
-163
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - col2 + col0 + + col2 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9033
SELECT - + col1 - - col0 DIV + 31 FROM tab1 AS cor0
----
-11
-26
-8

skipif mysql # not compatible
query I rowsort label-9033
SELECT - + col1 - - col0 / + 31 FROM tab1 AS cor0
----
-11
-26
-8

query I rowsort
SELECT ALL - col2 * 86 FROM tab0 AS cor0
----
-2838
-7052
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-9035
SELECT - cor0.col1 DIV - ( 84 ) + - col0 FROM tab0 cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-9035
SELECT - cor0.col1 / - ( 84 ) + - col0 FROM tab0 cor0
----
-23
-34
-88

query I rowsort
SELECT col1 * col0 + + col1 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT - col2 * - col1 + 76 + + col0 AS col1 FROM tab0 AS cor0
----
208
2938
7627

onlyif mysql # use DIV operator for integer division
query I rowsort label-9038
SELECT col0 DIV 68 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9038
SELECT col0 / 68 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL col2 * + col2 + + 16 FROM tab2 AS cor0
----
1460
692
745

query I rowsort
SELECT DISTINCT 24 - col2 AS col0 FROM tab1 AS cor0
----
-30
-33
-72

query I rowsort
SELECT - col1 * col0 + col0 * col2 AS col0 FROM tab2 AS cor0
----
-2574
-28
1659

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9042
SELECT ALL - ( col0 ) + CAST( col1 + + cor0.col0 AS SIGNED ) * - ( + 8 ) FROM tab1 AS cor0
----
-235
-656
-824

skipif mysql # not compatible
query I rowsort label-9042
SELECT ALL - ( col0 ) + CAST ( col1 + + cor0.col0 AS INTEGER ) * - ( + 8 ) FROM tab1 AS cor0
----
-235
-656
-824

query I rowsort
SELECT col2 * tab0.col2 - + 83 FROM tab0
----
-82
1006
6641

query I rowsort
SELECT cor0.col1 AS col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - - col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - tab0.col0 + 97 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 6c744434f6b0a9f790ffa77e26d07a7f

query I rowsort
SELECT + col0 * ( ( + tab1.col1 ) ) FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL - tab2.col0 - - tab2.col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL tab0.col0 + col0 - - col1 FROM tab0
----
134
167
269

query I rowsort
SELECT ALL tab1.col0 - - 5 * - col0 * - tab1.col2 FROM tab1
----
18304
38480
813

query I rowsort
SELECT ALL + 67 - col1 AS col0 FROM tab1 AS cor0
----
41
54
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9052
SELECT 17 DIV - col1 + col1 * - col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9052
SELECT 17 / - col1 + col1 * - col1 col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - col1 + ( - col2 ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT + 69 * + 39 AS col0 FROM tab2 AS cor0
----
2691

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9055
SELECT + ( cor0.col2 ) * CAST( NULL AS SIGNED ) * + tab1.col2 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9055
SELECT + ( cor0.col2 ) * CAST ( NULL AS INTEGER ) * + tab1.col2 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + col1 + 74 - col0 AS col0 FROM tab0
----
136
76

query I rowsort
SELECT col2 * + 95 + + col2 * + col2 FROM tab0
----
14514
4224
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - col2 col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT tab0.col1 * 95 AS col0 FROM tab0, tab2, tab2 AS cor0
----
8170
8645
9215

query I rowsort
SELECT ALL col2 * 48 + + col2 - col0 FROM tab1
----
2643
2729
4624

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9061
SELECT - CAST( - 26 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
26
26
26

skipif mysql # not compatible
query I rowsort label-9061
SELECT - CAST ( - 26 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
26
26
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9062
SELECT col1 + + col1 * col2 DIV + 98 FROM tab2 cor0
----
23
39
74

skipif mysql # not compatible
query I rowsort label-9062
SELECT col1 + + col1 * col2 / + 98 FROM tab2 cor0
----
23
39
74

query I rowsort
SELECT + 91 * col0 + col2 AS col2 FROM tab1 AS cor0
----
327
5881
7376

query I rowsort
SELECT ALL - 97 * 81 AS col0 FROM tab2 AS cor0
----
-7857
-7857
-7857

query I rowsort
SELECT - 50 + - cor0.col1 * col2 AS col0 FROM tab0 cor0
----
-147
-2888
-7512

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9066
SELECT ALL - CAST( NULL AS SIGNED ) / col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9066
SELECT ALL - CAST ( NULL AS INTEGER ) / col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 * - 39 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT ALL + ( + col2 ) * col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ( 3 ) + cor0.col0 AS col0 FROM tab0 AS cor0
----
27
38
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9070
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + col0 / - col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9070
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + col0 / - col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 + + cor0.col0 + - col2 col1 FROM tab2 cor0
----
103
31
92

query I rowsort
SELECT + ( 98 ) * col2 AS col1 FROM tab1 AS cor0
----
5292
5586
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-9073
SELECT - 48 DIV col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-9073
SELECT - 48 / col0 FROM tab0
----
-1
-2
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9074
SELECT col2 + - col0 + + col1 DIV - 19 FROM tab0
----
-11
-39
5

skipif mysql # not compatible
query I rowsort label-9074
SELECT col2 + - col0 + + col1 / - 19 FROM tab0
----
-11
-39
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9075
SELECT ALL - 18 DIV - col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-9075
SELECT ALL - 18 / - col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( - 42 AS REAL ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT DISTINCT - col0 + 31 * - tab2.col2 * col0 FROM tab2
----
-5866
-62946
-93141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 68 * + ( tab0.col1 ) col0 FROM tab0
----
5848
6188
6596

query I rowsort
SELECT - 30 + 82 AS col0 FROM tab2
----
52
52
52

query I rowsort
SELECT 85 + - col0 + col0 FROM tab0 AS cor0
----
85
85
85

query I rowsort
SELECT + col0 * + 90 AS col1 FROM tab1
----
270
5760
7200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 col1 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-9083
SELECT - col2 DIV col1 + col2 + - 40 FROM tab2 AS cor0
----
-13
-14
-4

skipif mysql # not compatible
query I rowsort label-9083
SELECT - col2 / col1 + col2 + - 40 FROM tab2 AS cor0
----
-13
-14
-4

query I rowsort
SELECT DISTINCT 90 * + col1 AS col0 FROM tab1 AS cor0
----
1170
2340
900

query I rowsort
SELECT + + col0 + col1 * col2 * + 84 AS col0 FROM tab2 AS cor0
----
128934
54343
70315

query I rowsort
SELECT - 11 * col2 + 77 + - 90 * col0 FROM tab1 AS cor0
----
-6310
-787
-8179

query I rowsort
SELECT DISTINCT 49 + col0 * + col1 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
177553
329364
737058

query I rowsort
SELECT col1 * col0 + ( + col0 + - col2 ) FROM tab1 AS cor0
----
1024
27
647

query I rowsort
SELECT DISTINCT 10 * + col1 FROM tab0 AS cor0
----
860
910
970

query I rowsort
SELECT ALL + - 3 * col1 AS col0 FROM tab1 AS cor0
----
-30
-39
-78

query I rowsort
SELECT 78 + - col2 AS col2 FROM tab1
----
-18
21
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9092
SELECT col2 + col0 + - 76 DIV - col0 FROM tab2 AS cor0
----
104
117
44

skipif mysql # not compatible
query I rowsort label-9092
SELECT col2 + col0 + - 76 / - col0 FROM tab2 AS cor0
----
104
117
44

query I rowsort
SELECT - - col1 * col2 + + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + cor0.col0 * + col0 + - 95 AS col0 FROM tab0 AS cor0
----
1130
481
7826

query I rowsort
SELECT ALL - cor0.col1 * 6 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-3354
-679
-8008

query I rowsort
SELECT - col0 * col0 + col0 * col1 FROM tab1 AS cor0
----
-3456
-5360
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-9097
SELECT - cor0.col2 DIV - CAST( + col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9097
SELECT - cor0.col2 / - CAST ( + col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + col1 + - ( + 96 ) * + col0 FROM tab2 AS cor0
----
-641
-7429
-7567

query I rowsort
SELECT DISTINCT + 40 * col2 AS col1 FROM tab2
----
1040
1080
1520

query I rowsort
SELECT DISTINCT + - col2 * 56 + ( + col2 ) AS col2 FROM tab0 AS cor0
----
-1815
-4510
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + 32 - col2 * col1 col0 FROM tab2 AS cor0
----
-702
27
570

query I rowsort
SELECT ALL col1 * - ( col1 ) FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT col2 - - col0 * col1 AS col1 FROM tab2
----
1381
244
4628

query I rowsort
SELECT - + cor0.col1 + - 0 * - col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 46 + + 34 FROM tab0 AS cor0
----
80

query I rowsort
SELECT - col1 - col0 * + tab1.col0 FROM tab1
----
-35
-4106
-6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT - - 91 AS col2 FROM tab0 cor0
----
91
91
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col0 col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + + 94 * + col1 FROM tab2 AS cor0
----
1598
2914
5546

query I rowsort
SELECT DISTINCT + ( 30 ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
30

query I rowsort
SELECT - 35 FROM tab2 cor0
----
-35
-35
-35

query I rowsort
SELECT + col1 * 71 FROM tab0 cor0
----
6106
6461
6887

query I rowsort
SELECT - 29 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 56a8aa9e4c5d3c934d1853afeb22653e

query I rowsort
SELECT + 36 * - col2 * col0 FROM tab1 AS cor0
----
-131328
-276480
-5832

query I rowsort
SELECT DISTINCT - 45 FROM tab2, tab1 AS cor0
----
-45

query I rowsort
SELECT + 61 * - tab1.col2 FROM tab1
----
-3294
-3477
-5856

query I rowsort
SELECT DISTINCT - + col0 * - 11 * - col1 FROM tab1 AS cor0
----
-11440
-7040
-858

query I rowsort
SELECT ALL + col1 * - col1 + - cor0.col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT ALL - ( 70 ) AS col2 FROM tab2
----
-70
-70
-70

query I rowsort
SELECT + col2 * 30 FROM tab1
----
1620
1710
2880

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab1, tab0 AS cor1
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT + col1 * + 64 * col1 FROM tab1
----
10816
43264
6400

query I rowsort
SELECT DISTINCT tab2.col2 * + col0 * ( col0 ) + - col0 AS col1 FROM tab2
----
1316
158106
237079

query I rowsort
SELECT 63 + + col2 AS col2 FROM tab1
----
117
120
159

query I rowsort
SELECT - tab2.col1 * col0 * - col0 - - col1 FROM tab2
----
106114
1550
359015

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9127
SELECT tab1.col0 * + CAST( NULL AS SIGNED ) * 33 AS col2 FROM tab1, tab2, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9127
SELECT tab1.col0 * + CAST ( NULL AS INTEGER ) * 33 AS col2 FROM tab1, tab2, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 + tab0.col1 ) col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 69 col0 FROM tab1 AS cor0
----
69
69
69

query I rowsort
SELECT DISTINCT + 21 + - tab0.col2 FROM tab0
----
-12
-61
20

query I rowsort
SELECT ALL col0 * col1 + - ( + col1 ) * col1 AS col1 FROM tab0
----
-182
-5332
-6014

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 * - cor0.col1 col0 FROM tab0, tab2 AS cor0
----
-1488
-2832
-816

query I rowsort
SELECT ALL 88 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 21 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9135
SELECT ALL - col1 DIV + ( col2 ) FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-9135
SELECT ALL - col1 / + ( col2 ) FROM tab0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT col1 * - 43 FROM tab2
----
-1333
-2537
-731

query I rowsort
SELECT DISTINCT col0 * 34 * - col0 AS col0 FROM tab1
----
-139264
-217600
-306

query I rowsort
SELECT - - col2 * - col2 - - col2 AS col2 FROM tab2 AS cor0
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-9139
SELECT + ( col0 ) DIV col0 + col2 * 40 * + col0 FROM tab0 AS cor0
----
1401
291921
31681

skipif mysql # not compatible
query I rowsort label-9139
SELECT + ( col0 ) / col0 + col2 * 40 * + col0 FROM tab0 AS cor0
----
1401
291921
31681

query I rowsort
SELECT + + col2 * + col0 + col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT ALL - - ( - col1 ) + cor0.col1 * - 36 AS col0 FROM tab2 AS cor0
----
-1147
-2183
-629

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9142
SELECT + CAST( + col0 AS SIGNED ) * cor0.col0 + cor0.col0 + 56 AS col0 FROM tab0 AS cor0
----
1316
656
8066

skipif mysql # not compatible
query I rowsort label-9142
SELECT + CAST ( + col0 AS INTEGER ) * cor0.col0 + cor0.col0 + 56 AS col0 FROM tab0 AS cor0
----
1316
656
8066

onlyif mysql # use DIV operator for integer division
query I rowsort label-9143
SELECT DISTINCT + - cor0.col1 DIV col1 + + col2 * 76 col0 FROM tab0 AS cor0
----
2507
6231
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9143
SELECT DISTINCT + - cor0.col1 / col1 + + col2 * 76 col0 FROM tab0 AS cor0
----
2507
6231
75

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + 20 AS REAL ) FROM tab2 AS cor0
----
20
20
20

query I rowsort
SELECT 97 + col1 FROM tab0 AS cor0
----
183
188
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9146
SELECT DISTINCT + col1 + CAST( - col2 AS SIGNED ) * col1 FROM tab2
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-9146
SELECT DISTINCT + col1 + CAST ( - col2 AS INTEGER ) * col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT 66 * + col2 + cor0.col1 * col1 + - col1 FROM tab1 AS cor0
----
3852
4214
6492

query I rowsort
SELECT + 76 * - cor0.col2 FROM tab1 AS cor0
----
-4104
-4332
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-9149
SELECT + cor0.col0 + col2 * cor0.col0 DIV - cor0.col0 AS col1 FROM tab0 cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-9149
SELECT + cor0.col0 + col2 * cor0.col0 / - cor0.col0 AS col1 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - 85 AS col0 FROM tab2, tab1 cor0
----
-85

query I rowsort
SELECT col2 - 45 * col2 * col2 FROM tab0 cor0
----
-302498
-44
-48972

onlyif mysql # use DIV operator for integer division
query I rowsort label-9152
SELECT col2 + - ( - 53 ) DIV + col1 AS col1 FROM tab2 AS cor0
----
26
28
41

skipif mysql # not compatible
query I rowsort label-9152
SELECT col2 + - ( - 53 ) / + col1 AS col1 FROM tab2 AS cor0
----
26
28
41

query I rowsort
SELECT DISTINCT + col0 * + col2 + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL - + col0 * - 45 + - cor0.col1 * - col2 FROM tab2 AS cor0
----
1152
4201
5044

query I rowsort
SELECT DISTINCT + col1 * - 15 - + cor0.col0 FROM tab0 AS cor0
----
-1314
-1454
-1490

onlyif mysql # use DIV operator for integer division
query I rowsort label-9156
SELECT DISTINCT + - col1 * + ( + 18 ) * - col0 + col1 - - 34 DIV cor0.col0 FROM tab0 AS cor0
----
145873
37239
61207

skipif mysql # not compatible
query I rowsort label-9156
SELECT DISTINCT + - col1 * + ( + 18 ) * - col0 + col1 - - 34 / cor0.col0 FROM tab0 AS cor0
----
145873
37239
61207

query I rowsort
SELECT - ( col2 ) * + col0 + - col2 * - col2 * col1 FROM tab0 AS cor0
----
604586
62
92862

query I rowsort
SELECT ALL col1 * + 81 FROM tab2 AS cor0
----
1377
2511
4779

onlyif mysql # use DIV operator for integer division
query I rowsort label-9159
SELECT DISTINCT 17 DIV + col0 + col1 FROM tab2 AS cor0
----
17
33
59

skipif mysql # not compatible
query I rowsort label-9159
SELECT DISTINCT 17 / + col0 + col1 FROM tab2 AS cor0
----
17
33
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9160
SELECT 31 DIV + 95 + col0 * 87 + cor0.col1 AS col2 FROM tab2 AS cor0
----
640
6845
6890

skipif mysql # not compatible
query I rowsort label-9160
SELECT 31 / + 95 + col0 * 87 + cor0.col1 AS col2 FROM tab2 AS cor0
----
640
6845
6890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9161
SELECT ALL - CAST( NULL AS DECIMAL ) * - 50 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9161
SELECT ALL - CAST ( NULL AS REAL ) * - 50 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + 47 * + col0 AS col0 FROM tab0
----
1214
1742
4274

query I rowsort
SELECT - tab2.col0 * + col2 + ( + tab2.col0 ) * - col2 AS col2 FROM tab2
----
-378
-4056
-6004

query I rowsort
SELECT ALL col0 * ( + col0 ) + col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT - col2 * + tab2.col0 AS col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col0 * col0 + col0 FROM tab2
----
-42
-6006
-6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9167
SELECT ALL - col2 + col2 - + CAST( - col0 * col2 AS SIGNED ) col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9167
SELECT ALL - col2 + col2 - + CAST ( - col0 * col2 AS INTEGER ) col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT 89 FROM tab0 cor0
----
89
89
89

query I rowsort
SELECT DISTINCT + + col1 + - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9170
SELECT DISTINCT + - col0 * + cor0.col0 + CAST( 99 AS SIGNED ) * col0 FROM tab2 AS cor0
----
1580
1638
644

skipif mysql # not compatible
query I rowsort label-9170
SELECT DISTINCT + - col0 * + cor0.col0 + CAST ( 99 AS INTEGER ) * col0 FROM tab2 AS cor0
----
1580
1638
644

query I rowsort
SELECT ALL - + col2 - + cor0.col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + 78 + + col1 FROM tab1 AS cor0
----
104
88
91

query I rowsort
SELECT ALL + + col1 * + col2 + col2 AS col2 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col1 * 16 + - ( cor0.col1 ) * + 99 col2 FROM tab2 AS cor0
----
-1394
-2542
-4838

query I rowsort
SELECT DISTINCT + - cor0.col2 - + col1 * cor0.col0 AS col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + 87 * + 56 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
4872

query I rowsort
SELECT ALL 44 - - tab1.col2 AS col2 FROM tab1
----
101
140
98

query I rowsort
SELECT + 29 + col0 * col1 FROM tab2
----
1372
246
4631

query I rowsort
SELECT DISTINCT 11 - + tab0.col1 AS col2 FROM tab0
----
-75
-80
-86

query I rowsort
SELECT + + ( - col2 ) * - 5 + col0 * col2 FROM tab2 AS cor0
----
2158
3192
324

query I rowsort
SELECT DISTINCT ( - col1 ) * ( + ( + col0 ) ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + + cor0.col1 * + col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + - col0 * - ( 69 ) FROM tab0 cor0
----
1656
2415
6141

onlyif mysql # use DIV operator for integer division
query I rowsort label-9184
SELECT DISTINCT tab1.col2 * tab1.col0 DIV - col2 AS col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-9184
SELECT DISTINCT tab1.col2 * tab1.col0 / - col2 AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - + tab2.col2 FROM tab2, tab1, tab1 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - 12 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT + col1 * - 75 + + col2 * col0 FROM tab1 AS cor0
----
-1788
2898
6705

onlyif mysql # use DIV operator for integer division
query I rowsort label-9188
SELECT - col1 + - col1 DIV - col2 AS col2 FROM tab0 cor0
----
-84
-90
0

skipif mysql # not compatible
query I rowsort label-9188
SELECT - col1 + - col1 / - col2 AS col2 FROM tab0 cor0
----
-84
-90
0

query I rowsort
SELECT ALL + col2 + - col1 * - col1 AS col2 FROM tab1 cor0
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-9190
SELECT ALL col1 * 42 + - 97 DIV col2 FROM tab1
----
1091
419
545

skipif mysql # not compatible
query I rowsort label-9190
SELECT ALL col1 * 42 + - 97 / col2 FROM tab1
----
1091
419
545

query I rowsort
SELECT + col1 * 4 AS col0 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT + col1 - - 91 * - 57 AS col0 FROM tab0 AS cor0
----
-5090
-5096
-5101

onlyif mysql # use DIV operator for integer division
query I rowsort label-9193
SELECT - - col2 DIV 16 - col2 * col2 * col2 FROM tab1 AS cor0
----
-157461
-185190
-884730

skipif mysql # not compatible
query I rowsort label-9193
SELECT - - col2 / 16 - col2 * col2 * col2 FROM tab1 AS cor0
----
-157461
-185190
-884730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col0 * col2 col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL - col0 * col1 + col0 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - + col1 * + 83 * col2 + - col1 * + 96 FROM tab1 AS cor0
----
-104832
-119028
-48270

query I rowsort
SELECT - + col1 + - col0 * 74 * + col0 AS col1 FROM tab0 AS cor0
----
-42710
-586245
-90747

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col0 * - CAST ( col1 * - cor0.col0 AS REAL ) FROM tab1 AS cor0
----
234
40960
83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-9199
SELECT col2 DIV ( - 25 + + col0 ) AS col1 FROM tab1 AS cor0
----
-2
1
1

skipif mysql # not compatible
query I rowsort label-9199
SELECT col2 / ( - 25 + + col0 ) AS col1 FROM tab1 AS cor0
----
-2
1
1

query I rowsort
SELECT DISTINCT col1 * ( + col1 * - col0 ) AS col0 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT col2 - - col1 * + col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL + + col1 * col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-9203
SELECT DISTINCT - 78 DIV - col0 col1 FROM tab1
----
0
1
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9203
SELECT DISTINCT - 78 / - col0 col1 FROM tab1
----
0
1
26

query I rowsort
SELECT - 43 - col1 AS col2 FROM tab2
----
-102
-60
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ( - 55 ) + col0 * - CAST ( col1 AS REAL ) col2 FROM tab1
----
-1095
-133
-695

onlyif mysql # use DIV operator for integer division
query I rowsort label-9206
SELECT ALL - 96 + col1 + - col0 DIV CAST( - col2 + - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-70
-83
-86

skipif mysql # not compatible
query I rowsort label-9206
SELECT ALL - 96 + col1 + - col0 / CAST ( - col2 + - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-70
-83
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-9207
SELECT DISTINCT - ( + col1 ) + + col0 DIV - col0 col2 FROM tab0 AS cor0
----
-87
-92
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9207
SELECT DISTINCT - ( + col1 ) + + col0 / - col0 col2 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT + - 81 * - ( + col0 ) + ( - col2 ) FROM tab1 AS cor0
----
189
5127
6384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 64 ) + + col2 col0 FROM tab0 AS cor0
----
-31
-63
18

query I rowsort
SELECT DISTINCT - cor0.col2 + col2 * - col2 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL + 79 * col0 + col0 * - col1 FROM tab0 AS cor0
----
-1068
-168
-630

query I rowsort
SELECT + col1 + 90 * + col1 FROM tab2 AS cor0
----
1547
2821
5369

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 col0 FROM tab1 AS cor0
----
42
42
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9214
SELECT ALL - CAST( + ( col0 ) AS SIGNED ) + + col2 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-9214
SELECT ALL - CAST ( + ( col0 ) AS INTEGER ) + + col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-9215
SELECT DISTINCT + col0 DIV - col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-9215
SELECT DISTINCT + col0 / - col2 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT + cor0.col2 + col2 * col2 AS col2 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT 30 * - col2 * + col0 FROM tab2 AS cor0
----
-5670
-60840
-90060

query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - 83 * col2 AS col1 FROM tab1 AS cor0
----
-4482
-4731
-7968

query I rowsort
SELECT 8 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT + col0 * 2 + col1 AS col0 FROM tab2 cor0
----
175
215
45

query I rowsort
SELECT + + col1 + - 95 FROM tab1 AS cor0
----
-69
-82
-85

query I rowsort
SELECT + - 14 + - 69 * col1 FROM tab1 AS cor0
----
-1808
-704
-911

query I rowsort
SELECT ALL + 96 + + col2 FROM tab2
----
122
123
134

onlyif mysql # use DIV operator for integer division
query I rowsort label-9225
SELECT + 30 DIV + col1 FROM tab1 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-9225
SELECT + 30 / + col1 FROM tab1 AS cor0
----
1
2
3

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-9227
SELECT - - 41 DIV col0 - 17 AS col0 FROM tab0 AS cor0
----
-16
-16
-17

skipif mysql # not compatible
query I rowsort label-9227
SELECT - - 41 / col0 - 17 AS col0 FROM tab0 AS cor0
----
-16
-16
-17

query I rowsort
SELECT 27 * tab0.col2 AS col2 FROM tab0
----
2214
27
891

query I rowsort
SELECT DISTINCT - + 40 + + col0 AS col2 FROM tab0 AS cor0
----
-16
-5
49

query I rowsort
SELECT - - col2 * col1 * - 24 + - 81 + col1 * col0 FROM tab1 AS cor0
----
-13121
-28993
-33699

query I rowsort
SELECT ALL + + col0 * - col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + cor0.col2 - - col0 AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - - col0 - 17 AS col1 FROM tab0 AS cor0
----
18
7
72

query I rowsort
SELECT + col0 * + 69 FROM tab2 AS cor0
----
483
5382
5451

onlyif mysql # use DIV operator for integer division
query I rowsort label-9235
SELECT - col1 DIV - 41 + + col2 * - col1 + ( + 14 ) FROM tab2 AS cor0
----
-1519
-632
-823

skipif mysql # not compatible
query I rowsort label-9235
SELECT - col1 / - 41 + + col2 * - col1 + ( + 14 ) FROM tab2 AS cor0
----
-1519
-632
-823

query I rowsort
SELECT ALL col0 * col2 + col1 AS col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT col2 + ( col0 ) + col1 AS col1 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - - col1 * 56 FROM tab2 AS cor0
----
1736
3304
952

query I rowsort
SELECT - - col0 + + cor0.col2 + col0 FROM tab0 cor0
----
260
71
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9240
SELECT DISTINCT + + col1 + - CAST( NULL AS SIGNED ) * 32 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9240
SELECT DISTINCT + + col1 + - CAST ( NULL AS INTEGER ) * 32 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - col1 + + 56 * - col2 + - col0 AS col0 FROM tab1 cor0
----
-3053
-3266
-5469

query I rowsort
SELECT ALL - col0 + 37 AS col1 FROM tab0 cor0
----
-52
13
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9243
SELECT DISTINCT col0 + CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-9243
SELECT DISTINCT col0 + CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - col1 * - 71 - col0 AS col0 FROM tab0 AS cor0
----
6082
6372
6852

query I rowsort
SELECT DISTINCT col1 + - ( col0 ) + cor0.col2 AS col1 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT DISTINCT + - col1 + - col2 * col2 + col2 * col1 AS col1 FROM tab0 AS cor0
----
-1
1663
647

query I rowsort
SELECT - cor0.col0 - 22 FROM tab2 AS cor0
----
-100
-101
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-9248
SELECT - - col2 * ( col2 + + col0 ) DIV + cor0.col0 FROM tab2 AS cor0
----
131
34
56

skipif mysql # not compatible
query I rowsort label-9248
SELECT - - col2 * ( col2 + + col0 ) / + cor0.col0 FROM tab2 AS cor0
----
131
34
56

query I rowsort
SELECT + col2 * ( 39 ) AS col0 FROM tab2
----
1014
1053
1482

query I rowsort
SELECT DISTINCT - + ( col1 ) * + col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - 15 + + cor0.col2 AS col0 FROM tab0, tab0 AS cor0
----
-14
18
67

query I rowsort
SELECT + col0 * + 34 AS col2 FROM tab1
----
102
2176
2720

query I rowsort
SELECT ALL + ( + 4 ) FROM tab0, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9254
SELECT DISTINCT - col1 * - col1 DIV + CAST( + col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-9254
SELECT DISTINCT - col1 * - col1 / + CAST ( + col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - ( + col2 ) * - col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT - cor0.col0 - col1 * col0 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL - - ( col2 ) + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 71 * 75 AS col2 FROM tab1
----
-5325

query I rowsort
SELECT - ( col0 ) * - cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9261
SELECT col1 DIV col0 + tab0.col0 * ( ( col1 ) ) FROM tab0
----
2067
3397
8100

skipif mysql # not compatible
query I rowsort label-9261
SELECT col1 / col0 + tab0.col0 * ( ( col1 ) ) FROM tab0
----
2067
3397
8100

query I rowsort
SELECT DISTINCT - 13 * col2 + col1 * 91 FROM tab0 AS cor0
----
7215
7397
8814

query I rowsort
SELECT ALL col0 * + 17 FROM tab2 AS cor0
----
119
1326
1343

query I rowsort
SELECT + - col1 * + 54 * col2 FROM tab1 AS cor0
----
-30780
-67392
-75816

query I rowsort
SELECT DISTINCT - + col1 * col1 + - col0 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT DISTINCT - 66 * - col1 AS col0 FROM tab0 AS cor0
----
5676
6006
6402

query I rowsort
SELECT DISTINCT + 65 + col2 * + cor0.col2 FROM tab2 AS cor0
----
1509
741
794

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + 52 col0 FROM tab1 AS cor0
----
156
3328
4160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9269
SELECT DISTINCT col1 * + col2 - col0 DIV - col0 FROM tab1 AS cor0
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-9269
SELECT DISTINCT col1 * + col2 - col0 / - col0 FROM tab1 AS cor0
----
1249
1405
571

query I rowsort
SELECT - col1 * col1 - cor0.col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT ALL + 11 * - col1 * col0 + 4 AS col0 FROM tab1 AS cor0
----
-11436
-7036
-854

query I rowsort
SELECT 31 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT + 79 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1343
2449
4661

query I rowsort
SELECT ALL - 99 + - 40 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 8700daa0b0e07938edbe7b70766d1f43

query I rowsort
SELECT ALL - - 54 * col2 AS col2 FROM tab0 AS cor0
----
1782
4428
54

query I rowsort
SELECT 36 * cor0.col2 FROM tab2 AS cor0
----
1368
936
972

query I rowsort
SELECT DISTINCT + col2 + + 48 * - 32 AS col0 FROM tab0 cor0
----
-1454
-1503
-1535

query I rowsort
SELECT ALL col2 * - 2 AS col1 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT ALL + col1 + + 75 + - col2 FROM tab1 AS cor0
----
-8
28
47

query I rowsort
SELECT DISTINCT - - col1 * 1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + col2 * 99 FROM tab0 AS cor0
----
3267
8118
99

query I rowsort
SELECT ALL + col1 + - 29 FROM tab1 AS cor0
----
-16
-19
-3

query I rowsort
SELECT - + ( + col1 ) + col1 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - ( 99 ) + - col2 FROM tab1 AS cor0
----
-153
-156
-195

query I rowsort
SELECT + cor0.col2 * 26 AS col2 FROM tab1 AS cor0
----
1404
1482
2496

query I rowsort
SELECT DISTINCT - ( 91 ) AS col1 FROM tab2 AS cor0
----
-91

query I rowsort
SELECT ALL - - 24 * col0 AS col2 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT DISTINCT col0 * - 33 FROM tab1 AS cor0
----
-2112
-2640
-99

query I rowsort
SELECT DISTINCT + + 19 FROM tab1 cor0
----
19

query I rowsort
SELECT ALL + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - + 87 * col2 AS col0 FROM tab1 AS cor0
----
-4698
-4959
-8352

query I rowsort
SELECT + ( + 60 ) * - col0 AS col0 FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT DISTINCT - 11 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
-11

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col0 * + 41 FROM tab2 AS cor0
----
-287
-3198
-3239

onlyif mysql # use DIV operator for integer division
query I rowsort label-9296
SELECT + 80 DIV + 28 AS col0 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-9296
SELECT + 80 / + 28 AS col0 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT col2 * 77 * - col1 AS col1 FROM tab0
----
-218526
-574574
-7469

query I rowsort
SELECT + - ( + col2 ) * - col1 + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + ( col2 + + col0 ) FROM tab0
----
171
36
57

query I rowsort
SELECT ALL - ( ( + col1 ) ) AS col1 FROM tab0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9301
SELECT + - col2 DIV col1 col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9301
SELECT + - col2 / col1 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ( + tab0.col2 * + col0 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT ( 74 ) AS col1 FROM tab2
----
74
74
74

query I rowsort
SELECT - - col0 + 51 FROM tab0 AS cor0
----
140
75
86

query I rowsort
SELECT ALL - 48 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT DISTINCT - tab1.col1 + + col0 * col1 AS col2 FROM tab1
----
1027
52
630

query I rowsort
SELECT + 36 + tab2.col1 + - col0 * - col2 AS col0 FROM tab2
----
2123
256
3055

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9308
SELECT col2 * CAST( + col0 AS SIGNED ) + - col2 AS col0 FROM tab1 AS cor0
----
108
3591
7584

skipif mysql # not compatible
query I rowsort label-9308
SELECT col2 * CAST ( + col0 AS INTEGER ) + - col2 AS col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT ALL 82 + + col1 AS col2 FROM tab1
----
108
92
95

query I rowsort
SELECT - ( - col0 ) * ( 82 ) + col1 AS col0 FROM tab0
----
2054
2967
7389

query I rowsort
SELECT - ( - col1 ) + tab2.col2 - col2 FROM tab2
----
17
31
59

query I rowsort
SELECT 95 * col2 FROM tab0
----
3135
7790
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 90 + col1 col1 FROM tab1
----
100
103
116

onlyif mysql # use DIV operator for integer division
query I rowsort label-9314
SELECT DISTINCT col0 * col0 * ( - ( - col0 ) ) + - 72 DIV + col1 AS col0 FROM tab1
----
25
262137
511995

skipif mysql # not compatible
query I rowsort label-9314
SELECT DISTINCT col0 * col0 * ( - ( - col0 ) ) + - 72 / + col1 AS col0 FROM tab1
----
25
262137
511995

query I rowsort
SELECT ALL + ( col1 ) * col0 + 37 AS col2 FROM tab2
----
1380
254
4639

query I rowsort
SELECT DISTINCT + 29 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
29

query I rowsort
SELECT ALL col2 * col2 * + col0 + - col1 AS col2 FROM tab1 AS cor0
----
207926
737267
8722

onlyif mysql # use DIV operator for integer division
query I rowsort label-9318
SELECT DISTINCT + - col1 + ( col2 ) DIV + col1 AS col1 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9318
SELECT DISTINCT + - col1 + ( col2 ) / + col1 AS col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + - col2 - - col2 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + + col1 * col1 + - col0 * col2 AS col2 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT 35 * col1 + 2 + - col2 AS col0 FROM tab2
----
1060
2041
559

onlyif mysql # use DIV operator for integer division
query I rowsort label-9322
SELECT + col0 * col1 DIV - col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-9322
SELECT + col0 * col1 / - col1 FROM tab2
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-9323
SELECT + - col2 + 58 DIV + col0 FROM tab2 AS cor0
----
-19
-26
-38

skipif mysql # not compatible
query I rowsort label-9323
SELECT + - col2 + 58 / + col0 FROM tab2 AS cor0
----
-19
-26
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9324
SELECT 68 DIV col0 FROM tab1
----
0
1
22

skipif mysql # not compatible
query I rowsort label-9324
SELECT 68 / col0 FROM tab1
----
0
1
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9325
SELECT ( col2 + CAST( NULL AS DECIMAL ) ) * - 36 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9325
SELECT ( col2 + CAST ( NULL AS REAL ) ) * - 36 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - tab2.col2 ) AS col2 FROM tab2
----
-26
-27
-38

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 cor2
----
972 values hashing to b51b4342db121ebc2d3d353dcd8ed521

query I rowsort
SELECT - - cor0.col1 + cor0.col2 AS col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - col1 + 72 AS col1 FROM tab1 AS cor0
----
46
59
62

query I rowsort
SELECT DISTINCT col0 - col0 AS col1 FROM tab0 WHERE NOT NULL NOT BETWEEN NULL AND col0 / col0
----

query I rowsort
SELECT col2 * col0 + col1 * col0 AS col1 FROM tab1 WHERE NOT col1 IN ( col0 )
----
240
4288
8720

query I rowsort
SELECT col2 + - col2 * col1 * - col0 AS col1 FROM tab0
----
3396
664200
68145

query III rowsort
SELECT * FROM tab2 WHERE col1 * col0 IN ( - col2 )
----

query I rowsort
SELECT tab2.col2 AS col1 FROM tab2 WHERE NULL <= - col1 * - col2
----

query I rowsort
SELECT tab1.col1 + - tab1.col0 FROM tab1
----
-54
-67
23

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 NOT IN ( - col1 * - col1 )
----

query I rowsort
SELECT ALL - - 91 + + col1 FROM tab1 cor0
----
101
104
117

query I rowsort
SELECT DISTINCT + - ( - col1 ) - 92 FROM tab1 AS cor0
----
-66
-79
-82

query I rowsort
SELECT DISTINCT 88 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
88

query I rowsort
SELECT 7 * - col1 FROM tab1 AS cor0
----
-182
-70
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + - col2 * + col2 col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT ALL - cor1.col2 + - 12 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3efbd24047d66ac1e89ade1793e904eb

query I rowsort
SELECT ( col1 ) + col2 * + ( + col2 ) AS col1 FROM tab2
----
1461
735
760

query I rowsort
SELECT DISTINCT ( - col2 ) + 97 AS col0 FROM tab0 AS cor0
----
15
64
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9345
SELECT ALL + + col2 DIV - col2 col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9345
SELECT ALL + + col2 / - col2 col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col2 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + 64 + + col1 FROM tab2 AS cor0
----
123
81
95

query I rowsort
SELECT + cor0.col1 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + + col2 * - 22 + col0 FROM tab1 AS cor0
----
-1185
-1190
-2032

query I rowsort
SELECT ALL - cor0.col0 + col1 * 82 AS col1 FROM tab0 AS cor0
----
7028
7373
7919

query I rowsort
SELECT + col1 * col2 + - col0 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-4550
-5595
788

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 12 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 cor2, tab2 AS cor3
----
3645 values hashing to 3a186ad492d315801f56fb30a5e89dbb

query I rowsort
SELECT ALL - - col2 + - col0 * col1 + + col2 FROM tab2 AS cor0
----
-1267
-163
-4550

query I rowsort
SELECT DISTINCT - 27 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-10
32
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-9356
SELECT - ( + col1 ) DIV col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-9356
SELECT - ( + col1 ) / col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT ALL col2 + cor0.col1 * 74 AS col0 FROM tab0 AS cor0
----
6397
6816
7179

onlyif mysql # use DIV operator for integer division
query I rowsort label-9358
SELECT ALL col2 * 5 + col2 DIV col0 FROM tab2
----
130
138
190

skipif mysql # not compatible
query I rowsort label-9358
SELECT ALL col2 * 5 + col2 / col0 FROM tab2
----
130
138
190

query I rowsort
SELECT ALL - 44 FROM tab1
----
-44
-44
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

query I rowsort
SELECT 27 + + tab0.col1 FROM tab0
----
113
118
124

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 col2 FROM tab1 WHERE NOT ( + col0 BETWEEN ( NULL ) AND NULL ) AND ( NULL ) IN ( col0 )
----

query I rowsort
SELECT col1 - + col0 * - col2 AS col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT col0 + + col0 * col0 * + col0 AS col0 FROM tab1
----
262208
30
512080

query I rowsort
SELECT + col2 * + col0 + col2 FROM tab0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-9366
SELECT + col2 + col0 DIV col2 FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-9366
SELECT + col2 + col0 / col2 FROM tab1
----
54
58
96

query I rowsort
SELECT ALL + col1 * - col1 + - col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT tab2.col1 AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col0 + - col2 * col1 * col0 FROM tab1 AS cor0
----
-36416
-4209
-99760

query I rowsort
SELECT + col2 + col0 * col1 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL col2 - + col1 * + col0 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT + ( + col1 * + col2 ) + col2 * col1 AS col0 FROM tab2
----
1292
1674
3068

query I rowsort
SELECT DISTINCT col0 + col1 + tab1.col2 AS col0 FROM tab1
----
131
189
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 86 + + col2 + + col1 col0 FROM tab2
----
-1
-28
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9375
SELECT ALL + CAST( ( col1 ) AS SIGNED ) + col1 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-9375
SELECT ALL + CAST ( ( col1 ) AS INTEGER ) + col1 FROM tab1
----
20
26
52

query I rowsort
SELECT - ( - col1 ) + col2 AS col2 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9377
SELECT DISTINCT 54 + col2 * + tab2.col0 * - col2 + col1 DIV - col1 FROM tab2
----
-114023
-5050
-52675

skipif mysql # not compatible
query I rowsort label-9377
SELECT DISTINCT 54 + col2 * + tab2.col0 * - col2 + col1 / - col1 FROM tab2
----
-114023
-5050
-52675

onlyif mysql # use DIV operator for integer division
query I rowsort label-9378
SELECT DISTINCT col0 DIV - 95 + + col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-9378
SELECT DISTINCT col0 / - 95 + + col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9379
SELECT ALL - 86 * + col1 DIV col1 FROM tab1 AS cor0
----
-86
-86
-86

skipif mysql # not compatible
query I rowsort label-9379
SELECT ALL - 86 * + col1 / col1 FROM tab1 AS cor0
----
-86
-86
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9380
SELECT - CAST( NULL AS SIGNED ) * + col0 + col2 * col1 + col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9380
SELECT - CAST ( NULL AS INTEGER ) * + col0 + col2 * col1 + col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 41 * - col0 AS col2 FROM tab0 cor0
----
-1435
-3649
-984

query I rowsort
SELECT ALL + 64 * cor0.col2 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT 48 * - col2 AS col2 FROM tab2 cor0
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT + + ( - cor0.col1 ) FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - ( + col2 ) * + cor0.col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - col1 * + col2 + - cor0.col2 + col0 AS col2 FROM tab0 AS cor0
----
-2847
-63
-7455

query I rowsort
SELECT DISTINCT - 59 + col0 * + col0 FROM tab1 cor0
----
-50
4037
6341

onlyif mysql # use DIV operator for integer division
query I rowsort label-9388
SELECT DISTINCT + 11 DIV cor0.col0 - + col0 AS col0 FROM tab1 AS cor0
----
-64
-80
0

skipif mysql # not compatible
query I rowsort label-9388
SELECT DISTINCT + 11 / cor0.col0 - + col0 AS col0 FROM tab1 AS cor0
----
-64
-80
0

query I rowsort
SELECT + col1 * - col2 * col0 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - 58 + col1 FROM tab1 AS cor0
----
-32
-45
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 81 * - cor0.col0 FROM tab0 AS cor0
----
1944
2835
7209

onlyif mysql # use DIV operator for integer division
query I rowsort label-9393
SELECT DISTINCT - 67 DIV + col0 AS col1 FROM tab2
----
-9
0

skipif mysql # not compatible
query I rowsort label-9393
SELECT DISTINCT - 67 / + col0 AS col1 FROM tab2
----
-9
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 col0 FROM tab2, tab1 cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT - 51 * 37 * - col2 - col0 AS col1 FROM tab1
----
101895
107495
181072

query I rowsort
SELECT DISTINCT 51 * - col0 AS col1 FROM tab1 AS cor0
----
-153
-3264
-4080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 * col2 col2 FROM tab1 AS cor0
----
-5238
-5529
-9312

query I rowsort
SELECT col1 * col0 FROM tab0 WHERE NOT NULL BETWEEN + col2 AND ( tab0.col2 + + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9399
SELECT col1 * + col0 + tab1.col0 DIV tab1.col2 AS col0 FROM tab1
----
1040
641
78

skipif mysql # not compatible
query I rowsort label-9399
SELECT col1 * + col0 + tab1.col0 / tab1.col2 AS col0 FROM tab1
----
1040
641
78

query I rowsort
SELECT ALL col1 + col1 * + col0 + - col2 AS col1 FROM tab1 AS cor0 WHERE NOT ( NULL ) IN ( - col1 + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9401
SELECT ALL cor0.col0 DIV col1 + col1 col0 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9401
SELECT ALL cor0.col0 / col1 + col1 col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + tab0.col0 + col0 + col2 FROM tab0
----
260
71
81

query I rowsort
SELECT - tab2.col0 * + tab2.col2 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 col0 FROM tab0
----
172
182
194

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL NOT BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 + - tab0.col0 col2 FROM tab0
----
-1113
-36
-6813

query I rowsort
SELECT ALL col1 + + col1 * + col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT - col0 * col1 + + tab1.col0 * col0 AS col2 FROM tab1
----
-69
3456
5360

query I rowsort
SELECT DISTINCT - col0 * - col1 + - cor0.col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL - - col2 * - col1 + + col1 * - col2 FROM tab0 AS cor0
----
-14924
-194
-5676

query I rowsort
SELECT DISTINCT - col0 + + col1 * + col0 AS col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT + + col1 + cor0.col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - + col0 * + col0 + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT - - col1 + + col1 - - col0 * + col0 AS col1 FROM tab1 AS cor0
----
4116
61
6426

query I rowsort
SELECT + cor0.col0 * - cor0.col2 * - col0 + - cor0.col2 FROM tab2 AS cor0
----
1296
158158
237120

query I rowsort
SELECT ALL cor0.col1 * + col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 * col0 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-9418
SELECT DISTINCT + - col2 DIV col0 + col0 AS col2 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-9418
SELECT DISTINCT + - col2 / col0 + col0 AS col2 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT - col1 + - col1 * col2 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-9420
SELECT ALL + col1 DIV - cor0.col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-9420
SELECT ALL + col1 / - cor0.col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT + + col0 - col0 * col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL + col2 * - col0 * - col2 - col1 * col0 AS col0 FROM tab0
----
-3360
24072
590337

query I rowsort
SELECT + + col0 * col0 - col0 * - col2 * col2 FROM tab2 AS cor0
----
120317
5152
58812

query I rowsort
SELECT ALL - col1 + tab2.col2 AS col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT tab0.col1 AS col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * tab0.col0 col1 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col0 - col0 * col0 col0 FROM tab0 AS cor0
----
-1190
-623
216

query I rowsort
SELECT DISTINCT + col1 * - col1 + col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT ALL - + col2 - - cor0.col1 * + col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col2 * + cor0.col2 col2 FROM tab2 cor0
----
1482
702
756

query I rowsort
SELECT + col0 + + cor0.col2 * + col0 AS col2 FROM tab1 AS cor0
----
165
3712
7760

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( + col2 )
----

query I rowsort
SELECT ALL + col0 * col0 + col2 * col0 FROM tab2
----
238
8112
9243

query I rowsort
SELECT DISTINCT + 48 + col2 + col0 * col2 AS col0 FROM tab2 cor0
----
2102
264
3088

query I rowsort
SELECT - col2 - col0 * - ( col1 ) * col0 AS col2 FROM tab1 AS cor0
----
180
40903
83104

query I rowsort
SELECT ( + col2 ) * ( - 49 ) * cor0.col2 FROM tab1 AS cor0
----
-142884
-159201
-451584

query I rowsort
SELECT ALL + col0 + + col2 * col1 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT ALL + 74 * col1 AS col0 FROM tab1
----
1924
740
962

query I rowsort
SELECT + - col2 * + col0 - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - - col2 - + col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + col2 * col1 * col2 + col0 FROM tab2 AS cor0
----
22606
24627
39962

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 + + col0 col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - 53 FROM tab1 AS cor0
----
-53
-53
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-9445
SELECT DISTINCT ( tab0.col0 ) DIV - col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-9445
SELECT DISTINCT ( tab0.col0 ) / - col0 FROM tab0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9446
SELECT - 46 DIV + 70 col0 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9446
SELECT - 46 / + 70 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + col0 * - 33 + col2 * cor0.col2 FROM tab1 AS cor0
----
1137
2817
6576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 24 * - col1 col1 FROM tab0 AS cor0
----
-2040
-2095
-2293

query I rowsort
SELECT - - col1 + - 87 AS col2 FROM tab1 AS cor0
----
-61
-74
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9450
SELECT + col0 * CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9450
SELECT + col0 * CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 96 * + col0 FROM tab0
----
2304
3360
8544

query I rowsort
SELECT DISTINCT + 41 FROM tab1
----
41

query I rowsort
SELECT ALL - 19 AS col1 FROM tab0 AS cor0
----
-19
-19
-19

query I rowsort
SELECT - - 58 * - 75 FROM tab2 AS cor0
----
-4350
-4350
-4350

query I rowsort
SELECT + - col2 + - 0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - + ( col0 ) + + col1 AS col0 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + ( col0 * + col1 + + 76 ) col1 FROM tab1 AS cor0
----
1212
208
773

query I rowsort
SELECT DISTINCT tab0.col1 + 32 * - col0 AS col2 FROM tab0
----
-1023
-2757
-682

query I rowsort
SELECT col1 * 30 + col0 * + col1 FROM tab0
----
10829
4644
6305

query I rowsort
SELECT DISTINCT col2 + - 88 AS col2 FROM tab1
----
-31
-34
8

query I rowsort
SELECT DISTINCT col1 + 31 AS col1 FROM tab0
----
117
122
128

query I rowsort
SELECT ( col1 ) * col0 + + 61 AS col1 FROM tab2
----
1404
278
4663

query I rowsort
SELECT DISTINCT + 18 AS col1 FROM tab1
----
18

query I rowsort
SELECT ALL + + 44 AS col1 FROM tab2, tab1 AS cor0, tab1, tab1 cor1
----
81 values hashing to 19a2b9512177749564ba22ea2213fe3f

query I rowsort
SELECT - col1 * - col0 * - col0 AS col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL - 99 - - col0 * - cor0.col1 FROM tab2 AS cor0
----
-1442
-316
-4701

query I rowsort
SELECT DISTINCT + col0 * + 17 FROM tab2 AS cor0
----
119
1326
1343

onlyif mysql # use DIV operator for integer division
query I rowsort label-9468
SELECT DISTINCT 66 + ( cor0.col0 ) DIV ( 73 + + col2 ) FROM tab2 AS cor0
----
66

skipif mysql # not compatible
query I rowsort label-9468
SELECT DISTINCT 66 + ( cor0.col0 ) / ( 73 + + col2 ) FROM tab2 AS cor0
----
66

query I rowsort
SELECT DISTINCT + - col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - col0 * - 99 - + col0 * col2 AS col1 FROM tab0 cor0
----
1513
1584
3430

query I rowsort
SELECT DISTINCT - 6 + - cor0.col1 * + col2 FROM tab2 AS cor0
----
-1540
-652
-843

query I rowsort
SELECT DISTINCT - + col2 * 49 + + col2 FROM tab0 AS cor0
----
-1584
-3936
-48

query I rowsort
SELECT ALL ( + 49 ) * + cor0.col2 + + col1 AS col2 FROM tab0 AS cor0
----
146
1703
4109

query I rowsort
SELECT DISTINCT - col0 - - col0 * 62 AS col0 FROM tab0
----
1464
2135
5429

query I rowsort
SELECT DISTINCT - 41 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
-41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9476
SELECT col1 + - col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9476
SELECT col1 + - col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 - cor0.col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col2 + col0 + + 43 FROM tab1 cor0
----
100
164
219

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9479
SELECT + + ( col1 ) * + CAST( col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-9479
SELECT + + ( col1 ) * + CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT col1 * + 43 + col2 FROM tab2 cor0
----
1360
2563
769

query I rowsort
SELECT ALL col1 * + 74 + + col1 FROM tab2
----
1275
2325
4425

query IIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0 WHERE NULL <> NULL
----

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-9484
SELECT + col0 DIV ( col0 + + col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9484
SELECT + col0 / ( col0 + + col1 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9485
SELECT + col2 * cor0.col1 DIV - cor0.col2 + + col0 FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-9485
SELECT + col2 * cor0.col1 / - cor0.col2 + + col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + ( col2 ) + ( 59 ) * - col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-9487
SELECT + - col2 DIV - col1 AS col2 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-9487
SELECT + - col2 / - col1 AS col2 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT + + col0 + cor0.col1 + ( 36 ) AS col1 FROM tab1 cor0
----
110
129
65

query I rowsort
SELECT ALL + 3 + col1 FROM tab2 AS cor0
----
20
34
62

query I rowsort
SELECT DISTINCT + - col2 + col0 AS col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT - ( - cor0.col1 ) * cor0.col2 + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT col1 + cor0.col0 * col1 * 19 FROM tab1 AS cor0
----
12170
1508
19773

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9493
SELECT CAST( NULL AS DECIMAL ) + - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9493
SELECT CAST ( NULL AS REAL ) + - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 87 * - col1 + col1 FROM tab2 AS cor0
----
-1462
-2666
-5074

query I rowsort
SELECT 52 * + col0 FROM tab2 cor0
----
364
4056
4108

query I rowsort
SELECT DISTINCT 38 + + col2 FROM tab1 AS cor0
----
134
92
95

query I rowsort
SELECT ( + col0 ) + 58 * col0 FROM tab0
----
1416
2065
5251

query I rowsort
SELECT DISTINCT - - 10 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
10

query I rowsort
SELECT ALL + 51 * - cor0.col2 * 15 FROM tab2, tab0 AS cor0
----
9 values hashing to 090958e503dbaa70482a4dcf77b93e1c

query I rowsort
SELECT ALL - - col0 * 67 - - col2 FROM tab0 AS cor0
----
1641
2346
6045

query I rowsort
SELECT ALL + - cor0.col1 * 99 FROM tab1 AS cor0
----
-1287
-2574
-990

query I rowsort
SELECT ALL + cor1.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL 43 * cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
27778
35991
65962

onlyif mysql # use DIV operator for integer division
query I rowsort label-9504
SELECT ( + col0 ) DIV col2 + + tab0.col1 FROM tab0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-9504
SELECT ( + col0 ) / col2 + + tab0.col1 FROM tab0
----
132
86
92

query I rowsort
SELECT + col0 * - col1 + + col0 + col1 FROM tab0
----
-1954
-3263
-7919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9506
SELECT CAST( NULL AS DECIMAL ) * + 57 + col0 - - tab1.col0 * - 14 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9506
SELECT CAST ( NULL AS REAL ) * + 57 + col0 - - tab1.col0 * - 14 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * ( col2 ) AS col0 FROM tab1
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9508
SELECT DISTINCT CAST( NULL AS SIGNED ) + + 43 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9508
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + 43 FROM tab2
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9509
SELECT DISTINCT - CAST( NULL AS SIGNED ) / + col1 + col0 AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9509
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / + col1 + col0 AS col1 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - + col2 * + 18 - col1 FROM tab1 AS cor0
----
-1036
-1741
-998

query I rowsort
SELECT DISTINCT + - col0 - 92 FROM tab1 AS cor0
----
-156
-172
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9512
SELECT ALL - CAST( + col1 AS SIGNED ) + - col2 col0 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9512
SELECT ALL - CAST ( + col1 AS INTEGER ) + - col2 col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT tab2.col2 * col1 * tab2.col0 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL col2 * col0 + - col2 AS col2 FROM tab2
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-9515
SELECT ALL col1 * + 8 + col0 DIV - 64 FROM tab0
----
688
727
776

skipif mysql # not compatible
query I rowsort label-9515
SELECT ALL col1 * + 8 + col0 / - 64 FROM tab0
----
688
727
776

query I rowsort
SELECT ALL - + ( - col0 ) FROM tab1 AS cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9517
SELECT DISTINCT cor1.col1 * CAST( - 2 AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-9517
SELECT DISTINCT cor1.col1 * CAST ( - 2 AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
-118
-34
-62

query I rowsort
SELECT DISTINCT col2 * + col0 - + cor0.col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL - 77 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT + - cor0.col0 * col2 + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT 25 * + col0 + + 55 FROM tab2 AS cor0
----
2005
2030
230

query I rowsort
SELECT DISTINCT col1 + 74 AS col0 FROM tab0 AS cor0
----
160
165
171

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9523
SELECT DISTINCT - col0 * - CAST( + col2 AS SIGNED ) * col0 AS col0 FROM tab2
----
1323
158184
237158

skipif mysql # not compatible
query I rowsort label-9523
SELECT DISTINCT - col0 * - CAST ( + col2 AS INTEGER ) * col0 AS col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL - - col1 + - col2 * 65 FROM tab1 AS cor0
----
-3484
-3695
-6227

query I rowsort
SELECT - cor0.col2 * - 61 AS col0 FROM tab2 cor0
----
1586
1647
2318

query I rowsort
SELECT DISTINCT col1 * ( - col2 ) AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col1 * + ( + 96 ) + col1 FROM tab2 AS cor0
----
-1615
-2945
-5605

onlyif mysql # use DIV operator for integer division
query I rowsort label-9528
SELECT + 96 - 74 DIV + col1 FROM tab1 AS cor0
----
89
91
94

skipif mysql # not compatible
query I rowsort label-9528
SELECT + 96 - 74 / + col1 FROM tab1 AS cor0
----
89
91
94

query I rowsort
SELECT ALL - ( + 18 ) FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + 63 * col2 - col2 FROM tab0 AS cor0
----
2046
5084
62

query I rowsort
SELECT DISTINCT col2 * - 47 FROM tab2 cor0
----
-1222
-1269
-1786

onlyif mysql # use DIV operator for integer division
query I rowsort label-9532
SELECT - cor0.col2 DIV + cor0.col0 + cor0.col1 AS col2 FROM tab1 cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-9532
SELECT - cor0.col2 / + cor0.col0 + cor0.col1 AS col2 FROM tab1 cor0
----
10
12
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9533
SELECT ALL CAST( NULL AS DECIMAL ) * 76 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9533
SELECT ALL CAST ( NULL AS REAL ) * 76 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 3 col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9535
SELECT CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9535
SELECT CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + 37 * tab2.col1 * + col2 FROM tab2
----
23902
30969
56758

query I rowsort
SELECT DISTINCT col2 + + col1 + - col0 AS col1 FROM tab0
----
63
84
95

query I rowsort
SELECT ( col0 * + ( - col0 ) + - col1 ) AS col2 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT + col0 * cor0.col0 * - col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - 60 * col1 FROM tab2
----
-1020
-1860
-3540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9541
SELECT + + col1 * + CAST( - col2 AS SIGNED ) + col2 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-9541
SELECT + + col1 * + CAST ( - col2 AS INTEGER ) + col2 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT cor0.col0 * col1 AS col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT 65 + + col2 * col1 FROM tab1 AS cor0
----
1313
1469
635

onlyif mysql # use DIV operator for integer division
query I rowsort label-9544
SELECT - + 63 DIV - 55 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9544
SELECT - + 63 / - 55 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - + col0 + col1 * + col1 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT + - ( - 7 ) + col0 AS col1 FROM tab0 AS cor0
----
31
42
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9547
SELECT + CAST( NULL AS SIGNED ) * + col2 + col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9547
SELECT + CAST ( NULL AS INTEGER ) * + col2 + col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9548
SELECT DISTINCT + col1 * CAST( NULL AS SIGNED ) + + 54 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9548
SELECT DISTINCT + col1 * CAST ( NULL AS INTEGER ) + + 54 AS col2 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT ( - 82 ) * col2 FROM tab2
----
-2132
-2214
-3116

query I rowsort
SELECT + 79 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col2 AS REAL ) * tab2.col1 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT col1 * + 75 FROM tab0
----
6450
6825
7275

query I rowsort
SELECT 28 * + col0 FROM tab1
----
1792
2240
84

query I rowsort
SELECT - 67 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to fbe03b15d6b951410b38f7e98895006f

onlyif mysql # use DIV operator for integer division
query I rowsort label-9555
SELECT + col0 + + col2 DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9555
SELECT + col0 + + col2 / cor0.col1 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 95 * col1 FROM tab2 AS cor0
----
1615
2945
5605

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) + ( col1 ) FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9558
SELECT ALL - + cor0.col2 DIV + col0 + col0 col1 FROM tab0 AS cor0
----
23
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9558
SELECT ALL - + cor0.col2 / + col0 + col0 col1 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT + col2 * - cor0.col1 + - ( + col0 ) FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL - 0 * + col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9561
SELECT col1 + col0 * CAST( - cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
-706
-7207
62

skipif mysql # not compatible
query I rowsort label-9561
SELECT col1 + col0 * CAST ( - cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9562
SELECT DISTINCT col0 DIV cor0.col0 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-9562
SELECT DISTINCT col0 / cor0.col0 FROM tab2 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9563
SELECT DISTINCT - + col1 DIV col1 + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-9563
SELECT DISTINCT - + col1 / col1 + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL + - 14 AS col2 FROM tab2 AS cor0
----
-14
-14
-14

onlyif mysql # use DIV operator for integer division
query I rowsort label-9565
SELECT col0 * + col1 + - col1 DIV col1 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-9565
SELECT col0 * + col1 + - col1 / col1 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT ALL - - 72 + - col1 FROM tab2 AS cor0
----
13
41
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9567
SELECT ALL cor0.col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9567
SELECT ALL cor0.col2 / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( - col0 ) + col2 - col2 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9569
SELECT DISTINCT - - col0 + - col1 DIV - col1 AS col2 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-9569
SELECT DISTINCT - - col0 + - col1 / - col1 AS col2 FROM tab0 cor0
----
25
36
90

query I rowsort
SELECT 20 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9571
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9571
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 42 col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT DISTINCT ( col1 ) + - col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT + + col1 + - col2 * - 73 FROM tab0 AS cor0
----
170
2495
6077

query I rowsort
SELECT + 6 FROM tab2, tab0 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT DISTINCT - - col2 - + 9 FROM tab1 AS cor0
----
45
48
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + cor0.col1 col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - col1 - tab2.col2 AS col0 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL ( col0 ) - + col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT + 47 * - 60 + + col2 + col2 AS col0 FROM tab1
----
-2628
-2706
-2712

onlyif mysql # use DIV operator for integer division
query I rowsort label-9581
SELECT DISTINCT 5 DIV - col2 - - col1 AS col1 FROM tab0
----
86
91
92

skipif mysql # not compatible
query I rowsort label-9581
SELECT DISTINCT 5 / - col2 - - col1 AS col1 FROM tab0
----
86
91
92

query I rowsort
SELECT 5 - + col0 * col0 * + ( - col1 * tab2.col0 + col2 ) FROM tab2
----
27840389
8144510
9315

query I rowsort
SELECT 48 * col1 - col0 AS col0 FROM tab1 AS cor0
----
1245
416
544

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * cor0.col1 col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - + col0 - col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + 8 * cor0.col1 - - col1 AS col2 FROM tab1 AS cor0
----
117
234
90

query I rowsort
SELECT DISTINCT col0 + - col1 * col2 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-9588
SELECT ALL - - col1 DIV - col1 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9588
SELECT ALL - - col1 / - col1 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9589
SELECT - - CAST( NULL AS SIGNED ) + - 75 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9589
SELECT - - CAST ( NULL AS INTEGER ) + - 75 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 0 + - col1 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - 22 FROM tab0, tab0 AS cor0, tab2 cor1
----
-22

query I rowsort
SELECT ALL col0 * 52 FROM tab1
----
156
3328
4160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9593
SELECT + col2 DIV col0 col2 FROM tab2 cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9593
SELECT + col2 / col0 col2 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT + cor0.col2 + - 64 AS col0 FROM tab1 cor0
----
-10
-7
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( cor1.col0 ) col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 64 * col0 col1 FROM tab1 cor0
----
246
4153
5216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9597
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9597
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL - col1 * + col1 + - col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT - - col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col0 col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - col1 * - cor0.col2 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL col1 * - 89 * col0 AS col2 FROM tab1 AS cor0
----
-56960
-6942
-92560

query I rowsort
SELECT + col0 + - ( - col2 ) + col2 AS col0 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT DISTINCT cor0.col0 + + col2 + - 20 FROM tab1 AS cor0
----
101
156
37

query I rowsort
SELECT col1 + - 2 - + col2 * - col2 FROM tab1 cor0
----
2940
3257
9227

query I rowsort
SELECT DISTINCT + - col1 + col2 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - col1 + 92 AS col0 FROM tab1 AS cor0
----
66
79
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 7 col1 FROM tab0 AS cor0
----
-79
-84
-90

query I rowsort
SELECT + col0 * col2 + + col1 + col1 AS col2 FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT DISTINCT + ( + col2 ) * + col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT + ( - 78 ) FROM tab1 AS cor0
----
-78
-78
-78

query I rowsort
SELECT - - col0 * 71 * col2 FROM tab0 AS cor0
----
2485
518158
56232

onlyif mysql # use DIV operator for integer division
query I rowsort label-9613
SELECT - col2 * col0 DIV - col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9613
SELECT - col2 * col0 / - col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col1 + cor0.col1 AS col2 FROM tab1 cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-9615
SELECT ALL + col2 + tab2.col0 DIV + col0 + col0 FROM tab2
----
105
118
35

skipif mysql # not compatible
query I rowsort label-9615
SELECT ALL + col2 + tab2.col0 / + col0 + col0 FROM tab2
----
105
118
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-9616
SELECT DISTINCT - tab0.col0 + ( - col0 ) DIV col0 FROM tab0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-9616
SELECT DISTINCT - tab0.col0 + ( - col0 ) / col0 FROM tab0
----
-25
-36
-90

query I rowsort
SELECT ALL - + col1 * col0 + + col2 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-9618
SELECT ALL - cor0.col0 * cor0.col2 + 3 DIV - col0 + + col2 AS col0 FROM tab0 cor0
----
-34
-7216
-759

skipif mysql # not compatible
query I rowsort label-9618
SELECT ALL - cor0.col0 * cor0.col2 + 3 / - col0 + + col2 AS col0 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT col0 * + cor0.col1 + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - col0 + - col2 + 35 * + 77 * - col2 AS col0 FROM tab1 AS cor0
----
-145587
-153736
-258896

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-9622
SELECT + cor0.col2 + col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-9622
SELECT + cor0.col2 + col1 / + col1 AS col2 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 4 + col1 * col1 col0 FROM tab0 AS cor0
----
7400
8285
9413

query I rowsort
SELECT ALL ( - col2 ) + + col2 * + 72 FROM tab0 AS cor0
----
2343
5822
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-9625
SELECT - col2 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-9625
SELECT - col2 / cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT - 5 + col1 AS col1 FROM tab0 AS cor0
----
81
86
92

query I rowsort
SELECT ALL + col1 - + col2 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL + 50 - - col0 AS col1 FROM tab1
----
114
130
53

query I rowsort
SELECT 47 * 78 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to b5bbc36d2693b40db49348ff84bfec0b

query I rowsort
SELECT ALL ( col1 * 66 ) - 42 FROM tab0
----
5634
5964
6360

onlyif mysql # use DIV operator for integer division
query I rowsort label-9631
SELECT DISTINCT col1 + col0 DIV - 4 FROM tab0 AS cor0
----
69
80
89

skipif mysql # not compatible
query I rowsort label-9631
SELECT DISTINCT col1 + col0 / - 4 FROM tab0 AS cor0
----
69
80
89

query I rowsort
SELECT ALL + 69 * tab1.col2 - 56 AS col2 FROM tab1
----
3670
3877
6568

query I rowsort
SELECT - 98 + + col2 + + ( - 74 ) * col2 FROM tab1
----
-4040
-4259
-7106

query I rowsort
SELECT 25 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT DISTINCT - 90 FROM tab2, tab1 AS cor0
----
-90

query I rowsort
SELECT + cor0.col1 - 71 AS col0 FROM tab2 cor0
----
-12
-40
-54

query I rowsort
SELECT col1 - 15 AS col0 FROM tab0 AS cor0
----
71
76
82

query I rowsort
SELECT DISTINCT - col1 * 75 * col1 + col2 - col0 AS col0 FROM tab2 AS cor0
----
-21716
-261127
-72055

onlyif mysql # use DIV operator for integer division
query I rowsort label-9639
SELECT col1 + + 44 DIV col1 AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9639
SELECT col1 + + 44 / col1 AS col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9640
SELECT DISTINCT - col2 + + ( - col2 ) DIV - col2 col1 FROM tab0 cor0
----
-32
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9640
SELECT DISTINCT - col2 + + ( - col2 ) / - col2 col1 FROM tab0 cor0
----
-32
-81
0

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ( - tab1.col2 ) + + tab1.col1 AS col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT 82 + cor0.col2 FROM tab2 AS cor0
----
108
109
120

query I rowsort
SELECT - ( + col0 ) + col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT - + col2 * col0 + + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL - + 49 - - col0 FROM tab2 AS cor0
----
-42
29
30

query I rowsort
SELECT ALL 76 + - cor0.col1 + - 85 * cor0.col0 FROM tab1 AS cor0
----
-205
-5374
-6737

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9648
SELECT CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9648
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + + col2 + + cor0.col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col0 + col2 * + col0 AS col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9651
SELECT - + col0 * col0 DIV 45 AS col2 FROM tab1 AS cor0
----
-142
-91
0

skipif mysql # not compatible
query I rowsort label-9651
SELECT - + col0 * col0 / 45 AS col2 FROM tab1 AS cor0
----
-142
-91
0

query I rowsort
SELECT ALL + cor0.col2 * cor0.col0 - - 67 FROM tab1 AS cor0
----
229
3715
7747

query I rowsort
SELECT DISTINCT 34 * + col1 FROM tab2 AS cor0
----
1054
2006
578

query I rowsort
SELECT DISTINCT - col1 / + tab1.col1 FROM tab1 WHERE NULL < - col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + tab0.col0 col1 FROM tab0 WHERE col1 IN ( col1 - tab0.col0 )
----

query I rowsort
SELECT 7 + + col2 AS col2 FROM tab1 AS cor0
----
103
61
64

query I rowsort
SELECT - col2 + + tab1.col0 AS col1 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9658
SELECT DISTINCT + tab1.col1 DIV + col2 col2 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9658
SELECT DISTINCT + tab1.col1 / + col2 col2 FROM tab1
----
0

query I rowsort
SELECT - col2 * - col1 * - col0 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-9660
SELECT ALL col0 * col2 DIV + col2 col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9660
SELECT ALL col0 * col2 / + col2 col1 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9661
SELECT ALL col2 * - tab1.col2 + + col1 * + col1 DIV col1 AS col0 FROM tab1
----
-2890
-3239
-9203

skipif mysql # not compatible
query I rowsort label-9661
SELECT ALL col2 * - tab1.col2 + + col1 * + col1 / col1 AS col0 FROM tab1
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 + - col0 col2 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT col0 + - col1 + - 16 FROM tab0
----
-18
-78

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab2 AS cor0 WHERE NULL NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9665
SELECT DISTINCT + col2 + col1 DIV col0 + + col1 FROM tab1
----
109
67
88

skipif mysql # not compatible
query I rowsort label-9665
SELECT DISTINCT + col2 + col1 / col0 + + col1 FROM tab1
----
109
67
88

query I rowsort
SELECT 64 AS col1 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT + + col1 * col0 + 98 * - col1 AS col2 FROM tab0 AS cor0
----
-6111
-6364
-819

query I rowsort
SELECT ALL 83 + 89 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to a46da130df0d0bf3cb83aa16c2b7ab83

query I rowsort
SELECT DISTINCT + col0 FROM tab0 WHERE NULL BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9670
SELECT DISTINCT - col2 DIV + col1 + - col1 AS col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9670
SELECT DISTINCT - col2 / + col1 + - col1 AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + col0 * - col2 + col1 AS col2 FROM tab1
----
-136
-3638
-7667

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT col0 * col0 - col1 * col0 * - col0 AS col0 FROM tab1
----
243
45056
89600

query I rowsort
SELECT DISTINCT col1 + + col1 * + tab0.col0 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL - col0 * col0 + + col0 AS col1 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT ALL - col2 * col1 + - col1 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT col1 * col1 * col1 FROM tab0 WHERE NOT - col0 * + col0 + - col2 IN ( - col2 )
----
636056
753571
912673

query I rowsort
SELECT + col0 + + col2 * col0 FROM tab1
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9679
SELECT col1 * col2 DIV col0 AS col2 FROM tab2
----
119
19
8

skipif mysql # not compatible
query I rowsort label-9679
SELECT col1 * col2 / col0 AS col2 FROM tab2
----
119
19
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL tab0.col0 + + col1 * - col1 * col1 + + col2 AS col0 FROM tab0
----
-635999
-753400
-912637

query III rowsort
SELECT * FROM tab2 WHERE + col2 + + col0 >= NULL
----

query I rowsort
SELECT + col2 + + col2 + - tab1.col1 * + tab1.col1 AS col2 FROM tab1
----
-568
14
23

query I rowsort
SELECT DISTINCT + tab1.col1 + - col1 * col1 + + col2 * col2 AS col2 FROM tab1
----
2266
3159
9060

query I rowsort
SELECT col2 * col2 * + col1 AS col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT - col2 * - col2 + col1 FROM tab2
----
1461
735
760

query I rowsort
SELECT col1 + + col0 + - col0 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * tab2.col0 col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT tab2.col0 * + col0 - col2 * - col0 FROM tab2
----
238
8112
9243

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( col0 + col1 )
----

query I rowsort
SELECT ALL col0 * col1 + + tab0.col1 * + col0 FROM tab0
----
16198
4128
6790

query I rowsort
SELECT ALL + tab2.col1 + 95 AS col0 FROM tab2
----
112
126
154

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 * tab2.col1 + - col0 col0 FROM tab2
----
-1507
-2611
-5034

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9694
SELECT - ( col2 ) - + col1 * + CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
251
3455
934

skipif mysql # not compatible
query I rowsort label-9694
SELECT - ( col2 ) - + col1 * + CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
251
3455
934

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-9696
SELECT DISTINCT - - 72 DIV + 79 + col2 AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-9696
SELECT DISTINCT - - 72 / + 79 + col2 AS col0 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col1 ) + col1 + + col1 col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ALL + 24 * col0 FROM tab2 AS cor0
----
168
1872
1896

query I rowsort
SELECT - - col1 * + col2 + + cor0.col0 * 44 * 98 AS col0 FROM tab2 AS cor0
----
31021
337870
341294

query I rowsort
SELECT DISTINCT - 9 FROM tab1, tab1 AS cor0
----
-9

query I rowsort
SELECT - cor0.col0 + + col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + col0 + col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT ALL - col1 + col2 + col0 AS col1 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT DISTINCT + col0 - col0 * col0 AS col2 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-9705
SELECT + cor0.col2 DIV + col0 - ( ( col0 ) ) * - cor0.col1 FROM tab0 AS cor0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-9705
SELECT + cor0.col2 / + col0 - ( ( col0 ) ) * - cor0.col1 FROM tab0 AS cor0
----
2065
3395
8099

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 + 19 FROM tab2 cor0
----
-1324
-198
-4583

query I rowsort
SELECT ALL - 70 * + col0 FROM tab0 AS cor0
----
-1680
-2450
-6230

onlyif mysql # use DIV operator for integer division
query I rowsort label-9708
SELECT col2 * - col0 + ( col0 ) DIV + cor0.col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-2053
-216
-3036

skipif mysql # not compatible
query I rowsort label-9708
SELECT col2 * - col0 + ( col0 ) / + cor0.col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-2053
-216
-3036

query I rowsort
SELECT ALL + 71 * col2 FROM tab1 AS cor0
----
3834
4047
6816

query I rowsort
SELECT - + 19 * + col1 FROM tab1 AS cor0
----
-190
-247
-494

query I rowsort
SELECT DISTINCT - cor0.col0 * - col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 * - col2 * ( + col0 ) + - col2 + 96 FROM tab0 AS cor0
----
-1130
-18945
-649508

query I rowsort
SELECT ALL - 73 * col2 AS col2 FROM tab2 cor0
----
-1898
-1971
-2774

query I rowsort
SELECT - col1 - + col2 * ( + col2 + - col2 ) * col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - 29 * tab2.col1 FROM tab2, tab2 AS cor0
----
-1711
-493
-899

query I rowsort
SELECT DISTINCT + - ( - col1 ) + + cor0.col1 * + col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT - - ( col0 ) + - col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT 88 * + col2 + - col0 * + col1 AS col0 FROM tab0 AS cor0
----
-3307
-883
840

query I rowsort
SELECT - col1 + 16 * + col1 FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT DISTINCT + col2 * - col0 * col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT - col2 * + 48 + col2 + - col2 * col1 FROM tab1 AS cor0
----
-3249
-3942
-5760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9722
SELECT + col2 / - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9722
SELECT + col2 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9723
SELECT CAST( NULL AS SIGNED ) col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9723
SELECT CAST ( NULL AS INTEGER ) col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL 14 * tab2.col0 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to f3b09edfd57b0acdc16a19521102f202

query I rowsort
SELECT + col2 + + col1 * + col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL cor0.col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col2 * + ( + 95 ) AS col2 FROM tab1 AS cor0
----
5130
5415
9120

query I rowsort
SELECT DISTINCT col1 + cor0.col0 AS col2 FROM tab2 cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 * - col2 col0 FROM tab2 AS cor0
----
17576
19683
54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-9730
SELECT DISTINCT 17 DIV - col0 + + col2 col1 FROM tab1 AS cor0
----
49
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9730
SELECT DISTINCT 17 / - col0 + + col2 col1 FROM tab1 AS cor0
----
49
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 31 + + col0 * + col2 col2 FROM tab0 AS cor0
----
4
7267
761

onlyif mysql # use DIV operator for integer division
query I rowsort label-9732
SELECT ALL + col2 DIV - cor0.col1 AS col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-9732
SELECT ALL + col2 / - cor0.col1 AS col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT - 78 + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1170
1326
492

query I rowsort
SELECT DISTINCT - - cor0.col0 * col2 + col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-9735
SELECT col2 * + col2 DIV + col2 + tab1.col1 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-9735
SELECT col2 * + col2 / + col2 + tab1.col1 FROM tab1
----
109
67
80

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab0, tab2 cor2
----
3645 values hashing to 71180f9f3efadf0ee3a7fec9678208ad

query I rowsort
SELECT - col2 + 0 AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + 82 AS col1 FROM tab2
----
82

query I rowsort
SELECT col1 * - col1 + col1 AS col1 FROM tab2 cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT + 1 FROM tab2, tab1 AS cor0
----
1

query I rowsort
SELECT + ( + col1 * col1 + - col1 ) FROM tab2
----
272
3422
930

query I rowsort
SELECT 71 + + 87 FROM tab2
----
158
158
158

query I rowsort
SELECT + 41 + col0 AS col1 FROM tab0
----
130
65
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) + - col2 col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL - + col0 + col2 * col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT ALL + 74 + col1 * col1 FROM tab2 AS cor0
----
1035
3555
363

query I rowsort
SELECT 28 * col1 + col1 AS col1 FROM tab0 AS cor0
----
2494
2639
2813

query I rowsort
SELECT - - col0 * + col0 + + col2 AS col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL - ( + col2 ) + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 * - col1 + + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - - 78 + + col0 AS col1 FROM tab0 AS cor0
----
102
113
167

query I rowsort
SELECT ALL 27 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1275
1431
597

query I rowsort
SELECT DISTINCT + col2 - cor0.col1 AS col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + col0 * ( ( + col1 ) * col2 ) + + cor0.col1 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT + col2 + + col2 * + col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 15 + - 83 col2 FROM tab1 AS cor0
----
-38
1117
877

query I rowsort
SELECT ALL + col1 * - col1 * - col1 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT DISTINCT + - 4 * + col2 AS col1 FROM tab2 AS cor0
----
-104
-108
-152

query I rowsort
SELECT DISTINCT - 31 + + 74 FROM tab0 AS cor0
----
43

query I rowsort
SELECT ALL - col0 * col2 - col0 * col0 FROM tab0 cor0
----
-1260
-1368
-15219

query I rowsort
SELECT DISTINCT + - 53 + + col2 FROM tab1 AS cor0
----
1
4
43

query I rowsort
SELECT ALL - + 14 - - col2 FROM tab1 AS cor0
----
40
43
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9763
SELECT + cor0.col0 DIV + cor0.col0 + + cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to a4eb83f40d87ef4bb021bb35a3b03309

skipif mysql # not compatible
query I rowsort label-9763
SELECT + cor0.col0 / + cor0.col0 + + cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to a4eb83f40d87ef4bb021bb35a3b03309

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9764
SELECT + + CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9764
SELECT + + CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + 71 FROM tab2 AS cor0
----
1207
2201
4189

query I rowsort
SELECT DISTINCT - + col0 * 5 * col0 AS col2 FROM tab0 AS cor0
----
-2880
-39605
-6125

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9767
SELECT ALL + col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9767
SELECT ALL + col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + + ( + col0 ) * col2 + - col1 FROM tab0 cor0
----
-159
620
7116

query I rowsort
SELECT + ( cor0.col0 ) * - col2 AS col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT cor0.col2 + col0 FROM tab1 AS cor0 WHERE col0 / - col0 IN ( col2 ) OR col2 * + col0 BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * tab2.col2 col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT col2 + - col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT + + cor0.col0 + + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - - cor0.col0 + + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN - col0 * col0 AND NULL
----

query I rowsort
SELECT col0 * - col1 * cor0.col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT tab1.col0 - col0 AS col2 FROM tab1 WHERE col0 = col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9778
SELECT - - col1 DIV - col1 col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9778
SELECT - - col1 / - col1 col0 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9779
SELECT + col2 + + cor0.col0 DIV col0 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-9779
SELECT + col2 + + cor0.col0 / col0 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9780
SELECT + - col2 DIV + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-9780
SELECT + - col2 / + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col1 col0 FROM tab2
----
55
58
85

query I rowsort
SELECT 19 * + col2 + + col0 * col2 FROM tab2
----
2522
3724
702

query I rowsort
SELECT ALL 24 + + col0 FROM tab0
----
113
48
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 * col0 col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT tab2.col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT col2 * + col1 + + col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-9787
SELECT col1 * col0 DIV + col1 + + col0 DIV - col0 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-9787
SELECT col1 * col0 / + col1 + + col0 / - col0 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT ALL + tab1.col2 * + col1 AS col2 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-9789
SELECT ALL col2 DIV col1 AS col2 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-9789
SELECT ALL col2 / col1 AS col2 FROM tab2
----
0
0
2

query I rowsort
SELECT cor0.col0 * - cor0.col0 - - col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT - - col0 + - ( col1 ) + col2 * + ( col1 ) FROM tab0 AS cor0
----
2776
35
7460

query I rowsort
SELECT DISTINCT cor0.col2 + - ( 34 ) FROM tab0 AS cor0
----
-1
-33
48

query I rowsort
SELECT DISTINCT + cor0.col1 * ( 84 ) FROM tab1 AS cor0
----
1092
2184
840

onlyif mysql # use DIV operator for integer division
query I rowsort label-9794
SELECT ALL + 38 + + 88 DIV col2 FROM tab1 AS cor0
----
38
39
39

skipif mysql # not compatible
query I rowsort label-9794
SELECT ALL + 38 + + 88 / col2 FROM tab1 AS cor0
----
38
39
39

query I rowsort
SELECT DISTINCT + 37 + - ( col1 + + 85 ) FROM tab1 AS cor0
----
-58
-61
-74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9796
SELECT DISTINCT - col2 - + CAST( NULL AS DECIMAL ) * + col1 AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9796
SELECT DISTINCT - col2 - + CAST ( NULL AS REAL ) * + col1 AS col1 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9797
SELECT ALL col1 - 96 DIV col1 FROM tab2
----
12
28
58

skipif mysql # not compatible
query I rowsort label-9797
SELECT ALL col1 - 96 / col1 FROM tab2
----
12
28
58

query I rowsort
SELECT col2 * 54 FROM tab0
----
1782
4428
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-9799
SELECT - cor0.col1 DIV col2 + cor0.col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9799
SELECT - cor0.col1 / col2 + cor0.col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + + ( + cor0.col0 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - cor0.col1 AS col2 FROM tab1, tab0, tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT ( col0 ) * + col0 AS col1 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - col0 * + col2 + - col1 AS col2 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT + ( - cor0.col1 ) * + 3 AS col1 FROM tab0 AS cor0
----
-258
-273
-291

query I rowsort
SELECT + - col0 * - col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col0 * col1 AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - tab0.col2 * col1 AS col0 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9808
SELECT DISTINCT col1 * col0 DIV + ( - 43 ) FROM tab1
----
-1
-14
-24

skipif mysql # not compatible
query I rowsort label-9808
SELECT DISTINCT col1 * col0 / + ( - 43 ) FROM tab1
----
-1
-14
-24

query I rowsort
SELECT DISTINCT + ( col1 ) * - 85 FROM tab1
----
-1105
-2210
-850

query I rowsort
SELECT 35 - + col2 AS col0 FROM tab0
----
-47
2
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * cor0.col1 * col0 col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT + 99 * col0 AS col0 FROM tab2 AS cor0
----
693
7722
7821

query I rowsort
SELECT + ( + 50 ) FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

query I rowsort
SELECT DISTINCT - + cor0.col1 * col0 + 10 AS col1 FROM tab0 AS cor0
----
-2054
-3385
-8089

query I rowsort
SELECT DISTINCT - col2 + col2 * col2 * + col1 AS col0 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT DISTINCT col0 + + 20 AS col0 FROM tab0 AS cor0
----
109
44
55

query I rowsort
SELECT ALL + - col1 * col1 + - col0 - col0 * ( 98 ) AS col0 FROM tab0 AS cor0
----
-12874
-17092
-9772

query I rowsort
SELECT DISTINCT col1 + + ( 45 ) AS col1 FROM tab1
----
55
58
71

query I rowsort
SELECT ALL col2 + ( - col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + + col2 + - 2 AS col1 FROM tab0 AS cor0
----
-1
31
80

query I rowsort
SELECT - col2 + 79 * col1 FROM tab2 AS cor0
----
1305
2422
4635

query I rowsort
SELECT ALL - + col1 * - 74 * 82 AS col0 FROM tab0 AS cor0
----
521848
552188
588596

query I rowsort
SELECT + + col1 * col1 * col0 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT ALL + col0 * + ( col2 ) - col1 * + 62 AS col0 FROM tab2 AS cor0
----
-1630
-1733
1948

query I rowsort
SELECT + + col2 * + 41 * 6 AS col1 FROM tab2 AS cor0
----
6396
6642
9348

query I rowsort
SELECT - col0 * + 62 FROM tab0 AS cor0
----
-1488
-2170
-5518

query I rowsort
SELECT 66 * col1 AS col1 FROM tab2 AS cor0
----
1122
2046
3894

onlyif mysql # use DIV operator for integer division
query I rowsort label-9828
SELECT col2 DIV - 51 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9828
SELECT col2 / - 51 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * + ( + col0 ) * 68 + ( col1 ) * 80 - 7 * + tab0.col1 AS col1 FROM tab0
----
-134074
-223779
-544089

query I rowsort
SELECT 17 FROM tab1, tab2 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT ALL ( - cor0.col2 ) * col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - 37 col1 FROM tab2 AS cor0
----
-1406
-962
-999

onlyif mysql # use DIV operator for integer division
query I rowsort label-9833
SELECT - col0 * 91 + cor0.col1 DIV + ( + col1 ) FROM tab1 AS cor0
----
-272
-5823
-7279

skipif mysql # not compatible
query I rowsort label-9833
SELECT - col0 * 91 + cor0.col1 / + ( + col1 ) FROM tab1 AS cor0
----
-272
-5823
-7279

onlyif mysql # use DIV operator for integer division
query I rowsort label-9834
SELECT DISTINCT + col2 * + 38 + + col1 DIV + 12 AS col2 FROM tab1 AS cor0
----
2054
2166
3649

skipif mysql # not compatible
query I rowsort label-9834
SELECT DISTINCT + col2 * + 38 + + col1 / + 12 AS col2 FROM tab1 AS cor0
----
2054
2166
3649

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col1 AS REAL ) * - col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9836
SELECT DISTINCT - + CAST( + col0 AS SIGNED ) FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-9836
SELECT DISTINCT - + CAST ( + col0 AS INTEGER ) FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL 81 + + 13 FROM tab2 AS cor0
----
94
94
94

query I rowsort
SELECT - ( cor0.col1 ) * - col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - ( + col0 ) + col2 + col1 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT ALL 0 * col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9841
SELECT DISTINCT col0 + + cor0.col2 * + CAST( 75 AS SIGNED ) * + col1 AS col0 FROM tab2 AS cor0
----
115128
48529
62782

skipif mysql # not compatible
query I rowsort label-9841
SELECT DISTINCT col0 + + cor0.col2 * + CAST ( 75 AS INTEGER ) * + col1 AS col0 FROM tab2 AS cor0
----
115128
48529
62782

onlyif mysql # use DIV operator for integer division
query I rowsort label-9842
SELECT DISTINCT col2 + + cor0.col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-9842
SELECT DISTINCT col2 + + cor0.col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT col0 + cor0.col0 * + col2 * col1 AS col2 FROM tab1 AS cor0
----
36544
4215
99920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 0 col0 FROM tab2 cor0
----
0

query I rowsort
SELECT + - col1 * + cor0.col1 * 63 FROM tab1 AS cor0
----
-10647
-42588
-6300

query I rowsort
SELECT + cor0.col0 * - col2 * - ( col0 ) AS col1 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT + - 18 + - col0 * 59 AS col1 FROM tab2 cor0
----
-431
-4620
-4679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9848
SELECT ALL cor0.col2 + col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9848
SELECT ALL cor0.col2 + col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * + 88 FROM tab1
----
-1144
-2288
-880

onlyif mysql # use DIV operator for integer division
query I rowsort label-9850
SELECT cor0.col1 DIV - 7 AS col2 FROM tab1 AS cor0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-9850
SELECT cor0.col1 / - 7 AS col2 FROM tab1 AS cor0
----
-1
-1
-3

query I rowsort
SELECT DISTINCT + col0 * 97 - col0 FROM tab0 AS cor0
----
2304
3360
8544

query I rowsort
SELECT ALL col2 + - 5 FROM tab0 AS cor0
----
-4
28
77

query I rowsort
SELECT DISTINCT col1 * - col1 - - cor0.col0 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-598
540
871

onlyif mysql # use DIV operator for integer division
query I rowsort label-9854
SELECT ( + col2 ) DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9854
SELECT ( + col2 ) / col0 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + 10 * cor0.col1 col0 FROM tab0 AS cor0
----
1001
1067
946

query I rowsort
SELECT ALL tab2.col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col0 * + ( + col1 ) + - col1 FROM tab1
----
1027
52
630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 73 + col2 * col2 col0 FROM tab1 AS cor0
----
2989
3322
9289

onlyif mysql # use DIV operator for integer division
query I rowsort label-9859
SELECT DISTINCT + col2 * - col0 + + col1 DIV 28 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-9859
SELECT DISTINCT + col2 * - col0 + + col1 / 28 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - col0 * col1 + col0 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL + ( - col1 ) - + col1 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT + 8 + + 22 FROM tab1 cor0
----
30

query I rowsort
SELECT - - col2 * col2 - 76 FROM tab2 AS cor0
----
1368
600
653

onlyif mysql # use DIV operator for integer division
query I rowsort label-9864
SELECT ALL col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9864
SELECT ALL col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * + col1 * + 27 AS col1 FROM tab1 AS cor0
----
-17280
-2106
-28080

query I rowsort
SELECT DISTINCT - + col2 + col0 * + 37 AS col2 FROM tab0 AS cor0
----
1294
3211
855

query I rowsort
SELECT + col2 + - col2 * col2 AS col1 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL cor0.col1 * ( - col1 ) AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col2 * CAST ( 11 AS REAL ) + - col1 * - col1 FROM tab0 AS cor0
----
7033
7379
9398

query I rowsort
SELECT DISTINCT - col1 + 32 AS col2 FROM tab2 AS cor0
----
-27
1
15

query I rowsort
SELECT ALL + cor0.col1 + + ( 38 ) FROM tab0 AS cor0 CROSS JOIN tab0, tab1 cor1
----
27 values hashing to 13d5dace67e175972f34b85f14d3d713

query I rowsort
SELECT DISTINCT - col0 * ( + col0 * col2 ) FROM tab1
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-9873
SELECT + col1 * col0 + col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
2066
3492
8100

skipif mysql # not compatible
query I rowsort label-9873
SELECT + col1 * col0 + col1 / + col2 AS col0 FROM tab0 AS cor0
----
2066
3492
8100

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9874
SELECT - col1 * col1 + col2 * cor0.col0 * - CAST( - col1 AS SIGNED ) col0 FROM tab0 AS cor0
----
-6014
60716
655837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9874
SELECT - col1 * col1 + col2 * cor0.col0 * - CAST ( - col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
-6014
60716
655837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * cor0.col0 * - ( + col2 + ( col2 ) ) col0 FROM tab2 AS cor0
----
-2646
-316368
-474316

query I rowsort
SELECT ALL - + col1 * ( + col2 ) FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9878
SELECT + CAST( NULL AS SIGNED ) * + col2 * cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9878
SELECT + CAST ( NULL AS INTEGER ) * + col2 * cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 72 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

query I rowsort
SELECT + col0 * ( col1 ) AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
-1
-33
-82

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab0 cor2
----
3645 values hashing to be7848c91584d04f21fd5bbb0d239aca

query I rowsort
SELECT col1 * 5 + - col2 AS col1 FROM tab2 AS cor0
----
128
269
47

query I rowsort
SELECT ALL - - ( cor0.col1 ) * + ( - col0 ) FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9885
SELECT DISTINCT + CAST( 43 AS SIGNED ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
43

skipif mysql # not compatible
query I rowsort label-9885
SELECT DISTINCT + CAST ( 43 AS INTEGER ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-9886
SELECT + col0 - - col1 DIV + col1 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-9886
SELECT + col0 - - col1 / + col1 FROM tab2 AS cor0
----
79
8
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9887
SELECT + 32 * col2 + - CAST( NULL AS SIGNED ) 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-9887
SELECT + 32 * col2 + - CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 - + cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 61 + col0 - 9 FROM tab0 AS cor0
----
141
76
87

query I rowsort
SELECT ALL + col2 * + col1 + + ( + tab0.col1 ) + col2 FROM tab0
----
195
2957
7635

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9891
SELECT ALL cor0.col2 * CAST( NULL AS SIGNED ) FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9891
SELECT ALL cor0.col2 * CAST ( NULL AS INTEGER ) FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9892
SELECT DISTINCT tab0.col0 + - col1 DIV + col2 FROM tab0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-9892
SELECT DISTINCT tab0.col0 + - col1 / + col2 FROM tab0
----
-62
22
88

query I rowsort
SELECT DISTINCT - col1 * col1 + col2 FROM tab0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-9894
SELECT col1 * col0 DIV + col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-9894
SELECT col1 * col0 / + col0 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 + col2 col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + ( - col1 ) + + 81 FROM tab0
----
-10
-16
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 * - col2 col0 FROM tab1
----
-1248
-1404
-570

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2, tab2 cor1
----
3645 values hashing to 42d854e4c33cb5afd5528228bff9250d

query I rowsort
SELECT ( + 48 ) - col0 AS col0 FROM tab0
----
-41
13
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9900
SELECT - - col1 + col1 * col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9900
SELECT - - col1 + col1 * col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 24 * - col2 AS col0 FROM tab2 AS cor0
----
624
648
912

query I rowsort
SELECT DISTINCT - - cor0.col2 * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - - 76 * col0 AS col1 FROM tab1 AS cor0
----
228
4864
6080

query I rowsort
SELECT + col0 * 96 FROM tab0 cor0
----
2304
3360
8544

query I rowsort
SELECT + - 65 AS col1 FROM tab2 AS cor0
----
-65
-65
-65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9906
SELECT - CAST( col0 AS SIGNED ) + col1 AS col2 FROM tab0 cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-9906
SELECT - CAST ( col0 AS INTEGER ) + col1 AS col2 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT - + 86 * - col2 * - 75 - - col0 AS col1 FROM tab0 AS cor0
----
-212826
-528811
-6415

onlyif mysql # use DIV operator for integer division
query I rowsort label-9908
SELECT DISTINCT + - col0 + col0 DIV ( col0 ) AS col0 FROM tab2 cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-9908
SELECT DISTINCT + - col0 + col0 / ( col0 ) AS col0 FROM tab2 cor0
----
-6
-77
-78

query I rowsort
SELECT ALL + - cor0.col0 * - col0 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-9910
SELECT - col1 + + cor0.col1 DIV - col0 col0 FROM tab1 AS cor0
----
-10
-13
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9910
SELECT - col1 + + cor0.col1 / - col0 col0 FROM tab1 AS cor0
----
-10
-13
-34

query I rowsort
SELECT DISTINCT - 95 FROM tab0, tab2 AS cor0
----
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-9912
SELECT ALL col1 DIV - col2 + + ( + col0 ) * col0 - col1 col1 FROM tab1 AS cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9912
SELECT ALL col1 / - col2 + + ( + col0 ) * col0 - col1 col1 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT + - col1 + + ( col2 ) * col0 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9914
SELECT ALL + cor0.col2 * CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-9914
SELECT ALL + cor0.col2 * CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-9915
SELECT - 7 DIV 20 col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9915
SELECT - 7 / 20 col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1, tab0, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - col1 * + 40 + col2 FROM tab1 AS cor0
----
-343
-424
-986

query I rowsort
SELECT + col0 + - 53 * + col1 AS col1 FROM tab0 cor0
----
-4534
-4734
-5106

query I rowsort
SELECT DISTINCT - col2 * 38 AS col2 FROM tab2 AS cor0
----
-1026
-1444
-988

query I rowsort
SELECT DISTINCT - - ( 66 ) AS col2 FROM tab2 AS cor0
----
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-9922
SELECT ALL + col0 DIV - col1 + col1 * col1 + + col2 * col2 AS col2 FROM tab1 AS cor0
----
3343
3592
9379

skipif mysql # not compatible
query I rowsort label-9922
SELECT ALL + col0 / - col1 + col1 * col1 + + col2 * col2 AS col2 FROM tab1 AS cor0
----
3343
3592
9379

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * col2 col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL col1 * - 92 + tab0.col2 AS col0 FROM tab0
----
-7879
-8290
-8923

query I rowsort
SELECT col1 - 19 * col1 FROM tab2
----
-1062
-306
-558

query I rowsort
SELECT col1 + col0 * col0 * 5 AS col2 FROM tab2 AS cor0
----
276
30479
31222

query I rowsort
SELECT ALL 97 * + col0 AS col2 FROM tab1 AS cor0
----
291
6208
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9928
SELECT + col0 + + col1 DIV - col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-9928
SELECT + col0 + + col1 / - col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT ALL - 64 * - cor0.col2 FROM tab2 cor0
----
1664
1728
2432

query I rowsort
SELECT DISTINCT + + 89 + col0 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
143
156
66

query I rowsort
SELECT DISTINCT - + col2 + - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9932
SELECT DISTINCT col2 + ( - cor0.col2 ) DIV - 78 AS col1 FROM tab1 AS cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-9932
SELECT DISTINCT col2 + ( - cor0.col2 ) / - 78 AS col1 FROM tab1 AS cor0
----
54
57
97

query I rowsort
SELECT ALL col0 * col1 + col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL 21 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9935
SELECT + ( + col2 ) - col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9935
SELECT + ( + col2 ) - col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 7 * 93 + + col0 * + 52 + 31 FROM tab2 AS cor0
----
1046
4738
4790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9937
SELECT cor0.col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9937
SELECT cor0.col2 * - CAST ( NULL AS INTEGER ) 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 ALL + 46 col0 FROM tab0 AS cor0
----
46
46
46

query I rowsort
SELECT + + 44 + + col2 AS col2 FROM tab2 AS cor0
----
70
71
82

query I rowsort
SELECT ALL + cor0.col0 * + 96 AS col1 FROM tab2 AS cor0
----
672
7488
7584

query I rowsort
SELECT ALL ( - 64 ) FROM tab2
----
-64
-64
-64

query I rowsort
SELECT ALL - col2 * - 32 FROM tab2
----
1216
832
864

query I rowsort
SELECT ALL + 98 - tab2.col0 AS col2 FROM tab2
----
19
20
91

query I rowsort
SELECT DISTINCT + col2 * + col0 + - 14 AS col2 FROM tab2 AS cor0
----
175
2014
2988

onlyif mysql # use DIV operator for integer division
query I rowsort label-9945
SELECT ALL + + col1 DIV cor0.col2 - - col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1128
-574
-7920

skipif mysql # not compatible
query I rowsort label-9945
SELECT ALL + + col1 / cor0.col2 - - col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1128
-574
-7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-9946
SELECT - + col2 DIV col0 + - 38 AS col0 FROM tab1 AS cor0
----
-38
-39
-56

skipif mysql # not compatible
query I rowsort label-9946
SELECT - + col2 / col0 + - 38 AS col0 FROM tab1 AS cor0
----
-38
-39
-56

query I rowsort
SELECT - col0 * col0 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
-1190
-18984
-649433

query I rowsort
SELECT - ( + col2 ) * ( col2 ) AS col2 FROM tab0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col1 + + col2 col0 FROM tab1
----
1136
132
697

query I rowsort
SELECT + 78 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT DISTINCT - col1 + 28 AS col0 FROM tab1 AS cor0
----
15
18
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-9952
SELECT ALL - col1 * 48 * 25 + + col1 DIV col2 FROM tab1 AS cor0
----
-12000
-15600
-31200

skipif mysql # not compatible
query I rowsort label-9952
SELECT ALL - col1 * 48 * 25 + + col1 / col2 FROM tab1 AS cor0
----
-12000
-15600
-31200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 64 col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9bd8c7417aea89812d57dc6142310b3f

query I rowsort
SELECT ALL - ( + 16 ) AS col1 FROM tab2, tab2 AS cor0, tab1, tab1 cor1
----
81 values hashing to 6a726f8493b62c5d4e1dd657007160c3

query I rowsort
SELECT DISTINCT + col1 - col2 AS col0 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT + col1 * col2 - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - col1 + - col0 * 34 AS col2 FROM tab1 AS cor0
----
-128
-2186
-2733

query I rowsort
SELECT ALL - + col0 + + col2 * col1 + + col0 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + col2 + 18 FROM tab2 AS cor0
----
44
45
56

query I rowsort
SELECT DISTINCT col0 * - 7 AS col2 FROM tab0 AS cor0
----
-168
-245
-623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9961
SELECT DISTINCT - + col1 - - CAST( col2 * col0 + 93 AS SIGNED ) FROM tab1 cor0
----
229
3731
7760

skipif mysql # not compatible
query I rowsort label-9961
SELECT DISTINCT - + col1 - - CAST ( col2 * col0 + 93 AS INTEGER ) FROM tab1 cor0
----
229
3731
7760

query I rowsort
SELECT ALL - + col0 + + 49 FROM tab2 cor0
----
-29
-30
42

query I rowsort
SELECT col0 + 92 * col2 FROM tab1 AS cor0
----
4971
5308
8912

query I rowsort
SELECT ALL col0 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9965
SELECT - col2 + - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9965
SELECT - col2 + - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9966
SELECT DISTINCT cor0.col0 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9966
SELECT DISTINCT cor0.col0 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9967
SELECT ALL col1 * 88 + 52 DIV col0 FROM tab0 AS cor0
----
7570
8008
8537

skipif mysql # not compatible
query I rowsort label-9967
SELECT ALL col1 * 88 + 52 / col0 FROM tab0 AS cor0
----
7570
8008
8537

query I rowsort
SELECT ALL + col1 * col2 + + col2 AS col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT 43 * cor0.col2 * + 13 FROM tab2 AS cor0
----
14534
15093
21242

query I rowsort
SELECT DISTINCT - 95 * + col2 FROM tab1 AS cor0
----
-5130
-5415
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 99 col1 FROM tab1, tab2 AS cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to 501094e80bab5e6e81bd79b84ea81e69

query I rowsort
SELECT ALL ( col0 ) * ( col1 ) FROM tab0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9973
SELECT ALL cor0.col2 * + CAST( NULL AS SIGNED ) - + 73 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9973
SELECT ALL cor0.col2 * + CAST ( NULL AS INTEGER ) - + 73 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 24 FROM tab0, tab1, tab1 cor0
----
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9975
SELECT ALL 32 DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9975
SELECT ALL 32 / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 71 * + col2 + col2 AS col2 FROM tab2 AS cor0
----
1872
1944
2736

query I rowsort
SELECT ALL + col1 * - col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT - 37 * col0 * col0 FROM tab0 AS cor0
----
-21312
-293077
-45325

query I rowsort
SELECT DISTINCT 0 FROM tab0, tab0 AS cor0, tab2 cor1
----
0

query I rowsort
SELECT + col2 * 93 * + 30 FROM tab0 AS cor0
----
228780
2790
92070

query I rowsort
SELECT 2 * + col0 * tab0.col2 + - 15 AS col0 FROM tab0
----
14581
1569
55

query I rowsort
SELECT DISTINCT - + 84 AS col2 FROM tab0, tab1, tab1 AS cor0
----
-84

query I rowsort
SELECT - 98 + 93 * col2 * + col2 AS col0 FROM tab0 AS cor0
----
-5
101179
625234

query I rowsort
SELECT + col1 - 56 AS col2 FROM tab1 AS cor0
----
-30
-43
-46

query I rowsort
SELECT DISTINCT + - 26 * - col1 + - col1 * - col2 * + col1 AS col2 FROM tab2 AS cor0
----
11424
26753
92040

query I rowsort
SELECT - 44 + - col1 AS col0 FROM tab1 AS cor0
----
-54
-57
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9987
SELECT - + CAST( + 78 AS SIGNED ) + + col2 AS col2 FROM tab1 AS cor0
----
-21
-24
18

skipif mysql # not compatible
query I rowsort label-9987
SELECT - + CAST ( + 78 AS INTEGER ) + + col2 AS col2 FROM tab1 AS cor0
----
-21
-24
18

query I rowsort
SELECT ALL - - cor0.col0 + - col0 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + col2 + + col0 FROM tab0 cor0
----
253
37
90

query I rowsort
SELECT ALL + col1 - + 43 FROM tab2
----
-12
-26
16

query I rowsort
SELECT DISTINCT + col2 + + tab2.col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT - col2 * col0 + cor0.col0 - - 17 FROM tab0 AS cor0
----
-7192
-751
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9993
SELECT + + col1 + - col2 + col2 * CAST( col2 + cor0.col1 AS SIGNED ) * cor0.col0 FROM tab2 AS cor0
----
10966
165089
172413

skipif mysql # not compatible
query I rowsort label-9993
SELECT + + col1 + - col2 + col2 * CAST ( col2 + cor0.col1 AS INTEGER ) * cor0.col0 FROM tab2 AS cor0
----
10966
165089
172413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9994
SELECT - CAST( NULL AS SIGNED ) * - 29 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9994
SELECT - CAST ( NULL AS INTEGER ) * - 29 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9995
SELECT cor0.col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9995
SELECT cor0.col1 / + col1 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9996
SELECT - 59 DIV - col1 FROM tab1 AS cor0
----
2
4
5

skipif mysql # not compatible
query I rowsort label-9996
SELECT - 59 / - col1 FROM tab1 AS cor0
----
2
4
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9997
SELECT CAST( NULL AS SIGNED ) * 57 * tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9997
SELECT CAST ( NULL AS INTEGER ) * 57 * tab2.col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 96 + cor0.col1 FROM tab1 cor0
----
106
109
122

query I rowsort
SELECT - 67 * 14 AS col2 FROM tab1 AS cor0
----
-938
-938
-938

