hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL col1 * col1 + + 58 AS col2 FROM tab1 cor0
----
158
227
734

query I rowsort
SELECT + + 63 * - col2 AS col2 FROM tab0 AS cor0
----
-2079
-5166
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2
SELECT ALL - cor0.col2 DIV cor0.col0 + col0 * - 21 FROM tab1 AS cor0
----
-1344
-1681
-81

skipif mysql # not compatible
query I rowsort label-2
SELECT ALL - cor0.col2 / cor0.col0 + col0 * - 21 FROM tab1 AS cor0
----
-1344
-1681
-81

query I rowsort
SELECT + 96 FROM tab2 cor0
----
96
96
96

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

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

query I rowsort
SELECT DISTINCT + 55 + col2 * + col0 + - col0 * + 53 * col2 FROM tab1 cor0
----
-189641
-399305
-8369

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-10
SELECT ALL col0 DIV - 6 AS col0 FROM tab1 AS cor0
----
-10
-13
0

skipif mysql # not compatible
query I rowsort label-10
SELECT ALL col0 / - 6 AS col0 FROM tab1 AS cor0
----
-10
-13
0

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-13
SELECT + col0 + ( + col0 ) DIV + col2 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-13
SELECT + col0 + ( + col0 ) / + col2 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT DISTINCT + 46 AS col1 FROM tab2
----
46

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

query I rowsort
SELECT - 50 + - col0 * + col2 FROM tab0
----
-7348
-842
-85

query I rowsort
SELECT ALL col0 + 5 + tab1.col0 * col1 AS col0 FROM tab1
----
1125
709
86

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

query I rowsort
SELECT - col2 - + 64 AS col1 FROM tab1 AS cor0
----
-118
-121
-160

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 * + 95 FROM tab0 AS cor0
----
-2
3049
7699

query I rowsort
SELECT - col2 + 18 FROM tab2 AS cor0
----
-20
-8
-9

query I rowsort
SELECT DISTINCT - col1 + + 39 FROM tab2
----
-20
22
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 92 col0 FROM tab1 AS cor0
----
146
149
188

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

query I rowsort
SELECT ALL + 6 AS col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
81 values hashing to 44f233d1b3804e00d9436c0a41d1e2c8

onlyif mysql # use DIV operator for integer division
query I rowsort label-26
SELECT + + col0 DIV - 35 col2 FROM tab1 cor0
----
-1
-2
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-27
SELECT + col2 * ( col1 * - col0 ) + col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
-119651
-51033
-5858

skipif mysql # not compatible
query I rowsort label-27
SELECT + col2 * ( col1 * - col0 ) + col1 / + col1 AS col1 FROM tab2 AS cor0
----
-119651
-51033
-5858

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

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

query I rowsort
SELECT DISTINCT + col2 + + col2 + 28 * col2 FROM tab1 AS cor0
----
1620
1710
2880

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

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

query I rowsort
SELECT + + 58 + + col1 FROM tab0 AS cor0
----
144
149
155

query I rowsort
SELECT ALL + col1 * + col0 + ( + col2 + + col1 ) * + col2 * 9 FROM tab2 AS cor0
----
14311
20153
24492

query I rowsort
SELECT - 5 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

query I rowsort
SELECT + 17 + - col0 FROM tab1 cor0
----
-47
-63
14

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-37
SELECT ALL - col1 DIV col0 + 62 * - col1 * col2 FROM tab1 AS cor0
----
-35340
-77376
-87056

skipif mysql # not compatible
query I rowsort label-37
SELECT ALL - col1 / col0 + 62 * - col1 * col2 FROM tab1 AS cor0
----
-35340
-77376
-87056

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

query I rowsort
SELECT - 1 * - col0 + - 39 * col1 AS col0 FROM tab1 AS cor0
----
-1011
-326
-427

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

query I rowsort
SELECT DISTINCT + col0 + col2 - + col0 * col1 * col1 FROM tab0 AS cor0
----
-177447
-329279
-736838

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

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

query I rowsort
SELECT ALL - col2 * - 9 + col1 FROM tab2 AS cor0
----
274
293
359

query I rowsort
SELECT - + col2 * - 82 AS col2 FROM tab0 AS cor0
----
2706
6724
82

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col1 * + 63 col2 FROM tab1 AS cor0
----
-1692
-687
-915

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-50
SELECT + + col2 DIV - col0 + + col1 FROM tab2 AS cor0
----
17
28
59

skipif mysql # not compatible
query I rowsort label-50
SELECT + + col2 / - col0 + + col1 FROM tab2 AS cor0
----
17
28
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 23 * col1 col2 FROM tab1 cor0
----
230
299
598

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

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

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

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

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

query I rowsort
SELECT DISTINCT ( + ( col1 ) ) * - col0 * - ( col2 ) + - 21 FROM tab1 cor0
----
36459
4191
99819

query I rowsort
SELECT ALL col2 - 57 * + cor0.col1 FROM tab1 cor0
----
-1428
-513
-645

query I rowsort
SELECT ALL col0 * col1 * - col1 + 39 AS col2 FROM tab0 AS cor0
----
-177465
-329276
-736970

query I rowsort
SELECT ALL col1 * 77 FROM tab2 AS cor0
----
1309
2387
4543

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

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

query I rowsort
SELECT + + 6 + + 20 FROM tab0 cor0
----
26
26
26

query I rowsort
SELECT ALL 41 + col0 AS col0 FROM tab0
----
130
65
76

query I rowsort
SELECT col0 * 40 + - col1 AS col0 FROM tab1
----
2550
3187
94

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

query I rowsort
SELECT - 98 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-115
-129
-157

query I rowsort
SELECT DISTINCT - - ( + col0 ) * + col1 + 35 * + col1 * 68 FROM tab1 cor0
----
24440
31980
61958

query I rowsort
SELECT DISTINCT 43 + - cor0.col0 FROM tab0 AS cor0
----
-46
19
8

query I rowsort
SELECT ALL + col1 * col2 + - 65 - col2 AS col1 FROM tab0 AS cor0
----
2740
31
7315

query I rowsort
SELECT - - 4 * - col0 AS col0 FROM tab0 AS cor0
----
-140
-356
-96

query I rowsort
SELECT ALL + 42 * + ( - col1 ) + - ( col2 ) FROM tab0
----
-3645
-3904
-4075

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

query I rowsort
SELECT ALL - col0 * col0 + tab1.col2 + 50 FROM tab1
----
-3989
-6254
95

query I rowsort
SELECT ALL 82 + col0 FROM tab2
----
160
161
89

query I rowsort
SELECT - col1 * + col2 * - col2 FROM tab1 cor0
----
119808
32490
75816

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

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

query I rowsort
SELECT DISTINCT + col1 AS col0 FROM tab0 AS cor0 WHERE ( NULL ) BETWEEN NULL AND - col0 + col1 * col0 OR NOT ( NULL ) NOT IN ( cor0.col2 * col2 * col1 )
----

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

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

query I rowsort
SELECT tab0.col0 + col1 * tab0.col1 + col0 AS col1 FROM tab0
----
7444
8459
9479

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

query I rowsort
SELECT + 54 + col0 FROM tab1 cor0
----
118
134
57

query I rowsort
SELECT + col2 + 29 * + col2 FROM tab2
----
1140
780
810

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 37 * col1 col2 FROM tab0
----
3182
3367
3589

query I rowsort
SELECT + 21 + col1 FROM tab1
----
31
34
47

query I rowsort
SELECT ALL 44 * - col0 AS col1 FROM tab0
----
-1056
-1540
-3916

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

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

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

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

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

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

query I rowsort
SELECT + col1 AS col1 FROM tab2 WHERE NULL >= NULL
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 col0 FROM tab0 WHERE - col1 / - col2 IN ( col1 / - tab0.col0 )
----

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

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

query I rowsort
SELECT + col2 + col1 * - tab2.col1 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT tab0.col0 * - tab0.col1 + col0 * - col1 + - col2 FROM tab0
----
-16280
-4161
-6791

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

query I rowsort
SELECT + tab1.col0 AS col1 FROM tab1 WHERE NOT NULL > NULL
----

query I rowsort
SELECT DISTINCT col1 * col0 * - col1 + + col2 * - col0 FROM tab0
----
-178296
-329350
-744307

query I rowsort
SELECT col0 * tab0.col0 AS col0 FROM tab0 WHERE - col0 * - col2 + col0 * + col2 - col1 > ( col1 )
----
576
7921

query I rowsort
SELECT col2 * col1 * - col0 + col1 + + col0 * col0 * - col0 FROM tab0
----
-1368996
-46173
-81850

query I rowsort
SELECT + col2 + col0 / col0 FROM tab0 WHERE NULL >= NULL
----

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

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

skipif mysql # not compatible
query I rowsort label-108
SELECT DISTINCT col2 / - col1 AS col1 FROM tab2
----
-2
0

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

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

query I rowsort
SELECT col0 * - col1 + - col2 * tab0.col2 + - col2 FROM tab0
----
-14905
-3186
-3397

query I rowsort
SELECT col0 * + col1 + col1 FROM tab1 WHERE NOT NULL > NULL
----

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

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( - col1 * - col2 ) > NULL
----

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

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

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

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

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

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

query I rowsort
SELECT + cor0.col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

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

skipif mysql # not compatible
query I rowsort label-121
SELECT col2 * col0 + - col0 / + col2 FROM tab1 AS cor0
----
162
3647
7680

query I rowsort
SELECT ALL 2 * ( - col0 ) FROM tab1 AS cor0
----
-128
-160
-6

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

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

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

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

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

query I rowsort
SELECT ALL - col1 + + 53 * col0 AS col2 FROM tab0 AS cor0
----
1186
1758
4626

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-128
SELECT DISTINCT + 47 DIV + 51 col1 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-128
SELECT DISTINCT + 47 / + 51 col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - 56 + col0 * - col2 AS col0 FROM tab1 AS cor0
----
-218
-3704
-7736

query I rowsort
SELECT DISTINCT tab1.col2 * 84 AS col0 FROM tab1
----
4536
4788
8064

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

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

query I rowsort
SELECT ALL - + ( + col0 ) * - col1 * ( 49 * + col0 ) + + col2 * - col2 AS col2 FROM tab0 AS cor0
----
2426175
35313015
5822424

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 53 * col2 col2 FROM tab1 cor0
----
-2862
-3021
-5088

query I rowsort
SELECT - col1 * col2 * - col2 FROM tab2 AS cor0
----
22599
24548
39884

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

query I rowsort
SELECT DISTINCT + col1 * col2 + 75 * + cor0.col1 FROM tab2 AS cor0
----
1921
3162
5959

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

query I rowsort
SELECT ALL 72 + col0 * - 23 AS col2 FROM tab0 AS cor0
----
-1975
-480
-733

onlyif mysql # use DIV operator for integer division
query I rowsort label-139
SELECT DISTINCT + - cor0.col0 DIV col1 + col2 + - col2 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-139
SELECT DISTINCT + - cor0.col0 / col1 + col2 + - col2 * + ( col1 ) AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL - - col2 * - 33 FROM tab2 cor0
----
-1254
-858
-891

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

skipif mysql # not compatible
query I rowsort label-141
SELECT - col2 * col0 * - col1 + col1 + - CAST ( col1 + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
36470
4186
99827

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

query I rowsort
SELECT DISTINCT cor0.col2 * 6 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
231
574
7

query I rowsort
SELECT col2 + col2 + + col1 FROM tab1 AS cor0
----
124
134
205

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-146
SELECT + col2 DIV col1 + - col0 * - col2 col1 FROM tab2 AS cor0
----
189
2028
3004

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-146
SELECT + col2 / col1 + - col0 * - col2 col1 FROM tab2 AS cor0
----
189
2028
3004

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

query I rowsort
SELECT DISTINCT + col2 + - ( col1 * col1 + - col0 ) AS col1 FROM tab2
----
-172
-3377
-927

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-150
SELECT - tab2.col1 * + tab2.col0 DIV + col0 - - col2 * + ( + tab2.col2 * - col0 + + col2 ) AS col0 FROM tab2
----
-112649
-4405
-52111

skipif mysql # not compatible
query I rowsort label-150
SELECT - tab2.col1 * + tab2.col0 / + col0 - - col2 * + ( + tab2.col2 * - col0 + + col2 ) AS col0 FROM tab2
----
-112649
-4405
-52111

query I rowsort
SELECT DISTINCT + col2 + 80 FROM tab0
----
113
162
81

query I rowsort
SELECT col0 * + ( col2 ) * - col1 + + col1 FROM tab1
----
-36470
-4186
-99827

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

query I rowsort
SELECT - col2 + col0 * col0 * - col0 AS col1 FROM tab2
----
-370
-474578
-493077

query I rowsort
SELECT ALL col0 + - 10 * 30 AS col2 FROM tab0 AS cor0
----
-211
-265
-276

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

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

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

query I rowsort
SELECT ALL - 15 * cor0.col1 FROM tab1 AS cor0
----
-150
-195
-390

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-162
SELECT ALL - CAST( + col1 AS SIGNED ) * col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-162
SELECT ALL - CAST ( + col1 AS INTEGER ) * col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT ( + 74 ) * col1 * col0 FROM tab0
----
152736
251230
599326

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-165
SELECT - CAST( col2 AS SIGNED ) * col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-165
SELECT - CAST ( col2 AS INTEGER ) * col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

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

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

query I rowsort
SELECT + col2 + + tab1.col2 - col0 * - col1 AS col2 FROM tab1
----
1232
186
754

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

query I rowsort
SELECT + cor0.col0 + col0 * + ( 17 ) AS col2 FROM tab1 AS cor0
----
1152
1440
54

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

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

query I rowsort
SELECT DISTINCT + cor0.col2 * - 0 FROM tab1 cor0
----
0

query I rowsort
SELECT - - col1 + 73 * - col0 FROM tab0 AS cor0
----
-1666
-2458
-6406

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

query I rowsort
SELECT ALL - col1 * ( + col0 ) * cor0.col0 + - col0 AS col2 FROM tab0 AS cor0
----
-118860
-49560
-720900

query I rowsort
SELECT DISTINCT - cor0.col2 - col2 AS col0 FROM tab0 AS cor0
----
-164
-2
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-177
SELECT col1 + - CAST( - 89 * col1 + - col1 AS SIGNED ) FROM tab1 AS cor0
----
1183
2366
910

skipif mysql # not compatible
query I rowsort label-177
SELECT col1 + - CAST ( - 89 * col1 + - col1 AS INTEGER ) FROM tab1 AS cor0
----
1183
2366
910

query I rowsort
SELECT ALL col1 + - 51 FROM tab0 AS cor0
----
35
40
46

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 * + CAST ( cor0.col1 AS REAL ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col0 + + 1 AS col2 FROM tab0 AS cor0
----
-23
-34
-88

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

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

query I rowsort
SELECT + ( col1 ) + 41 FROM tab1
----
51
54
67

query I rowsort
SELECT DISTINCT + 37 * col2 - + 49 FROM tab1
----
1949
2060
3503

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + cor0.col2 + - CAST ( 14 AS REAL ) * col2 FROM tab0 AS cor0
----
-1066
-13
-429

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

query I rowsort
SELECT DISTINCT + ( col0 ) - 3 * 25 * col1 FROM tab2
----
-1196
-2318
-4347

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

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

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

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

skipif mysql # not compatible
query I rowsort label-195
SELECT 11 / + col2 FROM tab1 AS cor0
----
0
0
0

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

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

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

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

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

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

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

query I rowsort
SELECT ALL tab2.col0 * 33 FROM tab2
----
231
2574
2607

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

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

query I rowsort
SELECT ALL cor0.col1 + + 28 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to b2ef0a0b6badf32b7d9b5f14ebc8e69a

query I rowsort
SELECT ALL + - 62 * col2 + cor0.col0 * col2 AS col0 FROM tab1 cor0
----
-3186
114
1728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 58 ) - + col2 col1 FROM tab0 AS cor0
----
-140
-59
-91

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-206
SELECT ALL - ( - col2 ) DIV - cor0.col2 + 69 col0 FROM tab1 cor0
----
68
68
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-206
SELECT ALL - ( - col2 ) / - cor0.col2 + 69 col0 FROM tab1 cor0
----
68
68
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-207
SELECT + CAST( ( - col1 ) AS SIGNED ) * 99 + 62 AS col2 FROM tab0 AS cor0
----
-8452
-8947
-9541

skipif mysql # not compatible
query I rowsort label-207
SELECT + CAST ( ( - col1 ) AS INTEGER ) * 99 + 62 AS col2 FROM tab0 AS cor0
----
-8452
-8947
-9541

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

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

query I rowsort
SELECT - 56 * col1 + - col1 * col0 + - col1 FROM tab2 AS cor0
----
-1984
-2312
-7965

query I rowsort
SELECT ALL col2 * + 63 FROM tab1
----
3402
3591
6048

query I rowsort
SELECT ( + 78 + - tab0.col1 ) AS col2 FROM tab0
----
-13
-19
-8

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-214
SELECT DISTINCT - CAST( + col1 + tab2.col2 AS SIGNED ) FROM tab2
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-214
SELECT DISTINCT - CAST ( + col1 + tab2.col2 AS INTEGER ) FROM tab2
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-215
SELECT - col1 * col1 DIV col0 + - tab1.col2 AS col2 FROM tab1
----
-279
-58
-98

skipif mysql # not compatible
query I rowsort label-215
SELECT - col1 * col1 / col0 + - tab1.col2 AS col2 FROM tab1
----
-279
-58
-98

query I rowsort
SELECT - - 32 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

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

query I rowsort
SELECT DISTINCT col2 * col1 + - ( - 93 ) FROM tab0 AS cor0
----
190
2931
7555

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

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

query I rowsort
SELECT DISTINCT - col2 + 5 FROM tab1 cor0
----
-49
-52
-91

query I rowsort
SELECT DISTINCT + col0 * - col1 * col1 + col1 AS col1 FROM tab1 cor0
----
-13507
-2002
-6390

query I rowsort
SELECT ALL col1 * + 81 AS col1 FROM tab1 AS cor0
----
1053
2106
810

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

query I rowsort
SELECT DISTINCT col1 * + cor0.col2 + col1 * col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT - cor1.col1 * cor1.col2 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6bd277b8320ae6f8c3fe593411d2dcf6

onlyif mysql # use DIV operator for integer division
query I rowsort label-227
SELECT cor0.col2 DIV + 3 FROM tab2, tab1 AS cor0
----
9 values hashing to 0a51790a6890d187998310b5fd717810

skipif mysql # not compatible
query I rowsort label-227
SELECT cor0.col2 / + 3 FROM tab2, tab1 AS cor0
----
9 values hashing to 0a51790a6890d187998310b5fd717810

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

query I rowsort
SELECT - + 52 * - col1 AS col1 FROM tab1 AS cor0
----
1352
520
676

query I rowsort
SELECT - 27 + + col1 + col0 AS col0 FROM tab0 cor0
----
105
153
83

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-232
SELECT - - ( col2 ) + col0 + col2 DIV + 58 FROM tab1 AS cor0
----
121
177
57

skipif mysql # not compatible
query I rowsort label-232
SELECT - - ( col2 ) + col0 + col2 / + 58 FROM tab1 AS cor0
----
121
177
57

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

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

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

query I rowsort
SELECT 48 * + 16 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 1a42c7cf674e742942dde5bf05a63671

query I rowsort
SELECT ALL + col1 * ( + col2 * - col0 + tab0.col0 ) AS col1 FROM tab0
----
-656019
-66048
0

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

query I rowsort
SELECT - 79 + + col1 * col1 FROM tab0 AS cor0
----
7317
8202
9330

query I rowsort
SELECT + 14 * - 38 + col0 FROM tab0 AS cor0
----
-443
-497
-508

query I rowsort
SELECT + ( - col0 ) + col0 * col0 AS col2 FROM tab0 AS cor0
----
1190
552
7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-241
SELECT + CAST( - col1 AS SIGNED ) + col1 * - 75 + + col1 AS col1 FROM tab2 AS cor0
----
-1275
-2325
-4425

skipif mysql # not compatible
query I rowsort label-241
SELECT + CAST ( - col1 AS INTEGER ) + col1 * - 75 + + col1 AS col1 FROM tab2 AS cor0
----
-1275
-2325
-4425

query I rowsort
SELECT tab2.col0 + 13 AS col0 FROM tab2
----
20
91
92

query I rowsort
SELECT ( 61 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

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

query I rowsort
SELECT col0 + ( - 34 ) FROM tab1
----
-31
30
46

query I rowsort
SELECT - col1 * 86 AS col2 FROM tab1 AS cor0
----
-1118
-2236
-860

onlyif mysql # use DIV operator for integer division
query I rowsort label-247
SELECT col0 * col0 DIV 58 + + col1 col0 FROM tab0 cor0
----
118
227
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-247
SELECT col0 * col0 / 58 + + col1 col0 FROM tab0 cor0
----
118
227
95

query I rowsort
SELECT DISTINCT + col1 + 67 FROM tab1 cor0
----
77
80
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-249
SELECT DISTINCT - col1 * + col2 + cor0.col0 * col1 DIV + 81 AS col2 FROM tab2 AS cor0
----
-1478
-630
-835

skipif mysql # not compatible
query I rowsort label-249
SELECT DISTINCT - col1 * + col2 + cor0.col0 * col1 / + 81 AS col2 FROM tab2 AS cor0
----
-1478
-630
-835

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-253
SELECT DISTINCT - CAST ( - 44 AS INTEGER ) * + col2 AS col1 FROM tab0 AS cor0
----
1452
3608
44

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

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

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

query I rowsort
SELECT - 34 + - col0 FROM tab1 AS cor0
----
-114
-37
-98

query I rowsort
SELECT DISTINCT - + 34 + + col0 + col2 * col0 FROM tab2 AS cor0
----
162
2072
3047

query I rowsort
SELECT DISTINCT + col2 + - cor0.col2 * - col2 FROM tab2 AS cor0
----
1482
702
756

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-262
SELECT CAST ( cor0.col1 AS INTEGER ) + + cor0.col1 * - col0 AS col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT - 53 * 32 AS col2 FROM tab2 AS cor0
----
-1696
-1696
-1696

query I rowsort
SELECT ALL 28 + col0 * + col0 * + 33 AS col1 FROM tab0 cor0
----
19036
261421
40453

query I rowsort
SELECT DISTINCT - 72 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-6192
-6552
-6984

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

skipif mysql # not compatible
query I rowsort label-266
SELECT + col2 / tab2.col0 + tab2.col0 AS col2 FROM tab2
----
10
78
79

query I rowsort
SELECT ALL col1 * 98 + col0 AS col1 FROM tab1
----
1044
1354
2551

query I rowsort
SELECT ALL 19 + col2 * + col1 AS col0 FROM tab0 AS cor0
----
116
2857
7481

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

query I rowsort
SELECT ALL + cor0.col0 * + 46 AS col1 FROM tab2 AS cor0
----
322
3588
3634

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

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

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

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

query I rowsort
SELECT - + col1 * - col0 + 37 AS col1 FROM tab2 AS cor0
----
1380
254
4639

query I rowsort
SELECT DISTINCT 99 * col1 - col0 AS col0 FROM tab0 AS cor0
----
8490
8920
9568

query I rowsort
SELECT col1 * col0 + col2 * 62 FROM tab1 AS cor0
----
3426
4174
6992

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

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

query I rowsort
SELECT DISTINCT + 3 + + col1 AS col2 FROM tab1 cor0
----
13
16
29

query I rowsort
SELECT ALL col0 + + cor0.col2 * 55 FROM tab1 AS cor0
----
2973
3199
5360

query I rowsort
SELECT ALL - - col0 - + col0 * 69 AS col2 FROM tab1 AS cor0
----
-204
-4352
-5440

query I rowsort
SELECT DISTINCT 25 * col1 AS col2 FROM tab0 cor0
----
2150
2275
2425

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

query I rowsort
SELECT col2 - col0 * + 79 AS col2 FROM tab1 AS cor0
----
-183
-4999
-6224

query I rowsort
SELECT DISTINCT + - ( col1 ) * cor0.col1 * 35 AS col2 FROM tab1 AS cor0
----
-23660
-3500
-5915

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-288
SELECT DISTINCT - col2 DIV + 11 + 23 FROM tab1 AS cor0
----
15
18
19

skipif mysql # not compatible
query I rowsort label-288
SELECT DISTINCT - col2 / + 11 + 23 FROM tab1 AS cor0
----
15
18
19

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

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

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

query I rowsort
SELECT ALL - - cor0.col0 * + ( col0 ) + - col1 FROM tab1 AS cor0
----
-17
4086
6387

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

query I rowsort
SELECT ALL + col1 + - 36 AS col2 FROM tab2 AS cor0
----
-19
-5
23

query I rowsort
SELECT DISTINCT - col2 - cor0.col2 * - 71 FROM tab0 AS cor0
----
2310
5740
70

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-299
SELECT DISTINCT col1 DIV - col1 + + ( col1 ) + 96 FROM tab2 AS cor0
----
112
126
154

skipif mysql # not compatible
query I rowsort label-299
SELECT DISTINCT col1 / - col1 + + ( col1 ) + 96 FROM tab2 AS cor0
----
112
126
154

query I rowsort
SELECT DISTINCT - col2 * 78 AS col0 FROM tab0 AS cor0
----
-2574
-6396
-78

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

query I rowsort
SELECT 93 * col1 - + col0 AS col1 FROM tab2
----
1502
2876
5409

onlyif mysql # use DIV operator for integer division
query I rowsort label-303
SELECT DISTINCT + 8 * - col0 DIV + tab1.col0 + + col0 AS col0 FROM tab1
----
-5
56
72

skipif mysql # not compatible
query I rowsort label-303
SELECT DISTINCT + 8 * - col0 / + tab1.col0 + + col0 AS col0 FROM tab1
----
-5
56
72

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

skipif mysql # not compatible
query I rowsort label-304
SELECT + 61 / col2 AS col2 FROM tab0
----
0
1
61

query I rowsort
SELECT DISTINCT + 78 * + col1 + col0 FROM tab1
----
1094
2031
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-306
SELECT - col2 + col2 DIV ( - 75 * col0 + tab1.col2 ) FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-306
SELECT - col2 + col2 / ( - 75 * col0 + tab1.col2 ) FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col0 * tab2.col2 * col1 + + col2 AS col1 FROM tab2
----
119678
51072
5886

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

query I rowsort
SELECT - col1 + ( - 30 * - cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-67
2369
904

query I rowsort
SELECT - 16 * + col0 + tab1.col0 AS col2 FROM tab1
----
-1200
-45
-960

query I rowsort
SELECT 95 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 cor2, tab0 AS cor3
----
243 values hashing to a96f63df7f05a6c9b4b5ff9a176b4494

query I rowsort
SELECT DISTINCT - - col0 * - 97 - 49 * - cor0.col0 FROM tab1 cor0
----
-144
-3072
-3840

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

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

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

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

query I rowsort
SELECT + 74 + + col0 AS col2 FROM tab1 AS cor0
----
138
154
77

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

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

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

query I rowsort
SELECT ALL col2 + col2 * tab0.col1 + ( tab0.col1 ) * - col0 FROM tab0
----
-3297
-555
807

onlyif mysql # use DIV operator for integer division
query I rowsort label-321
SELECT + ( cor0.col2 ) DIV - cor0.col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-321
SELECT + ( cor0.col2 ) / - cor0.col1 FROM tab2 cor0
----
-2
0
0

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

query I rowsort
SELECT DISTINCT + col1 + col1 + col2 * + col1 FROM tab0 cor0
----
291
3010
7644

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

query I rowsort
SELECT - - col0 * 20 * - col0 FROM tab2 AS cor0
----
-121680
-124820
-980

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

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

query I rowsort
SELECT ALL - ( - col1 ) * col1 FROM tab1
----
100
169
676

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

query I rowsort
SELECT ALL + 17 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT col0 * - col1 * ( - tab2.col0 + - tab2.col1 ) FROM tab2
----
128928
630474
8246

onlyif mysql # use DIV operator for integer division
query I rowsort label-332
SELECT ALL col1 DIV col1 + col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-332
SELECT ALL col1 / col1 + col1 FROM tab0
----
87
92
98

query I rowsort
SELECT - 92 * col2 FROM tab0
----
-3036
-7544
-92

query I rowsort
SELECT 53 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-336
SELECT ALL - col0 * - cor0.col0 + 22 DIV + col1 FROM tab1 AS cor0
----
4098
6401
9

skipif mysql # not compatible
query I rowsort label-336
SELECT ALL - col0 * - cor0.col0 + 22 / + col1 FROM tab1 AS cor0
----
4098
6401
9

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

query I rowsort
SELECT - col2 * 53 + col0 AS col2 FROM tab0 cor0
----
-1725
-18
-4257

query I rowsort
SELECT + + col0 * + 94 AS col1 FROM tab1 AS cor0
----
282
6016
7520

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

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

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

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

query I rowsort
SELECT + col1 * + ( + 97 + col2 ) AS col2 FROM tab0 AS cor0
----
11180
16289
9506

query I rowsort
SELECT DISTINCT - + cor0.col0 + 24 * - 70 FROM tab2 AS cor0
----
-1687
-1758
-1759

onlyif mysql # use DIV operator for integer division
query I rowsort label-345
SELECT ALL + - col2 DIV CAST( 14 * + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-345
SELECT ALL + - col2 / CAST ( 14 * + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-346
SELECT col0 DIV - col0 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-346
SELECT col0 / - col0 + + col0 AS col1 FROM tab1 AS cor0
----
2
63
79

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

query I rowsort
SELECT - + cor0.col2 + ( + col1 ) * col1 * 24 AS col2 FROM tab2 AS cor0
----
23037
6898
83518

query I rowsort
SELECT + col1 + ( cor0.col2 + cor0.col0 ) FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT DISTINCT col0 * col0 * col0 + + col0 FROM tab1 AS cor0
----
262208
30
512080

query I rowsort
SELECT + col1 * - ( col2 + col0 ) FROM tab2 cor0
----
-1054
-1989
-6136

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-353
SELECT ALL 38 DIV col2 + + col1 AS col1 FROM tab0 AS cor0
----
135
87
91

skipif mysql # not compatible
query I rowsort label-353
SELECT ALL 38 / col2 + + col1 AS col1 FROM tab0 AS cor0
----
135
87
91

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

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

query I rowsort
SELECT + col2 + 72 FROM tab0 AS cor0
----
105
154
73

query I rowsort
SELECT DISTINCT 26 + col0 AS col2 FROM tab1 AS cor0
----
106
29
90

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

skipif mysql # not compatible
query I rowsort label-357
SELECT CAST ( col0 AS INTEGER ) + - col2 * col2 AS col2 FROM tab2 AS cor0
----
-1365
-598
-722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 17 + col2 col2 FROM tab1 AS cor0
----
113
71
74

query I rowsort
SELECT + col0 * + 1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL 56 + 27 * col0 FROM tab1 AS cor0
----
137
1784
2216

query I rowsort
SELECT - col2 * ( col0 + col2 * - col1 ) FROM tab0
----
604586
62
92862

query I rowsort
SELECT + col2 * 29 FROM tab0
----
2378
29
957

query I rowsort
SELECT - 2 + cor0.col0 AS col2 FROM tab1 AS cor0
----
1
62
78

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

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

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

query I rowsort
SELECT cor0.col2 * cor0.col0 + 98 AS col1 FROM tab2 AS cor0
----
2126
287
3100

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

query I rowsort
SELECT DISTINCT + 52 * - col1 AS col0 FROM tab1
----
-1352
-520
-676

query I rowsort
SELECT - 64 * - col0 * 23 FROM tab2 AS cor0
----
10304
114816
116288

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

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

query I rowsort
SELECT 85 * col0 FROM tab0
----
2040
2975
7565

query I rowsort
SELECT + 5 * + col2 * + col2 + - col1 AS col0 FROM tab0 cor0
----
-92
33529
5359

onlyif mysql # use DIV operator for integer division
query I rowsort label-374
SELECT 93 DIV + col2 FROM tab0
----
1
2
93

skipif mysql # not compatible
query I rowsort label-374
SELECT 93 / + col2 FROM tab0
----
1
2
93

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

query I rowsort
SELECT ( col2 ) * col2 + col2 * col0 * + col0 FROM tab2
----
158860
2052
238602

query I rowsort
SELECT 3 + - 56 AS col2 FROM tab1
----
-53
-53
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - 89 AS REAL ) col1 FROM tab2
----
89
89
89

query I rowsort
SELECT DISTINCT 53 + col1 FROM tab1
----
63
66
79

query I rowsort
SELECT DISTINCT - col2 * 72 + - col2 AS col1 FROM tab0
----
-2409
-5986
-73

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-384
SELECT col1 * + col1 + - CAST ( - 29 AS INTEGER ) - - col0 AS col1 FROM tab2 AS cor0
----
3588
397
997

query I rowsort
SELECT ALL + 3 * - col1 * + 34 FROM tab0 AS cor0
----
-8772
-9282
-9894

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

query I rowsort
SELECT - 45 FROM tab2, tab2 AS cor0
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT DISTINCT - col0 - 21 * col2 AS col0 FROM tab1
----
-1137
-1261
-2096

query I rowsort
SELECT ALL col2 + - col1 + tab1.col2 FROM tab1
----
104
179
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-390
SELECT ALL - ( col2 ) + + col0 DIV - col1 AS col0 FROM tab2
----
-27
-27
-42

skipif mysql # not compatible
query I rowsort label-390
SELECT ALL - ( col2 ) + + col0 / - col1 AS col0 FROM tab2
----
-27
-27
-42

query I rowsort
SELECT - - ( 57 ) - col2 AS col0 FROM tab0 AS cor0
----
-25
24
56

query I rowsort
SELECT - col2 * + 26 AS col0 FROM tab1 AS cor0
----
-1404
-1482
-2496

query I rowsort
SELECT ALL - col1 + - 74 FROM tab1
----
-100
-84
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-394
SELECT + col1 + 51 * + col0 + + CAST( - col0 AS SIGNED ) * col0 DIV ( col1 ) FROM tab2
----
3679
387
3934

skipif mysql # not compatible
query I rowsort label-394
SELECT + col1 + 51 * + col0 + + CAST ( - col0 AS INTEGER ) * col0 / ( col1 ) FROM tab2
----
3679
387
3934

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

query I rowsort
SELECT ALL - - col2 + col1 * - 55 AS col0 FROM tab1 cor0
----
-1376
-493
-619

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

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

query I rowsort
SELECT ALL - 36 + - col1 * - col0 * col0 FROM tab2 cor0
----
106061
1483
358920

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

skipif mysql # not compatible
query I rowsort label-399
SELECT ALL ( + col0 ) / 80 FROM tab2 AS cor0
----
0
0
0

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

query I rowsort
SELECT ALL col2 + col2 * - 40 FROM tab2 AS cor0
----
-1014
-1053
-1482

query I rowsort
SELECT DISTINCT + 14 + col0 FROM tab0 cor0
----
103
38
49

query I rowsort
SELECT ALL + col1 * cor0.col2 + + col0 * - col0 FROM tab2 AS cor0
----
-4550
-5595
788

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 59 + + 22 col1 FROM tab2 cor0
----
1025
1851
3503

query I rowsort
SELECT ALL col2 + + col2 * 21 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT + col0 * col1 + - col2 * ( 52 ) FROM tab1 AS cor0
----
-2324
-2730
-3952

onlyif mysql # use DIV operator for integer division
query I rowsort label-408
SELECT - col0 DIV + col1 + col1 AS col2 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-408
SELECT - col0 / + col1 + col1 AS col2 FROM tab2 AS cor0
----
13
31
58

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

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

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

query I rowsort
SELECT ALL + 67 * 9 AS col1 FROM tab2 AS cor0
----
603
603
603

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

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

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

skipif mysql # not compatible
query I rowsort label-415
SELECT ALL ( + col1 ) + col0 / col0 AS col0 FROM tab2 AS cor0
----
18
32
60

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

query I rowsort
SELECT - 19 * - 3 AS col1 FROM tab0 AS cor0
----
57
57
57

query I rowsort
SELECT ALL + col2 * 42 * - col0 AS col2 FROM tab1 AS cor0
----
-153216
-322560
-6804

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

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

query I rowsort
SELECT DISTINCT col0 - - 98 AS col1 FROM tab2 AS cor0
----
105
176
177

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

skipif mysql # not compatible
query I rowsort label-422
SELECT ALL + CAST ( - cor0.col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT 4 + + 60 * + col1 FROM tab1 AS cor0
----
1564
604
784

query I rowsort
SELECT - + cor0.col1 + - 83 AS col1 FROM tab1 AS cor0
----
-109
-93
-96

query I rowsort
SELECT 75 * + col0 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT - col0 * + 45 AS col2 FROM tab1 AS cor0
----
-135
-2880
-3600

query I rowsort
SELECT DISTINCT + + 71 * col1 FROM tab2 AS cor0
----
1207
2201
4189

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

onlyif mysql # use DIV operator for integer division
query I rowsort label-431
SELECT col1 DIV 16 AS col2 FROM tab0
----
5
5
6

skipif mysql # not compatible
query I rowsort label-431
SELECT col1 / 16 AS col2 FROM tab0
----
5
5
6

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

query I rowsort
SELECT + col0 * - col0 + cor0.col1 * + col2 AS col1 FROM tab0 AS cor0
----
-1128
-459
2262

query I rowsort
SELECT ALL col2 + 75 FROM tab2 AS cor0
----
101
102
113

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

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

query I rowsort
SELECT + - col2 * 90 FROM tab0 AS cor0
----
-2970
-7380
-90

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

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

query I rowsort
SELECT 94 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT ALL + + col0 + - 44 FROM tab0 AS cor0
----
-20
-9
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 col1 FROM tab1, tab2 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

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

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

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

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

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

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

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

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

query I rowsort
SELECT + 10 * col1 * - col0 AS col0 FROM tab2 AS cor0
----
-13430
-2170
-46020

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

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

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

query I rowsort
SELECT + col1 + 36 * col2 AS col2 FROM tab2 AS cor0
----
1003
1385
995

query I rowsort
SELECT ALL + 9 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-455
SELECT col1 DIV - col0 AS col2 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-455
SELECT col1 / - col0 AS col2 FROM tab0
----
-1
-2
-3

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

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

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

query I rowsort
SELECT col2 * + tab0.col2 * col2 FROM tab0
----
1
35937
551368

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

query I rowsort
SELECT ALL - col0 + + tab1.col0 * - col0 + col2 AS col1 FROM tab1
----
-4103
-6384
42

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

query I rowsort
SELECT col0 + - cor0.col2 FROM tab2 AS cor0 WHERE NOT ( NULL ) BETWEEN NULL AND ( NULL )
----

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE ( + col2 + - col0 ) > ( col2 )
----

query I rowsort
SELECT col2 + - col0 + - col1 * + col1 FROM tab1 cor0
----
-107
-153
-625

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

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NULL = ( NULL )
----

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 * col2 + - col1 * col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-482
SELECT + 97 DIV - cor0.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort label-482
SELECT + 97 / - cor0.col2 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT DISTINCT - + 82 + - 52 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-134

query I rowsort
SELECT + - col2 * - ( 24 ) FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT DISTINCT + col0 + col1 * 5 * col0 FROM tab2 cor0
----
1092
23088
6794

onlyif mysql # use DIV operator for integer division
query I rowsort label-486
SELECT DISTINCT - col0 + + ( - col2 ) DIV col0 FROM tab0
----
-25
-35
-89

skipif mysql # not compatible
query I rowsort label-486
SELECT DISTINCT - col0 + + ( - col2 ) / col0 FROM tab0
----
-25
-35
-89

query I rowsort
SELECT DISTINCT + col1 + 40 FROM tab2
----
57
71
99

query I rowsort
SELECT col2 * 85 FROM tab2
----
2210
2295
3230

query I rowsort
SELECT + tab0.col1 + col0 * col0 * tab0.col2 + col1 AS col2 FROM tab0
----
1419
19180
649704

onlyif mysql # use DIV operator for integer division
query I rowsort label-490
SELECT col1 + 28 DIV + col1 + col0 * ( + col2 ) AS col1 FROM tab2
----
2087
220
3020

skipif mysql # not compatible
query I rowsort label-490
SELECT col1 + 28 / + col1 + col0 * ( + col2 ) AS col1 FROM tab2
----
2087
220
3020

query I rowsort
SELECT tab1.col0 - + col2 * + 0 * col1 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + 57 FROM tab2, tab0 cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

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

skipif mysql # not compatible
query I rowsort label-493
SELECT tab0.col0 + - col2 / tab0.col1 AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT - col1 * col1 + col1 AS col2 FROM tab0
----
-7310
-8190
-9312

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-496
SELECT DISTINCT - tab2.col1 DIV col0 + + col2 * + 17 FROM tab2
----
442
455
646

skipif mysql # not compatible
query I rowsort label-496
SELECT DISTINCT - tab2.col1 / col0 + + col2 * + 17 FROM tab2
----
442
455
646

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

query I rowsort
SELECT ALL col1 + - 26 + col2 FROM tab0
----
147
72
93

query I rowsort
SELECT ALL - + 70 * - cor0.col2 FROM tab0 AS cor0
----
2310
5740
70

query I rowsort
SELECT - - 19 * col2 FROM tab2 cor0
----
494
513
722

query I rowsort
SELECT DISTINCT ( cor0.col0 ) * - 12 FROM tab0 AS cor0
----
-1068
-288
-420

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

query I rowsort
SELECT DISTINCT + 98 * col0 + + 26 AS col0 FROM tab1 AS cor0
----
320
6298
7866

query I rowsort
SELECT DISTINCT ( + col1 ) + col1 * 37 AS col0 FROM tab0 cor0
----
3268
3458
3686

query I rowsort
SELECT 27 AS col0 FROM tab1 cor0
----
27
27
27

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-508
SELECT + CAST( ( col0 ) AS SIGNED ) * + col0 + tab1.col0 AS col1 FROM tab1
----
12
4160
6480

skipif mysql # not compatible
query I rowsort label-508
SELECT + CAST ( ( col0 ) AS INTEGER ) * + col0 + tab1.col0 AS col1 FROM tab1
----
12
4160
6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-509
SELECT ALL - tab1.col2 DIV 44 AS col0 FROM tab1
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-509
SELECT ALL - tab1.col2 / 44 AS col0 FROM tab1
----
-1
-1
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-510
SELECT DISTINCT - 14 DIV 69 col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-510
SELECT DISTINCT - 14 / 69 col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
0

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

query I rowsort
SELECT ALL 23 * col0 AS col0 FROM tab1
----
1472
1840
69

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

query I rowsort
SELECT DISTINCT - cor0.col1 * col0 + 20 + - col0 FROM tab1 AS cor0
----
-1100
-61
-684

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

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

query I rowsort
SELECT - col2 + col0 * - 81 FROM tab1 AS cor0
----
-297
-5241
-6576

query I rowsort
SELECT - 93 * col2 * - col0 + col2 FROM tab0
----
3256
678796
73689

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
1
33
82

query I rowsort
SELECT DISTINCT 41 AS col2 FROM tab1
----
41

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

query I rowsort
SELECT ALL 71 + - col1 * col0 FROM tab0 AS cor0
----
-1993
-3324
-8028

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

query I rowsort
SELECT col1 + 39 * + 58 * + col2 FROM tab0 AS cor0
----
185575
2359
74732

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

skipif mysql # not compatible
query I rowsort label-524
SELECT - 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-525
SELECT ALL + col1 * CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
2064
3395
8099

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

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

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

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

query I rowsort
SELECT + - 7 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

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

query I rowsort
SELECT + + col2 + 68 AS col0 FROM tab0 AS cor0
----
101
150
69

query I rowsort
SELECT - - 89 + + cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
1050
3570
378

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 11 * col0 col0 FROM tab1 AS cor0
----
45056
70400
99

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

skipif mysql # not compatible
query I rowsort label-535
SELECT ALL - + col2 + 20 / col0 - - ( col2 ) FROM tab1 AS cor0
----
0
0
6

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

query I rowsort
SELECT DISTINCT - ( - 57 ) + col1 AS col0 FROM tab2 AS cor0
----
116
74
88

query I rowsort
SELECT - 62 + ( - col2 + + ( - col2 ) * col2 ) FROM tab0 AS cor0
----
-1184
-64
-6868

query I rowsort
SELECT DISTINCT + - 51 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-1683
-4182
-51

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

query I rowsort
SELECT DISTINCT col0 + + 88 AS col0 FROM tab2 cor0
----
166
167
95

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

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

query I rowsort
SELECT 4 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

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

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

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

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

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

query I rowsort
SELECT DISTINCT 91 + col1 * tab1.col1 FROM tab1
----
191
260
767

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

query I rowsort
SELECT ( 3 ) AS col2 FROM tab2
----
3
3
3

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

query I rowsort
SELECT - col0 + + 63 * + col2 FROM tab2 AS cor0
----
1560
1694
2315

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

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

query I rowsort
SELECT 13 * + col1 + + col0 FROM tab2 AS cor0
----
300
410
845

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

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

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

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

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

query I rowsort
SELECT - cor0.col1 * 62 AS col2 FROM tab1 AS cor0
----
-1612
-620
-806

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

skipif mysql # not compatible
query I rowsort
SELECT - + col0 * CAST ( - 47 AS REAL ) FROM tab1 AS cor0
----
141
3008
3760

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-564
SELECT ( tab0.col1 ) DIV - tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cbfa8de8feb212fe31a1528b9e5261db

skipif mysql # not compatible
query I rowsort label-564
SELECT ( tab0.col1 ) / - tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cbfa8de8feb212fe31a1528b9e5261db

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

query I rowsort
SELECT ALL + 86 FROM tab0, tab2 cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

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

query I rowsort
SELECT ALL ( + tab2.col2 ) * + tab2.col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 111df31a7673b6df0bd01dfa87fa60a8

query I rowsort
SELECT DISTINCT 87 * + 37 * - tab1.col1 FROM tab1
----
-32190
-41847
-83694

query I rowsort
SELECT 96 + col2 * - col1 AS col1 FROM tab1
----
-1152
-1308
-474

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

query I rowsort
SELECT DISTINCT - 32 * col2 AS col0 FROM tab2
----
-1216
-832
-864

query I rowsort
SELECT - 2 + col2 AS col0 FROM tab0
----
-1
31
80

query I rowsort
SELECT ALL 48 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT - 3 * - col2 AS col0 FROM tab0
----
246
3
99

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

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

query I rowsort
SELECT DISTINCT col2 * col0 * 68 FROM tab1
----
11016
248064
522240

query I rowsort
SELECT + col2 * 66 * - col2 FROM tab0 AS cor0
----
-443784
-66
-71874

query I rowsort
SELECT ALL - - col0 * + 76 FROM tab2 AS cor0
----
532
5928
6004

query I rowsort
SELECT ALL + cor0.col0 * - col2 + 41 AS col0 FROM tab0 cor0
----
-7257
-751
6

query I rowsort
SELECT + 50 + cor0.col0 * col2 FROM tab2 AS cor0
----
2078
239
3052

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

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

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

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

query I rowsort
SELECT DISTINCT - 78 * - col1 * + 70 FROM tab1 AS cor0
----
141960
54600
70980

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

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

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

query I rowsort
SELECT ALL + 55 * col0 AS col0 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT DISTINCT + - 39 + - col2 + + col0 FROM tab1 cor0
----
-32
-55
-90

query I rowsort
SELECT DISTINCT cor0.col1 * + col0 + col2 - + ( col2 ) * + 8 * - col2 AS col1 FROM tab2 AS cor0
----
10036
12933
6076

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * col2 - - cor0.col0 col1 FROM tab2 AS cor0
----
-1456
-567
-830

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

query I rowsort
SELECT DISTINCT + - 63 - col2 FROM tab1 AS cor0
----
-117
-120
-159

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

skipif mysql # not compatible
query I rowsort label-595
SELECT ALL col0 + CAST ( cor0.col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - col1 + - col1 * + col1 FROM tab1 cor0
----
-110
-182
-702

query I rowsort
SELECT + col2 * - col2 + + 96 * - col2 FROM tab1 AS cor0
----
-18432
-8100
-8721

query I rowsort
SELECT DISTINCT col1 * 17 AS col0 FROM tab2 AS cor0
----
1003
289
527

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

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

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

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

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

query I rowsort
SELECT ALL col2 * 55 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
35530
46035
84370

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

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

query I rowsort
SELECT ALL + 74 * 64 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 340f9ac97d3f35eba3111b1f3fa9f35a

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col2 + tab1.col0 + tab1.col2 col1 FROM tab1
----
-2859
-3128
-9040

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

query I rowsort
SELECT col1 * col1 AS col2 FROM tab2 WHERE col1 / col0 + + col1 * col2 NOT BETWEEN ( - col1 + col1 ) AND col0
----
289
3481
961

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

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

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

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

query I rowsort
SELECT - col1 * - col0 * tab1.col1 + - col0 * col1 AS col0 FROM tab1
----
12480
1950
5760

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-620
SELECT DISTINCT col2 * - col1 * - col2 + col1 DIV + col2 FROM tab1
----
119808
32490
75816

skipif mysql # not compatible
query I rowsort label-620
SELECT DISTINCT col2 * - col1 * - col2 + col1 / + col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT DISTINCT col1 AS col2 FROM tab2 WHERE NULL > + col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + tab0.col2 * col2 col2 FROM tab0
----
1175
6815
98

query I rowsort
SELECT DISTINCT - col1 FROM tab1 WHERE ( + col1 + col1 ) = ( col1 * + col0 )
----

query I rowsort
SELECT col1 + - col0 + col1 FROM tab2
----
-45
40
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-625
SELECT DISTINCT + col1 + - col2 DIV tab1.col2 AS col0 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-625
SELECT DISTINCT + col1 + - col2 / tab1.col2 AS col0 FROM tab1
----
12
25
9

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

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

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

query I rowsort
SELECT ALL - 72 + - 45 FROM tab2
----
-117
-117
-117

query I rowsort
SELECT - col1 + 62 + + col2 FROM tab0
----
-34
53
9

query I rowsort
SELECT DISTINCT + 18 + col0 + col0 AS col2 FROM tab2
----
174
176
32

query I rowsort
SELECT 29 * - col2 FROM tab1 AS cor0
----
-1566
-1653
-2784

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

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

query I rowsort
SELECT 6 * col1 * col1 FROM tab0
----
44376
49686
56454

query I rowsort
SELECT ALL - 21 + ( - col2 * ( col0 ) ) FROM tab0
----
-56
-7319
-813

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 col0 FROM tab2
----
-14
-14
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
54
57
96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-640
SELECT cor0.col1 + - cor0.col0 DIV + 9 + col1 FROM tab1 AS cor0
----
13
18
52

skipif mysql # not compatible
query I rowsort label-640
SELECT cor0.col1 + - cor0.col0 / + 9 + col1 FROM tab1 AS cor0
----
13
18
52

query I rowsort
SELECT ALL + 23 * col2 AS col0 FROM tab0 cor0
----
1886
23
759

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-642
SELECT DISTINCT + col2 * col0 + ( col1 ) / + col1 col2 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT + 73 + col1 + col0 FROM tab0 AS cor0
----
183
205
253

onlyif mysql # use DIV operator for integer division
query I rowsort label-644
SELECT + col0 DIV col1 + col1 * col2 + - col0 FROM tab1
----
1174
1401
512

skipif mysql # not compatible
query I rowsort label-644
SELECT + col0 / col1 + col1 * col2 + - col0 FROM tab1
----
1174
1401
512

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

query I rowsort
SELECT - 10 FROM tab1, tab0 cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-651
SELECT + col0 DIV + ( 93 ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-651
SELECT + col0 / + ( 93 ) FROM tab2
----
0
0
0

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

query I rowsort
SELECT DISTINCT + + col0 * - 35 + col1 AS col1 FROM tab0 cor0
----
-1128
-3024
-754

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

skipif mysql # not compatible
query I rowsort label-654
SELECT - col2 * - CAST ( - col2 AS INTEGER ) - + col0 AS col0 FROM tab2 AS cor0
----
-1523
-736
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-655
SELECT + col0 + + col2 + col2 DIV 44 AS col1 FROM tab0 AS cor0
----
172
36
57

skipif mysql # not compatible
query I rowsort label-655
SELECT + col0 + + col2 + col2 / 44 AS col1 FROM tab0 AS cor0
----
172
36
57

query I rowsort
SELECT ALL - 77 * - col1 AS col1 FROM tab2 AS cor0
----
1309
2387
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col0 ) col2 FROM tab1 AS cor0
----
3
64
80

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

query I rowsort
SELECT + col1 * col0 + col0 + 76 FROM tab2 AS cor0
----
1498
300
4756

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

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

query I rowsort
SELECT ALL - ( 76 ) FROM tab1 AS cor0
----
-76
-76
-76

query I rowsort
SELECT - ( col0 ) * col2 * ( + col0 ) + - col1 FROM tab0 AS cor0
----
-1322
-19094
-649613

query I rowsort
SELECT - 76 + - col1 AS col2 FROM tab2 AS cor0
----
-107
-135
-93

query I rowsort
SELECT ALL + 84 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # use DIV operator for integer division
query I rowsort label-666
SELECT DISTINCT - col1 DIV + ( + col1 ) + col2 * + ( + col0 ) AS col0 FROM tab1 AS cor0
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-666
SELECT DISTINCT - col1 / + ( + col1 ) + col2 * + ( + col0 ) AS col0 FROM tab1 AS cor0
----
161
3647
7679

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-668
SELECT DISTINCT - col1 + CAST( - 58 AS SIGNED ) FROM tab1 AS cor0
----
-68
-71
-84

skipif mysql # not compatible
query I rowsort label-668
SELECT DISTINCT - col1 + CAST ( - 58 AS INTEGER ) FROM tab1 AS cor0
----
-68
-71
-84

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

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

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

query I rowsort
SELECT DISTINCT col0 - ( ( + col2 ) + 51 * - col0 ) FROM tab1
----
102
3271
4064

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

query I rowsort
SELECT col2 + + 44 - col0 AS col0 FROM tab1 AS cor0
----
37
60
95

query I rowsort
SELECT + col1 + + 44 FROM tab1 cor0
----
54
57
70

query I rowsort
SELECT DISTINCT tab2.col1 AS col1 FROM tab2, tab0 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + 52 - cor0.col2 AS col1 FROM tab1, tab1 AS cor0
----
-2
-44
-5

query I rowsort
SELECT ALL - col2 * - 89 FROM tab0
----
2937
7298
89

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

query I rowsort
SELECT - 76 AS col0 FROM tab2 AS cor0
----
-76
-76
-76

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-683
SELECT cor0.col1 DIV col0 + CAST( col0 AS SIGNED ) * - col1 AS col2 FROM tab2 AS cor0
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-683
SELECT cor0.col1 / col0 + CAST ( col0 AS INTEGER ) * - col1 AS col2 FROM tab2 AS cor0
----
-1343
-213
-4602

query I rowsort
SELECT - 22 + - col2 * 44 AS col1 FROM tab0 AS cor0
----
-1474
-3630
-66

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

query I rowsort
SELECT ALL - cor0.col2 * + 81 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c9108b5bd74bee0d25e122f67deb331a

query I rowsort
SELECT DISTINCT - - 4 + + col0 * + col1 FROM tab2 AS cor0
----
1347
221
4606

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-691
SELECT DISTINCT col1 DIV cor0.col2 + - col2 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-170
-55
61

skipif mysql # not compatible
query I rowsort label-691
SELECT DISTINCT col1 / cor0.col2 + - col2 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-170
-55
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 39 * - col0 col2 FROM tab0 AS cor0
----
1365
3471
936

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-696
SELECT ALL - col2 + col1 DIV 9 AS col0 FROM tab1 AS cor0
----
-52
-56
-95

skipif mysql # not compatible
query I rowsort label-696
SELECT ALL - col2 + col1 / 9 AS col0 FROM tab1 AS cor0
----
-52
-56
-95

query I rowsort
SELECT ALL col2 + ( + col0 * col2 ) + 83 * + col0 AS col2 FROM tab0 cor0
----
14767
2817
2941

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-699
SELECT + 78 * + cor0.col2 + + col2 DIV - ( col0 ) FROM tab2 AS cor0
----
2028
2103
2964

skipif mysql # not compatible
query I rowsort label-699
SELECT + 78 * + cor0.col2 + + col2 / - ( col0 ) FROM tab2 AS cor0
----
2028
2103
2964

query I rowsort
SELECT - col2 * - col0 * + col0 + col0 * ( col0 ) AS col2 FROM tab2 AS cor0
----
1372
164268
243399

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

query I rowsort
SELECT ( col2 ) * - col1 + 20 FROM tab1 cor0
----
-1228
-1384
-550

query I rowsort
SELECT + col0 * - 95 FROM tab1
----
-285
-6080
-7600

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

query I rowsort
SELECT DISTINCT ( 60 * tab1.col0 ) AS col0 FROM tab1
----
180
3840
4800

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

query I rowsort
SELECT - 0 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

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

query I rowsort
SELECT DISTINCT - - 61 + col2 * - col0 * + col2 AS col0 FROM tab2 AS cor0
----
-114015
-5042
-52667

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 35 * - 19 col1 FROM tab0
----
-665
-665
-665

query I rowsort
SELECT - 47 FROM tab2, tab1 AS cor0
----
9 values hashing to 6942a0d9558277afd0d00408d65cf5aa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 + + col0 * col2 * + col1 col0 FROM tab0
----
3491
664127
68165

query I rowsort
SELECT + 94 + col2 FROM tab2
----
120
121
132

query I rowsort
SELECT ALL tab1.col1 + 54 AS col2 FROM tab1
----
64
67
80

query I rowsort
SELECT DISTINCT + 39 + col0 FROM tab1
----
103
119
42

query I rowsort
SELECT DISTINCT col1 + 4 AS col2 FROM tab2
----
21
35
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-718
SELECT col2 DIV - col2 + - col1 AS col2 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-718
SELECT col2 / - col2 + - col1 AS col2 FROM tab1
----
-11
-14
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 33 * + 64 + col2 * + col1 col0 FROM tab2
----
56446
57861
80902

query I rowsort
SELECT DISTINCT cor1.col1 AS col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
10
13
26

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-722
SELECT DISTINCT + col1 DIV col1 + col0 * col0 + - col0 FROM tab1 AS cor0
----
4033
6321
7

skipif mysql # not compatible
query I rowsort label-722
SELECT DISTINCT + col1 / col1 + col0 * col0 + - col0 FROM tab1 AS cor0
----
4033
6321
7

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col0 AS REAL ) + col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1456
567
830

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

skipif mysql # not compatible
query I rowsort label-726
SELECT DISTINCT + + CAST ( + 74 AS INTEGER ) FROM tab1 AS cor0
----
74

query I rowsort
SELECT ALL - 0 + + 49 * - cor0.col0 FROM tab1 AS cor0
----
-147
-3136
-3920

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

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

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

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

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

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

query I rowsort
SELECT + - col2 + ( col0 ) + ( cor0.col2 ) * - col0 * - col0 FROM tab0 AS cor0
----
1259
18999
649529

query I rowsort
SELECT DISTINCT + + 51 * + 88 + col2 * col0 AS col2 FROM tab1 AS cor0
----
12168
4650
8136

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

query I rowsort
SELECT ALL col0 + col0 * ( col2 ) + + col1 AS col2 FROM tab0
----
167
7478
902

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-737
SELECT - cor0.col0 DIV - 29 FROM tab1, tab1 AS cor0
----
9 values hashing to dcf0bdb0a33a97c73a81c5b823899d40

skipif mysql # not compatible
query I rowsort label-737
SELECT - cor0.col0 / - 29 FROM tab1, tab1 AS cor0
----
9 values hashing to dcf0bdb0a33a97c73a81c5b823899d40

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

query I rowsort
SELECT ALL - col0 * col2 * + col1 + col1 FROM tab2 AS cor0
----
-119593
-51017
-5828

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

query I rowsort
SELECT DISTINCT - col1 * cor0.col2 - col1 AS col0 FROM tab2 cor0
----
-1593
-663
-868

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-743
SELECT + + col1 * CAST( - col2 AS SIGNED ) + - col2 + 66 FROM tab2 AS cor0
----
-1494
-618
-798

skipif mysql # not compatible
query I rowsort label-743
SELECT + + col1 * CAST ( - col2 AS INTEGER ) + - col2 + 66 FROM tab2 AS cor0
----
-1494
-618
-798

query I rowsort
SELECT DISTINCT - col2 + - 48 FROM tab0 AS cor0
----
-130
-49
-81

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

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

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

query I rowsort
SELECT DISTINCT + + col0 * - 11 FROM tab0 cor0
----
-264
-385
-979

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

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 + CAST ( col1 AS REAL ) * - col1 AS col1 FROM tab1 AS cor0
----
-36
-673
-89

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

query I rowsort
SELECT col0 * + 50 FROM tab2
----
350
3900
3950

query I rowsort
SELECT + + cor0.col2 + 53 AS col2 FROM tab2 AS cor0
----
79
80
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-753
SELECT + cor0.col0 DIV + ( col1 ) + + col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-753
SELECT + cor0.col0 / + ( col1 ) + + col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT + tab0.col0 + 69 FROM tab0
----
104
158
93

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-757
SELECT 67 + col2 DIV col0 AS col0 FROM tab0 AS cor0
----
67
67
68

skipif mysql # not compatible
query I rowsort label-757
SELECT 67 + col2 / col0 AS col0 FROM tab0 AS cor0
----
67
67
68

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

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

query I rowsort
SELECT + 42 + col0 * col0 FROM tab2 AS cor0
----
6126
6283
91

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

skipif mysql # not compatible
query I rowsort label-760
SELECT - 82 / + col0 FROM tab1 cor0
----
-1
-1
-27

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

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

skipif mysql # not compatible
query I rowsort label-762
SELECT + 22 / - col1 FROM tab2 cor0
----
-1
0
0

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

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

query I rowsort
SELECT DISTINCT + 23 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
23

query I rowsort
SELECT + - cor0.col1 * - col1 + + col0 * col1 AS col2 FROM tab2 AS cor0
----
1178
1632
8083

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-770
SELECT DISTINCT - tab2.col1 * 88 DIV tab2.col0 FROM tab2
----
-18
-389
-66

skipif mysql # not compatible
query I rowsort label-770
SELECT DISTINCT - tab2.col1 * 88 / tab2.col0 FROM tab2
----
-18
-389
-66

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

query I rowsort
SELECT - col0 + 54 AS col2 FROM tab1
----
-10
-26
51

query I rowsort
SELECT - col1 * + 64 FROM tab1
----
-1664
-640
-832

query I rowsort
SELECT DISTINCT col2 * - ( + 94 * col1 ) FROM tab1
----
-117312
-131976
-53580

onlyif mysql # use DIV operator for integer division
query I rowsort label-775
SELECT ALL - col2 DIV - 59 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-775
SELECT ALL - col2 / - 59 AS col2 FROM tab1
----
0
0
1

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

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

query I rowsort
SELECT - 81 * col1 * cor0.col2 FROM tab2 AS cor0
----
-124254
-52326
-67797

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-780
SELECT col0 + + 16 DIV + col0 FROM tab2
----
78
79
9

skipif mysql # not compatible
query I rowsort label-780
SELECT col0 + + 16 / + col0 FROM tab2
----
78
79
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-781
SELECT DISTINCT col1 + col0 DIV + col1 + + 62 AS col2 FROM tab1
----
78
81
88

skipif mysql # not compatible
query I rowsort label-781
SELECT DISTINCT col1 + col0 / + col1 + + 62 AS col2 FROM tab1
----
78
81
88

query I rowsort
SELECT + col0 * + 75 + - 35 + + col0 AS col2 FROM tab0 AS cor0
----
1789
2625
6729

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-784
SELECT - 27 DIV + col2 col1 FROM tab1
----
0
0
0

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-786
SELECT + 68 DIV + col2 AS col1 FROM tab0
----
0
2
68

skipif mysql # not compatible
query I rowsort label-786
SELECT + 68 / + col2 AS col1 FROM tab0
----
0
2
68

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

query I rowsort
SELECT + - col0 * 59 + col1 * - cor0.col0 * ( col0 ) AS col2 FROM tab1 AS cor0
----
-411
-44736
-87920

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

query I rowsort
SELECT tab0.col2 * 40 FROM tab0
----
1320
3280
40

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

query I rowsort
SELECT col0 + + cor0.col1 * + col2 * cor0.col1 + ( - cor0.col1 ) FROM tab2 AS cor0
----
11044
25923
90525

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

query I rowsort
SELECT + + 59 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ALL - 46 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to ae4d442ff589a18fe7c7777464d5970c

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-796
SELECT - col2 / - col0 + + col0 col2 FROM tab2 AS cor0
----
10
78
79

query I rowsort
SELECT + - col0 - + 94 FROM tab0 AS cor0
----
-118
-129
-183

query I rowsort
SELECT + cor0.col1 + col0 - 98 FROM tab0 AS cor0
----
12
34
82

query I rowsort
SELECT ALL - col1 * - 99 FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT DISTINCT ( 46 ) FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
46

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

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

query I rowsort
SELECT ALL + - col0 * col2 + - col2 + - 53 * - col1 AS col2 FROM tab0 AS cor0
----
-2557
3733
5105

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + ( - 48 ) col2 FROM tab1, tab1 cor0
----
9 values hashing to a1be3dc775614a409410f633d441a934

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

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

query I rowsort
SELECT ALL 12 + col2 FROM tab0 cor0
----
13
45
94

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + cor0.col1 col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + cor0.col2 + + ( col1 ) * col1 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + + 37 * + col1 + col0 AS col2 FROM tab0 AS cor0
----
3206
3456
3624

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

query I rowsort
SELECT - col0 + + col1 + - tab2.col0 FROM tab2
----
-141
-97
17

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

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

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

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

query I rowsort
SELECT DISTINCT col1 * 45 + col0 * col1 + col0 AS col0 FROM tab2 AS cor0
----
1619
2187
7335

query I rowsort
SELECT - - cor0.col0 + ( + col0 ) * + col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

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

query I rowsort
SELECT col2 + 16 AS col2 FROM tab0 AS cor0
----
17
49
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-822
SELECT ALL - col2 + 64 DIV - col0 + col1 col1 FROM tab0 AS cor0
----
51
9
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-822
SELECT ALL - col2 + 64 / - col0 + col1 col1 FROM tab0 AS cor0
----
51
9
95

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

query I rowsort
SELECT DISTINCT - - col2 * cor0.col1 * col2 + col0 * - col2 * - ( col1 ) FROM tab2 AS cor0
----
159536
28458
75582

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

query I rowsort
SELECT ALL + col2 - col0 * - ( ( col2 ) * + col0 + col1 ) FROM tab0
----
21105
4621
657703

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

query I rowsort
SELECT - col0 + - col0 * tab2.col2 + 31 * col1 FROM tab2
----
-2554
-277
765

onlyif mysql # use DIV operator for integer division
query I rowsort label-829
SELECT DISTINCT 65 * col1 DIV - col1 + - col1 + - col1 AS col0 FROM tab0
----
-237
-247
-259

skipif mysql # not compatible
query I rowsort label-829
SELECT DISTINCT 65 * col1 / - col1 + - col1 + - col1 AS col0 FROM tab0
----
-237
-247
-259

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-831
SELECT DISTINCT + - col0 + + col1 * - col2 / + cor0.col2 col0 FROM tab1 AS cor0
----
-29
-74
-93

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

query I rowsort
SELECT + + 26 + col0 * - 82 AS col1 FROM tab1 cor0
----
-220
-5222
-6534

onlyif mysql # use DIV operator for integer division
query I rowsort label-834
SELECT col0 DIV - 16 FROM tab1
----
-4
-5
0

skipif mysql # not compatible
query I rowsort label-834
SELECT col0 / - 16 FROM tab1
----
-4
-5
0

query I rowsort
SELECT ALL + 72 + + col2 + col0 FROM tab2
----
106
176
189

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

query I rowsort
SELECT ALL 9 * + col2 FROM tab1
----
486
513
864

query I rowsort
SELECT ALL 50 + col0 * - ( + col0 ) FROM tab1
----
-4046
-6350
41

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 15 * cor0.col1 col2 FROM tab2 AS cor0
----
255
465
885

onlyif mysql # use DIV operator for integer division
query I rowsort label-841
SELECT col0 * - col2 + tab0.col2 DIV - col0 FROM tab0
----
-35
-7298
-793

skipif mysql # not compatible
query I rowsort label-841
SELECT col0 * - col2 + tab0.col2 / - col0 FROM tab0
----
-35
-7298
-793

query I rowsort
SELECT col1 + 60 AS col0 FROM tab2
----
119
77
91

query I rowsort
SELECT ALL + col2 * - ( 79 * - col2 ) FROM tab1
----
230364
256671
728064

query I rowsort
SELECT col1 - + ( 32 ) FROM tab0
----
54
59
65

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 * + 98 col0 FROM tab0
----
2352
3430
8722

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

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

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

query I rowsort
SELECT ALL + col2 + - 10 - + col0 FROM tab2 AS cor0
----
-51
-62
10

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

query I rowsort
SELECT - + col1 + 13 AS col0 FROM tab0 cor0
----
-73
-78
-84

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

query I rowsort
SELECT - col1 + tab0.col1 * - col0 AS col2 FROM tab0
----
-2150
-3492
-8190

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col0 col1 FROM tab2 AS cor0
----
-49
-6084
-6241

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-857
SELECT col0 + col1 DIV - col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-857
SELECT col0 + col1 / - col1 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT DISTINCT + col1 * - 69 * col1 AS col1 FROM tab0 cor0
----
-510324
-571389
-649221

onlyif mysql # use DIV operator for integer division
query I rowsort label-859
SELECT DISTINCT + ( + 44 ) DIV cor0.col1 FROM tab1 AS cor0
----
1
3
4

skipif mysql # not compatible
query I rowsort label-859
SELECT DISTINCT + ( + 44 ) / cor0.col1 FROM tab1 AS cor0
----
1
3
4

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

query I rowsort
SELECT ALL 82 + - col1 AS col0 FROM tab0 AS cor0
----
-15
-4
-9

query I rowsort
SELECT ( - col0 + col2 ) FROM tab1
----
-7
16
51

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-866
SELECT ALL - CAST ( + col2 AS INTEGER ) * col0 * col0 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * + 82 col0 FROM tab0 AS cor0
----
-7052
-7462
-7954

query I rowsort
SELECT DISTINCT 48 FROM tab1 cor0
----
48

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

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

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

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

query I rowsort
SELECT 24 * - 47 FROM tab0 AS cor0
----
-1128
-1128
-1128

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

query I rowsort
SELECT - + 29 - + col2 * - col2 FROM tab1 cor0
----
2887
3220
9187

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

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

query I rowsort
SELECT ( - 25 ) + - cor0.col0 FROM tab1 AS cor0
----
-105
-28
-89

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

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

query I rowsort
SELECT ALL - ( - tab0.col0 ) AS col2 FROM tab0
----
24
35
89

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

skipif mysql # not compatible
query I rowsort label-880
SELECT DISTINCT CAST ( NULL AS INTEGER ) * tab1.col1 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + 44 + - col2 AS col2 FROM tab1 AS cor0
----
-10
-13
-52

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

query I rowsort
SELECT - 95 + + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 910371dfa834f9e0e9bb4d6136cfe0f8

query I rowsort
SELECT + 54 + - col1 FROM tab0 cor0
----
-32
-37
-43

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

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

query I rowsort
SELECT + 3 - col0 FROM tab0 AS cor0
----
-21
-32
-86

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-889
SELECT - col0 DIV col0 - cor0.col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-889
SELECT - col0 / col0 - cor0.col0 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT 58 + col2 * col2 FROM tab0
----
1147
59
6782

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

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

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

query I rowsort
SELECT ALL + col0 + col2 - - col2 AS col1 FROM tab2 cor0
----
130
155
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-894
SELECT ALL - col1 + + CAST( 86 AS SIGNED ) + col0 * 67 * col2 FROM tab1 AS cor0
----
10914
244492
514633

skipif mysql # not compatible
query I rowsort label-894
SELECT ALL - col1 + + CAST ( 86 AS INTEGER ) + col0 * 67 * col2 FROM tab1 AS cor0
----
10914
244492
514633

onlyif mysql # use DIV operator for integer division
query I rowsort label-895
SELECT ALL col1 - - col2 DIV cor0.col1 FROM tab2 cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-895
SELECT ALL col1 - - col2 / cor0.col1 FROM tab2 cor0
----
19
31
59

query I rowsort
SELECT DISTINCT - - col1 * ( col2 ) + + col1 * + 64 + col2 AS col0 FROM tab2 AS cor0
----
1772
2848
5336

query I rowsort
SELECT col1 * ( - 9 ) + - col2 AS col1 FROM tab0 AS cor0
----
-807
-874
-901

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

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

query I rowsort
SELECT - + 70 * 69 FROM tab2 AS cor0
----
-4830
-4830
-4830

query I rowsort
SELECT 97 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1, tab0 cor2
----
81 values hashing to f1d3319b9491f64621f2dbb0808458ca

query I rowsort
SELECT DISTINCT + col2 * + col2 + - 22 * + tab1.col0 + col2 * col0 FROM tab1
----
15136
3012
5489

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

query I rowsort
SELECT - tab2.col0 + 52 - col0 AS col1 FROM tab2
----
-104
-106
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-905
SELECT ALL - - cor0.col1 DIV + 8 + - col0 * - cor0.col0 AS col0 FROM tab1 cor0
----
12
4097
6401

skipif mysql # not compatible
query I rowsort label-905
SELECT ALL - - cor0.col1 / + 8 + - col0 * - cor0.col0 AS col0 FROM tab1 cor0
----
12
4097
6401

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

query I rowsort
SELECT 77 * - 30 + col0 AS col1 FROM tab0 AS cor0
----
-2221
-2275
-2286

query I rowsort
SELECT DISTINCT + 26 * col2 FROM tab1 AS cor0
----
1404
1482
2496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + 73 col0 FROM tab2 AS cor0
----
14
42
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 28 * 98 col0 FROM tab0 AS cor0
----
2744
2744
2744

query I rowsort
SELECT col2 + - ( col0 ) * col0 * col2 FROM tab0 AS cor0
----
-1224
-18975
-649440

query I rowsort
SELECT ALL + col2 + + ( + col0 ) * 98 * 15 FROM tab1 AS cor0
----
117696
4464
94137

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

query I rowsort
SELECT + 74 + + col1 AS col2 FROM tab1 AS cor0
----
100
84
87

query I rowsort
SELECT col0 * 44 AS col2 FROM tab2
----
308
3432
3476

query I rowsort
SELECT ALL - - 47 * - 76 + col0 * + 79 AS col0 FROM tab0 AS cor0
----
-1676
-807
3459

query I rowsort
SELECT col2 + - 32 AS col1 FROM tab1 AS cor0
----
22
25
64

query I rowsort
SELECT + - 36 - col0 AS col1 FROM tab0 cor0
----
-125
-60
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 77 + col2 col1 FROM tab0 AS cor0
----
110
159
78

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

query I rowsort
SELECT DISTINCT - col0 * col2 + 15 + - 9 FROM tab0 AS cor0
----
-29
-7292
-786

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

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

query I rowsort
SELECT DISTINCT 9 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9

query I rowsort
SELECT cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT - col1 - - 8 AS col0 FROM tab1 AS cor0
----
-18
-2
-5

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

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

query I rowsort
SELECT ALL + 63 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT col2 - - col2 * ( - 44 ) AS col2 FROM tab0
----
-1419
-3526
-43

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - 54 + 14 col2 FROM tab2 AS cor0
----
-1660
-3172
-904

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

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

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

query I rowsort
SELECT - col1 + + 7 - + cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
-187
-2917
-7546

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

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

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

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

skipif mysql # not compatible
query I rowsort label-938
SELECT ALL - col1 * - CAST ( ( col1 ) AS INTEGER ) - col0 AS col2 FROM tab0 AS cor0
----
7372
8192
9374

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

query I rowsort
SELECT - + col1 * 22 FROM tab2 AS cor0
----
-1298
-374
-682

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

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

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

query I rowsort
SELECT DISTINCT col2 * ( ( col2 ) ) * + 73 AS col2 FROM tab1 cor0
----
212868
237177
672768

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

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

query I rowsort
SELECT col0 + - col2 * ( col0 + + ( - cor0.col1 ) ) AS col2 FROM tab0 AS cor0
----
2070
253
97

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

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

query I rowsort
SELECT col2 * 79 + col0 AS col2 FROM tab1 AS cor0
----
4269
4567
7664

query I rowsort
SELECT + col1 - 50 FROM tab2
----
-19
-33
9

query I rowsort
SELECT + - cor0.col0 + - col1 * - 36 FROM tab0 cor0
----
3072
3187
3457

query I rowsort
SELECT - - 8 * - col2 AS col1 FROM tab2 AS cor0
----
-208
-216
-304

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

query I rowsort
SELECT 19 + - tab1.col2 AS col2 FROM tab1
----
-35
-38
-77

query I rowsort
SELECT 23 * cor0.col0 * - col1 FROM tab1 AS cor0
----
-14720
-1794
-23920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + col0 col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 75 * col1 AS col1 FROM tab1 cor0
----
1950
750
975

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

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

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

query I rowsort
SELECT - col1 - col2 FROM tab2 WHERE NOT col0 <> NULL
----

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

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

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

skipif mysql # not compatible
query I rowsort label-964
SELECT DISTINCT - col2 / - col0 + + col1 FROM tab2
----
17
34
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col0 + col2 * col0 * + tab2.col1 col1 FROM tab2
----
121680
54036
6048

query I rowsort
SELECT ALL - col1 + - col0 / + tab1.col0 FROM tab1 WHERE NOT NULL IN ( col1 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col0 FROM tab1 WHERE NOT col0 BETWEEN col1 AND col2
----
10
26

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

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

query I rowsort
SELECT - 37 + col0 * - 33 + + col2 * - col2 * 34 FROM tab0 cor0
----
-1226
-231590
-37855

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

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

query I rowsort
SELECT DISTINCT - col1 * tab1.col2 * col2 FROM tab1
----
-119808
-32490
-75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 * col2 col1 FROM tab0
----
26136
35
598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col2 col2 FROM tab2 WHERE NULL IN ( col1 * + col0 )
----

query I rowsort
SELECT col0 + col0 * - 5 + - ( col2 ) FROM tab1 AS cor0
----
-313
-416
-66

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

query I rowsort
SELECT + col1 * + col0 * + col1 - col0 * + col0 AS col2 FROM tab0
----
176928
328090
729088

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

query I rowsort
SELECT + col0 + - col2 * + col1 + col0 FROM tab1
----
-1088
-1398
-442

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 * col1 col2 FROM tab0
----
-3395
-664118
-68112

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

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

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

query I rowsort
SELECT DISTINCT + col0 AS col1 FROM tab0 cor0 WHERE NOT ( col0 * col0 + col2 ) IN ( + cor0.col1 + col0 + col0 * col1 )
----
24
35
89

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 * + tab2.col0 col2 FROM tab2
----
-1326
-186
-4543

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

query I rowsort
SELECT ALL col2 - col1 FROM tab1 WHERE NOT col2 = - col1
----
28
47
83

query I rowsort
SELECT DISTINCT + tab2.col2 * + col1 + tab2.col1 * tab2.col1 FROM tab2
----
1798
5015
935

query I rowsort
SELECT DISTINCT + col1 FROM tab2 WHERE ( - col0 ) BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-992
SELECT DISTINCT col1 DIV col0 + col2 * col2 FROM tab1
----
2924
3249
9216

skipif mysql # not compatible
query I rowsort label-992
SELECT DISTINCT col1 / col0 + col2 * col2 FROM tab1
----
2924
3249
9216

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

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

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

query III rowsort
SELECT * FROM tab0 WHERE ( - col0 ) IN ( col1 * - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-997
SELECT + col1 + + tab1.col0 DIV - tab1.col0 AS col2 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-997
SELECT + col1 + + tab1.col0 / - tab1.col0 AS col2 FROM tab1
----
12
25
9

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

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

query I rowsort
SELECT ALL + 45 + + col2 AS col2 FROM tab1 AS cor0
----
102
141
99

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

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

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

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

skipif mysql # not compatible
query I rowsort label-1003
SELECT - - col0 + + 33 / + 37 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col0 + - 9 * - col1 FROM tab1 AS cor0
----
231
26
37

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

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

skipif mysql # not compatible
query I rowsort label-1006
SELECT - col2 / cor0.col1 + cor0.col2 + - col1 / ( + 38 ) FROM tab2 cor0
----
25
27
36

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col2 + col1 + - col2 * - 41 * col2 col0 FROM tab2 cor0
----
26241
29083
58575

query I rowsort
SELECT 50 FROM tab0, tab0 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

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

query I rowsort
SELECT ALL col1 + col0 - + col0 * + 15 AS col0 FROM tab0
----
-1155
-250
-393

query I rowsort
SELECT ALL + tab0.col0 * - 60 FROM tab0
----
-1440
-2100
-5340

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1013
SELECT DISTINCT CAST( - 35 AS SIGNED ) - - col2 FROM tab1
----
19
22
61

skipif mysql # not compatible
query I rowsort label-1013
SELECT DISTINCT CAST ( - 35 AS INTEGER ) - - col2 FROM tab1
----
19
22
61

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

query I rowsort
SELECT - cor0.col0 * 60 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to e8961e62bb8b0be673e40358071b8ff6

query I rowsort
SELECT + - 4 * col2 AS col2 FROM tab1 AS cor0
----
-216
-228
-384

query I rowsort
SELECT - col1 * col1 * - col1 + + col1 * col1 + - col1 * - cor0.col1 FROM tab1 AS cor0
----
1200
18928
2535

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

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

query I rowsort
SELECT - cor0.col0 * - col1 + col1 + + cor0.col2 * + col0 FROM tab1 AS cor0
----
266
4298
8733

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

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

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

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

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

query I rowsort
SELECT + col0 * col0 - - ( col2 ) AS col0 FROM tab0 AS cor0
----
1226
609
8003

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

query I rowsort
SELECT + 1 * col1 * 63 + ( col0 ) AS col1 FROM tab0 cor0
----
5442
5822
6146

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

query I rowsort
SELECT + col1 + + col1 * - col1 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - 15 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 cor1, tab2 AS cor2, tab2 AS cor3
----
243 values hashing to 493d0614a60e9819b5547eae2efb074c

query I rowsort
SELECT col0 + + 72 * + 86 AS col1 FROM tab0
----
6216
6227
6281

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

query I rowsort
SELECT - col0 + 47 FROM tab0 AS cor0
----
-42
12
23

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT ALL - 30 * + col2 + col2 AS col2 FROM tab0 AS cor0
----
-2378
-29
-957

query I rowsort
SELECT DISTINCT - - ( 58 ) + - col2 FROM tab2 AS cor0
----
20
31
32

query I rowsort
SELECT ALL ( - 83 ) - + col2 AS col1 FROM tab2 cor0
----
-109
-110
-121

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

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

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

skipif mysql # not compatible
query I rowsort label-1041
SELECT DISTINCT CAST ( col0 AS INTEGER ) * col1 + - ( col0 ) AS col1 FROM tab0 cor0
----
2040
3360
8010

query I rowsort
SELECT ALL + 93 + - col0 FROM tab2 cor0
----
14
15
86

query I rowsort
SELECT DISTINCT - 12 + col2 AS col0 FROM tab2 AS cor0
----
14
15
26

query I rowsort
SELECT + 18 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - - 8 col2 FROM tab2 AS cor0
----
-23
-51
-9

query I rowsort
SELECT DISTINCT - - col0 - + 62 * - col2 * - col0 FROM tab0 AS cor0
----
-2135
-452387
-49080

query I rowsort
SELECT ALL + + col2 + + 73 FROM tab0 AS cor0
----
106
155
74

query I rowsort
SELECT 42 * + col2 AS col1 FROM tab0 AS cor0
----
1386
3444
42

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

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

query I rowsort
SELECT col2 * col0 * - col0 + + col2 FROM tab2 AS cor0
----
-1296
-158158
-237120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1052
SELECT DISTINCT - cor0.col2 + CAST( - 11 * - col0 AS SIGNED ) FROM tab0 cor0
----
231
384
897

skipif mysql # not compatible
query I rowsort label-1052
SELECT DISTINCT - cor0.col2 + CAST ( - 11 * - col0 AS INTEGER ) FROM tab0 cor0
----
231
384
897

onlyif mysql # use DIV operator for integer division
query I rowsort label-1053
SELECT DISTINCT - col2 DIV - CAST( col0 * - col1 AS SIGNED ) - 17 FROM tab2 cor0
----
-17

skipif mysql # not compatible
query I rowsort label-1053
SELECT DISTINCT - col2 / - CAST ( col0 * - col1 AS INTEGER ) - 17 FROM tab2 cor0
----
-17

query I rowsort
SELECT + - col2 * cor0.col0 + - 39 * col2 AS col0 FROM tab1 AS cor0
----
-11424
-2268
-5871

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

query I rowsort
SELECT ALL tab2.col2 * - 31 AS col0 FROM tab2
----
-1178
-806
-837

query I rowsort
SELECT - col2 - ( + col2 + - col1 ) FROM tab0
----
-73
20
95

query I rowsort
SELECT + 50 * cor0.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d2ff32563fae27ec65bd7fd9c8f1b456

query I rowsort
SELECT col0 + 7 * + col1 FROM tab1 AS cor0
----
134
171
185

query I rowsort
SELECT col2 * - ( - 67 ) AS col1 FROM tab1
----
3618
3819
6432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - ( - 29 ) col0 FROM tab1 AS cor0
----
16
19
3

query I rowsort
SELECT col0 * col0 + + 24 AS col1 FROM tab0
----
1249
600
7945

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

query I rowsort
SELECT DISTINCT + 48 * cor0.col1 FROM tab0 AS cor0
----
4128
4368
4656

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1066
SELECT ALL + 13 * + col0 - CAST( col2 + + col2 * 13 AS SIGNED ) FROM tab0 AS cor0
----
-150
441
9

skipif mysql # not compatible
query I rowsort label-1066
SELECT ALL + 13 * + col0 - CAST ( col2 + + col2 * 13 AS INTEGER ) FROM tab0 AS cor0
----
-150
441
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1067
SELECT ALL + col1 DIV + col1 + + 34 + + col2 col1 FROM tab1 AS cor0
----
131
89
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1067
SELECT ALL + col1 / + col1 + + 34 + + col2 col1 FROM tab1 AS cor0
----
131
89
92

query I rowsort
SELECT + col1 * col1 + + 59 FROM tab2 AS cor0
----
1020
348
3540

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1070
SELECT ALL - col2 * cor0.col2 + col1 DIV + col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-1070
SELECT ALL - col2 * cor0.col2 + col1 / + col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

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

query I rowsort
SELECT DISTINCT col1 * - col2 + col1 + col2 * - cor0.col0 FROM tab2 AS cor0
----
-3503
-3631
-995

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 * 69 col0 FROM tab1 AS cor0
----
-207
-4416
-5520

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1076
SELECT DISTINCT - col2 + + 72 + 37 * col0 DIV 13 AS col0 FROM tab1 AS cor0
----
197
203
26

skipif mysql # not compatible
query I rowsort label-1076
SELECT DISTINCT - col2 + + 72 + 37 * col0 / 13 AS col0 FROM tab1 AS cor0
----
197
203
26

query I rowsort
SELECT ALL + 53 FROM tab0, tab1 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT ALL ( - 88 ) + + col1 FROM tab0 AS cor0
----
-2
3
9

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

query I rowsort
SELECT ALL + - 3 + 76 * + col2 FROM tab0 AS cor0
----
2505
6229
73

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

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

query I rowsort
SELECT DISTINCT + tab1.col0 * + 16 FROM tab1
----
1024
1280
48

query I rowsort
SELECT + - 42 * col1 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT ALL - 94 * 3 FROM tab1 AS cor0
----
-282
-282
-282

query I rowsort
SELECT ( + col0 ) + + col2 * ( - col2 ) FROM tab0 cor0
----
-1065
-6635
34

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

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

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

query I rowsort
SELECT ALL col2 + + 59 FROM tab0
----
141
60
92

query I rowsort
SELECT 3 - col1 FROM tab1
----
-10
-23
-7

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col2 ) * - 29 col1 FROM tab0 AS cor0
----
-2378
-29
-957

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

query I rowsort
SELECT + ( + 35 ) AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT DISTINCT + 9 + col2 FROM tab2
----
35
36
47

query I rowsort
SELECT ALL col0 + - 30 FROM tab0
----
-6
5
59

query I rowsort
SELECT 93 * - tab0.col2 FROM tab0
----
-3069
-7626
-93

query I rowsort
SELECT DISTINCT + 20 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
20

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 * 41 col0 FROM tab2
----
188682
55063
8897

query I rowsort
SELECT col2 * - 87 FROM tab1
----
-4698
-4959
-8352

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1104
SELECT DISTINCT + col0 + col2 + col2 DIV + col2 FROM tab0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-1104
SELECT DISTINCT + col0 + col2 + col2 / + col2 FROM tab0
----
172
37
58

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

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

query I rowsort
SELECT col2 - - 15 AS col1 FROM tab1 cor0
----
111
69
72

query I rowsort
SELECT - + 80 * - col1 + cor0.col2 FROM tab1 AS cor0
----
1136
2134
857

query I rowsort
SELECT - col0 + ( col2 ) FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL col1 * 78 AS col0 FROM tab1
----
1014
2028
780

query I rowsort
SELECT col0 * col2 * - 0 + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - col0 + ( ( col0 ) ) + + col0 AS col2 FROM tab2
----
7
78
79

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1113
SELECT ALL + col0 + 16 + 71 DIV + tab0.col2 FROM tab0
----
105
122
42

skipif mysql # not compatible
query I rowsort label-1113
SELECT ALL + col0 + 16 + 71 / + tab0.col2 FROM tab0
----
105
122
42

query I rowsort
SELECT ALL - 18 FROM tab0, tab1 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

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

query I rowsort
SELECT - col1 * 32 + - col1 * col2 AS col2 FROM tab0 AS cor0
----
-10374
-3201
-5590

query I rowsort
SELECT ALL - - col1 + + 89 * - cor0.col1 FROM tab2 cor0
----
-1496
-2728
-5192

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

query I rowsort
SELECT - cor1.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1120
SELECT - 26 * col2 DIV col0 FROM tab2 cor0
----
-100
-12
-8

skipif mysql # not compatible
query I rowsort label-1120
SELECT - 26 * col2 / col0 FROM tab2 cor0
----
-100
-12
-8

query I rowsort
SELECT - 20 + 63 AS col2 FROM tab2 AS cor0
----
43
43
43

query I rowsort
SELECT + 70 + 30 * + cor0.col2 FROM tab1 AS cor0
----
1690
1780
2950

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

skipif mysql # not compatible
query I rowsort label-1123
SELECT ALL + + 43 + - col1 / - col1 FROM tab0 AS cor0
----
44
44
44

query I rowsort
SELECT - - col0 + 19 * + col1 FROM tab1 AS cor0
----
254
327
497

query I rowsort
SELECT - - 31 - - cor0.col2 * col1 FROM tab0 AS cor0
----
128
2869
7493

query I rowsort
SELECT ALL + - col2 + + 24 FROM tab0 cor0
----
-58
-9
23

query I rowsort
SELECT DISTINCT + col1 * - 32 AS col2 FROM tab1 AS cor0
----
-320
-416
-832

query I rowsort
SELECT - col2 * + 91 AS col0 FROM tab0 AS cor0
----
-3003
-7462
-91

query I rowsort
SELECT ALL + col0 * - 19 AS col0 FROM tab1 AS cor0
----
-1216
-1520
-57

query I rowsort
SELECT ALL + 94 * + col0 AS col1 FROM tab0
----
2256
3290
8366

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1134
SELECT - col0 + - 29 * col2 DIV tab1.col1 AS col0 FROM tab1
----
-229
-294
-63

skipif mysql # not compatible
query I rowsort label-1134
SELECT - col0 + - 29 * col2 / tab1.col1 AS col0 FROM tab1
----
-229
-294
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-1135
SELECT + col0 * col2 + col1 DIV - col2 FROM tab0
----
-62
7297
790

skipif mysql # not compatible
query I rowsort label-1135
SELECT + col0 * col2 + col1 / - col2 FROM tab0
----
-62
7297
790

query I rowsort
SELECT col2 * 8 + tab1.col2 FROM tab1
----
486
513
864

query I rowsort
SELECT ALL ( col2 + col1 ) * col0 AS col1 FROM tab1
----
240
4288
8720

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

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

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

query I rowsort
SELECT + + 10 AS col1 FROM tab0 AS cor0
----
10
10
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-1141
SELECT col0 + + col0 DIV + col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-1141
SELECT col0 + + col0 / + col2 FROM tab0
----
24
70
90

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

query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
13824
42875
704969

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

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

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

query I rowsort
SELECT ( col2 ) + ( 18 ) * tab2.col1 AS col0 FROM tab2
----
1088
344
585

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

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

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

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

query I rowsort
SELECT - cor0.col0 * - 97 FROM tab2 AS cor0
----
679
7566
7663

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

query I rowsort
SELECT DISTINCT col0 + + 91 * - 31 FROM tab1 AS cor0
----
-2741
-2757
-2818

query I rowsort
SELECT - col0 + + 33 AS col1 FROM tab0 AS cor0
----
-2
-56
9

query I rowsort
SELECT ALL - - col1 + ( + ( col1 ) * + 48 ) AS col1 FROM tab1 AS cor0
----
1274
490
637

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

query I rowsort
SELECT DISTINCT - col2 + 7 FROM tab2 AS cor0
----
-19
-20
-31

query I rowsort
SELECT + col1 * 38 * col2 FROM tab0 AS cor0
----
107844
283556
3686

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

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

query I rowsort
SELECT - col2 * col1 * + col2 + col2 * 85 FROM tab2 cor0
----
-20304
-21318
-37674

query I rowsort
SELECT DISTINCT cor0.col1 + 97 * col0 AS col0 FROM tab1 AS cor0
----
317
6218
7773

onlyif mysql # use DIV operator for integer division
query I rowsort label-1162
SELECT + 92 + col1 - + cor0.col2 DIV 50 FROM tab2 AS cor0
----
109
123
151

skipif mysql # not compatible
query I rowsort label-1162
SELECT + 92 + col1 - + cor0.col2 / 50 FROM tab2 AS cor0
----
109
123
151

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

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

query I rowsort
SELECT DISTINCT - cor0.col1 + 47 FROM tab0 AS cor0
----
-39
-44
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-1166
SELECT col2 DIV 88 + col2 col0 FROM tab1 AS cor0
----
54
57
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1166
SELECT col2 / 88 + col2 col0 FROM tab1 AS cor0
----
54
57
97

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

query I rowsort
SELECT col0 + col2 + - col2 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL 70 * col1 + col0 + col0 FROM tab0 AS cor0
----
6068
6548
6860

query I rowsort
SELECT DISTINCT + 3 * + col1 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ALL - col0 * + 47 FROM tab0 AS cor0
----
-1128
-1645
-4183

query I rowsort
SELECT ALL + col1 + + 56 * col2 FROM tab1 AS cor0
----
3050
3202
5389

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + ( col1 ) col2 FROM tab1 cor0
----
29
74
93

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

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

query I rowsort
SELECT ALL + col1 * col0 + col0 + + cor0.col2 FROM tab1 AS cor0
----
1216
135
761

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) * cor0.col2 + 32 FROM tab0 AS cor0
----
-2806
-65
-7430

query I rowsort
SELECT - 23 * - col0 * col0 + - 77 FROM tab1 AS cor0
----
130
147123
94131

query I rowsort
SELECT DISTINCT - 97 + col0 AS col0 FROM tab2 AS cor0
----
-18
-19
-90

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1179
SELECT ALL - - col2 / + cor0.col1 + col2 col0 FROM tab1 cor0
----
103
56
62

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

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

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

query I rowsort
SELECT + 41 * col0 + col1 * + col1 AS col0 FROM tab2 cor0
----
1248
3528
6679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1184
SELECT DISTINCT + ( - col0 ) + + CAST( - col2 + col2 AS SIGNED ) * - 64 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-1184
SELECT DISTINCT + ( - col0 ) + + CAST ( - col2 + col2 AS INTEGER ) * - 64 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + + col2 * + col2 + + ( col2 ) * - col1 FROM tab1 AS cor0
----
1512
2679
7968

query I rowsort
SELECT DISTINCT + cor0.col2 * + col2 + 13 AS col0 FROM tab1 cor0
----
2929
3262
9229

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 + col2 * ( + col1 + + col1 ) col2 FROM tab1 AS cor0
----
1456
2730
500

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1192
SELECT + 31 + col0 + col0 DIV col1 AS col1 FROM tab2 AS cor0
----
110
114
38

skipif mysql # not compatible
query I rowsort label-1192
SELECT + 31 + col0 + col0 / col1 AS col1 FROM tab2 AS cor0
----
110
114
38

query I rowsort
SELECT - + col1 + 5 * col2 AS col0 FROM tab1 cor0
----
244
275
467

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1195
SELECT DISTINCT + + 81 * cor0.col0 + col2 DIV 41 - col2 FROM tab2 AS cor0
----
540
6292
6361

skipif mysql # not compatible
query I rowsort label-1195
SELECT DISTINCT + + 81 * cor0.col0 + col2 / 41 - col2 FROM tab2 AS cor0
----
540
6292
6361

query I rowsort
SELECT ALL + - ( - 92 ) + col2 FROM tab1 AS cor0
----
146
149
188

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

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

skipif mysql # not compatible
query I rowsort label-1198
SELECT + + col1 / - col1 + - col0 * - cor0.col1 FROM tab1 cor0
----
1039
639
77

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

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

query I rowsort
SELECT ALL col2 * + col2 + - col1 AS col1 FROM tab2
----
1427
617
698

query I rowsort
SELECT ALL + col1 + col2 + + 62 AS col0 FROM tab0
----
160
181
235

onlyif mysql # use DIV operator for integer division
query I rowsort label-1202
SELECT ALL ( col2 ) + col1 DIV + col0 + col0 * col2 col0 FROM tab2
----
2054
220
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1202
SELECT ALL ( col2 ) + col1 / + col0 + col0 * col2 col0 FROM tab2
----
2054
220
3040

query I rowsort
SELECT + ( + col2 ) * 31 + + col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
10656
1836
5415

query I rowsort
SELECT ALL + 16 AS col0 FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT + - col2 * - col2 + - cor0.col1 * + col0 + col0 FROM tab2 AS cor0
----
-3848
180
519

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

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

query I rowsort
SELECT DISTINCT - - col2 + ( + col0 ) * + col1 + + ( 59 ) AS col2 FROM tab2 AS cor0
----
1440
303
4687

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

query I rowsort
SELECT col1 * - 81 FROM tab0
----
-6966
-7371
-7857

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

query I rowsort
SELECT - col0 * 85 AS col2 FROM tab0
----
-2040
-2975
-7565

query I rowsort
SELECT + col1 * - col2 * + col2 + col1 AS col2 FROM tab1 cor0
----
-119795
-32480
-75790

query I rowsort
SELECT DISTINCT - tab0.col1 - - 45 * col1 AS col1 FROM tab0
----
3784
4004
4268

query I rowsort
SELECT cor0.col2 * + col2 * cor0.col1 + - col0 + col0 FROM tab1 AS cor0
----
119808
32490
75816

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

query I rowsort
SELECT - + col2 * - cor0.col2 * + col1 + col0 AS col0 FROM tab1 AS cor0
----
119888
32554
75819

query I rowsort
SELECT + col0 * + 7 AS col1 FROM tab0 AS cor0
----
168
245
623

query I rowsort
SELECT col2 * 37 * col0 - - col2 AS col0 FROM tab0 AS cor0
----
1296
270108
29337

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT - - 11 * col0 FROM tab2 cor0
----
77
858
869

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

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

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

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

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

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

query I rowsort
SELECT - - 55 FROM tab0 cor0
----
55
55
55

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

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

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

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

query I rowsort
SELECT ALL 41 FROM tab1, tab1 cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1235
SELECT ALL - ( col2 ) + - col2 + col2 DIV + col1 FROM tab1 AS cor0
----
-106
-109
-185

skipif mysql # not compatible
query I rowsort label-1235
SELECT ALL - ( col2 ) + - col2 + col2 / + col1 FROM tab1 AS cor0
----
-106
-109
-185

query I rowsort
SELECT ( 91 ) AS col2 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT DISTINCT - 72 * + 43 * col2 + - col0 * col2 FROM tab0 AS cor0
----
-102960
-261170
-3131

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

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

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

query I rowsort
SELECT + + 79 * col1 + - col0 FROM tab1 cor0
----
2051
726
947

onlyif mysql # use DIV operator for integer division
query I rowsort label-1241
SELECT ALL - + cor0.col0 - + col1 DIV col1 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-1241
SELECT ALL - + cor0.col0 - + col1 / col1 FROM tab2 AS cor0
----
-79
-8
-80

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 43 + - col1 col2 FROM tab1 AS cor0
----
-53
-56
-69

query I rowsort
SELECT 4 + col1 AS col0 FROM tab0 AS cor0
----
101
90
95

query I rowsort
SELECT DISTINCT - 95 + + col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-17
545
945

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 2 - col1 * - col0 col0 FROM tab1 AS cor0
----
1042
642
80

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

query I rowsort
SELECT - + 86 * col2 * col2 AS col2 FROM tab0 AS cor0
----
-578264
-86
-93654

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * - 67 * + cor0.col1 col0 FROM tab0 AS cor0
----
-190146
-499954
-6499

onlyif mysql # use DIV operator for integer division
query I rowsort label-1252
SELECT ALL + col2 - 83 DIV col2 FROM tab0 AS cor0
----
-82
31
81

skipif mysql # not compatible
query I rowsort label-1252
SELECT ALL + col2 - 83 / col2 FROM tab0 AS cor0
----
-82
31
81

query I rowsort
SELECT - col1 * - 93 + + col2 FROM tab1 AS cor0
----
1305
2472
987

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

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

query I rowsort
SELECT ALL - ( - col0 ) * - 30 FROM tab2
----
-210
-2340
-2370

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1258
SELECT 80 DIV tab0.col2 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d9a855f3cb0336c59fcc1e1cd8e4c66f

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1258
SELECT 80 / tab0.col2 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d9a855f3cb0336c59fcc1e1cd8e4c66f

query I rowsort
SELECT + 47 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

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

query I rowsort
SELECT - cor0.col0 * col1 + + 88 + + col2 AS col2 FROM tab0 AS cor0
----
-1943
-3306
-7929

onlyif mysql # use DIV operator for integer division
query I rowsort label-1262
SELECT col0 DIV - 54 + - 92 AS col1 FROM tab0 AS cor0
----
-92
-92
-93

skipif mysql # not compatible
query I rowsort label-1262
SELECT col0 / - 54 + - 92 AS col1 FROM tab0 AS cor0
----
-92
-92
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 20 + - ( + col2 + - col1 ) col0 FROM tab0 cor0
----
-1667
-1811
-1844

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col2 + - col0 * col0 FROM tab0
----
-1226
-609
-8003

query I rowsort
SELECT DISTINCT col2 + - col1 * col1 * - col0 AS col1 FROM tab1
----
13616
2082
6457

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

skipif mysql # not compatible
query I rowsort label-1269
SELECT - col0 + col2 / col1 FROM tab2 AS cor0
----
-7
-77
-78

query I rowsort
SELECT DISTINCT + col1 + col0 * + col1 + tab0.col1 FROM tab0
----
2236
3589
8281

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

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

skipif mysql # not compatible
query I rowsort label-1272
SELECT + col0 / - col0 + + tab2.col2 / - col0 FROM tab2
----
-1
-1
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1273
SELECT DISTINCT col1 + - tab0.col0 + + col2 DIV - col0 FROM tab0
----
2
61
62

skipif mysql # not compatible
query I rowsort label-1273
SELECT DISTINCT col1 + - tab0.col0 + + col2 / - col0 FROM tab0
----
2
61
62

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1279
SELECT + cor0.col0 + + col1 / col0 + + col0 col0 FROM tab2 AS cor0
----
156
158
18

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

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

query I rowsort
SELECT - - cor0.col0 + col0 + col1 * + col1 AS col2 FROM tab0 AS cor0
----
7444
8459
9479

onlyif mysql # use DIV operator for integer division
query I rowsort label-1283
SELECT DISTINCT - 50 DIV tab1.col1 AS col1 FROM tab1
----
-1
-3
-5

skipif mysql # not compatible
query I rowsort label-1283
SELECT DISTINCT - 50 / tab1.col1 AS col1 FROM tab1
----
-1
-3
-5

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

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

query I rowsort
SELECT - 11 * + col0 - + col0 * tab1.col1 AS col0 FROM tab1
----
-111
-1344
-1920

onlyif mysql # use DIV operator for integer division
query I rowsort label-1286
SELECT DISTINCT + col0 + col1 DIV col0 col2 FROM tab1 AS cor0
----
11
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1286
SELECT DISTINCT + col0 + col1 / col0 col2 FROM tab1 AS cor0
----
11
64
80

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 - + cor0.col0 col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + - col2 + col1 + + col0 * cor0.col0 FROM tab1 AS cor0
----
-19
4049
6317

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

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

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

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

query I rowsort
SELECT - col1 + - cor0.col2 * col1 * col2 FROM tab0 cor0
----
-194
-611975
-93740

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - ( + col1 ) + tab1.col1 * - col1 * col0 AS col1 FROM tab1
----
-13533
-2054
-6410

query I rowsort
SELECT DISTINCT col2 + - 72 AS col2 FROM tab2
----
-34
-45
-46

query I rowsort
SELECT - - 35 * + col2 AS col1 FROM tab0 AS cor0
----
1155
2870
35

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

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

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

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

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

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

query I rowsort
SELECT - - 38 * + col0 FROM tab0 AS cor0
----
1330
3382
912

query I rowsort
SELECT - 48 * + col1 AS col0 FROM tab0 AS cor0
----
-4128
-4368
-4656

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

query I rowsort
SELECT col0 + + 15 * col0 FROM tab1
----
1024
1280
48

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

query I rowsort
SELECT + cor1.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

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

query I rowsort
SELECT ALL 74 + col0 AS col0 FROM tab2
----
152
153
81

query I rowsort
SELECT DISTINCT 13 * tab0.col1 AS col1 FROM tab0, tab2 AS cor0
----
1118
1183
1261

onlyif mysql # use DIV operator for integer division
query I rowsort label-1321
SELECT ALL - 97 DIV - 9 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

skipif mysql # not compatible
query I rowsort label-1321
SELECT ALL - 97 / - 9 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT ( col2 + col1 ) * - col1 AS col0 FROM tab0
----
-10234
-15743
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-1323
SELECT + 40 DIV col1 FROM tab1
----
1
3
4

skipif mysql # not compatible
query I rowsort label-1323
SELECT + 40 / col1 FROM tab1
----
1
3
4

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( ( col0 ) ) col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + 20 FROM tab1, tab2 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 69 * col1 col1 FROM tab2 AS cor0
----
-1173
-2139
-4071

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

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

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

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

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

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

query I rowsort
SELECT - col0 * col1 + cor0.col2 * 27 * + col0 AS col1 FROM tab0 AS cor0
----
-2450
188947
19320

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

query I rowsort
SELECT DISTINCT - col2 + 62 AS col2 FROM tab1 AS cor0
----
-34
5
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1337
SELECT + - col1 + col1 DIV 14 FROM tab1 AS cor0
----
-10
-13
-25

skipif mysql # not compatible
query I rowsort label-1337
SELECT + - col1 + col1 / 14 FROM tab1 AS cor0
----
-10
-13
-25

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

skipif mysql # not compatible
query I rowsort label-1338
SELECT ALL - + col0 / - ( col0 ) AS col1 FROM tab2 AS cor0
----
1
1
1

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

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

skipif mysql # not compatible
query I rowsort label-1340
SELECT + col2 * col0 / cor0.col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - 39 + 42 AS col0 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT ALL col2 * 77 * + 6 AS col0 FROM tab1
----
24948
26334
44352

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

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

query I rowsort
SELECT - col0 + - cor0.col2 + - col2 FROM tab2 AS cor0
----
-130
-155
-61

query I rowsort
SELECT cor0.col0 + 20 * - 64 FROM tab2 cor0
----
-1201
-1202
-1273

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

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

query I rowsort
SELECT ALL col2 * col0 + cor0.col1 - + col0 * 87 FROM tab0 AS cor0
----
-1210
-2913
-354

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

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

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

query I rowsort
SELECT + 85 + 90 + col2 FROM tab2 AS cor0
----
201
202
213

query I rowsort
SELECT DISTINCT - + col0 * 77 FROM tab2 AS cor0
----
-539
-6006
-6083

query I rowsort
SELECT 20 AS col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT ALL + + 62 * + col1 FROM tab0 cor0
----
5332
5642
6014

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

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

query I rowsort
SELECT - col2 * + col0 + col2 + col0 FROM tab1
----
-105
-3527
-7504

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

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

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

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

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

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

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

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

query I rowsort
SELECT - ( col0 ) * 68 * - col1 AS col0 FROM tab2
----
14756
312936
91324

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

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

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

query I rowsort
SELECT ALL + - col1 * - col1 + col2 * col1 AS col1 FROM tab2 cor0
----
1798
5015
935

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1371
SELECT DISTINCT + col1 + - CAST( col2 * - cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-1371
SELECT DISTINCT + col1 + - CAST ( col2 * - cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT 50 * + cor0.col0 AS col1 FROM tab0, tab2, tab2 AS cor0
----
350
3900
3950

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 + + col1 * + 2 - - col0 * + col0 col2 FROM tab1
----
115
4173
6522

query I rowsort
SELECT ALL + 52 * col1 * col2 AS col2 FROM tab2
----
33592
43524
79768

query I rowsort
SELECT - + col2 * 83 + col0 FROM tab2 cor0
----
-2080
-2234
-3075

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 col0 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1378
SELECT ALL - - cor0.col2 DIV + 49 - ( + col2 + 53 ) FROM tab2 cor0
----
-79
-80
-91

skipif mysql # not compatible
query I rowsort label-1378
SELECT ALL - - cor0.col2 / + 49 - ( + col2 + 53 ) FROM tab2 cor0
----
-79
-80
-91

query I rowsort
SELECT - col1 + 99 * - cor0.col0 FROM tab2 AS cor0
----
-724
-7781
-7838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 col2 FROM tab1, tab2 cor0, tab0 AS cor1
----
-7
-78
-79

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1382
SELECT ALL + col2 * CAST( col1 AS SIGNED ) + col1 * col0 DIV + cor0.col2 + + col0 FROM tab1 AS cor0
----
1338
1408
645

skipif mysql # not compatible
query I rowsort label-1382
SELECT ALL + col2 * CAST ( col1 AS INTEGER ) + col1 * col0 / + cor0.col2 + + col0 FROM tab1 AS cor0
----
1338
1408
645

query I rowsort
SELECT DISTINCT - tab1.col1 + - 26 AS col0 FROM tab1
----
-36
-39
-52

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

query I rowsort
SELECT + tab1.col0 + + 75 * col1 + - col1 AS col0 FROM tab1
----
1042
1927
804

query I rowsort
SELECT + + col2 * + col0 - col1 * col0 * 3 AS col2 FROM tab2 AS cor0
----
-1027
-11778
-462

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

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

query I rowsort
SELECT DISTINCT + col0 * 5 + col0 AS col1 FROM tab0
----
144
210
534

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

query I rowsort
SELECT ALL col2 + + 49 AS col1 FROM tab1
----
103
106
145

query I rowsort
SELECT - 84 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

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

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

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

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

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

query I rowsort
SELECT - 4 * cor0.col0 AS col2 FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT ALL - 4 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

onlyif mysql # use DIV operator for integer division
query I rowsort label-1399
SELECT DISTINCT + 70 DIV col1 + 5 FROM tab0 cor0
----
5

skipif mysql # not compatible
query I rowsort label-1399
SELECT DISTINCT + 70 / col1 + 5 FROM tab0 cor0
----
5

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

query I rowsort
SELECT ALL - + 59 + col2 FROM tab2 AS cor0
----
-21
-32
-33

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

query I rowsort
SELECT DISTINCT - + 46 * col2 - + 2 FROM tab1 AS cor0
----
-2486
-2624
-4418

query I rowsort
SELECT ( 14 ) FROM tab0
----
14
14
14

query I rowsort
SELECT - + 98 AS col2 FROM tab2, tab0, tab0 AS cor0, tab1
----
81 values hashing to b6a3c9eea26c3759e6417d75f38258d1

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

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

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

query I rowsort
SELECT - 87 * + col0 AS col1 FROM tab1 AS cor0
----
-261
-5568
-6960

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

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

query I rowsort
SELECT 55 - col0 AS col2 FROM tab1 AS cor0
----
-25
-9
52

query I rowsort
SELECT + ( + 35 ) * col0 FROM tab0
----
1225
3115
840

query I rowsort
SELECT 7 + + tab0.col0 AS col1 FROM tab0
----
31
42
96

query I rowsort
SELECT DISTINCT ( - col2 ) + col1 * - ( + col1 ) * - tab2.col1 FROM tab2
----
205353
29764
4875

onlyif mysql # use DIV operator for integer division
query I rowsort label-1416
SELECT DISTINCT - CAST( 29 AS SIGNED ) * col2 DIV + ( ( - col1 ) * col0 ) + + col0 + tab0.col1 FROM tab0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-1416
SELECT DISTINCT - CAST ( 29 AS INTEGER ) * col2 / + ( ( - col1 ) * col0 ) + + col0 + tab0.col1 FROM tab0
----
110
132
180

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

skipif mysql # not compatible
query I rowsort label-1417
SELECT ALL - ( + tab0.col0 ) + + col0 + col1 / col0 AS col0 FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT 53 + + col2 * - col0 + tab1.col1 FROM tab1
----
-3585
-7614
-83

query I rowsort
SELECT 22 * col0 * - col2 - 75 * + col2 AS col1 FROM tab2 cor0
----
-46566
-6183
-68894

query I rowsort
SELECT + + 63 * col0 AS col1 FROM tab1 cor0
----
189
4032
5040

query I rowsort
SELECT DISTINCT + col0 + 61 + + col1 FROM tab1 AS cor0
----
135
154
90

query I rowsort
SELECT DISTINCT + col2 * + ( 57 ) AS col0 FROM tab0 AS cor0
----
1881
4674
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1423
SELECT + - col2 + CAST( 70 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-26
13
16

skipif mysql # not compatible
query I rowsort label-1423
SELECT + - col2 + CAST ( 70 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-26
13
16

query I rowsort
SELECT DISTINCT - col0 * - 59 FROM tab2 AS cor0
----
413
4602
4661

query I rowsort
SELECT DISTINCT col2 * - ( col1 ) + + col2 + + 26 AS col2 FROM tab0 AS cor0
----
-2779
-70
-7354

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 col2 FROM tab0
----
110
132
180

query I rowsort
SELECT - - col2 * col1 + 25 AS col0 FROM tab2 AS cor0
----
1559
671
862

query I rowsort
SELECT + col2 * - 3 AS col1 FROM tab1 AS cor0
----
-162
-171
-288

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

query I rowsort
SELECT DISTINCT + col0 * + 30 FROM tab1
----
1920
2400
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1433
SELECT DISTINCT ( ( + tab1.col0 ) ) + 94 + + 45 DIV tab1.col2 FROM tab1, tab0 AS cor0
----
158
174
97

skipif mysql # not compatible
query I rowsort label-1433
SELECT DISTINCT ( ( + tab1.col0 ) ) + 94 + + 45 / tab1.col2 FROM tab1, tab0 AS cor0
----
158
174
97

query I rowsort
SELECT + - 47 * - col2 FROM tab2 AS cor0
----
1222
1269
1786

query I rowsort
SELECT + col2 * - 99 AS col2 FROM tab0 cor0
----
-3267
-8118
-99

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

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

query I rowsort
SELECT DISTINCT - - 83 + 55 FROM tab2 AS cor0
----
138

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

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

query I rowsort
SELECT - col2 * 5 AS col2 FROM tab1 AS cor0
----
-270
-285
-480

query I rowsort
SELECT - col1 * + ( - 84 ) * col0 AS col0 FROM tab1
----
53760
6552
87360

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

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

query I rowsort
SELECT - 10 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT + 73 * cor0.col2 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to fd5ac40d47629e37ab1adbd7df3c7291

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

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

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

query I rowsort
SELECT 75 * col0 AS col0 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT + 15 FROM tab1, tab2, tab1 AS cor0, tab0
----
15

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1450
SELECT col0 DIV col0 col1 FROM tab2
----
1
1
1

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

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

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

query I rowsort
SELECT DISTINCT ( + 5 ) * + col0 - + ( + col0 ) FROM tab1
----
12
256
320

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

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

query I rowsort
SELECT + tab0.col2 * col0 + + tab0.col0 - + 82 AS col0 FROM tab0
----
-12
7305
734

query I rowsort
SELECT ALL 29 * col2 + 0 AS col0 FROM tab0
----
2378
29
957

onlyif mysql # use DIV operator for integer division
query I rowsort label-1456
SELECT ALL col0 DIV col0 + 22 + - col1 * col0 FROM tab0
----
-2041
-3372
-8076

skipif mysql # not compatible
query I rowsort label-1456
SELECT ALL col0 / col0 + 22 + - col1 * col0 FROM tab0
----
-2041
-3372
-8076

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

query I rowsort
SELECT ALL 18 + - col0 AS col2 FROM tab1
----
-46
-62
15

query I rowsort
SELECT - 52 * col1 AS col2 FROM tab1 AS cor0
----
-1352
-520
-676

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1461
SELECT DISTINCT col1 DIV + cor0.col2 + + 26 FROM tab0 cor0
----
123
27
28

skipif mysql # not compatible
query I rowsort label-1461
SELECT DISTINCT col1 / + cor0.col2 + + 26 FROM tab0 cor0
----
123
27
28

query I rowsort
SELECT ALL + + 37 * - col1 FROM tab1 AS cor0
----
-370
-481
-962

query I rowsort
SELECT col0 + 71 FROM tab2
----
149
150
78

query I rowsort
SELECT col2 * - 55 + + ( + col0 ) AS col2 FROM tab2
----
-1352
-1478
-2011

query I rowsort
SELECT + - col0 * 69 FROM tab0 AS cor0
----
-1656
-2415
-6141

query I rowsort
SELECT cor0.col0 AS col2 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

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

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

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

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

query I rowsort
SELECT + 22 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1804
22
726

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

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

query I rowsort
SELECT - ( - 19 ) AS col2 FROM tab1 AS cor0
----
19
19
19

query I rowsort
SELECT DISTINCT + 73 AS col2 FROM tab2 AS cor0
----
73

query I rowsort
SELECT ALL + - col2 * 67 FROM tab0 AS cor0
----
-2211
-5494
-67

query I rowsort
SELECT DISTINCT + 33 + + col1 AS col2 FROM tab0 cor0
----
119
124
130

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1480
SELECT ALL - CAST( - 67 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
1742
1809
2546

skipif mysql # not compatible
query I rowsort label-1480
SELECT ALL - CAST ( - 67 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
1742
1809
2546

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1481
SELECT DISTINCT + CAST( col2 AS SIGNED ) + col0 * - 88 + cor0.col0 * cor0.col1 FROM tab1 AS cor0
----
-132
-4935
-5904

skipif mysql # not compatible
query I rowsort label-1481
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + col0 * - 88 + cor0.col0 * cor0.col1 FROM tab1 AS cor0
----
-132
-4935
-5904

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col2 AS REAL ) + - cor0.col0 FROM tab2 AS cor0
----
-41
-52
20

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * + col0 * - col2 col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 + - col2 col1 FROM tab1 AS cor0
----
-7
32
35

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1490
SELECT ALL + col1 * + col0 + - col1 DIV + col1 AS col1 FROM tab2 cor0
----
1342
216
4601

skipif mysql # not compatible
query I rowsort label-1490
SELECT ALL + col1 * + col0 + - col1 / + col1 AS col1 FROM tab2 cor0
----
1342
216
4601

onlyif mysql # use DIV operator for integer division
query I rowsort label-1491
SELECT ALL + col0 + col1 * - col2 + col1 DIV + ( col1 ) FROM tab0 AS cor0
----
-2813
-61
-7372

skipif mysql # not compatible
query I rowsort label-1491
SELECT ALL + col0 + col1 * - col2 + col1 / + ( col1 ) FROM tab0 AS cor0
----
-2813
-61
-7372

onlyif mysql # use DIV operator for integer division
query I rowsort label-1492
SELECT ALL - + col2 DIV - col0 + + col0 FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-1492
SELECT ALL - + col2 / - col0 + + col0 FROM tab2 AS cor0
----
10
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * 83 - col0 col2 FROM tab1 AS cor0
----
4479
4667
7888

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

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

query I rowsort
SELECT + + col0 + - col1 * + 88 AS col0 FROM tab1 cor0
----
-1064
-2285
-816

query I rowsort
SELECT - + col1 * ( + col2 ) + col1 * col0 + - col0 FROM tab0 AS cor0
----
-798
3263
548

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - ( 29 ) * + col0 col1 FROM tab1 AS cor0
----
105792
222720
4698

onlyif mysql # use DIV operator for integer division
query I rowsort label-1500
SELECT ALL + - col0 * col1 DIV col0 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-1500
SELECT ALL + - col0 * col1 / col0 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 col2 FROM tab2
----
118
34
62

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

query I rowsort
SELECT col0 + col0 * col0 AS col2 FROM tab1
----
12
4160
6480

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( + col1 ) + + col0 AS col2 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - - col0 + 71 FROM tab0 AS cor0
----
106
160
95

query I rowsort
SELECT + col1 + 24 FROM tab0 AS cor0
----
110
115
121

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

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

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

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

query I rowsort
SELECT ALL - cor0.col1 + 28 + - 6 AS col0 FROM tab2 AS cor0
----
-37
-9
5

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

query I rowsort
SELECT ALL - col1 * + col2 + col2 + col1 AS col0 FROM tab1 AS cor0
----
-1139
-1324
-503

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) col2 FROM tab2
----
7
78
79

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + col2 * + col1 + - 42 FROM tab2 AS cor0
----
1492
604
795

query I rowsort
SELECT - - col1 * - 75 AS col2 FROM tab0 AS cor0
----
-6450
-6825
-7275

query I rowsort
SELECT DISTINCT + cor0.col2 + 65 + col0 * col1 FROM tab2 AS cor0
----
1446
309
4693

query I rowsort
SELECT DISTINCT - + col1 - - col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col2 * - 52 AS col0 FROM tab1 AS cor0
----
-2808
-2964
-4992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 48 col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * + 40 col1 FROM tab1 cor0
----
120
2560
3200

query I rowsort
SELECT + col1 * + 28 AS col0 FROM tab0 AS cor0
----
2408
2548
2716

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 33 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT DISTINCT + - ( + col1 ) * - col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1526
SELECT ALL - CAST( - 4 AS SIGNED ) * col1 AS col2 FROM tab0 AS cor0
----
344
364
388

skipif mysql # not compatible
query I rowsort label-1526
SELECT ALL - CAST ( - 4 AS INTEGER ) * col1 AS col2 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT ALL col1 * + col0 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - ( col1 ) + + col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 * - cor0.col0 * col2 + + col2 * col0 AS col2 FROM tab0 AS cor0
----
1260
19800
656820

query I rowsort
SELECT ALL col2 * col2 + - col2 * col1 FROM tab2 AS cor0
----
-108
-858
798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1531
SELECT ALL - - CAST( NULL AS SIGNED ) * - cor0.col0 + - cor0.col2 + + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1531
SELECT ALL - - CAST ( NULL AS INTEGER ) * - cor0.col0 + - cor0.col2 + + col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1533
SELECT ALL - col0 * - col1 + CAST( NULL AS SIGNED ) * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1533
SELECT ALL - col0 * - col1 + CAST ( NULL AS INTEGER ) * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1534
SELECT - ( + col0 ) + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1534
SELECT - ( + col0 ) + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1535
SELECT col1 * col2 DIV - col0 + + col1 FROM tab1 AS cor0
----
-2
-442
2

skipif mysql # not compatible
query I rowsort label-1535
SELECT col1 * col2 / - col0 + + col1 FROM tab1 AS cor0
----
-2
-442
2

query I rowsort
SELECT DISTINCT + tab0.col1 + tab0.col1 * - col2 * + col0 FROM tab0
----
-3298
-664027
-68026

query I rowsort
SELECT 70 * + col0 + + ( + 37 * + col2 ) FROM tab2 AS cor0
----
1489
6422
6936

query I rowsort
SELECT DISTINCT + - cor0.col0 + col0 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - col2 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT + 55 * + col1 + - col1 FROM tab1 AS cor0
----
1404
540
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-1541
SELECT col2 DIV col0 + - col1 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-1541
SELECT col2 / col0 + - col1 FROM tab2 AS cor0
----
-17
-28
-59

query I rowsort
SELECT DISTINCT col0 + ( - col1 ) * - col2 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT ALL 60 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT col1 * col1 + - 8 AS col0 FROM tab2 AS cor0
----
281
3473
953

query I rowsort
SELECT + ( - 48 ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT - cor0.col0 + - 13 AS col0 FROM tab1 AS cor0
----
-16
-77
-93

query I rowsort
SELECT - cor0.col2 + - 76 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 54ead02ce882a3756fd9def1c366ce1e

query I rowsort
SELECT 19 + col1 * - col2 FROM tab2 AS cor0
----
-1515
-627
-818

query I rowsort
SELECT 11 + col1 FROM tab0 AS cor0
----
102
108
97

query I rowsort
SELECT + + ( cor1.col0 ) * 81 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ddde7d51e284856e0cecc596b775720b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1551
SELECT ALL col1 DIV col1 + col2 * col2 FROM tab0
----
1090
2
6725

skipif mysql # not compatible
query I rowsort label-1551
SELECT ALL col1 / col1 + col2 * col2 FROM tab0
----
1090
2
6725

query I rowsort
SELECT ALL + 82 FROM tab1, tab2 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT DISTINCT - ( + tab0.col0 * + tab0.col2 ) AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - - col2 * col2 + - col0 FROM tab0 AS cor0
----
-34
1065
6635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col2 ) col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + 54 * + 81 AS col1 FROM tab1
----
4374
4374
4374

query I rowsort
SELECT ALL col1 * col1 * - 71 + + col2 FROM tab0 AS cor0
----
-525083
-587869
-668038

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1558
SELECT DISTINCT col0 + CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1558
SELECT DISTINCT col0 + CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1559
SELECT + + col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1559
SELECT + + col2 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1560
SELECT DISTINCT cor0.col1 DIV col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1560
SELECT DISTINCT cor0.col1 / col0 AS col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT col0 * cor0.col1 + 16 * col0 FROM tab2 AS cor0
----
2607
329
5850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 - - tab2.col1 * - 73 col2 FROM tab2
----
-1225
-2247
-4291

query I rowsort
SELECT DISTINCT - col2 + col2 * - col2 + + col1 * - col2 FROM tab0 AS cor0
----
-14268
-3960
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-1564
SELECT DISTINCT + col0 + ( - col0 ) DIV + col2 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-1564
SELECT DISTINCT + col0 + ( - col0 ) / + col2 FROM tab1 AS cor0
----
3
63
80

query I rowsort
SELECT DISTINCT col1 * + 49 + - cor0.col1 AS col2 FROM tab2 cor0
----
1488
2832
816

query I rowsort
SELECT DISTINCT - col2 * - col0 + + col2 * + col2 FROM tab0 AS cor0
----
14022
1881
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col2 + col0 col2 FROM tab2
----
130
155
61

query I rowsort
SELECT DISTINCT col2 - + 32 * - col2 * col1 AS col1 FROM tab1
----
18297
40032
44982

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 + - col0 - - col1 * - col2 col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + + col0 * ( + col2 * col2 ) AS col1 FROM tab2 AS cor0
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-1571
SELECT DISTINCT col2 DIV - 77 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-1571
SELECT DISTINCT col2 / - 77 FROM tab1
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1572
SELECT DISTINCT - col2 * col0 DIV + cor0.col0 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-1572
SELECT DISTINCT - col2 * col0 / + cor0.col0 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - - col2 + col0 + - 2 * + 92 FROM tab1 cor0
----
-127
-63
-8

query I rowsort
SELECT tab2.col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1575
SELECT ALL CAST( 46 AS SIGNED ) AS col2 FROM tab2
----
46
46
46

skipif mysql # not compatible
query I rowsort label-1575
SELECT ALL CAST ( 46 AS INTEGER ) AS col2 FROM tab2
----
46
46
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-1576
SELECT ALL col2 - col1 * + CAST( - col1 AS SIGNED ) DIV col1 AS col0 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1576
SELECT ALL col2 - col1 * + CAST ( - col1 AS INTEGER ) / col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + 5 + cor0.col2 AS col2 FROM tab1 AS cor0
----
101
59
62

query I rowsort
SELECT DISTINCT - col0 - - col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL 51 * - col0 AS col0 FROM tab1 AS cor0
----
-153
-3264
-4080

query I rowsort
SELECT col0 * col0 - - col1 FROM tab0
----
1322
662
8012

query I rowsort
SELECT 95 * + col1 - col2 FROM tab0
----
8137
8563
9214

query I rowsort
SELECT ALL col0 + + ( - col1 * col0 ) AS col1 FROM tab1
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 27 col0 FROM tab2
----
-27
-27
-27

query I rowsort
SELECT + 56 + + col1 * - col2 AS col1 FROM tab0
----
-2782
-41
-7406

query I rowsort
SELECT - + 32 AS col0 FROM tab1 cor0
----
-32
-32
-32

query I rowsort
SELECT ALL 0 * col2 - + 31 AS col0 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT DISTINCT - - 39 + cor0.col2 * - 5 FROM tab1 AS cor0
----
-231
-246
-441

query I rowsort
SELECT ALL - col1 * col0 + - 52 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1433
-296
-4680

query I rowsort
SELECT - - col0 * col1 + col1 FROM tab0 cor0
----
2150
3492
8190

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NOT ( NULL ) < + col0 - col1 ) AND NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT col2 + - col1 * - col2 AS col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL + - col0 * cor0.col1 - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT - + col2 * - cor0.col2 + + col2 * - col1 FROM tab1 cor0
----
1512
2679
7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-1594
SELECT DISTINCT + col0 - col2 DIV - col1 AS col0 FROM tab2 cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-1594
SELECT DISTINCT + col0 - col2 / - col1 AS col0 FROM tab2 cor0
----
7
78
81

query I rowsort
SELECT - ( - ( tab1.col2 ) ) AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT + 37 * - 71 + col1 * tab0.col2 + - col1 FROM tab0
----
-2627
125
4744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 43 + col1 + - col0 col1 FROM tab1
----
-11
-24
66

query I rowsort
SELECT - 42 * + col1 FROM tab0
----
-3612
-3822
-4074

query I rowsort
SELECT - col2 + 86 + + col2 FROM tab0 AS cor0
----
86
86
86

query I rowsort
SELECT ALL + 82 * + 48 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
102336
39360
51168

query I rowsort
SELECT - - 37 * col0 FROM tab0 AS cor0
----
1295
3293
888

query I rowsort
SELECT DISTINCT + + ( 56 ) * - col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-1960
-408688
-44352

query I rowsort
SELECT - + col2 * + col1 + + col2 * col0 + + col1 * cor0.col1 FROM tab0 AS cor0
----
5350
8117
9347

query I rowsort
SELECT ALL + + cor0.col0 * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT - + col1 + + col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - - 13 * col2 + col0 + - cor0.col0 FROM tab2 AS cor0
----
338
351
494

query I rowsort
SELECT ALL + 34 * - col2 FROM tab0 AS cor0
----
-1122
-2788
-34

query I rowsort
SELECT DISTINCT - - 45 * col2 FROM tab0 AS cor0
----
1485
3690
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 84 col2 FROM tab2 AS cor0
----
84
84
84

query I rowsort
SELECT DISTINCT col0 + + 31 * col0 FROM tab2
----
224
2496
2528

query I rowsort
SELECT DISTINCT col1 * 65 + col1 + - col0 AS col0 FROM tab1
----
1713
596
778

query I rowsort
SELECT 62 - col2 FROM tab2
----
24
35
36

query I rowsort
SELECT + col2 * + 12 + col2 FROM tab2 AS cor0
----
338
351
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 col2 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + cor0.col0 + - col2 * + col1 AS col1 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + 44 AS col2 FROM tab2
----
44
44
44

query I rowsort
SELECT 56 * - col1 FROM tab2 AS cor0
----
-1736
-3304
-952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1618
SELECT - col0 + - col0 * + CAST( NULL AS SIGNED ) + - col2 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1618
SELECT - col0 + - col0 * + CAST ( NULL AS INTEGER ) + - col2 AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1619
SELECT + col1 DIV - tab0.col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-1619
SELECT + col1 / - tab0.col2 FROM tab0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 83 + + col1 col1 FROM tab0
----
169
174
180

query I rowsort
SELECT - + col0 - - 51 AS col0 FROM tab2 AS cor0
----
-27
-28
44

query I rowsort
SELECT - - 96 FROM tab0, tab1, tab1 cor0
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT DISTINCT - tab0.col0 * + tab0.col1 * + 70 AS col2 FROM tab0
----
-144480
-237650
-566930

onlyif mysql # use DIV operator for integer division
query I rowsort label-1624
SELECT - col0 DIV + tab1.col1 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-1624
SELECT - col0 / + tab1.col1 FROM tab1
----
-6
-6
0

query I rowsort
SELECT ALL tab1.col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT 19 * col2 + + 31 FROM tab1
----
1057
1114
1855

query I rowsort
SELECT - ( col0 ) * ( col1 ) FROM tab2
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-1628
SELECT col0 * col0 DIV col1 AS col1 FROM tab2
----
1
103
367

skipif mysql # not compatible
query I rowsort label-1628
SELECT col0 * col0 / col1 AS col1 FROM tab2
----
1
103
367

query I rowsort
SELECT - cor0.col1 + + 12 AS col0 FROM tab2 AS cor0
----
-19
-47
-5

query I rowsort
SELECT DISTINCT - - cor0.col1 * + ( - 26 ) + cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
-1586
-2080
-830

query I rowsort
SELECT ALL 87 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1632
SELECT - col0 * - CAST( - ( col0 ) AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-1632
SELECT - col0 * - CAST ( - ( col0 ) AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + col2 + 7 AS col0 FROM tab2 AS cor0
----
33
34
45

query I rowsort
SELECT col2 + ( - 66 ) * + col2 FROM tab1 AS cor0
----
-3510
-3705
-6240

query I rowsort
SELECT + col1 * + 33 * + col1 + + col0 AS col1 FROM tab0 AS cor0
----
244092
273362
310532

query I rowsort
SELECT ALL - cor0.col2 * col0 + + 12 FROM tab2 AS cor0
----
-177
-2016
-2990

onlyif mysql # use DIV operator for integer division
query I rowsort label-1637
SELECT tab1.col1 DIV + 39 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1637
SELECT tab1.col1 / + 39 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - - col0 + ( col1 ) * col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT col0 - + ( - col1 ) AS col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1640
SELECT - col2 DIV - 70 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1640
SELECT - col2 / - 70 AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT - ( + 63 ) * col2 + - ( col2 ) + col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT - - ( 70 ) + col2 FROM tab1 AS cor0
----
124
127
166

query I rowsort
SELECT - col1 + - 44 FROM tab2 AS cor0
----
-103
-61
-75

query I rowsort
SELECT col0 + ( col2 ) * ( + cor0.col1 ) FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - - ( col2 ) * + col1 + + ( - col2 * col2 ) FROM tab0 AS cor0
----
1749
738
96

query I rowsort
SELECT - ( + ( - col1 ) ) + col2 * - col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT col1 + col2 * col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT tab1.col1 * + 87 FROM tab1
----
1131
2262
870

query I rowsort
SELECT ALL ( 63 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1650
SELECT ALL tab0.col0 * CAST( + col1 AS SIGNED ) FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-1650
SELECT ALL tab0.col0 * CAST ( + col1 AS INTEGER ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 91 + + col2 AS col1 FROM tab1 AS cor0
----
145
148
187

query I rowsort
SELECT - - 69 + col0 AS col2 FROM tab0 AS cor0
----
104
158
93

query I rowsort
SELECT ALL + 18 + ( - col2 ) FROM tab1 AS cor0
----
-36
-39
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1654
SELECT DISTINCT CAST( NULL AS SIGNED ) - ( - cor0.col1 ) col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1654
SELECT DISTINCT CAST ( NULL AS INTEGER ) - ( - cor0.col1 ) col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - - 18 * col1 - col1 AS col2 FROM tab2 AS cor0
----
1003
289
527

query I rowsort
SELECT DISTINCT - + cor0.col2 + - col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT - ( 69 ) * + cor0.col1 + + ( 40 + col0 ) AS col0 FROM tab1 AS cor0
----
-1751
-586
-777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - 27 * - col2 col1 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT + - col2 * col1 * cor0.col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT + col0 * col2 * 65 FROM tab1 cor0
----
10530
237120
499200

query I rowsort
SELECT 57 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1881
-4674
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1662
SELECT col0 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1662
SELECT col0 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col0 * - col2 * - 51 AS col0 FROM tab2 cor0
----
-103428
-153102
-9639

onlyif mysql # use DIV operator for integer division
query I rowsort label-1664
SELECT + col1 + - cor0.col0 DIV 89 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1664
SELECT + col1 + - cor0.col0 / 89 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - tab0.col2 FROM tab0, tab0 cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT + + 30 + col1 * ( + col1 ) AS col0 FROM tab1 AS cor0
----
130
199
706

query I rowsort
SELECT tab0.col0 + + col2 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL + 79 * - col2 + col1 AS col2 FROM tab0 AS cor0
----
-2521
-6387
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-1669
SELECT + col2 + cor0.col2 DIV col0 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-1669
SELECT + col2 + cor0.col2 / col0 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT - col2 * - col0 * cor0.col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL col2 * + col1 + + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + - ( + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col2 * col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-1674
SELECT col0 * - col2 DIV + col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1674
SELECT col0 * - col2 / + col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL 61 * + col2 + 5 FROM tab2 AS cor0
----
1591
1652
2323

query I rowsort
SELECT ALL + + col0 * + ( col0 ) FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1677
SELECT DISTINCT + col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1677
SELECT DISTINCT + col2 / col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col0 * 21 FROM tab0 AS cor0
----
1869
504
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-1679
SELECT - col2 DIV 97 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1679
SELECT - col2 / 97 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1680
SELECT DISTINCT - col2 * CAST( - 82 AS SIGNED ) + col1 FROM tab2 AS cor0
----
2191
2245
3133

skipif mysql # not compatible
query I rowsort label-1680
SELECT DISTINCT - col2 * CAST ( - 82 AS INTEGER ) + col1 FROM tab2 AS cor0
----
2191
2245
3133

query I rowsort
SELECT DISTINCT col0 * col1 * col0 AS col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT 14 AS col1 FROM tab0
----
14
14
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1684
SELECT + ( cor0.col1 ) DIV col1 + cor0.col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-1684
SELECT + ( cor0.col1 ) / col1 + cor0.col2 FROM tab2 AS cor0
----
27
28
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * + 38 + - col0 * ( col0 ) col2 FROM tab0 AS cor0
----
-1187
-4805
678

query I rowsort
SELECT DISTINCT 73 + - col1 FROM tab2 cor0
----
14
42
56

query I rowsort
SELECT DISTINCT - 52 * + 26 AS col2 FROM tab1 AS cor0
----
-1352

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col1 col2 FROM tab0 cor0
----
0

query I rowsort
SELECT - col1 * + 10 + + col0 FROM tab1 AS cor0
----
-257
-36
-50

query I rowsort
SELECT - 34 + - col1 AS col1 FROM tab2 AS cor0
----
-51
-65
-93

query I rowsort
SELECT ALL 19 + col0 FROM tab2 AS cor0
----
26
97
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1692
SELECT ALL - 11 DIV - cor1.col1 AS col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-1692
SELECT ALL - 11 / - cor1.col1 AS col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col0 + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL 33 FROM tab2, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT DISTINCT + 99 + 65 FROM tab0
----
164

query I rowsort
SELECT ALL + 4 * col2 AS col2 FROM tab2 cor0
----
104
108
152

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 + - col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL - 5 + cor0.col0 AS col0 FROM tab2 cor0
----
2
73
74

query I rowsort
SELECT col0 * 41 AS col1 FROM tab1
----
123
2624
3280

query I rowsort
SELECT - 9 - col0 FROM tab2
----
-16
-87
-88

query I rowsort
SELECT ALL + col0 * col1 + col0 FROM tab2
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + tab0.col2 col0 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1703
SELECT + ( col2 ) DIV col0 + + col0 FROM tab2
----
10
78
79

skipif mysql # not compatible
query I rowsort label-1703
SELECT + ( col2 ) / col0 + + col0 FROM tab2
----
10
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 * - 13 col1 FROM tab0
----
754
754
754

query I rowsort
SELECT 80 * 90 FROM tab0
----
7200
7200
7200

query I rowsort
SELECT + + ( - col1 ) + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL + - 43 * col2 FROM tab0 AS cor0
----
-1419
-3526
-43

query I rowsort
SELECT DISTINCT - col1 * + col1 + + 87 FROM tab2 AS cor0
----
-202
-3394
-874

query I rowsort
SELECT - col1 * - col1 + - 94 AS col2 FROM tab2 AS cor0
----
195
3387
867

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1710
SELECT ALL CAST( ( col1 ) AS SIGNED ) + ( - 53 ) FROM tab1
----
-27
-40
-43

skipif mysql # not compatible
query I rowsort label-1710
SELECT ALL CAST ( ( col1 ) AS INTEGER ) + ( - 53 ) FROM tab1
----
-27
-40
-43

query I rowsort
SELECT ALL 16 + + tab0.col1 * col2 * 5 AS col1 FROM tab0
----
14206
37326
501

query I rowsort
SELECT ALL 58 * col2 AS col2 FROM tab2
----
1508
1566
2204

query I rowsort
SELECT DISTINCT - 67 * col1 AS col1 FROM tab2 AS cor0
----
-1139
-2077
-3953

query I rowsort
SELECT ALL col0 + col2 * - col0 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - + col2 + + col0 + col1 FROM tab1 AS cor0
----
-25
-3
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1716
SELECT ALL + 44 * + col1 + CAST( NULL AS SIGNED ) * cor0.col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1716
SELECT ALL + 44 * + col1 + CAST ( NULL AS INTEGER ) * cor0.col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col0 + - col2 + - col1 * ( col1 ) AS col2 FROM tab2 AS cor0
----
-248
-3429
-981

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + - col0 col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - + col1 + - col2 * + col1 AS col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT - tab0.col1 + + col1 * + ( col0 ) AS col0 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT - col2 + 11 FROM tab2
----
-15
-16
-27

query I rowsort
SELECT ALL - col0 * ( - col1 * col0 ) FROM tab1
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * cor0.col2 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - - col1 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-272
-3422
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-1725
SELECT col2 + - col0 DIV + tab0.col0 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-1725
SELECT col2 + - col0 / + tab0.col0 FROM tab0
----
0
32
81

query I rowsort
SELECT DISTINCT + 10 AS col1 FROM tab0 AS cor0
----
10

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1727
SELECT - CAST( NULL AS SIGNED ) - - 16 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1727
SELECT - CAST ( NULL AS INTEGER ) - - 16 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + col0 * col0 FROM tab0 AS cor0
----
1224
543
7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-1729
SELECT DISTINCT + col0 - cor0.col0 DIV col1 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1729
SELECT DISTINCT + col0 - cor0.col0 / col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL + col0 * + 42 AS col2 FROM tab1 AS cor0
----
126
2688
3360

query I rowsort
SELECT 85 - + 42 FROM tab0 AS cor0
----
43
43
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1732
SELECT DISTINCT + - col2 * col0 + col2 * CAST( col1 + + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-2508
-5184
2646

skipif mysql # not compatible
query I rowsort label-1732
SELECT DISTINCT + - col2 * col0 + col2 * CAST ( col1 + + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-2508
-5184
2646

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1733
SELECT CAST( NULL AS SIGNED ) * col0 + col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1733
SELECT CAST ( NULL AS INTEGER ) * col0 + col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - + 17 + - col0 AS col2 FROM tab0 AS cor0
----
-106
-41
-52

query I rowsort
SELECT col2 + 91 AS col1 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT ALL - col1 * - ( + 48 ) * - col2 FROM tab0
----
-136224
-358176
-4656

query I rowsort
SELECT + ( cor0.col2 ) * - col0 + 57 * col2 FROM tab1 cor0
----
-2208
-399
2916

query I rowsort
SELECT ALL - col1 + - col2 * + col0 FROM tab2 cor0
----
-2087
-220
-3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-1740
SELECT ALL ( col1 ) DIV col1 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1740
SELECT ALL ( col1 ) / col1 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT ALL - + 33 DIV col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1741
SELECT ALL - + 33 / col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT col1 * + 86 - col0 * col0 AS col2 FROM tab2 AS cor0
----
-1010
-4779
2617

query I rowsort
SELECT ALL - col0 - 67 AS col0 FROM tab1 AS cor0
----
-131
-147
-70

query I rowsort
SELECT DISTINCT + 66 AS col1 FROM tab0 AS cor0
----
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-1745
SELECT 65 + - col0 DIV - col2 FROM tab1 AS cor0
----
65
65
66

skipif mysql # not compatible
query I rowsort label-1745
SELECT 65 + - col0 / - col2 FROM tab1 AS cor0
----
65
65
66

query I rowsort
SELECT ALL col0 * + cor0.col0 AS col1 FROM tab1 AS cor0 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT - col2 + col2 * col0 AS col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT + col2 + + col1 + col0 * cor0.col0 FROM tab0 AS cor0
----
1323
695
8094

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col2 * col0 + col2 * col0 col1 FROM tab2
----
1512
160212
240160

query I rowsort
SELECT + col1 AS col1 FROM tab1 WHERE NULL < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1751
SELECT DISTINCT col1 - col2 DIV col0 FROM tab1
----
10
12
8

skipif mysql # not compatible
query I rowsort label-1751
SELECT DISTINCT col1 - col2 / col0 FROM tab1
----
10
12
8

query I rowsort
SELECT + col0 + + col1 AS col0 FROM tab2 AS cor0 WHERE ( NULL ) NOT BETWEEN col2 AND NULL
----

query I rowsort
SELECT - col0 * col1 * col2 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 col0 FROM tab2 AS cor0 WHERE ( NULL ) IN ( col0 )
----

query I rowsort
SELECT col1 * + col0 - col2 FROM tab2
----
1305
190
4576

query I rowsort
SELECT DISTINCT col1 * + col1 + - col0 * col2 * col0 FROM tab0
----
-11612
-641241
8184

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 col0 FROM tab0 WHERE NULL >= NULL
----

query I rowsort
SELECT DISTINCT - col0 * + col0 + + tab0.col0 AS col1 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT col0 - col2 * - col2 AS col1 FROM tab2
----
1523
736
754

query I rowsort
SELECT - col0 * col2 + col2 * col2 FROM tab1 WHERE NOT NULL < ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL IN ( + col1 )
----

query I rowsort
SELECT ALL tab0.col2 + tab0.col0 AS col1 FROM tab0
----
171
36
57

query III rowsort
SELECT ALL * FROM tab1 WHERE col2 / col1 IN ( col1 )
----

query I rowsort
SELECT - tab1.col1 * + col0 + + col1 AS col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col0 * col0 + - tab1.col2 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT - col0 * + tab2.col0 + col1 AS col0 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT col0 + tab0.col0 AS col1 FROM tab0 WHERE NOT - col1 * col2 NOT IN ( - col0 * - col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col0 IN ( - col1 - + col2 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL NOT BETWEEN col0 AND ( tab1.col2 * col0 / col2 )
----

query I rowsort
SELECT ALL + cor0.col2 * col0 + col2 * + col2 FROM tab1 AS cor0 WHERE NOT NULL IN ( col0 * col1 ) OR ( + col1 ) > - col2 * + col0 / col2
----
16896
3078
6897

query I rowsort
SELECT DISTINCT + cor0.col0 + + cor0.col1 FROM tab2, tab1, tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-1772
SELECT DISTINCT - col1 DIV + col1 + - col0 col0 FROM tab2
----
-79
-8
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1772
SELECT DISTINCT - col1 / + col1 + - col0 col0 FROM tab2
----
-79
-8
-80

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) NOT IN ( tab0.col2 + + col1 - col1 )
----

query I rowsort
SELECT DISTINCT + col0 * + col1 + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL + col1 + - col2 * col2 + + col2 FROM tab0 AS cor0
----
-6551
-970
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 * + col2 col1 FROM tab1 AS cor0
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - cor0.col2 - col0 col2 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-1778
SELECT DISTINCT + + col0 * + col1 + col1 + col2 DIV cor0.col1 FROM tab2 AS cor0
----
1362
248
4661

skipif mysql # not compatible
query I rowsort label-1778
SELECT DISTINCT + + col0 * + col1 + col1 + col2 / cor0.col1 FROM tab2 AS cor0
----
1362
248
4661

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - 16 AS col2 FROM tab2
----
-16
-16
-16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 11 col0 FROM tab0 AS cor0
----
-1001
-1067
-946

query I rowsort
SELECT ALL col2 + - 20 AS col0 FROM tab0 cor0
----
-19
13
62

query I rowsort
SELECT ALL + cor0.col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - - col0 * + 45 AS col2 FROM tab0 AS cor0
----
1080
1575
4005

query I rowsort
SELECT ALL col2 * - tab0.col0 AS col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL ( - col0 * - col0 ) AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL - 93 AS col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to ea79c61f7a02d25805171f5e85229fba

query I rowsort
SELECT ALL - 26 AS col0 FROM tab1
----
-26
-26
-26

query I rowsort
SELECT DISTINCT col1 - - 29 AS col0 FROM tab1
----
39
42
55

query I rowsort
SELECT + + col1 + 30 * cor0.col2 FROM tab2 AS cor0
----
1157
839
841

query I rowsort
SELECT + - col0 * + 5 FROM tab1 AS cor0
----
-15
-320
-400

query I rowsort
SELECT + + col1 * 94 * - col1 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-15873
-63518
-9390

onlyif mysql # use DIV operator for integer division
query I rowsort label-1793
SELECT cor0.col1 DIV + 58 + + 76 FROM tab2 AS cor0
----
76
76
77

skipif mysql # not compatible
query I rowsort label-1793
SELECT cor0.col1 / + 58 + + 76 FROM tab2 AS cor0
----
76
76
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 col0 FROM tab0 WHERE NOT + tab0.col0 NOT BETWEEN ( tab0.col2 * + col1 ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col2 col1 FROM tab1 WHERE + col1 IN ( tab1.col2 * col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 col1 FROM tab0
----
178
48
70

query I rowsort
SELECT col0 * col0 FROM tab0 WHERE + col2 * + col2 + col2 IN ( col1 )
----

query I rowsort
SELECT ALL + col0 * - col2 * - col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT tab1.col2 * col0 * col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT - col1 * col1 AS col2 FROM tab0 WHERE NOT NULL IN ( tab0.col0 )
----

query I rowsort
SELECT + col0 * - cor0.col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + + 32 + + 7 AS col0 FROM tab1, tab1 AS cor0
----
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 21 + + cor0.col2 * ( col2 ) * + col0 col0 FROM tab0 AS cor0
----
26157
56
598457

query I rowsort
SELECT ALL + col0 + col0 * col0 AS col1 FROM tab1
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - tab2.col0 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - cor0.col0 * cor0.col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col2 + - col0 + col0 AS col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT + col1 * - tab1.col1 AS col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - col1 + - ( + tab2.col0 ) * + col1 AS col2 FROM tab2
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-1810
SELECT CAST( + col1 AS SIGNED ) * col2 + cor0.col2 DIV + col1 AS col0 FROM tab1 AS cor0
----
1255
1406
575

skipif mysql # not compatible
query I rowsort label-1810
SELECT CAST ( + col1 AS INTEGER ) * col2 + cor0.col2 / + col1 AS col0 FROM tab1 AS cor0
----
1255
1406
575

query I rowsort
SELECT DISTINCT col1 * - col0 * - col0 AS col0 FROM tab2 cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + col1 + - col1 * col0 AS col0 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT col1 * ( + 77 * col2 ) + + 81 FROM tab1
----
108189
43971
96177

onlyif mysql # use DIV operator for integer division
query I rowsort label-1814
SELECT col0 DIV - ( - col0 ) AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1814
SELECT col0 / - ( - col0 ) AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT col0 * + col0 * - col1 FROM tab1
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-1816
SELECT DISTINCT + col0 DIV ( - col1 ) + - col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1816
SELECT DISTINCT + col0 / ( - col1 ) + - col1 FROM tab0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1817
SELECT col0 + col1 DIV tab2.col0 AS col1 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-1817
SELECT col0 + col1 / tab2.col0 AS col1 FROM tab2
----
11
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1818
SELECT - - CAST( NULL AS SIGNED ) + - 9 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1818
SELECT - - CAST ( NULL AS INTEGER ) + - 9 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + cor0.col0 col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - 30 + col1 * - col0 AS col2 FROM tab2 cor0
----
-1373
-247
-4632

query I rowsort
SELECT ALL - + col1 - col2 * col1 * col0 FROM tab0 AS cor0
----
-3492
-664209
-68198

query I rowsort
SELECT - - cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - - col1 + 95 + + col1 AS col1 FROM tab2 AS cor0
----
129
157
213

query I rowsort
SELECT DISTINCT - col0 + + 47 FROM tab0 AS cor0
----
-42
12
23

query I rowsort
SELECT + - ( + col2 ) + + cor0.col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - + cor0.col2 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-1827
SELECT - col1 DIV - col1 + col2 col0 FROM tab1 cor0
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1827
SELECT - col1 / - col1 + col2 col0 FROM tab1 cor0
----
55
58
97

query I rowsort
SELECT DISTINCT + col2 * - 22 + col1 FROM tab2 cor0
----
-513
-563
-819

query I rowsort
SELECT DISTINCT + col1 + + col0 + - col2 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT ALL - - col0 * + 16 - col1 AS col0 FROM tab0 AS cor0
----
1333
298
463

onlyif mysql # use DIV operator for integer division
query I rowsort label-1831
SELECT ALL - 90 DIV - col2 FROM tab0
----
1
2
90

skipif mysql # not compatible
query I rowsort label-1831
SELECT ALL - 90 / - col2 FROM tab0
----
1
2
90

query I rowsort
SELECT + + 13 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL - + 24 * + col1 AS col0 FROM tab1 cor0
----
-240
-312
-624

query I rowsort
SELECT DISTINCT 45 + col2 * - cor0.col2 AS col0 FROM tab1 cor0
----
-2871
-3204
-9171

query I rowsort
SELECT DISTINCT + 31 AS col1 FROM tab1 AS cor0
----
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-1836
SELECT col0 + + cor0.col1 * + col2 DIV + col2 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-1836
SELECT col0 + + cor0.col1 * + col2 / + col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT 64 * + col1 FROM tab2 AS cor0
----
1088
1984
3776

query I rowsort
SELECT ALL + col0 * col1 + col0 AS col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT cor0.col2 * - col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col2 * 86 * col2 + - col0 AS col2 FROM tab2 AS cor0
----
124105
58058
62687

onlyif mysql # use DIV operator for integer division
query I rowsort label-1841
SELECT - + col1 DIV - col0 AS col1 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-1841
SELECT - + col1 / - col0 AS col1 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT - cor0.col1 * + ( col2 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - - col0 + 78 * 71 AS col2 FROM tab2 AS cor0
----
5545
5616
5617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT + col0 * 89 - cor0.col2 * col1 * ( + 72 ) AS col1 FROM tab0 AS cor0
----
-202200
-3869
-529343

query I rowsort
SELECT ALL + cor0.col2 + + 41 * col2 AS col2 FROM tab2 cor0
----
1092
1134
1596

query I rowsort
SELECT col1 + 45 * + ( col2 ) * + 48 AS col2 FROM tab2 AS cor0
----
56219
58351
82097

query I rowsort
SELECT ALL col2 + 56 AS col0 FROM tab0 AS cor0
----
138
57
89

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 * 89 FROM tab1 AS cor0
----
270
5760
7200

query I rowsort
SELECT + + col2 * 17 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2277
-6068
-80

query I rowsort
SELECT ALL - col0 + - 25 FROM tab0 AS cor0
----
-114
-49
-60

query I rowsort
SELECT ALL + col1 * col1 + - col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT - col1 * - 50 + col2 * - cor0.col0 AS col2 FROM tab0 cor0
----
-2748
3508
4815

query I rowsort
SELECT ALL - 25 + - 73 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT ALL + - col1 + + col2 * 4 AS col2 FROM tab0 AS cor0
----
-93
237
46

query I rowsort
SELECT - col0 * - 71 FROM tab0 AS cor0
----
1704
2485
6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-1857
SELECT - col1 DIV 60 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1857
SELECT - col1 / 60 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - ( col2 + col1 ) col0 FROM tab1 AS cor0
----
10464
3819
4320

query I rowsort
SELECT - col2 + - 67 AS col0 FROM tab0 cor0
----
-100
-149
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * + ( - col2 + + cor0.col2 ) * col0 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col0 * cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
13824
42875
704969

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1862
SELECT + CAST( NULL AS DECIMAL ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1862
SELECT + CAST ( NULL AS REAL ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + + col1 * 36 AS col0 FROM tab1
----
303
372
882

onlyif mysql # use DIV operator for integer division
query I rowsort label-1864
SELECT + 82 DIV - ( cor0.col1 ) + + 57 + col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1590
699
892

skipif mysql # not compatible
query I rowsort label-1864
SELECT + 82 / - ( cor0.col1 ) + + 57 + col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
1590
699
892

query I rowsort
SELECT ( - col1 ) * cor0.col2 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT 86 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT - ( 95 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT ALL - col1 + col1 + + col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 29 * col0 - ( - ( cor0.col1 ) ) col1 FROM tab2 AS cor0
----
2308
2321
234

query I rowsort
SELECT ALL 8 * col2 + col1 FROM tab0 AS cor0
----
105
350
747

onlyif mysql # use DIV operator for integer division
query I rowsort label-1871
SELECT ALL - col1 + cor0.col1 DIV + col1 AS col1 FROM tab2 cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-1871
SELECT ALL - col1 + cor0.col1 / + col1 AS col1 FROM tab2 cor0
----
-16
-30
-58

query I rowsort
SELECT DISTINCT + col1 * + col0 + - ( + 61 * col1 ) + - col2 FROM tab0 AS cor0
----
-2523
-3215
2466

onlyif mysql # use DIV operator for integer division
query I rowsort label-1873
SELECT - - cor0.col0 DIV col0 col2 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1873
SELECT - - cor0.col0 / col0 col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + 66 AS col2 FROM tab1
----
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * tab2.col2 + col0 col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL 42 + - col2 * - 90 + col2 FROM tab2 cor0
----
2408
2499
3500

onlyif mysql # use DIV operator for integer division
query I rowsort label-1877
SELECT col1 DIV col2 + col2 * col2 FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-1877
SELECT col1 / col2 + col2 * col2 FROM tab1
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1878
SELECT ALL cor0.col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
243 values hashing to 76933ee8cce600e48802fbdea2376d45

skipif mysql # not compatible
query I rowsort label-1878
SELECT ALL cor0.col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
243 values hashing to 76933ee8cce600e48802fbdea2376d45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * tab2.col1 col2 FROM tab2
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1880
SELECT + + CAST( col0 AS SIGNED ) * col0 col0 FROM tab1 AS cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1880
SELECT + + CAST ( col0 AS INTEGER ) * col0 col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + - cor0.col0 * cor0.col1 + col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT 13 + col2 - 63 AS col1 FROM tab2
----
-12
-23
-24

query I rowsort
SELECT + cor0.col0 * + 59 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 87bed571573f5e33a11f2e1f74c6ca21

query I rowsort
SELECT - + 68 + - col0 AS col2 FROM tab2 AS cor0
----
-146
-147
-75

query I rowsort
SELECT ALL + - 66 * col2 + ( - 73 ) AS col0 FROM tab2 AS cor0
----
-1789
-1855
-2581

query I rowsort
SELECT + col1 * col2 + + 31 * + col0 FROM tab2 AS cor0
----
1054
3095
3952

query I rowsort
SELECT 53 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT 64 FROM tab0, tab1 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1889
SELECT ALL CAST( NULL AS SIGNED ) + + 5 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1889
SELECT ALL CAST ( NULL AS INTEGER ) + + 5 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col1 * + col1 + col2 AS col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + - col2 + 9 * cor0.col2 AS col2 FROM tab2 AS cor0
----
208
216
304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1892
SELECT + col0 * + CAST( + col0 AS SIGNED ) + - cor0.col2 AS col0 FROM tab2 AS cor0
----
22
6058
6203

skipif mysql # not compatible
query I rowsort label-1892
SELECT + col0 * + CAST ( + col0 AS INTEGER ) + - cor0.col2 AS col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT - cor0.col2 FROM tab1, tab2, tab2 cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT ALL + 41 + tab1.col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 27eb4b252911b8d0ad0e6ed9cfd65b13

onlyif mysql # use DIV operator for integer division
query I rowsort label-1895
SELECT DISTINCT + tab1.col2 DIV + ( col2 ) AS col1 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-1895
SELECT DISTINCT + tab1.col2 / + ( col2 ) AS col1 FROM tab1
----
1

query I rowsort
SELECT cor0.col0 * 45 FROM tab1 AS cor0
----
135
2880
3600

query I rowsort
SELECT + col2 * ( col2 ) * col1 + col0 FROM tab0 AS cor0
----
132
611973
93678

query I rowsort
SELECT 85 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col2 * - cor0.col1 col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT - cor0.col2 + col2 * - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1901
SELECT - CAST( - col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1901
SELECT - CAST ( - col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1902
SELECT ( cor0.col1 ) * - col1 * - CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-205379
-29791
-4913

skipif mysql # not compatible
query I rowsort label-1902
SELECT ( cor0.col1 ) * - col1 * - CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT 55 * + 68 FROM tab0, tab1 AS cor0
----
9 values hashing to 65c9ae6c67bc1ffeb0d12f1a2efbeebd

query I rowsort
SELECT DISTINCT 91 * 29 AS col2 FROM tab2, tab0 AS cor0
----
2639

query I rowsort
SELECT DISTINCT col2 * - 51 FROM tab2
----
-1326
-1377
-1938

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1906
SELECT ALL - cor0.col2 * - cor0.col0 * - col0 + + CAST( NULL AS SIGNED ) * + col0 * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1906
SELECT ALL - cor0.col2 * - cor0.col0 * - col0 + + CAST ( NULL AS INTEGER ) * + col0 * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1907
SELECT ALL - 5 DIV - col0 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1907
SELECT ALL - 5 / - col0 FROM tab1
----
0
0
1

query I rowsort
SELECT + 57 * col1 AS col2 FROM tab1 AS cor0
----
1482
570
741

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1909
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1909
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL - - 44 * col0 + 6 FROM tab0 AS cor0
----
1062
1546
3922

onlyif mysql # use DIV operator for integer division
query I rowsort label-1911
SELECT + col1 * col0 DIV cor0.col2 FROM tab1 AS cor0
----
1
10
11

skipif mysql # not compatible
query I rowsort label-1911
SELECT + col1 * col0 / cor0.col2 FROM tab1 AS cor0
----
1
10
11

query I rowsort
SELECT ALL - - ( - col0 ) AS col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - - col1 * + col1 AS col0 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT - col1 * + col0 * ( col2 + + col2 * + 40 ) FROM tab1 AS cor0
----
-1495680
-172692
-4093440

query I rowsort
SELECT + 10 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

onlyif mysql # use DIV operator for integer division
query I rowsort label-1916
SELECT ALL + tab0.col1 * col0 DIV tab0.col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-1916
SELECT ALL + tab0.col1 * col0 / tab0.col1 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL ( col1 * - col2 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col0 * 58 FROM tab2
----
-406
-4524
-4582

onlyif mysql # use DIV operator for integer division
query I rowsort label-1919
SELECT - col0 DIV + col1 + + col2 * col1 * + 58 FROM tab2 cor0
----
37464
48546
88971

skipif mysql # not compatible
query I rowsort label-1919
SELECT - col0 / + col1 + + col2 * col1 * + 58 FROM tab2 cor0
----
37464
48546
88971

onlyif mysql # use DIV operator for integer division
query I rowsort label-1920
SELECT DISTINCT - col1 DIV 56 + 27 * - col2 * 39 FROM tab0 AS cor0
----
-1054
-34750
-86347

skipif mysql # not compatible
query I rowsort label-1920
SELECT DISTINCT - col1 / 56 + 27 * - col2 * 39 FROM tab0 AS cor0
----
-1054
-34750
-86347

query I rowsort
SELECT ALL + col0 - 71 * col1 AS col2 FROM tab0 cor0
----
-6082
-6372
-6852

query I rowsort
SELECT + col2 + col0 * + 95 FROM tab2 AS cor0
----
692
7436
7543

query I rowsort
SELECT - - col1 + 19 FROM tab0 AS cor0
----
105
110
116

query I rowsort
SELECT DISTINCT + + col1 * + col1 * + 30 FROM tab1 AS cor0
----
20280
3000
5070

query I rowsort
SELECT DISTINCT + + col0 * col1 + - col2 FROM tab2 AS cor0
----
1305
190
4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1926
SELECT - - col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1926
SELECT - - col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 - - 42 AS col0 FROM tab0 cor0
----
-44
-49
-55

query I rowsort
SELECT tab0.col1 * 8 FROM tab0, tab1 AS cor0
----
9 values hashing to 55c69e585d0208340fa1b0b86aef86b4

query I rowsort
SELECT DISTINCT + 22 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
22

query I rowsort
SELECT + 66 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT + - col1 * 83 FROM tab2 AS cor0
----
-1411
-2573
-4897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + ( - cor0.col2 ) col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT col2 * col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL col0 + - 85 FROM tab1
----
-21
-5
-82

query I rowsort
SELECT ALL col2 * col1 - col1 * - col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT - - 23 + col1 * col2 * + 88 AS col0 FROM tab0 AS cor0
----
249767
656679
8559

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 1 - col0 * + col1 col1 FROM tab0 AS cor0
----
-2063
-3394
-8098

query I rowsort
SELECT ALL + 75 + + col0 AS col2 FROM tab0 AS cor0
----
110
164
99

query I rowsort
SELECT ALL 33 * - col0 FROM tab2 AS cor0
----
-231
-2574
-2607

query I rowsort
SELECT + cor0.col0 * cor0.col0 - col2 AS col1 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 + - 90 AS col1 FROM tab1 AS cor0
----
-81
4006
6310

query I rowsort
SELECT ALL + - 1 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + + 64 - + col0 * + col1 FROM tab2 cor0
----
-1279
-153
-4538

query I rowsort
SELECT DISTINCT + 52 * col1 + + 76 + 77 FROM tab0 AS cor0
----
4625
4885
5197

query I rowsort
SELECT - + col0 * - col2 + - 67 AS col1 FROM tab2 AS cor0
----
122
1961
2935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * - col0 + col0 col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL - 1 - col0 AS col1 FROM tab2
----
-79
-8
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1948
SELECT tab1.col1 DIV 48 + tab1.col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1948
SELECT tab1.col1 / 48 + tab1.col1 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL 96 - 83 FROM tab0
----
13
13
13

query I rowsort
SELECT ALL + col0 - col2 * col2 * ( col1 ) FROM tab1
----
-119728
-32426
-75813

query I rowsort
SELECT ALL col2 * col0 + + 85 AS col1 FROM tab0
----
120
7383
877

query I rowsort
SELECT ALL - col2 * col2 + - col2 AS col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT DISTINCT - - 27 * cor0.col2 FROM tab0 AS cor0
----
2214
27
891

query I rowsort
SELECT DISTINCT col2 * + col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT + - col1 * col2 + cor0.col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - + col1 * + col2 + ( 48 ) AS col2 FROM tab2 AS cor0
----
-1486
-598
-789

query I rowsort
SELECT DISTINCT + 9 * - col1 - + col2 * + 40 FROM tab0 AS cor0
----
-2094
-4099
-913

query I rowsort
SELECT ALL + + 58 * col1 + + col1 FROM tab2 AS cor0
----
1003
1829
3481

query I rowsort
SELECT - ( - 30 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL - 95 AS col1 FROM tab2 AS cor0
----
-95
-95
-95

query I rowsort
SELECT col0 + - ( tab1.col2 ) AS col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - col1 + ( col1 ) * cor0.col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT - ( - col0 ) * + col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + ( - col0 + col2 ) AS col2 FROM tab1
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1966
SELECT CAST( - col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-1966
SELECT CAST ( - col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + 29 * + col2 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT DISTINCT - - col1 * col0 + col2 * col0 AS col0 FROM tab0 AS cor0
----
15397
2856
3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 52 col2 FROM tab0, tab0 AS cor0
----
-52

query I rowsort
SELECT - cor0.col2 * - 59 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 480e5281eb7ad5a17f369ba6b37b1b54

query I rowsort
SELECT 37 FROM tab1, tab1 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT DISTINCT + 25 + col2 AS col2 FROM tab0 AS cor0
----
107
26
58

query I rowsort
SELECT DISTINCT - ( + cor0.col0 ) + col2 * + cor0.col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + ( cor0.col2 ) * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 * col1 col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - ( + 10 ) * cor0.col0 FROM tab0 AS cor0
----
-240
-350
-890

query I rowsort
SELECT + col1 * 46 AS col0 FROM tab1 AS cor0
----
1196
460
598

query I rowsort
SELECT DISTINCT - + 94 * - col1 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT - - 32 + - col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-2806
-65
-7430

query I rowsort
SELECT DISTINCT - + col0 + col2 * col2 FROM tab2 cor0
----
1365
598
722

query I rowsort
SELECT DISTINCT 94 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
94

query I rowsort
SELECT ALL + 43 * col1 AS col2 FROM tab1 cor0
----
1118
430
559

query I rowsort
SELECT DISTINCT + 38 * + col2 FROM tab1 cor0
----
2052
2166
3648

query I rowsort
SELECT DISTINCT ( col1 + + col0 ) AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT + tab1.col0 - tab1.col0 FROM tab2, tab0 cor0 CROSS JOIN tab1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-1986
SELECT + col0 * col2 + col2 DIV col2 AS col1 FROM tab0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-1986
SELECT + col0 * col2 + col2 / col2 AS col1 FROM tab0
----
36
7299
793

query I rowsort
SELECT ALL + tab2.col2 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL col2 * cor0.col2 * col0 + col1 * + 53 AS col2 FROM tab0 AS cor0
----
30694
5176
603259

query I rowsort
SELECT DISTINCT - - cor0.col2 + - ( - col1 * col2 ) AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + + col0 + ( col1 ) + col2 * cor0.col1 * col1 AS col0 FROM tab1 cor0
----
16317
36533
5774

query I rowsort
SELECT cor0.col2 + - ( 24 + cor0.col0 ) * col1 FROM tab2 AS cor0
----
-1713
-5992
-934

query I rowsort
SELECT DISTINCT col2 + - 55 AS col1 FROM tab0 AS cor0
----
-22
-54
27

query I rowsort
SELECT col1 * col0 + + 3 FROM tab0 AS cor0
----
2067
3398
8102

query I rowsort
SELECT - col2 + col1 * ( tab1.col1 ) FROM tab1
----
43
622
73

query I rowsort
SELECT DISTINCT ( + col0 ) + + col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT 74 AS col1 FROM tab0 cor0
----
74
74
74

query I rowsort
SELECT ALL + col1 + - col2 * + col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-1998
SELECT 36 DIV + col1 AS col1 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1998
SELECT 36 / + col1 AS col1 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT ALL + col2 * 28 FROM tab1
----
1512
1596
2688

query I rowsort
SELECT - col1 + + ( + col1 + - col0 ) FROM tab0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 * col0 col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - 97 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT + col0 * + col1 + + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + - col0 * 73 FROM tab1 AS cor0
----
-219
-4672
-5840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( ( col1 ) ) * - col0 col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT cor0.col2 * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col1 + ( - col2 ) AS col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT - 27 + - 96 * - col0 + - ( 58 + col0 ) AS col0 FROM tab2 AS cor0
----
580
7325
7420

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2009
SELECT - ( col0 ) + - ( - ( + cor0.col0 ) ) / - CAST( NULL AS SIGNED ) + col1 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2009
SELECT - ( col0 ) + - ( - ( + cor0.col0 ) ) / - CAST ( NULL AS INTEGER ) + col1 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2010
SELECT cor0.col2 + col1 DIV + cor0.col2 + - col1 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-2010
SELECT cor0.col2 + col1 / + cor0.col2 + - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 * col0 + col0 * - col1 + col0 FROM tab2 AS cor0
----
-10608
-259
-7505

query I rowsort
SELECT - - cor0.col2 * col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - + col2 + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col2 ) col1 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + tab1.col2 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to f2656d9e76ae2d6dc568bba21c85e398

query I rowsort
SELECT col0 * col1 * 93 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
124937
20208
428012

query I rowsort
SELECT DISTINCT - tab0.col2 * col2 + - col1 * col2 * col2 FROM tab0
----
-618608
-94743
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col2 col1 FROM tab2
----
104
117
34

query I rowsort
SELECT 41 + col0 FROM tab1
----
105
121
44

query I rowsort
SELECT ALL + col1 + + col0 * col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT + cor0.col0 * - ( - 9 ) * cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 4365e35b81a576a386399818320d621d

onlyif mysql # use DIV operator for integer division
query I rowsort label-2022
SELECT - col2 DIV - col0 + 1 * ( + col2 ) FROM tab0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-2022
SELECT - col2 / - col0 + 1 * ( + col2 ) FROM tab0
----
1
34
82

query I rowsort
SELECT col1 * + tab1.col0 + + col2 - 50 FROM tab1
----
1086
647
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2024
SELECT - col1 * + col2 + - ( 41 * col0 ) + CAST( - 7 AS SIGNED ) FROM tab0 AS cor0
----
-11118
-1539
-3829

skipif mysql # not compatible
query I rowsort label-2024
SELECT - col1 * + col2 + - ( 41 * col0 ) + CAST ( - 7 AS INTEGER ) FROM tab0 AS cor0
----
-11118
-1539
-3829

onlyif mysql # use DIV operator for integer division
query I rowsort label-2025
SELECT DISTINCT + cor0.col0 DIV col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2025
SELECT DISTINCT + cor0.col0 / col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT + 89 + cor0.col2 + col2 FROM tab1 AS cor0
----
197
203
281

query I rowsort
SELECT ALL 64 * - col1 FROM tab0 AS cor0
----
-5504
-5824
-6208

onlyif mysql # use DIV operator for integer division
query I rowsort label-2028
SELECT + cor0.col0 DIV + 24 FROM tab0 AS cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-2028
SELECT + cor0.col0 / + 24 FROM tab0 AS cor0
----
1
1
3

query I rowsort
SELECT DISTINCT - - col1 * ( col1 ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + col1 + 16 FROM tab1 cor0
----
26
29
42

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + - col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT ALL - col0 - + 65 * + cor0.col2 FROM tab1 AS cor0
----
-3513
-3769
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * col2 col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2034
SELECT DISTINCT + cor0.col0 * - CAST( 4 AS SIGNED ) FROM tab1 AS cor0
----
-12
-256
-320

skipif mysql # not compatible
query I rowsort label-2034
SELECT DISTINCT + cor0.col0 * - CAST ( 4 AS INTEGER ) FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT ALL + cor0.col0 * 5 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT col1 - - col2 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + cor0.col0 * 48 - - col2 FROM tab0 AS cor0
----
1185
1681
4354

query I rowsort
SELECT - 99 * + 92 + - col0 AS col2 FROM tab0 AS cor0
----
-9132
-9143
-9197

query I rowsort
SELECT - + ( + 45 ) * + cor0.col1 AS col0 FROM tab0 cor0
----
-3870
-4095
-4365

query I rowsort
SELECT DISTINCT + + 12 * + 72 AS col1 FROM tab0 AS cor0
----
864

query I rowsort
SELECT ALL + - ( col0 ) * - cor0.col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + 50 * - col2 + col1 * ( 24 + + col2 ) FROM tab0 AS cor0
----
2375
3252
5546

query I rowsort
SELECT ALL - 54 * + 1 FROM tab1 AS cor0
----
-54
-54
-54

query I rowsort
SELECT DISTINCT - col2 + + col1 AS col1 FROM tab2 cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2045
SELECT col1 / - col1 + - CAST( NULL AS DECIMAL ) / - col2 + col2 * - 26 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2045
SELECT col1 / - col1 + - CAST ( NULL AS REAL ) / - col2 + col2 * - 26 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL - col2 + col0 * + 72 + + 37 * - col0 AS col1 FROM tab1 cor0
----
2183
2704
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2048
SELECT - col0 DIV 20 col2 FROM tab1
----
-3
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2048
SELECT - col0 / 20 col2 FROM tab1
----
-3
-4
0

query I rowsort
SELECT ALL - cor0.col1 + - ( col1 ) FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT 99 * - cor0.col1 FROM tab2 AS cor0
----
-1683
-3069
-5841

query I rowsort
SELECT ALL + + col0 * 99 + + col0 + col0 AS col2 FROM tab1 AS cor0
----
303
6464
8080

query I rowsort
SELECT ALL + 98 AS col1 FROM tab1 AS cor0
----
98
98
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2053
SELECT + - CAST( - col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2053
SELECT + - CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + 16 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9ffb4aaf972de606a4957894645b6216

query I rowsort
SELECT DISTINCT + + 34 * col2 AS col2 FROM tab1 cor0
----
1836
1938
3264

query I rowsort
SELECT DISTINCT - ( - col0 ) AS col2 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2057
SELECT ALL + col1 + col1 DIV + cor0.col1 + col1 * col2 FROM tab2 AS cor0
----
1594
664
869

skipif mysql # not compatible
query I rowsort label-2057
SELECT ALL + col1 + col1 / + cor0.col1 + col1 * col2 FROM tab2 AS cor0
----
1594
664
869

query I rowsort
SELECT ALL - - cor0.col0 * col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col1 + - col0 * col2 AS col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT col2 * col0 - - cor0.col2 * - col1 AS col1 FROM tab2 cor0
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-2061
SELECT DISTINCT - - col2 + cor0.col2 * + CAST( col0 AS SIGNED ) DIV col0 AS col2 FROM tab2 AS cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort label-2061
SELECT DISTINCT - - col2 + cor0.col2 * + CAST ( col0 AS INTEGER ) / col0 AS col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT 18 + col1 * + col0 FROM tab2 AS cor0
----
1361
235
4620

query I rowsort
SELECT - - 10 * col0 - 69 AS col0 FROM tab2 AS cor0
----
1
711
721

query I rowsort
SELECT DISTINCT + ( + col1 ) * col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + col2 - col2 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL ( - tab2.col2 ) * col2 FROM tab2
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2067
SELECT ALL 69 DIV - col1 col1 FROM tab1
----
-2
-5
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2067
SELECT ALL 69 / - col1 col1 FROM tab1
----
-2
-5
-6

query I rowsort
SELECT ALL + col2 * 30 FROM tab0
----
2460
30
990

query I rowsort
SELECT - 24 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

query I rowsort
SELECT DISTINCT - col0 + + col0 + - col2 * col1 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL cor0.col0 * - col1 * 22 AS col0 FROM tab1 AS cor0
----
-14080
-1716
-22880

query I rowsort
SELECT DISTINCT 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 - col0 + col0 col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL col0 * 14 * col0 AS col2 FROM tab1 cor0
----
126
57344
89600

query I rowsort
SELECT ALL + col1 + + 6 * + col1 AS col1 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT DISTINCT + + col1 * 71 AS col1 FROM tab0 AS cor0
----
6106
6461
6887

query I rowsort
SELECT + col0 * + col0 + 50 FROM tab2 AS cor0
----
6134
6291
99

query I rowsort
SELECT DISTINCT col0 + col1 + col0 AS col2 FROM tab2
----
175
215
45

query I rowsort
SELECT DISTINCT tab2.col1 + + tab2.col1 AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT + col0 + tab1.col0 * ( - 11 ) FROM tab1
----
-30
-640
-800

query I rowsort
SELECT ALL + + col1 - - 45 FROM tab1 AS cor0
----
55
58
71

query I rowsort
SELECT + col1 * col0 + - col2 FROM tab1
----
24
583
944

query I rowsort
SELECT + cor0.col2 * ( - col2 ) AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * ( 72 ) + col0 col2 FROM tab0 AS cor0
----
107
2400
5993

query I rowsort
SELECT ( 46 ) * + col0 + - 30 FROM tab0 AS cor0
----
1074
1580
4064

query I rowsort
SELECT col1 * - ( - col0 ) * + col1 + - 88 AS col1 FROM tab0
----
177416
329227
736921

query I rowsort
SELECT ALL col1 * + 68 FROM tab2
----
1156
2108
4012

query I rowsort
SELECT - cor0.col0 + - 40 FROM tab0 AS cor0
----
-129
-64
-75

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( 45 AS REAL ) AS col0 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to 8a6d20810140ea088e8e0fd74ffb8339

query I rowsort
SELECT + 56 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT 97 + ( - col0 ) FROM tab0
----
62
73
8

query I rowsort
SELECT DISTINCT + col1 * - 70 FROM tab2 AS cor0
----
-1190
-2170
-4130

query I rowsort
SELECT DISTINCT col0 + ( + cor0.col0 ) * col0 + col1 * col1 FROM tab1 AS cor0
----
4260
6649
688

query I rowsort
SELECT + ( 33 ) AS col2 FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT ALL - 45 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT DISTINCT - + col2 * col2 + ( 10 ) AS col1 FROM tab0 cor0
----
-1079
-6714
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2097
SELECT - col1 + col0 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2097
SELECT - col1 + col0 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL 57 * + col2 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT - + 45 * col1 FROM tab2 AS cor0
----
-1395
-2655
-765

query I rowsort
SELECT DISTINCT + + col1 * col2 * + 24 AS col0 FROM tab0 AS cor0
----
179088
2328
68112

query I rowsort
SELECT 31 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT DISTINCT - 24 AS col0 FROM tab0, tab1 AS cor0, tab0 cor1
----
-24

query I rowsort
SELECT ALL - col2 * 4 * col1 AS col1 FROM tab0 cor0
----
-11352
-29848
-388

onlyif mysql # use DIV operator for integer division
query I rowsort label-2105
SELECT DISTINCT + col2 DIV - 20 FROM tab0 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2105
SELECT DISTINCT + col2 / - 20 FROM tab0 cor0
----
-1
-4
0

query I rowsort
SELECT - + cor0.col0 + + cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT + tab0.col0 * + ( + tab0.col0 * col1 ) AS col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT - col0 * 27 * col0 AS col0 FROM tab0
----
-15552
-213867
-33075

query I rowsort
SELECT ALL + - col2 * ( 42 ) + col2 FROM tab0 cor0
----
-1353
-3362
-41

query I rowsort
SELECT - col0 + ( col2 ) AS col1 FROM tab0 cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * 17 col1 FROM tab2 AS cor0
----
-442
-459
-646

query I rowsort
SELECT cor0.col0 * ( col2 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col1 + - 1 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2114
SELECT + + col1 DIV - col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-2114
SELECT + + col1 / - col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
23
26
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2115
SELECT + - col2 * col2 DIV - col1 FROM tab1 cor0
----
112
324
708

skipif mysql # not compatible
query I rowsort label-2115
SELECT + - col2 * col2 / - col1 FROM tab1 cor0
----
112
324
708

query I rowsort
SELECT - col1 * col2 * col1 AS col2 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT + col0 * - col2 * - cor0.col0 + col2 * col0 AS col2 FROM tab2 AS cor0
----
1512
160212
240160

query I rowsort
SELECT ALL - col2 FROM tab0 AS cor0 WHERE NOT + col1 BETWEEN ( + col2 ) AND col1 * + col1
----

query I rowsort
SELECT ALL - col1 * + col0 * col0 AS col0 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL tab0.col1 * - col0 * col2 + + tab0.col2 * - col2 AS col0 FROM tab0 WHERE NOT - col0 NOT IN ( - col1 * col2 )
----

query I rowsort
SELECT DISTINCT tab2.col0 FROM tab1 AS cor0 CROSS JOIN tab2
----
7
78
79

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col0 / + col0 >= - col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col2 * col0 * - col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col1 * col2 - - col2 AS col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT ALL - 26 + - cor0.col0 FROM tab0 AS cor0
----
-115
-50
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-2126
SELECT tab1.col2 * col2 DIV col1 + col1 AS col1 FROM tab1
----
138
334
721

skipif mysql # not compatible
query I rowsort label-2126
SELECT tab1.col2 * col2 / col1 + col1 AS col1 FROM tab1
----
138
334
721

query I rowsort
SELECT + col2 * + col2 + + col1 AS col1 FROM tab1
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-2128
SELECT DISTINCT + col0 DIV tab1.col1 FROM tab1
----
0
6

skipif mysql # not compatible
query I rowsort label-2128
SELECT DISTINCT + col0 / tab1.col1 FROM tab1
----
0
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2129
SELECT ALL + col1 DIV - col0 + col1 + col2 col1 FROM tab2
----
54
55
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2129
SELECT ALL + col1 / - col0 + col1 + col2 col1 FROM tab2
----
54
55
85

query I rowsort
SELECT - tab0.col0 + + col2 + col2 AS col2 FROM tab0
----
-33
42
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2131
SELECT ALL - tab1.col0 DIV - col1 AS col2 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2131
SELECT ALL - tab1.col0 / - col1 AS col2 FROM tab1
----
0
6
6

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( + tab1.col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2133
SELECT DISTINCT col1 + col1 DIV tab0.col0 - col0 AS col2 FROM tab0
----
3
64
65

skipif mysql # not compatible
query I rowsort label-2133
SELECT DISTINCT col1 + col1 / tab0.col0 - col0 AS col2 FROM tab0
----
3
64
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + tab2.col0 + tab2.col0 col2 FROM tab2
----
182
196
41

query I rowsort
SELECT DISTINCT tab0.col2 + - col1 + tab0.col1 AS col2 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2136
SELECT ALL col2 DIV col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2136
SELECT ALL col2 / col1 col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2137
SELECT - col2 * + col0 DIV - col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2137
SELECT - col2 * + col0 / - col0 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2138
SELECT + col0 * col0 DIV col1 + col2 * col0 FROM tab1
----
162
4057
8172

skipif mysql # not compatible
query I rowsort label-2138
SELECT + col0 * col0 / col1 + col2 * col0 FROM tab1
----
162
4057
8172

query I rowsort
SELECT 74 + col0 AS col1 FROM tab1
----
138
154
77

query I rowsort
SELECT DISTINCT 16 + col0 FROM tab0
----
105
40
51

query I rowsort
SELECT DISTINCT col2 * col1 * - col2 + - tab1.col2 AS col0 FROM tab1
----
-119904
-32547
-75870

query I rowsort
SELECT tab1.col1 * - tab1.col2 * - col2 + 16 FROM tab1
----
119824
32506
75832

onlyif mysql # use DIV operator for integer division
query I rowsort label-2143
SELECT - tab1.col2 + col2 DIV 21 + + col2 col1 FROM tab1
----
2
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2143
SELECT - tab1.col2 + col2 / 21 + + col2 col1 FROM tab1
----
2
2
4

query I rowsort
SELECT DISTINCT col0 * tab0.col2 + tab0.col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL + - col1 + cor0.col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + ( col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL ( - col0 ) + + col1 * - 79 * + col2 AS col2 FROM tab0 AS cor0
----
-224226
-589587
-7698

query I rowsort
SELECT 64 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 9bd8c7417aea89812d57dc6142310b3f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + - col2 col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT col1 - tab2.col2 * col2 * col2 FROM tab2
----
-17517
-19652
-54855

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col0 col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL tab2.col1 + tab2.col2 FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT col1 + - col0 * tab1.col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT col2 + col1 * tab2.col2 FROM tab2 WHERE NOT NULL < col0 * + col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL col0 * col0 + col2 + - col1 FROM tab2
----
45
6051
6262

query III rowsort
SELECT * FROM tab2 WHERE + col2 * + col1 IN ( col2 + + col1 )
----

query I rowsort
SELECT + col1 + col0 * + tab0.col2 AS col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL + col0 FROM tab2 WHERE col0 * col0 * col2 >= NULL
----

query I rowsort
SELECT tab1.col1 + col0 * + col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT col1 + + col1 AS col1 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL - tab1.col0 * tab1.col1 AS col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2163
SELECT col0 + + col2 DIV 36 AS col2 FROM tab0
----
24
35
91

skipif mysql # not compatible
query I rowsort label-2163
SELECT col0 + + col2 / 36 AS col2 FROM tab0
----
24
35
91

query I rowsort
SELECT - 34 - col2 * - 82 AS col2 FROM tab2
----
2098
2180
3082

query I rowsort
SELECT DISTINCT + + 51 * col0 FROM tab1 cor0
----
153
3264
4080

query I rowsort
SELECT + - col0 + - cor0.col2 * col0 AS col2 FROM tab0 cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * col2 col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - 41 AS col2 FROM tab1 cor0
----
-41

query I rowsort
SELECT - 72 + + col0 AS col1 FROM tab0 AS cor0
----
-37
-48
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2170
SELECT ALL - ( - col0 ) + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2170
SELECT ALL - ( - col0 ) + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col2 * + ( + col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col0 + 76 * 31 FROM tab1 cor0
----
2359
2420
2436

onlyif mysql # use DIV operator for integer division
query I rowsort label-2173
SELECT ALL col0 DIV + 8 FROM tab2 AS cor0
----
0
9
9

skipif mysql # not compatible
query I rowsort label-2173
SELECT ALL col0 / + 8 FROM tab2 AS cor0
----
0
9
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT DISTINCT col0 + 88 DIV col2 AS col2 FROM tab0 AS cor0
----
123
26
90

skipif mysql # not compatible
query I rowsort label-2174
SELECT DISTINCT col0 + 88 / col2 AS col2 FROM tab0 AS cor0
----
123
26
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 92 * - 22 col2 FROM tab2 AS cor0
----
-52624
-54648
-76912

onlyif mysql # use DIV operator for integer division
query I rowsort label-2176
SELECT DISTINCT - col1 + - col2 DIV cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2176
SELECT DISTINCT - col1 + - col2 / cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + col2 * col1 * - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-22606
-24627
-39962

query I rowsort
SELECT DISTINCT + col2 * 29 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT - + col1 + col1 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT ALL + + col1 + col2 * + col2 * 99 + - 15 AS col2 FROM tab1 cor0
----
288695
321646
912382

query I rowsort
SELECT - 51 * + col0 - col2 AS col1 FROM tab1 AS cor0
----
-207
-3321
-4176

query I rowsort
SELECT ALL + cor0.col1 + + col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - 94 + + col2 FROM tab0 cor0
----
-12
-61
-93

query I rowsort
SELECT DISTINCT + - 27 AS col2 FROM tab1 AS cor0
----
-27

query I rowsort
SELECT + col1 + 93 AS col2 FROM tab0 AS cor0
----
179
184
190

query I rowsort
SELECT DISTINCT + + 75 * col0 + col1 FROM tab1 AS cor0
----
251
4810
6013

onlyif mysql # use DIV operator for integer division
query I rowsort label-2187
SELECT + col2 DIV - col2 - col2 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-2187
SELECT + col2 / - col2 - col2 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT ALL - ( 1 ) AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 63 + + col2 col0 FROM tab1 AS cor0
----
-6
-9
33

query I rowsort
SELECT - - cor0.col1 + ( col1 ) + + col0 AS col0 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT ALL col2 + + cor0.col0 * - col0 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-2192
SELECT DISTINCT + - col2 + + col1 * col2 + 84 DIV col1 FROM tab0 cor0
----
2805
7380
96

skipif mysql # not compatible
query I rowsort label-2192
SELECT DISTINCT + - col2 + + col1 * col2 + 84 / col1 FROM tab0 cor0
----
2805
7380
96

query I rowsort
SELECT + 98 * col0 AS col1 FROM tab1 AS cor0
----
294
6272
7840

query I rowsort
SELECT - 44 * + col0 + col2 AS col2 FROM tab1 cor0
----
-2759
-3424
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2195
SELECT ALL + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2195
SELECT ALL + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL col0 * cor0.col2 * - col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT col2 + + 30 * col2 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) + + cor0.col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ( + col1 ) * cor0.col1 - col1 AS col2 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT ALL + ( + col0 ) * col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - + col1 * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 98 * col2 AS col0 FROM tab1 AS cor0
----
5292
5586
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-2203
SELECT - - 98 + + col2 DIV col1 FROM tab2 cor0
----
100
98
98

skipif mysql # not compatible
query I rowsort label-2203
SELECT - - 98 + + col2 / col1 FROM tab2 cor0
----
100
98
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2204
SELECT ALL - - col0 + - col1 * + CAST( col2 + + col1 AS SIGNED ) FROM tab1 AS cor0
----
-1337
-2077
-606

skipif mysql # not compatible
query I rowsort label-2204
SELECT ALL - - col0 + - col1 * + CAST ( col2 + + col1 AS INTEGER ) FROM tab1 AS cor0
----
-1337
-2077
-606

query I rowsort
SELECT ALL - - 88 * col1 AS col0 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT - 2 * + col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL + + col1 + col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL - tab1.col2 + - col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT + + col1 * - col0 + - col2 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col0 + ( 27 + + col0 ) * 10 col0 FROM tab1 AS cor0
----
4558
462
8750

query I rowsort
SELECT ALL + ( - col2 ) + + col1 * 60 * col0 FROM tab1 AS cor0
----
38343
4626
62304

query I rowsort
SELECT col2 * + col2 + ( col2 ) FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL + ( col0 ) + - cor0.col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - col1 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2215
SELECT ALL 6 + col1 + + CAST( - col1 + + col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
39
7
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2215
SELECT ALL 6 + col1 + + CAST ( - col1 + + col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
39
7
88

query I rowsort
SELECT DISTINCT - 12 + tab0.col1 FROM tab0, tab0 AS cor0
----
74
79
85

query I rowsort
SELECT DISTINCT 21 * - col0 + col1 * + 61 FROM tab2
----
-622
1744
1961

query I rowsort
SELECT - col0 - - col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT col1 + ( col2 ) FROM tab1
----
109
67
80

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT col2 + col2 * + 90 + 56 AS col0 FROM tab0
----
147
3059
7518

query I rowsort
SELECT + cor0.col0 + col0 + + 89 * + 35 FROM tab0 cor0
----
3163
3185
3293

query I rowsort
SELECT + 82 * + col0 FROM tab0
----
1968
2870
7298

query I rowsort
SELECT DISTINCT 23 + cor0.col0 FROM tab0 AS cor0
----
112
47
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-2225
SELECT col0 DIV + col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-2225
SELECT col0 / + col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT + ( + col1 ) * + col1 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 45 col1 FROM tab2 AS cor0
----
-45
-45
-45

query I rowsort
SELECT DISTINCT + 53 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
53

query I rowsort
SELECT DISTINCT ( - 74 ) * col0 + + col1 FROM tab1
----
-196
-4726
-5907

query I rowsort
SELECT - tab0.col0 + 21 + + col0 FROM tab0
----
21
21
21

query I rowsort
SELECT DISTINCT - 29 * - 76 AS col1 FROM tab0 AS cor0
----
2204

query I rowsort
SELECT ALL + ( cor0.col0 ) AS col1 FROM tab2 cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2233
SELECT ALL - - CAST( NULL AS SIGNED ) * col2 + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2233
SELECT ALL - - CAST ( NULL AS INTEGER ) * col2 + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 67 * - col0 FROM tab0 AS cor0
----
1608
2345
5963

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col1 col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT 38 - cor0.col2 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to dfe7c495ddb399fd0b8bc29ea773d3e7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2237
SELECT - col1 + + 90 DIV - col2 AS col1 FROM tab1 AS cor0
----
-11
-13
-27

skipif mysql # not compatible
query I rowsort label-2237
SELECT - col1 + + 90 / - col2 AS col1 FROM tab1 AS cor0
----
-11
-13
-27

query I rowsort
SELECT - col1 * - col0 + - col2 + - col2 FROM tab2 AS cor0
----
1267
163
4550

query I rowsort
SELECT + col2 * cor0.col2 + + col0 AS col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT + + col2 - col2 * col2 AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

onlyif mysql # use DIV operator for integer division
query I rowsort label-2241
SELECT DISTINCT 95 + - col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
96

skipif mysql # not compatible
query I rowsort label-2241
SELECT DISTINCT 95 + - col0 / - col0 AS col2 FROM tab2 AS cor0
----
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2242
SELECT + CAST( NULL AS SIGNED ) + - 21 / col1 + 11 * col0 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2242
SELECT + CAST ( NULL AS INTEGER ) + - 21 / col1 + 11 * col0 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 23 * - cor0.col2 + - col2 FROM tab1 AS cor0
----
1188
1254
2112

query I rowsort
SELECT ALL + col0 * 94 FROM tab0 AS cor0
----
2256
3290
8366

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + - cor0.col1 + col2 col2 FROM tab2 cor0
----
100
3
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 36 - col2 col1 FROM tab1 AS cor0
----
-132
-90
-93

query I rowsort
SELECT DISTINCT 3 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2248
SELECT + - col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2248
SELECT + - col0 / + col1 AS col2 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT + 20 * col1 AS col2 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT DISTINCT 19 * - col2 * col2 + col1 + col1 FROM tab0
----
-127574
-20519
175

query I rowsort
SELECT DISTINCT 35 + - col2 FROM tab0
----
-47
2
34

query I rowsort
SELECT col0 + tab1.col1 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT - col2 * 82 * + col1 AS col0 FROM tab1 AS cor0
----
-102336
-115128
-46740

query I rowsort
SELECT col2 + - cor0.col1 * cor0.col0 * + col1 + - 37 FROM tab2 AS cor0
----
-22830
-271529
-6737

query I rowsort
SELECT - 85 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 91e44ead5e72fa22f87a57243e232ede

query I rowsort
SELECT ALL 9 FROM tab0, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL - + col2 * - cor0.col1 + - col2 * - col2 AS col1 FROM tab0 cor0
----
14186
3927
98

query I rowsort
SELECT ALL - col0 + + cor0.col1 * - col2 FROM tab2 AS cor0
----
-1612
-725
-844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + + ( col2 ) col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL col0 + ( - col0 ) AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * col0 - col0 AS col0 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT ALL col2 - 70 * + 32 AS col1 FROM tab0
----
-2158
-2207
-2239

query I rowsort
SELECT DISTINCT + tab1.col1 - ( 26 ) * col0 AS col0 FROM tab1
----
-1654
-2067
-52

query I rowsort
SELECT 31 + + cor0.col0 FROM tab0, tab1 cor0
----
9 values hashing to 24fa8f685160021bf96af2f39a41800b

query I rowsort
SELECT DISTINCT col1 - tab2.col2 * col2 AS col2 FROM tab2
----
-1427
-617
-698

onlyif mysql # use DIV operator for integer division
query I rowsort label-2266
SELECT ALL col2 * - CAST( col0 AS SIGNED ) - - col0 DIV 14 FROM tab0
----
-33
-7292
-791

skipif mysql # not compatible
query I rowsort label-2266
SELECT ALL col2 * - CAST ( col0 AS INTEGER ) - - col0 / 14 FROM tab0
----
-33
-7292
-791

query I rowsort
SELECT DISTINCT + + 69 * 79 AS col2 FROM tab0, tab2, tab1 AS cor0
----
5451

skipif mysql # not compatible
query I rowsort
SELECT ALL + ( - ( col0 ) ) * - CAST ( + col2 + - tab2.col1 AS REAL ) AS col1 FROM tab2
----
-2574
-28
1659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col2 - - col2 col0 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT ALL - 11 FROM tab0, tab2 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2271
SELECT - 35 / cor0.col1 + + CAST( NULL AS SIGNED ) FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2271
SELECT - 35 / cor0.col1 + + CAST ( NULL AS INTEGER ) FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - - 62 + col2 * col0 AS col2 FROM tab2 AS cor0
----
2090
251
3064

query I rowsort
SELECT col2 + - 95 AS col1 FROM tab2
----
-57
-68
-69

query I rowsort
SELECT DISTINCT - 62 FROM tab1, tab1 AS cor0
----
-62

query I rowsort
SELECT ( + ( col0 ) ) FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2276
SELECT + tab1.col2 DIV - ( + tab1.col0 ) - col2 FROM tab1
----
-57
-72
-97

skipif mysql # not compatible
query I rowsort label-2276
SELECT + tab1.col2 / - ( + tab1.col0 ) - col2 FROM tab1
----
-57
-72
-97

query I rowsort
SELECT 57 * col1 AS col2 FROM tab2
----
1767
3363
969

query I rowsort
SELECT + - col1 * col0 + + 6 AS col0 FROM tab2 AS cor0
----
-1337
-211
-4596

query I rowsort
SELECT DISTINCT 56 * - col1 * col2 FROM tab1
----
-31920
-69888
-78624

query I rowsort
SELECT DISTINCT - - col2 * col1 + col1 * - col1 + cor0.col2 FROM tab2 AS cor0
----
-1921
-97
395

query I rowsort
SELECT - - 68 AS col1 FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT DISTINCT 79 + cor0.col2 AS col0 FROM tab0 cor0
----
112
161
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2283
SELECT DISTINCT + col0 DIV col1 + - col2 DIV col1 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2283
SELECT DISTINCT + col0 / col1 + - col2 / col1 FROM tab2 AS cor0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 54 col1 FROM tab2 AS cor0
----
54
54
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-2285
SELECT - - CAST( - cor0.col1 AS SIGNED ) DIV col1 + 28 FROM tab0 AS cor0
----
27
27
27

skipif mysql # not compatible
query I rowsort label-2285
SELECT - - CAST ( - cor0.col1 AS INTEGER ) / col1 + 28 FROM tab0 AS cor0
----
27
27
27

query I rowsort
SELECT + col0 + 24 * - col1 AS col2 FROM tab1 cor0
----
-176
-232
-621

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col0 ) col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - - col1 * cor0.col2 + + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ( + 99 ) * - col0 + 61 * - 9 AS col1 FROM tab0 AS cor0
----
-2925
-4014
-9360

query I rowsort
SELECT ALL - col1 * + ( - col2 ) + col2 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2291
SELECT DISTINCT col2 DIV 63 + 10 * + col0 AS col0 FROM tab1
----
30
640
801

skipif mysql # not compatible
query I rowsort label-2291
SELECT DISTINCT col2 / 63 + 10 * + col0 AS col0 FROM tab1
----
30
640
801

query I rowsort
SELECT DISTINCT col1 * tab1.col1 + col0 AS col1 FROM tab1
----
164
249
679

query I rowsort
SELECT ALL tab1.col1 * col0 + 70 * + col1 FROM tab1
----
1340
1898
1950

onlyif mysql # use DIV operator for integer division
query I rowsort label-2294
SELECT ALL ( col0 ) DIV + tab1.col1 AS col0 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2294
SELECT ALL ( col0 ) / + tab1.col1 AS col0 FROM tab1
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2295
SELECT col2 DIV tab2.col0 + col0 * - 86 FROM tab2
----
-599
-6708
-6794

skipif mysql # not compatible
query I rowsort label-2295
SELECT col2 / tab2.col0 + col0 * - 86 FROM tab2
----
-599
-6708
-6794

query I rowsort
SELECT ALL + + 43 FROM tab0 AS cor0
----
43
43
43

query I rowsort
SELECT col2 * 17 AS col1 FROM tab0
----
1394
17
561

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2299
SELECT ALL + - CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2299
SELECT ALL + - CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - col2 + 22 AS col2 FROM tab2
----
-1512
-624
-815

query I rowsort
SELECT DISTINCT + + col2 - - col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT 79 AS col2 FROM tab1 cor0
----
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 4 * col0 col0 FROM tab2
----
28
312
316

query I rowsort
SELECT ALL + col1 * 80 AS col0 FROM tab1 AS cor0
----
1040
2080
800

query I rowsort
SELECT - col0 * col0 + + ( - col2 ) FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT DISTINCT - col0 + - col2 AS col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + col0 + + cor0.col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + cor0.col2 - col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + ( col2 ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - 27 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + cor0.col0 col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - col1 - ( col1 ) * + col2 AS col0 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL - col2 + 85 + col0 FROM tab0 cor0
----
119
76
92

query I rowsort
SELECT ALL col2 + col0 * ( + cor0.col0 ) FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL - col0 * col1 + ( col2 ) AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT + col2 * ( - 86 + + col2 ) AS col0 FROM tab1 AS cor0
----
-1653
-1728
960

query I rowsort
SELECT + - col2 * + cor0.col0 - + 55 * col1 AS col1 FROM tab0 cor0
----
-12303
-5370
-5522

query I rowsort
SELECT ALL - - col2 * col2 * col1 FROM tab2 AS cor0
----
22599
24548
39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-2319
SELECT + col0 * ( - col0 ) DIV + col1 FROM tab2
----
-1
-103
-367

skipif mysql # not compatible
query I rowsort label-2319
SELECT + col0 * ( - col0 ) / + col1 FROM tab2
----
-1
-103
-367

query I rowsort
SELECT DISTINCT + - col2 * + ( + col1 ) * + col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2321
SELECT - col1 DIV col1 col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2321
SELECT - col1 / col1 col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT 58 + col2 AS col1 FROM tab1 cor0
----
112
115
154

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2323
SELECT + CAST( NULL AS DECIMAL ) + + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2323
SELECT + CAST ( NULL AS REAL ) + + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + cor0.col2 AS col1 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT + 55 - cor0.col2 FROM tab0 AS cor0
----
-27
22
54

query I rowsort
SELECT ( col1 ) + - col0 AS col1 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT col1 * - 12 + 98 FROM tab2
----
-106
-274
-610

query I rowsort
SELECT + + cor0.col2 * + 91 AS col1 FROM tab0 cor0
----
3003
7462
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2329
SELECT + + CAST( - col2 AS SIGNED ) + - col2 * + ( 92 ) - col1 AS col0 FROM tab2 AS cor0
----
-2477
-2542
-3551

skipif mysql # not compatible
query I rowsort label-2329
SELECT + + CAST ( - col2 AS INTEGER ) + - col2 * + ( 92 ) - col1 AS col0 FROM tab2 AS cor0
----
-2477
-2542
-3551

onlyif mysql # use DIV operator for integer division
query I rowsort label-2330
SELECT + cor0.col0 DIV col2 col0 FROM tab1 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2330
SELECT + cor0.col0 / col2 col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 + + col1 * CAST ( - col2 * cor0.col2 AS REAL ) FROM tab2 cor0
----
-22572
-24510
-39858

onlyif mysql # use DIV operator for integer division
query I rowsort label-2332
SELECT - - 17 DIV - col0 AS col1 FROM tab1 AS cor0
----
-5
0
0

skipif mysql # not compatible
query I rowsort label-2332
SELECT - - 17 / - col0 AS col1 FROM tab1 AS cor0
----
-5
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2333
SELECT ALL + col1 DIV - cor0.col2 + + 33 AS col1 FROM tab1 AS cor0
----
33
33
33

skipif mysql # not compatible
query I rowsort label-2333
SELECT ALL + col1 / - cor0.col2 + + 33 AS col1 FROM tab1 AS cor0
----
33
33
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-2334
SELECT + col1 + + col2 DIV cor0.col1 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-2334
SELECT + col1 + + col2 / cor0.col1 FROM tab2 AS cor0
----
19
31
59

query I rowsort
SELECT DISTINCT + cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 63 * cor0.col0 FROM tab0 AS cor0
----
1512
2205
5607

query I rowsort
SELECT 85 * + cor0.col1 * col1 FROM tab2 cor0
----
24565
295885
81685

query I rowsort
SELECT + + 6 AS col2 FROM tab2 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT cor1.col2 * cor1.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
162
3648
7680

query I rowsort
SELECT + 19 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT - + col1 * - cor0.col0 * - col1 AS col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2342
SELECT DISTINCT - CAST( NULL AS SIGNED ) / + cor0.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2342
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / + cor0.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
NULL

query I rowsort
SELECT + col1 * - col2 - + ( + 48 ) FROM tab1 AS cor0
----
-1296
-1452
-618

query I rowsort
SELECT ALL + + col0 + col0 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT 42 * col1 AS col2 FROM tab1 AS cor0
----
1092
420
546

query I rowsort
SELECT DISTINCT + col1 + + col1 * + ( col0 + col1 ) AS col1 FROM tab0 AS cor0
----
12901
16471
9546

query I rowsort
SELECT DISTINCT + - col0 + + col0 * col2 + + col0 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2348
SELECT DISTINCT CAST( - 31 AS SIGNED ) * col0 AS col0 FROM tab2
----
-217
-2418
-2449

skipif mysql # not compatible
query I rowsort label-2348
SELECT DISTINCT CAST ( - 31 AS INTEGER ) * col0 AS col0 FROM tab2
----
-217
-2418
-2449

onlyif mysql # use DIV operator for integer division
query I rowsort label-2349
SELECT - col1 DIV + col1 - - 78 AS col0 FROM tab1 AS cor0
----
77
77
77

skipif mysql # not compatible
query I rowsort label-2349
SELECT - col1 / + col1 - - 78 AS col0 FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT - col1 - - col0 * 55 AS col1 FROM tab1 AS cor0
----
139
3510
4387

query I rowsort
SELECT - col1 * col0 * - 35 + col0 FROM tab2 AS cor0
----
161148
47084
7602

query I rowsort
SELECT + + 5 + col0 FROM tab1 AS cor0
----
69
8
85

query I rowsort
SELECT - col2 * - col1 - + col0 AS col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT - col0 + + 1 * col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT col0 * col0 + + col1 AS col0 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2356
SELECT - + cor0.col0 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2356
SELECT - + cor0.col0 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2358
SELECT CAST( + col2 AS SIGNED ) + + col2 * col1 FROM tab1 cor0
----
1344
1458
627

skipif mysql # not compatible
query I rowsort label-2358
SELECT CAST ( + col2 AS INTEGER ) + + col2 * col1 FROM tab1 cor0
----
1344
1458
627

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2359
SELECT ALL + - CAST( NULL AS SIGNED ) / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2359
SELECT ALL + - CAST ( NULL AS INTEGER ) / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 * + col2 col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + col2 + col0 * - col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT + 24 + - col0 FROM tab2 AS cor0
----
-54
-55
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2363
SELECT DISTINCT + CAST( + 9 AS SIGNED ) * + col1 * col2 FROM tab2 AS cor0
----
13806
5814
7533

skipif mysql # not compatible
query I rowsort label-2363
SELECT DISTINCT + CAST ( + 9 AS INTEGER ) * + col1 * col2 FROM tab2 AS cor0
----
13806
5814
7533

query I rowsort
SELECT ALL - 48 * - col0 AS col2 FROM tab2 AS cor0
----
336
3744
3792

query I rowsort
SELECT DISTINCT - - 17 * - cor0.col2 FROM tab0 cor0
----
-1394
-17
-561

query I rowsort
SELECT ALL + 50 * 28 + - col0 AS col0 FROM tab0 AS cor0
----
1311
1365
1376

query I rowsort
SELECT + - col1 + col2 * col1 FROM tab2 AS cor0
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2368
SELECT - col0 * - 65 + + col0 * CAST( + 17 AS SIGNED ) FROM tab0 AS cor0
----
1968
2870
7298

skipif mysql # not compatible
query I rowsort label-2368
SELECT - col0 * - 65 + + col0 * CAST ( + 17 AS INTEGER ) FROM tab0 AS cor0
----
1968
2870
7298

query I rowsort
SELECT + col2 + 1 FROM tab2 cor0
----
27
28
39

query I rowsort
SELECT + 11 * col2 FROM tab1 AS cor0
----
1056
594
627

query I rowsort
SELECT DISTINCT - ( + 56 ) + - col0 FROM tab0 AS cor0
----
-145
-80
-91

query I rowsort
SELECT ALL - ( - 69 ) * col0 FROM tab0 AS cor0
----
1656
2415
6141

query I rowsort
SELECT ALL + ( + col0 ) * + cor0.col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - + 54 + col0 AS col2 FROM tab2 cor0
----
-47
24
25

query I rowsort
SELECT + + 94 FROM tab0 AS cor0
----
94
94
94

query I rowsort
SELECT DISTINCT - 8 + - col0 * col2 FROM tab0 AS cor0
----
-43
-7306
-800

query I rowsort
SELECT ALL 90 * + cor0.col1 + 7 FROM tab1 AS cor0
----
1177
2347
907

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 2 - col2 col1 FROM tab2
----
26
27
38

query I rowsort
SELECT - col2 + col1 * + 88 AS col0 FROM tab1 AS cor0
----
1048
2234
823

query I rowsort
SELECT + col1 + ( - 33 + - cor0.col2 ) FROM tab1 cor0
----
-116
-61
-80

query I rowsort
SELECT ALL + - col1 * - ( col2 ) * + cor0.col2 + + 45 * col2 FROM tab2 AS cor0
----
23814
26258
41054

query I rowsort
SELECT DISTINCT col2 * + col0 + - col1 AS col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL - 63 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

query I rowsort
SELECT - cor0.col1 * - cor0.col0 + - col0 * col0 FROM tab1 cor0
----
-3456
-5360
69

query I rowsort
SELECT ALL - + cor0.col2 * col1 + col1 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + - col0 + 97 * + col1 FROM tab2 AS cor0
----
1570
3000
5645

query I rowsort
SELECT DISTINCT - cor0.col2 + ( 24 ) AS col1 FROM tab1 AS cor0
----
-30
-33
-72

query I rowsort
SELECT col0 - ( - ( + col1 ) ) * + 13 FROM tab2
----
300
410
845

query I rowsort
SELECT ALL col1 * + 68 AS col0 FROM tab1 AS cor0
----
1768
680
884

query I rowsort
SELECT ALL - col1 * 80 * + col0 AS col0 FROM tab1 AS cor0
----
-51200
-6240
-83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2391
SELECT CAST( NULL AS SIGNED ) * col2 + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2391
SELECT CAST ( NULL AS INTEGER ) * col2 + + col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2392
SELECT ALL + col1 + + CAST( NULL AS SIGNED ) / - 81 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2392
SELECT ALL + col1 + + CAST ( NULL AS INTEGER ) / - 81 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - 70 FROM tab1
----
-1820
-700
-910

query I rowsort
SELECT col1 * - 74 FROM tab0
----
-6364
-6734
-7178

query I rowsort
SELECT ALL ( 41 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL - cor0.col0 * cor0.col2 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to c9eceb64fb5e346d80937cf73eb6308e

query I rowsort
SELECT DISTINCT - + ( col2 ) * col0 * - col1 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT ALL - cor0.col0 + col0 * + 69 FROM tab0 AS cor0
----
1632
2380
6052

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 56 * col0 col1 FROM tab1 cor0
----
-168
-3584
-4480

query I rowsort
SELECT + + col2 + - col1 * - ( cor0.col1 + cor0.col2 ) AS col0 FROM tab1 AS cor0
----
1513
2134
727

query I rowsort
SELECT 13 * col2 * col2 FROM tab0 AS cor0
----
13
14157
87412

query I rowsort
SELECT ALL - - cor1.col1 + cor1.col2 AS col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

query I rowsort
SELECT ( col1 ) * col0 - - col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT DISTINCT ( - col2 ) * + col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT col0 + + col1 * ( col1 ) AS col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - - cor0.col0 * col0 + ( ( - col0 ) ) * col2 FROM tab1 cor0
----
-1280
-153
448

query I rowsort
SELECT ALL + col1 + + tab0.col0 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT + col2 + + col1 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL tab2.col1 * - col0 + + 82 AS col1 FROM tab2
----
-1261
-135
-4520

query I rowsort
SELECT - tab2.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT 63 * col2 FROM tab2
----
1638
1701
2394

query I rowsort
SELECT - cor0.col2 + 33 FROM tab1, tab2 AS cor0
----
9 values hashing to 23abe3632e9871e4f8071f7902c6b014

onlyif mysql # use DIV operator for integer division
query I rowsort label-2413
SELECT DISTINCT - 16 DIV - col1 + - col2 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2413
SELECT DISTINCT - 16 / - col1 + - col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT + col1 + col0 * col1 * + 9 + col0 * + col1 AS col2 FROM tab1
----
10413
6410
806

query I rowsort
SELECT DISTINCT - 46 + + col2 * - col2 * - 79 AS col2 FROM tab0
----
33
531150
85985

query I rowsort
SELECT + col0 + 90 FROM tab1
----
154
170
93

query I rowsort
SELECT DISTINCT col2 * - col0 + col1 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2418
SELECT ALL + 59 DIV ( col2 ) + 5 AS col0 FROM tab0 cor0
----
5
6
64

skipif mysql # not compatible
query I rowsort label-2418
SELECT ALL + 59 / ( col2 ) + 5 AS col0 FROM tab0 cor0
----
5
6
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 88 + cor0.col2 col1 FROM tab0 AS cor0
----
121
170
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 * col1 col1 FROM tab1 AS cor0
----
1976
760
988

query I rowsort
SELECT ALL - col1 * col1 + - col1 + col2 FROM tab0 cor0
----
-7449
-8290
-9505

onlyif mysql # use DIV operator for integer division
query I rowsort label-2422
SELECT DISTINCT - cor0.col1 * col2 DIV col1 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2422
SELECT DISTINCT - cor0.col1 * col2 / col1 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - - cor0.col2 * col0 + + col1 AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT 67 AS col1 FROM tab2, tab2 AS cor0
----
67

query I rowsort
SELECT DISTINCT ( + col2 * col1 + col2 ) AS col0 FROM tab2
----
1560
684
864

query I rowsort
SELECT + ( - ( col2 ) ) + col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT - - col2 + + 14 * + col1 AS col0 FROM tab1 AS cor0
----
197
278
418

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + 95 ) col1 FROM tab1 AS cor0
----
-95

query I rowsort
SELECT ALL - + 82 FROM tab2 AS cor0
----
-82
-82
-82

query I rowsort
SELECT DISTINCT col1 + col0 * + col0 FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-2431
SELECT ALL + col0 + - col0 * col0 DIV + col1 + - col0 AS col1 FROM tab1 AS cor0
----
-409
-492
0

skipif mysql # not compatible
query I rowsort label-2431
SELECT ALL + col0 + - col0 * col0 / + col1 + - col0 AS col1 FROM tab1 AS cor0
----
-409
-492
0

query I rowsort
SELECT ALL + + 74 * + 89 AS col1 FROM tab0 AS cor0
----
6586
6586
6586

query I rowsort
SELECT DISTINCT col0 + col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL + - 51 FROM tab0 AS cor0
----
-51
-51
-51

query I rowsort
SELECT + 36 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT ( + col0 + + col2 ) FROM tab1
----
121
176
57

query I rowsort
SELECT ALL col2 + cor0.col0 * - col0 FROM tab1 AS cor0
----
-4039
-6304
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - col1 col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT col2 * cor0.col1 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL cor0.col2 + - 89 FROM tab0 AS cor0
----
-56
-7
-88

query I rowsort
SELECT col2 * + col0 + col1 + + col0 AS col1 FROM tab2 AS cor0
----
2165
227
3098

query I rowsort
SELECT DISTINCT - col2 * + ( col0 ) * col0 AS col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - 56 * - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dc8adb5a22835a3499bc74e2304fbcb9

query I rowsort
SELECT DISTINCT - cor0.col2 * + 15 AS col0 FROM tab2 AS cor0
----
-390
-405
-570

query I rowsort
SELECT col2 + 3 + 24 FROM tab1 AS cor0
----
123
81
84

query I rowsort
SELECT - + col1 + col1 * - 21 + - col1 AS col2 FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT DISTINCT - cor0.col1 * 77 + - col0 FROM tab2 AS cor0
----
-1388
-2394
-4621

query I rowsort
SELECT + col2 + - 51 + 69 * col1 FROM tab1 AS cor0
----
1797
696
942

query I rowsort
SELECT + - col1 + 84 + - ( + col0 + + col0 ) FROM tab0 AS cor0
----
-185
-50
-83

query I rowsort
SELECT DISTINCT - - col2 + col0 * - ( col2 ) AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT col2 + 88 + col2 AS col1 FROM tab2 AS cor0
----
140
142
164

query I rowsort
SELECT - + cor0.col2 AS col2 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + + cor0.col0 + col0 AS col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT - col2 * - 51 + + col2 FROM tab2 AS cor0
----
1352
1404
1976

query I rowsort
SELECT - + 57 * cor0.col1 + - col0 AS col0 FROM tab0 AS cor0
----
-4926
-5276
-5564

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2456
SELECT CAST( + col0 AS SIGNED ) * - col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-2456
SELECT CAST ( + col0 AS INTEGER ) * - col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + 99 - col0 AS col2 FROM tab2 AS cor0
----
20
21
92

query I rowsort
SELECT - 66 + - 27 * cor0.col0 FROM tab0 AS cor0
----
-1011
-2469
-714

query I rowsort
SELECT - col1 * col2 + cor0.col0 * - col1 * col1 AS col1 FROM tab0 AS cor0
----
-180342
-329412
-744471

query I rowsort
SELECT + ( - cor0.col1 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT DISTINCT + col2 * + 57 * col0 FROM tab1 AS cor0
----
207936
437760
9234

query I rowsort
SELECT DISTINCT - col0 + 91 AS col1 FROM tab1 AS cor0
----
11
27
88

query I rowsort
SELECT ALL + 83 + - 88 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

query I rowsort
SELECT ALL tab1.col1 * col1 AS col2 FROM tab1
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2465
SELECT ALL - - col2 + - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-2465
SELECT ALL - - col2 + - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + col0 + - col2 + + col2 AS col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL 77 * col2 + col2 FROM tab0 AS cor0
----
2574
6396
78

query I rowsort
SELECT col1 + - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT col2 - col2 AS col2 FROM tab2 cor0
----
0

query I rowsort
SELECT ( - 26 ) + + col0 AS col0 FROM tab2 cor0
----
-19
52
53

query I rowsort
SELECT DISTINCT col0 * + col0 * + 10 + ( col1 * + 34 ) FROM tab0
----
15548
82304
8684

query I rowsort
SELECT - + cor0.col2 + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * cor0.col0 col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT col1 + col2 * col2 DIV 75 FROM tab2 AS cor0
----
36
40
68

skipif mysql # not compatible
query I rowsort label-2474
SELECT col1 + col2 * col2 / 75 FROM tab2 AS cor0
----
36
40
68

query I rowsort
SELECT 58 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT ALL 52 + col1 FROM tab2
----
111
69
83

query I rowsort
SELECT DISTINCT - 25 * col1 * col1 + col2 AS col1 FROM tab0 cor0
----
-184867
-206943
-235224

query I rowsort
SELECT - + col0 * + col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - ( col0 ) + + 51 * + 36 * col1 AS col0 FROM tab2 AS cor0
----
108246
31133
56909

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 col2 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2481
SELECT ALL + col2 DIV + 72 + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2481
SELECT ALL + col2 / + 72 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT col2 * 48 * + 50 - col0 AS col0 FROM tab0 AS cor0
----
196711
2365
79176

query I rowsort
SELECT + + cor0.col0 + - cor0.col0 * col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT col0 * 34 + cor0.col1 AS col0 FROM tab0 AS cor0
----
1287
3117
902

query I rowsort
SELECT DISTINCT cor0.col2 + col0 * + col0 AS col1 FROM tab2 AS cor0
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2486
SELECT DISTINCT - - col1 DIV col0 AS col1 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-2486
SELECT DISTINCT - - col1 / col0 AS col1 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT 2 * + 52 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d32adf5fdd5e4096e2c037977ca3f009

query I rowsort
SELECT - - col1 * col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL + + col0 + 97 AS col1 FROM tab0 cor0
----
121
132
186

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2490
SELECT ALL + col0 * 24 - ( + col1 ) * CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2490
SELECT ALL + col0 * 24 - ( + col1 ) * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col0 * + 5 AS col0 FROM tab2 AS cor0
----
35
390
395

query I rowsort
SELECT ALL - col1 * - ( + col2 ) FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2493
SELECT DISTINCT - col0 DIV col1 + + 78 AS col0 FROM tab1 AS cor0
----
72
78

skipif mysql # not compatible
query I rowsort label-2493
SELECT DISTINCT - col0 / col1 + + 78 AS col0 FROM tab1 AS cor0
----
72
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + - col0 * + ( - col1 ) * - col2 - - 45 * - col1 col0 FROM tab1
----
-101673
-37500
-6786

onlyif mysql # use DIV operator for integer division
query I rowsort label-2495
SELECT + col2 + - col1 DIV col2 + ( - col0 * col2 ) AS col2 FROM tab1
----
-108
-3591
-7584

skipif mysql # not compatible
query I rowsort label-2495
SELECT + col2 + - col1 / col2 + ( - col0 * col2 ) AS col2 FROM tab1
----
-108
-3591
-7584

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-2497
SELECT col2 DIV + 79 + - col0 - - tab0.col2 * + col1 FROM tab0
----
2814
62
7374

skipif mysql # not compatible
query I rowsort label-2497
SELECT col2 / + 79 + - col0 - - tab0.col2 * + col1 FROM tab0
----
2814
62
7374

query I rowsort
SELECT DISTINCT 65 + col0 FROM tab1 AS cor0
----
129
145
68

query I rowsort
SELECT 21 + col1 AS col1 FROM tab2 AS cor0
----
38
52
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2500
SELECT DISTINCT 15 DIV - cor0.col1 AS col2 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2500
SELECT DISTINCT 15 / - cor0.col1 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - 74 + - ( - col0 ) FROM tab1 cor0
----
-10
-71
6

query I rowsort
SELECT - + ( - 45 ) * + col1 FROM tab2 AS cor0
----
1395
2655
765

query I rowsort
SELECT DISTINCT col0 * cor0.col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL - 93 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-3069
-7626
-93

query I rowsort
SELECT - col2 - col2 * col2 FROM tab2 cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL - 97 * col1 FROM tab2 AS cor0
----
-1649
-3007
-5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 43 col2 FROM tab2 AS cor0
----
43

query I rowsort
SELECT 46 * + col2 + col1 AS col2 FROM tab0 AS cor0
----
143
1604
3863

query I rowsort
SELECT + col2 * col0 + - 6 FROM tab2 AS cor0
----
183
2022
2996

query I rowsort
SELECT DISTINCT + + cor0.col0 * col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2511
SELECT ALL + + cor0.col0 + - col1 DIV 14 FROM tab2 AS cor0
----
5
74
78

skipif mysql # not compatible
query I rowsort label-2511
SELECT ALL + + cor0.col0 + - col1 / 14 FROM tab2 AS cor0
----
5
74
78

query I rowsort
SELECT - col0 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col1 + cor0.col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT + + col1 * col0 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL col1 + - 16 - + tab1.col2 AS col1 FROM tab1
----
-44
-63
-99

query I rowsort
SELECT ALL + ( tab0.col1 ) * + col1 - col2 FROM tab0
----
7363
8199
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 * tab0.col2 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 957e42147c4e1160fc6b514706cda1c5

query I rowsort
SELECT DISTINCT - 57 + col2 FROM tab1 AS cor0
----
-3
0
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2519
SELECT - - CAST( 91 AS SIGNED ) FROM tab0 AS cor0
----
91
91
91

skipif mysql # not compatible
query I rowsort label-2519
SELECT - - CAST ( 91 AS INTEGER ) FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT ALL + 56 + - col2 + col1 AS col1 FROM tab0 AS cor0
----
109
152
65

query I rowsort
SELECT DISTINCT - - 13 + col0 AS col0 FROM tab1 cor0
----
16
77
93

query I rowsort
SELECT - 88 * - col0 FROM tab1 AS cor0
----
264
5632
7040

query I rowsort
SELECT ALL + cor0.col0 + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + cor0.col0 * col0 * + 84 AS col2 FROM tab1 AS cor0
----
344064
537600
756

query I rowsort
SELECT ALL + - 66 - - col0 * 8 AS col0 FROM tab1 AS cor0
----
-42
446
574

query I rowsort
SELECT + col0 + col1 * col0 FROM tab1 cor0
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2527
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-2527
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT ALL - col2 * + ( + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 78 + - cor0.col1 + - col2 * - ( - col1 ) col0 FROM tab1 AS cor0
----
-1360
-2275
-3458

query I rowsort
SELECT DISTINCT + - col2 * ( col2 + + cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-14022
-1881
-36

query I rowsort
SELECT col2 + col2 * + col1 + col2 FROM tab1 cor0
----
1440
1512
684

query I rowsort
SELECT - col2 + cor0.col1 * + col2 * + col2 + 72 FROM tab0 AS cor0
----
168
611874
93693

query I rowsort
SELECT DISTINCT cor0.col0 * - col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + + col0 * - 16 + + col0 FROM tab1 AS cor0
----
-1200
-45
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-2535
SELECT - col2 + + 52 DIV col2 FROM tab0 AS cor0
----
-32
-82
51

skipif mysql # not compatible
query I rowsort label-2535
SELECT - col2 + + 52 / col2 FROM tab0 AS cor0
----
-32
-82
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2536
SELECT + CAST( + cor0.col2 AS SIGNED ) * + col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-2536
SELECT + CAST ( + cor0.col2 AS INTEGER ) * + col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col2 * + 85 FROM tab2
----
2210
2295
3230

query I rowsort
SELECT DISTINCT - tab2.col0 * - col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col2 * + cor0.col2 - col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT ALL 59 * + col0 AS col2 FROM tab0 cor0
----
1416
2065
5251

query I rowsort
SELECT - - 2 AS col2 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT col0 * + col1 * col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-2543
SELECT DISTINCT - tab1.col1 DIV + col0 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-2543
SELECT DISTINCT - tab1.col1 / + col0 FROM tab1
----
-8
0

query I rowsort
SELECT + ( 97 ) + + col0 FROM tab2 AS cor0
----
104
175
176

query I rowsort
SELECT + + 74 AS col1 FROM tab0 AS cor0
----
74
74
74

query I rowsort
SELECT - col0 * 40 FROM tab1
----
-120
-2560
-3200

query I rowsort
SELECT - + col2 + 18 * + col1 AS col2 FROM tab0 AS cor0
----
1515
1556
1745

query I rowsort
SELECT - col0 + - 90 AS col0 FROM tab2 AS cor0
----
-168
-169
-97

query I rowsort
SELECT + + 97 * col0 FROM tab0 cor0
----
2328
3395
8633

query I rowsort
SELECT ALL - col1 + - col0 * - ( - col0 + - col0 ) AS col2 FROM tab2 AS cor0
----
-12227
-12499
-129

query I rowsort
SELECT DISTINCT + cor0.col2 * - tab0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 6e831ce95b59398818a720c8e9b6e293

query I rowsort
SELECT - ( col0 * - col2 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT + tab0.col2 + - ( - col2 ) FROM tab0
----
164
2
66

query I rowsort
SELECT col0 + - col1 * tab1.col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT col0 + - col1 * 52 AS col0 FROM tab1
----
-1349
-456
-596

query I rowsort
SELECT + + col0 * col1 + ( col1 ) * - cor0.col2 AS col0 FROM tab1 cor0
----
-1326
-208
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2557
SELECT DISTINCT + 50 * - col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2557
SELECT DISTINCT + 50 * - col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL

query I rowsort
SELECT - col2 + + ( col0 ) FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + cor0.col2 * cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8a9dbff4c424879f0bb94abfbb1a134b

query I rowsort
SELECT - col1 * col0 + 18 AS col2 FROM tab2 AS cor0
----
-1325
-199
-4584

onlyif mysql # use DIV operator for integer division
query I rowsort label-2561
SELECT col2 + + col1 - - 13 DIV + col0 AS col2 FROM tab1 cor0
----
109
67
84

skipif mysql # not compatible
query I rowsort label-2561
SELECT col2 + + col1 - - 13 / + col0 AS col2 FROM tab1 cor0
----
109
67
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 69 * cor0.col0 + + cor0.col2 col2 FROM tab2 AS cor0
----
-3354
-419770
-430591

onlyif mysql # use DIV operator for integer division
query I rowsort label-2563
SELECT + - cor0.col1 + ( + 22 ) * cor0.col2 DIV + col1 AS col2 FROM tab1 AS cor0
----
115
149
19

skipif mysql # not compatible
query I rowsort label-2563
SELECT + - cor0.col1 + ( + 22 ) * cor0.col2 / + col1 AS col2 FROM tab1 AS cor0
----
115
149
19

query I rowsort
SELECT 17 * + col0 * + col1 FROM tab1
----
10880
1326
17680

query I rowsort
SELECT - 92 + col2 AS col1 FROM tab0
----
-10
-59
-91

query I rowsort
SELECT - col2 + col2 * + col1 AS col0 FROM tab0 AS cor0
----
2805
7380
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2567
SELECT DISTINCT + col2 DIV tab2.col1 + + 88 AS col1 FROM tab2
----
88
90

skipif mysql # not compatible
query I rowsort label-2567
SELECT DISTINCT + col2 / tab2.col1 + + 88 AS col1 FROM tab2
----
88
90

query I rowsort
SELECT col1 * + col1 + + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT + 11 + col2 FROM tab1
----
107
65
68

query I rowsort
SELECT - + ( - col1 ) + ( + ( + col1 ) ) * 62 FROM tab0 AS cor0
----
5418
5733
6111

query I rowsort
SELECT DISTINCT - + cor0.col0 - cor0.col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2572
SELECT DISTINCT col1 DIV - col2 + 17 FROM tab0 AS cor0
----
-80
15
16

skipif mysql # not compatible
query I rowsort label-2572
SELECT DISTINCT col1 / - col2 + 17 FROM tab0 AS cor0
----
-80
15
16

query I rowsort
SELECT col0 + + col1 + + ( col2 + col0 ) * - col2 AS col1 FROM tab1 AS cor0
----
-16803
-3049
-6823

query I rowsort
SELECT DISTINCT 3 AS col0 FROM tab2, tab1 AS cor0, tab0 cor1
----
3

query I rowsort
SELECT col2 + + col1 + - col1 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * ( + col1 ) - - col2 col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT - col1 * - 97 FROM tab0 AS cor0
----
8342
8827
9409

query I rowsort
SELECT DISTINCT - - col2 - col1 * - 64 FROM tab2 AS cor0
----
1126
2011
3802

query I rowsort
SELECT ALL + cor0.col1 + + ( - col2 ) FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col2 * ( col2 + col2 ) AS col2 FROM tab1 AS cor0
----
18432
5832
6498

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2581
SELECT - + col2 + CAST( 48 AS SIGNED ) * + col2 FROM tab2 AS cor0
----
1222
1269
1786

skipif mysql # not compatible
query I rowsort label-2581
SELECT - + col2 + CAST ( 48 AS INTEGER ) * + col2 FROM tab2 AS cor0
----
1222
1269
1786

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2582
SELECT DISTINCT - col1 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2582
SELECT DISTINCT - col1 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + + col0 * 79 + - col1 - - col2 FROM tab2 AS cor0
----
549
6129
6262

query I rowsort
SELECT DISTINCT - + col0 + - 34 FROM tab2 AS cor0
----
-112
-113
-41

query I rowsort
SELECT DISTINCT tab0.col0 + col2 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT + 53 * + cor0.col1 FROM tab2 AS cor0
----
1643
3127
901

onlyif mysql # use DIV operator for integer division
query I rowsort label-2587
SELECT + + col2 DIV col1 + col0 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-2587
SELECT + + col2 / col1 + col0 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT + col0 * - 20 * + col1 - - cor0.col2 AS col1 FROM tab2 AS cor0
----
-26822
-4313
-92014

query I rowsort
SELECT + col2 * col0 * col2 - + col2 * col2 * col1 FROM tab0 cor0
----
-13448
-62
-67518

query I rowsort
SELECT + ( 9 ) * + col0 FROM tab0 AS cor0
----
216
315
801

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2591
SELECT DISTINCT CAST( NULL AS SIGNED ) + ( cor0.col0 + col0 ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2591
SELECT DISTINCT CAST ( NULL AS INTEGER ) + ( cor0.col0 + col0 ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col0 * + 4 + + cor0.col1 * + 93 + - col2 AS col0 FROM tab0 cor0
----
7869
8025
8880

query I rowsort
SELECT 69 + + 46 AS col1 FROM tab0 cor0
----
115
115
115

onlyif mysql # use DIV operator for integer division
query I rowsort label-2594
SELECT ALL - col0 DIV - 34 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
2
33
84

skipif mysql # not compatible
query I rowsort label-2594
SELECT ALL - col0 / - 34 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
2
33
84

query I rowsort
SELECT col0 * + ( col2 ) + col1 * + col0 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT DISTINCT 82 FROM tab1 cor0
----
82

query I rowsort
SELECT ALL - + col0 * cor0.col0 + + col1 * - 36 * col0 FROM tab2 AS cor0
----
-171756
-54589
-7861

query I rowsort
SELECT - tab2.col0 + - cor0.col2 FROM tab2, tab1 cor0
----
9 values hashing to 25b717de0e5bddb07e934fd4878503a0

query I rowsort
SELECT + col1 + - col2 * - 31 FROM tab2 AS cor0
----
1195
865
868

query I rowsort
SELECT ALL + 84 * 14 FROM tab0
----
1176
1176
1176

query I rowsort
SELECT col0 - - col0 * - col1 AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT 73 + + col0 FROM tab0 cor0
----
108
162
97

query I rowsort
SELECT DISTINCT + - col0 * col1 + - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL 26 * col0 + + ( - col2 ) * col2 * + col0 + col2 AS col0 FROM tab0 AS cor0
----
-25479
-596040
876

query I rowsort
SELECT ALL - - col2 * col2 + col1 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT 67 * col1 + + col0 + + col1 * + col2 FROM tab2 AS cor0
----
1864
2921
5565

query I rowsort
SELECT + + cor0.col0 * col0 AS col2 FROM tab0 cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col2 ) col1 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2609
SELECT ALL + - col0 DIV - col1 + 27 * - col1 FROM tab0 AS cor0
----
-2322
-2457
-2619

skipif mysql # not compatible
query I rowsort label-2609
SELECT ALL + - col0 / - col1 + 27 * - col1 FROM tab0 AS cor0
----
-2322
-2457
-2619

query I rowsort
SELECT col1 + + cor0.col2 + ( - 22 ) FROM tab2 AS cor0
----
33
36
63

query I rowsort
SELECT ALL - col0 - + col0 * + col2 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT ALL - 40 - - tab0.col0 AS col2 FROM tab0
----
-16
-5
49

query I rowsort
SELECT ALL 41 * tab1.col2 - - col2 AS col2 FROM tab1
----
2268
2394
4032

query I rowsort
SELECT ALL + col0 * - col0 - col2 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT ALL col0 + tab1.col1 * col1 AS col1 FROM tab1
----
164
249
679

query I rowsort
SELECT ALL 51 + tab2.col0 * + col1 AS col0 FROM tab2
----
1394
268
4653

query I rowsort
SELECT ALL 73 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT tab2.col0 + + col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT - 78 AS col0 FROM tab0 AS cor0
----
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2620
SELECT DISTINCT col0 DIV + col0 + - col1 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2620
SELECT DISTINCT col0 / + col0 + - col1 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT + 14 + + col0 FROM tab1 AS cor0
----
17
78
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-2622
SELECT DISTINCT - 13 DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2622
SELECT DISTINCT - 13 / col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + - cor0.col2 * cor0.col1 + 98 + col2 * col2 * + col2 FROM tab2 AS cor0
----
16140
18944
54324

query I rowsort
SELECT - - col2 + col1 + col2 AS col0 FROM tab0 cor0
----
152
255
99

query I rowsort
SELECT 67 + cor0.col1 * 38 - + col0 AS col0 FROM tab1 AS cor0
----
1052
383
481

query I rowsort
SELECT DISTINCT + 16 * + col2 FROM tab2 cor0
----
416
432
608

query I rowsort
SELECT ALL - - 37 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT + col1 * 64 AS col2 FROM tab2 cor0
----
1088
1984
3776

query I rowsort
SELECT - 58 + cor0.col0 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 0d165f0e2a18ccd7f44b537c9177dad2

query I rowsort
SELECT + 11 * col0 + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-112
-1170
-2133

query I rowsort
SELECT ALL - + col2 * + col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + col1 + + ( col0 ) * + 8 * 88 AS col0 FROM tab2 AS cor0
----
4959
54971
55633

query I rowsort
SELECT col0 * col2 + col1 * ( col1 * tab2.col0 ) AS col0 FROM tab2
----
25833
273546
6916

query I rowsort
SELECT 19 * 40 AS col0 FROM tab1 AS cor0
----
760
760
760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 30 col2 FROM tab2 AS cor0
----
30
30
30

query I rowsort
SELECT ALL - + ( - 79 ) * col1 FROM tab1 AS cor0
----
1027
2054
790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2637
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + col1 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2637
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + col1 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL cor0.col2 + + 20 * col2 * col1 AS col2 FROM tab1 AS cor0
----
11457
25056
28134

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2639
SELECT + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2639
SELECT + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + col0 - + cor0.col1 FROM tab0 cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + + col0 * col1 col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT col1 * col1 * ( + col0 ) AS col2 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT ALL - col1 * col2 + - 78 FROM tab1 AS cor0
----
-1326
-1482
-648

query I rowsort
SELECT - 50 AS col2 FROM tab0
----
-50
-50
-50

query I rowsort
SELECT DISTINCT col2 * + col0 + col0 + + col2 FROM tab0 cor0
----
71
7469
849

query I rowsort
SELECT DISTINCT - col0 + 28 AS col0 FROM tab1 AS cor0
----
-36
-52
25

query I rowsort
SELECT ALL + - col2 + + col2 * col2 * - col2 FROM tab2 AS cor0
----
-17602
-19710
-54910

query I rowsort
SELECT + col2 * - 64 FROM tab1 cor0
----
-3456
-3648
-6144

onlyif mysql # use DIV operator for integer division
query I rowsort label-2649
SELECT ALL + + col1 - 97 DIV + 58 AS col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-2649
SELECT ALL + + col1 - 97 / + 58 AS col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT ALL col0 * col0 + 56 - - cor0.col0 * + 44 FROM tab1 cor0
----
197
6968
9976

query I rowsort
SELECT DISTINCT + col1 * col2 * - col2 + - 80 * - col0 AS col1 FROM tab2
----
-18228
-22039
-33644

onlyif mysql # use DIV operator for integer division
query I rowsort label-2652
SELECT DISTINCT + ( col2 ) DIV col1 + + col0 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2652
SELECT DISTINCT + ( col2 ) / col1 + + col0 FROM tab2
----
7
78
81

query I rowsort
SELECT DISTINCT 71 * + col1 + + tab0.col1 + + col1 * tab0.col0 AS col2 FROM tab0
----
10379
14651
8256

onlyif mysql # use DIV operator for integer division
query I rowsort label-2654
SELECT + ( col0 ) * col1 + 58 + + 76 DIV col2 AS col2 FROM tab0 AS cor0
----
2124
3529
8157

skipif mysql # not compatible
query I rowsort label-2654
SELECT + ( col0 ) * col1 + 58 + + 76 / col2 AS col2 FROM tab0 AS cor0
----
2124
3529
8157

onlyif mysql # use DIV operator for integer division
query I rowsort label-2655
SELECT ( ( + col1 ) + col2 ) DIV + col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2655
SELECT ( ( + col1 ) + col2 ) / + col1 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT col1 * - col1 + col2 * - 58 * 55 AS col2 FROM tab1
----
-172936
-181930
-306409

query I rowsort
SELECT + ( + ( col0 ) ) * - 67 + col1 AS col0 FROM tab1
----
-175
-4278
-5347

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2658
SELECT DISTINCT ( col2 ) * + col1 + + CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2658
SELECT DISTINCT ( col2 ) * + col1 + + CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT - col2 + cor0.col0 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2660
SELECT ALL + + col1 + - col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2660
SELECT ALL + + col1 + - col2 / - col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - cor0.col1 + col1 * + col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT - col1 * 50 + - col0 + + col0 AS col1 FROM tab1 cor0
----
-1300
-500
-650

query I rowsort
SELECT DISTINCT + ( col1 ) * cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + ( - 61 ) * col0 AS col0 FROM tab1 AS cor0
----
-183
-3904
-4880

query I rowsort
SELECT DISTINCT - 97 + + col1 AS col2 FROM tab0 AS cor0
----
-11
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col2 + cor0.col0 col1 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + col0 * + col0 - - col0 * - col1 * col0 AS col2 FROM tab1 AS cor0
----
-225
-36864
-76800

query I rowsort
SELECT ALL 82 + col2 * ( - col2 ) * + col2 AS col1 FROM tab1 AS cor0
----
-157382
-185111
-884654

query I rowsort
SELECT + + 52 + cor0.col1 * 52 AS col0 FROM tab1 AS cor0
----
1404
572
728

query I rowsort
SELECT DISTINCT - 2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 + + col1 * col0 col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL + ( col1 ) * - col1 - col2 AS col0 FROM tab0 cor0
----
-7429
-8363
-9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-2673
SELECT ALL + - 45 DIV - col0 + col1 + + col0 FROM tab1 AS cor0
----
44
74
93

skipif mysql # not compatible
query I rowsort label-2673
SELECT ALL + - 45 / - col0 + col1 + + col0 FROM tab1 AS cor0
----
44
74
93

query I rowsort
SELECT DISTINCT + 42 * - col2 - - 91 AS col2 FROM tab1 AS cor0
----
-2177
-2303
-3941

query I rowsort
SELECT + 86 + + col1 AS col2 FROM tab2 AS cor0
----
103
117
145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col0 ) + - col2 + col0 col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT col0 * 65 FROM tab0
----
1560
2275
5785

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2678
SELECT DISTINCT CAST( NULL AS SIGNED ) + ( col2 * + col2 + + 40 ) AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2678
SELECT DISTINCT CAST ( NULL AS INTEGER ) + ( col2 * + col2 + + 40 ) AS col2 FROM tab1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2679
SELECT CAST( - cor0.col2 AS SIGNED ) FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

skipif mysql # not compatible
query I rowsort label-2679
SELECT CAST ( - cor0.col2 AS INTEGER ) FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

onlyif mysql # use DIV operator for integer division
query I rowsort label-2680
SELECT ALL - 4 + + col0 DIV - col2 AS col2 FROM tab0
----
-39
-4
-5

skipif mysql # not compatible
query I rowsort label-2680
SELECT ALL - 4 + + col0 / - col2 AS col2 FROM tab0
----
-39
-4
-5

query I rowsort
SELECT + + col1 * cor0.col2 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + + cor0.col2 * + col1 + + col2 + col1 * col0 AS col1 FROM tab1 AS cor0
----
1267
1536
2384

query I rowsort
SELECT + + col1 + col2 + ( col2 ) AS col0 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT + - cor0.col2 + col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + col1 + col0 * col1 + col0 FROM tab2 AS cor0
----
1439
255
4739

query I rowsort
SELECT + col1 * col0 * 4 AS col2 FROM tab0 cor0
----
13580
32396
8256

query I rowsort
SELECT - + ( col0 ) + + 63 FROM tab2 AS cor0
----
-15
-16
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-2688
SELECT + col0 + + col1 DIV - col0 + - col2 col1 FROM tab0 cor0
----
-12
32
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2688
SELECT + col0 + + col1 / - col0 + - col2 col1 FROM tab0 cor0
----
-12
32
6

query I rowsort
SELECT col0 * 10 * - cor0.col0 + col0 FROM tab2 AS cor0
----
-483
-60762
-62331

query I rowsort
SELECT DISTINCT 21 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
21

query I rowsort
SELECT ALL + 79 * col2 FROM tab0
----
2607
6478
79

query I rowsort
SELECT 52 AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT DISTINCT 25 * col2 AS col1 FROM tab1
----
1350
1425
2400

query I rowsort
SELECT ALL + tab1.col1 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

onlyif mysql # use DIV operator for integer division
query I rowsort label-2695
SELECT ALL - tab2.col2 DIV col1 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2695
SELECT ALL - tab2.col2 / col1 FROM tab2
----
-2
0
0

query I rowsort
SELECT ALL - col2 * - col0 * - col1 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT + cor0.col1 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - cor0.col1 * - 45 FROM tab2 AS cor0
----
1395
2655
765

query I rowsort
SELECT + + ( - 4 ) + col0 FROM tab1 cor0
----
-1
60
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2700
SELECT ALL col1 DIV CAST( col1 * + col1 AS SIGNED ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2700
SELECT ALL col1 / CAST ( col1 * + col1 AS INTEGER ) FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + tab2.col2 col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT - ( + 84 ) FROM tab1, tab2 AS cor0
----
-84

query I rowsort
SELECT DISTINCT - 24 * - ( + col1 ) FROM tab2 AS cor0
----
1416
408
744

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2704
SELECT - CAST( NULL AS SIGNED ) + - col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2704
SELECT - CAST ( NULL AS INTEGER ) + - col2 col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2705
SELECT DISTINCT + col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-2705
SELECT DISTINCT + col2 / + col0 AS col0 FROM tab2 AS cor0
----
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col2 col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( + cor0.col0 ) col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 84 col0 FROM tab2 AS cor0
----
-84
-84
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-2709
SELECT - col0 DIV col2 + col0 AS col0 FROM tab1 AS cor0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-2709
SELECT - col0 / col2 + col0 AS col0 FROM tab1 AS cor0
----
3
63
80

query I rowsort
SELECT DISTINCT - col0 - + col1 * col2 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT - 86 FROM tab0, tab1 cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

onlyif mysql # use DIV operator for integer division
query I rowsort label-2712
SELECT + ( col0 ) DIV - col2 + 47 AS col0 FROM tab1 AS cor0
----
46
47
47

skipif mysql # not compatible
query I rowsort label-2712
SELECT + ( col0 ) / - col2 + 47 AS col0 FROM tab1 AS cor0
----
46
47
47

query I rowsort
SELECT - + ( + col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL 39 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT - col1 * col0 + + col1 * col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col0 * + col1 + - col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2717
SELECT DISTINCT - CAST( col2 AS SIGNED ) FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2717
SELECT DISTINCT - CAST ( col2 AS INTEGER ) FROM tab2 cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2718
SELECT ALL 71 + col2 DIV col0 AS col1 FROM tab2 AS cor0
----
71
71
74

skipif mysql # not compatible
query I rowsort label-2718
SELECT ALL 71 + col2 / col0 AS col1 FROM tab2 AS cor0
----
71
71
74

query I rowsort
SELECT ALL + + cor0.col0 - - ( col0 ) FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2720
SELECT ALL + CAST( NULL AS SIGNED ) + col0 * - 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-2720
SELECT ALL + CAST ( NULL AS INTEGER ) + col0 * - col1 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 39 * - ( col1 ) FROM tab0 AS cor0
----
-3354
-3549
-3783

query I rowsort
SELECT ALL + col2 - + 98 * col2 FROM tab0 AS cor0
----
-3201
-7954
-97

query I rowsort
SELECT DISTINCT + - col1 * - 81 * col1 AS col0 FROM tab2 AS cor0
----
23409
281961
77841

query I rowsort
SELECT ALL col2 + 82 + col1 * - 95 FROM tab2 AS cor0
----
-1495
-2836
-5497

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 33 col0 FROM tab1 AS cor0
----
-33
-33
-33

query I rowsort
SELECT DISTINCT + ( - 45 ) + - col0 FROM tab1 AS cor0
----
-109
-125
-48

query I rowsort
SELECT ( - col1 ) + - col2 AS col1 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT cor0.col2 * + 48 AS col0 FROM tab0 AS cor0
----
1584
3936
48

query I rowsort
SELECT + + 22 * col1 AS col2 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT DISTINCT - col0 * + col0 * col0 FROM tab2
----
-343
-474552
-493039

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2731
SELECT + col1 + cor0.col0 / CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2731
SELECT + col1 + cor0.col0 / CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col1 * - col0 + col1 AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + col0 - - cor0.col1 AS col2 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2734
SELECT - CAST( NULL AS SIGNED ) * 63 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2734
SELECT - CAST ( NULL AS INTEGER ) * 63 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2735
SELECT DISTINCT col0 * 68 + ( col0 ) * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2735
SELECT DISTINCT col0 * 68 + ( col0 ) * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT col0 + + 56 * col0 AS col2 FROM tab1 AS cor0
----
171
3648
4560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + - col2 * ( + 78 ) FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT ALL + col1 + col0 * + 84 AS col1 FROM tab0 AS cor0
----
2102
3037
7567

query I rowsort
SELECT + col2 * + col2 + + ( + col2 ) FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT DISTINCT + col2 + 17 * ( col2 ) FROM tab2 AS cor0
----
468
486
684

query I rowsort
SELECT + col2 + + col2 * + col1 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL col2 * col0 + 93 * col1 FROM tab2 AS cor0
----
3072
4583
7515

onlyif mysql # use DIV operator for integer division
query I rowsort label-2745
SELECT + col2 DIV 71 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2745
SELECT + col2 / 71 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col1 * 62 AS col2 FROM tab0 AS cor0
----
-5332
-5642
-6014

query I rowsort
SELECT DISTINCT + col1 * + ( - col1 ) FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2749
SELECT + col0 / col1 + + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2749
SELECT + col0 / col1 + + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * ( col2 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col1 * col1 + + col2 * col2 AS col0 FROM tab0 AS cor0
----
15005
8485
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 74 * 35 + cor0.col2 * - col1 col1 FROM tab0 AS cor0
----
-219842
-2687
-88308

query I rowsort
SELECT ALL - - cor0.col2 + + ( - col0 ) AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + col1 + col1 * - col0 + - col2 AS col1 FROM tab0
----
-2011
-3299
-8090

query I rowsort
SELECT DISTINCT - tab0.col0 * + col2 + + 92 * - col1 - - 87 FROM tab0
----
-15583
-8617
-8872

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 25b043ae64f25e8f205735b09d2d3d6a

query I rowsort
SELECT ALL + - 8 AS col1 FROM tab2 cor0
----
-8
-8
-8

query I rowsort
SELECT ALL col0 * col0 + ( col0 ) FROM tab2 cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2759
SELECT cor0.col0 DIV + col1 + - col1 AS col1 FROM tab1 AS cor0
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-2759
SELECT cor0.col0 / + col1 + - col1 AS col1 FROM tab1 AS cor0
----
-26
-4
-7

query I rowsort
SELECT ALL 96 FROM tab1, tab1 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT - col2 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT - - col0 * - col1 + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL + col2 * + 94 + col0 AS col0 FROM tab0
----
129
3126
7797

query I rowsort
SELECT DISTINCT 81 AS col1 FROM tab2
----
81

query I rowsort
SELECT + - tab1.col1 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - col1 * - col1 * - col1 AS col1 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT 30 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT 26 * col2 + + 26 AS col2 FROM tab2
----
1014
702
728

query I rowsort
SELECT + 95 * + col2 + col2 * col1 FROM tab0
----
15252
192
5973

onlyif mysql # use DIV operator for integer division
query I rowsort label-2770
SELECT ALL ( col2 ) DIV col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2770
SELECT ALL ( col2 ) / col1 FROM tab1
----
2
5
7

query I rowsort
SELECT ALL col2 + col1 + cor0.col2 AS col2 FROM tab0 AS cor0
----
152
255
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2772
SELECT ALL + - cor0.col0 DIV - col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2772
SELECT ALL + - cor0.col0 / - col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT cor2.col2 FROM tab1, tab0 AS cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL - - col1 + - col2 AS col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT 64 * - col0 AS col1 FROM tab1 AS cor0
----
-192
-4096
-5120

onlyif mysql # use DIV operator for integer division
query I rowsort label-2776
SELECT - - 93 DIV + ( + col1 ) + + 41 + col2 * cor0.col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
114122
5147
52770

skipif mysql # not compatible
query I rowsort label-2776
SELECT - - 93 / + ( + col1 ) + + 41 + col2 * cor0.col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
114122
5147
52770

query I rowsort
SELECT + ( col2 ) * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT 81 + col2 * col2 FROM tab1 AS cor0
----
2997
3330
9297

query I rowsort
SELECT DISTINCT - ( - 11 ) * - col2 FROM tab2 AS cor0
----
-286
-297
-418

query I rowsort
SELECT ALL + 25 * + col2 FROM tab1 cor0
----
1350
1425
2400

query I rowsort
SELECT + col0 * col0 * + col0 FROM tab0
----
13824
42875
704969

query I rowsort
SELECT tab0.col1 + 34 * - col1 FROM tab0
----
-2838
-3003
-3201

query I rowsort
SELECT col2 - 14 * col2 FROM tab1 AS cor0
----
-1248
-702
-741

onlyif mysql # use DIV operator for integer division
query I rowsort label-2784
SELECT + + cor0.col1 * col2 + col0 * cor0.col2 + col0 DIV col1 FROM tab0 AS cor0
----
132
14760
3630

skipif mysql # not compatible
query I rowsort label-2784
SELECT + + cor0.col1 * col2 + col0 * cor0.col2 + col0 / col1 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT ( col1 ) * + col0 + 33 AS col2 FROM tab0 AS cor0
----
2097
3428
8132

onlyif mysql # use DIV operator for integer division
query I rowsort label-2786
SELECT DISTINCT col2 DIV 96 + 20 AS col2 FROM tab1
----
20
21

skipif mysql # not compatible
query I rowsort label-2786
SELECT DISTINCT col2 / 96 + 20 AS col2 FROM tab1
----
20
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 + + col0 col0 FROM tab1
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * - cor0.col2 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 42bf3b8f2bb865dbe16abdf6d3d647fc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2789
SELECT + CAST( NULL AS DECIMAL ) + col0 * + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2789
SELECT + CAST ( NULL AS REAL ) + col0 * + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2790
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 96 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2790
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 96 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - - col0 * + 25 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT ( col0 ) * - col0 + + cor0.col0 FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2793
SELECT DISTINCT CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2793
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT + + col2 + + cor0.col0 + col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT 54 + 3 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT col0 * + col1 * - col0 AS col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT 22 + + tab0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to ecc40f22db3be52650304cd9d3449cc4

query I rowsort
SELECT col1 * 38 AS col1 FROM tab2
----
1178
2242
646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col0 + ( 75 * - col2 ) col1 FROM tab0
----
-2451
-40
-6061

query I rowsort
SELECT 27 FROM tab2, tab1 cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT + col0 + + 16 * - col0 FROM tab0 AS cor0
----
-1335
-360
-525

query I rowsort
SELECT DISTINCT col2 + + ( col1 + + col2 * - col1 ) FROM tab0 AS cor0
----
-2719
-7289
1

query I rowsort
SELECT ALL - col2 * + col2 * + col0 AS col0 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT ALL 0 AS col1 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT col1 * 13 AS col2 FROM tab0 AS cor0
----
1118
1183
1261

query I rowsort
SELECT - col2 * 19 + ( + col2 ) AS col1 FROM tab1 cor0
----
-1026
-1728
-972

query I rowsort
SELECT DISTINCT - col1 * col1 + + col1 FROM tab1
----
-156
-650
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2808
SELECT - + CAST( NULL AS SIGNED ) - - 80 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2808
SELECT - + CAST ( NULL AS INTEGER ) - - 80 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + tab1.col1 * - 8 AS col1 FROM tab1
----
-104
-208
-80

query I rowsort
SELECT col1 * + 99 FROM tab0 AS cor0
----
8514
9009
9603

query I rowsort
SELECT + col0 * col2 * + 7 AS col1 FROM tab0 AS cor0
----
245
51086
5544

query I rowsort
SELECT ALL + + cor0.col0 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL - col0 + col1 - - col2 AS col2 FROM tab0
----
63
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2814
SELECT DISTINCT + + col0 * cor0.col2 + + col1 + + col1 DIV col0 AS col2 FROM tab1 AS cor0
----
196
3658
7693

skipif mysql # not compatible
query I rowsort label-2814
SELECT DISTINCT + + col0 * cor0.col2 + + col1 + + col1 / col0 AS col2 FROM tab1 AS cor0
----
196
3658
7693

query I rowsort
SELECT DISTINCT - + col0 * col2 * col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2816
SELECT - CAST( 21 AS SIGNED ) * col0 AS col0 FROM tab2 AS cor0
----
-147
-1638
-1659

skipif mysql # not compatible
query I rowsort label-2816
SELECT - CAST ( 21 AS INTEGER ) * col0 AS col0 FROM tab2 AS cor0
----
-147
-1638
-1659

query I rowsort
SELECT ALL + 25 AS col0 FROM tab1 cor0
----
25
25
25

query I rowsort
SELECT - 29 AS col1 FROM tab1
----
-29
-29
-29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * + col0 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + ( + cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 col1 FROM tab2
----
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 36 col1 FROM tab0
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col0 + - col1 * - col1 AS col2 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT + col1 + - col2 * - ( 52 ) FROM tab0 cor0
----
149
1802
4355

onlyif mysql # use DIV operator for integer division
query I rowsort label-2826
SELECT DISTINCT + ( col1 ) DIV + col0 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-2826
SELECT DISTINCT + ( col1 ) / + col0 FROM tab2 cor0
----
0
4

query I rowsort
SELECT + col1 + - col2 * col2 AS col0 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT + + 82 + + col0 * col2 * col0 FROM tab1 AS cor0
----
233554
568
614482

query I rowsort
SELECT ALL + 15 + col0 FROM tab1 AS cor0
----
18
79
95

query I rowsort
SELECT ALL + 81 AS col2 FROM tab0 AS cor0
----
81
81
81

query I rowsort
SELECT ALL - tab0.col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT + cor0.col2 FROM tab1, tab1 cor0, tab2, tab1 AS cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT ALL tab1.col2 * - 41 FROM tab1
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT 91 FROM tab1, tab0 AS cor0, tab1 cor1
----
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-2835
SELECT ALL 13 DIV - tab0.col2 - ( col0 * - col1 + 90 * + col0 ) FROM tab0
----
-96
232
89

skipif mysql # not compatible
query I rowsort label-2835
SELECT ALL 13 / - tab0.col2 - ( col0 * - col1 + 90 * + col0 ) FROM tab0
----
-96
232
89

query I rowsort
SELECT ALL - 51 + tab1.col2 - col2 AS col2 FROM tab1
----
-51
-51
-51

query I rowsort
SELECT ALL col2 + + tab0.col1 - + tab0.col1 FROM tab0
----
1
33
82

query I rowsort
SELECT - 79 + col0 AS col1 FROM tab1
----
-15
-76
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2839
SELECT - col0 * - col2 * col2 - + col1 DIV col2 FROM tab0 AS cor0
----
-62
26134
598435

skipif mysql # not compatible
query I rowsort label-2839
SELECT - col0 * - col2 * col2 - + col1 / col2 FROM tab0 AS cor0
----
-62
26134
598435

query I rowsort
SELECT + 21 * - col0 AS col0 FROM tab1 AS cor0
----
-1344
-1680
-63

query I rowsort
SELECT DISTINCT 64 + - col2 FROM tab1
----
-32
10
7

query I rowsort
SELECT - ( 36 ) * col0 FROM tab0 AS cor0
----
-1260
-3204
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 10 col0 FROM tab2 AS cor0
----
-10

query I rowsort
SELECT - col0 + + col1 + + col2 * + col0 AS col1 FROM tab2 AS cor0
----
2009
213
2940

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 21 col0 FROM tab1 AS cor0
----
21
21
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + col0 * col1 * - cor0.col2 col0 FROM tab0 AS cor0
----
-4620
-672039
-68688

query I rowsort
SELECT col0 * + ( + col1 ) * col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + col0 * + 57 + col2 FROM tab1
----
225
3705
4656

query I rowsort
SELECT - col2 + 61 * + tab2.col0 AS col1 FROM tab2
----
400
4732
4781

query I rowsort
SELECT cor0.col2 + col0 AS col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL - 15 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT - 63 + ( + col2 ) FROM tab1
----
-6
-9
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-2853
SELECT DISTINCT + 8 DIV col0 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-2853
SELECT DISTINCT + 8 / col0 AS col1 FROM tab0
----
0

query I rowsort
SELECT ALL cor0.col2 + col1 + col1 * col0 FROM tab0 AS cor0
----
2183
3493
8272

query I rowsort
SELECT ALL - col0 + - 47 AS col1 FROM tab1 AS cor0
----
-111
-127
-50

query I rowsort
SELECT DISTINCT col0 * + ( col0 ) + + 79 * cor0.col1 * col2 FROM tab2 AS cor0
----
127270
57275
66172

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 58 col1 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT ALL - 19 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-115
-73
-76

query I rowsort
SELECT - ( + 57 ) + + col2 FROM tab0 AS cor0
----
-24
-56
25

query I rowsort
SELECT DISTINCT - 80 AS col1 FROM tab1, tab2, tab1 AS cor0
----
-80

query I rowsort
SELECT DISTINCT + ( + col1 ) AS col2 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2862
SELECT ALL + - CAST( NULL AS DECIMAL ) * 87 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2862
SELECT ALL + - CAST ( NULL AS REAL ) * 87 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + ( - col1 ) * 24 AS col1 FROM tab2 AS cor0
----
-15504
-20088
-36816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2864
SELECT ALL + 72 + 34 DIV - col1 AS col0 FROM tab2 AS cor0
----
70
71
72

skipif mysql # not compatible
query I rowsort label-2864
SELECT ALL + 72 + 34 / - col1 AS col0 FROM tab2 AS cor0
----
70
71
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT 25 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2867
SELECT DISTINCT + - ( - col2 ) + - CAST( col1 AS SIGNED ) DIV - col0 AS col1 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-2867
SELECT DISTINCT + - ( - col2 ) + - CAST ( col1 AS INTEGER ) / - col0 AS col1 FROM tab2 AS cor0
----
26
31
38

query I rowsort
SELECT DISTINCT - + col0 * - cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - + 73 + - col2 AS col0 FROM tab1 AS cor0
----
-127
-130
-169

query I rowsort
SELECT ALL + 84 + col1 FROM tab2 AS cor0
----
101
115
143

query I rowsort
SELECT - + col0 * col0 + cor0.col1 * + col2 AS col0 FROM tab0 AS cor0
----
-1128
-459
2262

onlyif mysql # use DIV operator for integer division
query I rowsort label-2872
SELECT ALL + - col1 + + col1 * col1 DIV - 87 AS col0 FROM tab2 AS cor0
----
-20
-42
-99

skipif mysql # not compatible
query I rowsort label-2872
SELECT ALL + - col1 + + col1 * col1 / - 87 AS col0 FROM tab2 AS cor0
----
-20
-42
-99

query I rowsort
SELECT - - 57 * col2 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT 45 + 26 * col1 FROM tab1
----
305
383
721

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 20 * col0 col1 FROM tab0 AS cor0
----
-1780
-480
-700

query I rowsort
SELECT DISTINCT - + col0 - + col0 AS col0 FROM tab0 cor0
----
-178
-48
-70

query I rowsort
SELECT ALL + - cor0.col2 * - col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - - 9 AS col2 FROM tab0 AS cor0
----
9
9
9

query I rowsort
SELECT + + col1 + - col1 * + col2 + + col2 AS col2 FROM tab0 AS cor0
----
-2719
-7289
1

query I rowsort
SELECT - col0 * - 91 + + col2 + + col2 FROM tab1 AS cor0
----
381
5938
7472

onlyif mysql # use DIV operator for integer division
query I rowsort label-2881
SELECT DISTINCT - + col0 DIV ( + col1 ) col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2881
SELECT DISTINCT - + col0 / ( + col1 ) col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL tab1.col2 * ( + 37 ) + + col2 FROM tab1
----
2052
2166
3648

query I rowsort
SELECT col2 + - ( col2 ) * - col1 FROM tab1 AS cor0
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-2884
SELECT + col0 DIV + col0 - col2 AS col2 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-2884
SELECT + col0 / + col0 - col2 AS col2 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT DISTINCT - cor0.col0 + ( + col2 ) * col0 AS col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT + col1 + col2 * col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL - + col1 * + cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - - cor0.col1 - - col2 * - ( col2 * ( + cor0.col0 ) ) AS col2 FROM tab1 AS cor0
----
-207926
-737267
-8722

query I rowsort
SELECT col0 * 95 * + col2 + cor0.col1 AS col1 FROM tab0 cor0
----
3422
693401
75326

query I rowsort
SELECT col1 * col1 + 27 + col1 AS col1 FROM tab0 AS cor0
----
7509
8399
9533

query I rowsort
SELECT ALL - 60 - + col1 AS col1 FROM tab2 AS cor0
----
-119
-77
-91

query I rowsort
SELECT DISTINCT - - 72 AS col1 FROM tab0 AS cor0
----
72

query I rowsort
SELECT - - cor0.col2 * col1 + + col0 AS col1 FROM tab2 cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2894
SELECT ALL - + CAST( NULL AS SIGNED ) * - col1 * - cor0.col1 + - cor0.col2 * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2894
SELECT ALL - + CAST ( NULL AS INTEGER ) * - col1 * - cor0.col1 + - cor0.col2 * - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 - - col2 * + col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT col2 * col2 - + col1 * col0 AS col0 FROM tab1 cor0
----
2609
2838
8176

query I rowsort
SELECT - - col0 + 9 AS col0 FROM tab2 cor0
----
16
87
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2898
SELECT col1 * CAST( NULL AS SIGNED ) + col2 * tab2.col1 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2898
SELECT col1 * CAST ( NULL AS INTEGER ) + col2 * tab2.col1 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + col0 + col0 AS col1 FROM tab2
----
21
234
237

query I rowsort
SELECT + - col2 + col0 * col2 AS col1 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - col1 + cor0.col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2902
SELECT ALL col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2902
SELECT ALL col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 - - ( col0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + cor0.col1 * + 14 FROM tab2 AS cor0
----
238
434
826

onlyif mysql # use DIV operator for integer division
query I rowsort label-2905
SELECT + + col1 DIV col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2905
SELECT + + col1 / col1 FROM tab2 cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2906
SELECT - col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2906
SELECT - col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + 25 AS col0 FROM tab0 cor0
----
-57
-8
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - col2 - col0 * col0 col0 FROM tab1 AS cor0
----
-15616
-2925
-7345

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 18 + - col2 col2 FROM tab1 AS cor0
----
123
138
414

query I rowsort
SELECT - cor0.col2 * 95 FROM tab1, tab1 AS cor0
----
9 values hashing to 33b946f8d0ffc1b06b274930e2b28b79

query I rowsort
SELECT - 13 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 1c6aaa07ba8d3dc01ee616e16bef60f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 58 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT DISTINCT - col2 * col0 + col0 + + col2 FROM tab1
----
-105
-3527
-7504

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2915
SELECT - CAST( NULL AS DECIMAL ) AS col0 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2915
SELECT - CAST ( NULL AS REAL ) AS col0 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT col1 * + col0 + ( + 74 ) FROM tab2 AS cor0
----
1417
291
4676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2917
SELECT - 38 * - col0 DIV col0 AS col0 FROM tab1 AS cor0
----
38
38
38

skipif mysql # not compatible
query I rowsort label-2917
SELECT - 38 * - col0 / col0 AS col0 FROM tab1 AS cor0
----
38
38
38

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN NULL AND - col2 * + col2
----

query I rowsort
SELECT col0 + col2 * col2 - - col2 FROM tab1
----
2973
3370
9392

query I rowsort
SELECT ALL tab1.col0 + col2 * tab1.col0 AS col1 FROM tab1
----
165
3712
7760

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) <= col1
----

query I rowsort
SELECT + col0 + + col2 - + col1 AS col0 FROM tab1
----
111
163
31

query I rowsort
SELECT col2 + col0 + col2 FROM tab1
----
111
178
272

query I rowsort
SELECT DISTINCT + col1 + tab1.col0 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT + col0 * + 53 * - col0 AS col2 FROM tab0 AS cor0
----
-30528
-419813
-64925

query I rowsort
SELECT ALL ( + col2 ) * col2 AS col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT 25 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

onlyif mysql # use DIV operator for integer division
query I rowsort label-2928
SELECT DISTINCT + col2 DIV col2 + col1 AS col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2928
SELECT DISTINCT + col2 / col2 + col1 AS col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT DISTINCT + 18 * + col1 AS col2 FROM tab2 AS cor0
----
1062
306
558

query I rowsort
SELECT ALL - 99 * + col0 FROM tab1
----
-297
-6336
-7920

query I rowsort
SELECT col1 + 47 * + col2 FROM tab2 AS cor0
----
1281
1300
1803

query I rowsort
SELECT DISTINCT + tab1.col1 * + ( - col2 * + col0 + 94 ) FROM tab1
----
-1768
-35540
-98618

query I rowsort
SELECT + tab1.col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query IIIIIIIII rowsort
SELECT * FROM tab1, tab2, tab1 AS cor0 WHERE NULL < NULL
----

query I rowsort
SELECT col2 + - cor0.col2 AS col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2936
SELECT ALL + CAST( col0 AS SIGNED ) AS col2 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2936
SELECT ALL + CAST ( col0 AS INTEGER ) AS col2 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 4 * cor0.col2 col0 FROM tab1 AS cor0
----
-216
-228
-384

query I rowsort
SELECT ALL - ( + col1 + col1 ) FROM tab1
----
-20
-26
-52

query I rowsort
SELECT DISTINCT + 73 AS col0 FROM tab1, tab1 AS cor0
----
73

query I rowsort
SELECT + ( cor0.col2 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT - 18 + + col1 FROM tab2 AS cor0
----
-1
13
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-2942
SELECT - 30 + col2 DIV - 57 + - col1 * + cor0.col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-22861
-271548
-6757

skipif mysql # not compatible
query I rowsort label-2942
SELECT - 30 + col2 / - 57 + - col1 * + cor0.col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-22861
-271548
-6757

query I rowsort
SELECT ALL - 76 FROM tab0, tab2 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT - col0 * col0 + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT + col1 + + col1 * - col0 FROM tab1
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 * + col2 col0 FROM tab0 cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - col2 + - col1 * + cor0.col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT - + col0 * + col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - - col1 * - col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL - col2 * + col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2952
SELECT DISTINCT col2 * col2 + + col2 + col2 DIV cor0.col0 FROM tab1 AS cor0
----
2988
3306
9313

skipif mysql # not compatible
query I rowsort label-2952
SELECT DISTINCT col2 * col2 + + col2 + col2 / cor0.col0 FROM tab1 AS cor0
----
2988
3306
9313

query I rowsort
SELECT DISTINCT - - col2 + + col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2954
SELECT DISTINCT - col1 DIV - col1 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-2954
SELECT DISTINCT - col1 / - col1 FROM tab2
----
1

query I rowsort
SELECT tab1.col1 + + tab1.col1 * tab1.col1 FROM tab1
----
110
182
702

query I rowsort
SELECT ALL + col0 * tab0.col1 * col0 AS col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT + - cor0.col1 + col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - - col0 * cor0.col1 + col1 AS col2 FROM tab1 cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + + col1 col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2960
SELECT DISTINCT - + col1 DIV col1 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2960
SELECT DISTINCT - + col1 / col1 AS col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL + 19 * col0 AS col1 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT DISTINCT + - ( - col1 ) * col2 + col2 * col2 FROM tab1 cor0
----
10464
3819
4320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2963
SELECT + col1 DIV col2 + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2963
SELECT + col1 / col2 + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - 19 * + cor0.col2 * cor0.col1 + - col2 + cor0.col0 FROM tab0 AS cor0
----
-141771
-1809
-53931

query I rowsort
SELECT cor0.col0 + col1 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2966
SELECT ALL - - col0 DIV + col0 + - cor0.col2 * + col2 * col2 FROM tab0 AS cor0
----
-35936
-551367
0

skipif mysql # not compatible
query I rowsort label-2966
SELECT ALL - - col0 / + col0 + - cor0.col2 * + col2 * col2 FROM tab0 AS cor0
----
-35936
-551367
0

query I rowsort
SELECT - col1 * col0 + col1 AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + 58 AS col0 FROM tab0
----
58
58
58

query I rowsort
SELECT ( 92 ) * + col1 FROM tab0
----
7912
8372
8924

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - cor0.col0 + - cor0.col0 col2 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL + 33 + - col0 FROM tab2
----
-45
-46
26

query I rowsort
SELECT + 54 * + col0 FROM tab0 AS cor0
----
1296
1890
4806

query I rowsort
SELECT ALL + col1 + col1 + + tab0.col1 FROM tab0
----
258
273
291

query I rowsort
SELECT ALL + col2 + col0 + col1 FROM tab2
----
134
163
65

query I rowsort
SELECT col1 * col1 + col1 * + col2 + + col2 * col2 FROM tab0
----
11323
22467
9507

query I rowsort
SELECT col1 * col0 * + tab2.col0 AS col1 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + col2 + col2 * col2 * + col2 FROM tab0
----
2
35970
551450

query I rowsort
SELECT ALL - col1 + - col2 + + col0 AS col2 FROM tab0
----
-63
-84
-95

query I rowsort
SELECT DISTINCT + col1 + col1 + col0 AS col2 FROM tab0
----
196
229
271

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT DISTINCT col1 * + col0 * col2 AS col1 FROM tab1 WHERE NOT NULL IN ( col2 * - col0 )
----

query I rowsort
SELECT DISTINCT - col2 * + col0 + col2 FROM tab2 WHERE NOT - col2 + col2 <> NULL
----

query I rowsort
SELECT DISTINCT - col2 + tab2.col2 * - col0 * col2 + col0 AS col1 FROM tab2
----
-114035
-5123
-52676

query I rowsort
SELECT tab0.col1 * - col0 - col1 * col1 AS col1 FROM tab0
----
-12804
-16380
-9460

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 col0 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2986
SELECT DISTINCT col1 DIV + col0 - col2 AS col2 FROM tab2
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-2986
SELECT DISTINCT col1 / + col0 - col2 AS col2 FROM tab2
----
-23
-26
-38

query I rowsort
SELECT DISTINCT - tab2.col0 * tab2.col1 AS col0 FROM tab2
----
-1343
-217
-4602

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) IN ( - tab0.col0 )
----

query I rowsort
SELECT + col2 * + col1 * col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - tab2.col2 * - col1 AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 * col2 * col0 AS col1 FROM tab2
----
114076
5103
52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 col2 FROM tab2 WHERE NULL BETWEEN ( + col2 ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col2 col2 FROM tab2
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col2 * tab2.col1 col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + col1 * col1 + tab2.col0 FROM tab2
----
3559
368
968

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col2 ) NOT IN ( - col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT col2 FROM tab2 WHERE ( col2 ) < - col2 + + col0
----
26
38

query I rowsort
SELECT + col1 * + col2 + col2 AS col0 FROM tab1
----
1344
1458
627

query I rowsort
SELECT tab1.col2 * + col1 + col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL + tab0.col1 + tab0.col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT + tab0.col1 + - col1 AS col0 FROM tab0
----
0

query I rowsort
SELECT - col1 - - col2 AS col2 FROM tab1
----
28
47
83

query I rowsort
SELECT col0 * - tab0.col2 + col1 * - col2 AS col1 FROM tab0
----
-132
-14760
-3630

query I rowsort
SELECT DISTINCT - col1 - - col1 AS col1 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3005
SELECT + col1 DIV col0 + tab2.col2 FROM tab2
----
26
31
38

skipif mysql # not compatible
query I rowsort label-3005
SELECT + col1 / col0 + tab2.col2 FROM tab2
----
26
31
38

query I rowsort
SELECT - col2 + - col0 * - tab2.col0 AS col2 FROM tab2
----
22
6058
6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-3007
SELECT DISTINCT + col1 DIV + tab1.col1 - - col2 AS col1 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-3007
SELECT DISTINCT + col1 / + tab1.col1 - - col2 AS col1 FROM tab1
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3008
SELECT ALL + col0 + col1 DIV - cor0.col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-3008
SELECT ALL + col0 + col1 / - cor0.col0 FROM tab0 AS cor0
----
21
33
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + col2 * col0 col1 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT col2 * - cor0.col0 * col2 + col2 AS col1 FROM tab2 AS cor0
----
-114038
-5076
-52702

query I rowsort
SELECT DISTINCT col2 * col2 * + col1 + + col2 * + col1 AS col2 FROM tab2 AS cor0
----
23436
25194
41418

query I rowsort
SELECT cor0.col1 + col0 * + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL + tab2.col1 - - col1 * + tab2.col2 FROM tab2
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 + - col0 + + col0 col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT col1 + - col2 - + col0 AS col2 FROM tab2
----
-100
-3
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3017
SELECT DISTINCT + col2 DIV 69 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-3017
SELECT DISTINCT + col2 / 69 FROM tab2
----
0

query I rowsort
SELECT DISTINCT 37 AS col1 FROM tab0
----
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3019
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - 76 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3019
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - 76 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 * + cor0.col2 * + col0 - 37 FROM tab0 AS cor0
----
-2
26099
598399

query I rowsort
SELECT ALL + 60 * 28 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 99af47aca8e06400dbe2d90a51050ca4

query I rowsort
SELECT + 72 + cor0.col1 FROM tab1 cor0
----
82
85
98

query I rowsort
SELECT - col1 * + col0 + + 35 AS col0 FROM tab1 AS cor0
----
-1005
-43
-605

query I rowsort
SELECT DISTINCT - tab2.col2 AS col2 FROM tab2, tab0 cor0
----
-26
-27
-38

query I rowsort
SELECT - col0 * + col1 + - 50 FROM tab1 AS cor0
----
-1090
-128
-690

query I rowsort
SELECT + - ( col1 ) + - 75 FROM tab0 AS cor0
----
-161
-166
-172

query I rowsort
SELECT col0 * col1 + + col0 * - col0 FROM tab2 cor0
----
-1482
-4898
168

query I rowsort
SELECT + 38 AS col1 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT - - col2 + ( - col0 ) AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + col0 * ( - ( col1 ) ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3031
SELECT - + col2 + + CAST( - col0 + col2 * 68 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1664
1802
2467

skipif mysql # not compatible
query I rowsort label-3031
SELECT - + col2 + + CAST ( - col0 + col2 * 68 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1664
1802
2467

query I rowsort
SELECT ALL + - col1 - + cor0.col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - + col0 * + col2 + + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3034
SELECT DISTINCT + col1 * CAST( + col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-3034
SELECT DISTINCT + col1 * CAST ( + col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + col1 * ( - col0 ) AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3036
SELECT - CAST( NULL AS SIGNED ) + + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3036
SELECT - CAST ( NULL AS INTEGER ) + + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col0 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT - - 22 * + 66 + col1 + + col2 FROM tab0 cor0
----
1550
1571
1625

query I rowsort
SELECT + - ( - 28 ) AS col2 FROM tab2 AS cor0
----
28
28
28

query I rowsort
SELECT - col2 + col1 * col1 AS col2 FROM tab1 cor0
----
43
622
73

query I rowsort
SELECT DISTINCT 33 + - col2 * + col0 FROM tab0 AS cor0
----
-2
-7265
-759

query I rowsort
SELECT DISTINCT + 55 * - col0 AS col0 FROM tab2 AS cor0
----
-385
-4290
-4345

query I rowsort
SELECT ALL - 47 + col2 * - col2 FROM tab2 cor0
----
-1491
-723
-776

query I rowsort
SELECT col2 * + 96 + - col1 FROM tab1 AS cor0
----
5158
5462
9203

query I rowsort
SELECT DISTINCT + col0 * + 41 FROM tab0 AS cor0
----
1435
3649
984

onlyif mysql # use DIV operator for integer division
query I rowsort label-3046
SELECT DISTINCT + + 3 DIV col0 col0 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3046
SELECT DISTINCT + + 3 / col0 col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT cor0.col0 + - cor0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + 67 * + col2 AS col1 FROM tab2 AS cor0
----
1742
1809
2546

query I rowsort
SELECT ALL - col1 + - col1 * - col1 AS col2 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT ALL 96 FROM tab1, tab1 cor0 CROSS JOIN tab2
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3051
SELECT CAST( - 40 + col2 AS SIGNED ) FROM tab1
----
14
17
56

skipif mysql # not compatible
query I rowsort label-3051
SELECT CAST ( - 40 + col2 AS INTEGER ) FROM tab1
----
14
17
56

query I rowsort
SELECT - - 1 FROM tab1, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT + col0 * - cor0.col0 - + col2 AS col1 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT - + col0 * - ( col0 ) + col1 + - ( cor0.col0 + - col0 ) FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-3055
SELECT - col1 + - col2 DIV col2 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-3055
SELECT - col1 + - col2 / col2 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT - + cor0.col2 + col2 * - col1 * + col2 AS col0 FROM tab0 AS cor0
----
-611966
-93687
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3057
SELECT tab2.col1 + CAST( NULL AS DECIMAL ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3057
SELECT tab2.col1 + CAST ( NULL AS REAL ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT 76 + - col1 + - col0 AS col1 FROM tab2
----
-20
-61
38

query I rowsort
SELECT ALL cor0.col0 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + col2 * ( - col0 ) FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col2 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col0 * - ( 63 ) FROM tab1
----
-189
-4032
-5040

query I rowsort
SELECT ALL + col1 + + 46 - 72 * col2 * tab2.col0 FROM tab2
----
-13531
-145911
-216081

query I rowsort
SELECT col1 + - col1 * 35 - + col0 FROM tab0
----
-2948
-3183
-3333

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3065
SELECT DISTINCT + col0 - CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3065
SELECT DISTINCT + col0 - CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3066
SELECT ALL 46 * col1 * CAST( NULL AS SIGNED ) + + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3066
SELECT ALL 46 * col1 * CAST ( NULL AS INTEGER ) + + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 66 * - col0 + 81 AS col2 FROM tab1
----
-117
-4143
-5199

query I rowsort
SELECT ALL - 89 * col0 + col0 FROM tab0
----
-2112
-3080
-7832

query I rowsort
SELECT - col0 * + col2 + 85 AS col2 FROM tab2 AS cor0
----
-104
-1943
-2917

query I rowsort
SELECT 38 * + col0 + 83 AS col1 FROM tab0 AS cor0
----
1413
3465
995

query I rowsort
SELECT ALL - ( + col2 ) * col0 * 39 AS col2 FROM tab2 AS cor0
----
-117078
-7371
-79092

query I rowsort
SELECT DISTINCT + col2 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL + 71 + - col1 * 36 FROM tab1
----
-289
-397
-865

onlyif mysql # use DIV operator for integer division
query I rowsort label-3074
SELECT DISTINCT + cor0.col2 + + col0 + 38 DIV col1 col2 FROM tab2 AS cor0
----
104
119
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3074
SELECT DISTINCT + cor0.col2 + + col0 + 38 / col1 col2 FROM tab2 AS cor0
----
104
119
35

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab0 cor1, tab1, tab2 cor2
----
3645 values hashing to d6394df0309139ffe20e7d96c77e26ee

query I rowsort
SELECT + - col1 * - col0 + + col1 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL + col0 * cor0.col1 + + col2 * - col2 FROM tab1 AS cor0
----
-2609
-2838
-8176

query I rowsort
SELECT + 82 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT ALL col2 * - 60 FROM tab0
----
-1980
-4920
-60

query I rowsort
SELECT DISTINCT col0 * + ( tab2.col1 ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT col0 * - col0 + + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3082
SELECT DISTINCT - col2 - CAST( NULL AS SIGNED ) * - col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3082
SELECT DISTINCT - col2 - CAST ( NULL AS INTEGER ) * - col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col0 + 12 * - 43 AS col2 FROM tab2 AS cor0
----
-437
-438
-509

onlyif mysql # use DIV operator for integer division
query I rowsort label-3084
SELECT ALL + col1 DIV + col1 + + col0 col2 FROM tab1 AS cor0
----
4
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3084
SELECT ALL + col1 / + col1 + + col0 col2 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3085
SELECT DISTINCT - + col2 * + col0 - - col1 DIV col2 AS col1 FROM tab0 AS cor0
----
-7297
-790
62

skipif mysql # not compatible
query I rowsort label-3085
SELECT DISTINCT - + col2 * + col0 - - col1 / col2 AS col1 FROM tab0 AS cor0
----
-7297
-790
62

query I rowsort
SELECT ( + 9 ) + cor0.col1 AS col2 FROM tab2 AS cor0
----
26
40
68

query I rowsort
SELECT ALL - 25 - col0 FROM tab2
----
-103
-104
-32

query I rowsort
SELECT col1 + col1 + col0 * + ( col1 ) FROM tab1
----
1066
130
660

query I rowsort
SELECT - 80 + 79 + - col0 * tab2.col1 FROM tab2
----
-1344
-218
-4603

query I rowsort
SELECT DISTINCT - tab1.col0 FROM tab1, tab0 cor0, tab0 AS cor1
----
-3
-64
-80

query I rowsort
SELECT - tab1.col2 + - 91 AS col2 FROM tab1
----
-145
-148
-187

onlyif mysql # use DIV operator for integer division
query I rowsort label-3092
SELECT + col2 DIV - col1 + + col2 * - 44 FROM tab2
----
-1144
-1188
-1674

skipif mysql # not compatible
query I rowsort label-3092
SELECT + col2 / - col1 + + col2 * - 44 FROM tab2
----
-1144
-1188
-1674

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3093
SELECT ALL CAST( - col0 AS SIGNED ) * col0 AS col1 FROM tab1 cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-3093
SELECT ALL CAST ( - col0 AS INTEGER ) * col0 AS col1 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - 57 * - col2 FROM tab2 cor0
----
1482
1539
2166

query I rowsort
SELECT - - col0 * - 50 AS col1 FROM tab1 AS cor0
----
-150
-3200
-4000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3096
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * - col2 + + col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3096
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * - col2 + + col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - ( + cor0.col2 ) + col2 * - ( col2 + - col1 ) AS col1 FROM tab1 AS cor0
----
-1566
-2736
-8064

query I rowsort
SELECT 79 * + 67 FROM tab2 AS cor0
----
5293
5293
5293

query I rowsort
SELECT cor0.col2 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - - col1 + col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col0 * col0 - - col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT - - col0 + col2 * col1 AS col2 FROM tab0 AS cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col2 ) col1 FROM tab2 cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3104
SELECT DISTINCT col0 DIV col1 + 99 AS col0 FROM tab2 AS cor0
----
100
103
99

skipif mysql # not compatible
query I rowsort label-3104
SELECT DISTINCT col0 / col1 + 99 AS col0 FROM tab2 AS cor0
----
100
103
99

query I rowsort
SELECT + 22 * col0 AS col1 FROM tab2 AS cor0
----
154
1716
1738

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3106
SELECT ALL - - ( - cor0.col1 ) * CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-3106
SELECT ALL - - ( - cor0.col1 ) * CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3107
SELECT DISTINCT - 55 DIV col0 + - 96 AS col1 FROM tab0 AS cor0
----
-96
-97
-98

skipif mysql # not compatible
query I rowsort label-3107
SELECT DISTINCT - 55 / col0 + - 96 AS col1 FROM tab0 AS cor0
----
-96
-97
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3108
SELECT - col2 + col0 * ( col0 ) DIV - col0 FROM tab2 cor0
----
-104
-117
-34

skipif mysql # not compatible
query I rowsort label-3108
SELECT - col2 + col0 * ( col0 ) / - col0 FROM tab2 cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3109
SELECT ALL ( col0 ) + - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3109
SELECT ALL ( col0 ) + - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col0 - - col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - + col1 * - col0 * + col1 + 49 FROM tab2 AS cor0
----
22880
271567
6776

onlyif mysql # use DIV operator for integer division
query I rowsort label-3112
SELECT + cor0.col2 + + col0 DIV + col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3112
SELECT + cor0.col2 + + col0 / + col1 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL 71 FROM tab1, tab0 cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT DISTINCT col2 - ( + col2 ) AS col0 FROM tab1
----
0

query I rowsort
SELECT DISTINCT tab1.col1 * - 11 AS col1 FROM tab1
----
-110
-143
-286

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 2 col2 FROM tab2
----
-2
-2
-2

query I rowsort
SELECT DISTINCT - cor0.col0 * col0 + + 17 FROM tab1 AS cor0
----
-4079
-6383
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3118
SELECT + ( - col2 ) DIV + col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3118
SELECT + ( - col2 ) / + col2 FROM tab1
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3119
SELECT DISTINCT col2 + + tab2.col1 - tab2.col1 / CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-3119
SELECT DISTINCT col2 + + tab2.col1 - tab2.col1 / CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3120
SELECT col1 DIV + tab0.col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3120
SELECT col1 / + tab0.col1 FROM tab0
----
1
1
1

query I rowsort
SELECT - - cor0.col2 + + col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3122
SELECT + 77 * col0 DIV + col0 AS col1 FROM tab2 AS cor0
----
77
77
77

skipif mysql # not compatible
query I rowsort label-3122
SELECT + 77 * col0 / + col0 AS col1 FROM tab2 AS cor0
----
77
77
77

query I rowsort
SELECT - - 70 + - cor0.col1 * - col1 + 77 AS col2 FROM tab1 AS cor0
----
247
316
823

onlyif mysql # use DIV operator for integer division
query I rowsort label-3124
SELECT DISTINCT tab1.col0 * - col1 + tab1.col1 DIV - 53 AS col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3124
SELECT DISTINCT tab1.col0 * - col1 + tab1.col1 / - 53 AS col0 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3125
SELECT DISTINCT + 11 * col0 DIV + 67 + - tab2.col0 * + col0 FROM tab2
----
-48
-6072
-6229

skipif mysql # not compatible
query I rowsort label-3125
SELECT DISTINCT + 11 * col0 / + 67 + - tab2.col0 * + col0 FROM tab2
----
-48
-6072
-6229

onlyif mysql # use DIV operator for integer division
query I rowsort label-3126
SELECT 61 DIV + col2 AS col1 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3126
SELECT 61 / + col2 AS col1 FROM tab1
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3127
SELECT col1 * cor0.col0 + + col2 DIV cor0.col0 FROM tab2 AS cor0
----
1343
220
4602

skipif mysql # not compatible
query I rowsort label-3127
SELECT col1 * cor0.col0 + + col2 / cor0.col0 FROM tab2 AS cor0
----
1343
220
4602

query I rowsort
SELECT + cor0.col0 * col0 + + col1 FROM tab2 cor0
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * col1 * - 67 + - ( col2 ) col1 FROM tab1
----
-38247
-83712
-94122

query I rowsort
SELECT - col1 * col1 + + col1 * col1 * col1 AS col1 FROM tab2
----
201898
28830
4624

onlyif mysql # use DIV operator for integer division
query I rowsort label-3131
SELECT DISTINCT ( + col0 ) DIV + col2 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-3131
SELECT DISTINCT ( + col0 ) / + col2 FROM tab1
----
0
1

query I rowsort
SELECT DISTINCT col1 + col0 + 58 * tab0.col1 AS col1 FROM tab0
----
5098
5458
5758

query I rowsort
SELECT DISTINCT col2 * col1 + ( + col2 ) FROM tab0
----
2871
7544
98

query I rowsort
SELECT - + col2 * - col0 * col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3135
SELECT - col0 DIV ( 52 ) - col2 * col2 AS col2 FROM tab0
----
-1
-1089
-6725

skipif mysql # not compatible
query I rowsort label-3135
SELECT - col0 / ( 52 ) - col2 * col2 AS col2 FROM tab0
----
-1
-1089
-6725

onlyif mysql # use DIV operator for integer division
query I rowsort label-3136
SELECT col1 + col1 * col2 DIV - tab1.col0 AS col1 FROM tab1
----
-2
-442
2

skipif mysql # not compatible
query I rowsort label-3136
SELECT col1 + col1 * col2 / - tab1.col0 AS col1 FROM tab1
----
-2
-442
2

query I rowsort
SELECT ALL + + 27 + col0 FROM tab0 AS cor0
----
116
51
62

query I rowsort
SELECT + col0 * - 9 FROM tab1 AS cor0
----
-27
-576
-720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 6 * + col2 col2 FROM tab0 AS cor0
----
198
492
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + - col0 * col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3142
SELECT - col0 * - col1 + 21 DIV col1 FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-3142
SELECT - col0 * - col1 + 21 / col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + 80 FROM tab1 AS cor0
----
80

query I rowsort
SELECT ALL - + col1 * + ( + col1 ) FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + 25 * + col2 FROM tab0 AS cor0
----
2050
25
825

query I rowsort
SELECT ALL 10 * col0 AS col1 FROM tab1 AS cor0
----
30
640
800

query I rowsort
SELECT 28 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
1117
29
6752

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3148
SELECT CAST( ( col1 ) AS SIGNED ) AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3148
SELECT CAST ( ( col1 ) AS INTEGER ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + col0 + 2 * col2 FROM tab2 cor0
----
-26
-3
47

query I rowsort
SELECT DISTINCT - ( - col0 ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3151
SELECT - 4 DIV - ( col2 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3151
SELECT - 4 / - ( col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 6 * 70 + col1 AS col0 FROM tab2 cor0
----
-361
-389
-403

query I rowsort
SELECT tab0.col0 * col1 + - 78 * - col2 AS col0 FROM tab0
----
14495
3473
4638

query I rowsort
SELECT DISTINCT + col0 * - 74 AS col2 FROM tab0
----
-1776
-2590
-6586

query I rowsort
SELECT - tab1.col0 * ( - col0 ) + col0 * - 24 AS col2 FROM tab1
----
-63
2560
4480

query I rowsort
SELECT - cor0.col0 * + 12 FROM tab0 AS cor0
----
-1068
-288
-420

query I rowsort
SELECT ALL 27 * - 78 FROM tab0, tab2 AS cor0
----
9 values hashing to 77740b18bf2138f5ff9f6dd864ee01ef

query I rowsort
SELECT ALL - - col0 * col2 + 65 AS col0 FROM tab1 AS cor0
----
227
3713
7745

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * cor0.col0 * col1 col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT - col1 + col2 * + col2 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT DISTINCT cor0.col2 - 92 AS col1 FROM tab0 AS cor0
----
-10
-59
-91

query I rowsort
SELECT ALL - col1 * + 40 FROM tab2 AS cor0
----
-1240
-2360
-680

query I rowsort
SELECT - col2 * + ( cor0.col0 ) + - cor0.col0 * + col1 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT - 91 + ( - col1 * ( col1 ) ) AS col1 FROM tab2 AS cor0
----
-1052
-3572
-380

query I rowsort
SELECT ALL cor0.col2 * + cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3166
SELECT col1 DIV - col0 + col2 AS col0 FROM tab2 cor0
----
23
26
38

skipif mysql # not compatible
query I rowsort label-3166
SELECT col1 / - col0 + col2 AS col0 FROM tab2 cor0
----
23
26
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( ( + col1 ) ) * - col1 * cor0.col1 + col1 col2 FROM tab0 AS cor0
----
-635970
-753480
-912576

query I rowsort
SELECT DISTINCT - 88 * + col1 AS col0 FROM tab0 AS cor0
----
-7568
-8008
-8536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3169
SELECT + + col0 * col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3169
SELECT + + col0 * col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 86 * - col0 AS col0 FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT - 2 + - col0 AS col2 FROM tab1 AS cor0
----
-5
-66
-82

query I rowsort
SELECT + - 60 + col1 FROM tab0 AS cor0
----
26
31
37

query I rowsort
SELECT ( 51 ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 86 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col1 col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col0 + col1 * ( ( col2 ) + 55 ) AS col2 FROM tab1 AS cor0
----
1056
1883
2831

query I rowsort
SELECT + col2 + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT + col0 + 83 * - col0 AS col2 FROM tab0 AS cor0
----
-1968
-2870
-7298

query I rowsort
SELECT + col2 + + 92 AS col1 FROM tab2 AS cor0
----
118
119
130

query I rowsort
SELECT ALL + col1 * + col0 - cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
-620
3068
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 39 col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT + ( col0 ) * - col0 AS col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT ALL - + col1 - col2 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT col1 + + col0 * + tab2.col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT + 3 * - col1 AS col1 FROM tab2 cor0
----
-177
-51
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - 43 ) col1 FROM tab1 cor0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3187
SELECT DISTINCT tab2.col0 * - 75 + col0 DIV ( col0 ) FROM tab2
----
-524
-5849
-5924

skipif mysql # not compatible
query I rowsort label-3187
SELECT DISTINCT tab2.col0 * - 75 + col0 / ( col0 ) FROM tab2
----
-524
-5849
-5924

query I rowsort
SELECT + col1 * tab1.col0 + + col1 AS col0 FROM tab1
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-3189
SELECT + 61 * 83 DIV - col1 AS col1 FROM tab0
----
-52
-55
-58

skipif mysql # not compatible
query I rowsort label-3189
SELECT + 61 * 83 / - col1 AS col1 FROM tab0
----
-52
-55
-58

query I rowsort
SELECT ALL - col2 + 29 AS col1 FROM tab2
----
-9
2
3

query I rowsort
SELECT DISTINCT - ( ( - col2 ) ) * - col0 + tab0.col2 AS col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT - 53 * col0 - 21 FROM tab1 AS cor0
----
-180
-3413
-4261

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 - col0 * col1 AS col0 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT + 85 - - col1 FROM tab1 AS cor0
----
111
95
98

query I rowsort
SELECT ( col1 ) * - col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL + ( - 20 ) FROM tab1
----
-20
-20
-20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 48 * + col1 col0 FROM tab1
----
-1248
-480
-624

onlyif mysql # use DIV operator for integer division
query I rowsort label-3198
SELECT col1 * col2 + - col0 DIV col2 AS col0 FROM tab0 cor0
----
2838
62
7461

skipif mysql # not compatible
query I rowsort label-3198
SELECT col1 * col2 + - col0 / col2 AS col0 FROM tab0 cor0
----
2838
62
7461

query I rowsort
SELECT col2 * - col2 + col0 + + ( + 62 + + col2 ) * ( 38 ) * + cor0.col0 AS col0 FROM tab2 AS cor0
----
22952
260234
298835

query I rowsort
SELECT DISTINCT - + 75 AS col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
-75

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 4634d10e8b6b37510bb99745aade36ab

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab1, tab2 cor1, tab0 AS cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

onlyif mysql # use DIV operator for integer division
query I rowsort label-3203
SELECT ( - col1 ) + col1 DIV ( + col1 ) AS col2 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3203
SELECT ( - col1 ) + col1 / ( + col1 ) AS col2 FROM tab0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3204
SELECT col0 DIV - col0 + - col1 AS col2 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-3204
SELECT col0 / - col0 + - col1 AS col2 FROM tab1
----
-11
-14
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-3205
SELECT DISTINCT - col0 DIV - 77 + col1 FROM tab2
----
18
31
60

skipif mysql # not compatible
query I rowsort label-3205
SELECT DISTINCT - col0 / - 77 + col1 FROM tab2
----
18
31
60

query I rowsort
SELECT ALL 8 + + col0 AS col2 FROM tab0
----
32
43
97

query I rowsort
SELECT - 16 AS col1 FROM tab2 cor0
----
-16
-16
-16

query I rowsort
SELECT ALL ( + cor0.col1 ) FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col1 ) + tab2.col1 col1 FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3210
SELECT DISTINCT ( col1 ) DIV - col1 + - col1 AS col2 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-3210
SELECT DISTINCT ( col1 ) / - col1 + - col1 AS col2 FROM tab0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab2, tab1 AS cor0
----
47

query I rowsort
SELECT DISTINCT + + col0 + cor0.col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + 16 * col1 + + col2 FROM tab1 AS cor0
----
217
304
470

query I rowsort
SELECT + - col0 + - 7 * - cor0.col2 FROM tab0 AS cor0
----
-28
207
485

query I rowsort
SELECT + + cor0.col0 + 58 AS col2 FROM tab1 cor0
----
122
138
61

query I rowsort
SELECT ALL - 43 * cor0.col0 + col1 * + 93 AS col2 FROM tab2 AS cor0
----
-1816
2133
2582

query I rowsort
SELECT ALL - + col0 * + cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col2 + - 4 FROM tab0 AS cor0
----
-3
29
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 48 col0 FROM tab0
----
48
48
48

query I rowsort
SELECT + - col0 * cor0.col1 AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + 52 * - col0 FROM tab2
----
-364
-4056
-4108

query I rowsort
SELECT + col0 * 63 FROM tab0 AS cor0
----
1512
2205
5607

query I rowsort
SELECT ALL - col0 * - col1 + col2 + col0 FROM tab2 AS cor0
----
1460
251
4706

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 72 * + col1 * - col1 col0 FROM tab0 AS cor0
----
-532488
-596143
-677413

query I rowsort
SELECT ALL + col0 * 87 FROM tab0 AS cor0
----
2088
3045
7743

query I rowsort
SELECT col1 + + col0 - col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + col2 + + col0 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL col0 - + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT - - 14 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

query I rowsort
SELECT DISTINCT + cor0.col2 - + col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3231
SELECT DISTINCT - - col0 DIV - cor0.col1 + - col1 + - col1 AS col2 FROM tab0 cor0
----
-172
-182
-194

skipif mysql # not compatible
query I rowsort label-3231
SELECT DISTINCT - - col0 / - cor0.col1 + - col1 + - col1 AS col2 FROM tab0 cor0
----
-172
-182
-194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3232
SELECT ALL col1 + CAST( col0 AS SIGNED ) * col2 + 92 FROM tab2 AS cor0
----
2179
3111
312

skipif mysql # not compatible
query I rowsort label-3232
SELECT ALL col1 + CAST ( col0 AS INTEGER ) * col2 + 92 FROM tab2 AS cor0
----
2179
3111
312

query I rowsort
SELECT col0 * - col0 * + col0 + col0 FROM tab1
----
-24
-262080
-511920

query I rowsort
SELECT DISTINCT - - col0 + + 20 * + col0 FROM tab1 AS cor0
----
1344
1680
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3235
SELECT + CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3235
SELECT + CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 14 + - 11 AS col0 FROM tab2 cor0
----
-25
-25
-25

query I rowsort
SELECT DISTINCT - col0 * + 50 + col2 * + col1 FROM tab0 AS cor0
----
-1653
1638
3012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + 73 * + col0 + col0 AS col1 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT + + col1 * col1 + - col2 AS col0 FROM tab0 cor0
----
7363
8199
9408

query I rowsort
SELECT + + ( + col1 ) - col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + ( col1 ) + + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + + col2 + + cor0.col0 * col0 - - col0 FROM tab0 AS cor0
----
1261
633
8092

query I rowsort
SELECT col0 + col1 * + col1 AS col2 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT + 83 * cor0.col1 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to aa672f99571022f49f1c373e5901fa03

query I rowsort
SELECT + 37 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT + col1 + ( col2 ) * col0 AS col1 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT ALL + cor0.col2 * - col1 * col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + 24 * - col0 AS col2 FROM tab1 AS cor0
----
-1536
-1920
-72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3250
SELECT col2 * + cor0.col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3250
SELECT col2 * + cor0.col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 24 * col2 FROM tab1 AS cor0
----
-1296
-1368
-2304

query I rowsort
SELECT DISTINCT col2 * col1 * - col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL - + col2 * col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT 85 * col2 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT DISTINCT col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col0 * - col2 col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + 17 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-1632
-918
-969

query I rowsort
SELECT DISTINCT ( col1 ) * - col0 + - tab1.col1 FROM tab1
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT + tab1.col2 + + col2 FROM tab1
----
108
114
192

query I rowsort
SELECT - cor0.col0 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT ( col1 ) * - cor0.col1 + col1 + - col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL 37 + tab1.col2 + col1 FROM tab1
----
104
117
146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - - col1 * col0 col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL + - col1 * cor0.col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - - 83 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
161
162
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3266
SELECT + col0 DIV col1 col0 FROM tab1 cor0
----
0
6
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3266
SELECT + col0 / col1 col0 FROM tab1 cor0
----
0
6
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3267
SELECT ALL col1 * + col1 + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
157
265
730

skipif mysql # not compatible
query I rowsort label-3267
SELECT ALL col1 * + col1 + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
157
265
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-3268
SELECT + col1 + - col0 DIV + cor0.col1 AS col2 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-3268
SELECT + col1 + - col0 / + cor0.col1 AS col2 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT + ( - cor0.col1 ) + - cor0.col1 * - col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT 86 + - col0 + col0 FROM tab0 AS cor0
----
86
86
86

query I rowsort
SELECT + cor0.col2 + cor0.col1 * + 46 AS col2 FROM tab2 AS cor0
----
1453
2740
820

query I rowsort
SELECT + col1 * col2 + cor0.col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - cor0.col0 + col1 + col1 * - col0 FROM tab1 AS cor0
----
-1107
-55
-694

query I rowsort
SELECT - - col1 + 58 * - col2 AS col2 FROM tab0 cor0
----
-1828
-4665
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-3275
SELECT ALL tab2.col2 DIV - 35 FROM tab2, tab2 cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-3275
SELECT ALL tab2.col2 / - 35 FROM tab2, tab2 cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col2 * ( col0 ) col2 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT 12 AS col1 FROM tab1
----
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3278
SELECT + col2 * + tab2.col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3278
SELECT + col2 * + tab2.col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - tab1.col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT col0 + - col0 * - col1 AS col0 FROM tab0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-3281
SELECT ALL tab2.col0 DIV col0 + col0 + - col2 FROM tab2
----
-19
42
53

skipif mysql # not compatible
query I rowsort label-3281
SELECT ALL tab2.col0 / col0 + col0 + - col2 FROM tab2
----
-19
42
53

query I rowsort
SELECT ALL col2 * tab1.col1 + col0 + col1 * - tab1.col2 * col2 FROM tab1
----
-118480
-31856
-74409

query I rowsort
SELECT col2 * col1 * col1 AS col1 FROM tab0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 + tab1.col2 col0 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL - col2 * col2 + - tab0.col1 * + col1 AS col0 FROM tab0
----
-15005
-8485
-9410

query I rowsort
SELECT col0 - col1 * col0 AS col2 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3287
SELECT ALL col0 DIV col0 + col1 * - tab2.col1 FROM tab2
----
-288
-3480
-960

skipif mysql # not compatible
query I rowsort label-3287
SELECT ALL col0 / col0 + col1 * - tab2.col1 FROM tab2
----
-288
-3480
-960

query III rowsort
SELECT * FROM tab1 WHERE - col2 * - col2 <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col2 - col2 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col2 * tab2.col0 * + col0 AS col0 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3291
SELECT DISTINCT + col2 + - col2 DIV col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-3291
SELECT DISTINCT + col2 + - col2 / col2 FROM tab1
----
53
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3292
SELECT ALL + col0 DIV tab0.col2 AS col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3292
SELECT ALL + col0 / tab0.col2 AS col2 FROM tab0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3293
SELECT col0 DIV + col0 - + col1 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3293
SELECT col0 / + col0 - + col1 FROM tab1
----
-12
-25
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3294
SELECT col1 DIV - tab0.col2 + - col2 * + col2 AS col2 FROM tab0
----
-1091
-6725
-98

skipif mysql # not compatible
query I rowsort label-3294
SELECT col1 / - tab0.col2 + - col2 * + col2 AS col2 FROM tab0
----
-1091
-6725
-98

query I rowsort
SELECT ALL - col0 + col1 * + tab1.col1 AS col1 FROM tab1
----
36
673
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 col1 FROM tab1
----
27
27
27

query I rowsort
SELECT ALL + 18 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ALL + - col0 * + col1 + - cor0.col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT - - cor0.col1 + + col1 * cor0.col0 * - 99 FROM tab2 AS cor0
----
-132940
-21452
-455539

query I rowsort
SELECT + col0 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - col1 + cor0.col0 * + col1 AS col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL 61 * + col2 * - col2 FROM tab1 AS cor0
----
-177876
-198189
-562176

query I rowsort
SELECT - 73 * col1 + + 40 * - col1 + col1 AS col0 FROM tab1 cor0
----
-1120
-1456
-2912

query I rowsort
SELECT DISTINCT - - 27 + col1 FROM tab0 cor0
----
113
118
124

query I rowsort
SELECT - - 26 * col0 FROM tab1 AS cor0
----
1664
2080
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 37 col1 FROM tab2 AS cor0
----
-37
-37
-37

query I rowsort
SELECT DISTINCT + 62 AS col1 FROM tab2
----
62

query I rowsort
SELECT + tab2.col1 * col1 * col2 + - 13 FROM tab2
----
10969
25934
90493

onlyif mysql # use DIV operator for integer division
query I rowsort label-3309
SELECT - col1 + col1 DIV ( ( col2 ) ) FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-3309
SELECT - col1 + col1 / ( ( col2 ) ) FROM tab1
----
-10
-13
-26

query I rowsort
SELECT + 25 * - col2 AS col2 FROM tab1 AS cor0
----
-1350
-1425
-2400

query I rowsort
SELECT + 98 + col2 + 20 FROM tab1 AS cor0
----
172
175
214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col1 + 44 col0 FROM tab0 AS cor0
----
141
2882
7506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 22 * - col0 - + col1 * col2 col1 FROM tab2 AS cor0
----
-2384
-3250
-991

query I rowsort
SELECT - 49 * + col1 * + 42 FROM tab1 AS cor0
----
-20580
-26754
-53508

query I rowsort
SELECT col0 * col2 + + cor0.col0 * - ( + col2 ) AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * col2 + cor0.col2 + col1 FROM tab2 AS cor0
----
1619
701
895

query I rowsort
SELECT DISTINCT 11 FROM tab2 cor0 CROSS JOIN tab2, tab1 cor1, tab2 AS cor2
----
11

query I rowsort
SELECT + col1 * - 46 AS col0 FROM tab0 AS cor0
----
-3956
-4186
-4462

query I rowsort
SELECT DISTINCT + 95 AS col1 FROM tab0, tab0 AS cor0
----
95

query I rowsort
SELECT + 52 * + col2 + col1 AS col2 FROM tab1 AS cor0
----
2834
2974
5005

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3321
SELECT CAST( NULL AS DECIMAL ) * - col0 / col0 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-3321
SELECT CAST ( NULL AS REAL ) * - col0 / col0 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3322
SELECT DISTINCT - CAST( col1 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3322
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT tab1.col2 * cor0.col1 + + tab1.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 98eef4cb5f322082a4c2bcced10b4b54

query I rowsort
SELECT + cor2.col1 * 28 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to fe27bf1f023c90a0fc748f4ed0a689d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3325
SELECT ALL - CAST( NULL AS SIGNED ) + - ( + col2 * cor0.col1 ) + + ( col2 ) * - ( col1 + + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3325
SELECT ALL - CAST ( NULL AS INTEGER ) + - ( + col2 * cor0.col1 ) + + ( col2 ) * - ( col1 + + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 30 * 52 FROM tab0 cor0
----
1560

query I rowsort
SELECT DISTINCT col2 * col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + + col0 - col1 * cor0.col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT ALL - col1 * - col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT - - ( + col2 ) + + cor0.col0 + col2 * - col2 FROM tab0 AS cor0
----
-1032
-6553
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3331
SELECT 78 - - tab0.col0 DIV col2 FROM tab0
----
113
78
79

skipif mysql # not compatible
query I rowsort label-3331
SELECT 78 - - tab0.col0 / col2 FROM tab0
----
113
78
79

query I rowsort
SELECT - col1 + - 28 * + col1 AS col2 FROM tab2
----
-1711
-493
-899

query I rowsort
SELECT + col1 - 33 FROM tab2
----
-16
-2
26

query I rowsort
SELECT DISTINCT - + col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3335
SELECT col1 * - col1 DIV - col1 col0 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3335
SELECT col1 * - col1 / - col1 col0 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL col2 - tab0.col0 * - col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT - col2 * - col2 + + cor0.col1 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT 3 + col0 + + col0 * col0 AS col2 FROM tab2
----
59
6165
6323

query I rowsort
SELECT - 16 + col1 + - col0 FROM tab0
----
-14
46
46

query I rowsort
SELECT ALL + 27 AS col1 FROM tab0 cor0
----
27
27
27

query I rowsort
SELECT + - 48 + 27 * col0 FROM tab0 AS cor0
----
2355
600
897

query I rowsort
SELECT ALL - 84 * col0 FROM tab2 cor0
----
-588
-6552
-6636

onlyif mysql # use DIV operator for integer division
query I rowsort label-3343
SELECT DISTINCT + cor0.col2 DIV - 15 FROM tab2 AS cor0
----
-1
-2

skipif mysql # not compatible
query I rowsort label-3343
SELECT DISTINCT + cor0.col2 / - 15 FROM tab2 AS cor0
----
-1
-2

query I rowsort
SELECT ALL - ( col2 ) + col2 * col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT ALL + 82 * + 54 + - col2 FROM tab2 cor0
----
4390
4401
4402

query I rowsort
SELECT ALL col2 * col0 + tab2.col1 * col1 AS col2 FROM tab2
----
1150
3291
5509

query I rowsort
SELECT DISTINCT - col1 * col0 + - 17 FROM tab0
----
-2081
-3412
-8116

query I rowsort
SELECT col2 + - col2 * col2 AS col0 FROM tab2
----
-1406
-650
-702

query I rowsort
SELECT 47 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT DISTINCT + - 61 FROM tab2 AS cor0
----
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * ( + col0 ) col0 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 76 * - 8 col2 FROM tab2 AS cor0
----
608
608
608

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL < ( NULL )
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE col0 NOT IN ( col0 )
----

query I rowsort
SELECT col0 - col1 * col1 AS col1 FROM tab2 AS cor0 WHERE NOT NULL BETWEEN ( + col0 ) AND NULL
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL IN ( + col0 + + tab1.col2 )
----

query I rowsort
SELECT DISTINCT + tab1.col2 FROM tab2 AS cor0 CROSS JOIN tab1
----
54
57
96

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) < col2
----

query I rowsort
SELECT col0 * cor0.col0 + + col0 / col1 AS col2 FROM tab1 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT col0 * + col2 * + col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT - col2 + + col1 AS col0 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT tab0.col2 + - tab0.col0 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL + col1 * - cor0.col1 + - col2 AS col0 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT col1 * - col2 * col2 + - col2 FROM tab2
----
-22626
-24586
-39910

query I rowsort
SELECT + col0 + col2 + col2 * col2 FROM tab1
----
2973
3370
9392

query I rowsort
SELECT DISTINCT + tab1.col1 + col1 * - col0 * + col0 FROM tab1
----
-208
-40950
-83187

query I rowsort
SELECT + - col2 + - col1 * + col0 * - col1 AS col0 FROM tab0 AS cor0
----
177471
329314
736927

onlyif mysql # use DIV operator for integer division
query I rowsort label-3368
SELECT ALL + - col1 DIV - col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3368
SELECT ALL + - col1 / - col2 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + cor0.col2 col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3370
SELECT DISTINCT - col0 DIV col2 AS col1 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-3370
SELECT DISTINCT - col0 / col2 AS col1 FROM tab0 cor0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 + col2 col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + col1 * + col1 * cor0.col2 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-3373
SELECT DISTINCT - cor0.col0 DIV + col2 col1 FROM tab1 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3373
SELECT DISTINCT - cor0.col0 / + col2 col1 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT col1 * col1 + - col0 * col0 FROM tab1 cor0
----
-3996
-6231
667

query I rowsort
SELECT DISTINCT - cor0.col0 + - col0 * - col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT - - col2 * col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT ALL + - cor0.col0 + + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - + cor0.col0 + col2 * - col2 * + col2 FROM tab0 AS cor0
----
-35961
-36
-551457

onlyif mysql # use DIV operator for integer division
query I rowsort label-3379
SELECT - col0 + tab0.col1 DIV - col2 FROM tab0
----
-132
-26
-90

skipif mysql # not compatible
query I rowsort label-3379
SELECT - col0 + tab0.col1 / - col2 FROM tab0
----
-132
-26
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + + col2 * col2 * - col0 col0 FROM tab2
----
-111074
-4914
-50700

onlyif mysql # use DIV operator for integer division
query I rowsort label-3381
SELECT ALL col0 + col2 DIV col2 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-3381
SELECT ALL col0 + col2 / col2 FROM tab0
----
25
36
90

query I rowsort
SELECT DISTINCT col1 * + col0 + col0 AS col2 FROM tab1
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 * - col0 + + col0 AS col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab1, tab2, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + 92 * tab0.col1 FROM tab0, tab1 cor0
----
9 values hashing to 844e514306f2f916b4219f43521d18e1

query I rowsort
SELECT - col0 * + cor0.col1 + + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

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-3388
SELECT - col2 DIV col1 + col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3388
SELECT - col2 / col1 + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - - cor0.col2 * - ( col1 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - - 12 * - cor0.col0 + + col1 * col0 AS col1 FROM tab0 cor0
----
1776
2975
7031

onlyif mysql # use DIV operator for integer division
query I rowsort label-3391
SELECT + + col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3391
SELECT + + col2 / - col0 AS col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT + + col2 + ( + col2 ) + - col2 * - col0 FROM tab1 AS cor0
----
270
3762
7872

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 * 69 + col2 col1 FROM tab2
----
1211
2166
4097

query I rowsort
SELECT - ( + col0 ) + + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col2 + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL - col1 - + cor0.col0 * col1 AS col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT + 63 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT ALL - + col2 - - col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + col0 * col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - + 58 * col1 + + col2 + 99 AS col0 FROM tab2 AS cor0
----
-1672
-3297
-849

query I rowsort
SELECT - 36 * - col0 FROM tab1 cor0
----
108
2304
2880

query I rowsort
SELECT DISTINCT cor0.col2 * - 51 * 15 AS col0 FROM tab1, tab1 AS cor0
----
-41310
-43605
-73440

query I rowsort
SELECT + cor0.col2 * + ( col0 ) AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT tab2.col1 - tab2.col1 FROM tab2, tab2 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + - col2 * + ( col0 ) * + col2 AS col1 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT ALL ( col1 * 36 ) FROM tab1
----
360
468
936

query I rowsort
SELECT DISTINCT + col2 * + 47 AS col0 FROM tab1 cor0
----
2538
2679
4512

onlyif mysql # use DIV operator for integer division
query I rowsort label-3408
SELECT ALL + col0 + - ( col2 ) DIV col0 FROM tab1 AS cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-3408
SELECT ALL + col0 + - ( col2 ) / col0 FROM tab1 AS cor0
----
-15
64
79

query I rowsort
SELECT cor0.col2 * - ( - col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 51 FROM tab0, tab0 AS cor0
----
51

query I rowsort
SELECT ALL - col0 * + col1 * 96 FROM tab0
----
-198144
-325920
-777504

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col2 * - col0 col1 FROM tab0 AS cor0
----
-36
-7380
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3413
SELECT ALL + 19 + cor0.col0 DIV - col2 FROM tab1 AS cor0
----
18
19
19

skipif mysql # not compatible
query I rowsort label-3413
SELECT ALL + 19 + cor0.col0 / - col2 FROM tab1 AS cor0
----
18
19
19

query I rowsort
SELECT tab1.col0 - col1 * col0 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3415
SELECT + col2 DIV - col2 AS col2 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3415
SELECT + col2 / - col2 AS col2 FROM tab1 cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3416
SELECT DISTINCT + 19 DIV + col0 + - 35 * col0 FROM tab0
----
-1225
-3115
-840

skipif mysql # not compatible
query I rowsort label-3416
SELECT DISTINCT + 19 / + col0 + - 35 * col0 FROM tab0
----
-1225
-3115
-840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 * + col0 col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT col0 * - col2 * - ( col2 ) + - col0 FROM tab2 AS cor0
----
113997
5096
52650

query I rowsort
SELECT + + 67 + - col0 AS col1 FROM tab2 AS cor0
----
-11
-12
60

query I rowsort
SELECT 28 * cor0.col2 * + 98 + col0 FROM tab1 AS cor0
----
148179
156472
263504

query I rowsort
SELECT + + col0 + - col1 * col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - 41 + col0 FROM tab0 cor0
----
-17
-6
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3423
SELECT + CAST( - col1 AS SIGNED ) 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-3423
SELECT + CAST ( - col1 AS INTEGER ) col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - cor0.col1 + + 25 AS col2 FROM tab2 cor0
----
-34
-6
8

query I rowsort
SELECT ALL + + col2 + col1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - ( + col1 ) + col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT 97 * col2 AS col0 FROM tab0
----
3201
7954
97

query I rowsort
SELECT - 19 * cor0.col0 FROM tab2 AS cor0
----
-133
-1482
-1501

query I rowsort
SELECT DISTINCT - ( + col1 ) * col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - 5 AS col1 FROM tab1 AS cor0
----
-5
-5
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3431
SELECT ( + 64 ) + - col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3431
SELECT ( + 64 ) + - col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 75 * + col2 AS col2 FROM tab2 AS cor0
----
-1950
-2025
-2850

query I rowsort
SELECT col2 * + col0 + - col2 + + 33 AS col1 FROM tab1 AS cor0
----
141
3624
7617

query I rowsort
SELECT ALL - 40 AS col0 FROM tab0 AS cor0
----
-40
-40
-40

query I rowsort
SELECT ALL col1 * 35 FROM tab2 AS cor0
----
1085
2065
595

query I rowsort
SELECT DISTINCT + 22 * col1 - - col1 FROM tab1 AS cor0
----
230
299
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-3437
SELECT ALL + - 99 DIV + col2 AS col2 FROM tab0 AS cor0
----
-1
-3
-99

skipif mysql # not compatible
query I rowsort label-3437
SELECT ALL + - 99 / + col2 AS col2 FROM tab0 AS cor0
----
-1
-3
-99

query I rowsort
SELECT - ( col1 ) + col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + + 34 AS col2 FROM tab2 cor0
----
34

query I rowsort
SELECT ALL col0 * 70 FROM tab2 AS cor0
----
490
5460
5530

query I rowsort
SELECT + - 85 AS col0 FROM tab1 cor0
----
-85
-85
-85

query I rowsort
SELECT ALL + ( col1 ) * 36 AS col1 FROM tab0 AS cor0
----
3096
3276
3492

query I rowsort
SELECT - 14 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c2bf0e2420d22cd58d7ee3b30827afcc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 33 * col0 col2 FROM tab0 AS cor0
----
1155
2937
792

query I rowsort
SELECT ALL + - 79 + + col1 FROM tab1 AS cor0
----
-53
-66
-69

query I rowsort
SELECT - 49 AS col1 FROM tab0 AS cor0
----
-49
-49
-49

query I rowsort
SELECT ALL - col2 + - 0 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL 55 * - cor0.col2 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 75758aa09e787211684ca1f366d020f2

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab1, tab1 AS cor0
----
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-3450
SELECT - - col1 * col0 DIV col1 + + cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
134
167
269

skipif mysql # not compatible
query I rowsort label-3450
SELECT - - col1 * col0 / col1 + + cor0.col1 + col0 AS col0 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT DISTINCT 94 FROM tab0, tab0 cor0
----
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3452
SELECT DISTINCT 88 DIV - col2 AS col2 FROM tab0
----
-1
-2
-88

skipif mysql # not compatible
query I rowsort label-3452
SELECT DISTINCT 88 / - col2 AS col2 FROM tab0
----
-1
-2
-88

query I rowsort
SELECT - + col2 * - col2 + col2 + col2 FROM tab2 AS cor0
----
1520
728
783

onlyif mysql # use DIV operator for integer division
query I rowsort label-3454
SELECT - col0 + + col1 DIV col2 + - cor0.col0 FROM tab0 AS cor0
----
-177
-46
27

skipif mysql # not compatible
query I rowsort label-3454
SELECT - col0 + + col1 / col2 + - cor0.col0 FROM tab0 AS cor0
----
-177
-46
27

query I rowsort
SELECT ALL - - col1 * 39 + col1 FROM tab0 AS cor0
----
3440
3640
3880

onlyif mysql # use DIV operator for integer division
query I rowsort label-3456
SELECT ALL col1 + CAST( col1 AS SIGNED ) DIV col0 col2 FROM tab2
----
17
35
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3456
SELECT ALL col1 + CAST ( col1 AS INTEGER ) / col0 col2 FROM tab2
----
17
35
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3457
SELECT + col1 + 2 DIV col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3457
SELECT + col1 + 2 / col1 FROM tab0 cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3458
SELECT DISTINCT CAST( NULL AS DECIMAL ) + - col1 * + col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3458
SELECT DISTINCT CAST ( NULL AS REAL ) + - col1 * + col1 FROM tab2 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3459
SELECT - col2 DIV cor0.col2 + + col0 * col0 FROM tab1 AS cor0
----
4095
6399
8

skipif mysql # not compatible
query I rowsort label-3459
SELECT - col2 / cor0.col2 + + col0 * col0 FROM tab1 AS cor0
----
4095
6399
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col1 * tab2.col2 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col0 + - ( + 23 ) * tab2.col1 AS col0 FROM tab2
----
-1279
-312
-706

query I rowsort
SELECT - col1 * ( + 85 ) AS col2 FROM tab2
----
-1445
-2635
-5015

query I rowsort
SELECT col1 * 51 FROM tab1
----
1326
510
663

query I rowsort
SELECT ALL - 63 FROM tab2, tab1 cor0
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

query I rowsort
SELECT - 3 + 80 AS col1 FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT + 85 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

query I rowsort
SELECT + cor0.col0 * 40 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2b743fb39d694b9cbc88a7185e54b9c9

query I rowsort
SELECT + col2 + - 46 FROM tab1 AS cor0
----
11
50
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3469
SELECT - + CAST( NULL AS DECIMAL ) col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3469
SELECT - + CAST ( NULL AS REAL ) col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 89 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT col1 * + 51 * + col2 FROM tab2
----
32946
42687
78234

query I rowsort
SELECT ALL col2 * ( - col2 ) * + col1 + 93 AS col2 FROM tab2
----
-22506
-24455
-39791

query I rowsort
SELECT ( col2 * - col0 ) + - 59 FROM tab0
----
-7357
-851
-94

query I rowsort
SELECT DISTINCT - + col1 + - col2 * col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL - col1 * col1 + col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to def82b52aa9c83b91991d7d043276abe

query I rowsort
SELECT ALL - 36 * col1 + + col2 FROM tab2 AS cor0
----
-1089
-2098
-574

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3478
SELECT ALL + 58 * cor0.col1 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3478
SELECT ALL + 58 * cor0.col1 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 89 * col0 FROM tab2 AS cor0
----
623
6942
7031

query I rowsort
SELECT ALL + 93 AS col2 FROM tab1
----
93
93
93

query I rowsort
SELECT DISTINCT + ( col1 + ( - col2 ) ) FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT - + col0 * + 1 * + ( col0 ) AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3483
SELECT ALL - cor0.col1 DIV + col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3483
SELECT ALL - cor0.col1 / + col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + + ( cor0.col1 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT DISTINCT + - col2 + + ( 3 ) FROM tab0 AS cor0
----
-30
-79
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 + 73 col2 FROM tab1
----
127
130
169

query I rowsort
SELECT ALL + col0 * - 55 + 45 FROM tab0 cor0
----
-1275
-1880
-4850

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - col2 + - CAST ( col1 AS REAL ) col2 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * ( cor0.col2 ) * col1 col0 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT + col2 * col0 + - col1 * col0 FROM tab0 AS cor0
----
-1272
-3360
-801

onlyif mysql # use DIV operator for integer division
query I rowsort label-3491
SELECT col2 DIV col2 + + 44 DIV + col2 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3491
SELECT col2 / col2 + + 44 / + col2 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - + cor0.col0 + + col1 * col0 + + col2 FROM tab0 AS cor0
----
2073
3361
8092

query I rowsort
SELECT DISTINCT - + cor0.col1 + - col2 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + col0 + col1 * col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + + col1 * col2 - - cor0.col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-3496
SELECT DISTINCT - cor0.col2 + - col2 DIV col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3496
SELECT DISTINCT - cor0.col2 + - col2 / col2 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT DISTINCT - 70 + - col1 FROM tab2 AS cor0
----
-101
-129
-87

query I rowsort
SELECT + col2 * + cor0.col0 + ( + 8 ) FROM tab2 AS cor0
----
197
2036
3010

query I rowsort
SELECT DISTINCT - 55 * - col1 FROM tab2
----
1705
3245
935

query I rowsort
SELECT - tab0.col1 FROM tab0, tab1, tab0 AS cor0, tab2 AS cor1
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

query I rowsort
SELECT DISTINCT tab2.col0 * 35 FROM tab2, tab2 cor0
----
245
2730
2765

query I rowsort
SELECT ( col2 * + ( col0 ) ) - tab0.col0 * tab0.col1 AS col2 FROM tab0
----
-1272
-3360
-801

query I rowsort
SELECT DISTINCT + cor0.col2 * + 86 AS col2 FROM tab0, tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab2, tab0, tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col0 * + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * + col1 * - ( 34 ) col0 FROM tab0
----
-253708
-3298
-96492

query I rowsort
SELECT ALL col2 * + 91 AS col2 FROM tab1
----
4914
5187
8736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT col0 + 51 * - tab2.col1 AS col2 FROM tab2
----
-1574
-2931
-788

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3510
SELECT col2 * - CAST( NULL AS SIGNED ) * - col2 + col0 * col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3510
SELECT col2 * - CAST ( NULL AS INTEGER ) * - col2 + col0 * col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3511
SELECT ALL - col1 * - CAST( NULL AS SIGNED ) + + col1 * col1 * - CAST( col1 AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3511
SELECT ALL - col1 * - CAST ( NULL AS INTEGER ) + + col1 * col1 * - CAST ( col1 AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * 66 * + col1 + + cor0.col2 FROM tab2 AS cor0
----
19112
229772
63453

onlyif mysql # use DIV operator for integer division
query I rowsort label-3513
SELECT + col1 DIV ( - 12 ) + - col0 AS col0 FROM tab1 AS cor0
----
-5
-64
-81

skipif mysql # not compatible
query I rowsort label-3513
SELECT + col1 / ( - 12 ) + - col0 AS col0 FROM tab1 AS cor0
----
-5
-64
-81

query I rowsort
SELECT + 85 AS col1 FROM tab0 cor0
----
85
85
85

query I rowsort
SELECT - 23 * col0 FROM tab1 cor0
----
-1472
-1840
-69

query I rowsort
SELECT + - 88 * col1 + - col0 FROM tab2 AS cor0
----
-1575
-2735
-5270

query I rowsort
SELECT 98 * - col1 AS col0 FROM tab2 AS cor0
----
-1666
-3038
-5782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col0 * col1 col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT col1 + + ( col1 * + col2 ) FROM tab0
----
194
2924
7553

query I rowsort
SELECT tab2.col0 + 2 * - tab2.col1 * col0 AS col2 FROM tab2
----
-2607
-427
-9126

query I rowsort
SELECT ( - ( tab1.col0 ) * - 81 ) AS col1 FROM tab1
----
243
5184
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3522
SELECT - CAST( - 99 AS SIGNED ) FROM tab2 AS cor0
----
99
99
99

skipif mysql # not compatible
query I rowsort label-3522
SELECT - CAST ( - 99 AS INTEGER ) FROM tab2 AS cor0
----
99
99
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT + ( col2 ) DIV col1 + + 71 * cor0.col1 FROM tab0 AS cor0
----
6106
6461
6887

skipif mysql # not compatible
query I rowsort label-3523
SELECT + ( col2 ) / col1 + + 71 * cor0.col1 FROM tab0 AS cor0
----
6106
6461
6887

query I rowsort
SELECT DISTINCT - 49 * tab2.col0 * tab2.col0 + col0 AS col0 FROM tab2
----
-2394
-298038
-305730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + tab0.col2 * + col2 col0 FROM tab0
----
1122
2
6806

query I rowsort
SELECT - cor0.col1 + + 48 FROM tab0 AS cor0
----
-38
-43
-49

query I rowsort
SELECT ALL 57 * + col2 - - col0 AS col1 FROM tab1 AS cor0
----
3081
3313
5552

onlyif mysql # use DIV operator for integer division
query I rowsort label-3528
SELECT DISTINCT col0 - col1 * col2 DIV - ( + col2 ) FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-3528
SELECT DISTINCT col0 - col1 * col2 / - ( + col2 ) FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - 73 + - col1 * col1 + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-1027
-283
-3476

query I rowsort
SELECT col0 + + 79 * - col2 * 94 AS col0 FROM tab2 cor0
----
-192998
-200495
-282109

query I rowsort
SELECT DISTINCT + + ( col2 ) + + col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + + 99 + col0 FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT + 0 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 + + col0 col2 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - 95 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT DISTINCT + 38 + col2 AS col1 FROM tab2 cor0
----
64
65
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3537
SELECT - - col2 + - cor0.col1 * col0 DIV - col0 FROM tab1 cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-3537
SELECT - - col2 + - cor0.col1 * col0 / - col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col2 * - col0 + - col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT 60 * - col2 * ( - cor0.col2 ) + col2 + + col1 AS col2 FROM tab2 cor0
----
40645
43798
86695

query I rowsort
SELECT ALL + 45 + + cor0.col0 FROM tab0 AS cor0
----
134
69
80

query I rowsort
SELECT ALL + col1 * col1 + - 39 AS col0 FROM tab1 cor0
----
130
61
637

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) + cor0.col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - col2 - - col0 * + ( 59 ) AS col1 FROM tab0 AS cor0
----
1383
2064
5169

query I rowsort
SELECT + 75 + col0 FROM tab1 AS cor0
----
139
155
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3545
SELECT ALL col1 * cor0.col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3545
SELECT ALL col1 * cor0.col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 25 AS col1 FROM tab2
----
25
25
25

query I rowsort
SELECT - col2 - col0 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - + col0 + - ( 90 ) * - col1 * - col0 AS col1 FROM tab0 AS cor0
----
-185784
-305585
-728999

onlyif mysql # use DIV operator for integer division
query I rowsort label-3549
SELECT + cor0.col1 DIV col1 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3549
SELECT + cor0.col1 / col1 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col1 * - ( - cor0.col0 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + + col2 * + col1 - col2 * - col1 AS col1 FROM tab0 AS cor0
----
14924
194
5676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 * + col2 col0 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT col0 * ( col1 ) + + col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT col1 + 73 * - 33 AS col1 FROM tab1 cor0
----
-2383
-2396
-2399

query I rowsort
SELECT - - col0 * - 66 FROM tab2 AS cor0
----
-462
-5148
-5214

query I rowsort
SELECT ALL ( col1 ) * cor0.col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3557
SELECT CAST( NULL AS SIGNED ) * col0 + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3557
SELECT CAST ( NULL AS INTEGER ) * col0 + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 57 AS col0 FROM tab1 AS cor0
----
57
57
57

query I rowsort
SELECT 74 FROM tab0, tab2, tab0 cor0
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

query I rowsort
SELECT ALL + cor0.col0 + col0 * cor0.col1 * - col1 FROM tab2 AS cor0
----
-22752
-271440
-6720

query I rowsort
SELECT 77 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT ALL - col1 + col2 * - col2 AS col0 FROM tab2
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + col1 + col1 + + col2 FROM tab0
----
195
205
264

query I rowsort
SELECT DISTINCT - cor0.col2 * - ( - col2 + col0 ) AS col1 FROM tab2 cor0
----
-540
1352
1558

onlyif mysql # use DIV operator for integer division
query I rowsort label-3565
SELECT ALL cor0.col0 DIV 83 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3565
SELECT ALL cor0.col0 / 83 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - - col0 * - 65 AS col0 FROM tab2 cor0
----
-455
-5070
-5135

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL col0 * + col1 + + 40 AS col0 FROM tab0 AS cor0
----
2104
3435
8139

query I rowsort
SELECT - col2 * - cor0.col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3570
SELECT ALL - col1 * CAST( + ( - col1 ) AS SIGNED ) AS col0 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-3570
SELECT ALL - col1 * CAST ( + ( - col1 ) AS INTEGER ) AS col0 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 * col2 col1 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL + + 67 FROM tab1 AS cor0
----
67
67
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3573
SELECT DISTINCT - col2 * - col1 + col0 + CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1341
1433
644

skipif mysql # not compatible
query I rowsort label-3573
SELECT DISTINCT - col2 * - col1 + col0 + CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1341
1433
644

query I rowsort
SELECT - - 0 * col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col0 - + 10 FROM tab0 AS cor0
----
14
25
79

query I rowsort
SELECT DISTINCT + + 11 * + 57 FROM tab2 AS cor0
----
627

query I rowsort
SELECT - col2 * col1 - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - - 96 - col1 AS col0 FROM tab1 cor0
----
70
83
86

query I rowsort
SELECT col0 * - 51 - - col1 AS col2 FROM tab2 AS cor0
----
-326
-3919
-4012

onlyif mysql # use DIV operator for integer division
query I rowsort label-3580
SELECT + ( + ( - cor0.col2 ) ) DIV + cor0.col0 - col1 * + col1 AS col0 FROM tab1 AS cor0
----
-100
-170
-694

skipif mysql # not compatible
query I rowsort label-3580
SELECT + ( + ( - cor0.col2 ) ) / + cor0.col0 - col1 * + col1 AS col0 FROM tab1 AS cor0
----
-100
-170
-694

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + cor0.col0 + cor0.col1 + col2 * col0 col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + ( + col0 ) + - 51 AS col0 FROM tab1 AS cor0
----
-48
13
29

query I rowsort
SELECT ALL + 83 AS col2 FROM tab2 cor0
----
83
83
83

query I rowsort
SELECT ALL 2 * + col2 + + ( col2 + - cor0.col2 ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - col1 + - col0 * + col1 AS col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-3586
SELECT ALL + col2 * col1 DIV - col2 - - col2 DIV col2 col2 FROM tab1
----
-12
-25
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3586
SELECT ALL + col2 * col1 / - col2 - - col2 / col2 col2 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT DISTINCT - ( col0 ) - tab2.col1 AS col2 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT - col1 * col0 + col1 + tab1.col2 * + 0 FROM tab1
----
-1027
-52
-630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3589
SELECT + - col1 - - col0 * - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3589
SELECT + - col1 - - col0 * - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 45 + col0 * col0 * - cor0.col2 FROM tab1 AS cor0
----
-233427
-441
-614355

query I rowsort
SELECT + + 64 + col2 AS col0 FROM tab1 AS cor0
----
118
121
160

onlyif mysql # use DIV operator for integer division
query I rowsort label-3592
SELECT ALL - - col1 + + col1 DIV + 78 AS col0 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3592
SELECT ALL - - col1 + + col1 / + 78 AS col0 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT DISTINCT col2 + + cor0.col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT 67 * - col2 + col2 FROM tab0 AS cor0
----
-2178
-5412
-66

query I rowsort
SELECT - 94 * - col1 + - col1 AS col2 FROM tab0 AS cor0
----
7998
8463
9021

query I rowsort
SELECT - 18 * - col2 - - col0 * + 26 FROM tab2 AS cor0
----
2496
2738
668

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3597
SELECT ALL col2 * col1 / + CAST( NULL AS SIGNED ) - + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3597
SELECT ALL col2 * col1 / + CAST ( NULL AS INTEGER ) - + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col1 - - col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3599
SELECT - col2 + - cor0.col2 DIV col2 AS col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3599
SELECT - col2 + - cor0.col2 / col2 AS col2 FROM tab0 AS cor0
----
-2
-34
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3600
SELECT + - col0 + - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3600
SELECT + - col0 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab0.col0 + col0 AS col0 FROM tab0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 80 * col2 + + col0 col0 FROM tab1 AS cor0
----
-233277
-259856
-737200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + 58 col0 FROM tab0 AS cor0
----
-24
25
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3604
SELECT DISTINCT + CAST( NULL AS SIGNED ) + 18 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3604
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + 18 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

query I rowsort
SELECT + 73 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT + 45 * cor0.col0 AS col1 FROM tab2 AS cor0
----
315
3510
3555

query I rowsort
SELECT ALL - ( col0 ) * - col0 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + ( - col2 ) col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - + ( col0 ) + - col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL col0 * 45 FROM tab0 AS cor0
----
1080
1575
4005

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3611
SELECT ALL col0 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3611
SELECT ALL col0 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3612
SELECT + cor0.col0 DIV - cor0.col1 FROM tab0, tab1 cor0
----
9 values hashing to 0cf123df00ec8476d9e0a7b2d2f6001e

skipif mysql # not compatible
query I rowsort label-3612
SELECT + cor0.col0 / - cor0.col1 FROM tab0, tab1 cor0
----
9 values hashing to 0cf123df00ec8476d9e0a7b2d2f6001e

query I rowsort
SELECT ALL 45 * + tab2.col2 FROM tab2
----
1170
1215
1710

query I rowsort
SELECT ALL ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT col2 * 81 FROM tab2 AS cor0
----
2106
2187
3078

query I rowsort
SELECT DISTINCT - 22 * 87 FROM tab0
----
-1914

query I rowsort
SELECT DISTINCT col0 * + 62 * col0 AS col2 FROM tab2
----
3038
377208
386942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 36 col2 FROM tab2, tab2 AS cor0
----
36

query I rowsort
SELECT ALL - 77 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT DISTINCT + 56 FROM tab2, tab1 AS cor0
----
56

query I rowsort
SELECT - + cor0.col2 * + 9 * col1 + col0 FROM tab2 AS cor0
----
-13728
-5735
-7526

query I rowsort
SELECT ALL 41 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3624
SELECT - - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3624
SELECT - - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 + 27 * col0 * - CAST ( - 76 AS REAL ) FROM tab0 AS cor0
----
182546
49215
71819

query I rowsort
SELECT + col2 * col0 + 10 AS col0 FROM tab0
----
45
7308
802

query I rowsort
SELECT ALL col0 + - tab1.col2 * col1 * + col1 FROM tab1
----
-16144
-36501
-5636

query I rowsort
SELECT - col2 + + 81 AS col2 FROM tab2
----
43
54
55

query I rowsort
SELECT DISTINCT - col2 * 54 + + col2 + col0 AS col2 FROM tab0
----
-1725
-18
-4257

query I rowsort
SELECT 90 + col1 + tab1.col0 FROM tab1
----
119
164
183

query I rowsort
SELECT - col1 * - col0 + + col1 * - ( - col2 + col1 * col2 ) AS col0 FROM tab2
----
-24893
-84370
-8993

query I rowsort
SELECT - col0 + col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3633
SELECT DISTINCT CAST( - col1 AS SIGNED ) FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3633
SELECT DISTINCT CAST ( - col1 AS INTEGER ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT col1 * - 78 FROM tab1
----
-1014
-2028
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-3635
SELECT - ( + col0 ) * col0 DIV + col0 AS col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3635
SELECT - ( + col0 ) * col0 / + col0 AS col2 FROM tab1
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3636
SELECT - CAST( NULL AS SIGNED ) * ( col1 ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3636
SELECT - CAST ( NULL AS INTEGER ) * ( col1 ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3637
SELECT DISTINCT + col1 DIV + col0 FROM tab1 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-3637
SELECT DISTINCT + col1 / + col0 FROM tab1 AS cor0
----
0
8

query I rowsort
SELECT + + col0 + - col1 * - col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3639
SELECT - - 70 DIV 47 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-3639
SELECT - - 70 / 47 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT col1 * + col2 + 35 AS col2 FROM tab2 AS cor0
----
1569
681
872

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - + col1 col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + - col0 + col2 + - 39 FROM tab2 AS cor0
----
-19
-80
-91

query I rowsort
SELECT col2 + + cor0.col0 + cor0.col0 AS col1 FROM tab1 cor0
----
185
256
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 48 * + col1 + col1 col1 FROM tab2 AS cor0
----
1519
2891
833

query I rowsort
SELECT ALL + + tab1.col0 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL 24 + - tab0.col1 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to a1a27705f4c2996a3d964ddf450d2a53

query I rowsort
SELECT + ( col2 ) + + 39 AS col1 FROM tab1 AS cor0
----
135
93
96

query I rowsort
SELECT ALL col0 * col2 - + 74 FROM tab0
----
-39
718
7224

query I rowsort
SELECT ALL + 77 + - col1 FROM tab0
----
-14
-20
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3650
SELECT + - col0 + 83 DIV + 64 AS col1 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3650
SELECT + - col0 + 83 / + 64 AS col1 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort
SELECT + - col1 + - CAST ( 11 AS REAL ) FROM tab0 AS cor0
----
-102
-108
-97

query I rowsort
SELECT DISTINCT cor0.col2 + 83 AS col2 FROM tab1 AS cor0
----
137
140
179

query I rowsort
SELECT DISTINCT + + col2 + - 63 AS col0 FROM tab1 AS cor0
----
-6
-9
33

query I rowsort
SELECT col0 * col2 + + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT cor0.col1 * + 97 + col1 AS col1 FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT ALL + + col2 + - 94 - col1 AS col2 FROM tab2 AS cor0
----
-127
-73
-98

query I rowsort
SELECT col1 + col0 * - ( + col0 ) AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL + col0 + + 22 FROM tab0 AS cor0
----
111
46
57

query I rowsort
SELECT DISTINCT + cor0.col2 + cor0.col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - + col0 * 21 + 82 AS col1 FROM tab2 AS cor0
----
-1556
-1577
-65

query I rowsort
SELECT + col0 + col1 + cor0.col0 AS col0 FROM tab1 AS cor0
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-3662
SELECT DISTINCT - + cor0.col1 + - ( 44 ) DIV - col2 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-3662
SELECT DISTINCT - + cor0.col1 + - ( 44 ) / - col2 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - col0 + ( col1 ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT 80 + - col1 * - col2 FROM tab2 AS cor0
----
1614
726
917

query I rowsort
SELECT - - cor0.col2 * 46 AS col1 FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT + 63 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT + - 95 * + cor0.col2 FROM tab0 AS cor0
----
-3135
-7790
-95

query I rowsort
SELECT ( + 87 ) * + col0 AS col1 FROM tab1 AS cor0
----
261
5568
6960

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( - col1 AS REAL ) + col0 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT DISTINCT + + cor0.col1 * col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col0 + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT - 40 * col1 FROM tab1 AS cor0
----
-1040
-400
-520

query I rowsort
SELECT ALL + 41 + + col0 AS col2 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT 91 * col2 + col0 FROM tab0 AS cor0
----
126
3027
7551

query I rowsort
SELECT ALL - col1 * - col2 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + cor0.col0 + - col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * + col2 + 77 * + 97 FROM tab1 AS cor0
----
10385
10718
16685

query I rowsort
SELECT DISTINCT 36 AS col2 FROM tab0 AS cor0
----
36

query I rowsort
SELECT - - 31 - + col1 * col2 FROM tab2 AS cor0
----
-1503
-615
-806

query I rowsort
SELECT 35 * cor0.col1 - - cor0.col1 * - col1 AS col0 FROM tab0 AS cor0
----
-4386
-5096
-6014

query I rowsort
SELECT DISTINCT col2 + + 8 * col0 FROM tab2 cor0
----
650
670
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3682
SELECT - 49 DIV + cor0.col0 + col1 * + col1 FROM tab2 AS cor0
----
289
3481
954

skipif mysql # not compatible
query I rowsort label-3682
SELECT - 49 / + cor0.col0 + col1 * + col1 FROM tab2 AS cor0
----
289
3481
954

query I rowsort
SELECT ALL 3 * cor0.col0 AS col0 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT col1 * - col2 - - col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - col0 + 22 FROM tab2 AS cor0
----
-56
-57
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3686
SELECT + CAST( NULL AS SIGNED ) + 45 * - col1 + + cor0.col2 * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3686
SELECT + CAST ( NULL AS INTEGER ) + 45 * - col1 + + cor0.col2 * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3687
SELECT - 42 + + col1 * - col1 + CAST( col0 AS SIGNED ) * + col2 FROM tab2 AS cor0
----
-1495
-814
2671

skipif mysql # not compatible
query I rowsort label-3687
SELECT - 42 + + col1 * - col1 + CAST ( col0 AS INTEGER ) * + col2 FROM tab2 AS cor0
----
-1495
-814
2671

onlyif mysql # use DIV operator for integer division
query I rowsort label-3688
SELECT DISTINCT - ( col0 ) DIV - col1 AS col1 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-3688
SELECT DISTINCT - ( col0 ) / - col1 AS col1 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT ALL col1 * + 73 * cor0.col1 FROM tab0 AS cor0
----
539908
604513
686857

query I rowsort
SELECT ( col2 ) * col2 + col1 * 8 * - col0 FROM tab2 AS cor0
----
-1007
-36140
-9300

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 * + tab2.col2 + col0 * tab2.col0 - + CAST ( 51 AS REAL ) * - col2 FROM tab2
----
6734
6735
697

query I rowsort
SELECT DISTINCT - tab1.col1 + col2 * + col0 - col0 * + col0 FROM tab1
----
-458
1267
127

query I rowsort
SELECT ALL + tab0.col2 + ( - col2 ) - col0 * 65 AS col0 FROM tab0
----
-1560
-2275
-5785

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 81 - - 47 col0 FROM tab2
----
145
159
187

onlyif mysql # use DIV operator for integer division
query I rowsort label-3695
SELECT ALL + col2 DIV + col2 - 71 AS col2 FROM tab1
----
-70
-70
-70

skipif mysql # not compatible
query I rowsort label-3695
SELECT ALL + col2 / + col2 - 71 AS col2 FROM tab1
----
-70
-70
-70

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to a698694a7dac245e42212ff0316bdf45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 col2 FROM tab2, tab0 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT 45 * + 73 FROM tab1 cor0
----
3285
3285
3285

query I rowsort
SELECT DISTINCT ( col1 ) * col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3700
SELECT ALL + col1 DIV + 75 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3700
SELECT ALL + col1 / + 75 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3702
SELECT + CAST( col1 AS SIGNED ) * + col2 col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3702
SELECT + CAST ( col1 AS INTEGER ) * + col2 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + tab2.col2 * col1 + col2 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3704
SELECT ALL - - col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3704
SELECT ALL - - col0 / - col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT 11 * col2 AS col2 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT ALL col0 * + col0 * 46 AS col1 FROM tab1 AS cor0
----
188416
294400
414

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT + cor1.col2 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3709
SELECT - ( 42 ) * cor0.col1 DIV - 6 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c04b2beae9324a163a4bd04f20c3bb97

skipif mysql # not compatible
query I rowsort label-3709
SELECT - ( 42 ) * cor0.col1 / - 6 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c04b2beae9324a163a4bd04f20c3bb97

query I rowsort
SELECT DISTINCT + col2 + col0 * - col2 AS col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT + + col2 * + ( col2 + - col2 * - col0 ) FROM tab0 AS cor0
----
27225
36
605160

onlyif mysql # use DIV operator for integer division
query I rowsort label-3712
SELECT col0 * 84 DIV col1 FROM tab2 AS cor0
----
111
18
390

skipif mysql # not compatible
query I rowsort label-3712
SELECT col0 * 84 / col1 FROM tab2 AS cor0
----
111
18
390

onlyif mysql # use DIV operator for integer division
query I rowsort label-3713
SELECT + col0 * + ( col0 ) DIV - col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3713
SELECT + col0 * + ( col0 ) / - col0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + col0 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL col1 - col2 * - 39 * + cor0.col2 AS col0 FROM tab2 cor0
----
26423
28462
56333

query I rowsort
SELECT ALL + col2 + 99 FROM tab1 AS cor0
----
153
156
195

query I rowsort
SELECT - col2 * + ( + col1 + col1 * 36 ) FROM tab2 AS cor0
----
-23902
-30969
-56758

query I rowsort
SELECT DISTINCT + col0 + - ( + ( col2 ) ) AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + col2 + + col0 * - col1 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - 85 + col1 FROM tab1 AS cor0
----
-59
-72
-75

query I rowsort
SELECT cor0.col1 AS col1 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ( col0 ) * col1 * + 22 AS col0 FROM tab2
----
101244
29546
4774

query I rowsort
SELECT ALL + ( + col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT 31 - 40 * + col1 FROM tab1 cor0
----
-1009
-369
-489

query I rowsort
SELECT + col2 * - 62 * cor0.col1 + - ( - col1 ) + col0 FROM tab2 AS cor0
----
-39956
-51856
-94971

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 74 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT + tab0.col0 + 49 * - tab0.col1 AS col2 FROM tab0
----
-4190
-4370
-4718

query I rowsort
SELECT - col1 + 52 AS col0 FROM tab2 AS cor0
----
-7
21
35

query I rowsort
SELECT + 38 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT + + col1 + - 39 AS col0 FROM tab0 AS cor0
----
47
52
58

query I rowsort
SELECT ALL - 10 + col1 AS col0 FROM tab2 AS cor0
----
21
49
7

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab1 cor1, tab0, tab2 AS cor2
----
3645 values hashing to da83d3eeaeb9e24a3cb14bb7058757dd

onlyif mysql # use DIV operator for integer division
query I rowsort label-3733
SELECT ALL + col1 DIV + col1 + - 9 * + col1 AS col2 FROM tab0 AS cor0
----
-773
-818
-872

skipif mysql # not compatible
query I rowsort label-3733
SELECT ALL + col1 / + col1 + - 9 * + col1 AS col2 FROM tab0 AS cor0
----
-773
-818
-872

query I rowsort
SELECT DISTINCT + col0 + + col1 - - 52 FROM tab2 cor0
----
148
189
90

query I rowsort
SELECT col0 * col0 + col2 + 76 * cor0.col0 FROM tab0 AS cor0
----
14767
2433
3886

query I rowsort
SELECT - col1 + col2 + 72 AS col2 FROM tab2 AS cor0
----
39
68
93

query I rowsort
SELECT ALL - col0 + + 29 * col0 FROM tab0
----
2492
672
980

query I rowsort
SELECT DISTINCT + - col0 + col0 * - 59 AS col2 FROM tab0 AS cor0
----
-1440
-2100
-5340

query I rowsort
SELECT DISTINCT - col2 * + col2 - + cor0.col1 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL - col2 * col2 - col2 * col0 FROM tab1 AS cor0
----
-16896
-3078
-6897

query I rowsort
SELECT DISTINCT + col2 * col2 AS col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - col2 + - 65 * col0 AS col0 FROM tab1 AS cor0
----
-249
-4217
-5296

query I rowsort
SELECT + 98 * col1 FROM tab0
----
8428
8918
9506

query I rowsort
SELECT DISTINCT - 16 AS col2 FROM tab1
----
-16

query I rowsort
SELECT + - ( - col0 ) + + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3746
SELECT + 26 DIV + col0 - - 3 FROM tab1 AS cor0
----
11
3
3

skipif mysql # not compatible
query I rowsort label-3746
SELECT + 26 / + col0 - - 3 FROM tab1 AS cor0
----
11
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + col0 * 22 col0 FROM tab0 AS cor0
----
1867
442
673

query I rowsort
SELECT ALL - cor0.col1 * col0 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + + cor0.col2 + 72 AS col0 FROM tab2 AS cor0
----
110
98
99

query I rowsort
SELECT ALL + 33 * col0 AS col2 FROM tab1
----
2112
2640
99

query I rowsort
SELECT - - col0 * - 44 FROM tab1 AS cor0
----
-132
-2816
-3520

query I rowsort
SELECT ALL ( - ( col2 ) ) + col0 + - tab2.col2 FROM tab2
----
-47
26
3

query I rowsort
SELECT ALL ( - col2 * + col0 ) + col1 * 6 AS col1 FROM tab2
----
-1674
-2900
-3

query I rowsort
SELECT DISTINCT + ( 39 ) AS col0 FROM tab2
----
39

query I rowsort
SELECT ALL ( 23 ) AS col2 FROM tab2
----
23
23
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 41 col1 FROM tab1
----
2214
2337
3936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 21 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT DISTINCT + ( + tab0.col0 ) FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3759
SELECT CAST( - 82 AS SIGNED ) DIV + tab0.col0 AS col1 FROM tab0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-3759
SELECT CAST ( - 82 AS INTEGER ) / + tab0.col0 AS col1 FROM tab0
----
-2
-3
0

query I rowsort
SELECT + - 93 AS col2 FROM tab1 AS cor0
----
-93
-93
-93

query I rowsort
SELECT DISTINCT - 97 AS col0 FROM tab1 cor0
----
-97

query I rowsort
SELECT DISTINCT - - 46 FROM tab1 AS cor0
----
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 20 col2 FROM tab2
----
20
20
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 * col1 - + tab0.col2 col1 FROM tab0
----
6589
6925
7468

query I rowsort
SELECT col2 * + col1 + col2 * + col1 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT - 16 + col2 + 88 * col2 AS col1 FROM tab1
----
4790
5057
8528

query I rowsort
SELECT 32 * col2 FROM tab0 AS cor0
----
1056
2624
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-3768
SELECT - col1 * + col0 DIV col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-3768
SELECT - col1 * + col0 / col0 FROM tab2
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT ALL - col1 * - tab1.col1 + ( col2 ) AS col0 FROM tab1
----
157
265
730

query I rowsort
SELECT ALL - 15 + col0 AS col0 FROM tab2
----
-8
63
64

query I rowsort
SELECT DISTINCT + 23 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
23

query I rowsort
SELECT ALL + 85 * - col1 AS col0 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT + col2 + + 42 AS col2 FROM tab0 AS cor0
----
124
43
75

query I rowsort
SELECT DISTINCT + + ( ( + cor0.col2 ) ) AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - tab1.col0 * col0 * + tab1.col1 + col1 FROM tab1
----
-208
-40950
-83187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 93 col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 79 col0 FROM tab2, tab1 cor0
----
79

query I rowsort
SELECT + - col1 * + 56 FROM tab2 AS cor0
----
-1736
-3304
-952

query I rowsort
SELECT - + 14 * + col2 AS col2 FROM tab0 AS cor0
----
-1148
-14
-462

query I rowsort
SELECT ALL 66 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT DISTINCT + ( col0 ) + - col0 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT 47 + - 67 * - col2 AS col0 FROM tab0 cor0
----
114
2258
5541

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3784
SELECT DISTINCT - - CAST( col2 AS SIGNED ) * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-3784
SELECT DISTINCT - - CAST ( col2 AS INTEGER ) * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3785
SELECT DISTINCT - - col1 * col0 * col2 + CAST( NULL AS SIGNED ) + cor0.col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3785
SELECT DISTINCT - - col1 * col0 * col2 + CAST ( NULL AS INTEGER ) + cor0.col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col1 * + ( col0 * col0 ) FROM tab0 AS cor0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3787
SELECT - + CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3787
SELECT - + CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3788
SELECT DISTINCT - cor0.col1 DIV 82 AS col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3788
SELECT DISTINCT - cor0.col1 / 82 AS col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - col1 * + ( - col0 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + + ( + col1 ) * col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - ( - 57 ) FROM tab2 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT - col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col2 + - 3 AS col1 FROM tab0 AS cor0
----
-2
30
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col1 col2 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - 84 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

query I rowsort
SELECT DISTINCT + + col1 + - 33 FROM tab1 AS cor0
----
-20
-23
-7

query I rowsort
SELECT ALL - col0 * - 38 FROM tab1 cor0
----
114
2432
3040

query I rowsort
SELECT + cor0.col2 + - 68 AS col0 FROM tab0 AS cor0
----
-35
-67
14

query I rowsort
SELECT + ( + cor0.col0 ) - - col2 AS col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - + col0 * 40 FROM tab2 AS cor0
----
-280
-3120
-3160

query I rowsort
SELECT - ( + col1 ) - - col2 FROM tab2 AS cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - cor0.col2 ) + col2 col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT 56 + col2 AS col0 FROM tab2 AS cor0
----
82
83
94

query I rowsort
SELECT ALL + + 80 + + 18 AS col2 FROM tab2 AS cor0
----
98
98
98

query I rowsort
SELECT + - col0 * col1 + - col0 AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3806
SELECT ALL + - ( cor0.col1 ) + cor0.col1 DIV - col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-3806
SELECT ALL + - ( cor0.col1 ) + cor0.col1 / - col1 FROM tab2 AS cor0
----
-18
-32
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3807
SELECT - col0 DIV + col1 - - col0 FROM tab2 cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-3807
SELECT - col0 / + col1 - - col0 FROM tab2 cor0
----
7
75
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-3808
SELECT ALL - 31 DIV col2 + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3808
SELECT ALL - 31 / col2 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 20 + 78 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT DISTINCT 27 * col0 AS col1 FROM tab0 AS cor0
----
2403
648
945

query I rowsort
SELECT ALL + + col2 * - col2 + + 35 AS col1 FROM tab0 AS cor0
----
-1054
-6689
34

query I rowsort
SELECT DISTINCT + col0 + - cor0.col2 * cor0.col0 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-3813
SELECT DISTINCT + 8 + cor0.col1 DIV + col2 FROM tab1 cor0
----
8

skipif mysql # not compatible
query I rowsort label-3813
SELECT DISTINCT + 8 + cor0.col1 / + col2 FROM tab1 cor0
----
8

query I rowsort
SELECT - col0 * cor0.col1 + + ( col1 ) FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT cor0.col2 - col1 * cor0.col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - - 64 * - col0 AS col2 FROM tab2 AS cor0
----
-448
-4992
-5056

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3817
SELECT ALL col1 + col2 * - CAST( col0 AS SIGNED ) col0 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3817
SELECT ALL col1 + col2 * - CAST ( col0 AS INTEGER ) col0 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col0 * col0 col0 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-3819
SELECT DISTINCT 46 DIV col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3819
SELECT DISTINCT 46 / col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - - 68 + col1 * - col2 FROM tab1 AS cor0
----
-1180
-1336
-502

onlyif mysql # use DIV operator for integer division
query I rowsort label-3821
SELECT DISTINCT + ( - cor0.col0 ) * 84 - 26 DIV col1 FROM tab2 AS cor0
----
-588
-6552
-6637

skipif mysql # not compatible
query I rowsort label-3821
SELECT DISTINCT + ( - cor0.col0 ) * 84 - 26 / col1 FROM tab2 AS cor0
----
-588
-6552
-6637

query I rowsort
SELECT - 88 * col1 FROM tab0 AS cor0
----
-7568
-8008
-8536

query I rowsort
SELECT ALL - - 73 AS col0 FROM tab0 AS cor0
----
73
73
73

query I rowsort
SELECT + col2 + - col2 * - 31 AS col1 FROM tab1 AS cor0
----
1728
1824
3072

query I rowsort
SELECT DISTINCT + col2 * - cor0.col0 * - col0 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) * - cor0.col2 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col1 * + 57 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-16473
-198417
-54777

query I rowsort
SELECT col0 + + col1 * 84 FROM tab1
----
1172
2187
904

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 * 49 col0 FROM tab2 AS cor0
----
1330
1352
1941

query I rowsort
SELECT DISTINCT tab1.col2 * col2 AS col0 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3831
SELECT cor0.col0 DIV col2 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3831
SELECT cor0.col0 / col2 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - cor0.col0 * col1 + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col0 col2 FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3834
SELECT + CAST( NULL AS DECIMAL ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3834
SELECT + CAST ( NULL AS REAL ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 83 * - col0 + col1 * - 23 AS col2 FROM tab2
----
-1294
-6948
-7831

query I rowsort
SELECT DISTINCT - col2 * + ( - 77 + + col1 ) FROM tab2
----
1242
2280
468

query I rowsort
SELECT + - col1 + col0 * - cor0.col2 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL cor0.col1 + col1 * ( col2 + + col1 ) AS col2 FROM tab1 cor0
----
1430
2106
680

query I rowsort
SELECT - 14 * + 39 + col0 * 39 + + 47 AS col2 FROM tab1
----
-382
1997
2621

query I rowsort
SELECT - 19 AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

query I rowsort
SELECT ALL ( col2 ) * col0 + ( - col2 ) FROM tab0
----
34
7216
759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - cor0.col2 ) + col0 col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL ( - col1 ) + - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT col1 * 53 + - cor0.col0 FROM tab2 cor0
----
1636
3049
822

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3845
SELECT + CAST( ( - col0 ) AS SIGNED ) FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3845
SELECT + CAST ( ( - col0 ) AS INTEGER ) FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3846
SELECT DISTINCT col0 DIV col0 + col0 * 28 FROM tab2 AS cor0
----
197
2185
2213

skipif mysql # not compatible
query I rowsort label-3846
SELECT DISTINCT col0 / col0 + col0 * 28 FROM tab2 AS cor0
----
197
2185
2213

query I rowsort
SELECT DISTINCT + col2 + 99 * + col1 FROM tab0 cor0
----
8547
9091
9604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3848
SELECT ALL + + ( + col1 ) + - col2 + CAST( NULL AS DECIMAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3848
SELECT ALL + + ( + col1 ) + - col2 + CAST ( NULL AS REAL ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col0 * - col0 + - col1 AS col2 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL - 45 * + tab2.col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 917799f3ca6d72ba5d6cf2e056c894cf

query I rowsort
SELECT col1 + - col0 * - 14 * 40 + - col1 * + col2 FROM tab2 AS cor0
----
3114
42205
43611

query I rowsort
SELECT - - col0 + - col0 * - col2 FROM tab0 cor0
----
70
7387
816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3853
SELECT - CAST( NULL AS SIGNED ) col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3853
SELECT - CAST ( NULL AS INTEGER ) col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - - 7 + - col2 AS col2 FROM tab1 cor0
----
-47
-50
-89

query I rowsort
SELECT ALL col0 + - col1 * + col0 * + col2 AS col1 FROM tab0
----
-3360
-664029
-68088

query I rowsort
SELECT + col2 * col1 + - col2 + + ( ( - cor0.col1 ) ) AS col0 FROM tab0 AS cor0
----
-1
2719
7289

query I rowsort
SELECT ALL - col2 * + col2 + + col2 + + 64 AS col2 FROM tab2 AS cor0
----
-1342
-586
-638

query I rowsort
SELECT + ( col2 ) * - col1 + - col1 + col2 * col0 FROM tab0 AS cor0
----
-159
-2132
-255

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3859
SELECT - CAST( NULL AS DECIMAL ) / cor0.col0 + - col0 * - 58 + 74 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3859
SELECT - CAST ( NULL AS REAL ) / cor0.col0 + - col0 * - 58 + 74 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - tab1.col0 FROM tab1, tab0, tab0 cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab2 cor1, tab0, tab0 cor2
----
3645 values hashing to a5677c50b23f70287df35c2388a1c9bf

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab1, tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort
SELECT - - col0 + + CAST ( - col2 AS REAL ) * col2 FROM tab2 AS cor0
----
-1365
-598
-722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3864
SELECT + col0 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3864
SELECT + col0 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + + col0 * 85 FROM tab1 AS cor0
----
281
5450
6813

query I rowsort
SELECT - col1 + - 57 AS col1 FROM tab0 cor0
----
-143
-148
-154

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - 82 col1 FROM tab2 AS cor0
----
-2132
-2214
-3116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 99 + + col0 * col2 col1 FROM tab0 AS cor0
----
16109
3168
3500

query I rowsort
SELECT - col0 + + 33 AS col1 FROM tab2
----
-45
-46
26

query I rowsort
SELECT ALL col2 * ( 16 ) FROM tab1
----
1536
864
912

query I rowsort
SELECT + col1 + col1 * col0 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + + col2 * - 60 FROM tab0 AS cor0
----
-1980
-4920
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3873
SELECT DISTINCT + col1 DIV + cor0.col1 - + 60 DIV col0 AS col0 FROM tab1 cor0
----
-19
1

skipif mysql # not compatible
query I rowsort label-3873
SELECT DISTINCT + col1 / + cor0.col1 - + 60 / col0 AS col0 FROM tab1 cor0
----
-19
1

query I rowsort
SELECT DISTINCT + col0 * + ( col2 ) - col1 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-3875
SELECT ALL col1 DIV ( + col2 ) AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3875
SELECT ALL col1 / ( + col2 ) AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT - - col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col2 - + 98 FROM tab0 AS cor0
----
-131
-180
-99

query I rowsort
SELECT DISTINCT 83 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
83

query I rowsort
SELECT DISTINCT + col2 * + ( col2 ) AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT ALL + cor0.col0 + col0 * - 65 AS col2 FROM tab1 cor0
----
-192
-4096
-5120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + col1 col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL col0 * cor0.col0 AS col1 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT + col1 * - cor0.col2 + + col0 + + col1 FROM tab2 AS cor0
----
-1397
-550
-799

query I rowsort
SELECT - + col2 + + col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT col0 + + cor0.col2 + + ( col0 ) * col0 FROM tab0 cor0
----
1261
633
8092

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 37 + + col0 + - col2 col2 FROM tab1 AS cor0
----
-30
-53
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * col1 col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3888
SELECT 39 DIV cor0.col2 col0 FROM tab0 AS cor0
----
0
1
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3888
SELECT 39 / cor0.col2 col0 FROM tab0 AS cor0
----
0
1
39

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) FROM tab1, tab2 cor0
----
17
31
59

query I rowsort
SELECT 14 * + 29 AS col2 FROM tab0
----
406
406
406

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 11 col0 FROM tab1, tab0 cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT ALL + 62 * 68 FROM tab2
----
4216
4216
4216

query I rowsort
SELECT DISTINCT 44 AS col2 FROM tab1
----
44

query I rowsort
SELECT DISTINCT 89 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
89

query I rowsort
SELECT ALL 52 * - col0 AS col2 FROM tab2
----
-364
-4056
-4108

query I rowsort
SELECT ( + col0 ) * col2 + + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + + 62 FROM tab0, tab1, tab1 cor0, tab2
----
62

query I rowsort
SELECT + ( + col2 * col1 ) AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT + - 66 FROM tab2, tab0, tab1 cor0
----
-66

query I rowsort
SELECT + col0 * 52 * - col1 + ( - col1 + col2 ) * col1 FROM tab2
----
-11408
-241251
-69479

query I rowsort
SELECT col0 + 76 FROM tab1
----
140
156
79

query I rowsort
SELECT ( 2 ) + col2 AS col0 FROM tab2 cor0
----
28
29
40

query I rowsort
SELECT ALL + col0 * 82 + + cor0.col2 FROM tab1 cor0
----
300
5305
6656

onlyif mysql # use DIV operator for integer division
query I rowsort label-3904
SELECT + col2 * cor0.col2 DIV + col0 + col0 FROM tab1 AS cor0
----
114
195
975

skipif mysql # not compatible
query I rowsort label-3904
SELECT + col2 * cor0.col2 / + col0 + col0 FROM tab1 AS cor0
----
114
195
975

query I rowsort
SELECT ALL ( 90 ) + cor0.col0 * + col2 * - col0 FROM tab2 AS cor0
----
-1233
-158094
-237068

query I rowsort
SELECT DISTINCT - 50 - col1 AS col0 FROM tab2 AS cor0
----
-109
-67
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 2 AS REAL ) col2 FROM tab2
----
2
2
2

query I rowsort
SELECT DISTINCT 82 + - tab2.col0 + tab2.col1 FROM tab2, tab2 AS cor0
----
106
20
63

query I rowsort
SELECT ALL - col2 + - col1 + - col1 FROM tab2 cor0
----
-144
-72
-89

query I rowsort
SELECT DISTINCT - 47 + - col2 AS col2 FROM tab2 AS cor0
----
-73
-74
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 12 col2 FROM tab1 AS cor0
----
12
12
12

query I rowsort
SELECT DISTINCT + col0 + + col1 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - ( + col1 ) + - cor0.col1 AS col2 FROM tab0 cor0
----
-172
-182
-194

query I rowsort
SELECT - 66 AS col1 FROM tab2 cor0
----
-66
-66
-66

query I rowsort
SELECT + 35 * col2 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT 70 + col0 FROM tab0 AS cor0
----
105
159
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3917
SELECT DISTINCT - col1 DIV ( + 27 ) FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3917
SELECT DISTINCT - col1 / ( + 27 ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col2 * ( 1 ) + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - col1 * col1 + col2 FROM tab2 AS cor0
----
-251
-3455
-934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3920
SELECT DISTINCT - col2 + CAST( - col0 + col1 AS SIGNED ) FROM tab1 cor0
----
-111
-163
-31

skipif mysql # not compatible
query I rowsort label-3920
SELECT DISTINCT - col2 + CAST ( - col0 + col1 AS INTEGER ) FROM tab1 cor0
----
-111
-163
-31

query I rowsort
SELECT - col1 * col1 + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL + col2 * 6 FROM tab2 AS cor0
----
156
162
228

query I rowsort
SELECT DISTINCT + 52 + cor0.col2 FROM tab1, tab1 AS cor0
----
106
109
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT DISTINCT col2 DIV + 30 AS col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3924
SELECT DISTINCT col2 / + 30 AS col0 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT DISTINCT col1 + col1 * + 32 AS col0 FROM tab2 AS cor0
----
1023
1947
561

skipif mysql # not compatible
query I rowsort
SELECT col2 + + CAST ( - 11 AS REAL ) FROM tab1 AS cor0
----
43
46
85

query I rowsort
SELECT ALL col2 * col0 + 99 FROM tab0 AS cor0
----
134
7397
891

onlyif mysql # use DIV operator for integer division
query I rowsort label-3928
SELECT ALL - col2 DIV + 58 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3928
SELECT ALL - col2 / + 58 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col1 * - col0 - col0 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3930
SELECT DISTINCT col1 * CAST( NULL AS DECIMAL ) + + col2 + col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3930
SELECT DISTINCT col1 * CAST ( NULL AS REAL ) + + col2 + col2 FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL - - col2 - - 1 * + col1 * - col2 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-3932
SELECT ALL col1 + cor0.col1 DIV col0 FROM tab0 AS cor0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-3932
SELECT ALL col1 + cor0.col1 / col0 FROM tab0 AS cor0
----
89
92
99

query I rowsort
SELECT col1 * - 72 AS col1 FROM tab2 cor0
----
-1224
-2232
-4248

query I rowsort
SELECT DISTINCT + - cor0.col1 * ( - 63 ) FROM tab1 AS cor0
----
1638
630
819

query I rowsort
SELECT ALL col1 * - 96 + col1 AS col0 FROM tab1 cor0
----
-1235
-2470
-950

query I rowsort
SELECT ALL 99 AS col1 FROM tab2 AS cor0
----
99
99
99

query I rowsort
SELECT ALL 0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + col0 * - col0 + - cor0.col1 * - 8 FROM tab1 AS cor0
----
-4016
-6296
199

query I rowsort
SELECT - - col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col1 * - 49 + + col1 AS col2 FROM tab1 AS cor0
----
-1248
-480
-624

query I rowsort
SELECT DISTINCT + col1 + + col1 - col1 * 60 AS col1 FROM tab2 AS cor0
----
-1798
-3422
-986

onlyif mysql # use DIV operator for integer division
query I rowsort label-3942
SELECT ALL ( col2 ) - + col1 DIV - ( cor0.col2 ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3942
SELECT ALL ( col2 ) - + col1 / - ( cor0.col2 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - 32 AS col0 FROM tab2, tab0 AS cor0
----
-32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col1 ) * cor0.col2 + 7 + + cor0.col1 col1 FROM tab0 AS cor0
----
201
2931
7560

query I rowsort
SELECT - col2 + 82 * col0 FROM tab1 AS cor0
----
192
5191
6464

query I rowsort
SELECT - - col2 * + 44 + + col0 FROM tab0 AS cor0
----
1476
3697
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 8 * 76 + - col1 col0 FROM tab2 AS cor0
----
-625
-639
-667

query I rowsort
SELECT DISTINCT col2 * 80 * + cor0.col1 FROM tab0 AS cor0
----
227040
596960
7760

query I rowsort
SELECT ALL + cor0.col0 + col1 * - cor0.col0 FROM tab1 cor0
----
-576
-75
-960

query I rowsort
SELECT + col1 + + col1 + col1 AS col1 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT - 71 * + col1 FROM tab1 AS cor0
----
-1846
-710
-923

query I rowsort
SELECT + - col1 + ( col0 ) * col1 AS col0 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3954
SELECT ALL col0 + + 61 * ( tab1.col0 ) + ( col2 ) DIV col2 col0 FROM tab1
----
187
3969
4961

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3954
SELECT ALL col0 + + 61 * ( tab1.col0 ) + ( col2 ) / col2 col0 FROM tab1
----
187
3969
4961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 * + col2 + col2 * + col2 * + 8 col0 FROM tab1
----
20412
22743
64512

query I rowsort
SELECT DISTINCT + col0 * col1 + - tab2.col0 FROM tab2
----
1264
210
4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-3957
SELECT ALL - col0 DIV + ( tab0.col2 ) + + col2 AS col2 FROM tab0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-3957
SELECT ALL - col0 / + ( tab0.col2 ) + + col2 AS col2 FROM tab0
----
-34
33
81

query I rowsort
SELECT - col2 * col1 + col2 + col0 * - 17 FROM tab0
----
-3213
-691
-8893

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3959
SELECT CAST( col0 AS SIGNED ) * + col2 + - col2 FROM tab0 AS cor0
----
34
7216
759

skipif mysql # not compatible
query I rowsort label-3959
SELECT CAST ( col0 AS INTEGER ) * + col2 + - col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT 28 * cor0.col1 FROM tab0, tab0 cor0
----
9 values hashing to a332cfd25dcf64ec1aac7d898652e988

query I rowsort
SELECT - tab1.col0 AS col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT 62 + col2 * + 85 FROM tab1 AS cor0
----
4652
4907
8222

query I rowsort
SELECT DISTINCT + 17 AS col0 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
17

query I rowsort
SELECT - col1 * - col0 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT col0 * col0 * + col0 AS col0 FROM tab1
----
262144
27
512000

query I rowsort
SELECT DISTINCT cor0.col0 + - 83 AS col1 FROM tab0, tab1 AS cor0
----
-19
-3
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3967
SELECT col1 DIV - 1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3967
SELECT col1 / - 1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col0 * 64 + col0 * tab1.col0 FROM tab1
----
11520
201
8192

query I rowsort
SELECT DISTINCT - col2 * + 67 FROM tab2
----
-1742
-1809
-2546

query I rowsort
SELECT - col0 * + ( + 42 ) FROM tab2
----
-294
-3276
-3318

query I rowsort
SELECT ALL - cor0.col0 * + 39 FROM tab1 cor0
----
-117
-2496
-3120

query I rowsort
SELECT + col0 * - 35 * col2 FROM tab0 AS cor0
----
-1225
-255430
-27720

onlyif mysql # use DIV operator for integer division
query I rowsort label-3973
SELECT col2 DIV col1 + - 23 + col0 FROM tab2 AS cor0
----
-16
55
58

skipif mysql # not compatible
query I rowsort label-3973
SELECT col2 / col1 + - 23 + col0 FROM tab2 AS cor0
----
-16
55
58

query I rowsort
SELECT - col1 * - 14 AS col2 FROM tab0 AS cor0
----
1204
1274
1358

query I rowsort
SELECT + 83 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT DISTINCT - col2 * 50 AS col0 FROM tab2 AS cor0
----
-1300
-1350
-1900

query I rowsort
SELECT + 55 FROM tab1 cor0
----
55
55
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-3978
SELECT ALL - col1 + - cor0.col1 DIV ( col1 ) FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-3978
SELECT ALL - col1 + - cor0.col1 / ( col1 ) FROM tab1 AS cor0
----
-11
-14
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col1 - - 87 * + col1 col0 FROM tab1 cor0
----
1586
770
962

query I rowsort
SELECT - ( col1 ) * - ( - col0 ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT cor0.col2 * - col1 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT 33 * + col1 FROM tab0 AS cor0
----
2838
3003
3201

onlyif mysql # use DIV operator for integer division
query I rowsort label-3983
SELECT ALL - - 75 DIV col0 AS col1 FROM tab2 AS cor0
----
0
0
10

skipif mysql # not compatible
query I rowsort label-3983
SELECT ALL - - 75 / col0 AS col1 FROM tab2 AS cor0
----
0
0
10

query I rowsort
SELECT + + 17 AS col0 FROM tab2 cor0
----
17
17
17

query I rowsort
SELECT ALL - + 46 * - col1 + col2 FROM tab1 AS cor0
----
1250
517
694

query I rowsort
SELECT - - ( - col1 ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL col0 * - col0 * - 85 FROM tab1
----
348160
544000
765

query I rowsort
SELECT - col1 * + ( - col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL cor0.col1 + - 3 FROM tab0, tab0 AS cor0
----
9 values hashing to 9af5bf694317f77e09b629bc8e60b619

query I rowsort
SELECT col2 * col2 * + 55 AS col2 FROM tab1 AS cor0
----
160380
178695
506880

query I rowsort
SELECT cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + 71 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT - col2 * + cor0.col1 * + col1 FROM tab1 cor0
----
-16224
-36504
-5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * cor0.col0 col0 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-3995
SELECT - col0 * 63 DIV col1 AS col0 FROM tab0 AS cor0
----
-17
-22
-61

skipif mysql # not compatible
query I rowsort label-3995
SELECT - col0 * 63 / col1 AS col0 FROM tab0 AS cor0
----
-17
-22
-61

query I rowsort
SELECT + + cor0.col0 + - 75 + col1 FROM tab1 cor0
----
-1
-46
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-3997
SELECT DISTINCT col1 + - ( col2 ) DIV col2 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3997
SELECT DISTINCT col1 + - ( col2 ) / col2 FROM tab1
----
12
25
9

query I rowsort
SELECT + + cor0.col0 + cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8733ba2dd568938e338b27ad757d3e3b

query I rowsort
SELECT 44 + + col0 * + col0 AS col0 FROM tab2
----
6128
6285
93

query I rowsort
SELECT + 74 - col0 * + col1 AS col2 FROM tab1
----
-4
-566
-966

query I rowsort
SELECT ALL + - 48 + 75 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT col1 + col1 * col2 FROM tab2
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4003
SELECT ALL ( + col2 ) DIV col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4003
SELECT ALL ( + col2 ) / col0 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT + 69 * - col2 * col2 + ( col1 ) * col0 FROM tab0
----
-455857
-73077
3326

query I rowsort
SELECT + col2 + col2 * col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + - col1 + 28 AS col2 FROM tab2 AS cor0
----
-3
-31
11

query I rowsort
SELECT ALL - tab0.col0 - + tab0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to aac9661904614ee295157ea355327523

query I rowsort
SELECT DISTINCT col1 * - col2 + col2 * + col2 FROM tab1
----
1512
2679
7968

query I rowsort
SELECT ( 25 ) FROM tab2
----
25
25
25

query I rowsort
SELECT + - 89 * + 57 + col2 FROM tab0 AS cor0
----
-4991
-5040
-5072

query I rowsort
SELECT ALL - - col1 * - col1 + + col0 AS col2 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT col2 + - 98 FROM tab2 AS cor0
----
-60
-71
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) * - 77 + cor0.col0 col1 FROM tab0 AS cor0
----
-6598
-6918
-7434

onlyif mysql # use DIV operator for integer division
query I rowsort label-4014
SELECT ALL + + col0 * - col1 + + 1 DIV + 65 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-4014
SELECT ALL + + col0 * - col1 + + 1 / + 65 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - tab1.col1 * col0 - - col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT col0 + - cor0.col0 AS col0 FROM tab0 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * col1 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - - ( - col0 ) + - col2 * - col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT 85 AS col0 FROM tab1 AS cor0
----
85

query I rowsort
SELECT ALL tab1.col0 + ( col2 * - col1 + col2 ) AS col1 FROM tab1
----
-1072
-1347
-449

onlyif mysql # use DIV operator for integer division
query I rowsort label-4021
SELECT DISTINCT - col0 DIV + cor0.col2 + + col2 DIV col0 col1 FROM tab1 AS cor0
----
-1
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4021
SELECT DISTINCT - col0 / + cor0.col2 + + col2 / col0 col1 FROM tab1 AS cor0
----
-1
1
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4022
SELECT DISTINCT + col0 * 77 * - 42 + - col2 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4022
SELECT DISTINCT + col0 * 77 * - 42 + - col2 * + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - col1 + 44 AS col1 FROM tab2 AS cor0
----
-15
13
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4024
SELECT ALL - - col1 * CAST( NULL AS SIGNED ) + - cor0.col2 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4024
SELECT ALL - - col1 * CAST ( NULL AS INTEGER ) + - cor0.col2 * - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4025
SELECT DISTINCT - 53 DIV col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-4025
SELECT DISTINCT - 53 / col0 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT + 86 - cor0.col1 AS col1 FROM tab1 cor0
----
60
73
76

query I rowsort
SELECT ALL + 53 + col1 * + col1 AS col2 FROM tab0 AS cor0
----
7449
8334
9462

query I rowsort
SELECT + - 6 * + 80 FROM tab0 AS cor0
----
-480
-480
-480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4029
SELECT DISTINCT CAST( NULL AS SIGNED ) - cor0.col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4029
SELECT DISTINCT CAST ( NULL AS INTEGER ) - cor0.col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 46 AS col1 FROM tab2 AS cor0
----
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 7 + - col2 col2 FROM tab1 cor0
----
-103
-61
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4032
SELECT - col1 DIV 17 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4032
SELECT - col1 / 17 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + - 93 * col2 * + col0 + col2 AS col0 FROM tab0 AS cor0
----
-3254
-678632
-73623

query I rowsort
SELECT DISTINCT - col2 + + 74 FROM tab1 AS cor0
----
-22
17
20

query I rowsort
SELECT + ( col2 ) + + cor0.col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4036
SELECT ALL + CAST( NULL AS DECIMAL ) * - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4036
SELECT ALL + CAST ( NULL AS REAL ) * - cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4037
SELECT ALL col1 DIV + col1 + col2 * col0 * col1 col2 FROM tab0 AS cor0
----
3396
664119
68113

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4037
SELECT ALL col1 / + col1 + col2 * col0 * col1 col2 FROM tab0 AS cor0
----
3396
664119
68113

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - - ( + 12 ) AS col0 FROM tab0 AS cor0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 64 * - 83 - col0 col0 FROM tab2 AS cor0
----
5233
5234
5305

query I rowsort
SELECT DISTINCT 34 FROM tab0, tab0 AS cor0
----
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - - col0 * tab1.col0 col0 FROM tab1
----
4153
63
6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4043
SELECT ALL tab2.col1 - CAST( col2 + + col0 AS SIGNED ) FROM tab2
----
-100
-3
-45

skipif mysql # not compatible
query I rowsort label-4043
SELECT ALL tab2.col1 - CAST ( col2 + + col0 AS INTEGER ) FROM tab2
----
-100
-3
-45

query I rowsort
SELECT ALL + col1 * - ( 0 ) - + col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - col1 * - col2 + + 40 + col0 * col1 FROM tab2 AS cor0
----
1094
2029
6176

query I rowsort
SELECT - - col1 + cor0.col2 + col2 FROM tab2 AS cor0
----
111
85
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4047
SELECT col0 * CAST( 51 * - col1 AS SIGNED ) + 98 + + col1 FROM tab1 AS cor0
----
-32532
-3854
-52929

skipif mysql # not compatible
query I rowsort label-4047
SELECT col0 * CAST ( 51 * - col1 AS INTEGER ) + 98 + + col1 FROM tab1 AS cor0
----
-32532
-3854
-52929

query I rowsort
SELECT DISTINCT 17 * + tab0.col2 * - tab0.col0 + col1 AS col0 FROM tab0
----
-123975
-13378
-498

query I rowsort
SELECT - tab2.col1 - + tab2.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 679222606429bc7195f6dbd388ba1980

query I rowsort
SELECT col2 * + col0 + tab0.col2 AS col1 FROM tab0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-4051
SELECT ALL + cor0.col2 * - 98 - col2 DIV + col1 AS col2 FROM tab1 AS cor0
----
-5294
-5591
-9415

skipif mysql # not compatible
query I rowsort label-4051
SELECT ALL + cor0.col2 * - 98 - col2 / + col1 AS col2 FROM tab1 AS cor0
----
-5294
-5591
-9415

query I rowsort
SELECT + cor0.col0 * - cor0.col1 + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col2 * + col2 + col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - cor0.col0 * 29 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to ab477c413ddf2523c5c060170e45760c

onlyif mysql # use DIV operator for integer division
query I rowsort label-4055
SELECT + col0 DIV 87 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4055
SELECT + col0 / 87 FROM tab0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4056
SELECT + col1 DIV 13 + col2 * 89 AS col0 FROM tab1
----
4808
5073
8545

skipif mysql # not compatible
query I rowsort label-4056
SELECT + col1 / 13 + col2 * 89 AS col0 FROM tab1
----
4808
5073
8545

onlyif mysql # use DIV operator for integer division
query I rowsort label-4057
SELECT - - 18 + col0 * col2 DIV 35 FROM tab0 AS cor0
----
19
226
40

skipif mysql # not compatible
query I rowsort label-4057
SELECT - - 18 + col0 * col2 / 35 FROM tab0 AS cor0
----
19
226
40

query I rowsort
SELECT ALL + - 52 + - 7 AS col1 FROM tab2 AS cor0
----
-59
-59
-59

query I rowsort
SELECT DISTINCT 0 * + 73 AS col0 FROM tab2
----
0

query I rowsort
SELECT - + col2 * 70 AS col2 FROM tab1 cor0
----
-3780
-3990
-6720

query I rowsort
SELECT DISTINCT col0 * + col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL 95 * + col2 + + col1 FROM tab0
----
192
3221
7881

query I rowsort
SELECT ( - 33 * - col2 ) AS col1 FROM tab2
----
1254
858
891

query I rowsort
SELECT + + col2 + - col0 + - 64 FROM tab0 AS cor0
----
-55
-71
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4065
SELECT - col2 + cor0.col1 + col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-28
-46
-83

skipif mysql # not compatible
query I rowsort label-4065
SELECT - col2 + cor0.col1 + col0 / col2 AS col0 FROM tab1 AS cor0
----
-28
-46
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4066
SELECT DISTINCT cor0.col0 * cor0.col0 DIV 42 FROM tab0 AS cor0
----
13
188
29

skipif mysql # not compatible
query I rowsort label-4066
SELECT DISTINCT cor0.col0 * cor0.col0 / 42 FROM tab0 AS cor0
----
13
188
29

query I rowsort
SELECT ALL - + 36 + col1 * 4 AS col0 FROM tab2 AS cor0
----
200
32
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4068
SELECT ALL + - ( - cor0.col1 ) + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4068
SELECT ALL + - ( - cor0.col1 ) + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 * col1 * col1 AS col0 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + - 8 * col2 FROM tab1 cor0
----
-432
-456
-768

query I rowsort
SELECT - col2 - cor0.col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4072
SELECT col0 + col1 * col1 DIV + col1 + - col1 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4072
SELECT col0 + col1 * col1 / + col1 + - col1 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + 73 * + col1 + 86 * col2 FROM tab1 AS cor0
----
5632
6542
9205

query I rowsort
SELECT DISTINCT - - col0 + col1 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4075
SELECT - - ( col1 ) DIV ( + col0 ) + + col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-4075
SELECT - - ( col1 ) / ( + col0 ) + + col2 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT 2 * + col2 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4077
SELECT - 90 DIV + col1 FROM tab1
----
-3
-6
-9

skipif mysql # not compatible
query I rowsort label-4077
SELECT - 90 / + col1 FROM tab1
----
-3
-6
-9

query I rowsort
SELECT ( col1 ) * + ( col0 ) FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4079
SELECT - col2 DIV + col0 AS col2 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4079
SELECT - col2 / + col0 AS col2 FROM tab0
----
-1
0
0

query I rowsort
SELECT + ( + col2 ) * - col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4081
SELECT - col2 * - col0 DIV + col0 + + cor0.col2 FROM tab1 cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-4081
SELECT - col2 * - col0 / + col0 + + cor0.col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT col1 * - col2 * - col0 - - col1 FROM tab1 AS cor0
----
36490
4238
99853

onlyif mysql # use DIV operator for integer division
query I rowsort label-4083
SELECT col1 DIV col0 + - 23 * col2 + 32 AS col2 FROM tab0 AS cor0
----
-1853
-724
11

skipif mysql # not compatible
query I rowsort label-4083
SELECT col1 / col0 + - 23 * col2 + 32 AS col2 FROM tab0 AS cor0
----
-1853
-724
11

query I rowsort
SELECT + col0 * + col0 + + 29 FROM tab0 AS cor0
----
1254
605
7950

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 * - ( 12 * + col1 ) col2 FROM tab2
----
273972
3258216
80724

query I rowsort
SELECT + tab0.col1 * - col2 * 28 AS col2 FROM tab0
----
-208936
-2716
-79464

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4087
SELECT ALL 90 + - col1 / - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4087
SELECT ALL 90 + - col1 / - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 74 * tab1.col0 + + col1 FROM tab1
----
248
4746
5933

query I rowsort
SELECT - col1 + - col1 + - 32 * + col1 AS col1 FROM tab0 AS cor0
----
-2924
-3094
-3298

query I rowsort
SELECT - col0 + + col1 - 31 FROM tab0 cor0
----
-29
31
31

query I rowsort
SELECT DISTINCT + 26 * col1 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT - - 45 AS col0 FROM tab1 AS cor0
----
45
45
45

query I rowsort
SELECT ALL - cor0.col0 * col0 + + col0 AS col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT col0 * col1 - col1 * + col1 AS col1 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT - + ( ( col1 ) ) + col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT col2 + - 91 * col1 FROM tab1
----
-1087
-2312
-853

query I rowsort
SELECT - ( + col2 ) AS col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL + col0 * + tab0.col0 + col0 * + col1 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT DISTINCT - col0 * tab1.col1 * + tab1.col0 AS col1 FROM tab1 WHERE NOT NULL IN ( tab1.col0 * col0 )
----

query I rowsort
SELECT DISTINCT col1 * col1 * col0 + tab1.col2 FROM tab1
----
13616
2082
6457

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col1 + - tab0.col2 col1 FROM tab0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col0 * - col1 col1 FROM tab2 WHERE + col1 + + col2 * + col2 NOT IN ( col1 + tab2.col0 )
----
-106097
-1519
-358956

query I rowsort
SELECT + col1 + tab1.col0 FROM tab1 WHERE NULL >= ( col1 )
----

query I rowsort
SELECT DISTINCT col2 / - col2 FROM tab0 WHERE NOT ( + col2 ) NOT BETWEEN - col2 * col2 AND ( NULL )
----

query I rowsort
SELECT DISTINCT - col0 * col1 + + col2 * col0 FROM tab1
----
3008
6640
84

query I rowsort
SELECT + col1 * col0 * col2 + + col2 FROM tab0
----
3396
664200
68145

query I rowsort
SELECT DISTINCT + col2 + - col2 AS col0 FROM tab2 WHERE ( col0 ) IN ( + col0 )
----
0

query I rowsort
SELECT ALL col0 + - col0 * + col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL + col2 * tab1.col0 + + tab1.col0 FROM tab1
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * + tab2.col1 col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL col1 AS col2 FROM tab1 WHERE NOT - col0 IN ( + col1 * - col1 * col0 )
----
10
13
26

query I rowsort
SELECT DISTINCT - col2 * - col2 FROM tab0 WHERE ( NULL ) NOT IN ( col2 * col0 + + col0 )
----

query I rowsort
SELECT DISTINCT - col2 * col0 + ( col1 ) FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-4114
SELECT DISTINCT - col2 * col1 * + col2 + - col2 DIV - tab2.col0 AS col2 FROM tab2
----
-22596
-24548
-39884

skipif mysql # not compatible
query I rowsort label-4114
SELECT DISTINCT - col2 * col1 * + col2 + - col2 / - tab2.col0 AS col2 FROM tab2
----
-22596
-24548
-39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 22 * + col0 + ( - col1 ) * + col0 - 71 col2 FROM tab2 AS cor0
----
-134
-2957
324

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 + col0 NOT IN ( + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4117
SELECT + col0 DIV col1 + col1 + + tab2.col2 * col0 AS col1 FROM tab2
----
2088
220
3023

skipif mysql # not compatible
query I rowsort label-4117
SELECT + col0 / col1 + col1 + + tab2.col2 * col0 AS col1 FROM tab2
----
2088
220
3023

query III rowsort
SELECT * FROM tab0 WHERE NOT - col2 + col1 NOT IN ( + tab0.col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * + col2 col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL - col0 * col1 + col1 FROM tab2
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 * - col2 col2 FROM tab1 cor0
----
-119808
-32490
-75816

query I rowsort
SELECT + col1 + - cor0.col2 * - col2 + - col2 AS col1 FROM tab0 AS cor0
----
1142
6733
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4123
SELECT DISTINCT - col2 DIV - col0 - - col2 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-4123
SELECT DISTINCT - col2 / - col0 - - col2 FROM tab1 AS cor0
----
57
72
97

query I rowsort
SELECT cor0.col0 - - col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col0 + - col0 + col1 AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT + col1 FROM tab1 WHERE ( - col1 * + col0 ) NOT BETWEEN NULL AND + col1
----

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col1 - col0 <> ( NULL )
----

query I rowsort
SELECT ALL - tab2.col1 - col0 AS col1 FROM tab2
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4130
SELECT - col2 * col2 + + col1 DIV col1 AS col1 FROM tab2
----
-1443
-675
-728

skipif mysql # not compatible
query I rowsort label-4130
SELECT - col2 * col2 + + col1 / col1 AS col1 FROM tab2
----
-1443
-675
-728

query I rowsort
SELECT DISTINCT col1 * + col0 + col2 * tab2.col2 FROM tab2
----
2787
5278
946

query III rowsort
SELECT ALL * FROM tab1 WHERE + col1 BETWEEN col2 AND ( col2 + + col1 * + col2 )
----

query I rowsort
SELECT col2 + + tab2.col2 FROM tab2 WHERE + col0 NOT IN ( col1 )
----
52
54
76

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT + col1 NOT IN ( col0 )
----

query I rowsort
SELECT col2 * col0 + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT tab1.col2 + col0 * + tab1.col0 AS col1 FROM tab1
----
4153
63
6496

query I rowsort
SELECT + col1 FROM tab2 cor0 WHERE NOT ( col1 ) IN ( cor0.col0 )
----
17
31
59

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT ( col0 ) <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + tab0.col0 + col1 * + col2 col2 FROM tab0
----
164
2046
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4140
SELECT col2 * tab1.col1 DIV col0 AS col2 FROM tab1
----
15
468
8

skipif mysql # not compatible
query I rowsort label-4140
SELECT col2 * tab1.col1 / col0 AS col2 FROM tab1
----
15
468
8

query I rowsort
SELECT ALL - col0 + + tab1.col2 * col1 + col1 * col2 AS col1 FROM tab1
----
1076
2416
2805

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col2 * - col1 col0 FROM tab0
----
-2838
-7462
-97

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 35707ade138fec4b370f5140a4cd2963

query I rowsort
SELECT DISTINCT + 86 + - 16 FROM tab0 AS cor0
----
70

query I rowsort
SELECT 37 * + col2 - col2 FROM tab2 cor0
----
1368
936
972

query I rowsort
SELECT DISTINCT - col1 * ( - col1 ) FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + 69 * + col1 + cor0.col2 AS col1 FROM tab2 cor0
----
1211
2166
4097

query I rowsort
SELECT DISTINCT + col2 + col0 * tab1.col0 - col0 FROM tab1
----
4089
60
6416

query I rowsort
SELECT col1 * - 59 * col2 FROM tab1
----
-33630
-73632
-82836

query I rowsort
SELECT ALL 57 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT - col1 + + col0 AS col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT col2 * col2 + tab0.col2 FROM tab0
----
1122
2
6806

query I rowsort
SELECT ALL + ( - col1 ) + - col2 * - 97 FROM tab1
----
5212
5519
9299

query I rowsort
SELECT DISTINCT + 24 * - col2 + col1 * + 88 FROM tab2
----
2080
4568
584

query I rowsort
SELECT DISTINCT + ( + 18 ) + + tab0.col0 AS col1 FROM tab0
----
107
42
53

query I rowsort
SELECT ALL + ( - cor0.col0 ) AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT + col0 + 31 AS col2 FROM tab0 AS cor0
----
120
55
66

query I rowsort
SELECT ALL - ( col2 ) * cor0.col2 * - 99 AS col1 FROM tab0 AS cor0
----
107811
665676
99

query I rowsort
SELECT ALL - ( + col0 ) * + col0 * + col0 FROM tab2 AS cor0
----
-343
-474552
-493039

onlyif mysql # use DIV operator for integer division
query I rowsort label-4160
SELECT ALL - + 41 + 78 DIV + col1 col2 FROM tab1 AS cor0
----
-34
-35
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4160
SELECT ALL - + 41 + 78 / + col1 col2 FROM tab1 AS cor0
----
-34
-35
-38

query I rowsort
SELECT + 37 * col1 * - col1 + col0 AS col0 FROM tab1 AS cor0
----
-25009
-3636
-6173

query I rowsort
SELECT 2 + 94 FROM tab0 AS cor0
----
96
96
96

query I rowsort
SELECT DISTINCT 25 * cor0.col0 * - col1 AS col0 FROM tab0 AS cor0
----
-202475
-51600
-84875

query I rowsort
SELECT col0 * - col2 + - col0 FROM tab0
----
-70
-7387
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4165
SELECT col1 * - CAST( 28 * col0 AS SIGNED ) + + ( - 4 ) AS col0 FROM tab0 AS cor0
----
-226776
-57796
-95064

skipif mysql # not compatible
query I rowsort label-4165
SELECT col1 * - CAST ( 28 * col0 AS INTEGER ) + + ( - 4 ) AS col0 FROM tab0 AS cor0
----
-226776
-57796
-95064

query I rowsort
SELECT DISTINCT + cor0.col2 + + cor0.col1 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4167
SELECT + + col1 + col1 DIV + col0 FROM tab2 cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-4167
SELECT + + col1 + col1 / + col0 FROM tab2 cor0
----
17
35
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4168
SELECT - - col2 - + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4168
SELECT - - col2 - + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col2 * cor0.col1 + col0 AS col2 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT - col0 * + 72 - col0 * col1 FROM tab0 AS cor0
----
-14507
-3792
-5915

query I rowsort
SELECT - col2 + 39 * - col2 FROM tab0 AS cor0
----
-1320
-3280
-40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + ( col1 ) col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT col0 * - col0 - col1 * + col2 * col2 AS col0 FROM tab1 AS cor0
----
-126208
-36586
-75825

query I rowsort
SELECT DISTINCT + - col1 * col2 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4175
SELECT + cor0.col1 DIV ( 87 ) AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4175
SELECT + cor0.col1 / ( 87 ) AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4176
SELECT cor0.col1 DIV ( 35 * cor0.col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4176
SELECT cor0.col1 / ( 35 * cor0.col1 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4177
SELECT DISTINCT ( - col1 ) DIV - col0 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-4177
SELECT DISTINCT ( - col1 ) / - col0 FROM tab2 cor0
----
0
4

query I rowsort
SELECT ALL - 25 * + col1 AS col2 FROM tab0 AS cor0
----
-2150
-2275
-2425

query I rowsort
SELECT - + col1 * 89 FROM tab1 AS cor0
----
-1157
-2314
-890

onlyif mysql # use DIV operator for integer division
query I rowsort label-4180
SELECT DISTINCT - + ( col1 ) DIV col0 + + col0 FROM tab1 AS cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-4180
SELECT DISTINCT - + ( col1 ) / col0 + + col0 FROM tab1 AS cor0
----
-5
64
80

query I rowsort
SELECT DISTINCT + - col0 + + col2 * - col0 FROM tab2 cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4182
SELECT - ( col2 ) DIV + col1 + - col1 AS col0 FROM tab2 AS cor0
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-4182
SELECT - ( col2 ) / + col1 + - col1 AS col0 FROM tab2 AS cor0
----
-19
-31
-59

query I rowsort
SELECT DISTINCT - 21 * - col0 AS col0 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT ALL + col2 - 42 AS col1 FROM tab1
----
12
15
54

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT 74 + + tab1.col1 * + col1 + col2 AS col0 FROM tab1
----
231
339
804

query I rowsort
SELECT ALL col1 + 90 FROM tab0
----
176
181
187

query I rowsort
SELECT DISTINCT - 85 * + ( + col0 ) + col2 + + col2 FROM tab2
----
-541
-6578
-6639

query I rowsort
SELECT col2 + + col2 AS col0 FROM tab2 cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + + col0 col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT 44 + 1 * - tab1.col1 AS col1 FROM tab1
----
18
31
34

query I rowsort
SELECT DISTINCT + 34 FROM tab0
----
34

query I rowsort
SELECT DISTINCT - ( + col2 ) * + col0 AS col0 FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) * col1 col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT 39 + + col1 FROM tab2
----
56
70
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4196
SELECT DISTINCT 95 DIV - 31 + col2 * - col2 AS col2 FROM tab1
----
-2919
-3252
-9219

skipif mysql # not compatible
query I rowsort label-4196
SELECT DISTINCT 95 / - 31 + col2 * - col2 AS col2 FROM tab1
----
-2919
-3252
-9219

onlyif mysql # use DIV operator for integer division
query I rowsort label-4197
SELECT col1 * + col0 DIV + col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4197
SELECT col1 * + col0 / + col0 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4198
SELECT ALL col0 DIV tab1.col2 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4198
SELECT ALL col0 / tab1.col2 AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT ALL - cor0.col1 * ( 72 ) AS col0 FROM tab2 AS cor0
----
-1224
-2232
-4248

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col1 * - col0 col1 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL col2 * ( col0 ) * - col2 AS col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - 98 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9b0655947ad21e0b95a137a474fa6a1f

query I rowsort
SELECT 79 + tab1.col2 FROM tab1
----
133
136
175

query I rowsort
SELECT DISTINCT - 5 AS col2 FROM tab2
----
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 + tab1.col1 col2 FROM tab1
----
-63
-76
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4206
SELECT col0 * col2 + + col0 * col1 DIV + col1 AS col2 FROM tab1
----
165
3712
7760

skipif mysql # not compatible
query I rowsort label-4206
SELECT col0 * col2 + + col0 * col1 / + col1 AS col2 FROM tab1
----
165
3712
7760

query I rowsort
SELECT - ( - col2 * ( col2 ) ) AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 96 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
96

query I rowsort
SELECT col0 * - 79 + - col2 + col0 * col1 FROM tab1
----
-213
-4473
-5376

query I rowsort
SELECT DISTINCT col2 + tab0.col1 * col0 AS col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 * col0 * col2 AS col1 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT col0 * - 66 AS col2 FROM tab2 AS cor0
----
-462
-5148
-5214

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4214
SELECT DISTINCT + + col0 * CAST( col0 + - col1 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-14596
-2170
-49104

skipif mysql # not compatible
query I rowsort label-4214
SELECT DISTINCT + + col0 * CAST ( col0 + - col1 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-14596
-2170
-49104

query I rowsort
SELECT - col2 * ( 74 ) FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT DISTINCT - col2 * + col2 + - 59 FROM tab1 cor0
----
-2975
-3308
-9275

query I rowsort
SELECT ALL + + col2 + 18 - 23 * + col1 AS col0 FROM tab1 AS cor0
----
-155
-185
-526

query I rowsort
SELECT + col0 + 1 * - col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + col0 + col0 * - cor0.col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT col1 * + col1 * - col0 AS col2 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT col0 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + - cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + col1 + - col2 + col1 FROM tab0 AS cor0
----
100
139
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-4224
SELECT DISTINCT - tab2.col2 DIV - tab2.col1 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-4224
SELECT DISTINCT - tab2.col2 / - tab2.col1 FROM tab2
----
0
2

query I rowsort
SELECT - col0 * col1 AS col2 FROM tab0 WHERE NOT - col0 * col2 > NULL
----

query I rowsort
SELECT + col0 * - col0 * col1 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-4227
SELECT cor0.col0 DIV + col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-4227
SELECT cor0.col0 / + col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL col0 + + col0 * col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + 73 + col2 AS col0 FROM tab0 AS cor0
----
106
155
74

query I rowsort
SELECT - - col1 + col2 * - cor0.col0 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - - 50 + + col0 * + cor0.col1 AS col1 FROM tab0 cor0
----
2114
3445
8149

query I rowsort
SELECT DISTINCT + cor0.col1 + + cor0.col0 * - col1 + col2 AS col2 FROM tab1 AS cor0
----
-573
-931
2

query I rowsort
SELECT ALL + - col0 * - col2 * + col1 + col0 AS col0 FROM tab1 cor0
----
36544
4215
99920

query I rowsort
SELECT DISTINCT - 87 AS col0 FROM tab2 AS cor0
----
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + col0 + cor0.col1 col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL - + cor0.col0 * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL + + col2 + col0 * cor0.col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL col2 - tab1.col2 * - col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT 78 + - col2 + col0 AS col2 FROM tab1 AS cor0
----
27
62
85

query I rowsort
SELECT ALL + cor0.col2 AS col2 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4241
SELECT col2 + + col0 - + ( ( col2 ) ) * CAST( - 96 AS SIGNED ) AS col2 FROM tab1
----
5241
5593
9392

skipif mysql # not compatible
query I rowsort label-4241
SELECT col2 + + col0 - + ( ( col2 ) ) * CAST ( - 96 AS INTEGER ) AS col2 FROM tab1
----
5241
5593
9392

onlyif mysql # use DIV operator for integer division
query I rowsort label-4242
SELECT col0 DIV - 61 AS col0 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4242
SELECT col0 / - 61 AS col0 FROM tab1 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort
SELECT + - col2 + CAST ( cor0.col1 AS REAL ) * - col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT col1 * + col2 + + 5 + - col2 FROM tab2 AS cor0
----
1513
613
815

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2, tab2 cor3
----
3645 values hashing to 59ca7c96f3955e014bebd08b5442edff

query I rowsort
SELECT col1 * + ( 83 ) * col1 + 84 FROM tab0 AS cor0
----
613952
687407
781031

query I rowsort
SELECT ALL + col2 * + 93 FROM tab0 AS cor0
----
3069
7626
93

query I rowsort
SELECT col1 * col1 * col2 + + col2 FROM tab1 cor0
----
16320
36558
5757

query I rowsort
SELECT - + cor0.col2 * - ( + 42 ) AS col2 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT ALL col1 * - ( + col1 ) * + cor0.col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT cor0.col1 * 7 + + col1 FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT DISTINCT - + col2 + col0 * - 85 * - col1 AS col0 FROM tab2 cor0
----
114117
18418
391144

query I rowsort
SELECT + ( + col1 ) * - col1 + col1 AS col2 FROM tab0 cor0
----
-7310
-8190
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 7 ) * + col0 + + col1 col1 FROM tab0 AS cor0
----
-148
-532
-82

query I rowsort
SELECT col1 + col2 * col0 * - col0 FROM tab1 AS cor0
----
-233462
-460
-614387

onlyif mysql # use DIV operator for integer division
query I rowsort label-4256
SELECT col2 + - cor0.col0 DIV cor0.col1 FROM tab1 AS cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-4256
SELECT col2 + - cor0.col0 / cor0.col1 FROM tab1 AS cor0
----
51
54
90

query I rowsort
SELECT DISTINCT + col0 + + col1 * - 5 FROM tab1 AS cor0
----
-127
14
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-4258
SELECT cor0.col0 DIV - col1 + col1 AS col2 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4258
SELECT cor0.col0 / - col1 + col1 AS col2 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - + cor0.col0 + + col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4260
SELECT DISTINCT col2 + cor0.col2 * CAST( NULL AS SIGNED ) + + col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4260
SELECT DISTINCT col2 + cor0.col2 * CAST ( NULL AS INTEGER ) + + col2 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 83 * - col1 + + 60 + + col1 AS col2 FROM tab1 cor0
----
-1006
-2072
-760

query I rowsort
SELECT ALL - - cor0.col2 * col2 * - col1 AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-4263
SELECT ALL - 6 DIV col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4263
SELECT ALL - 6 / col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + + col2 * - col2 + + 90 AS col2 FROM tab0 cor0
----
-6634
-999
89

query I rowsort
SELECT ALL + col1 + - col0 * + 34 + - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-4012
-424
-7195

query I rowsort
SELECT DISTINCT - + col0 - + col0 AS col1 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - + 68 * cor0.col2 FROM tab0 cor0
----
-2244
-5576
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4268
SELECT DISTINCT + - col0 DIV + col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4268
SELECT DISTINCT + - col0 / + col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT col2 + + cor0.col1 * - col1 FROM tab2 AS cor0
----
-251
-3455
-934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 76 + col0 * - 67 col0 FROM tab2 AS cor0
----
-5302
-5369
-545

query I rowsort
SELECT ALL - + col1 - col2 * col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT - col1 * - col2 + cor0.col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + col1 * col0 + 1 FROM tab0 AS cor0
----
2065
3396
8100

query I rowsort
SELECT ALL 70 + col2 AS col0 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT DISTINCT + + 17 * col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT DISTINCT - + col0 + - col2 + 7 FROM tab2 AS cor0
----
-110
-27
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4277
SELECT - ( - col0 ) DIV col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4277
SELECT - ( - col0 ) / col1 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL + 24 FROM tab0, tab2 cor0, tab2 cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT - cor0.col2 + + col1 AS col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT ( - col2 ) - + col2 * - col0 * col2 FROM tab1
----
207879
737184
8694

query I rowsort
SELECT DISTINCT 37 + - col2 AS col2 FROM tab1
----
-17
-20
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4282
SELECT 33 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4282
SELECT 33 / - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT 61 * col0 FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT DISTINCT + col1 * + col1 * col0 FROM tab2 AS cor0
----
22831
271518
6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4285
SELECT ALL CAST( - col2 AS SIGNED ) * - col1 FROM tab2 cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-4285
SELECT ALL CAST ( - col2 AS INTEGER ) * - col1 FROM tab2 cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col1 ) + - col1 col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4287
SELECT ALL + ( col0 ) DIV + col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4287
SELECT ALL + ( col0 ) / + col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - ( col0 ) + cor0.col1 * + 6 FROM tab1 AS cor0
----
-2
-4
153

query I rowsort
SELECT DISTINCT - 5 FROM tab1, tab2 cor0, tab0 AS cor1
----
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col2 + col2 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT 65 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to ee83821bd928a072bc435d7135362ca1

query I rowsort
SELECT ALL - 80 * col1 AS col2 FROM tab2
----
-1360
-2480
-4720

query I rowsort
SELECT DISTINCT + 99 FROM tab1, tab1 AS cor0
----
99

query I rowsort
SELECT - ( 40 ) - + col2 AS col0 FROM tab0
----
-122
-41
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4296
SELECT DISTINCT + col2 - col1 DIV - col1 AS col1 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4296
SELECT DISTINCT + col2 - col1 / - col1 AS col1 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col0 AS REAL ) + col2 * - 98 FROM tab2 AS cor0
----
-2626
-2653
-3803

onlyif mysql # use DIV operator for integer division
query I rowsort label-4298
SELECT + col2 DIV 54 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4298
SELECT + col2 / 54 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col0 * 79 FROM tab1 AS cor0
----
237
5056
6320

query I rowsort
SELECT ALL - - cor0.col0 + col0 AS col1 FROM tab2 cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col2 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + - col1 * + ( 53 ) * - col0 AS col1 FROM tab1 AS cor0
----
33920
4134
55120

query I rowsort
SELECT col1 + + 58 + + col1 FROM tab2 AS cor0
----
120
176
92

query I rowsort
SELECT - - cor0.col1 * col0 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + + col1 + col1 * - col0 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col1 ) col0 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4307
SELECT DISTINCT cor0.col2 + + col0 DIV - 51 + col1 AS col0 FROM tab1 AS cor0
----
108
66
80

skipif mysql # not compatible
query I rowsort label-4307
SELECT DISTINCT cor0.col2 + + col0 / - 51 + col1 AS col0 FROM tab1 AS cor0
----
108
66
80

query I rowsort
SELECT ALL + col2 + - col1 * col2 - col1 AS col1 FROM tab1 cor0
----
-1165
-1376
-523

onlyif mysql # use DIV operator for integer division
query I rowsort label-4309
SELECT + 95 * + col1 + ( cor0.col1 ) DIV col2 FROM tab0 cor0
----
8172
8646
9312

skipif mysql # not compatible
query I rowsort label-4309
SELECT + 95 * + col1 + ( cor0.col1 ) / col2 FROM tab0 cor0
----
8172
8646
9312

query I rowsort
SELECT DISTINCT - col2 + - col1 - ( 66 ) * col2 AS col0 FROM tab0 AS cor0
----
-164
-2297
-5585

query I rowsort
SELECT DISTINCT - ( + col0 ) + + 26 * cor0.col0 + + col0 FROM tab0 AS cor0
----
2314
624
910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - 97 AS col0 FROM tab0 AS cor0
----
-97
-97
-97

query I rowsort
SELECT col2 + 65 AS col0 FROM tab2 AS cor0
----
103
91
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 81 col0 FROM tab2 AS cor0
----
2106
2187
3078

query I rowsort
SELECT DISTINCT 61 AS col2 FROM tab2, tab1, tab1 cor0
----
61

query I rowsort
SELECT 66 + + col1 AS col2 FROM tab1
----
76
79
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-4318
SELECT DISTINCT 87 DIV col2 AS col1 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-4318
SELECT DISTINCT 87 / col2 AS col1 FROM tab1
----
0
1

query I rowsort
SELECT col0 + + col1 * + tab2.col2 FROM tab2
----
1612
725
844

query I rowsort
SELECT - 64 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT 45 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT 17 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT ALL + 11 FROM tab2, tab1 cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT DISTINCT + col0 * + cor0.col1 * col1 - + col1 AS col1 FROM tab1 AS cor0
----
13507
2002
6390

onlyif mysql # use DIV operator for integer division
query I rowsort label-4325
SELECT ALL + tab2.col2 DIV + 66 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-4325
SELECT ALL + tab2.col2 / + 66 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4326
SELECT col2 + - CAST( NULL AS SIGNED ) * - 72 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4326
SELECT col2 + - CAST ( NULL AS INTEGER ) * - 72 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 28 * - 12 FROM tab0, tab0 AS cor0
----
9 values hashing to a49ea234d443daae83e5340420151d25

query I rowsort
SELECT DISTINCT - 48 * col2 + - col2 FROM tab0
----
-1617
-4018
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-4329
SELECT 32 DIV 39 col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4329
SELECT 32 / 39 col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + tab0.col0 * col1 + + col2 + col0 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT - + 13 * + col1 FROM tab2 AS cor0
----
-221
-403
-767

query I rowsort
SELECT - 15 * col1 + cor0.col0 * + 40 + cor0.col1 FROM tab2 AS cor0
----
-154
2294
2922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col1 - col2 col0 FROM tab2 AS cor0
----
-327
-3507
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT DISTINCT col1 DIV 67 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4334
SELECT DISTINCT col1 / 67 FROM tab2
----
0

query I rowsort
SELECT 10 * 6 FROM tab2
----
60
60
60

query I rowsort
SELECT DISTINCT 30 * col0 AS col1 FROM tab0
----
1050
2670
720

query I rowsort
SELECT 27 * - col0 FROM tab2
----
-189
-2106
-2133

query I rowsort
SELECT - - 44 * - col0 FROM tab0 cor0
----
-1056
-1540
-3916

query I rowsort
SELECT - + col2 * + cor0.col1 + 86 AS col2 FROM tab1 cor0
----
-1162
-1318
-484

query I rowsort
SELECT ALL - + ( + 14 ) FROM tab1 AS cor0
----
-14
-14
-14

query I rowsort
SELECT col2 * + 88 AS col0 FROM tab1
----
4752
5016
8448

onlyif mysql # use DIV operator for integer division
query I rowsort label-4342
SELECT + tab1.col2 DIV + 89 AS col0 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4342
SELECT + tab1.col2 / + 89 AS col0 FROM tab1
----
0
0
1

query I rowsort
SELECT DISTINCT 55 FROM tab2 cor0
----
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-4344
SELECT + col2 DIV 11 FROM tab1 AS cor0
----
4
5
8

skipif mysql # not compatible
query I rowsort label-4344
SELECT + col2 / 11 FROM tab1 AS cor0
----
4
5
8

query I rowsort
SELECT ALL - + col1 + + 14 * - col1 FROM tab2 AS cor0
----
-255
-465
-885

onlyif mysql # use DIV operator for integer division
query I rowsort label-4346
SELECT + ( + 50 ) + + col1 DIV + ( 52 ) AS col2 FROM tab1 cor0
----
50
50
50

skipif mysql # not compatible
query I rowsort label-4346
SELECT + ( + 50 ) + + col1 / + ( 52 ) AS col2 FROM tab1 cor0
----
50
50
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4347
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + col2 / cor0.col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4347
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + col2 / cor0.col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 * - ( tab2.col0 * + col2 ) FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT tab1.col0 + 22 FROM tab1
----
102
25
86

query I rowsort
SELECT - col2 * 56 FROM tab1 AS cor0
----
-3024
-3192
-5376

query I rowsort
SELECT 18 * col1 - + col2 AS col1 FROM tab1 cor0
----
123
138
414

query I rowsort
SELECT DISTINCT - 70 * + col2 AS col0 FROM tab1 AS cor0
----
-3780
-3990
-6720

onlyif mysql # use DIV operator for integer division
query I rowsort label-4353
SELECT ALL - 71 DIV col0 col0 FROM tab1 AS cor0
----
-1
-23
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4353
SELECT ALL - 71 / col0 col0 FROM tab1 AS cor0
----
-1
-23
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 2 col2 FROM tab2 AS cor0
----
-2

query I rowsort
SELECT + + cor0.col0 + col1 * - col1 AS col0 FROM tab1 AS cor0
----
-36
-673
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + cor0.col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + ( col0 ) + + 30 AS col2 FROM tab0 AS cor0
----
119
54
65

query I rowsort
SELECT DISTINCT + 19 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
19

query I rowsort
SELECT ALL - 11 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 7120875811e4d19a19b69cd34b6bc202

query I rowsort
SELECT col0 * 8 FROM tab1 AS cor0
----
24
512
640

query I rowsort
SELECT + col1 * ( col1 ) + - col2 * col2 AS col2 FROM tab1 AS cor0
----
-2240
-3149
-9047

onlyif mysql # use DIV operator for integer division
query I rowsort label-4362
SELECT - cor0.col1 DIV 6 FROM tab0 AS cor0
----
-14
-15
-16

skipif mysql # not compatible
query I rowsort label-4362
SELECT - cor0.col1 / 6 FROM tab0 AS cor0
----
-14
-15
-16

query I rowsort
SELECT + - col2 + + ( cor0.col1 ) AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col1 * 51 * 98 + + col1 AS col0 FROM tab0 AS cor0
----
429914
454909
484903

query I rowsort
SELECT ALL - col2 + - col1 * - 86 + col0 * 42 FROM tab0 AS cor0
----
11482
8371
9811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4366
SELECT ALL + - cor0.col0 * CAST( NULL AS SIGNED ) + col2 * - col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4366
SELECT ALL + - cor0.col0 * CAST ( NULL AS INTEGER ) + col2 * - col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4367
SELECT + col1 + ( 24 ) * col0 DIV - 76 FROM tab0 AS cor0
----
63
79
86

skipif mysql # not compatible
query I rowsort label-4367
SELECT + col1 + ( 24 ) * col0 / - 76 FROM tab0 AS cor0
----
63
79
86

query I rowsort
SELECT DISTINCT + - col2 * + col1 - - col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-4369
SELECT ALL + col1 * col2 DIV ( - col0 ) AS col0 FROM tab0 cor0
----
-118
-2
-83

skipif mysql # not compatible
query I rowsort label-4369
SELECT ALL + col1 * col2 / ( - col0 ) AS col0 FROM tab0 cor0
----
-118
-2
-83

query I rowsort
SELECT ALL - col0 + + ( - col0 ) * col1 + 49 AS col0 FROM tab2 AS cor0
----
-1373
-175
-4631

query I rowsort
SELECT DISTINCT - col1 + 10 * col2 AS col0 FROM tab0 AS cor0
----
-87
244
729

query I rowsort
SELECT - + col0 * - col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col1 + - cor0.col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT - - ( col0 ) + + cor0.col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + + col0 * ( col0 ) + - col0 AS col2 FROM tab0 AS cor0
----
1190
552
7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 58 + - col0 col1 FROM tab2 AS cor0
----
-136
-137
-65

query I rowsort
SELECT - + 8 * + col2 FROM tab0 AS cor0
----
-264
-656
-8

query I rowsort
SELECT ALL + col0 * ( col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col0 + 80 FROM tab0
----
104
115
169

query I rowsort
SELECT ALL - cor1.col1 AS col0 FROM tab0, tab0 cor0, tab2 cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL col0 * ( + tab2.col1 * col2 ) AS col0 FROM tab2
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4382
SELECT - - 80 * col0 + + CAST( + col0 AS SIGNED ) + - col1 * ( 11 ) FROM tab2 AS cor0
----
226
5669
6212

skipif mysql # not compatible
query I rowsort label-4382
SELECT - - 80 * col0 + + CAST ( + col0 AS INTEGER ) + - col1 * ( 11 ) FROM tab2 AS cor0
----
226
5669
6212

onlyif mysql # use DIV operator for integer division
query I rowsort label-4383
SELECT DISTINCT - col2 DIV col0 AS col0 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4383
SELECT DISTINCT - col2 / col0 AS col0 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT - + 29 * col0 + 14 * - 1 AS col2 FROM tab2 AS cor0
----
-217
-2276
-2305

query I rowsort
SELECT col1 * + col2 + + 89 FROM tab1 AS cor0
----
1337
1493
659

query I rowsort
SELECT DISTINCT - ( col0 ) * + col2 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 - cor0.col1 col2 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT ALL - 15 + + col0 FROM tab2
----
-8
63
64

query I rowsort
SELECT ALL - col0 + ( - col0 + col2 ) * + ( + col1 * col1 ) AS col2 FROM tab2 AS cor0
----
-11928
-181090
19213

onlyif mysql # use DIV operator for integer division
query I rowsort label-4390
SELECT DISTINCT col0 DIV col0 + 93 - - col1 FROM tab2 AS cor0
----
111
125
153

skipif mysql # not compatible
query I rowsort label-4390
SELECT DISTINCT col0 / col0 + 93 - - col1 FROM tab2 AS cor0
----
111
125
153

query I rowsort
SELECT DISTINCT tab2.col0 * - tab2.col1 AS col2 FROM tab2, tab1 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4392
SELECT DISTINCT 9 + + col2 DIV col1 FROM tab1
----
11
14
16

skipif mysql # not compatible
query I rowsort label-4392
SELECT DISTINCT 9 + + col2 / col1 FROM tab1
----
11
14
16

query I rowsort
SELECT DISTINCT - 74 + col2 FROM tab0
----
-41
-73
8

query I rowsort
SELECT ALL - col0 * col1 * col1 + col1 FROM tab2
----
-22814
-271459
-6696

query I rowsort
SELECT 11 * col1 * + col1 AS col2 FROM tab2 AS cor0
----
10571
3179
38291

query I rowsort
SELECT col0 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + + col1 * + col1 + + col1 FROM tab1 AS cor0
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4398
SELECT + + 41 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4398
SELECT + + 41 / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + cor0.col2 - cor0.col2 * col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 19 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4401
SELECT DISTINCT + col0 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4401
SELECT DISTINCT + col0 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT col0 + - ( - col2 ) * col2 AS col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL col0 + - ( + col1 * col0 + - 16 ) FROM tab0
----
-2024
-3344
-7994

onlyif mysql # use DIV operator for integer division
query I rowsort label-4404
SELECT ALL - col0 DIV - col2 + col1 * col2 AS col1 FROM tab1
----
1248
1404
571

skipif mysql # not compatible
query I rowsort label-4404
SELECT ALL - col0 / - col2 + col1 * col2 AS col1 FROM tab1
----
1248
1404
571

query I rowsort
SELECT col1 + + 14 FROM tab1 cor0
----
24
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-4406
SELECT + cor0.col2 DIV - CAST( + col0 AS SIGNED ) + col2 * col0 AS col1 FROM tab0 AS cor0
----
35
7298
791

skipif mysql # not compatible
query I rowsort label-4406
SELECT + cor0.col2 / - CAST ( + col0 AS INTEGER ) + col2 * col0 AS col1 FROM tab0 AS cor0
----
35
7298
791

onlyif mysql # use DIV operator for integer division
query I rowsort label-4407
SELECT - + 24 DIV cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-4407
SELECT - + 24 / cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

query I rowsort
SELECT DISTINCT + + col0 + - col2 * col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + - col1 * 88 + col0 FROM tab0 AS cor0
----
-7544
-7919
-8501

query I rowsort
SELECT ALL + - ( + col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col1 * + col2 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL - + ( - col1 ) + - col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + col1 * + 47 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT DISTINCT - ( 5 ) + + cor0.col1 FROM tab1 AS cor0
----
21
5
8

query I rowsort
SELECT ALL - - ( + 98 ) * col1 AS col2 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT + col0 + + 69 AS col0 FROM tab1 AS cor0
----
133
149
72

query I rowsort
SELECT + - ( 93 ) + col2 FROM tab0 AS cor0
----
-11
-60
-92

query I rowsort
SELECT - col2 * 91 + + col1 AS col0 FROM tab1 AS cor0
----
-4888
-5177
-8723

onlyif mysql # use DIV operator for integer division
query I rowsort label-4419
SELECT + col2 DIV - ( - col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4419
SELECT + col2 / - ( - col1 ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 47 AS col0 FROM tab1 AS cor0
----
47
47
47

query I rowsort
SELECT - ( 5 ) FROM tab1 cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT - + ( col1 ) * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - 16 + 48 FROM tab2 AS cor0
----
32
32
32

query I rowsort
SELECT ALL + col2 * 55 AS col0 FROM tab1 AS cor0
----
2970
3135
5280

query I rowsort
SELECT + col2 + col0 * 67 FROM tab2
----
496
5252
5331

query I rowsort
SELECT col0 + + ( col2 ) AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT + col2 * tab2.col0 + tab2.col0 AS col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL - 71 FROM tab1, tab2 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4429
SELECT col2 + col0 * col0 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4429
SELECT col2 + col0 * col0 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4430
SELECT ALL + tab0.col0 DIV 23 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 58ae7e090d51c8455ede8ad629ce3d8d

skipif mysql # not compatible
query I rowsort label-4430
SELECT ALL + tab0.col0 / 23 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 58ae7e090d51c8455ede8ad629ce3d8d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4431
SELECT - 56 DIV 64 + col0 * 59 FROM tab1 cor0
----
177
3776
4720

skipif mysql # not compatible
query I rowsort label-4431
SELECT - 56 / 64 + col0 * 59 FROM tab1 cor0
----
177
3776
4720

query I rowsort
SELECT - - 78 * + col1 FROM tab1 AS cor0
----
1014
2028
780

query I rowsort
SELECT - 2 + col1 * + col2 AS col1 FROM tab0 AS cor0
----
2836
7460
95

query I rowsort
SELECT - - 52 + col2 FROM tab2 AS cor0
----
78
79
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4435
SELECT - - col0 + - col1 DIV col1 AS col0 FROM tab0 cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-4435
SELECT - - col0 + - col1 / col1 AS col0 FROM tab0 cor0
----
23
34
88

query I rowsort
SELECT ALL ( col0 ) + + col2 AS col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4437
SELECT ALL + col0 DIV - cor0.col0 + ( col2 ) col2 FROM tab0 AS cor0
----
0
32
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4437
SELECT ALL + col0 / - cor0.col0 + ( col2 ) col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT DISTINCT + + col2 + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT col0 * - 40 AS col1 FROM tab1
----
-120
-2560
-3200

query I rowsort
SELECT 94 * - cor0.col1 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 2542d908b6c2e05490962cfae004b164

query I rowsort
SELECT DISTINCT 51 * - col0 * col1 FROM tab0
----
-105264
-173145
-413049

query I rowsort
SELECT - tab1.col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + col2 * cor0.col0 + - col1 AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT col1 * + 78 AS col0 FROM tab2 AS cor0
----
1326
2418
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4445
SELECT + col0 + - col0 DIV - 67 AS col2 FROM tab1 cor0
----
3
64
81

skipif mysql # not compatible
query I rowsort label-4445
SELECT + col0 + - col0 / - 67 AS col2 FROM tab1 cor0
----
3
64
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4446
SELECT + col2 + CAST( cor0.col1 AS SIGNED ) * col0 AS col2 FROM tab2 AS cor0
----
1381
244
4628

skipif mysql # not compatible
query I rowsort label-4446
SELECT + col2 + CAST ( cor0.col1 AS INTEGER ) * col0 AS col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT - 83 FROM tab2, tab0, tab0 AS cor0
----
-83

query I rowsort
SELECT ALL - 8 * - tab0.col2 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to a2a2fbf04d21b762d1abeabe511146e7

query I rowsort
SELECT + col0 * col0 * - col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + 7 * + cor0.col2 * 72 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 46e3f1b6df28cc54b5dbc45f2078efd5

query I rowsort
SELECT ALL + tab2.col2 * + ( col2 ) AS col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT tab0.col1 + + col2 + - 85 * col0 FROM tab0
----
-1921
-2877
-7392

query I rowsort
SELECT ALL + + col0 * + col0 + - col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT DISTINCT + col2 * col1 - + 51 * col2 AS col1 FROM tab2 AS cor0
----
-1292
-540
208

query I rowsort
SELECT col0 - ( 0 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL cor0.col2 * - col2 + + 84 AS col2 FROM tab2 AS cor0
----
-1360
-592
-645

query I rowsort
SELECT - col0 + - col0 * cor0.col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE - col0 + col1 + + col0 * + col2 > NULL
----

query I rowsort
SELECT ALL col2 * - col0 + col1 AS col1 FROM tab2
----
-158
-1969
-2985

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE cor0.col1 + col0 + col1 IN ( cor0.col1 )
----

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT NULL BETWEEN col0 * - col2 AND ( NULL )
----

query III rowsort
SELECT ALL * FROM tab2 cor0 WHERE col2 <= NULL
----

query I rowsort
SELECT DISTINCT col1 * + col0 + + tab2.col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT + col1 + + col0 * + col2 AS col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT + col0 + col2 * col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL + col1 * col1 + tab0.col0 * + col0 AS col0 FROM tab0
----
10634
16202
7972

query I rowsort
SELECT ALL col1 + - tab0.col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + col2 + col1 FROM tab2 WHERE NOT col0 > + col0
----
55
58
85

query I rowsort
SELECT ALL col1 + + col0 FROM tab1 WHERE NULL NOT BETWEEN + col1 * + col1 * col1 + + col0 / - col2 AND NULL
----

query I rowsort
SELECT ALL + col1 + col1 * col2 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT col2 AS col2 FROM tab0 WHERE ( - col1 ) = ( - col0 * - col1 )
----

query I rowsort
SELECT ALL col2 + + col2 * col0 FROM tab0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-4473
SELECT - tab0.col0 DIV + col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4473
SELECT - tab0.col0 / + col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col0 * + col2 * col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT + col2 * - tab1.col2 * - tab1.col2 AS col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT ALL cor0.col2 * col0 AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT - - col2 + - col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT col1 * col2 - - col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT col1 + col1 + col1 FROM tab1
----
30
39
78

query I rowsort
SELECT DISTINCT tab2.col2 AS col1 FROM tab2, tab0, tab2 cor0
----
26
27
38

query I rowsort
SELECT col2 * col2 * + tab0.col2 FROM tab0
----
1
35937
551368

query I rowsort
SELECT DISTINCT tab2.col2 * col0 * col2 + - col2 AS col2 FROM tab2
----
114038
5076
52702

query I rowsort
SELECT DISTINCT - col0 * col1 + col1 AS col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT ALL tab1.col2 * tab1.col1 + + col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT ALL col1 + + col0 + col1 FROM tab1 AS cor0 WHERE - col2 * + col1 <= cor0.col0 * col1 OR NOT col0 NOT BETWEEN NULL AND + col0 * + col0 + col0
----
106
55
84

query I rowsort
SELECT ALL tab1.col2 + - col0 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT - col1 * - col1 + + col2 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT - - col0 + - ( 67 ) * + col0 AS col0 FROM tab2 AS cor0
----
-462
-5148
-5214

query I rowsort
SELECT ALL - tab0.col2 * - col2 + + col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT DISTINCT + 69 + - col2 * 92 AS col0 FROM tab2
----
-2323
-2415
-3427

query I rowsort
SELECT ALL 67 + - col2 FROM tab2
----
29
40
41

query I rowsort
SELECT + col2 * tab1.col2 * - col1 + - col0 * col0 AS col2 FROM tab1
----
-126208
-36586
-75825

query I rowsort
SELECT DISTINCT col2 * - ( 70 ) AS col1 FROM tab0
----
-2310
-5740
-70

query I rowsort
SELECT col2 * 32 AS col2 FROM tab0
----
1056
2624
32

query I rowsort
SELECT ALL col1 * - 62 FROM tab1 AS cor0
----
-1612
-620
-806

query I rowsort
SELECT DISTINCT - cor1.col0 * cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ec78515ecc610830fe02f4a5c8d4e4d5

query I rowsort
SELECT ALL + col0 + + col1 * - col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-4498
SELECT DISTINCT - col0 DIV - ( col0 ) col0 FROM tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4498
SELECT DISTINCT - col0 / - ( col0 ) col0 FROM tab2 AS cor0
----
1

query I rowsort
SELECT col2 * ( ( - col2 ) * col2 ) AS col0 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT DISTINCT + col2 * - col1 + + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - col1 * + ( - 30 ) + + col0 AS col1 FROM tab1 AS cor0
----
364
470
783

query I rowsort
SELECT + - col2 + ( cor0.col0 ) * col0 AS col1 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT ALL - col1 * col2 - cor0.col0 * - col2 * col2 FROM tab2 AS cor0
----
113430
4266
51194

query I rowsort
SELECT + col1 * + col2 * - col0 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT ALL + col0 + + col0 + + col0 FROM tab2
----
21
234
237

query I rowsort
SELECT col2 * col2 + col2 + col0 FROM tab0
----
1146
37
6895

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) < ( col1 )
----

query I rowsort
SELECT DISTINCT col0 + col1 * tab0.col0 + col2 * - col0 FROM tab0
----
1296
3395
890

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( + col2 + - col2 - col0 ) < - col0
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT + col0 * col2 AS col1 FROM tab1 WHERE NOT + col0 + - col0 - - col2 NOT IN ( tab1.col2 + + col1 )
----

query I rowsort
SELECT + tab1.col2 * col0 * col1 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4512
SELECT DISTINCT - col0 + col2 * + col0 + + col1 * col2 DIV tab2.col0 AS col2 FROM tab2
----
1969
2931
301

skipif mysql # not compatible
query I rowsort label-4512
SELECT DISTINCT - col0 + col2 * + col0 + + col1 * col2 / tab2.col0 AS col2 FROM tab2
----
1969
2931
301

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 * + col2 col2 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - col2 * - tab0.col1 AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL tab1.col0 * col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT - col1 * + col1 * tab1.col1 AS col2 FROM tab1
----
-1000
-17576
-2197

query I rowsort
SELECT DISTINCT col0 AS col1 FROM tab1 WHERE NOT col1 + col2 / - col2 IN ( + col2 * - col1 / col2 )
----
3
64
80

query I rowsort
SELECT + col1 * + col1 + - col1 FROM tab2
----
272
3422
930

query I rowsort
SELECT ALL + col0 * col0 * col2 AS col2 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT col0 * + col2 * - col0 AS col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT col2 + tab1.col2 * + col1 AS col0 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT - col1 * + col2 * col2 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT + ( col0 ) + col1 * + cor0.col2 + col0 FROM tab2 AS cor0
----
1690
804
851

query I rowsort
SELECT DISTINCT + - cor0.col0 + + col0 + 64 * ( - col2 ) * - 79 FROM tab2 AS cor0
----
131456
136512
192128

query I rowsort
SELECT col1 * col0 * col1 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
22869
271544
6754

query I rowsort
SELECT ALL + + col0 + col1 * col0 AS col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT 77 * cor0.col1 + + col1 * 70 * col0 + col2 FROM tab1 AS cor0
----
45627
73897
7516

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4528
SELECT ALL cor0.col1 * - col0 + ( + ( - col0 ) ) * + CAST( ( col0 ) AS SIGNED ) FROM tab2 AS cor0
----
-10686
-266
-7584

skipif mysql # not compatible
query I rowsort label-4528
SELECT ALL cor0.col1 * - col0 + ( + ( - col0 ) ) * + CAST ( ( col0 ) AS INTEGER ) FROM tab2 AS cor0
----
-10686
-266
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-4529
SELECT ALL - col0 * col2 DIV col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4529
SELECT ALL - col0 * col2 / col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL col1 FROM tab1 WHERE col0 * col0 * - col0 - - col2 / col0 NOT IN ( col2 / col2 + col1 )
----
10
13
26

query I rowsort
SELECT col1 AS col0 FROM tab0 WHERE + col1 * + col2 * col0 - col2 * + col2 IN ( + tab0.col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4532
SELECT ALL - 52 DIV - col0 + 45 * col1 FROM tab2 AS cor0
----
1402
2655
765

skipif mysql # not compatible
query I rowsort label-4532
SELECT ALL - 52 / - col0 + 45 * col1 FROM tab2 AS cor0
----
1402
2655
765

query I rowsort
SELECT + col0 * 45 + cor0.col1 FROM tab1 AS cor0
----
161
2890
3613

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + col1 + 1 col0 FROM tab1 AS cor0
----
-1039
-639
-77

query I rowsort
SELECT ALL - col2 * - col2 + + col1 AS col2 FROM tab0
----
1175
6815
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4536
SELECT 84 + tab2.col1 DIV + col0 + col0 AS col2 FROM tab2
----
162
163
95

skipif mysql # not compatible
query I rowsort label-4536
SELECT 84 + tab2.col1 / + col0 + col0 AS col2 FROM tab2
----
162
163
95

query I rowsort
SELECT col2 * cor0.col0 + - 40 AS col2 FROM tab0 AS cor0
----
-5
7258
752

query I rowsort
SELECT - col0 + - 69 AS col1 FROM tab1 AS cor0
----
-133
-149
-72

query I rowsort
SELECT DISTINCT - 17 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
-17

query I rowsort
SELECT - 56 + + col2 FROM tab0 AS cor0
----
-23
-55
26

query I rowsort
SELECT - - 3 AS col1 FROM tab2 cor0
----
3
3
3

query I rowsort
SELECT + col1 + - cor0.col2 AS col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - col0 + + 5 + + col2 FROM tab1 AS cor0
----
-2
21
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-4544
SELECT DISTINCT + col1 * col0 DIV + col2 + 37 + + 41 AS col1 FROM tab1
----
79
88
89

skipif mysql # not compatible
query I rowsort label-4544
SELECT DISTINCT + col1 * col0 / + col2 + 37 + + 41 AS col1 FROM tab1
----
79
88
89

query I rowsort
SELECT col0 + col2 * cor0.col1 AS col1 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT ALL - - 96 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 29 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL - 39 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

query I rowsort
SELECT DISTINCT - 39 AS col1 FROM tab0
----
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-4550
SELECT 72 DIV + col0 AS col2 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-4550
SELECT 72 / + col0 AS col2 FROM tab0
----
0
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 31 col2 FROM tab0
----
31
31
31

query I rowsort
SELECT - 49 + col0 AS col2 FROM tab2
----
-42
29
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-4553
SELECT tab0.col0 DIV col2 + ( col2 * col1 ) col0 FROM tab0
----
132
2838
7463

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4553
SELECT tab0.col0 / col2 + ( col2 * col1 ) col0 FROM tab0
----
132
2838
7463

onlyif mysql # use DIV operator for integer division
query I rowsort label-4554
SELECT ALL - - 38 * col1 * col1 + - col1 DIV + col1 FROM tab0 AS cor0
----
281047
314677
357541

skipif mysql # not compatible
query I rowsort label-4554
SELECT ALL - - 38 * col1 * col1 + - col1 / + col1 FROM tab0 AS cor0
----
281047
314677
357541

query I rowsort
SELECT + + col1 * col2 + - ( col1 ) * - col2 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 73 col0 FROM tab0 cor0
----
73
73
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4557
SELECT col2 * + cor0.col1 * CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4557
SELECT col2 * + cor0.col1 * CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4558
SELECT DISTINCT + 26 DIV col0 AS col0 FROM tab2
----
0
3

skipif mysql # not compatible
query I rowsort label-4558
SELECT DISTINCT + 26 / col0 AS col0 FROM tab2
----
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4559
SELECT 84 DIV col0 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-4559
SELECT 84 / col0 FROM tab0
----
0
2
3

query I rowsort
SELECT DISTINCT col1 * col0 - col2 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT ALL 33 * col0 - col0 FROM tab2
----
224
2496
2528

query I rowsort
SELECT col1 + col0 * col0 AS col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + col2 + + col2 + + col0 AS col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT DISTINCT + tab1.col2 * tab1.col1 + col2 AS col0 FROM tab1
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col0 * + col1 * - col0 col0 FROM tab1
----
237
41024
83280

query I rowsort
SELECT - cor0.col2 + + cor0.col1 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT ALL - ( 8 ) AS col1 FROM tab1
----
-8
-8
-8

query I rowsort
SELECT DISTINCT 22 AS col2 FROM tab0, tab1 AS cor0
----
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - 18 col1 FROM tab2
----
20
8
9

query I rowsort
SELECT ( + 19 ) AS col0 FROM tab2
----
19
19
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 58 ) col1 FROM tab2
----
-58
-58
-58

query I rowsort
SELECT + 19 * - col2 AS col2 FROM tab2 cor0
----
-494
-513
-722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 * - 81 col0 FROM tab0 cor0
----
6399
6399
6399

query I rowsort
SELECT 43 * + col0 AS col0 FROM tab2 AS cor0
----
301
3354
3397

query I rowsort
SELECT + ( col2 ) * + col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + 9 * - col2 AS col0 FROM tab1 cor0
----
-486
-513
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-4577
SELECT ALL 17 DIV + col0 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4577
SELECT ALL 17 / + col0 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 77 col1 FROM tab1
----
231
4928
6160

query I rowsort
SELECT ALL 35 + col0 AS col0 FROM tab2 AS cor0
----
113
114
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4580
SELECT ALL 83 DIV col1 + - col0 col1 FROM tab1 AS cor0
----
-56
-74
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4580
SELECT ALL 83 / col1 + - col0 col1 FROM tab1 AS cor0
----
-56
-74
0

query I rowsort
SELECT DISTINCT - col2 * + cor0.col2 + + col0 FROM tab1 cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL + ( col1 ) * col1 AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT - tab0.col2 + col1 AS col1 FROM tab0
----
53
9
96

query I rowsort
SELECT 66 * - tab1.col1 FROM tab1
----
-1716
-660
-858

query I rowsort
SELECT 15 + col0 * col0 * + col2 FROM tab0
----
1240
19023
649537

query I rowsort
SELECT + col1 + 76 AS col2 FROM tab1
----
102
86
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4587
SELECT DISTINCT - col2 * - col2 + col2 * col2 * ( col1 + CAST( NULL AS SIGNED ) ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4587
SELECT DISTINCT - col2 * - col2 + col2 * col2 * ( col1 + CAST ( NULL AS INTEGER ) ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + - col2 * - col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT - col0 + + col0 * + col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) + + col0 AS col1 FROM tab0 AS cor0
----
-2
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4591
SELECT + 4 DIV - col0 + col0 FROM tab1 AS cor0
----
2
64
80

skipif mysql # not compatible
query I rowsort label-4591
SELECT + 4 / - col0 + col0 FROM tab1 AS cor0
----
2
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col2 col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT - 52 + + col1 + 95 * - 58 FROM tab0 AS cor0
----
-5465
-5471
-5476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 13 * col2 * col2 col1 FROM tab0 AS cor0
----
13
14157
87412

query I rowsort
SELECT ALL + + 13 * col0 + - cor0.col1 * col2 FROM tab1 AS cor0
----
-1365
-208
262

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) + + col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - + cor0.col2 * col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4598
SELECT DISTINCT - col2 + col0 * - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4598
SELECT DISTINCT - col2 + col0 * - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + ( + col1 ) * + 67 * ( col2 ) FROM tab1 AS cor0
----
38190
83616
94068

query I rowsort
SELECT DISTINCT + 39 * - col1 FROM tab1 AS cor0
----
-1014
-390
-507

query I rowsort
SELECT ALL 37 + - col0 + - cor0.col0 * col2 FROM tab1 cor0
----
-128
-3675
-7723

query I rowsort
SELECT + + col2 * - col2 AS col0 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * col0 - cor0.col2 col1 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT - + 57 + + col1 AS col2 FROM tab1 cor0
----
-31
-44
-47

query I rowsort
SELECT + col1 - col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT + - col1 + col0 * + ( cor0.col0 ) * 58 FROM tab0 AS cor0
----
33322
459327
70953

query I rowsort
SELECT DISTINCT col2 + col2 * - 65 * - col1 FROM tab0 AS cor0
----
184503
485112
6306

query I rowsort
SELECT col0 * - 47 * - col0 + - col0 AS col2 FROM tab0 AS cor0
----
27048
372198
57540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4610
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4610
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - 59 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 582c5aa5e5b4fc3f2ea27e7637992d1f

query I rowsort
SELECT + - 16 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

query I rowsort
SELECT - + col0 + - 48 FROM tab0 AS cor0
----
-137
-72
-83

query I rowsort
SELECT ALL col2 + + col2 * 6 FROM tab1 AS cor0
----
378
399
672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4615
SELECT ALL col0 * + CAST( NULL AS SIGNED ) + 47 * + col2 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4615
SELECT ALL col0 * + CAST ( NULL AS INTEGER ) + 47 * + col2 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - 47 AS col1 FROM tab2 AS cor0
----
-40
31
32

query I rowsort
SELECT DISTINCT col2 * - cor0.col1 + - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 7 + col1 col1 FROM tab1 AS cor0
----
19
3
6

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab1, tab1 cor0, tab0 cor1
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4620
SELECT DISTINCT - col1 DIV 11 + col1 FROM tab1
----
10
12
24

skipif mysql # not compatible
query I rowsort label-4620
SELECT DISTINCT - col1 / 11 + col1 FROM tab1
----
10
12
24

query I rowsort
SELECT - col0 * 80 - - 26 FROM tab1
----
-214
-5094
-6374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col1 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + col2 * 87 FROM tab2 cor0
----
2262
2349
3306

query I rowsort
SELECT - + 85 + - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1140
491
7836

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col0 AS REAL ) * - col2 * ( - col2 ) + col2 + CAST ( - col0 AS INTEGER ) * col2 * col0 AS col1 FROM tab2 cor0
----
-210886
-351196
-6399

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4626
SELECT ALL + CAST( col1 AS SIGNED ) * cor0.col0 - + cor0.col0 col1 FROM tab0 AS cor0
----
2040
3360
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4626
SELECT ALL + CAST ( col1 AS INTEGER ) * cor0.col0 - + cor0.col0 col1 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4627
SELECT CAST( NULL AS SIGNED ) + 97 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4627
SELECT CAST ( NULL AS INTEGER ) + 97 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( col0 ) + col1 col2 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 * col2 col2 FROM tab0 cor0
----
2178
5412
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * 96 * - col1 + + 4 + col0 col0 FROM tab2 AS cor0
----
129011
20843
441874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 25 col0 FROM tab2, tab1 AS cor0
----
-25

query I rowsort
SELECT col1 - 49 AS col2 FROM tab1 AS cor0
----
-23
-36
-39

query I rowsort
SELECT + col0 + - col1 - + col0 * - tab2.col1 FROM tab2
----
1405
193
4621

query I rowsort
SELECT DISTINCT tab0.col1 - ( + col1 ) * col0 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT tab0.col2 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + cor0.col0 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col2 + + 6 FROM tab0 AS cor0
----
39
7
88

query I rowsort
SELECT + + 23 * col0 FROM tab2 AS cor0
----
161
1794
1817

query I rowsort
SELECT DISTINCT - + 59 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1166
517
7862

query I rowsort
SELECT + - 26 + col1 FROM tab0 AS cor0
----
60
65
71

query I rowsort
SELECT DISTINCT + 33 FROM tab1, tab0 AS cor0, tab0, tab1 AS cor1
----
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-4642
SELECT 99 DIV - 57 AS col0 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-4642
SELECT 99 / - 57 AS col0 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT 39 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT - col1 + + 42 * + ( col2 ) * - col2 AS col0 FROM tab0 AS cor0
----
-139
-282499
-45824

query I rowsort
SELECT + 62 + tab0.col0 FROM tab0
----
151
86
97

query I rowsort
SELECT ALL - col2 * col1 + + col2 + - col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + tab2.col2 * - 73 FROM tab2
----
-1898
-1971
-2774

query I rowsort
SELECT DISTINCT cor0.col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4649
SELECT - + col1 DIV CAST( + col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4649
SELECT - + col1 / CAST ( + col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL col1 * - col1 + col0 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT + col2 * + ( col0 ) + tab1.col0 * ( tab1.col0 ) * - col0 + col1 AS col0 FROM tab1
----
-258486
-504307
161

query I rowsort
SELECT ALL - col0 + 11 * - tab1.col0 + tab1.col2 AS col1 FROM tab1
----
-711
-864
18

query I rowsort
SELECT DISTINCT col2 * 32 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT DISTINCT + col0 * col1 + 10 FROM tab1 AS cor0
----
1050
650
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-4655
SELECT DISTINCT col1 DIV - 58 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4655
SELECT DISTINCT col1 / - 58 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT ALL + - col1 + cor0.col2 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + + col0 * - col1 - + ( col1 ) * - 87 col0 FROM tab2 AS cor0
----
2453
505
98

query I rowsort
SELECT - - ( + col0 ) - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + 23 - col0 FROM tab2 AS cor0
----
-55
-56
16

query I rowsort
SELECT - col1 * + col1 + 95 AS col0 FROM tab1 AS cor0
----
-5
-581
-74

query I rowsort
SELECT + col1 + - cor0.col0 * - ( + 56 ) AS col0 FROM tab0 cor0
----
1430
2057
5075

query I rowsort
SELECT - - col1 * cor0.col1 - - cor0.col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1209
740
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-4663
SELECT - col1 + + col2 * 37 DIV - col2 AS col1 FROM tab1 AS cor0
----
-47
-50
-63

skipif mysql # not compatible
query I rowsort label-4663
SELECT - col1 + + col2 * 37 / - col2 AS col1 FROM tab1 AS cor0
----
-47
-50
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4664
SELECT - col1 DIV + col1 + - ( + col0 ) AS col2 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-4664
SELECT - col1 / + col1 + - ( + col0 ) AS col2 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT + - col2 - - col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT cor0.col0 + + ( col1 ) AS col2 FROM tab2 cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4667
SELECT - - col1 DIV col2 + col1 DIV - col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4667
SELECT - - col1 / col2 + col1 / - col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT + cor0.col1 + ( + col2 ) FROM tab2 cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4669
SELECT DISTINCT + col1 DIV tab0.col0 + - ( 79 ) * col0 * - 49 AS col0 FROM tab0
----
135487
344520
92907

skipif mysql # not compatible
query I rowsort label-4669
SELECT DISTINCT + col1 / tab0.col0 + - ( 79 ) * col0 * - 49 AS col0 FROM tab0
----
135487
344520
92907

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4670
SELECT DISTINCT + CAST( NULL AS SIGNED ) / col0 - cor0.col0 * - col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4670
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / col0 - cor0.col0 * - col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 col1 FROM tab0 cor0
----
30
30
30

query I rowsort
SELECT - ( cor0.col2 ) * - col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - 84 * - col2 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT - + 33 * - col1 FROM tab0 cor0
----
2838
3003
3201

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + col0 ) col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4676
SELECT col0 DIV + tab1.col0 + - col0 AS col0 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-4676
SELECT col0 / + tab1.col0 + - col0 AS col0 FROM tab1
----
-2
-63
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 35 * + ( + col2 * 64 ) col0 FROM tab0
----
183680
2240
73920

query I rowsort
SELECT + - 25 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 2e7a33467ee3a4d9570560d60302b35a

query I rowsort
SELECT col0 * + col2 + - ( - col1 ) FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT ALL ( + col2 ) + - col2 FROM tab1
----
0
0
0

query I rowsort
SELECT tab0.col0 * col0 + - col0 + + ( col0 ) AS col1 FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 74 * cor0.col1 col0 FROM tab0 AS cor0
----
-6364
-6734
-7178

query I rowsort
SELECT ALL - cor0.col0 + + col2 * + col0 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-4684
SELECT ALL - col2 * - col1 DIV - col1 - ( col1 + col1 ) * - col0 * cor0.col2 FROM tab2 AS cor0
----
102030
11691
239278

skipif mysql # not compatible
query I rowsort label-4684
SELECT ALL - col2 * - col1 / - col1 - ( col1 + col1 ) * - col0 * cor0.col2 FROM tab2 AS cor0
----
102030
11691
239278

query I rowsort
SELECT ALL + - 78 * cor0.col1 FROM tab0 AS cor0
----
-6708
-7098
-7566

query I rowsort
SELECT - + 85 AS col1 FROM tab2 AS cor0
----
-85
-85
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4687
SELECT DISTINCT + - ( + cor0.col0 ) + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4687
SELECT DISTINCT + - ( + cor0.col0 ) + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4688
SELECT DISTINCT CAST( - col2 AS SIGNED ) * tab0.col0 * 26 col0 FROM tab0
----
-189748
-20592
-910

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4688
SELECT DISTINCT CAST ( - col2 AS INTEGER ) * tab0.col0 * 26 col0 FROM tab0
----
-189748
-20592
-910

query I rowsort
SELECT - col0 * + col1 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + col2 * + 94 AS col2 FROM tab2
----
2444
2538
3572

query I rowsort
SELECT - tab1.col2 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT col1 * 51 AS col0 FROM tab0
----
4386
4641
4947

query I rowsort
SELECT DISTINCT + col1 * 89 AS col1 FROM tab0
----
7654
8099
8633

query I rowsort
SELECT ALL - col0 * - tab2.col2 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + + col2 * cor0.col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT + col2 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4697
SELECT + CAST( NULL AS SIGNED ) * 74 / - cor0.col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4697
SELECT + CAST ( NULL AS INTEGER ) * 74 / - cor0.col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * + 56 FROM tab2 cor0
----
392
4368
4424

onlyif mysql # use DIV operator for integer division
query I rowsort label-4699
SELECT ( - 47 ) DIV cor0.col1 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-4699
SELECT ( - 47 ) / cor0.col1 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT + 37 * + 78 FROM tab2 AS cor0
----
2886
2886
2886

query I rowsort
SELECT + - cor0.col0 + 98 AS col0 FROM tab0 AS cor0
----
63
74
9

query I rowsort
SELECT ALL - col1 + - ( col2 ) AS col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT - - cor0.col1 + 34 + - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1356
696
8046

query I rowsort
SELECT DISTINCT col0 * col1 - - col2 * col0 * - 42 FROM tab0 AS cor0
----
-298417
-31200
1925

query I rowsort
SELECT col2 - - 81 FROM tab1 AS cor0
----
135
138
177

query I rowsort
SELECT - 9 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 3dfe689e16ce3a87877d40f349e6c7b5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4707
SELECT DISTINCT - + col2 * + CAST( + 49 AS SIGNED ) FROM tab1 AS cor0
----
-2646
-2793
-4704

skipif mysql # not compatible
query I rowsort label-4707
SELECT DISTINCT - + col2 * + CAST ( + 49 AS INTEGER ) FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT - col0 * col2 - ( col2 ) FROM tab2
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 + - tab2.col2 col2 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT col1 * col1 + + 19 * + col0 FROM tab2
----
1094
1790
4963

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - tab0.col2 col1 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT ALL - 14 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT ALL + - cor0.col2 + + col1 * + cor0.col0 + + col0 AS col0 FROM tab1 cor0
----
1024
27
647

query I rowsort
SELECT ALL + col0 - col0 * col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT - col2 + - col1 * - col0 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT - + col2 + - ( - col2 ) * - col2 + + col1 FROM tab1 AS cor0
----
-2944
-3296
-9299

query I rowsort
SELECT - 71 * 12 - col1 FROM tab1
----
-862
-865
-878

query I rowsort
SELECT DISTINCT - ( - col2 + - tab0.col1 ) * ( - col2 ) FROM tab0
----
-14186
-3927
-98

query I rowsort
SELECT + ( + tab2.col2 ) AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT ( - ( + col0 ) ) * 12 * col2 FROM tab2 cor0
----
-2268
-24336
-36024

query I rowsort
SELECT DISTINCT + + col1 * - col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + 14 + + col2 + - col0 FROM tab0 AS cor0
----
-20
23
7

query I rowsort
SELECT ALL + 39 + col0 FROM tab0 cor0
----
128
63
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-4725
SELECT + + col2 DIV cor0.col0 - - 84 col2 FROM tab0 AS cor0
----
84
84
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4725
SELECT + + col2 / cor0.col0 - - 84 col2 FROM tab0 AS cor0
----
84
84
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4726
SELECT + cor0.col2 - col1 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
-7363
-8199
-9408

skipif mysql # not compatible
query I rowsort label-4726
SELECT + cor0.col2 - col1 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-4727
SELECT + col0 * + col0 - + 97 DIV - col2 AS col2 FROM tab1 AS cor0
----
10
4097
6401

skipif mysql # not compatible
query I rowsort label-4727
SELECT + col0 * + col0 - + 97 / - col2 AS col2 FROM tab1 AS cor0
----
10
4097
6401

query I rowsort
SELECT DISTINCT 23 * col1 AS col0 FROM tab1
----
230
299
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-4729
SELECT - + cor0.col1 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4729
SELECT - + cor0.col1 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4730
SELECT DISTINCT 76 * + col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4730
SELECT DISTINCT 76 * + col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - + col1 - col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL + - 25 * - col2 FROM tab1 AS cor0
----
1350
1425
2400

query I rowsort
SELECT DISTINCT + - col0 * - col0 + + col0 * 78 AS col2 FROM tab2 AS cor0
----
12168
12403
595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 50 col0 FROM tab0
----
50
50
50

query I rowsort
SELECT ALL + - 73 * col1 + + col2 AS col1 FROM tab0 cor0
----
-6245
-6561
-7080

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
-7
-78
-79

query I rowsort
SELECT ALL + - 11 * - col1 + - col2 * col1 FROM tab1 AS cor0
----
-1105
-1118
-460

query I rowsort
SELECT + - cor0.col0 * + col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort
SELECT - - col1 + CAST ( 94 AS REAL ) + col1 FROM tab0 AS cor0
----
266
276
288

query I rowsort
SELECT + cor0.col2 * + col1 - 79 AS col0 FROM tab0 AS cor0
----
18
2759
7383

query I rowsort
SELECT cor0.col1 + 53 + - 77 * col1 AS col2 FROM tab2 AS cor0
----
-1239
-2303
-4431

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4742
SELECT + + col2 / CAST( NULL AS SIGNED ) - col2 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4742
SELECT + + col2 / CAST ( NULL AS INTEGER ) - col2 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - 15 + + col1 FROM tab2 cor0
----
103
19
47

query I rowsort
SELECT 47 + + col0 + 55 * - ( col2 ) AS col0 FROM tab2
----
-1305
-1431
-1964

query I rowsort
SELECT DISTINCT 47 + col0 + - col1 AS col0 FROM tab0
----
-15
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4746
SELECT ALL col2 * col0 + + 53 DIV - col0 FROM tab1
----
145
3648
7680

skipif mysql # not compatible
query I rowsort label-4746
SELECT ALL col2 * col0 + + 53 / - col0 FROM tab1
----
145
3648
7680

query I rowsort
SELECT ALL ( - col1 ) + 93 + ( - col1 ) AS col2 FROM tab2
----
-25
31
59

query I rowsort
SELECT + col1 * 44 + + col1 * col1 * ( + col0 ) FROM tab2 AS cor0
----
23579
274114
8091

query I rowsort
SELECT ALL 86 * - col0 + + 58 FROM tab1
----
-200
-5446
-6822

query I rowsort
SELECT ALL - col0 + - ( col0 ) - col1 FROM tab1 AS cor0
----
-138
-173
-32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4751
SELECT CAST( 53 AS SIGNED ) FROM tab0 cor0
----
53
53
53

skipif mysql # not compatible
query I rowsort label-4751
SELECT CAST ( 53 AS INTEGER ) FROM tab0 cor0
----
53
53
53

query I rowsort
SELECT DISTINCT cor0.col0 + + cor0.col2 * col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + - 64 + 15 FROM tab2 AS cor0
----
-49

query I rowsort
SELECT DISTINCT + 73 * + col1 + col0 FROM tab0 AS cor0
----
6302
6732
7116

query I rowsort
SELECT DISTINCT + 95 * col1 + + col2 FROM tab1 cor0
----
1007
1331
2524

query I rowsort
SELECT col1 * + 3 AS col0 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT ALL - + 91 - col0 FROM tab1 AS cor0
----
-155
-171
-94

query I rowsort
SELECT ALL + col0 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - - col1 * + col0 + + col2 + col0 AS col0 FROM tab0 AS cor0
----
2121
3431
8270

onlyif mysql # use DIV operator for integer division
query I rowsort label-4760
SELECT DISTINCT - + ( col1 ) * col0 + - CAST( col1 AS SIGNED ) DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-4760
SELECT DISTINCT - + ( col1 ) * col0 + - CAST ( col1 AS INTEGER ) / cor0.col2 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 22 col1 FROM tab1 AS cor0
----
22

query I rowsort
SELECT + + 88 AS col2 FROM tab2 cor0
----
88
88
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + 5 col0 FROM tab1 AS cor0
----
-21
-5
-8

query I rowsort
SELECT DISTINCT + - 54 + col0 AS col0 FROM tab0 AS cor0
----
-19
-30
35

query I rowsort
SELECT ALL + col2 * + 24 + - col2 FROM tab0 AS cor0
----
1886
23
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4766
SELECT ALL - col2 + + CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4766
SELECT ALL - col2 + + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + + ( 64 ) AS col2 FROM tab0
----
153
88
99

query I rowsort
SELECT ALL - cor0.col1 + col2 * col0 AS col2 FROM tab0 cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-4769
SELECT ALL - ( col2 ) + + col1 - cor0.col1 DIV 32 AS col1 FROM tab0 AS cor0
----
51
7
93

skipif mysql # not compatible
query I rowsort label-4769
SELECT ALL - ( col2 ) + + col1 - cor0.col1 / 32 AS col1 FROM tab0 AS cor0
----
51
7
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4770
SELECT col0 * + col1 + col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
2063
3394
8098

skipif mysql # not compatible
query I rowsort label-4770
SELECT col0 * + col1 + col0 / - col0 AS col1 FROM tab0 AS cor0
----
2063
3394
8098

query I rowsort
SELECT - 36 * col1 * col1 FROM tab1 AS cor0
----
-24336
-3600
-6084

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2 AS cor2
----
3645 values hashing to 85e6cb74738e0d8388af8fb625b2bd38

query I rowsort
SELECT + tab0.col0 * + col0 + + col0 * + col1 AS col2 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT DISTINCT + 65 * - 40 AS col0 FROM tab1 cor0
----
-2600

query I rowsort
SELECT DISTINCT 21 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4776
SELECT ALL col0 * + CAST( ( - col1 ) AS SIGNED ) FROM tab2
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-4776
SELECT ALL col0 * + CAST ( ( - col1 ) AS INTEGER ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT col0 * + tab0.col0 + col0 AS col2 FROM tab0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + 28 col1 FROM tab2 AS cor0
----
-10
1
2

query I rowsort
SELECT - col2 + + col2 * 91 FROM tab0 AS cor0
----
2970
7380
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4780
SELECT ALL + tab1.col2 * + CAST( NULL AS SIGNED ) * col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4780
SELECT ALL + tab1.col2 * + CAST ( NULL AS INTEGER ) * col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * 16 FROM tab0
----
1376
1456
1552

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col1 AS REAL ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT 53 * - col0 AS col1 FROM tab1 AS cor0
----
-159
-3392
-4240

query I rowsort
SELECT - 34 + col0 * cor0.col0 FROM tab0 cor0
----
1191
542
7887

query I rowsort
SELECT + + 75 * 1 AS col0 FROM tab0 AS cor0
----
75
75
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4786
SELECT - CAST( NULL AS SIGNED ) - - 59 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4786
SELECT - CAST ( NULL AS INTEGER ) - - 59 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + 87 FROM tab1 AS cor0
----
23
7
84

query I rowsort
SELECT + + col2 + - col1 - - col0 * ( col2 + col1 * + 48 ) FROM tab1 AS cor0
----
34415
3934
57683

query I rowsort
SELECT ( col2 ) * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - ( + col2 ) * ( col0 ) * - col2 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - col0 * col1 * cor0.col2 + + col0 AS col2 FROM tab2 AS cor0
----
-119574
-50955
-5852

onlyif mysql # use DIV operator for integer division
query I rowsort label-4792
SELECT + col0 DIV + col0 + + 21 DIV + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
1
22

skipif mysql # not compatible
query I rowsort label-4792
SELECT + col0 / + col0 + + 21 / + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
1
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4793
SELECT + col0 * col1 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4793
SELECT + col0 * col1 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * - col2 * cor0.col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4795
SELECT DISTINCT - col1 / + col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4795
SELECT DISTINCT - col1 / + col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col0 + + col0 * col2 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT ALL - col0 + + col2 * 96 FROM tab2 AS cor0
----
2418
2585
3569

query I rowsort
SELECT + cor0.col2 + cor0.col1 FROM tab1 cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col2 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - - 6 FROM tab1 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT - 37 * + cor0.col2 FROM tab2, tab0 cor0, tab0 AS cor1
----
-1221
-3034
-37

query I rowsort
SELECT + 44 * 63 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c1d519f0a3631b295b4b843342b2e378

query I rowsort
SELECT + col2 + + col1 AS col0 FROM tab2 cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col0 col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT col1 + + ( + col0 ) AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL col1 + col2 * + col1 * col1 + - col2 AS col2 FROM tab2 AS cor0
----
10961
25951
90539

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + - col2 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4808
SELECT - - col2 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4808
SELECT - - col2 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + col1 * ( - cor0.col0 ) + - cor0.col0 FROM tab1 AS cor0
----
-1024
-27
-647

query I rowsort
SELECT ALL - col1 - ( + col2 * cor0.col2 + ( 57 ) ) AS col1 FROM tab2 cor0
----
-1518
-792
-817

query I rowsort
SELECT - col1 + - col0 * - col0 FROM tab1 AS cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + 83 col2 FROM tab2 AS cor0
----
109
110
121

query I rowsort
SELECT ALL - cor0.col2 + - 85 * col0 FROM tab2 AS cor0
----
-622
-6656
-6753

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) AS col0 FROM tab2, tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col2 * col0 + - col2 FROM tab1 AS cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( col1 ) * cor0.col1 - col2 col2 FROM tab1 AS cor0
----
-157
-265
-730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4817
SELECT ( + col0 ) * + CAST( col1 AS SIGNED ) - col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-4817
SELECT ( + col0 ) * + CAST ( col1 AS INTEGER ) - col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - - col2 col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 * + col0 + 69 * col1 col1 FROM tab2 AS cor0
----
162255
238331
3462

onlyif mysql # use DIV operator for integer division
query I rowsort label-4820
SELECT - col0 + - col0 DIV + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-4820
SELECT - col0 + - col0 / + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT ( 57 ) AS col2 FROM tab2
----
57
57
57

query I rowsort
SELECT ALL 85 FROM tab0 cor0
----
85
85
85

query I rowsort
SELECT - 63 * + col1 FROM tab1
----
-1638
-630
-819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4824
SELECT CAST( + 74 AS SIGNED ) FROM tab1, tab2 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

skipif mysql # not compatible
query I rowsort label-4824
SELECT CAST ( + 74 AS INTEGER ) FROM tab1, tab2 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

onlyif mysql # use DIV operator for integer division
query I rowsort label-4825
SELECT ALL + col0 + col2 DIV 84 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4825
SELECT ALL + col0 + col2 / 84 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL col0 + col2 * col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL col0 * + 75 FROM tab2 AS cor0
----
525
5850
5925

query I rowsort
SELECT + + 32 * - col1 AS col2 FROM tab0 AS cor0
----
-2752
-2912
-3104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col1 * col1 col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT + ( - 6 ) * col0 + - 16 FROM tab0 AS cor0
----
-160
-226
-550

query I rowsort
SELECT ALL col0 * - ( + col1 * - tab2.col0 ) FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT col1 - col2 AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL 4 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + ( 72 ) + + col1 - col2 AS col1 FROM tab0
----
125
168
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4835
SELECT DISTINCT + 36 * - col2 + col2 DIV - col1 AS col0 FROM tab1
----
-1946
-2057
-3463

skipif mysql # not compatible
query I rowsort label-4835
SELECT DISTINCT + 36 * - col2 + col2 / - col1 AS col0 FROM tab1
----
-1946
-2057
-3463

query I rowsort
SELECT ALL + - ( - 50 ) * col2 FROM tab1 AS cor0
----
2700
2850
4800

query I rowsort
SELECT DISTINCT + ( 37 ) FROM tab1 cor0
----
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4838
SELECT ALL - CAST( col0 AS SIGNED ) * col1 + tab0.col0 * tab0.col1 * col2 FROM tab0
----
0
656019
66048

skipif mysql # not compatible
query I rowsort label-4838
SELECT ALL - CAST ( col0 AS INTEGER ) * col1 + tab0.col0 * tab0.col1 * col2 FROM tab0
----
0
656019
66048

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4839
SELECT ALL + CAST( NULL AS DECIMAL ) + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4839
SELECT ALL + CAST ( NULL AS REAL ) + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 89 + + 6 FROM tab2
----
95

query I rowsort
SELECT ALL 18 + - col2 AS col2 FROM tab0
----
-15
-64
17

query I rowsort
SELECT DISTINCT col0 * 73 AS col0 FROM tab0 AS cor0
----
1752
2555
6497

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col0 col2 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT + 96 + - tab1.col0 FROM tab1, tab2, tab1 AS cor0
----
16
32
93

query I rowsort
SELECT DISTINCT 77 * - tab1.col0 * + tab1.col0 + - tab1.col2 + col0 FROM tab1
----
-315385
-492816
-744

query I rowsort
SELECT ALL - col2 * tab1.col0 + + col1 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT ALL + col1 * + col1 + col0 DIV + tab2.col0 AS col1 FROM tab2
----
290
3482
962

skipif mysql # not compatible
query I rowsort label-4847
SELECT ALL + col1 * + col1 + col0 / + tab2.col0 AS col1 FROM tab2
----
290
3482
962

query I rowsort
SELECT 76 - + col0 FROM tab0
----
-13
41
52

query I rowsort
SELECT 87 + + tab1.col2 AS col0 FROM tab1
----
141
144
183

query I rowsort
SELECT ALL - 80 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT DISTINCT + - col2 * - col1 - col0 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT ALL - col1 + ( ( col2 ) ) AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - + col0 + - col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4854
SELECT DISTINCT - col2 + col0 DIV col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4854
SELECT DISTINCT - col2 + col0 / col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + col0 * - 42 AS col1 FROM tab2 AS cor0
----
-294
-3276
-3318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col0 + col2 + - col2 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4857
SELECT - - col2 + + CAST( NULL AS SIGNED ) * + 99 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4857
SELECT - - col2 + + CAST ( NULL AS INTEGER ) * + 99 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + 74 + col2 AS col0 FROM tab0 AS cor0
----
140
238
76

query I rowsort
SELECT - col2 + 23 * - col1 AS col2 FROM tab2 cor0
----
-1383
-429
-740

onlyif mysql # use DIV operator for integer division
query I rowsort label-4860
SELECT col0 DIV - CAST( + col0 * col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4860
SELECT col0 / - CAST ( + col0 * col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - col2 * cor0.col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - col0 * 20 AS col1 FROM tab2
----
-140
-1560
-1580

query I rowsort
SELECT - 18 FROM tab0, tab0 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4864
SELECT ALL + CAST( + 13 AS SIGNED ) + + tab0.col2 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 668a2742992d94283d4ebb1a66e12e06

skipif mysql # not compatible
query I rowsort label-4864
SELECT ALL + CAST ( + 13 AS INTEGER ) + + tab0.col2 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 668a2742992d94283d4ebb1a66e12e06

onlyif mysql # use DIV operator for integer division
query I rowsort label-4865
SELECT DISTINCT - col1 DIV 39 AS col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4865
SELECT DISTINCT - col1 / 39 AS col1 FROM tab1
----
0

query I rowsort
SELECT col0 + col1 * - 8 * col2 AS col1 FROM tab0
----
-22680
-59607
-741

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) AS col0 FROM tab0, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + - cor0.col0 * - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4869
SELECT DISTINCT + col2 + CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-4869
SELECT DISTINCT + col2 + CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4870
SELECT col1 + + col1 DIV - 73 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4870
SELECT col1 + + col1 / - 73 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4871
SELECT col1 DIV CAST( - ( col1 ) AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4871
SELECT col1 / CAST ( - ( col1 ) AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4872
SELECT DISTINCT - col0 DIV CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4872
SELECT DISTINCT - col0 / CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT ALL - - col1 + - 28 * col0 FROM tab1 AS cor0
----
-1782
-2227
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-4874
SELECT - - col0 + col2 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-4874
SELECT - - col0 + col2 / cor0.col2 AS col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT DISTINCT - + cor0.col0 + 26 AS col2 FROM tab0 AS cor0
----
-63
-9
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + cor0.col2 ) * - col0 + 54 * + col1 col0 FROM tab0 AS cor0
----
-2384
3852
5203

query I rowsort
SELECT + - ( + col0 ) * + col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + ( col2 ) * col2 * col0 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT - + col0 * - 12 * + cor0.col0 FROM tab2 AS cor0
----
588
73008
74892

query I rowsort
SELECT + col2 - 69 AS col1 FROM tab2
----
-31
-42
-43

query I rowsort
SELECT ALL - - 21 * col2 FROM tab2 AS cor0
----
546
567
798

query I rowsort
SELECT + cor0.col2 + + col0 * + col2 FROM tab2 cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-4883
SELECT - + col0 DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4883
SELECT - + col0 / cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 31 + + 52 * - col2 FROM tab2 AS cor0
----
-1321
-1373
-1945

query I rowsort
SELECT ALL + cor0.col2 * + col0 + + ( + col1 ) AS col1 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 - - col1 * + col0 col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT 31 AS col1 FROM tab1 AS cor0
----
31
31
31

query I rowsort
SELECT DISTINCT - cor0.col2 * + col2 + + cor0.col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT - 10 * col0 AS col0 FROM tab0 AS cor0
----
-240
-350
-890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4890
SELECT + cor0.col0 * col1 + CAST( col0 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
4736
7440
87

skipif mysql # not compatible
query I rowsort label-4890
SELECT + cor0.col0 * col1 + CAST ( col0 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT DISTINCT - 16 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-16

query I rowsort
SELECT DISTINCT cor0.col2 * col0 + col1 AS col0 FROM tab1 AS cor0
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 10 * + col0 + + 60 col1 FROM tab2 AS cor0
----
-10
-720
-730

query I rowsort
SELECT 25 * + col2 + - col2 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT + col0 * col0 - + 74 AS col1 FROM tab1 AS cor0
----
-65
4022
6326

query I rowsort
SELECT DISTINCT 69 + col1 * + col0 FROM tab0 AS cor0
----
2133
3464
8168

query I rowsort
SELECT DISTINCT - - col2 * + col1 * - ( - col1 ) + col0 AS col2 FROM tab1 AS cor0
----
16304
36507
5764

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * cor0.col2 + cor0.col0 col2 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + + col2 - col0 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-4900
SELECT col1 + col1 DIV 54 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4900
SELECT col1 + col1 / 54 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT - - 89 * + col2 * ( - cor0.col1 * col0 ) + + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-10648950
-4541947
-521444

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4902
SELECT ALL - - col0 * + col1 + - CAST( col2 + + col2 AS SIGNED ) / - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4902
SELECT ALL - - col0 * + col1 + - CAST ( col2 + + col2 AS INTEGER ) / - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col0 ) - - col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col0 * cor0.col2 * 21 FROM tab1 AS cor0
----
161280
3402
76608

query I rowsort
SELECT DISTINCT - - 80 + col2 AS col0 FROM tab2 AS cor0
----
106
107
118

query I rowsort
SELECT ALL - col2 * + ( + col0 ) FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - - col2 * - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT DISTINCT - col1 * + col0 + 79 * ( col1 ) FROM tab2
----
0
2232
59

query I rowsort
SELECT + 49 + col2 FROM tab1
----
103
106
145

query I rowsort
SELECT + 24 * col1 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT col1 + + 91 * + col0 FROM tab0
----
2270
3282
8190

query I rowsort
SELECT DISTINCT - 37 * col1 FROM tab1
----
-370
-481
-962

query I rowsort
SELECT 28 * + col0 FROM tab0
----
2492
672
980

query I rowsort
SELECT + 72 * + col0 FROM tab1 AS cor0
----
216
4608
5760

query I rowsort
SELECT 6 * 27 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 480af13fa97bed507a41d8a44cc231af

query I rowsort
SELECT DISTINCT cor2.col1 AS col2 FROM tab0 cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2
----
10
13
26

query I rowsort
SELECT ALL - - col0 + 81 * ( - col0 ) AS col2 FROM tab1 AS cor0
----
-240
-5120
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 49 + col0 col2 FROM tab0 AS cor0
----
-14
-25
40

query I rowsort
SELECT DISTINCT + 74 * + col1 * col2 AS col2 FROM tab0 AS cor0
----
210012
552188
7178

query I rowsort
SELECT ( + tab2.col0 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ( + col2 ) * cor0.col2 + ( col0 ) + col1 * - col2 AS col0 FROM tab0 AS cor0
----
-1725
-61
-649

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4922
SELECT + ( cor0.col2 ) * cor0.col1 + - CAST( NULL AS SIGNED ) / + col2 + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4922
SELECT + ( cor0.col2 ) * cor0.col1 + - CAST ( NULL AS INTEGER ) / + col2 + cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 40 + col0 FROM tab1
----
104
120
43

query I rowsort
SELECT ( 76 ) * col1 + + col0 AS col1 FROM tab1 AS cor0
----
1068
1979
824

query I rowsort
SELECT - + 1 + - col0 + - col0 AS col0 FROM tab0 AS cor0
----
-179
-49
-71

query I rowsort
SELECT + - cor0.col2 * - 70 + col2 FROM tab2 AS cor0
----
1846
1917
2698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * col1 col1 FROM tab2 cor0
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4928
SELECT - col1 + - ( + col2 ) * CAST( NULL AS SIGNED ) - 36 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4928
SELECT - col1 + - ( + col2 ) * CAST ( NULL AS INTEGER ) - 36 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 10 * col1 + - col1 FROM tab2 AS cor0
----
-187
-341
-649

query I rowsort
SELECT - - cor0.col0 + col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4931
SELECT ALL + 38 DIV cor0.col0 AS col1 FROM tab0 cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4931
SELECT ALL + 38 / cor0.col0 AS col1 FROM tab0 cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 + + col2 col1 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT DISTINCT - col1 * col2 + - cor0.col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL + - 24 * col2 + col0 FROM tab0 cor0
----
-1879
-768
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + col1 * cor0.col0 col2 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT - col0 + ( cor0.col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - + col2 * 21 * + 35 AS col0 FROM tab0 AS cor0
----
-24255
-60270
-735

onlyif mysql # use DIV operator for integer division
query I rowsort label-4938
SELECT DISTINCT col2 * col2 + col2 * ( col2 ) DIV col0 + 66 * 25 col1 FROM tab2 AS cor0
----
2334
2483
3112

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4938
SELECT DISTINCT col2 * col2 + col2 * ( col2 ) / col0 + 66 * 25 col1 FROM tab2 AS cor0
----
2334
2483
3112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 62 * - 39 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 52eccfaebee1dd44cefa2292431f0475

query I rowsort
SELECT ALL - + col2 * + col0 + + col1 * + ( col1 ) AS col2 FROM tab2 AS cor0
----
-2713
1453
772

query I rowsort
SELECT ALL ( + 46 ) FROM tab1 AS cor0
----
46
46
46

query I rowsort
SELECT cor0.col1 + cor0.col0 AS col0 FROM tab2 cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4943
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - col0 * - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4943
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - col0 * - col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4944
SELECT + col2 DIV - 29 col2 FROM tab1
----
-1
-1
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4944
SELECT + col2 / - 29 col2 FROM tab1
----
-1
-1
-3

query I rowsort
SELECT - col0 * - col0 * + ( + col1 * + 50 ) AS col0 FROM tab2
----
17947800
5304850
75950

query I rowsort
SELECT ALL 97 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 85 col2 FROM tab0, tab2 AS cor0
----
85

query I rowsort
SELECT ALL + col2 + - 40 AS col0 FROM tab0 AS cor0
----
-39
-7
42

query I rowsort
SELECT ALL - col0 + ( - col2 ) FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4950
SELECT ALL cor0.col0 + col1 + col1 DIV cor0.col0 FROM tab0 AS cor0
----
113
134
181

skipif mysql # not compatible
query I rowsort label-4950
SELECT ALL cor0.col0 + col1 + col1 / cor0.col0 FROM tab0 AS cor0
----
113
134
181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col0 col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL cor0.col0 * col0 + - col0 AS col0 FROM tab0 cor0
----
1190
552
7832

query I rowsort
SELECT - - col0 + ( + ( + col2 ) ) * + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + col2 + + 91 AS col1 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT DISTINCT + col2 + ( 27 ) + - col2 AS col2 FROM tab0 AS cor0
----
27

query I rowsort
SELECT - col0 * 95 + + 23 * col0 AS col1 FROM tab2 AS cor0
----
-504
-5616
-5688

onlyif mysql # use DIV operator for integer division
query I rowsort label-4958
SELECT + - col0 DIV col1 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4958
SELECT + - col0 / col1 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT DISTINCT - + col2 * col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col1 * - 27 FROM tab0 AS cor0
----
-2322
-2457
-2619

onlyif mysql # use DIV operator for integer division
query I rowsort label-4961
SELECT DISTINCT - ( col1 ) DIV + cor0.col1 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4961
SELECT DISTINCT - ( col1 ) / + cor0.col1 FROM tab1 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4962
SELECT ALL col0 DIV + 43 FROM tab0 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4962
SELECT ALL col0 / + 43 FROM tab0 cor0
----
0
0
2

query I rowsort
SELECT + 15 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT col1 * col0 + + col1 * col1 FROM tab0
----
12804
16380
9460

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4965
SELECT ALL + col1 + col1 / CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4965
SELECT ALL + col1 + col1 / CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 65 * - col0 + - cor0.col1 FROM tab2 AS cor0
----
424
5011
5118

onlyif mysql # use DIV operator for integer division
query I rowsort label-4967
SELECT + - col0 + col1 DIV + 94 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4967
SELECT + - col0 + col1 / + 94 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4968
SELECT ALL - - 73 + cor0.col2 DIV - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
74
74
74

skipif mysql # not compatible
query I rowsort label-4968
SELECT ALL - - 73 + cor0.col2 / - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
74
74
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-4969
SELECT DISTINCT 39 DIV col0 + - col0 FROM tab2 AS cor0
----
-2
-78
-79

skipif mysql # not compatible
query I rowsort label-4969
SELECT DISTINCT 39 / col0 + - col0 FROM tab2 AS cor0
----
-2
-78
-79

query I rowsort
SELECT DISTINCT - + cor0.col1 * col1 + 69 * col2 * - col2 FROM tab2 AS cor0
----
-50125
-51262
-99925

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT - col0 * + col0 * - 81 - + col0 * - col1 AS col1 FROM tab1 AS cor0
----
332416
519440
807

query I rowsort
SELECT - col2 + col1 * + 23 FROM tab1 cor0
----
173
203
544

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4974
SELECT ALL + 0 + - col1 * CAST( - 32 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
2752
2912
3104

skipif mysql # not compatible
query I rowsort label-4974
SELECT ALL + 0 + - col1 * CAST ( - 32 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2752
2912
3104

query I rowsort
SELECT col0 + col1 * + 92 FROM tab2 AS cor0
----
1643
2859
5506

query I rowsort
SELECT - + col1 * + ( - col0 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4977
SELECT col2 + + col0 * col0 DIV col1 AS col1 FROM tab2 AS cor0
----
129
28
405

skipif mysql # not compatible
query I rowsort label-4977
SELECT col2 + + col0 * col0 / col1 AS col1 FROM tab2 AS cor0
----
129
28
405

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4978
SELECT + col0 * + CAST( - 26 * - col0 AS SIGNED ) FROM tab0 AS cor0
----
14976
205946
31850

skipif mysql # not compatible
query I rowsort label-4978
SELECT + col0 * + CAST ( - 26 * - col0 AS INTEGER ) FROM tab0 AS cor0
----
14976
205946
31850

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT col1 * col2 DIV - col1 + - col2 * col0 FROM tab1
----
-216
-3705
-7776

skipif mysql # not compatible
query I rowsort label-4979
SELECT col1 * col2 / - col1 + - col2 * col0 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT + col2 * + col2 + - 69 FROM tab2
----
1375
607
660

query I rowsort
SELECT 2 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT 54 AS col2 FROM tab2
----
54
54
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-4983
SELECT - col2 DIV + col2 + col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-4983
SELECT - col2 / + col2 + col2 FROM tab1
----
53
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4984
SELECT DISTINCT - col2 + 13 DIV col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4984
SELECT DISTINCT - col2 + 13 / col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + cor0.col2 + - ( col1 ) FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT + - col0 + - col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4987
SELECT - col2 + CAST( - 47 AS SIGNED ) FROM tab0 AS cor0
----
-129
-48
-80

skipif mysql # not compatible
query I rowsort label-4987
SELECT - col2 + CAST ( - 47 AS INTEGER ) FROM tab0 AS cor0
----
-129
-48
-80

query I rowsort
SELECT DISTINCT - + 0 + + ( cor1.col0 ) + + 62 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
126
142
65

query I rowsort
SELECT - - 28 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT cor0.col2 * 91 FROM tab0, tab1 AS cor0
----
9 values hashing to 45285ffa439708fe5215b7a3a1f4aef8

query I rowsort
SELECT - col1 * + 72 * - tab1.col0 + + col0 AS col2 FROM tab1
----
46144
5619
74960

query I rowsort
SELECT + + col0 + col2 * col1 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4993
SELECT ALL col0 / + CAST( NULL AS SIGNED ) + - ( - col1 + col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4993
SELECT ALL col0 / + CAST ( NULL AS INTEGER ) + - ( - col1 + col0 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 24 FROM tab0, tab0 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT DISTINCT + col2 * col1 - col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + + 87 * + col1 + col2 FROM tab1 AS cor0
----
1227
2316
927

query I rowsort
SELECT + col2 * col2 - + 36 FROM tab1 cor0
----
2880
3213
9180

query I rowsort
SELECT ALL + 6 * + tab2.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 77086711deaa68b47c6dc962dc1127d8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4999
SELECT col0 DIV + 57 + - col2 + col1 FROM tab0
----
10
53
96

skipif mysql # not compatible
query I rowsort label-4999
SELECT col0 / + 57 + - col2 + col1 FROM tab0
----
10
53
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5000
SELECT ALL - + ( + col0 ) + col2 DIV 73 FROM tab1 AS cor0
----
-3
-64
-79

skipif mysql # not compatible
query I rowsort label-5000
SELECT ALL - + ( + col0 ) + col2 / 73 FROM tab1 AS cor0
----
-3
-64
-79

query I rowsort
SELECT ALL - 98 * col0 FROM tab0 AS cor0
----
-2352
-3430
-8722

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 ALL col2 + col2 + col1 FROM tab2
----
111
85
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-5004
SELECT ALL + CAST( col0 AS SIGNED ) DIV - col0 + 55 FROM tab0
----
54
54
54

skipif mysql # not compatible
query I rowsort label-5004
SELECT ALL + CAST ( col0 AS INTEGER ) / - col0 + 55 FROM tab0
----
54
54
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5005
SELECT + CAST( NULL AS SIGNED ) FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5005
SELECT + CAST ( NULL AS INTEGER ) FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + col2 - cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( col1 ) * cor0.col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - ( - col0 ) + - col2 AS col1 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + 45 * + col1 AS col0 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT 39 + col1 FROM tab1 AS cor0
----
49
52
65

query I rowsort
SELECT + col1 - + col1 * col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5012
SELECT - - 90 * + col0 + - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5012
SELECT - - 90 * + col0 + - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 97 * col0 FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT DISTINCT + 38 AS col2 FROM tab2 AS cor0
----
38

query I rowsort
SELECT DISTINCT + 79 AS col2 FROM tab1
----
79

query I rowsort
SELECT ( 35 ) FROM tab0
----
35
35
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-5017
SELECT ALL 35 DIV tab2.col1 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5017
SELECT ALL 35 / tab2.col1 FROM tab2
----
0
1
2

query I rowsort
SELECT ALL col2 * col2 + + col0 * col2 AS col2 FROM tab0
----
14022
1881
36

query I rowsort
SELECT DISTINCT 29 * cor2.col0 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
1015
2581
696

onlyif mysql # use DIV operator for integer division
query I rowsort label-5020
SELECT + 52 DIV + ( col0 * 43 ) + 6 AS col1 FROM tab0 AS cor0
----
6
6
6

skipif mysql # not compatible
query I rowsort label-5020
SELECT + 52 / + ( col0 * 43 ) + 6 AS col1 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT 77 * - col1 AS col2 FROM tab1 cor0
----
-1001
-2002
-770

query I rowsort
SELECT ALL + cor0.col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT 24 * col1 * - ( + 82 ) + - col1 FROM tab2 AS cor0
----
-116171
-33473
-61039

query I rowsort
SELECT + 69 * col2 AS col2 FROM tab0 AS cor0
----
2277
5658
69

query I rowsort
SELECT - col0 + - col1 * - 72 AS col0 FROM tab1 AS cor0
----
1869
656
856

query I rowsort
SELECT DISTINCT + ( + 62 ) AS col0 FROM tab1
----
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5028
SELECT + CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5028
SELECT + CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5029
SELECT DISTINCT CAST( - col1 + col2 AS SIGNED ) FROM tab1
----
28
47
83

skipif mysql # not compatible
query I rowsort label-5029
SELECT DISTINCT CAST ( - col1 + col2 AS INTEGER ) FROM tab1
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col0 - col0 col2 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT col0 - 53 * - ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
1650
3205
980

query I rowsort
SELECT - col1 - ( ( col0 ) ) FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT col1 * 42 + col0 FROM tab2 AS cor0
----
1309
2556
793

onlyif mysql # use DIV operator for integer division
query I rowsort label-5034
SELECT - cor0.col0 * + ( - ( col1 ) * - col0 ) + + col2 DIV col1 FROM tab1 AS cor0
----
-232
-40955
-83193

skipif mysql # not compatible
query I rowsort label-5034
SELECT - cor0.col0 * + ( - ( col1 ) * - col0 ) + + col2 / col1 FROM tab1 AS cor0
----
-232
-40955
-83193

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5035
SELECT col2 + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort label-5035
SELECT col2 + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5036
SELECT col0 + CAST( + col2 AS SIGNED ) col1 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5036
SELECT col0 + CAST ( + col2 AS INTEGER ) col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - col0 * - ( - col2 ) AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - 3 * col1 + tab2.col2 AS col0 FROM tab2
----
-13
-151
-66

query I rowsort
SELECT + ( tab0.col0 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # use DIV operator for integer division
query I rowsort label-5040
SELECT col1 * ( + col1 ) DIV + col0 AS col2 FROM tab0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-5040
SELECT col1 * ( + col1 ) / + col0 AS col2 FROM tab0
----
268
308
93

query I rowsort
SELECT 28 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT - - col1 * + 60 + - col2 + col2 AS col2 FROM tab1 AS cor0
----
1560
600
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-5043
SELECT col2 + 7 * cor0.col2 DIV - cor0.col0 AS col0 FROM tab2 AS cor0
----
0
24
35

skipif mysql # not compatible
query I rowsort label-5043
SELECT col2 + 7 * cor0.col2 / - cor0.col0 AS col0 FROM tab2 AS cor0
----
0
24
35

query I rowsort
SELECT ALL 39 + - col2 FROM tab1 AS cor0
----
-15
-18
-57

query I rowsort
SELECT ALL 58 + - col0 FROM tab2 AS cor0
----
-20
-21
51

query I rowsort
SELECT DISTINCT - - 65 * col2 AS col1 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT ALL - col0 * ( col1 ) - - col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - col1 + + col1 * col1 * col2 AS col2 FROM tab0 AS cor0
----
243982
678951
9312

query I rowsort
SELECT ALL + - col1 * - col0 + + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - 54 + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1194
1350
516

query I rowsort
SELECT DISTINCT + 35 + col0 FROM tab2 AS cor0
----
113
114
42

query I rowsort
SELECT ALL + tab1.col1 * ( + col1 ) FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT col0 * col2 - 55 AS col0 FROM tab1
----
107
3593
7625

query I rowsort
SELECT ( - col0 ) - - col0 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT 67 AS col2 FROM tab1
----
67
67
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 35 col0 FROM tab2
----
35
35
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-5057
SELECT - + CAST( col1 AS SIGNED ) + + col2 DIV 20 AS col1 FROM tab1 AS cor0
----
-24
-8
-9

skipif mysql # not compatible
query I rowsort label-5057
SELECT - + CAST ( col1 AS INTEGER ) + + col2 / 20 AS col1 FROM tab1 AS cor0
----
-24
-8
-9

query I rowsort
SELECT ALL - - col1 * + ( + col1 ) AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ( col1 ) * col2 - - 67 FROM tab0 AS cor0
----
164
2905
7529

query I rowsort
SELECT DISTINCT + - 22 * - col0 + + col1 * - 2 FROM tab1 AS cor0
----
1388
14
1734

query I rowsort
SELECT - 27 + - col2 AS col1 FROM tab0 AS cor0
----
-109
-28
-60

query I rowsort
SELECT + + col0 + - 25 AS col1 FROM tab2 AS cor0
----
-18
53
54

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col0 * col0 AS col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT + - col0 + col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT 56 + col0 FROM tab1
----
120
136
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5066
SELECT - col0 + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5066
SELECT - col0 + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5067
SELECT + col1 + ( + col0 ) DIV - col1 FROM tab2
----
13
31
58

skipif mysql # not compatible
query I rowsort label-5067
SELECT + col1 + ( + col0 ) / - col1 FROM tab2
----
13
31
58

query I rowsort
SELECT + cor0.col1 * col1 * col1 AS col2 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT ALL col2 * - col1 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + 18 * col1 + col2 * + 73 FROM tab2 cor0
----
2529
2960
3080

query I rowsort
SELECT + - cor0.col1 * + col0 + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + 97 * - 46 AS col0 FROM tab0 AS cor0
----
-4462
-4462
-4462

query I rowsort
SELECT - 68 * col2 + col2 AS col0 FROM tab1 cor0
----
-3618
-3819
-6432

onlyif mysql # use DIV operator for integer division
query I rowsort label-5074
SELECT ALL + - col0 + + col1 DIV col2 FROM tab0 AS cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-5074
SELECT ALL + - col0 + + col1 / col2 FROM tab0 AS cor0
----
-22
-88
62

query I rowsort
SELECT ( ( + tab2.col2 ) ) FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5076
SELECT DISTINCT - CAST( NULL AS DECIMAL ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5076
SELECT DISTINCT - CAST ( NULL AS REAL ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5077
SELECT ALL col0 + cor0.col0 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5077
SELECT ALL col0 + cor0.col0 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 AS col1 FROM tab2, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 91 * col0 + col0 AS col1 FROM tab0 AS cor0
----
-2160
-3150
-8010

query I rowsort
SELECT DISTINCT 10 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
10

query I rowsort
SELECT + + col1 * + col1 * - col2 + + col2 AS col1 FROM tab2 AS cor0
----
-10944
-25920
-90480

query I rowsort
SELECT - col0 * + tab1.col0 * col2 AS col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT ALL col1 + - ( - col0 ) FROM tab0
----
110
132
180

query I rowsort
SELECT - col0 * col2 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL col0 + - col0 * + col0 AS col2 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - - col1 * 54 FROM tab2 AS cor0
----
1674
3186
918

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT ALL + - col0 + - 42 DIV col2 + col2 AS col1 FROM tab0 cor0
----
-7
-76
8

skipif mysql # not compatible
query I rowsort label-5087
SELECT ALL + - col0 + - 42 / col2 + col2 AS col1 FROM tab0 cor0
----
-7
-76
8

query I rowsort
SELECT ALL + + col1 + 11 AS col1 FROM tab2 cor0
----
28
42
70

query I rowsort
SELECT - + col0 + 23 FROM tab1 AS cor0
----
-41
-57
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5090
SELECT - col2 DIV + 99 + col1 DIV col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5090
SELECT - col2 / + 99 + col1 / col1 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5091
SELECT ALL + CAST( NULL AS SIGNED ) * - col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5091
SELECT ALL + CAST ( NULL AS INTEGER ) * - col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5092
SELECT + + 29 * + col2 + - col2 DIV + 49 + + col2 AS col0 FROM tab0 AS cor0
----
2459
30
990

skipif mysql # not compatible
query I rowsort label-5092
SELECT + + 29 * + col2 + - col2 / + 49 + + col2 AS col0 FROM tab0 AS cor0
----
2459
30
990

query I rowsort
SELECT DISTINCT - + 65 FROM tab2 AS cor0
----
-65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5094
SELECT + CAST( + col1 AS DECIMAL ) + - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5094
SELECT + CAST ( + col1 AS REAL ) + - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 74 FROM tab1 AS cor0
----
74

query I rowsort
SELECT 50 * col0 * - cor0.col0 FROM tab0 AS cor0
----
-28800
-396050
-61250

query I rowsort
SELECT - - ( ( - col2 ) ) * col1 + + col2 + col1 * 23 FROM tab0 AS cor0
----
-5287
-827
2135

query I rowsort
SELECT ALL + - col2 + col1 * - col1 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT + col2 - - ( - tab0.col1 + col2 ) AS col1 FROM tab0
----
-20
-95
73

query I rowsort
SELECT DISTINCT - col0 * 35 + + col1 FROM tab1
----
-2230
-2787
-79

query I rowsort
SELECT - - col0 + + ( col1 ) AS col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 - + col0 col2 FROM tab2
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5103
SELECT ALL 69 DIV cor0.col0 + col2 FROM tab1 AS cor0
----
58
77
96

skipif mysql # not compatible
query I rowsort label-5103
SELECT ALL 69 / cor0.col0 + col2 FROM tab1 AS cor0
----
58
77
96

query I rowsort
SELECT DISTINCT ( 10 ) FROM tab1 AS cor0
----
10

query I rowsort
SELECT ALL cor0.col1 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - col0 + + 67 AS col0 FROM tab2 AS cor0
----
-11
-12
60

query I rowsort
SELECT col1 * + 62 FROM tab2
----
1054
1922
3658

onlyif mysql # use DIV operator for integer division
query I rowsort label-5108
SELECT DISTINCT + col1 DIV cor0.col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5108
SELECT DISTINCT + col1 / cor0.col1 FROM tab2 AS cor0
----
1

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 15ae1b54cae2dcf5c6eef7f1d15689eb

query I rowsort
SELECT ALL col2 - + tab2.col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT 60 + - 24 AS col2 FROM tab2 AS cor0
----
36
36
36

query I rowsort
SELECT ALL col2 + col2 * + tab2.col2 FROM tab2
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-5113
SELECT - 87 DIV col0 FROM tab2 AS cor0
----
-1
-1
-12

skipif mysql # not compatible
query I rowsort label-5113
SELECT - 87 / col0 FROM tab2 AS cor0
----
-1
-1
-12

query I rowsort
SELECT 77 * - tab2.col1 FROM tab2
----
-1309
-2387
-4543

query I rowsort
SELECT - 4 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT ALL col0 - - ( + col1 ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + - col2 + - col2 AS col0 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT ALL - col1 * ( 72 ) + col0 * + 54 + - ( + col0 ) * - col1 FROM tab0 AS cor0
----
-1699
-2832
6353

query I rowsort
SELECT ALL + 18 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5120
SELECT DISTINCT + col0 + CAST( NULL AS SIGNED ) * 32 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5120
SELECT DISTINCT + col0 + CAST ( NULL AS INTEGER ) * 32 AS col0 FROM tab0
----
NULL

query I rowsort
SELECT ALL - 19 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

onlyif mysql # use DIV operator for integer division
query I rowsort label-5122
SELECT - tab1.col1 * col2 DIV col1 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5122
SELECT - tab1.col1 * col2 / col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + tab1.col1 + col2 + - col1 AS col2 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5124
SELECT DISTINCT + col0 + col2 * col1 DIV - col0 + + col1 FROM tab1 AS cor0
----
-439
66
78

skipif mysql # not compatible
query I rowsort label-5124
SELECT DISTINCT + col0 + col2 * col1 / - col0 + + col1 FROM tab1 AS cor0
----
-439
66
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5125
SELECT DISTINCT + cor0.col0 DIV - 77 + 38 * col2 FROM tab0 AS cor0
----
1254
3115
38

skipif mysql # not compatible
query I rowsort label-5125
SELECT DISTINCT + cor0.col0 / - 77 + 38 * col2 FROM tab0 AS cor0
----
1254
3115
38

query I rowsort
SELECT - cor0.col1 * - col0 AS col2 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * + cor0.col1 col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5128
SELECT ALL + col0 DIV - col0 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5128
SELECT ALL + col0 / - col0 FROM tab2 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col1 + - 90 FROM tab1 AS cor0
----
-100
-103
-116

query I rowsort
SELECT ALL - - col2 + + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 65 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
65

query I rowsort
SELECT - cor0.col1 + + col2 + col1 * - 9 FROM tab0 AS cor0
----
-827
-828
-969

query I rowsort
SELECT - 88 * col2 FROM tab2 cor0
----
-2288
-2376
-3344

query I rowsort
SELECT + - col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + col2 + cor0.col2 + 34 FROM tab0 AS cor0
----
100
198
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-5136
SELECT - + col2 + col1 DIV col1 + + col0 FROM tab1 AS cor0
----
-15
-50
8

skipif mysql # not compatible
query I rowsort label-5136
SELECT - + col2 + col1 / col1 + + col0 FROM tab1 AS cor0
----
-15
-50
8

query I rowsort
SELECT - col1 + - 30 * - col0 AS col2 FROM tab0 AS cor0
----
2579
634
953

query I rowsort
SELECT DISTINCT cor0.col0 + 9 + 24 FROM tab1 AS cor0
----
113
36
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5139
SELECT 64 DIV + tab2.col0 AS col0 FROM tab2
----
0
0
9

skipif mysql # not compatible
query I rowsort label-5139
SELECT 64 / + tab2.col0 AS col0 FROM tab2
----
0
0
9

query I rowsort
SELECT + col0 * ( - col2 * + col2 ) + 5 + + 26 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-207671
-736937
-8067

query I rowsort
SELECT + col2 * 41 FROM tab0 AS cor0
----
1353
3362
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 75 col0 FROM tab2 AS cor0
----
101
102
113

query I rowsort
SELECT + + cor0.col0 * col1 - col0 * col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5144
SELECT DISTINCT - CAST( - col2 AS SIGNED ) * col1 + col1 FROM tab0 AS cor0
----
194
2924
7553

skipif mysql # not compatible
query I rowsort label-5144
SELECT DISTINCT - CAST ( - col2 AS INTEGER ) * col1 + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + ( + col0 ) * - col2 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5146
SELECT CAST( NULL AS SIGNED ) * + col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5146
SELECT CAST ( NULL AS INTEGER ) * + col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 56 + col2 + col1 * - ( + ( + cor0.col2 ) ) AS col0 FROM tab2 AS cor0
----
-1564
-664
-866

query I rowsort
SELECT ALL - + ( cor0.col2 ) AS col2 FROM tab0 cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 * col0 + + col2 col2 FROM tab2
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-5150
SELECT 97 DIV col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5150
SELECT 97 / col1 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + 69 * - col1 + col0 * col1 FROM tab2 AS cor0
----
-1922
170
531

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 * ( + cor0.col1 + col2 ) FROM tab0 cor0
----
10258
15832
9541

query I rowsort
SELECT ALL + col0 - col0 * col0 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5154
SELECT DISTINCT + ( - col2 ) + + cor0.col0 DIV + col1 FROM tab2 AS cor0
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-5154
SELECT DISTINCT + ( - col2 ) + + cor0.col0 / + col1 FROM tab2 AS cor0
----
-25
-27
-34

query I rowsort
SELECT ALL col2 + col0 * 47 AS col1 FROM tab2 AS cor0
----
356
3692
3751

query I rowsort
SELECT - + 94 FROM tab1 AS cor0
----
-94
-94
-94

query I rowsort
SELECT DISTINCT - + 7 + + col2 + - col1 FROM tab0 cor0
----
-103
-16
-60

query I rowsort
SELECT ALL + 89 * + cor0.col0 * + col0 - + cor0.col1 FROM tab1 AS cor0
----
364534
569587
775

query I rowsort
SELECT 54 * - cor0.col1 AS col0 FROM tab1 cor0
----
-1404
-540
-702

query I rowsort
SELECT - 43 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5161
SELECT ALL + + col1 + + CAST( NULL AS SIGNED ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5161
SELECT ALL + + col1 + + CAST ( NULL AS INTEGER ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5162
SELECT - tab1.col2 - + col0 DIV col2 FROM tab1
----
-54
-58
-96

skipif mysql # not compatible
query I rowsort label-5162
SELECT - tab1.col2 - + col0 / col2 FROM tab1
----
-54
-58
-96

query I rowsort
SELECT 13 AS col0 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT DISTINCT + 95 * col1 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
27455
330695
91295

query I rowsort
SELECT DISTINCT + 29 - - col2 AS col2 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT DISTINCT 94 + + col0 - + col0 FROM tab1 AS cor0
----
94

query I rowsort
SELECT 34 + ( col2 + + 45 ) * + col0 AS col1 FROM tab0 AS cor0
----
11337
1644
1906

query I rowsort
SELECT DISTINCT - 34 + 31 AS col0 FROM tab2 AS cor0
----
-3

query I rowsort
SELECT 69 FROM tab0, tab0 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT + tab0.col1 - ( col0 ) * + col0 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT ALL - col1 * + ( - tab0.col0 ) AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ( - 1 + col1 ) AS col1 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 87 col2 FROM tab1
----
-87

query I rowsort
SELECT + 76 + col1 AS col2 FROM tab1 AS cor0
----
102
86
89

query I rowsort
SELECT DISTINCT + cor0.col0 * 69 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
207
4416
5520

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1, tab2 cor2
----
3645 values hashing to b34c9987c389223e07378cde8a36e94f

query I rowsort
SELECT + col2 * ( + col1 + col0 ) AS col2 FROM tab2 AS cor0
----
1026
3562
3648

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT DISTINCT + col2 + - 98 * + 41 * + col1 + 56 * 56 AS col0 FROM tab0 AS cor0
----
-342379
-362420
-386609

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5180
SELECT - cor0.col2 + CAST( + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5180
SELECT - cor0.col2 + CAST ( + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col2 + ( col2 ) AS col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - + col1 * + col0 + cor0.col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT col2 + 95 AS col0 FROM tab0 cor0
----
128
177
96

query I rowsort
SELECT DISTINCT - col0 * - 53 FROM tab2 AS cor0
----
371
4134
4187

query I rowsort
SELECT DISTINCT col0 * + 48 + - col2 FROM tab1 AS cor0
----
3015
3744
90

query I rowsort
SELECT col2 + - 30 * col2 AS col2 FROM tab0 AS cor0
----
-2378
-29
-957

query I rowsort
SELECT DISTINCT col2 * col1 + col2 * ( col0 ) FROM tab2
----
1026
3562
3648

query I rowsort
SELECT - col1 - + cor0.col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + col2 + col1 * tab2.col2 - 57 AS col1 FROM tab2
----
1503
627
807

query I rowsort
SELECT col1 + + col0 * - 82 * col1 + col2 FROM tab0
----
-169129
-278292
-663945

query I rowsort
SELECT DISTINCT - col1 * + col1 + col2 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT + + col0 + col1 + col2 * + col0 FROM tab0 AS cor0
----
167
7478
902

query I rowsort
SELECT ALL + col1 * col2 - 87 FROM tab0 AS cor0
----
10
2751
7375

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5194
SELECT ALL - + col1 * ( 6 ) + - col2 * - CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
1180
544
651

skipif mysql # not compatible
query I rowsort label-5194
SELECT ALL - + col1 * ( 6 ) + - col2 * - CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
1180
544
651

query I rowsort
SELECT - col0 + 67 AS col2 FROM tab2 cor0
----
-11
-12
60

query I rowsort
SELECT ALL ( + 16 ) * - col0 AS col1 FROM tab2
----
-112
-1248
-1264

query I rowsort
SELECT DISTINCT col0 * + col0 + cor0.col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT col0 * - 1 * + col2 FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 + col1 col1 FROM tab1
----
101
85
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * ( col0 ) col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT 80 * cor0.col1 AS col0 FROM tab2 cor0
----
1360
2480
4720

query I rowsort
SELECT ALL - 99 + col1 * - col2 FROM tab0
----
-196
-2937
-7561

query I rowsort
SELECT ALL + col2 + + col1 * 11 * col0 AS col2 FROM tab1
----
11536
7097
912

query I rowsort
SELECT DISTINCT + - 79 * + col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-224202
-589498
-7663

query I rowsort
SELECT DISTINCT col1 + + col0 AS col2 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT + col2 * col1 + + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-5207
SELECT + ( - col0 ) + col2 DIV col0 AS col2 FROM tab1 AS cor0
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-5207
SELECT + ( - col0 ) + col2 / col0 AS col2 FROM tab1 AS cor0
----
-64
-79
15

query I rowsort
SELECT + col0 * - col0 + - col0 AS col1 FROM tab1
----
-12
-4160
-6480

query I rowsort
SELECT ALL + tab1.col0 * - tab1.col0 FROM tab1
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col0 + col2 col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - 4 * - col0 FROM tab1 AS cor0
----
12
256
320

query I rowsort
SELECT ALL - 16 * + col1 FROM tab0 AS cor0
----
-1376
-1456
-1552

query I rowsort
SELECT + - 69 + col1 FROM tab2 AS cor0
----
-10
-38
-52

query I rowsort
SELECT + - 22 * - col1 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT - - ( 40 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT ALL 88 + cor0.col1 FROM tab1 AS cor0
----
101
114
98

query I rowsort
SELECT + + cor0.col2 + ( - 60 ) AS col2 FROM tab1 AS cor0
----
-3
-6
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-5218
SELECT col1 DIV 27 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5218
SELECT col1 / 27 FROM tab2
----
0
1
2

query I rowsort
SELECT + + col2 * 24 AS col0 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT cor0.col0 * col1 - + 69 FROM tab2 AS cor0
----
1274
148
4533

query I rowsort
SELECT col2 + 74 FROM tab1 AS cor0
----
128
131
170

query I rowsort
SELECT ALL col1 * + 20 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT ALL + 70 + 77 FROM tab2 AS cor0
----
147
147
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-5224
SELECT ALL - col0 DIV - 83 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5224
SELECT ALL - col0 / - 83 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT col2 * + 70 + + col2 AS col1 FROM tab0 AS cor0
----
2343
5822
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 64 col2 FROM tab0
----
-64
-64
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-5227
SELECT col0 DIV + col2 + col1 AS col1 FROM tab1 AS cor0
----
11
13
26

skipif mysql # not compatible
query I rowsort label-5227
SELECT col0 / + col2 + col1 AS col1 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT DISTINCT cor0.col0 + 89 FROM tab0 AS cor0
----
113
124
178

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 40 * col2 col1 FROM tab1 AS cor0
----
2160
2280
3840

query I rowsort
SELECT - + col1 + + col1 * ( 63 ) FROM tab1 AS cor0
----
1612
620
806

query I rowsort
SELECT ( + col2 + col2 ) AS col2 FROM tab0
----
164
2
66

query I rowsort
SELECT ALL - 49 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to adfccb10c9468825d9961e3613140f89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5233
SELECT DISTINCT CAST( - ( col2 ) AS SIGNED ) FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5233
SELECT DISTINCT CAST ( - ( col2 ) AS INTEGER ) FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT ( - col0 ) * - col0 AS col2 FROM tab0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5235
SELECT col0 * col1 + col2 DIV 30 AS col2 FROM tab0
----
2065
3395
8101

skipif mysql # not compatible
query I rowsort label-5235
SELECT col0 * col1 + col2 / 30 AS col2 FROM tab0
----
2065
3395
8101

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col1 FROM tab1, tab2 AS cor0
----
67

query I rowsort
SELECT ALL 4 FROM tab0, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT ALL ( col2 ) * col1 + - 47 + - 10 FROM tab2 AS cor0
----
1477
589
780

query I rowsort
SELECT ALL ( cor0.col0 ) * - col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + + col2 + col2 AS col1 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 16 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5242
SELECT + 61 + - ( col0 * col1 ) + + col1 DIV col2 FROM tab0
----
-2001
-3237
-8037

skipif mysql # not compatible
query I rowsort label-5242
SELECT + 61 + - ( col0 * col1 ) + + col1 / col2 FROM tab0
----
-2001
-3237
-8037

query I rowsort
SELECT ALL col1 * ( + col1 ) * - tab2.col2 - col2 * col2 AS col2 FROM tab2
----
-12426
-26676
-91182

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 33 col1 FROM tab2
----
33

query I rowsort
SELECT 42 + ( col1 ) FROM tab2 AS cor0
----
101
59
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5246
SELECT 96 + col1 * col0 - - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5246
SELECT 96 + col1 * col0 - - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5247
SELECT DISTINCT ( + tab2.col1 ) DIV + col1 - - col2 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-5247
SELECT DISTINCT ( + tab2.col1 ) / + col1 - - col2 FROM tab2
----
27
28
39

query I rowsort
SELECT col1 + + tab0.col2 * - col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT col1 * tab1.col1 * tab1.col0 AS col2 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT - col2 + - col0 + col1 AS col1 FROM tab0 AS cor0
----
-80
29
61

query I rowsort
SELECT cor0.col0 + - col2 + - 58 FROM tab1 AS cor0
----
-109
-51
-74

query I rowsort
SELECT ALL - tab1.col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT - col1 + ( col2 ) FROM tab0
----
-53
-9
-96

query I rowsort
SELECT - col0 * col0 + ( col1 ) FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT - col0 * cor0.col2 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5256
SELECT ALL + col2 * CAST( NULL AS SIGNED ) + ( col0 ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5256
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) + ( col0 ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 + 13 FROM tab0 AS cor0
----
14
46
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5258
SELECT + + col1 / + CAST( NULL AS SIGNED ) + - cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5258
SELECT + + col1 / + CAST ( NULL AS INTEGER ) + - cor0.col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 89 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT 0 * col0 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 ) + col1 col0 FROM tab2 cor0
----
0

query I rowsort
SELECT DISTINCT - col2 + + col0 * col2 * col2 AS col0 FROM tab2 AS cor0
----
114038
5076
52702

query I rowsort
SELECT ALL + ( - col1 ) * + col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5264
SELECT ALL - 0 DIV - col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5264
SELECT ALL - 0 / - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( + 45 ) + + col0 + + 20 FROM tab1 AS cor0
----
129
145
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-5266
SELECT DISTINCT - ( cor0.col2 ) + col0 DIV 87 + - cor0.col2 FROM tab2 AS cor0
----
-52
-54
-76

skipif mysql # not compatible
query I rowsort label-5266
SELECT DISTINCT - ( cor0.col2 ) + col0 / 87 + - cor0.col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5268
SELECT col2 + + cor0.col0 DIV col1 col2 FROM tab2 AS cor0
----
27
27
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5268
SELECT col2 + + cor0.col0 / col1 col2 FROM tab2 AS cor0
----
27
27
42

query I rowsort
SELECT ALL col1 * + col0 * + col1 FROM tab1 AS cor0
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 col2 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5271
SELECT DISTINCT - col2 DIV - cor0.col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5271
SELECT DISTINCT - col2 / - cor0.col0 FROM tab0 AS cor0
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5272
SELECT col2 + col2 + CAST( col2 * col0 AS SIGNED ) FROM tab1 AS cor0
----
270
3762
7872

skipif mysql # not compatible
query I rowsort label-5272
SELECT col2 + col2 + CAST ( col2 * col0 AS INTEGER ) FROM tab1 AS cor0
----
270
3762
7872

query I rowsort
SELECT - + 10 + col1 AS col1 FROM tab0 AS cor0
----
76
81
87

query I rowsort
SELECT + + col1 * - col1 + + 12 * + 69 FROM tab1 AS cor0
----
152
659
728

query I rowsort
SELECT DISTINCT + - 71 * - col2 + 78 + col0 FROM tab2 cor0
----
2002
2855

query I rowsort
SELECT DISTINCT 28 + col1 * + col0 AS col0 FROM tab2
----
1371
245
4630

onlyif mysql # use DIV operator for integer division
query I rowsort label-5277
SELECT + col0 + + cor0.col2 DIV ( col0 ) - + col1 AS col0 FROM tab1 AS cor0
----
-5
54
68

skipif mysql # not compatible
query I rowsort label-5277
SELECT + col0 + + cor0.col2 / ( col0 ) - + col1 AS col0 FROM tab1 AS cor0
----
-5
54
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-5278
SELECT - + col2 + - col2 DIV + ( + col1 + + col1 ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5278
SELECT - + col2 + - col2 / + ( + col1 + + col1 ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL - - 24 + col0 FROM tab2 AS cor0
----
102
103
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * tab2.col1 * col1 col1 FROM tab2
----
-10982
-25947
-90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 64 + - col2 * + col2 col0 FROM tab0 AS cor0
----
-1153
-65
-6788

onlyif mysql # use DIV operator for integer division
query I rowsort label-5282
SELECT + + col2 DIV + 74 AS col1 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5282
SELECT + + col2 / + 74 AS col1 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - col1 + 54 * + col2 FROM tab0 AS cor0
----
-43
1696
4337

query I rowsort
SELECT DISTINCT + col1 * col2 + + col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL 40 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT DISTINCT 51 + - col1 * ( + col2 ) FROM tab2
----
-1483
-595
-786

query I rowsort
SELECT DISTINCT + cor0.col2 + + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5288
SELECT + + col0 DIV col1 + - col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5288
SELECT + + col0 / col1 + - col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - cor0.col1 * col0 - + col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT + col2 + col0 + + col1 AS col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL + - cor0.col1 AS col0 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col1 + + col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + + cor0.col2 * + col0 * - col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT col0 + + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col1 * + col2 - col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT ALL - + col2 + col1 AS col0 FROM tab1 cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5297
SELECT ALL - col1 * col0 + col0 DIV - col0 FROM tab0 AS cor0
----
-2065
-3396
-8100

skipif mysql # not compatible
query I rowsort label-5297
SELECT ALL - col1 * col0 + col0 / - col0 FROM tab0 AS cor0
----
-2065
-3396
-8100

query I rowsort
SELECT + col1 + col0 * col0 AS col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT - - col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + + cor0.col0 + col2 + cor0.col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT ALL col2 * + col1 + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + col0 * + col0 + + col2 + + cor0.col1 FROM tab2 AS cor0
----
107
6169
6296

query I rowsort
SELECT ALL + tab0.col2 + + col1 * + col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col1 + + tab2.col0 - col1 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL + tab1.col0 + - col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5306
SELECT ALL + col0 + col1 DIV + col0 AS col1 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-5306
SELECT ALL + col0 + col1 / + col0 AS col1 FROM tab0
----
27
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5307
SELECT - col1 DIV - tab2.col0 AS col0 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5307
SELECT - col1 / - tab2.col0 AS col0 FROM tab2
----
0
0
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5308
SELECT ALL - col1 DIV col1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5308
SELECT ALL - col1 / col1 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - + col0 - - col1 * col2 FROM tab2 cor0
----
1456
567
830

query I rowsort
SELECT - 51 AS col0 FROM tab1
----
-51
-51
-51

query I rowsort
SELECT DISTINCT col0 * col0 - + col2 * - col1 * + col0 AS col0 FROM tab0 cor0
----
4620
672039
68688

query I rowsort
SELECT DISTINCT - + col2 * col1 * - cor0.col1 + col0 + - col1 FROM tab2 AS cor0
----
11044
25923
90525

query I rowsort
SELECT ALL + cor0.col1 + cor0.col1 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to bd4e64b4654b9e3f8122f4e1bada2bd0

query I rowsort
SELECT ALL tab0.col2 + + col1 * - col0 AS col1 FROM tab0
----
-2031
-3394
-8017

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE ( - tab0.col0 ) BETWEEN ( cor0.col2 ) AND ( NULL )
----

query I rowsort
SELECT ALL - col2 * - col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT - + cor0.col0 * col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col2 * col2 - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - col0 + + col0 + + col1 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT + col0 + cor0.col1 * col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL tab0.col0 + col2 * - col0 * col0 FROM tab0
----
-1190
-18984
-649433

query I rowsort
SELECT - col2 * - col1 + col2 AS col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT DISTINCT 80 - - col2 * ( - col2 ) FROM tab0 AS cor0
----
-1009
-6644
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query III rowsort
SELECT * FROM tab1 WHERE ( col2 / col1 ) NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL + tab0.col2 + col2 * + col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT ALL - tab0.col1 + - col1 * col1 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT col1 * - col1 * col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT - col2 * - tab2.col0 + col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT DISTINCT col2 AS col0 FROM tab1 AS cor0 WHERE NULL > ( NULL )
----

query I rowsort
SELECT ALL - col0 * + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL - col0 * - col0 * col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT DISTINCT col1 * col0 * + col2 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + col1 + - col0 * + col2 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT col0 + col0 * col1 AS col1 FROM tab1
----
1120
704
81

query III rowsort
SELECT ALL * FROM tab1 cor0 WHERE NOT + col2 * + col1 IN ( col0 * col0 + col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - col0 * - col1 + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT DISTINCT col0 * col1 * tab2.col1 AS col1 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-5339
SELECT col1 + - col1 + col1 DIV - col1 AS col1 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5339
SELECT col1 + - col1 + col1 / - col1 AS col1 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT - col0 * col0 + col2 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT ALL + tab1.col2 + - col0 * col2 FROM tab1
----
-108
-3591
-7584

query III rowsort
SELECT * FROM tab1 WHERE + col1 = ( - col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( - col1 * col2 ) >= NULL
----

query I rowsort
SELECT + col0 * + col0 + - tab2.col2 * col0 AS col1 FROM tab2
----
-140
3239
4056

query I rowsort
SELECT ALL - col0 * col1 + + col0 FROM tab1
----
-576
-75
-960

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col2 / col1 + col1 >= NULL
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL IN ( + tab2.col0 - + col0 * col2 )
----

query I rowsort
SELECT DISTINCT - col2 * tab2.col2 AS col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT col1 * - col1 * + col2 AS col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT tab0.col2 * - col0 AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + + 12 + + col0 * col1 FROM tab1 AS cor0
----
1052
652
90

query I rowsort
SELECT ALL ( + col0 ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL - 89 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c36e597b7bc5727536f5bb580e6cebbc

query I rowsort
SELECT DISTINCT col0 * + col2 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col0 + cor0.col1 * 41 * - cor0.col2 FROM tab0 AS cor0
----
-116382
-306031
-4012

query I rowsort
SELECT ALL cor0.col0 + col1 * - 21 AS col0 FROM tab2 AS cor0
----
-1161
-278
-644

query I rowsort
SELECT + + cor0.col1 + 63 * + 82 AS col2 FROM tab0 AS cor0
----
5252
5257
5263

query I rowsort
SELECT + 57 + col1 AS col0 FROM tab2
----
116
74
88

query I rowsort
SELECT 16 * + col2 + 95 FROM tab0
----
111
1407
623

query I rowsort
SELECT cor0.col0 * cor0.col0 * 97 FROM tab2 cor0
----
4753
590148
605377

query I rowsort
SELECT col1 * 60 * col1 AS col0 FROM tab1
----
10140
40560
6000

query I rowsort
SELECT - 4 + 78 * col0 FROM tab2 AS cor0
----
542
6080
6158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5363
SELECT col2 DIV + tab1.col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5363
SELECT col2 / + tab1.col2 FROM tab1
----
1
1
1

query I rowsort
SELECT + col1 * 15 AS col2 FROM tab2
----
255
465
885

onlyif mysql # use DIV operator for integer division
query I rowsort label-5365
SELECT + col2 DIV 25 FROM tab0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-5365
SELECT + col2 / 25 FROM tab0
----
0
1
3

query I rowsort
SELECT + col1 - + 43 * col0 FROM tab2
----
-270
-3295
-3380

query I rowsort
SELECT + 14 * col1 * col2 AS col1 FROM tab0
----
104468
1358
39732

query I rowsort
SELECT + 59 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT col0 + 79 * col0 AS col2 FROM tab1 AS cor0
----
240
5120
6400

query I rowsort
SELECT - ( + ( - cor0.col2 ) ) * col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5371
SELECT col1 DIV - 80 + cor0.col0 + + 81 FROM tab1 AS cor0
----
145
161
84

skipif mysql # not compatible
query I rowsort label-5371
SELECT col1 / - 80 + cor0.col0 + + 81 FROM tab1 AS cor0
----
145
161
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5372
SELECT col0 * - col1 + cor0.col2 DIV ( 76 ) AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8098

skipif mysql # not compatible
query I rowsort label-5372
SELECT col0 * - col1 + cor0.col2 / ( 76 ) AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8098

query I rowsort
SELECT 84 + - cor0.col2 FROM tab1 cor0
----
-12
27
30

query I rowsort
SELECT - col1 * - col0 + col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + ( + tab1.col2 ) * col1 * - col1 AS col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT col1 + 67 - col1 FROM tab2
----
67
67
67

query I rowsort
SELECT + 74 * + ( col1 ) * col1 FROM tab1
----
12506
50024
7400

query I rowsort
SELECT tab0.col2 * col2 + col0 AS col0 FROM tab0
----
1113
36
6813

query I rowsort
SELECT - ( 58 ) + + col1 + col2 * col0 FROM tab2 AS cor0
----
162
2029
2961

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( + cor0.col0 AS REAL ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT ( 77 ) + col1 * tab2.col2 * + col2 + col1 * col2 AS col2 FROM tab2
----
23513
25271
41495

query I rowsort
SELECT ALL - 57 + + col1 + + tab2.col1 AS col2 FROM tab2
----
-23
5
61

query I rowsort
SELECT ALL ( - tab0.col2 ) + + col2 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col0 + - tab1.col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT 25 AS col0 FROM tab0, tab0 cor0
----
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-5386
SELECT + 50 DIV + col2 + col1 * col1 DIV - col0 FROM tab1 cor0
----
-1
-2
-225

skipif mysql # not compatible
query I rowsort label-5386
SELECT + 50 / + col2 + col1 * col1 / - col0 FROM tab1 cor0
----
-1
-2
-225

onlyif mysql # use DIV operator for integer division
query I rowsort label-5387
SELECT - 18 + - col1 DIV col0 + - col2 DIV + cor0.col2 AS col2 FROM tab0 AS cor0
----
-20
-21
-22

skipif mysql # not compatible
query I rowsort label-5387
SELECT - 18 + - col1 / col0 + - col2 / + cor0.col2 AS col2 FROM tab0 AS cor0
----
-20
-21
-22

query I rowsort
SELECT col0 * + col1 + + col2 + col2 AS col1 FROM tab1 AS cor0
----
1232
186
754

query I rowsort
SELECT ALL + 0 - col1 * + col1 * col2 FROM tab2 cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL 56 + col0 AS col2 FROM tab2 AS cor0
----
134
135
63

query I rowsort
SELECT - 25 + cor0.col1 FROM tab0 AS cor0
----
61
66
72

query I rowsort
SELECT + 26 AS col0 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT col1 + col2 + - cor0.col1 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5394
SELECT + col1 DIV ( + ( + col1 ) ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5394
SELECT + col1 / ( + ( + col1 ) ) FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5395
SELECT ALL col2 + col2 - col0 * tab2.col0 DIV - col1 FROM tab2
----
155
443
55

skipif mysql # not compatible
query I rowsort label-5395
SELECT ALL col2 + col2 - col0 * tab2.col0 / - col1 FROM tab2
----
155
443
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 33 - - tab0.col2 col2 FROM tab0
----
197
35
99

query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 + + col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5398
SELECT col1 + - CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5398
SELECT col1 + - CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 * + 64 FROM tab0 AS cor0
----
-2112
-5248
-64

query I rowsort
SELECT - col2 + + 57 * + col0 AS col2 FROM tab0 AS cor0
----
1335
1994
4991

onlyif mysql # use DIV operator for integer division
query I rowsort label-5401
SELECT col1 DIV ( - 44 * - col2 ) col1 FROM tab0 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5401
SELECT col1 / ( - 44 * - col2 ) col1 FROM tab0 AS cor0
----
0
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5402
SELECT 36 DIV + 10 + cor0.col2 * + col1 + + col1 FROM tab2 AS cor0
----
1596
666
871

skipif mysql # not compatible
query I rowsort label-5402
SELECT 36 / + 10 + cor0.col2 * + col1 + + col1 FROM tab2 AS cor0
----
1596
666
871

query I rowsort
SELECT DISTINCT + + ( 47 ) * + col2 FROM tab0 AS cor0
----
1551
3854
47

query I rowsort
SELECT DISTINCT - 99 * + col2 AS col2 FROM tab1 AS cor0
----
-5346
-5643
-9504

query I rowsort
SELECT + ( col0 ) + + cor0.col1 + col0 * cor0.col1 FROM tab0 AS cor0
----
2174
3527
8279

query I rowsort
SELECT + 45 + - col0 + col0 AS col0 FROM tab2 AS cor0
----
45
45
45

query I rowsort
SELECT ALL + col0 * - 98 + + col2 * col1 AS col0 FROM tab0 cor0
----
-1260
-3333
486

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 59 col0 FROM tab1 AS cor0
----
59

query I rowsort
SELECT + 8 + col2 * col2 * col0 + col0 AS col1 FROM tab0 AS cor0
----
26168
598533
78

query I rowsort
SELECT ALL - - col0 + + cor0.col2 * - cor0.col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to 9a402ad2669465fb284445c499a48f2c

query I rowsort
SELECT DISTINCT - + col2 + - cor0.col0 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 88 col2 FROM tab1, tab2 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT DISTINCT - col1 * + col0 * - col1 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT ALL + cor0.col0 + + col0 + col2 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT ALL - ( 26 ) + col1 AS col2 FROM tab0 AS cor0
----
60
65
71

query I rowsort
SELECT + - ( + 27 ) FROM tab2 AS cor0
----
-27
-27
-27

query I rowsort
SELECT DISTINCT 10 - cor0.col2 AS col1 FROM tab2 AS cor0
----
-16
-17
-28

query I rowsort
SELECT ALL 65 AS col1 FROM tab2 cor0
----
65
65
65

query I rowsort
SELECT ( + 16 ) FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT + ( + cor0.col0 ) + - col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - col2 * 37 FROM tab2 AS cor0
----
-1406
-962
-999

query I rowsort
SELECT ALL + col0 * + col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT DISTINCT - + 1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
-1

query I rowsort
SELECT + - col0 * col1 + + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - col0 * col0 + 22 FROM tab2 AS cor0
----
-27
-6062
-6219

query I rowsort
SELECT col2 * + col0 * - cor0.col2 + cor0.col0 FROM tab1 AS cor0
----
-207872
-737200
-8745

query I rowsort
SELECT + + col1 + + col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL + 0 * + col2 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col0 + - col2 * + 83 AS col2 FROM tab1 AS cor0
----
-4479
-4667
-7888

query I rowsort
SELECT DISTINCT col2 * col2 * col0 + - col2 + cor0.col1 FROM tab0 AS cor0
----
131
26189
598445

query I rowsort
SELECT col0 * col2 - 0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5433
SELECT ALL - col2 DIV + col0 + 13 * col1 AS col2 FROM tab1 AS cor0
----
130
168
320

skipif mysql # not compatible
query I rowsort label-5433
SELECT ALL - col2 / + col0 + 13 * col1 AS col2 FROM tab1 AS cor0
----
130
168
320

query I rowsort
SELECT ALL + 31 + - col0 + ( - 61 ) * + col2 FROM tab1 AS cor0
----
-3266
-3510
-5905

query I rowsort
SELECT DISTINCT - col2 + + 63 * 97 AS col2 FROM tab1 AS cor0
----
6015
6054
6057

query I rowsort
SELECT + col0 + + ( ( + col2 ) ) * + col2 AS col2 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ALL col0 * 93 - col0 AS col0 FROM tab1 AS cor0
----
276
5888
7360

onlyif mysql # use DIV operator for integer division
query I rowsort label-5438
SELECT + col2 * 80 + - col1 * cor0.col2 DIV + col2 FROM tab1 AS cor0
----
4294
4550
7667

skipif mysql # not compatible
query I rowsort label-5438
SELECT + col2 * 80 + - col1 * cor0.col2 / + col2 FROM tab1 AS cor0
----
4294
4550
7667

query I rowsort
SELECT DISTINCT + col2 * col2 + col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT 47 FROM tab1, tab1 cor0, tab2 cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT + tab2.col0 - + col0 * tab2.col1 * - 58 AS col2 FROM tab2
----
12593
266994
77973

query I rowsort
SELECT - cor0.col2 + 90 * 97 FROM tab0 AS cor0
----
8648
8697
8729

query I rowsort
SELECT col0 * + col0 + - col0 * col2 * - col0 AS col2 FROM tab2 AS cor0
----
1372
164268
243399

query I rowsort
SELECT col1 * 44 AS col1 FROM tab1 AS cor0
----
1144
440
572

onlyif mysql # use DIV operator for integer division
query I rowsort label-5445
SELECT - col1 DIV 62 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5445
SELECT - col1 / 62 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col1 * col1 col0 FROM tab2 AS cor0
----
306
3540
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 58 + col1 col2 FROM tab2
----
117
75
89

query I rowsort
SELECT ( + col0 ) + col1 AS col0 FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5449
SELECT - cor0.col1 * - CAST( - col0 AS SIGNED ) + - col1 * col1 AS col2 FROM tab2 cor0
----
-1178
-1632
-8083

skipif mysql # not compatible
query I rowsort label-5449
SELECT - cor0.col1 * - CAST ( - col0 AS INTEGER ) + - col1 * col1 AS col2 FROM tab2 cor0
----
-1178
-1632
-8083

query I rowsort
SELECT + col2 * ( + col2 ) + col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT ALL - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5452
SELECT - CAST( NULL AS SIGNED ) * - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5452
SELECT - CAST ( NULL AS INTEGER ) * - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 95 * + col0 + - col2 FROM tab2
----
-692
-7436
-7543

query I rowsort
SELECT + 85 + + col2 FROM tab0 AS cor0
----
118
167
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-5455
SELECT + CAST( col0 AS SIGNED ) DIV col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5455
SELECT + CAST ( col0 AS INTEGER ) / col1 FROM tab2
----
0
1
4

query I rowsort
SELECT DISTINCT - col2 * tab1.col2 + col2 * ( + 88 ) FROM tab1
----
-768
1767
1836

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5457
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5457
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 14 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

query I rowsort
SELECT - 59 + + col1 * - col1 AS col1 FROM tab2 AS cor0
----
-1020
-348
-3540

query I rowsort
SELECT ALL col0 * col0 * ( col0 ) FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col1 * + 6 FROM tab1 cor0
----
-18
102
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5462
SELECT - - col1 * col1 * - CAST( NULL AS SIGNED ) + - col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5462
SELECT - - col1 * col1 * - CAST ( NULL AS INTEGER ) + - col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - tab2.col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL 93 + + 73 FROM tab0
----
166
166
166

query I rowsort
SELECT DISTINCT 95 FROM tab0, tab2 AS cor0, tab2, tab0 AS cor1
----
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5466
SELECT + col0 * ( - col1 ) + + CAST( col0 AS SIGNED ) + - col1 DIV - cor0.col0 FROM tab1 AS cor0
----
-576
-67
-960

skipif mysql # not compatible
query I rowsort label-5466
SELECT + col0 * ( - col1 ) + + CAST ( col0 AS INTEGER ) + - col1 / - cor0.col0 FROM tab1 AS cor0
----
-576
-67
-960

query I rowsort
SELECT ( col0 ) + col2 + + col1 AS col2 FROM tab2 cor0
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5468
SELECT + tab2.col0 + + col2 DIV + col1 AS col1 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-5468
SELECT + tab2.col0 + + col2 / + col1 AS col1 FROM tab2
----
7
78
81

query I rowsort
SELECT + + col2 * + ( col2 * col1 ) FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - + 36 + col0 AS col1 FROM tab2 cor0
----
-29
42
43

query I rowsort
SELECT - 23 * + ( cor0.col0 ) + + col1 + - col2 * + col2 AS col1 FROM tab1 AS cor0
----
-11043
-2959
-4711

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 * 95 - - 27 AS col1 FROM tab2 cor0
----
-145703
-61343
-79488

query I rowsort
SELECT + col2 * + cor0.col2 + col0 AS col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL + 13 + + col1 * - 70 AS col0 FROM tab0 AS cor0
----
-6007
-6357
-6777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 91 col2 FROM tab0 AS cor0
----
-91
-91
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 74 + + cor0.col1 col2 FROM tab0 AS cor0
----
160
165
171

query I rowsort
SELECT ALL cor0.col1 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - col2 + cor0.col1 * col0 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT cor0.col1 * + cor0.col2 * col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - col1 + + col0 * 54 AS col0 FROM tab2 AS cor0
----
347
4153
4249

query I rowsort
SELECT col0 + ( col1 ) + col2 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT col2 * + col1 + + col1 + - col2 AS col1 FROM tab0 AS cor0
----
193
2891
7471

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5483
SELECT + tab0.col2 * - CAST( - 21 * col1 AS SIGNED ) - - 4 AS col1 FROM tab0
----
156706
2041
59602

skipif mysql # not compatible
query I rowsort label-5483
SELECT + tab0.col2 * - CAST ( - 21 * col1 AS INTEGER ) - - 4 AS col1 FROM tab0
----
156706
2041
59602

query I rowsort
SELECT ALL 25 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query I rowsort
SELECT DISTINCT + + col0 * ( ( col2 ) ) + col2 * - 97 FROM tab0 AS cor0
----
-2409
-62
-656

query I rowsort
SELECT DISTINCT 84 FROM tab2 AS cor0
----
84

query I rowsort
SELECT DISTINCT - col1 * 23 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT - ( - cor0.col2 ) + - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col1 * - col0 * col2 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT + 55 * - cor0.col1 FROM tab2 AS cor0
----
-1705
-3245
-935

query I rowsort
SELECT col2 + col2 - col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT col1 - + 39 AS col0 FROM tab0
----
47
52
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5493
SELECT col1 DIV - ( tab0.col2 * col1 ) AS col2 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5493
SELECT col1 / - ( tab0.col2 * col1 ) AS col2 FROM tab0
----
-1
0
0

query I rowsort
SELECT - ( col1 ) + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT ( 56 ) * + col0 * + 31 + + col2 FROM tab0 AS cor0
----
154586
41697
60761

query I rowsort
SELECT + ( - cor0.col2 ) * col0 - 42 * ( + col2 * + col1 ) FROM tab2 AS cor0
----
-30134
-35343
-66456

query I rowsort
SELECT DISTINCT 14 * 68 AS col0 FROM tab1 AS cor0
----
952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 37 col1 FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT + col0 + 0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT col2 + + cor0.col1 * + col1 + ( + col2 ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
3406
3646
9481

query I rowsort
SELECT - - cor0.col2 + + 11 FROM tab0 AS cor0
----
12
44
93

query I rowsort
SELECT DISTINCT col2 * + cor0.col1 * col2 + col2 AS col1 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT DISTINCT 93 * 22 AS col2 FROM tab2, tab0 AS cor0
----
2046

query I rowsort
SELECT ALL - tab0.col2 + + col1 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT 73 + - col2 + col1 AS col2 FROM tab0
----
126
169
82

query I rowsort
SELECT ( - col2 ) - + col0 * ( - col0 ) FROM tab0
----
1224
543
7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-5507
SELECT DISTINCT + tab0.col0 - col0 * col2 DIV - col0 AS col1 FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-5507
SELECT DISTINCT + tab0.col0 - col0 * col2 / - col0 AS col1 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT - ( + 71 * col1 ) + - ( col0 ) - col1 * - 83 AS col0 FROM tab1
----
309
56
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5509
SELECT ALL 0 * + 69 + - col0 * - CAST( NULL AS SIGNED ) + + col1 * col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5509
SELECT ALL 0 * + 69 + - col0 * - CAST ( NULL AS INTEGER ) + + col1 * col0 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 73 * - col2 + col0 * - col0 FROM tab0 AS cor0
----
-1152
-1935
1833

query I rowsort
SELECT ALL - ( ( col2 ) ) * - col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT ( + 45 ) * + tab0.col1 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
3870
4095
4365

query I rowsort
SELECT DISTINCT cor0.col0 * - 38 * col1 AS col0 FROM tab2 cor0
----
-174876
-51034
-8246

query I rowsort
SELECT - + col2 * + cor0.col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col0 + + ( col2 ) AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + col0 - + col1 * col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT col1 * - ( + col2 ) FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * cor0.col1 col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - cor0.col0 + + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 + ( + col2 ) AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col2 * 68 * - cor0.col2 FROM tab2 AS cor0
----
45968
49572
98192

query I rowsort
SELECT ALL + - col1 * col0 - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-5524
SELECT ALL col1 * - col1 + ( col2 ) DIV + col1 + - cor0.col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

skipif mysql # not compatible
query I rowsort label-5524
SELECT ALL col1 * - col1 + ( col2 ) / + col1 + - cor0.col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT + 4 + + col1 FROM tab2 AS cor0
----
21
35
63

query I rowsort
SELECT - - 26 * - col1 + - ( col0 ) FROM tab2 AS cor0
----
-1612
-521
-813

query I rowsort
SELECT - col2 + 5 * col2 FROM tab2
----
104
108
152

query I rowsort
SELECT DISTINCT - 57 * - 89 FROM tab1
----
5073

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5529
SELECT CAST( NULL AS SIGNED ) * tab0.col2 * col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5529
SELECT CAST ( NULL AS INTEGER ) * tab0.col2 * col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 53 + col1 AS col1 FROM tab1
----
63
66
79

query I rowsort
SELECT - 16 FROM tab0, tab2 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 99 col2 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT DISTINCT ( cor0.col0 ) - + col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT ALL + col2 + + cor0.col2 * col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT + 19 + - col2 AS col0 FROM tab2 AS cor0
----
-19
-7
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 37 + col1 * col0 col1 FROM tab2 AS cor0
----
1306
180
4565

onlyif mysql # use DIV operator for integer division
query I rowsort label-5537
SELECT ALL - - 54 + cor0.col2 DIV col2 AS col0 FROM tab0 AS cor0
----
55
55
55

skipif mysql # not compatible
query I rowsort label-5537
SELECT ALL - - 54 + cor0.col2 / col2 AS col0 FROM tab0 AS cor0
----
55
55
55

query I rowsort
SELECT ALL - col2 * col2 - ( col2 ) * - col0 AS col0 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT DISTINCT + + cor0.col0 * + col0 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5540
SELECT col2 + - cor0.col0 * col1 DIV cor0.col2 FROM tab0 AS cor0
----
-16
-29
-3394

skipif mysql # not compatible
query I rowsort label-5540
SELECT col2 + - cor0.col0 * col1 / cor0.col2 FROM tab0 AS cor0
----
-16
-29
-3394

query I rowsort
SELECT ALL + col1 + + cor0.col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT - 57 AS col1 FROM tab1 AS cor0
----
-57
-57
-57

query I rowsort
SELECT - col2 * + 6 + + col0 AS col1 FROM tab2
----
-149
-155
-78

query I rowsort
SELECT ALL - col1 + - 30 FROM tab2
----
-47
-61
-89

query I rowsort
SELECT ALL - cor0.col1 * col0 * - 72 FROM tab0 AS cor0
----
148608
244440
583128

query I rowsort
SELECT DISTINCT - - col2 * ( col2 ) + - col0 FROM tab1 cor0
----
2913
3185
9136

query I rowsort
SELECT + col1 * 84 - - 47 FROM tab2 cor0
----
1475
2651
5003

query I rowsort
SELECT + col2 - + col1 * col0 AS col0 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT col1 * col1 * 74 + + col1 * - ( cor0.col1 + col0 ) * - cor0.col1 FROM tab1 AS cor0
----
14800
28223
69628

query I rowsort
SELECT DISTINCT + col0 * + 15 FROM tab0 AS cor0
----
1335
360
525

query I rowsort
SELECT - + 98 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT ALL + col2 * - ( col0 ) AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + col0 * 98 - - col2 FROM tab2 AS cor0
----
-659
-7618
-7704

query I rowsort
SELECT ALL + col0 + + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - + col1 + col1 * col0 + + cor0.col2 AS col1 FROM tab2 cor0
----
1364
213
4569

query I rowsort
SELECT ALL + col2 * - col2 - - col1 * - col1 AS col2 FROM tab1 AS cor0
----
-3349
-3592
-9385

query I rowsort
SELECT + col0 + + cor0.col1 * + cor0.col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT col0 + + col0 * col2 + - col2 AS col0 FROM tab0 AS cor0
----
69
7305
783

query I rowsort
SELECT ALL - ( + 61 ) FROM tab2 AS cor0
----
-61
-61
-61

query I rowsort
SELECT - ( 97 ) AS col2 FROM tab1
----
-97
-97
-97

query I rowsort
SELECT 4 * - 64 FROM tab2
----
-256
-256
-256

query I rowsort
SELECT DISTINCT + + 20 * col1 + col1 AS col2 FROM tab0 AS cor0
----
1806
1911
2037

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5563
SELECT CAST( NULL AS SIGNED ) * col1 + + col1 * - col1 * - ( col2 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5563
SELECT CAST ( NULL AS INTEGER ) * col1 + + col1 * - col1 * - ( col2 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + col1 * + col1 + - col2 + col2 * col2 AS col1 FROM tab0 AS cor0
----
245124
685684
9409

query I rowsort
SELECT col0 + + col1 + + 65 * - col1 FROM tab2
----
-1009
-1977
-3698

query I rowsort
SELECT ALL + 8 * - col0 AS col2 FROM tab1 AS cor0
----
-24
-512
-640

query I rowsort
SELECT ALL - - cor0.col2 + + 35 FROM tab1, tab0 AS cor0
----
9 values hashing to e6451c2de0e4dbbce4132229b3476884

query I rowsort
SELECT - 96 * cor0.col2 + - col0 FROM tab2 AS cor0
----
-2574
-2599
-3727

onlyif mysql # use DIV operator for integer division
query I rowsort label-5569
SELECT DISTINCT - 49 + 73 * col1 DIV - col0 AS col2 FROM tab2 cor0
----
-104
-372
-64

skipif mysql # not compatible
query I rowsort label-5569
SELECT DISTINCT - 49 + 73 * col1 / - col0 AS col2 FROM tab2 cor0
----
-104
-372
-64

query I rowsort
SELECT + + col1 + - ( - col2 ) + 75 * 13 FROM tab1 AS cor0
----
1042
1055
1084

query I rowsort
SELECT DISTINCT - ( 40 ) * - col0 + - col1 * + col0 FROM tab0 AS cor0
----
-1104
-1995
-4539

query I rowsort
SELECT - - cor0.col1 + cor0.col2 + cor0.col0 FROM tab0 AS cor0
----
133
143
262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 72 ) + col1 col1 FROM tab1 AS cor0
----
82
85
98

query I rowsort
SELECT col1 + 57 FROM tab0 AS cor0
----
143
148
154

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5575
SELECT col2 + - col1 * CAST( - col0 AS SIGNED ) * col1 + cor0.col0 FROM tab0 AS cor0
----
177561
329351
737180

skipif mysql # not compatible
query I rowsort label-5575
SELECT col2 + - col1 * CAST ( - col0 AS INTEGER ) * col1 + cor0.col0 FROM tab0 AS cor0
----
177561
329351
737180

query I rowsort
SELECT + 72 + + col1 FROM tab1 AS cor0
----
82
85
98

query I rowsort
SELECT + col1 + col0 * - col0 AS col2 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT + cor0.col1 * col2 * + 6 + col1 * col0 * - col2 AS col0 FROM tab1 AS cor0
----
-33060
-92352
4212

query I rowsort
SELECT - 68 + col2 + col1 * 2 AS col2 FROM tab1
----
38
54
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5580
SELECT + CAST( NULL AS DECIMAL ) / col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5580
SELECT + CAST ( NULL AS REAL ) / col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - ( - col0 ) col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col1 * 62 * - col0 FROM tab0 AS cor0
----
-127968
-210490
-502138

query I rowsort
SELECT + col1 * + col1 * + col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT ALL - col1 * 22 AS col0 FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT ALL + col2 * + col0 + - col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT 54 - col2 * - col1 FROM tab0 AS cor0
----
151
2892
7516

query I rowsort
SELECT + col1 * - col2 + ( col1 ) * - 58 * - col1 AS col1 FROM tab2
----
16116
200364
54901

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5588
SELECT - CAST( - cor0.col2 AS SIGNED ) col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5588
SELECT - CAST ( - cor0.col2 AS INTEGER ) col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 - col1 col2 FROM tab1 cor0
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 - cor0.col2 col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5591
SELECT + + col1 DIV + col0 AS col2 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5591
SELECT + + col1 / + col0 AS col2 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT + + 74 + col1 AS col1 FROM tab0 AS cor0
----
160
165
171

query I rowsort
SELECT DISTINCT ( - 31 ) AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-31

query I rowsort
SELECT ALL col1 * col1 - + col2 * 8 FROM tab2
----
-15
3273
745

query I rowsort
SELECT DISTINCT - col1 + + ( - 88 ) FROM tab2
----
-105
-119
-147

query I rowsort
SELECT col1 * + 92 FROM tab1
----
1196
2392
920

query I rowsort
SELECT DISTINCT + col1 * + col2 + cor0.col2 AS col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-5598
SELECT DISTINCT - col0 DIV 14 AS col2 FROM tab1 AS cor0
----
-4
-5
0

skipif mysql # not compatible
query I rowsort label-5598
SELECT DISTINCT - col0 / 14 AS col2 FROM tab1 AS cor0
----
-4
-5
0

query I rowsort
SELECT ALL + 80 * col1 FROM tab0
----
6880
7280
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5600
SELECT ALL ( col2 + col1 ) * ( - ( + col2 ) + col0 ) DIV - col0 AS col1 FROM tab2
----
-28
-56
165

skipif mysql # not compatible
query I rowsort label-5600
SELECT ALL ( col2 + col1 ) * ( - ( + col2 ) + col0 ) / - col0 AS col1 FROM tab2
----
-28
-56
165

onlyif mysql # use DIV operator for integer division
query I rowsort label-5601
SELECT - + col1 DIV - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5601
SELECT - + col1 / - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 55 + - col2 * cor0.col2 * - col1 AS col0 FROM tab2 AS cor0
----
22544
24493
39829

query I rowsort
SELECT + + 14 AS col2 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT + - col1 * - col1 * col1 AS col0 FROM tab1 AS cor0
----
1000
17576
2197

query I rowsort
SELECT ALL ( col0 + + col0 ) FROM tab1
----
128
160
6

query I rowsort
SELECT ALL + - 6 * + col0 AS col2 FROM tab2 AS cor0
----
-42
-468
-474

query I rowsort
SELECT ALL + 97 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT + - 49 * col2 FROM tab2 AS cor0
----
-1274
-1323
-1862

query I rowsort
SELECT + ( + col2 * col0 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL + + col0 * col2 AS col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5611
SELECT ALL + col0 + col1 * col2 DIV cor0.col1 + col1 FROM tab1 cor0
----
131
189
83

skipif mysql # not compatible
query I rowsort label-5611
SELECT ALL + col0 + col1 * col2 / cor0.col1 + col1 FROM tab1 cor0
----
131
189
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5612
SELECT + col2 + - col0 * 72 DIV + col0 FROM tab1 AS cor0
----
-15
-18
24

skipif mysql # not compatible
query I rowsort label-5612
SELECT + col2 + - col0 * 72 / + col0 FROM tab1 AS cor0
----
-15
-18
24

query I rowsort
SELECT - - 15 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 43 * - cor0.col1 + - cor0.col0 col2 FROM tab2 cor0
----
-1340
-2615
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 68 * col2 col1 FROM tab1 AS cor0
----
3672
3876
6528

query I rowsort
SELECT DISTINCT 20 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5617
SELECT DISTINCT ( - col2 ) + + col0 DIV 24 + col0 * ( - col2 + cor0.col2 ) * col2 AS col2 FROM tab0 AS cor0
----
-32
-79
0

skipif mysql # not compatible
query I rowsort label-5617
SELECT DISTINCT ( - col2 ) + + col0 / 24 + col0 * ( - col2 + cor0.col2 ) * col2 AS col2 FROM tab0 AS cor0
----
-32
-79
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5618
SELECT col0 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5618
SELECT col0 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + tab0.col1 * col0 + + 36 * col2 * - col2 FROM tab0
----
-233965
-37140
3359

query I rowsort
SELECT - - cor0.col0 * col1 - 84 AS col0 FROM tab1 AS cor0
----
-6
556
956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5621
SELECT ALL + col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5621
SELECT ALL + col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 - 86 AS col0 FROM tab0 AS cor0
----
-172
-177
-183

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + + col2 * - ( - 92 ) FROM tab2 AS cor0
----
2392
2484
3496

query I rowsort
SELECT + 70 + + col1 FROM tab1
----
80
83
96

query I rowsort
SELECT 70 - col1 * col1 AS col1 FROM tab0
----
-7326
-8211
-9339

query I rowsort
SELECT ALL col0 + - cor0.col2 + col1 * + col2 AS col2 FROM tab0 AS cor0
----
131
2829
7469

query I rowsort
SELECT DISTINCT - col2 + 86 FROM tab2 cor0
----
48
59
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5629
SELECT - CAST( 43 AS SIGNED ) FROM tab0 AS cor0
----
-43
-43
-43

skipif mysql # not compatible
query I rowsort label-5629
SELECT - CAST ( 43 AS INTEGER ) FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT - + 77 + + col1 FROM tab0 AS cor0
----
14
20
9

query I rowsort
SELECT col2 * - col2 + col0 * col2 AS col2 FROM tab2 AS cor0
----
-540
1352
1558

query I rowsort
SELECT ALL - + 38 + - col0 AS col2 FROM tab0 AS cor0
----
-127
-62
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-5633
SELECT - + col2 DIV - 85 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5633
SELECT - + col2 / - 85 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - 95 * + 55 + + cor0.col1 FROM tab0 AS cor0
----
-5128
-5134
-5139

query I rowsort
SELECT DISTINCT - col2 * - ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 1 + + 75 col1 FROM tab2 cor0
----
74

query I rowsort
SELECT ALL + + cor0.col1 + + col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - col2 * - ( col0 ) * col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT col1 * 6 AS col2 FROM tab0
----
516
546
582

query I rowsort
SELECT cor0.col2 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT col0 * - 12 AS col0 FROM tab0
----
-1068
-288
-420

query I rowsort
SELECT + tab2.col2 * 19 FROM tab2
----
494
513
722

query I rowsort
SELECT DISTINCT 31 AS col1 FROM tab0, tab0 AS cor0
----
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) * + col1 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5645
SELECT - + col1 + col2 DIV - col1 FROM tab2 AS cor0
----
-19
-31
-59

skipif mysql # not compatible
query I rowsort label-5645
SELECT - + col1 + col2 / - col1 FROM tab2 AS cor0
----
-19
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + - col0 + col1 col1 FROM tab1 AS cor0
----
29
3
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-5647
SELECT - col0 * cor0.col1 + col1 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1342
-216
-4601

skipif mysql # not compatible
query I rowsort label-5647
SELECT - col0 * cor0.col1 + col1 / + col1 AS col0 FROM tab2 AS cor0
----
-1342
-216
-4601

query I rowsort
SELECT ALL - col1 * - cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT ALL - - cor0.col2 * - col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col0 + - col2 AS col0 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5651
SELECT ALL 81 * - col1 + col2 DIV - col1 FROM tab2
----
-1379
-2511
-4779

skipif mysql # not compatible
query I rowsort label-5651
SELECT ALL 81 * - col1 + col2 / - col1 FROM tab2
----
-1379
-2511
-4779

query I rowsort
SELECT - col0 + - col0 + col2 * + col0 FROM tab1 AS cor0
----
156
3520
7520

query I rowsort
SELECT ALL - col1 + col2 * - col0 * col2 + col0 AS col0 FROM tab1
----
-207882
-737213
-8771

query I rowsort
SELECT + - col1 + - col2 * cor0.col0 AS col2 FROM tab0 cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-5655
SELECT ALL + tab0.col0 DIV tab0.col2 + col1 + col1 * + col0 FROM tab0
----
2150
3527
8191

skipif mysql # not compatible
query I rowsort label-5655
SELECT ALL + tab0.col0 / tab0.col2 + col1 + col1 * + col0 FROM tab0
----
2150
3527
8191

query I rowsort
SELECT + col1 * + col2 + - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - col1 * + col0 + col0 + + col1 FROM tab2 AS cor0
----
-1247
-179
-4465

query I rowsort
SELECT - - col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - ( col0 ) + + col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - col1 * + col1 - - col2 * col1 * col0 FROM tab1
----
3536
36380
99671

query I rowsort
SELECT + tab0.col0 + + 38 AS col2 FROM tab0
----
127
62
73

query I rowsort
SELECT DISTINCT - + col0 * - col2 + col0 + col2 AS col0 FROM tab2 cor0
----
2132
223
3119

query I rowsort
SELECT DISTINCT 3 + - col1 + + col0 AS col2 FROM tab1 AS cor0
----
-20
57
70

query I rowsort
SELECT + ( - 33 ) + col1 FROM tab0
----
53
58
64

query I rowsort
SELECT - col0 * - col1 + col2 AS col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL - ( 69 ) AS col1 FROM tab2
----
-69
-69
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-5667
SELECT + 44 DIV + tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5667
SELECT + 44 / + tab0.col1 FROM tab0
----
0
0
0

query I rowsort
SELECT cor0.col0 + - col1 AS col1 FROM tab2 cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5669
SELECT ALL - - col2 DIV col2 + col1 + - col0 DIV + col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5669
SELECT ALL - - col2 / col2 + col1 + - col0 / + col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + - 12 + + col0 * + col2 + - col2 FROM tab2 AS cor0
----
150
1990
2952

query I rowsort
SELECT ALL - 38 * + col2 AS col2 FROM tab1 AS cor0
----
-2052
-2166
-3648

query I rowsort
SELECT DISTINCT + 8 + col2 * col1 AS col0 FROM tab0 cor0
----
105
2846
7470

query I rowsort
SELECT DISTINCT col2 - + col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - 61 * - col0 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT + - 32 FROM tab2 AS cor0
----
-32
-32
-32

query I rowsort
SELECT ALL - - col2 * + col2 + col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT + - col1 * cor0.col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT 5 AS col0 FROM tab0 cor0
----
5

query I rowsort
SELECT ALL - - ( - col2 ) * - col0 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + + 52 FROM tab1 AS cor0
----
52
52
52

query I rowsort
SELECT ALL - - col0 * - cor0.col0 + col0 AS col2 FROM tab2 AS cor0
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-5682
SELECT DISTINCT col1 + + col1 DIV col1 AS col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-5682
SELECT DISTINCT col1 + + col1 / col1 AS col1 FROM tab0
----
87
92
98

query I rowsort
SELECT col2 AS col1 FROM tab0 WHERE - col0 IN ( + col0 )
----

query I rowsort
SELECT + tab1.col2 + - tab1.col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT col2 * + col2 + tab2.col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL col1 * tab1.col1 + col2 FROM tab1
----
157
265
730

query I rowsort
SELECT tab2.col0 AS col1 FROM tab2 WHERE NOT col2 NOT IN ( + col1 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL NOT IN ( col0 + - tab2.col0 )
----

query I rowsort
SELECT DISTINCT col2 + + col2 + + col2 AS col0 FROM tab2
----
114
78
81

query I rowsort
SELECT DISTINCT - col1 * col2 + + tab0.col1 + col2 FROM tab0
----
-2719
-7289
1

query I rowsort
SELECT col1 FROM tab2 WHERE + col1 - col0 > NULL
----

query I rowsort
SELECT col2 * - col0 + + col1 + - col0 * - col1 AS col2 FROM tab1
----
-2998
-58
-6627

onlyif mysql # use DIV operator for integer division
query I rowsort label-5693
SELECT ALL - col1 DIV + tab0.col0 AS col2 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-5693
SELECT ALL - col1 / + tab0.col0 AS col2 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT - col2 + col0 * - col1 + col2 * - col0 AS col1 FROM tab2 WHERE NOT NULL IN ( - tab2.col0 * - col1 * - col1 )
----

query I rowsort
SELECT - col1 * col1 * - tab0.col0 FROM tab0
----
177504
329315
737009

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col2 + + col2 IN ( col0 * col2 * + col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5697
SELECT - col2 * col0 DIV col2 + + tab0.col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5697
SELECT - col2 * col0 / col2 + + tab0.col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5698
SELECT col0 - - col1 DIV col0 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-5698
SELECT col0 - - col1 / col0 FROM tab2
----
11
78
79

query I rowsort
SELECT cor0.col0 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE ( NULL ) BETWEEN NULL AND - cor0.col1 OR NULL >= ( - col1 )
----

query I rowsort
SELECT ALL + cor0.col2 + col2 * - col2 AS col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab1 AS cor0 WHERE NOT ( NULL ) <= col0 / col0 OR NOT NULL <= col2
----

query I rowsort
SELECT DISTINCT + col1 + - cor0.col2 + + col0 FROM tab2 AS cor0 WHERE NOT - col1 <> - col0
----

query I rowsort
SELECT col0 * + col0 + + col1 * col0 AS col2 FROM tab0
----
16020
2640
4620

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT col1 + - col2 + - col2 NOT IN ( + cor0.col0 * col2 / - col0 )
----

query I rowsort
SELECT 40 + col0 * + col1 AS col1 FROM tab1 AS cor0
----
1080
118
680

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) * col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL col0 * col1 * col2 FROM tab1 cor0
----
36480
4212
99840

query I rowsort
SELECT + 84 + 75 FROM tab0 AS cor0
----
159
159
159

query I rowsort
SELECT ALL - 28 + 74 AS col0 FROM tab2 AS cor0
----
46
46
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5711
SELECT - CAST( NULL AS SIGNED ) + - cor0.col2 / + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5711
SELECT - CAST ( NULL AS INTEGER ) + - cor0.col2 / + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5712
SELECT DISTINCT - CAST( - col0 + + col1 AS SIGNED ) * + col2 FROM tab1
----
-1242
3078
6432

skipif mysql # not compatible
query I rowsort label-5712
SELECT DISTINCT - CAST ( - col0 + + col1 AS INTEGER ) * + col2 FROM tab1
----
-1242
3078
6432

query I rowsort
SELECT ALL - 29 * col2 + ( + 1 ) FROM tab1 AS cor0
----
-1565
-1652
-2783

query I rowsort
SELECT + - col2 + col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + tab1.col1 AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

onlyif mysql # use DIV operator for integer division
query I rowsort label-5716
SELECT ALL + col0 DIV 92 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5716
SELECT ALL + col0 / 92 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL 36 AS col1 FROM tab1
----
36
36
36

query I rowsort
SELECT cor0.col2 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + col0 - + col1 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col2 * + ( - col0 ) - + col1 col0 FROM tab1 AS cor0
----
-134
-3601
-7597

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5721
SELECT DISTINCT - - col0 * CAST( NULL AS SIGNED ) + 51 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5721
SELECT DISTINCT - - col0 * CAST ( NULL AS INTEGER ) + 51 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - col0 * 80 * 64 + col0 AS col0 FROM tab1 AS cor0
----
-15357
-327616
-409520

query I rowsort
SELECT DISTINCT - 80 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5724
SELECT ALL + col2 DIV + 69 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5724
SELECT ALL + col2 / + 69 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT col2 * ( - col2 ) + + col0 AS col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 cor1, tab1 AS cor2
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT + col0 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + - cor0.col1 * - col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - + col1 * + col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 36 col1 FROM tab0 AS cor0
----
36
36
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) * - cor0.col0 + col2 * col0 col1 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT ALL 71 * - col2 FROM tab1 cor0
----
-3834
-4047
-6816

query I rowsort
SELECT ALL - col0 - 4 * col2 * cor0.col2 FROM tab0 AS cor0
----
-26985
-39
-4380

query I rowsort
SELECT + col2 * + 45 AS col1 FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT DISTINCT + cor0.col2 * col1 + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - - col2 * - 67 FROM tab0 AS cor0
----
-2211
-5494
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-5738
SELECT DISTINCT + cor0.col2 * col2 DIV - col1 FROM tab1 AS cor0
----
-112
-324
-708

skipif mysql # not compatible
query I rowsort label-5738
SELECT DISTINCT + cor0.col2 * col2 / - col1 FROM tab1 AS cor0
----
-112
-324
-708

onlyif mysql # use DIV operator for integer division
query I rowsort label-5739
SELECT DISTINCT + col1 - - col1 DIV col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-5739
SELECT DISTINCT + col1 - - col1 / col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT - + 87 FROM tab0, tab1 AS cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT ALL - col0 + col2 + - tab2.col2 AS col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL + + 73 + + col2 * - 35 FROM tab2 AS cor0
----
-1257
-837
-872

query I rowsort
SELECT DISTINCT + 73 * + col1 FROM tab2 AS cor0
----
1241
2263
4307

onlyif mysql # use DIV operator for integer division
query I rowsort label-5744
SELECT - + cor0.col0 + - col2 * col1 + - 19 DIV - col1 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif mysql # not compatible
query I rowsort label-5744
SELECT - + cor0.col0 + - col2 * col1 + - 19 / - col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT - col2 + - col0 * + 54 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-4297
-4321
-436

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col2 + + col2 * CAST ( - col1 AS REAL ) col0 FROM tab0 cor0
----
-2871
-7544
-98

query I rowsort
SELECT + + col1 + - cor0.col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT ALL + + col2 * 2 + col1 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT DISTINCT + cor0.col1 - - col2 * + col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - - col1 + 77 FROM tab0 AS cor0
----
163
168
174

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 - 89 col0 FROM tab0 cor0
----
-175
-180
-186

query I rowsort
SELECT ALL - col1 + + col2 * col2 * col1 AS col0 FROM tab2 AS cor0
----
22568
24531
39825

query I rowsort
SELECT - + col1 + col0 * col2 + col1 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + - col1 + + cor0.col1 * + col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT - col0 * + 51 - col0 * + col0 * + col2 FROM tab0 cor0
----
-20232
-3010
-654061

query I rowsort
SELECT DISTINCT + col2 + - 39 AS col2 FROM tab0 AS cor0
----
-38
-6
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5757
SELECT 15 + col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5757
SELECT 15 + col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 + 28 FROM tab0
----
63
7326
820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5759
SELECT - ( - col2 ) * CAST( - 12 AS SIGNED ) + col1 * + col0 FROM tab1
----
-112
-44
-570

skipif mysql # not compatible
query I rowsort label-5759
SELECT - ( - col2 ) * CAST ( - 12 AS INTEGER ) + col1 * + col0 FROM tab1
----
-112
-44
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col2 * 10 ) + 39 + + col1 * col0 col0 FROM tab1
----
-423
109
119

query I rowsort
SELECT ALL ( col0 ) * tab1.col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT + col1 * + col1 * ( - col0 ) AS col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-5763
SELECT ALL col2 DIV + col0 + + col1 FROM tab0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-5763
SELECT ALL col2 / + col0 + + col1 FROM tab0
----
87
91
97

query I rowsort
SELECT ALL col1 * col0 * 96 FROM tab1 cor0
----
61440
7488
99840

query I rowsort
SELECT DISTINCT + 77 * col0 AS col0 FROM tab1 AS cor0
----
231
4928
6160

onlyif mysql # use DIV operator for integer division
query I rowsort label-5766
SELECT + + 20 DIV - cor0.col0 col2 FROM tab2 cor0
----
-2
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5766
SELECT + + 20 / - cor0.col0 col2 FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT DISTINCT + - 17 * - cor0.col1 FROM tab1 AS cor0
----
170
221
442

onlyif mysql # use DIV operator for integer division
query I rowsort label-5768
SELECT ALL - + 78 DIV - col0 AS col2 FROM tab1 cor0
----
0
1
26

skipif mysql # not compatible
query I rowsort label-5768
SELECT ALL - + 78 / - col0 AS col2 FROM tab1 cor0
----
0
1
26

query I rowsort
SELECT ALL - 74 * col2 FROM tab2 AS cor0
----
-1924
-1998
-2812

query I rowsort
SELECT col0 * + ( + 65 ) + col2 AS col1 FROM tab2 AS cor0
----
482
5096
5173

query I rowsort
SELECT col0 + ( + col0 + - col1 ) FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT col2 + col0 + + 37 AS col2 FROM tab2 AS cor0
----
141
154
71

query I rowsort
SELECT DISTINCT + col2 * + 87 + col1 + col0 AS col0 FROM tab1 AS cor0
----
4727
5033
8445

onlyif mysql # use DIV operator for integer division
query I rowsort label-5774
SELECT + col2 + col0 DIV col1 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5774
SELECT + col2 + col0 / col1 AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT tab1.col0 * col0 + + 44 + col2 FROM tab1
----
107
4197
6540

query I rowsort
SELECT + ( - col1 ) * + col2 * col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT ( col1 ) * - col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5778
SELECT ALL - col1 * + col2 / + col0 + CAST( NULL AS SIGNED ) + + cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5778
SELECT ALL - col1 * + col2 / + col0 + CAST ( NULL AS INTEGER ) + + cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5780
SELECT DISTINCT CAST( + 83 AS SIGNED ) FROM tab1 cor0
----
83

skipif mysql # not compatible
query I rowsort label-5780
SELECT DISTINCT CAST ( + 83 AS INTEGER ) FROM tab1 cor0
----
83

query I rowsort
SELECT ALL + 45 + col0 - col0 * + 23 FROM tab1 AS cor0
----
-1363
-1715
-21

query I rowsort
SELECT DISTINCT + col1 * - ( cor0.col0 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - - 77 * - col1 AS col1 FROM tab0 cor0
----
-6622
-7007
-7469

query I rowsort
SELECT + ( + col0 ) * col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col2 + + ( + col1 ) AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL - tab0.col2 + + col0 * 94 AS col0 FROM tab0
----
2223
3289
8284

query I rowsort
SELECT ALL tab1.col0 + - tab1.col0 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + ( + 81 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT - col0 + col2 AS col2 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + ( + col2 ) + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-5791
SELECT + cor0.col2 + + 19 DIV - cor0.col0 AS col2 FROM tab1 AS cor0
----
48
57
96

skipif mysql # not compatible
query I rowsort label-5791
SELECT + cor0.col2 + + 19 / - cor0.col0 AS col2 FROM tab1 AS cor0
----
48
57
96

query I rowsort
SELECT - 84 AS col0 FROM tab2 cor0
----
-84
-84
-84

query I rowsort
SELECT 27 * - col2 - col2 * + tab1.col1 FROM tab1
----
-2109
-2862
-3840

query I rowsort
SELECT DISTINCT 44 FROM tab2, tab0 AS cor0
----
44

query I rowsort
SELECT DISTINCT + - cor1.col1 * - 7 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
182
70
91

query I rowsort
SELECT 99 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + 91 AS col0 FROM tab0, tab1, tab1 AS cor0
----
91

query I rowsort
SELECT - 71 FROM tab0
----
-71
-71
-71

query I rowsort
SELECT col0 + + ( col2 * - col0 ) FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + + cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5802
SELECT ALL - + col2 * - CAST( col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-5802
SELECT ALL - + col2 * - CAST ( col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5803
SELECT DISTINCT + + col1 + ( ( col2 ) ) * ( col2 ) DIV cor0.col0 AS col2 FROM tab0 cor0
----
131
166
97

skipif mysql # not compatible
query I rowsort label-5803
SELECT DISTINCT + + col1 + ( ( col2 ) ) * ( col2 ) / cor0.col0 AS col2 FROM tab0 cor0
----
131
166
97

query I rowsort
SELECT + cor1.col0 FROM tab2 cor0 CROSS JOIN tab2, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT col1 + 18 AS col0 FROM tab0 AS cor0
----
104
109
115

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 95 col1 FROM tab1
----
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5807
SELECT DISTINCT col1 DIV cor0.col0 + col0 + + cor0.col0 FROM tab1 AS cor0
----
128
14
160

skipif mysql # not compatible
query I rowsort label-5807
SELECT DISTINCT col1 / cor0.col0 + col0 + + cor0.col0 FROM tab1 AS cor0
----
128
14
160

query I rowsort
SELECT col2 * + 87 AS col0 FROM tab0 AS cor0
----
2871
7134
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5809
SELECT + col2 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5809
SELECT + col2 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * 76 + col0 FROM tab1 AS cor0
----
-4101
-4268
-7216

query I rowsort
SELECT 86 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5812
SELECT - col2 + 64 DIV - col1 FROM tab1 AS cor0
----
-100
-56
-63

skipif mysql # not compatible
query I rowsort label-5812
SELECT - col2 + 64 / - col1 FROM tab1 AS cor0
----
-100
-56
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-5813
SELECT ALL + col0 DIV 21 + - 6 AS col0 FROM tab1 AS cor0
----
-3
-3
-6

skipif mysql # not compatible
query I rowsort label-5813
SELECT ALL + col0 / 21 + - 6 AS col0 FROM tab1 AS cor0
----
-3
-3
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5814
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) + - col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5814
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) + - col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 + - col0 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 + col1 * col2 * col0 col0 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT ALL - + col1 * 61 * col0 + + col1 AS col0 FROM tab1 AS cor0
----
-39030
-4732
-63427

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5818
SELECT DISTINCT CAST( - 87 AS SIGNED ) * - col2 + col1 AS col0 FROM tab2 AS cor0
----
2321
2380
3323

skipif mysql # not compatible
query I rowsort label-5818
SELECT DISTINCT CAST ( - 87 AS INTEGER ) * - col2 + col1 AS col0 FROM tab2 AS cor0
----
2321
2380
3323

query I rowsort
SELECT DISTINCT - + cor0.col0 * 75 AS col0 FROM tab2 AS cor0
----
-525
-5850
-5925

query I rowsort
SELECT + - ( - col2 ) + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5821
SELECT ALL CAST( NULL AS SIGNED ) * - cor0.col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5821
SELECT ALL CAST ( NULL AS INTEGER ) * - cor0.col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 25 + - col0 AS col1 FROM tab2 AS cor0
----
-103
-104
-32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 * 77 col1 FROM tab0
----
44352
609917
94325

query I rowsort
SELECT DISTINCT + cor1.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5825
SELECT - + 37 + + col1 + 25 DIV col0 FROM tab1 AS cor0
----
-24
-27
-3

skipif mysql # not compatible
query I rowsort label-5825
SELECT - + 37 + + col1 + 25 / col0 FROM tab1 AS cor0
----
-24
-27
-3

query I rowsort
SELECT DISTINCT - col2 * col2 + 11 FROM tab1 AS cor0
----
-2905
-3238
-9205

query I rowsort
SELECT - - 84 * col0 - col2 FROM tab0 AS cor0
----
1983
2939
7394

query I rowsort
SELECT - col0 * - col1 + - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col0 * - col1 + - tab2.col1 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT ALL 24 + col0 AS col0 FROM tab2 AS cor0
----
102
103
31

query I rowsort
SELECT col0 * + col0 + - col0 FROM tab1
----
4032
6
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 col2 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5833
SELECT CAST( NULL AS SIGNED ) FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5833
SELECT CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT col2 * col0 * ( + col1 ) AS col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL 64 + 93 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e82f5eabd63a750c55c098fa7763bb43

query I rowsort
SELECT DISTINCT + 65 FROM tab0, tab2, tab1 AS cor0
----
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5837
SELECT ALL - 42 + - col1 DIV + 86 + + col2 FROM tab0
----
-10
-42
39

skipif mysql # not compatible
query I rowsort label-5837
SELECT ALL - 42 + - col1 / + 86 + + col2 FROM tab0
----
-10
-42
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5838
SELECT + 87 / - tab2.col1 + + CAST( NULL AS SIGNED ) + ( + col2 ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5838
SELECT + 87 / - tab2.col1 + + CAST ( NULL AS INTEGER ) + ( + col2 ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5839
SELECT ALL 18 * col1 + CAST( col0 AS SIGNED ) AS col2 FROM tab0
----
1572
1727
1781

skipif mysql # not compatible
query I rowsort label-5839
SELECT ALL 18 * col1 + CAST ( col0 AS INTEGER ) AS col2 FROM tab0
----
1572
1727
1781

query I rowsort
SELECT + - col0 * col0 + col1 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + col2 + + 44 FROM tab0 AS cor0
----
126
45
77

query I rowsort
SELECT ALL 98 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT DISTINCT col0 * tab2.col0 + - ( col0 ) * - col0 FROM tab2
----
12168
12482
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5844
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5844
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col0 + - 68 + - col0 AS col2 FROM tab2
----
-68
-68
-68

query I rowsort
SELECT + 5 AS col2 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT ALL - col2 * + col1 + - col1 AS col2 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT - cor1.col0 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT + col2 * col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL - + col0 - cor0.col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT cor0.col2 + + col2 + col1 * col2 FROM tab0 AS cor0
----
2904
7626
99

query I rowsort
SELECT + + cor0.col0 + col1 * col0 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + col1 + col1 + - col0 * + col0 FROM tab1 cor0
----
-4076
-6374
43

query I rowsort
SELECT + col0 * + 89 + col2 FROM tab1 AS cor0
----
321
5753
7216

query I rowsort
SELECT 10 + - 49 AS col0 FROM tab2
----
-39
-39
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5856
SELECT DISTINCT - CAST( NULL AS DECIMAL ) - + col2 AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5856
SELECT DISTINCT - CAST ( NULL AS REAL ) - + col2 AS col2 FROM tab0
----
NULL

query I rowsort
SELECT ( - col2 * - col1 ) - 29 AS col0 FROM tab0
----
2809
68
7433

query I rowsort
SELECT 19 * - 43 + + col0 AS col1 FROM tab2
----
-738
-739
-810

query I rowsort
SELECT ALL cor0.col0 * - cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 9b23e5e74ef3405a4dbf05cceb18c8a8

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT 91 AS col2 FROM tab1, tab1 AS cor0
----
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-5862
SELECT ALL - ( - col1 ) DIV cor0.col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5862
SELECT ALL - ( - col1 ) / cor0.col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5863
SELECT - CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-5863
SELECT - CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT - ( - 35 ) AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2 AS cor2
----
35

query I rowsort
SELECT ALL + cor0.col2 + - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5866
SELECT DISTINCT + col2 + col0 DIV col0 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-5866
SELECT DISTINCT + col2 + col0 / col0 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL - cor0.col1 + col2 AS col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT ALL 33 * col1 - - col2 AS col0 FROM tab2 AS cor0
----
1050
1973
599

query I rowsort
SELECT DISTINCT + + ( col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + 69 + - cor0.col2 * col2 FROM tab2 AS cor0
----
-1375
-607
-660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col1 col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + 23 + col2 * + tab2.col1 AS col2 FROM tab2
----
1557
669
860

query I rowsort
SELECT ( + col0 ) - - col1 * - col2 * col2 AS col1 FROM tab0 AS cor0
----
-611795
-62
-93630

onlyif mysql # use DIV operator for integer division
query I rowsort label-5874
SELECT - col0 + col1 DIV ( + col0 ) AS col0 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-5874
SELECT - col0 + col1 / ( + col0 ) AS col0 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT DISTINCT - col1 * col2 + + col1 * - col1 AS col1 FROM tab1 cor0
----
-1417
-2080
-670

query I rowsort
SELECT ALL - 87 - - col1 * 98 * cor0.col2 AS col1 FROM tab2 AS cor0
----
150245
63221
81939

query I rowsort
SELECT ALL - + ( cor0.col0 ) FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( 15 AS REAL ) * - col0 FROM tab0
----
-1335
-360
-525

query I rowsort
SELECT DISTINCT - ( + tab0.col0 * + 42 ) FROM tab0, tab2 AS cor0
----
-1008
-1470
-3738

query I rowsort
SELECT + col2 - col0 * - 81 AS col0 FROM tab0 AS cor0
----
1977
2836
7291

query I rowsort
SELECT + 61 * + col2 * + col1 - - col2 FROM tab1 AS cor0
----
34827
76224
85698

query I rowsort
SELECT DISTINCT + 2 * + cor0.col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + 28 * + 56 FROM tab1, tab2 AS cor0
----
9 values hashing to fef6c76d32d8549626b47199cff234ba

query I rowsort
SELECT + col2 + - col0 * + col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT ALL + 99 + + cor0.col0 FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT DISTINCT - 23 AS col2 FROM tab2, tab2 AS cor0
----
-23

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 cor0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 980274175fafec015a83080672486a9a

query I rowsort
SELECT col1 + ( col1 ) FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5889
SELECT ALL - CAST( NULL AS SIGNED ) * 72 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5889
SELECT ALL - CAST ( NULL AS INTEGER ) * 72 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 99 * col1 * - 97 AS col1 FROM tab1
----
-124839
-249678
-96030

query I rowsort
SELECT col1 * col1 * + tab1.col2 AS col0 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT - ( tab2.col0 ) FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL col2 * - col1 * + tab0.col0 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT + - cor0.col2 * col0 + - 31 * 11 FROM tab1 cor0
----
-3989
-503
-8021

query I rowsort
SELECT - col2 * - col0 + col2 + - 17 AS col2 FROM tab0 AS cor0
----
19
7363
808

query I rowsort
SELECT DISTINCT - ( col1 ) * col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + 11 * col1 * col2 FROM tab0
----
1067
31218
82082

query I rowsort
SELECT ALL - cor0.col2 * + col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col1 + + 52 * col0 col0 FROM tab1 AS cor0
----
185
3402
4253

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + ( - col1 ) col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - - col2 * + 79 * + 11 FROM tab1 AS cor0
----
46926
49533
83424

query I rowsort
SELECT DISTINCT - col1 * - ( - col2 + col0 ) FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT - - cor0.col2 * 57 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT ALL - ( tab0.col0 ) + + 72 FROM tab0
----
-17
37
48

query I rowsort
SELECT - + col2 + - 69 FROM tab0 AS cor0
----
-102
-151
-70

query I rowsort
SELECT + cor0.col1 * col1 + col0 AS col2 FROM tab1 cor0
----
164
249
679

query I rowsort
SELECT - - cor0.col0 + 84 FROM tab2 cor0
----
162
163
91

query I rowsort
SELECT ALL tab2.col1 * - ( col0 ) AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - col0 * col0 * - 70 AS col2 FROM tab0
----
40320
554470
85750

query I rowsort
SELECT + col0 - + 83 * col1 FROM tab2
----
-1332
-2566
-4819

onlyif mysql # use DIV operator for integer division
query I rowsort label-5911
SELECT DISTINCT cor0.col1 DIV 57 AS col0 FROM tab0, tab0 cor0
----
1

skipif mysql # not compatible
query I rowsort label-5911
SELECT DISTINCT cor0.col1 / 57 AS col0 FROM tab0, tab0 cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5912
SELECT col0 DIV cor0.col1 + + col2 * + col0 + ( - col0 ) FROM tab1 cor0
----
159
3590
7606

skipif mysql # not compatible
query I rowsort label-5912
SELECT col0 / cor0.col1 + + col2 * + col0 + ( - col0 ) FROM tab1 cor0
----
159
3590
7606

query I rowsort
SELECT - + col2 * + col2 + col2 FROM tab0 AS cor0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5914
SELECT ALL + 89 + + col1 DIV col1 FROM tab0 AS cor0
----
90
90
90

skipif mysql # not compatible
query I rowsort label-5914
SELECT ALL + 89 + + col1 / col1 FROM tab0 AS cor0
----
90
90
90

query I rowsort
SELECT DISTINCT - + ( - col1 ) - col2 AS col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT ALL - 51 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

query I rowsort
SELECT + 49 FROM tab2, tab2 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + col2 * - tab2.col2 AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT ALL col1 * ( + tab0.col0 ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - col2 * - 13 FROM tab1
----
1248
702
741

query I rowsort
SELECT + col0 * cor0.col0 + ( - cor0.col2 ) + + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-1521
-2171
-260

query I rowsort
SELECT + col1 - col1 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT col2 + + col2 * - ( - cor0.col1 ) + + col0 AS col0 FROM tab0 AS cor0
----
133
2895
7633

query I rowsort
SELECT cor0.col1 * - col1 * - cor0.col1 + col0 FROM tab2 AS cor0
----
205457
29798
4992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + + cor0.col1 * cor0.col2 col2 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 70 * 99 + + tab0.col0 col0 FROM tab0
----
6954
6965
7019

query I rowsort
SELECT DISTINCT col2 + - ( tab0.col2 ) AS col0 FROM tab0
----
0

query I rowsort
SELECT 9 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT 55 FROM tab0, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + 71 * - col1 FROM tab2 AS cor0
----
-1207
-2201
-4189

query I rowsort
SELECT ( + col0 + + col0 ) * col1 FROM tab0
----
16198
4128
6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-5932
SELECT ALL col1 * tab1.col1 DIV + col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5932
SELECT ALL col1 * tab1.col1 / + col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - + 89 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
-89

query I rowsort
SELECT + 76 + + col0 * + col1 * col0 + col0 FROM tab0
----
118936
49636
720976

onlyif mysql # use DIV operator for integer division
query I rowsort label-5935
SELECT 7 * - col1 * + ( - col1 ) - - col2 * ( - col1 ) DIV cor0.col0 AS col2 FROM tab1 AS cor0
----
1168
4264
692

skipif mysql # not compatible
query I rowsort label-5935
SELECT 7 * - col1 * + ( - col1 ) - - col2 * ( - col1 ) / cor0.col0 AS col2 FROM tab1 AS cor0
----
1168
4264
692

query I rowsort
SELECT - col0 * col2 - ( - col0 + col2 ) FROM tab2 AS cor0
----
-1976
-209
-2961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 55 col1 FROM tab2
----
-55
-55
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-5938
SELECT 16 + col1 DIV col0 AS col2 FROM tab0
----
17
18
19

skipif mysql # not compatible
query I rowsort label-5938
SELECT 16 + col1 / col0 AS col2 FROM tab0
----
17
18
19

query I rowsort
SELECT 60 * + col0 FROM tab1
----
180
3840
4800

onlyif mysql # use DIV operator for integer division
query I rowsort label-5940
SELECT DISTINCT ( col0 ) + col1 DIV tab0.col0 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-5940
SELECT DISTINCT ( col0 ) + col1 / tab0.col0 FROM tab0
----
27
37
90

query I rowsort
SELECT ALL col1 - - col1 AS col0 FROM tab1 AS cor0
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 col0 FROM tab0
----
90
90
90

query I rowsort
SELECT - tab1.col0 * 86 FROM tab1
----
-258
-5504
-6880

query I rowsort
SELECT - col1 + ( - col1 + ( - col2 ) ) AS col0 FROM tab1 AS cor0
----
-106
-122
-77

query I rowsort
SELECT col0 * 96 + col1 + - col2 FROM tab1
----
260
6097
7597

query I rowsort
SELECT 50 + - col0 * col0 AS col2 FROM tab2
----
-6034
-6191
1

query I rowsort
SELECT + - col0 * + col0 * col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5948
SELECT ALL - ( - cor0.col2 ) * 70 + col2 + - col2 DIV - 89 AS col0 FROM tab2 AS cor0
----
1846
1917
2698

skipif mysql # not compatible
query I rowsort label-5948
SELECT ALL - ( - cor0.col2 ) * 70 + col2 + - col2 / - 89 AS col0 FROM tab2 AS cor0
----
1846
1917
2698

query I rowsort
SELECT + col2 * + col1 + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT - + ( + cor0.col2 ) + - ( + col1 ) FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5951
SELECT ALL - 39 DIV + col1 + + 42 FROM tab1 AS cor0
----
39
39
41

skipif mysql # not compatible
query I rowsort label-5951
SELECT ALL - 39 / + col1 + + 42 FROM tab1 AS cor0
----
39
39
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * cor0.col1 + cor0.col0 * col1 col2 FROM tab1 AS cor0
----
1210
1482
2288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + cor0.col0 col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - + col0 - col2 * + ( 90 ) * - col0 AS col2 FROM tab1 AS cor0
----
14577
328256
691120

query I rowsort
SELECT DISTINCT col0 + - col2 + + 47 FROM tab2 AS cor0
----
27
88
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col1 + - cor0.col0 col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL + + ( + col2 ) * + col2 + - col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT DISTINCT + - col0 * - col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + cor0.col1 + col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col2 * - col0 + + col2 + ( + cor0.col2 ) FROM tab1 AS cor0
----
270
3762
7872

query I rowsort
SELECT + + col0 * - ( - col1 ) AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT col0 * - col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5963
SELECT col2 + cor0.col1 * 11 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
12
44
93

skipif mysql # not compatible
query I rowsort label-5963
SELECT col2 + cor0.col1 * 11 / cor0.col1 AS col1 FROM tab0 AS cor0
----
12
44
93

query I rowsort
SELECT ALL + - col1 + + col0 AS col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT ALL col0 * 43 AS col1 FROM tab0 AS cor0
----
1032
1505
3827

query I rowsort
SELECT col0 * + ( - 88 * col2 ) AS col0 FROM tab1 cor0
----
-14256
-321024
-675840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5967
SELECT ALL - 43 * - 48 * cor0.col2 + ( 60 + - col1 ) * - CAST( - 82 AS SIGNED ) FROM tab0 cor0
----
-970
166706
65980

skipif mysql # not compatible
query I rowsort label-5967
SELECT ALL - 43 * - 48 * cor0.col2 + ( 60 + - col1 ) * - CAST ( - 82 AS INTEGER ) FROM tab0 cor0
----
-970
166706
65980

query I rowsort
SELECT DISTINCT + ( - col2 ) + + col1 * col1 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT ALL ( 24 ) - col2 FROM tab1 AS cor0
----
-30
-33
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5970
SELECT ALL col2 DIV ( + col2 ) 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-5970
SELECT ALL col2 / ( + col2 ) col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - ( + cor0.col1 ) - + col0 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + col0 + + col2 * col0 * + col2 AS col2 FROM tab0 AS cor0
----
26160
598525
70

query I rowsort
SELECT DISTINCT - ( - 99 ) - cor0.col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-693
-7199
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-5974
SELECT ALL - ( col1 ) * - col2 + - ( - 80 ) DIV - col2 AS col0 FROM tab1 AS cor0
----
1248
1403
569

skipif mysql # not compatible
query I rowsort label-5974
SELECT ALL - ( col1 ) * - col2 + - ( - 80 ) / - col2 AS col0 FROM tab1 AS cor0
----
1248
1403
569

onlyif mysql # use DIV operator for integer division
query I rowsort label-5975
SELECT DISTINCT + 12 * + col1 - col1 DIV - col0 FROM tab1 AS cor0
----
120
156
320

skipif mysql # not compatible
query I rowsort label-5975
SELECT DISTINCT + 12 * + col1 - col1 / - col0 FROM tab1 AS cor0
----
120
156
320

query I rowsort
SELECT ALL - - ( col2 ) + col0 * 36 FROM tab2 AS cor0
----
279
2834
2882

query I rowsort
SELECT - col2 + - 29 FROM tab0 AS cor0
----
-111
-30
-62

query I rowsort
SELECT DISTINCT - - cor0.col2 + - cor0.col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + ( + col0 ) + col1 + - cor0.col0 FROM tab2 cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 16 + + col2 * col0 col1 FROM tab0 AS cor0
----
51
7314
808

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5981
SELECT ALL - CAST( col0 AS SIGNED ) + cor0.col2 * CAST( - col2 + + col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-1
-321
485

skipif mysql # not compatible
query I rowsort label-5981
SELECT ALL - CAST ( col0 AS INTEGER ) + cor0.col2 * CAST ( - col2 + + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-1
-321
485

query I rowsort
SELECT DISTINCT ( - ( col0 ) ) * col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + col1 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + + 37 + + col0 * col2 FROM tab0 AS cor0
----
72
7335
829

query I rowsort
SELECT - col2 + - col2 * col2 * + col0 FROM tab2
----
-114114
-5130
-52754

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - - 10 * col1 * col0 AS col1 FROM tab1 AS cor0
----
10400
6400
780

query I rowsort
SELECT cor0.col0 * + col1 * col0 AS col1 FROM tab0 AS cor0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5989
SELECT ALL - + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5989
SELECT ALL - + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col1 + + ( col2 ) * ( 57 ) AS col1 FROM tab0 AS cor0
----
-40
1795
4583

query I rowsort
SELECT + + 83 - col0 FROM tab1 AS cor0
----
19
3
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5992
SELECT - + CAST( + 43 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-43
-43
-43

skipif mysql # not compatible
query I rowsort label-5992
SELECT - + CAST ( + 43 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - col2 + col2 + - col0 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + col0 + col2 * 69 FROM tab2 AS cor0
----
1870
1872
2701

query I rowsort
SELECT DISTINCT + 34 + - col1 AS col0 FROM tab2
----
-25
17
3

query I rowsort
SELECT col2 * + col2 + + 55 AS col2 FROM tab2 AS cor0
----
1499
731
784

query I rowsort
SELECT - col2 * 42 AS col0 FROM tab0 AS cor0
----
-1386
-3444
-42

query I rowsort
SELECT ALL - + col2 + col2 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor0.col0 * - ( + cor0.col1 ) + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL col1 * + col0 + + 73 - col0 AS col2 FROM tab1 AS cor0
----
1033
148
649

query I rowsort
SELECT DISTINCT col2 * ( - col0 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 - + col0 col2 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT + col0 + - 21 * col1 AS col0 FROM tab0 AS cor0
----
-1782
-1822
-2002

query I rowsort
SELECT - 39 * + col0 AS col2 FROM tab2 cor0
----
-273
-3042
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-6005
SELECT DISTINCT + 69 DIV + 17 AS col1 FROM tab1, tab2 AS cor0
----
4

skipif mysql # not compatible
query I rowsort label-6005
SELECT DISTINCT + 69 / + 17 AS col1 FROM tab1, tab2 AS cor0
----
4

query I rowsort
SELECT col0 * - col0 + col1 AS col1 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT 5 * + col0 AS col2 FROM tab0
----
120
175
445

onlyif mysql # use DIV operator for integer division
query I rowsort label-6008
SELECT DISTINCT - col1 DIV - col1 AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-6008
SELECT DISTINCT - col1 / - col1 AS col2 FROM tab1
----
1

query I rowsort
SELECT 68 * col1 AS col2 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT DISTINCT + col1 + + cor0.col0 + + 91 * + col1 FROM tab1 AS cor0
----
1276
2395
984

onlyif mysql # use DIV operator for integer division
query I rowsort label-6011
SELECT ALL + col1 * + col2 + - 18 DIV 76 AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-6011
SELECT ALL + col1 * + col2 + - 18 / 76 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - 44 + col2 AS col2 FROM tab0 AS cor0
----
-11
-43
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6013
SELECT DISTINCT + col1 + col1 DIV 28 col1 FROM tab2
----
17
32
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6013
SELECT DISTINCT + col1 + col1 / 28 col1 FROM tab2
----
17
32
61

query I rowsort
SELECT - col0 + col2 + + ( col1 ) * + col2 AS col0 FROM tab1
----
1264
1455
563

query I rowsort
SELECT cor0.col1 + 4 * 24 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to f1b206ed02d756e3726b73328a5483a3

query I rowsort
SELECT - + 70 * - ( col2 * - ( + col2 ) ) AS col0 FROM tab0 AS cor0
----
-470680
-70
-76230

query I rowsort
SELECT + col0 * 94 FROM tab0
----
2256
3290
8366

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * ( + 81 ) + col1 * col1 col0 FROM tab0
----
12244
15490
9340

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 62 col0 FROM tab1
----
62
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6020
SELECT + CAST( NULL AS SIGNED ) + + cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6020
SELECT + CAST ( NULL AS INTEGER ) + + cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6021
SELECT ALL - CAST( - 95 AS SIGNED ) * - col2 + col2 FROM tab1 cor0
----
-5076
-5358
-9024

skipif mysql # not compatible
query I rowsort label-6021
SELECT ALL - CAST ( - 95 AS INTEGER ) * - col2 + col2 FROM tab1 cor0
----
-5076
-5358
-9024

query I rowsort
SELECT + - 47 - - col1 FROM tab1 AS cor0
----
-21
-34
-37

query I rowsort
SELECT - 9 * - col0 AS col0 FROM tab1 cor0
----
27
576
720

query I rowsort
SELECT - ( - col2 ) * - col1 + - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT - col0 * + 3 AS col1 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT + - 67 * + col1 FROM tab1 cor0
----
-1742
-670
-871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + 39 + + col1 * - col2 col2 FROM tab1 AS cor0
----
-1755
-2418
-960

query I rowsort
SELECT + - col0 + 25 AS col1 FROM tab1 AS cor0
----
-39
-55
22

query I rowsort
SELECT ALL - - 75 * 3 + - col1 AS col0 FROM tab2 AS cor0
----
166
194
208

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 + col1 AS col2 FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT - ( + col1 ) * cor0.col1 + col0 AS col2 FROM tab1 cor0
----
-36
-673
-89

query I rowsort
SELECT ALL - col0 * 70 FROM tab0 AS cor0
----
-1680
-2450
-6230

onlyif mysql # use DIV operator for integer division
query I rowsort label-6033
SELECT ALL + - cor0.col1 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6033
SELECT ALL + - cor0.col1 / cor0.col1 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 82 col0 FROM tab2
----
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6035
SELECT ( ( - col0 ) ) DIV - 27 FROM tab2
----
0
2
2

skipif mysql # not compatible
query I rowsort label-6035
SELECT ( ( - col0 ) ) / - 27 FROM tab2
----
0
2
2

query I rowsort
SELECT col1 * - col1 * col0 FROM tab0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-6037
SELECT col1 DIV 26 AS col2 FROM tab0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-6037
SELECT col1 / 26 AS col2 FROM tab0
----
3
3
3

query I rowsort
SELECT 15 * + col0 AS col0 FROM tab0
----
1335
360
525

query I rowsort
SELECT - col1 + col2 + + col1 AS col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT + + col2 + - 23 * col1 FROM tab0 AS cor0
----
-1945
-2011
-2230

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 * col1 * col1 - - col1 * 3 col2 FROM tab1
----
-13481
-1950
-6370

query I rowsort
SELECT - 5 + + col2 FROM tab0 cor0
----
-4
28
77

query I rowsort
SELECT - - 31 * col1 AS col2 FROM tab1 AS cor0
----
310
403
806

query I rowsort
SELECT DISTINCT col2 * cor0.col1 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col0 * col0 * + col0 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT - col0 * col2 - + col1 * ( col2 ) * - 59 AS col2 FROM tab2 cor0
----
35112
49194
88478

query I rowsort
SELECT - cor0.col1 * col0 + 98 FROM tab1 AS cor0
----
-542
-942
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 62 col0 FROM tab1 AS cor0
----
62

query I rowsort
SELECT - - col1 * col2 + + 50 FROM tab0 AS cor0
----
147
2888
7512

query I rowsort
SELECT ALL - - ( + col2 ) + + col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - 79 * col1 col1 FROM tab2 AS cor0
----
-121186
-51034
-66123

query I rowsort
SELECT - - cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL + + col0 * + ( col2 ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL col0 + + ( 82 ) * col2 FROM tab2 AS cor0
----
2210
2221
3195

query I rowsort
SELECT ALL ( + col2 ) AS col0 FROM tab2
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6056
SELECT col2 DIV - col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-6056
SELECT col2 / - col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6057
SELECT col2 * 73 DIV - col2 col1 FROM tab1 AS cor0
----
-73
-73
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6057
SELECT col2 * 73 / - col2 col1 FROM tab1 AS cor0
----
-73
-73
-73

query I rowsort
SELECT - ( - 40 ) + col0 * col2 AS col1 FROM tab1 AS cor0
----
202
3688
7720

query I rowsort
SELECT - 77 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

onlyif mysql # use DIV operator for integer division
query I rowsort label-6060
SELECT col1 DIV + col0 AS col2 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-6060
SELECT col1 / + col0 AS col2 FROM tab2 cor0
----
0
0
4

query I rowsort
SELECT - - 75 * col2 + - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1150
-1771
1899

query I rowsort
SELECT DISTINCT col2 * 9 * col0 FROM tab0
----
315
65682
7128

onlyif mysql # use DIV operator for integer division
query I rowsort label-6063
SELECT DISTINCT - - col1 * + cor0.col1 + col2 * col1 + - col2 DIV col0 FROM tab2 AS cor0
----
1795
5015
935

skipif mysql # not compatible
query I rowsort label-6063
SELECT DISTINCT - - col1 * + cor0.col1 + col2 * col1 + - col2 / col0 FROM tab2 AS cor0
----
1795
5015
935

query I rowsort
SELECT ALL + col1 * - 90 FROM tab1 AS cor0
----
-1170
-2340
-900

query I rowsort
SELECT DISTINCT - col1 * + 63 FROM tab2 AS cor0
----
-1071
-1953
-3717

query I rowsort
SELECT col2 - - col1 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL + cor0.col1 * col2 + col0 * col1 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT - + col2 * col2 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-1523
-736
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-6069
SELECT DISTINCT + col1 + col2 DIV col0 AS col1 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-6069
SELECT DISTINCT + col1 + col2 / col0 AS col1 FROM tab1 AS cor0
----
10
14
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-6070
SELECT cor0.col2 + - cor0.col0 DIV - col1 FROM tab1 cor0
----
102
54
63

skipif mysql # not compatible
query I rowsort label-6070
SELECT cor0.col2 + - cor0.col0 / - col1 FROM tab1 cor0
----
102
54
63

query I rowsort
SELECT ALL col2 * 62 + 18 FROM tab2 AS cor0
----
1630
1692
2374

query I rowsort
SELECT DISTINCT + col1 - + col1 * - col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT - col0 - - col1 AS col2 FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-6074
SELECT tab1.col1 + - col1 - ( ( tab1.col2 ) ) DIV - 7 FROM tab1
----
13
7
8

skipif mysql # not compatible
query I rowsort label-6074
SELECT tab1.col1 + - col1 - ( ( tab1.col2 ) ) / - 7 FROM tab1
----
13
7
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col0 - ( col0 ) * + col1 col0 FROM tab0
----
-15397
-2856
-3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-6076
SELECT 60 + col1 DIV col0 FROM tab2
----
60
60
64

skipif mysql # not compatible
query I rowsort label-6076
SELECT 60 + col1 / col0 FROM tab2
----
60
60
64

query I rowsort
SELECT DISTINCT - col2 * + ( tab0.col2 ) + col1 AS col2 FROM tab0
----
-1003
-6633
96

query I rowsort
SELECT + col1 - col1 * col1 FROM tab1 cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - col0 + - 19 + col0 FROM tab2 AS cor0
----
-19
-19
-19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col0 col2 FROM tab2 cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 * + col2 col0 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 * col0 col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT col0 * - 14 * + cor0.col0 + col1 AS col0 FROM tab2 AS cor0
----
-655
-85117
-87357

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6084
SELECT ALL - CAST( NULL AS SIGNED ) * col0 * - col2 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6084
SELECT ALL - CAST ( NULL AS INTEGER ) * col0 * - col2 AS col2 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6085
SELECT - + col1 * + cor0.col2 + col0 * - CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6085
SELECT - + col1 * + cor0.col2 + col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor1.col0 * 97 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 680888a24a416fac4670ec8fb277d7c9

query I rowsort
SELECT DISTINCT - col1 * - cor0.col1 + col0 + col1 AS col0 FROM tab0 AS cor0
----
7506
8461
9541

query I rowsort
SELECT DISTINCT - + col0 * col0 + - 40 FROM tab1 AS cor0
----
-4136
-49
-6440

query I rowsort
SELECT ALL - 89 + + col2 AS col2 FROM tab2 AS cor0
----
-51
-62
-63

query I rowsort
SELECT DISTINCT + - 58 * - col2 AS col2 FROM tab2 AS cor0
----
1508
1566
2204

query I rowsort
SELECT - ( col2 ) * - col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + + 81 AS col0 FROM tab2 AS cor0
----
81

query I rowsort
SELECT ALL + col0 + - cor0.col2 * - col0 FROM tab1 AS cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 * - cor0.col2 col2 FROM tab0 AS cor0
----
-2508
-6232
-76

query I rowsort
SELECT DISTINCT 68 * col0 + ( col2 ) * + col0 FROM tab2 AS cor0
----
665
7332
8374

onlyif mysql # use DIV operator for integer division
query I rowsort label-6096
SELECT DISTINCT - + 99 DIV col2 FROM tab0 AS cor0
----
-1
-3
-99

skipif mysql # not compatible
query I rowsort label-6096
SELECT DISTINCT - + 99 / col2 FROM tab0 AS cor0
----
-1
-3
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( cor0.col1 ) * - 79 col1 FROM tab0 AS cor0
----
-6794
-7189
-7663

query I rowsort
SELECT - col1 * + col1 * ( col1 ) FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT ALL + col0 + - cor0.col0 AS col2 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + ( - cor0.col2 ) + col1 col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT ALL + cor0.col0 + ( - col2 * - col1 + + ( - col2 ) ) FROM tab1 AS cor0
----
1232
1353
577

query I rowsort
SELECT DISTINCT + col0 + ( - col1 ) * col0 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - col2 * 33 AS col2 FROM tab1 AS cor0
----
-1782
-1881
-3168

query I rowsort
SELECT ALL 56 * col1 AS col2 FROM tab0
----
4816
5096
5432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6105
SELECT + 37 * - col0 + CAST( + col0 AS SIGNED ) AS col1 FROM tab0
----
-1260
-3204
-864

skipif mysql # not compatible
query I rowsort label-6105
SELECT + 37 * - col0 + CAST ( + col0 AS INTEGER ) AS col1 FROM tab0
----
-1260
-3204
-864

query I rowsort
SELECT ALL - - ( + 16 ) FROM tab1 AS cor0
----
16
16
16

query I rowsort
SELECT + 91 + - 20 AS col2 FROM tab1 AS cor0
----
71
71
71

query I rowsort
SELECT DISTINCT 76 * col0 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT - - 76 + col0 AS col1 FROM tab2 cor0
----
154
155
83

query I rowsort
SELECT DISTINCT - - 95 + cor0.col2 AS col2 FROM tab0 AS cor0
----
128
177
96

query I rowsort
SELECT - col2 + 56 AS col2 FROM tab2 AS cor0
----
18
29
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - 48 col2 FROM tab0 AS cor0
----
-130
-49
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6113
SELECT 80 DIV - col2 + + col1 * col2 AS col0 FROM tab0 AS cor0
----
17
2836
7462

skipif mysql # not compatible
query I rowsort label-6113
SELECT 80 / - col2 + + col1 * col2 AS col0 FROM tab0 AS cor0
----
17
2836
7462

query I rowsort
SELECT ALL + - col2 + + ( col1 ) + col0 * - 23 FROM tab2 AS cor0
----
-157
-1761
-1838

query I rowsort
SELECT DISTINCT 85 * col2 + col1 FROM tab1
----
4616
4855
8173

query I rowsort
SELECT DISTINCT - 58 * tab2.col0 + - col1 AS col1 FROM tab2
----
-437
-4583
-4599

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 51 col2 FROM tab1 AS cor0
----
-51
-51
-51

query I rowsort
SELECT DISTINCT + 80 + + col0 FROM tab2 AS cor0
----
158
159
87

query I rowsort
SELECT + + 56 AS col2 FROM tab1 AS cor0
----
56
56
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6120
SELECT DISTINCT - ( + col0 ) DIV col0 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-6120
SELECT DISTINCT - ( + col0 ) / col0 FROM tab1
----
-1

query I rowsort
SELECT - ( + 64 ) FROM tab2
----
-64
-64
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-6122
SELECT 81 + - col1 DIV col2 AS col1 FROM tab1
----
81
81
81

skipif mysql # not compatible
query I rowsort label-6122
SELECT 81 + - col1 / col2 AS col1 FROM tab1
----
81
81
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + tab1.col0 col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + ( - col2 ) + - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col2 col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6126
SELECT - CAST( 0 AS SIGNED ) * col0 + - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6126
SELECT - CAST ( 0 AS INTEGER ) * col0 + - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 - ( col0 ) FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + 5 + - ( col1 ) FROM tab1 cor0
----
-21
-5
-8

query I rowsort
SELECT + + 90 - - col0 AS col2 FROM tab0 cor0
----
114
125
179

query I rowsort
SELECT DISTINCT - 95 AS col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
-95

query I rowsort
SELECT DISTINCT 75 AS col0 FROM tab0, tab2 AS cor0
----
75

query I rowsort
SELECT - col0 * + col1 * + cor0.col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 7 col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT + + col1 * - 35 AS col0 FROM tab1 AS cor0
----
-350
-455
-910

query I rowsort
SELECT 79 FROM tab0, tab2 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT DISTINCT col0 * - 41 FROM tab2 AS cor0
----
-287
-3198
-3239

query I rowsort
SELECT ALL + 88 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT DISTINCT tab2.col1 + tab2.col0 + ( col1 ) * - 62 AS col2 FROM tab2
----
-1884
-3521
-958

query I rowsort
SELECT DISTINCT tab2.col2 + ( + ( col2 ) ) FROM tab2
----
52
54
76

query I rowsort
SELECT ALL + tab0.col2 + + tab0.col2 FROM tab0
----
164
2
66

query I rowsort
SELECT + cor0.col1 + - 86 * + col1 + - col1 FROM tab0 cor0
----
-7396
-7826
-8342

query I rowsort
SELECT ( + 45 ) * cor0.col0 * + 94 FROM tab1 AS cor0
----
12690
270720
338400

query I rowsort
SELECT col1 * - 8 * 68 AS col2 FROM tab0
----
-46784
-49504
-52768

query I rowsort
SELECT ALL 93 FROM tab1, tab1 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6146
SELECT + cor0.col0 DIV + CAST( - col2 AS SIGNED ) AS col1 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-6146
SELECT + cor0.col0 / + CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 cor0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6147
SELECT ALL col0 DIV - ( - 60 * col0 ) + - col0 + + 0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6147
SELECT ALL col0 / - ( - 60 * col0 ) + - col0 + + 0 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6148
SELECT col2 DIV ( + 5 ) FROM tab0
----
0
16
6

skipif mysql # not compatible
query I rowsort label-6148
SELECT col2 / ( + 5 ) FROM tab0
----
0
16
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col2 * - col0 + + col0 * col2 col0 FROM tab2 AS cor0
----
351
4030
5966

query I rowsort
SELECT DISTINCT - col2 * 92 + col0 AS col1 FROM tab2 AS cor0
----
-2314
-2477
-3417

query I rowsort
SELECT DISTINCT + + ( 58 ) FROM tab2 AS cor0
----
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6152
SELECT DISTINCT cor1.col1 DIV - 14 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
-1
0

skipif mysql # not compatible
query I rowsort label-6152
SELECT DISTINCT cor1.col1 / - 14 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 79 * + col1 col2 FROM tab2 AS cor0
----
-1343
-2449
-4661

query I rowsort
SELECT ALL - 13 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

query I rowsort
SELECT - 78 - col1 FROM tab2
----
-109
-137
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6156
SELECT 90 + + 2 DIV + col0 - col0 FROM tab0
----
1
55
66

skipif mysql # not compatible
query I rowsort label-6156
SELECT 90 + + 2 / + col0 - col0 FROM tab0
----
1
55
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6157
SELECT DISTINCT col1 + col0 / + col2 - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6157
SELECT DISTINCT col1 + col0 / + col2 - CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT ALL cor0.col2 * + tab1.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to bbf44891fdcfbe372162a2e549d3eeed

query I rowsort
SELECT DISTINCT - ( 2 * - col1 ) FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT 45 - col1 * col0 AS col0 FROM tab2
----
-1298
-172
-4557

query I rowsort
SELECT 84 * ( col0 ) + 12 + ( + col1 * col1 + col2 ) FROM tab0
----
12362
15851
9457

query I rowsort
SELECT - - col1 + + col0 + col0 * 65 AS col0 FROM tab1 AS cor0
----
224
4234
5293

query I rowsort
SELECT + ( + 2 ) * col2 * - 70 AS col0 FROM tab2 AS cor0
----
-3640
-3780
-5320

query I rowsort
SELECT ALL 18 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6165
SELECT ALL CAST( NULL AS DECIMAL ) AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6165
SELECT ALL CAST ( NULL AS REAL ) AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT 3 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT col0 + + col0 * ( cor0.col1 ) FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + cor0.col1 col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - - col1 + - cor0.col1 * + col0 * + col1 AS col0 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT DISTINCT + cor0.col1 * col0 - + 74 FROM tab2 AS cor0
----
1269
143
4528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col1 col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6173
SELECT + + 12 DIV col1 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6173
SELECT + + 12 / col1 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - + col2 * + col0 + + 13 FROM tab0 AS cor0
----
-22
-7285
-779

query I rowsort
SELECT ALL - cor0.col1 + - cor0.col1 FROM tab2 AS cor0
----
-118
-34
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 68 + - col0 * - ( col1 * col0 ) col2 FROM tab2 AS cor0
----
106029
1451
358888

query I rowsort
SELECT DISTINCT 83 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6178
SELECT DISTINCT 60 * tab0.col2 DIV 65 FROM tab0
----
0
30
75

skipif mysql # not compatible
query I rowsort label-6178
SELECT DISTINCT 60 * tab0.col2 / 65 FROM tab0
----
0
30
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + col2 col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ( + col0 ) * 35 AS col1 FROM tab2 AS cor0
----
245
2730
2765

query I rowsort
SELECT ALL - - 0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * 41 - + col2 FROM tab1 AS cor0
----
2567
3184
69

query I rowsort
SELECT DISTINCT + + col1 * + 27 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-17442
-22599
-41418

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + 27 col1 FROM tab1 AS cor0
----
-24
37
53

query I rowsort
SELECT DISTINCT - cor0.col0 * + 90 FROM tab1 cor0
----
-270
-5760
-7200

query I rowsort
SELECT DISTINCT col1 * col0 * - col0 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT col2 * - col2 + col0 AS col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT - ( tab2.col0 + 30 ) * col1 FROM tab2
----
-1147
-1853
-6372

query I rowsort
SELECT - 30 + col2 FROM tab0
----
-29
3
52

query I rowsort
SELECT 28 * - col2 - col1 FROM tab0
----
-1010
-125
-2387

query I rowsort
SELECT - col1 * col0 + col2 * col1 FROM tab1
----
-70
1326
208

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col2 / col1 NOT BETWEEN + col1 * col0 AND ( NULL )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT - col2 + col0 FROM tab1 WHERE NOT col0 NOT IN ( + tab1.col0 )
----
-16
-51
7

query I rowsort
SELECT col2 * + col0 + - col1 AS col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL - tab0.col2 + col0 * col2 FROM tab0
----
34
7216
759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col0 + col0 + tab0.col2 col0 FROM tab0
----
-1189
-519
-7750

query I rowsort
SELECT col1 * - col1 * col0 AS col0 FROM tab1
----
-13520
-2028
-6400

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( + col0 * - col0 * + col1 ) IN ( - col2 * col1 )
----

query I rowsort
SELECT DISTINCT + col1 * col1 + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT col0 + - tab2.col1 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT col1 * col2 + col0 + tab1.col2 FROM tab1
----
1424
1461
691

query I rowsort
SELECT DISTINCT col1 * col0 AS col0 FROM tab2 WHERE NOT ( NULL ) < NULL
----

query I rowsort
SELECT col0 AS col2 FROM tab2 WHERE NULL NOT IN ( + col1 )
----

query III rowsort
SELECT * FROM tab0 WHERE tab0.col2 / col1 NOT IN ( - col0 + + col2 - - col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT - col1 + - col2 FROM tab1 WHERE NOT - col2 BETWEEN ( col1 ) AND NULL
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6206
SELECT col1 - - col0 DIV col0 col2 FROM tab0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6206
SELECT col1 - - col0 / col0 col2 FROM tab0
----
87
92
98

query I rowsort
SELECT + tab2.col1 * - col2 + col1 * + tab2.col0 AS col2 FROM tab2
----
-620
3068
697

query III rowsort
SELECT * FROM tab1 WHERE NULL > col1 * - col1
----

query I rowsort
SELECT ALL - col2 + col2 * col2 FROM tab0 WHERE NOT NULL = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 + - col2 col2 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 FROM tab0 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT ALL col2 * + 47 * - col1 + col2 AS col2 FROM tab0
----
-133353
-350632
-4558

onlyif mysql # use DIV operator for integer division
query I rowsort label-6213
SELECT + col1 DIV + col0 - - col2 * + col2 col1 FROM tab0
----
1092
3
6725

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6213
SELECT + col1 / + col0 - - col2 * + col2 col1 FROM tab0
----
1092
3
6725

query I rowsort
SELECT - 46 * - 46 * + col0 AS col0 FROM tab1
----
135424
169280
6348

query I rowsort
SELECT - 56 + + col2 FROM tab1
----
-2
1
40

query I rowsort
SELECT 49 * col0 + - ( - 24 ) AS col2 FROM tab0 cor0
----
1200
1739
4385

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 + + ( 55 ) FROM tab2 AS cor0
----
2083
244
3057

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 * + cor0.col0 col0 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 + col1 * col2 + + cor0.col0 col1 FROM tab2 cor0
----
1061
2068
6214

query I rowsort
SELECT ALL + + ( cor0.col1 ) AS col0 FROM tab2 cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6221
SELECT + 74 + + col0 DIV col1 FROM tab2 AS cor0
----
74
75
78

skipif mysql # not compatible
query I rowsort label-6221
SELECT + 74 + + col0 / col1 FROM tab2 AS cor0
----
74
75
78

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + col0 + col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
12839
16469
9484

query I rowsort
SELECT DISTINCT + 98 + + col1 * - cor0.col2 AS col0 FROM tab2 cor0
----
-1436
-548
-739

query I rowsort
SELECT ALL col1 * ( 43 ) + col0 FROM tab0
----
3722
4002
4206

query I rowsort
SELECT 61 + + cor1.col1 * 16 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 862a91b6d4f7cd78e5a2d9e9e84c1827

query I rowsort
SELECT DISTINCT + col1 + - 92 AS col2 FROM tab0
----
-1
-6
5

query I rowsort
SELECT - + col2 - 12 FROM tab1 AS cor0
----
-108
-66
-69

query I rowsort
SELECT col0 + + 3 AS col2 FROM tab2 AS cor0
----
10
81
82

query I rowsort
SELECT - - col0 + + cor0.col0 * - col1 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT - + col0 + + cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT col2 * cor0.col1 + + 73 AS col1 FROM tab1 AS cor0
----
1321
1477
643

query I rowsort
SELECT ALL col1 * + 97 AS col0 FROM tab2 cor0
----
1649
3007
5723

query I rowsort
SELECT ALL - + col1 + ( col1 ) * cor0.col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 - - col0 * col1 AS col0 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT - + col0 - 43 AS col1 FROM tab1 AS cor0
----
-107
-123
-46

query I rowsort
SELECT + 42 + + col2 * + col2 * 63 FROM tab2 AS cor0
----
42630
45969
91014

query I rowsort
SELECT ALL - col1 * + 43 AS col0 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT ALL - 29 * + col2 + col2 FROM tab1 AS cor0
----
-1512
-1596
-2688

query I rowsort
SELECT ALL + ( col2 ) + - col2 * - col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + - col2 + 76 * + col2 AS col1 FROM tab1 cor0
----
4050
4275
7200

skipif mysql # not compatible
query I rowsort
SELECT ALL + 51 + - ( col2 ) + + CAST ( col0 AS REAL ) FROM tab2 AS cor0
----
103
31
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6242
SELECT DISTINCT + 68 DIV col0 + - cor0.col2 * + col1 * col0 + + col1 AS col1 FROM tab2 AS cor0
----
-119593
-51017
-5819

skipif mysql # not compatible
query I rowsort label-6242
SELECT DISTINCT + 68 / col0 + - cor0.col2 * + col1 * col0 + + col1 AS col1 FROM tab2 AS cor0
----
-119593
-51017
-5819

query I rowsort
SELECT ALL - - 91 * col2 + col2 FROM tab1 cor0
----
4968
5244
8832

query I rowsort
SELECT DISTINCT + cor1.col1 + 1 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
11
14
27

query I rowsort
SELECT DISTINCT - col1 + + col1 * col0 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT - + 18 + ( + col1 ) * col2 * + col1 FROM tab1 cor0
----
16206
36486
5682

query I rowsort
SELECT DISTINCT col2 * + col1 + + col1 AS col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL - 83 * + col0 - + col1 AS col0 FROM tab1 AS cor0
----
-275
-5322
-6653

query I rowsort
SELECT DISTINCT - col0 + col0 * - col2 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT 64 * col1 AS col0 FROM tab0 AS cor0
----
5504
5824
6208

query I rowsort
SELECT col2 + 59 * - col0 * col1 AS col0 FROM tab1 AS cor0
----
-37703
-4548
-61264

onlyif mysql # use DIV operator for integer division
query I rowsort label-6252
SELECT + tab1.col0 DIV ( col0 ) AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6252
SELECT + tab1.col0 / ( col0 ) AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT + - col2 + col2 * - col2 AS col0 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT + col1 * + cor0.col2 + - 38 AS col2 FROM tab2 AS cor0
----
1496
608
799

query I rowsort
SELECT col0 + + 74 * + col0 AS col2 FROM tab1 cor0
----
225
4800
6000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6256
SELECT ALL - CAST( NULL AS DECIMAL ) - - 82 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6256
SELECT ALL - CAST ( NULL AS REAL ) - - 82 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 32 col2 FROM tab1 AS cor0
----
32
32
32

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col2 AS REAL ) * + col2 + - cor0.col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6259
SELECT + CAST( - col1 AS SIGNED ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-6259
SELECT + CAST ( - col1 AS INTEGER ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - 3 * + col2 * + col1 AS col2 FROM tab2 AS cor0
----
-1938
-2511
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6261
SELECT col1 DIV col0 AS col0 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6261
SELECT col1 / col0 AS col0 FROM tab0 cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6262
SELECT + col2 DIV - col0 + col0 FROM tab0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-6262
SELECT + col2 / - col0 + col0 FROM tab0
----
23
35
89

query I rowsort
SELECT - col0 + col0 * + col1 AS col1 FROM tab1 AS cor0
----
576
75
960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 43 * - col1 col1 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT 11 - tab2.col2 FROM tab2, tab1 cor0
----
9 values hashing to e13d40a9944ad4408b0b2a63b47af5ea

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + - col1 col2 FROM tab0
----
-62
706
7207

query I rowsort
SELECT ALL 51 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT + col2 * ( - col2 ) AS col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT 44 * + 87 FROM tab2
----
3828

query I rowsort
SELECT - cor0.col2 + - cor0.col2 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 6d59c936869313d0b2d0f28c10bf14a9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6271
SELECT col1 * - col1 * 70 + + 94 DIV + col2 AS col1 FROM tab0 AS cor0
----
-517718
-579669
-658536

skipif mysql # not compatible
query I rowsort label-6271
SELECT col1 * - col1 * 70 + + 94 / + col2 AS col1 FROM tab0 AS cor0
----
-517718
-579669
-658536

query I rowsort
SELECT DISTINCT 68 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
68

query I rowsort
SELECT 45 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT ALL cor0.col2 * tab2.col1 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 2dce99ccc9ab3f12533423eaad01995c

query I rowsort
SELECT ALL - 24 + col0 AS col1 FROM tab0 cor0
----
0
11
65

query I rowsort
SELECT ALL ( + col2 ) * + col1 * col1 AS col2 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6277
SELECT DISTINCT + - cor0.col2 DIV + col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-6277
SELECT DISTINCT + - cor0.col2 / + col1 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6278
SELECT - - col2 / CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6278
SELECT - - col2 / CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + col0 * + ( col0 ) FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL + + col1 * + col2 + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - 33 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

query I rowsort
SELECT + 73 + + col2 AS col0 FROM tab0 AS cor0
----
106
155
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6283
SELECT ALL + CAST( ( col2 ) + 56 AS SIGNED ) AS col1 FROM tab2
----
82
83
94

skipif mysql # not compatible
query I rowsort label-6283
SELECT ALL + CAST ( ( col2 ) + 56 AS INTEGER ) AS col1 FROM tab2
----
82
83
94

query I rowsort
SELECT + 41 + - col1 FROM tab1 AS cor0
----
15
28
31

query I rowsort
SELECT col0 * col2 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + + ( 91 ) AS col0 FROM tab1 AS cor0
----
91
91
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 + 39 * - col1 col1 FROM tab2 AS cor0
----
-1149
-2241
-603

query I rowsort
SELECT - col1 + cor0.col0 * + col1 AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col2 * 38 + + col2 FROM tab1 AS cor0
----
2106
2223
3744

query I rowsort
SELECT + + 45 * col2 + + cor0.col2 * - cor0.col1 * + col0 AS col1 FROM tab2 AS cor0
----
-118482
-4644
-49324

query I rowsort
SELECT ALL - col2 * - ( col0 ) AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col1 + - 3 FROM tab0
----
83
88
94

query I rowsort
SELECT col2 + - 96 FROM tab1
----
-39
-42
0

query I rowsort
SELECT - - col2 + 91 AS col1 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT DISTINCT - col1 + 92 * + col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-3317
-671507
-72950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6296
SELECT + col0 + CAST( col2 AS SIGNED ) * - cor0.col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif mysql # not compatible
query I rowsort label-6296
SELECT + col0 + CAST ( col2 AS INTEGER ) * - cor0.col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT + - col0 * + col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL col1 + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 75 col1 FROM tab1 AS cor0
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * 41 + col0 col0 FROM tab1 AS cor0
----
2217
2401
4016

query I rowsort
SELECT DISTINCT col1 * - col0 + - col1 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL + - 91 - - cor0.col2 * col2 FROM tab2 AS cor0
----
1353
585
638

query I rowsort
SELECT ALL + col2 * 18 * + col0 + 26 * - ( - col0 ) * + ( + 53 ) AS col1 FROM tab2 AS cor0
----
13048
143988
162898

query I rowsort
SELECT DISTINCT + + cor0.col1 * 2 - col2 AS col1 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT ALL ( + ( - col2 ) ) * + 41 FROM tab1 AS cor0
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT + 1 + + col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT - 15 + - 56 * col2 FROM tab1 AS cor0
----
-3039
-3207
-5391

query I rowsort
SELECT ALL - ( + tab1.col2 ) FROM tab1, tab2 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT + 7 * cor0.col1 AS col1 FROM tab1 AS cor0
----
182
70
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col2 ) * + col0 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + ( col1 ) * col1 - + cor0.col0 * + col0 AS col1 FROM tab2 cor0
----
-2603
-5952
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-6313
SELECT DISTINCT - col0 DIV col1 + col2 * 3 FROM tab2 AS cor0
----
110
77
81

skipif mysql # not compatible
query I rowsort label-6313
SELECT DISTINCT - col0 / col1 + col2 * 3 FROM tab2 AS cor0
----
110
77
81

query I rowsort
SELECT ALL + - col1 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - 80 * col2 + + col1 AS col2 FROM tab0 AS cor0
----
-2554
-6469
17

query I rowsort
SELECT - + col1 + + col0 + 87 AS col0 FROM tab2 AS cor0
----
106
149
63

query I rowsort
SELECT - col1 + cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT ALL + + cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - + 3 * col2 + 93 + + 71 FROM tab0 AS cor0
----
-82
161
65

query I rowsort
SELECT - 96 FROM tab1, tab0 cor0
----
9 values hashing to c89b545346f99713888a7934e4caa539

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6321
SELECT + 3 + + col2 * CAST( + col0 AS SIGNED ) FROM tab1 cor0
----
165
3651
7683

skipif mysql # not compatible
query I rowsort label-6321
SELECT + 3 + + col2 * CAST ( + col0 AS INTEGER ) FROM tab1 cor0
----
165
3651
7683

query I rowsort
SELECT DISTINCT + ( col0 ) * + 45 FROM tab0 AS cor0
----
1080
1575
4005

query I rowsort
SELECT + cor0.col1 - cor0.col0 * col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL col1 + col0 + + cor0.col1 AS col2 FROM tab1 cor0
----
106
55
84

query I rowsort
SELECT DISTINCT col0 * + 85 FROM tab2 AS cor0
----
595
6630
6715

query I rowsort
SELECT ALL - - col0 + - 91 FROM tab0 AS cor0
----
-2
-56
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * - 57 col1 FROM tab0 AS cor0
----
4902
5187
5529

query I rowsort
SELECT ALL + 6 FROM tab1, tab2 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT ALL 53 + col1 * col1 * col1 AS col1 FROM tab1
----
1053
17629
2250

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + ( - col1 * + col2 ) col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT - col1 + - 31 AS col0 FROM tab1 AS cor0
----
-41
-44
-57

query I rowsort
SELECT + + col2 + + 7 AS col2 FROM tab2 AS cor0
----
33
34
45

query I rowsort
SELECT - col2 + col1 * + col1 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT + col0 + + 84 AS col1 FROM tab2 AS cor0
----
162
163
91

query I rowsort
SELECT DISTINCT - + col2 + 93 AS col2 FROM tab1 AS cor0
----
-3
36
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * 27 col2 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT + - col0 * col1 + + col2 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT col0 - - col1 AS col2 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6339
SELECT + col2 DIV tab2.col1 AS col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6339
SELECT + col2 / tab2.col1 AS col0 FROM tab2
----
0
0
2

query I rowsort
SELECT - 80 AS col0 FROM tab2
----
-80
-80
-80

query I rowsort
SELECT col1 + col0 * - col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT col2 * + 20 + 13 + + col1 FROM tab2 AS cor0
----
584
592
790

query I rowsort
SELECT DISTINCT col0 * col2 + 49 FROM tab0
----
7347
84
841

onlyif mysql # use DIV operator for integer division
query I rowsort label-6344
SELECT ( tab2.col0 ) DIV + 70 + tab2.col2 * col2 * col0 FROM tab2
----
114077
5103
52729

skipif mysql # not compatible
query I rowsort label-6344
SELECT ( tab2.col0 ) / + 70 + tab2.col2 * col2 * col0 FROM tab2
----
114077
5103
52729

onlyif mysql # use DIV operator for integer division
query I rowsort label-6345
SELECT DISTINCT + + col1 DIV - col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6345
SELECT DISTINCT + + col1 / - col2 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6346
SELECT + col2 DIV + 57 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6346
SELECT + col2 / + 57 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6347
SELECT - - col1 DIV - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-6347
SELECT - - col1 / - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 69 col2 FROM tab1 AS cor0
----
133
149
72

query I rowsort
SELECT DISTINCT + col2 + - col0 * + col1 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 cor2, tab2 AS cor3
----
3645 values hashing to 9a8c5b685ae97f053cdce34c34044cb4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6351
SELECT - CAST( + col2 AS SIGNED ) * + col1 + + 55 AS col2 FROM tab1
----
-1193
-1349
-515

skipif mysql # not compatible
query I rowsort label-6351
SELECT - CAST ( + col2 AS INTEGER ) * + col1 + + 55 AS col2 FROM tab1
----
-1193
-1349
-515

query I rowsort
SELECT + + cor0.col1 AS col2 FROM tab2, tab0 cor0, tab1, tab2 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT DISTINCT + ( + col1 ) * + cor0.col1 + - ( col2 ) AS col0 FROM tab1 AS cor0
----
43
622
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 84 col2 FROM tab1 AS cor0
----
84
84
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6355
SELECT + 13 * col0 DIV - 36 AS col2 FROM tab0
----
-12
-32
-8

skipif mysql # not compatible
query I rowsort label-6355
SELECT + 13 * col0 / - 36 AS col2 FROM tab0
----
-12
-32
-8

query I rowsort
SELECT ALL - col1 + + col2 AS col0 FROM tab2
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * cor0.col0 + 66 col1 FROM tab2 AS cor0
----
115
6150
6307

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + col1 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - 10 + col1 FROM tab1 cor0
----
0
16
3

query I rowsort
SELECT + 86 * - col2 + + col2 * + col0 AS col0 FROM tab2 AS cor0
----
-208
-2133
-266

query I rowsort
SELECT DISTINCT - + 16 * col1 AS col0 FROM tab1 AS cor0
----
-160
-208
-416

query I rowsort
SELECT DISTINCT - - ( col2 ) * 95 FROM tab0 AS cor0
----
3135
7790
95

query I rowsort
SELECT ALL + 35 * cor0.col0 + - col2 AS col0 FROM tab2 AS cor0
----
218
2704
2727

query I rowsort
SELECT + + 89 AS col0 FROM tab0 AS cor0
----
89
89
89

query I rowsort
SELECT DISTINCT + 97 * 70 FROM tab1, tab0 AS cor0
----
6790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6366
SELECT CAST( col0 AS SIGNED ) + - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-6366
SELECT CAST ( col0 AS INTEGER ) + - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6367
SELECT + + CAST( col0 AS SIGNED ) * - col0 FROM tab0 cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-6367
SELECT + + CAST ( col0 AS INTEGER ) * - col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - - cor0.col2 + col1 * col2 * col2 FROM tab0 AS cor0
----
611966
93687
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6369
SELECT ALL - col2 + col1 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6369
SELECT ALL - col2 + col1 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6370
SELECT + + col1 DIV col2 + - 92 AS col1 FROM tab1 AS cor0
----
-92
-92
-92

skipif mysql # not compatible
query I rowsort label-6370
SELECT + + col1 / col2 + - 92 AS col1 FROM tab1 AS cor0
----
-92
-92
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6371
SELECT DISTINCT col0 DIV col0 + - 41 * col2 + - 50 AS col0 FROM tab0 AS cor0
----
-1402
-3411
-90

skipif mysql # not compatible
query I rowsort label-6371
SELECT DISTINCT col0 / col0 + - 41 * col2 + - 50 AS col0 FROM tab0 AS cor0
----
-1402
-3411
-90

query I rowsort
SELECT - col2 * 53 + - col1 AS col2 FROM tab0 AS cor0
----
-150
-1835
-4437

onlyif mysql # use DIV operator for integer division
query I rowsort label-6373
SELECT + cor0.col1 DIV - col2 + - col2 * - col0 AS col0 FROM tab0 AS cor0
----
-62
7297
790

skipif mysql # not compatible
query I rowsort label-6373
SELECT + cor0.col1 / - col2 + - col2 * - col0 AS col0 FROM tab0 AS cor0
----
-62
7297
790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT + col1 + + CAST( NULL AS SIGNED ) * + 68 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6374
SELECT + col1 + + CAST ( NULL AS INTEGER ) * + 68 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab1, tab1 cor1
----
243 values hashing to 89e3b35a4a4f02d7b83645addb9dcdc3

query I rowsort
SELECT - col2 * col2 - ( col0 ) * tab1.col1 FROM tab1
----
-10256
-2994
-3889

query I rowsort
SELECT DISTINCT - col2 * col0 + col1 AS col2 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT col1 * + cor0.col1 + + col2 * col2 FROM tab2 AS cor0
----
1690
1733
4157

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6379
SELECT col2 + + CAST( col0 + + col2 AS SIGNED ) * col0 AS col1 FROM tab2 AS cor0
----
265
8138
9281

skipif mysql # not compatible
query I rowsort label-6379
SELECT col2 + + CAST ( col0 + + col2 AS INTEGER ) * col0 AS col1 FROM tab2 AS cor0
----
265
8138
9281

query I rowsort
SELECT + col0 + ( - col1 ) AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT 57 + col1 * + col1 FROM tab2 AS cor0
----
1018
346
3538

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 98 - cor0.col2 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 9b71745356abc686fe94b390c9eb46b4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6383
SELECT + 68 DIV cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 72809751a514b8ff790b0ea816423bf7

skipif mysql # not compatible
query I rowsort label-6383
SELECT + 68 / cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 72809751a514b8ff790b0ea816423bf7

query I rowsort
SELECT DISTINCT + 33 AS col2 FROM tab2, tab0 cor0
----
33

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
47

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 cor2, tab1 AS cor3
----
3645 values hashing to b3ea820890445d59f3f7464a1521d42d

query I rowsort
SELECT ALL + + 11 * 64 + - col1 * 21 AS col2 FROM tab0 AS cor0
----
-1102
-1207
-1333

query I rowsort
SELECT - + 65 FROM tab0 cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT - col2 * + col2 * col0 AS col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT 70 * col2 AS col0 FROM tab2 AS cor0
----
1820
1890
2660

query I rowsort
SELECT + col0 * col2 + cor0.col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT 67 * col0 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT 34 + col0 * cor0.col2 FROM tab2 AS cor0
----
2062
223
3036

query I rowsort
SELECT - col0 * + 26 * 19 - + col0 FROM tab0 AS cor0
----
-11880
-17325
-44055

onlyif mysql # use DIV operator for integer division
query I rowsort label-6395
SELECT ALL + col1 DIV - 30 AS col1 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6395
SELECT ALL + col1 / - 30 AS col1 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - + col1 + col1 * ( + col0 ) * + col1 AS col1 FROM tab2 AS cor0
----
22814
271459
6696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6397
SELECT col1 + - CAST( NULL AS SIGNED ) * ( col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6397
SELECT col1 + - CAST ( NULL AS INTEGER ) * ( col1 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * 24 AS col2 FROM tab1 cor0
----
240
312
624

query I rowsort
SELECT DISTINCT - 48 * col0 AS col1 FROM tab2
----
-336
-3744
-3792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6400
SELECT 92 DIV tab0.col1 FROM tab0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6400
SELECT 92 / tab0.col1 FROM tab0
----
0
1
1

query I rowsort
SELECT + 24 * col2 + - 82 FROM tab0 AS cor0
----
-58
1886
710

query I rowsort
SELECT DISTINCT + 98 + - col2 AS col1 FROM tab1 AS cor0
----
2
41
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 53 + col1 col2 FROM tab2 AS cor0
----
-22
-36
6

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col0 + col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT col1 * 26 + - col0 AS col0 FROM tab2
----
1456
363
799

query I rowsort
SELECT 72 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

onlyif mysql # use DIV operator for integer division
query I rowsort label-6407
SELECT - 36 * - tab2.col1 DIV - col1 + col0 DIV 72 AS col2 FROM tab2
----
-35
-35
-36

skipif mysql # not compatible
query I rowsort label-6407
SELECT - 36 * - tab2.col1 / - col1 + col0 / 72 AS col2 FROM tab2
----
-35
-35
-36

query I rowsort
SELECT - col1 * + col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + 74 * + cor0.col1 + - col0 AS col0 FROM tab0 AS cor0
----
6340
6645
7143

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6410
SELECT + + col2 + - col2 * + CAST( 15 AS SIGNED ) FROM tab1 AS cor0
----
-1344
-756
-798

skipif mysql # not compatible
query I rowsort label-6410
SELECT + + col2 + - col2 * + CAST ( 15 AS INTEGER ) FROM tab1 AS cor0
----
-1344
-756
-798

query I rowsort
SELECT DISTINCT + col0 * tab0.col1 - - 30 * - col0 FROM tab0
----
1344
2345
5429

onlyif mysql # use DIV operator for integer division
query I rowsort label-6412
SELECT DISTINCT + tab1.col2 * 97 - col1 DIV col2 AS col2 FROM tab1
----
5238
5529
9312

skipif mysql # not compatible
query I rowsort label-6412
SELECT DISTINCT + tab1.col2 * 97 - col1 / col2 AS col2 FROM tab1
----
5238
5529
9312

query I rowsort
SELECT ALL - col1 - col0 * 0 AS col0 FROM tab2
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6414
SELECT DISTINCT + col1 DIV col2 - 50 FROM tab0
----
-48
-49
47

skipif mysql # not compatible
query I rowsort label-6414
SELECT DISTINCT + col1 / col2 - 50 FROM tab0
----
-48
-49
47

query I rowsort
SELECT tab2.col1 + + col1 - 68 * + col2 AS col2 FROM tab2
----
-1650
-1774
-2550

query I rowsort
SELECT col0 * - 77 - tab0.col1 FROM tab0
----
-1934
-2792
-6944

query I rowsort
SELECT DISTINCT - col2 * 87 - - 38 * + col0 AS col0 FROM tab0 AS cor0
----
-1959
-3752
1243

query I rowsort
SELECT ALL 29 FROM tab1, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL + col1 + - 59 * cor0.col0 - col0 FROM tab0 cor0
----
-1354
-2003
-5249

query I rowsort
SELECT cor0.col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 63 col1 FROM tab2 AS cor0
----
63
63
63

query I rowsort
SELECT - + col2 * col1 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT col0 * + 28 + + col2 AS col2 FROM tab2 AS cor0
----
2210
223
2250

onlyif mysql # use DIV operator for integer division
query I rowsort label-6424
SELECT DISTINCT + 10 + - col1 DIV + col2 + - col0 AS col1 FROM tab1 cor0
----
-54
-70
7

skipif mysql # not compatible
query I rowsort label-6424
SELECT DISTINCT + 10 + - col1 / + col2 + - col0 AS col1 FROM tab1 cor0
----
-54
-70
7

query I rowsort
SELECT - col0 * - col2 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + ( cor0.col2 ) * + col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6427
SELECT col1 * 91 DIV col0 + + col0 AS col2 FROM tab2 AS cor0
----
146
410
98

skipif mysql # not compatible
query I rowsort label-6427
SELECT col1 * 91 / col0 + + col0 AS col2 FROM tab2 AS cor0
----
146
410
98

query I rowsort
SELECT DISTINCT - ( - col0 ) * col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT ( + col0 ) + - cor0.col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - - col2 * + col1 - + col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6431
SELECT DISTINCT + CAST( col1 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-6431
SELECT DISTINCT + CAST ( col1 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6432
SELECT DISTINCT CAST( 17 AS SIGNED ) + col2 * + col0 AS col0 FROM tab2 AS cor0
----
2045
206
3019

skipif mysql # not compatible
query I rowsort label-6432
SELECT DISTINCT CAST ( 17 AS INTEGER ) + col2 * + col0 AS col0 FROM tab2 AS cor0
----
2045
206
3019

query I rowsort
SELECT - - col0 * - cor0.col0 + + cor0.col1 * + col0 AS col0 FROM tab0 AS cor0
----
1488
178
2170

query I rowsort
SELECT DISTINCT 16 * + col0 AS col0 FROM tab0 AS cor0
----
1424
384
560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6435
SELECT ALL + CAST( NULL AS SIGNED ) * col2 + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6435
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6436
SELECT + + 1 + 55 DIV + cor0.col1 FROM tab1 AS cor0
----
3
5
6

skipif mysql # not compatible
query I rowsort label-6436
SELECT + + 1 + 55 / + cor0.col1 FROM tab1 AS cor0
----
3
5
6

query I rowsort
SELECT - col0 * 86 + col0 - - col2 FROM tab2 AS cor0
----
-568
-6604
-6677

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 84 col0 FROM tab0 AS cor0
----
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6439
SELECT - ( - col1 ) + - col2 DIV + col2 FROM tab0 cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6439
SELECT - ( - col1 ) + - col2 / + col2 FROM tab0 cor0
----
85
90
96

query I rowsort
SELECT DISTINCT col1 + + 94 AS col2 FROM tab2 AS cor0
----
111
125
153

query I rowsort
SELECT 80 + - 61 FROM tab1 AS cor0
----
19
19
19

query I rowsort
SELECT - ( col2 ) + col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col1 col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - col2 + col2 * + col0 AS col2 FROM tab2
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6446
SELECT ALL 60 DIV + tab0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

skipif mysql # not compatible
query I rowsort label-6446
SELECT ALL 60 / + tab0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 833b749ae5e53c39fb5c10fe39c8013c

query I rowsort
SELECT 42 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT - ( col0 ) + col1 FROM tab2 cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + col1 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - col1 * + cor0.col2 * - col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6451
SELECT ALL + CAST( NULL AS SIGNED ) / - col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6451
SELECT ALL + CAST ( NULL AS INTEGER ) / - col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + col2 * col1 AS col0 FROM tab2 AS cor0
----
1475
629
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL cor0.col2 + cor0.col2 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT ALL - 17 * cor0.col0 - + col1 FROM tab1 AS cor0
----
-1098
-1373
-77

query I rowsort
SELECT + ( - col2 ) AS col2 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT 82 * - 99 FROM tab2
----
-8118
-8118
-8118

query I rowsort
SELECT col2 + ( + col2 ) * col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT DISTINCT 49 * 39 + col1 FROM tab0
----
1997
2002
2008

query I rowsort
SELECT ALL - col0 + tab1.col2 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT - - col1 * cor0.col1 + - ( col2 + - col1 * + ( col1 ) ) FROM tab1 AS cor0
----
1298
143
242

onlyif mysql # use DIV operator for integer division
query I rowsort label-6462
SELECT - cor0.col2 + - cor0.col0 DIV col2 AS col1 FROM tab0 AS cor0
----
-33
-36
-83

skipif mysql # not compatible
query I rowsort label-6462
SELECT - cor0.col2 + - cor0.col0 / col2 AS col1 FROM tab0 AS cor0
----
-33
-36
-83

query I rowsort
SELECT DISTINCT col0 * - ( col1 ) AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col0 * 99 AS col0 FROM tab2 AS cor0
----
693
7722
7821

query I rowsort
SELECT cor0.col0 * col1 * - 23 AS col1 FROM tab1 AS cor0
----
-14720
-1794
-23920

query I rowsort
SELECT + cor0.col1 * 20 AS col1 FROM tab0 AS cor0
----
1720
1820
1940

onlyif mysql # use DIV operator for integer division
query I rowsort label-6467
SELECT ALL col2 DIV col2 + - col2 + - col2 * 19 FROM tab1 AS cor0
----
-1079
-1139
-1919

skipif mysql # not compatible
query I rowsort label-6467
SELECT ALL col2 / col2 + - col2 + - col2 * 19 FROM tab1 AS cor0
----
-1079
-1139
-1919

query I rowsort
SELECT ALL - - col1 + - col0 * - 1 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6469
SELECT - cor0.col0 DIV 66 AS col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6469
SELECT - cor0.col0 / 66 AS col0 FROM tab0 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6470
SELECT DISTINCT + col1 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-6470
SELECT DISTINCT + col1 / cor0.col0 AS col1 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT ALL - - cor0.col1 + + 35 AS col2 FROM tab0 AS cor0
----
121
126
132

query I rowsort
SELECT + - 47 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

query I rowsort
SELECT - col0 + + ( col1 ) FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT col1 + col0 * + col0 AS col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT col2 + 98 * col1 FROM tab2 cor0
----
1704
3065
5808

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6476
SELECT CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-6476
SELECT CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

onlyif mysql # use DIV operator for integer division
query I rowsort label-6477
SELECT - + cor0.col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-6477
SELECT - + cor0.col2 / + col1 AS col2 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT 43 * - cor0.col0 * + cor0.col1 + + col2 FROM tab1 AS cor0
----
-27463
-3300
-44624

query I rowsort
SELECT + cor0.col0 * - col0 * col2 + + col0 FROM tab1 AS cor0
----
-233408
-483
-614320

query I rowsort
SELECT - 37 + - col0 * + col2 * - col2 AS col1 FROM tab0 cor0
----
-2
26099
598399

onlyif mysql # use DIV operator for integer division
query I rowsort label-6481
SELECT 12 + 94 DIV - col2 FROM tab1
----
11
11
12

skipif mysql # not compatible
query I rowsort label-6481
SELECT 12 + 94 / - col2 FROM tab1
----
11
11
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-6482
SELECT ALL 39 DIV col2 col0 FROM tab0
----
0
1
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6482
SELECT ALL 39 / col2 col0 FROM tab0
----
0
1
39

query I rowsort
SELECT 43 + col2 * cor0.col1 FROM tab2 AS cor0
----
1577
689
880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 col2 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT - + col2 + col1 * col2 FROM tab1 AS cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col1 * + col0 + col2 * + col1 col2 FROM tab0
----
-3263
-548
798

query I rowsort
SELECT + + col1 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + ( + cor0.col1 ) * - cor0.col0 - - col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + cor0.col1 * - cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c6f4b0b1d1f7796b05493e23d40b0b75

query I rowsort
SELECT col2 * + 42 + + col1 + col0 AS col2 FROM tab1
----
2297
2468
4125

query I rowsort
SELECT ALL - col2 + col1 * col0 AS col1 FROM tab0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6492
SELECT CAST( NULL AS SIGNED ) * 96 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6492
SELECT CAST ( NULL AS INTEGER ) * 96 AS col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6493
SELECT CAST( NULL AS SIGNED ) / col1 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6493
SELECT CAST ( NULL AS INTEGER ) / col1 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + tab1.col2 * + ( col2 ) AS col0 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ( + col0 ) * col0 * col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT + col1 * col0 + - col0 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6497
SELECT DISTINCT + CAST( ( col0 ) AS SIGNED ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-6497
SELECT DISTINCT + CAST ( ( col0 ) AS INTEGER ) * + col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + ( 18 ) * - col2 AS col0 FROM tab1 AS cor0
----
-1026
-1728
-972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col0 * col0 * col0 col0 FROM tab2 cor0
----
-336
-474474
-492960

query I rowsort
SELECT col1 * + cor0.col0 - - col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + col0 - col1 * col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT + - col2 + + cor0.col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL tab0.col0 FROM tab1, tab2 cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - col1 + col2 * - col2 AS col2 FROM tab1
----
-2942
-3259
-9229

query I rowsort
SELECT ALL tab2.col2 * col2 - col2 * + col1 FROM tab2
----
-108
-858
798

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL NOT BETWEEN ( col2 + - col0 * - col1 ) AND NULL
----

query I rowsort
SELECT col2 * + col0 + - col1 AS col0 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT + col1 - col2 * + tab2.col1 AS col2 FROM tab2
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6509
SELECT ALL - col0 + - col0 + col2 DIV col1 FROM tab1
----
-123
-153
-4

skipif mysql # not compatible
query I rowsort label-6509
SELECT ALL - col0 + - col0 + col2 / col1 FROM tab1
----
-123
-153
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6510
SELECT DISTINCT + tab0.col2 + - col0 DIV + col2 + col2 FROM tab0
----
-33
163
66

skipif mysql # not compatible
query I rowsort label-6510
SELECT DISTINCT + tab0.col2 + - col0 / + col2 + col2 FROM tab0
----
-33
163
66

query I rowsort
SELECT + col0 + tab1.col1 AS col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6512
SELECT DISTINCT col0 + + tab2.col0 * + col0 DIV + col0 + - col0 * + col1 AS col0 FROM tab2
----
-1185
-203
-4446

skipif mysql # not compatible
query I rowsort label-6512
SELECT DISTINCT col0 + + tab2.col0 * + col0 / + col0 + - col0 * + col1 AS col0 FROM tab2
----
-1185
-203
-4446

onlyif mysql # use DIV operator for integer division
query I rowsort label-6513
SELECT col0 * col0 DIV col1 + col2 AS col2 FROM tab2 AS cor0
----
129
28
405

skipif mysql # not compatible
query I rowsort label-6513
SELECT col0 * col0 / col1 + col2 AS col2 FROM tab2 AS cor0
----
129
28
405

query I rowsort
SELECT ALL - col0 + - col2 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT ALL col0 + + col1 * col2 * + col2 FROM tab0 AS cor0
----
132
611973
93678

onlyif mysql # use DIV operator for integer division
query I rowsort label-6516
SELECT col2 * col1 + - col0 DIV col2 AS col0 FROM tab0 AS cor0
----
2838
62
7461

skipif mysql # not compatible
query I rowsort label-6516
SELECT col2 * col1 + - col0 / col2 AS col0 FROM tab0 AS cor0
----
2838
62
7461

query I rowsort
SELECT ALL + col0 * - col2 * - col1 FROM tab2
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col0 FROM tab0, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab1, tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT col0 * col2 - + cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 - + cor0.col0 col2 FROM tab2 cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 * tab1.col0 col2 FROM tab1
----
-262144
-27
-512000

query I rowsort
SELECT DISTINCT + col0 * col1 * col2 + + col1 + col2 FROM tab1 AS cor0
----
36547
4292
99949

query I rowsort
SELECT DISTINCT + + col1 + col0 - - col1 AS col0 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT ALL + col2 * col2 * col0 - col2 AS col2 FROM tab2 cor0
----
114038
5076
52702

query I rowsort
SELECT ALL - + col1 * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-6527
SELECT ALL - col0 DIV + col0 + + col1 FROM tab0 cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-6527
SELECT ALL - col0 / + col0 + + col1 FROM tab0 cor0
----
85
90
96

query I rowsort
SELECT + col1 * + 62 + - ( col0 ) AS col1 FROM tab2 AS cor0
----
1915
3580
975

query I rowsort
SELECT - col2 + col1 * col2 + - cor0.col2 FROM tab1 AS cor0
----
1056
1296
456

query I rowsort
SELECT ALL - - col0 * 24 AS col1 FROM tab0 AS cor0
----
2136
576
840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 * ( + cor0.col2 ) col2 FROM tab2 cor0
----
17576
19683
54872

query I rowsort
SELECT cor0.col1 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT - col0 * 78 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT col0 + col0 + + tab1.col1 * - 22 AS col0 FROM tab1
----
-126
-566
-92

query I rowsort
SELECT DISTINCT cor0.col2 * 53 FROM tab1 cor0
----
2862
3021
5088

query I rowsort
SELECT + col2 * - col2 + - col0 + + col2 FROM tab0 cor0
----
-1080
-35
-6731

query I rowsort
SELECT DISTINCT col2 + 57 * col0 + - col1 AS col0 FROM tab2
----
395
4413
4524

query I rowsort
SELECT - col0 + - ( 18 ) FROM tab0
----
-107
-42
-53

query I rowsort
SELECT - 57 * + col1 FROM tab1 AS cor0
----
-1482
-570
-741

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6540
SELECT DISTINCT + col0 + - CAST( + col0 AS SIGNED ) AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6540
SELECT DISTINCT + col0 + - CAST ( + col0 AS INTEGER ) AS col2 FROM tab2
----
0

query I rowsort
SELECT DISTINCT col0 * + 46 + - col0 * col1 + col0 * col0 FROM tab2
----
154
5070
8532

query I rowsort
SELECT DISTINCT tab0.col2 + - col0 * - col2 * + tab0.col2 FROM tab0
----
26169
36
598518

query I rowsort
SELECT ALL + col2 + + col0 + ( - col2 ) FROM tab0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6544
SELECT ALL - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6544
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * col2 + 62 * + col2 + - 76 FROM tab2
----
1787
3564
5282

onlyif mysql # use DIV operator for integer division
query I rowsort label-6546
SELECT DISTINCT + col2 DIV col1 + + col1 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6546
SELECT DISTINCT + col2 / col1 + + col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + 0 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT ( + 54 ) AS col0 FROM tab1
----
54

query I rowsort
SELECT DISTINCT - - ( col1 ) + - col1 * + col1 AS col2 FROM tab2 cor0
----
-272
-3422
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-6550
SELECT ALL + col2 + - col2 DIV ( col0 * + cor0.col0 ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6550
SELECT ALL + col2 + - col2 / ( col0 * + cor0.col0 ) FROM tab2 AS cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6551
SELECT ALL + - col2 + col1 * CAST( ( col1 ) AS SIGNED ) * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-13616
-2082
-6457

skipif mysql # not compatible
query I rowsort label-6551
SELECT ALL + - col2 + col1 * CAST ( ( col1 ) AS INTEGER ) * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-13616
-2082
-6457

onlyif mysql # use DIV operator for integer division
query I rowsort label-6552
SELECT DISTINCT - cor0.col0 * col0 DIV 53 col2 FROM tab0 AS cor0
----
-10
-149
-23

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6552
SELECT DISTINCT - cor0.col0 * col0 / 53 col2 FROM tab0 AS cor0
----
-10
-149
-23

query I rowsort
SELECT ALL - + col2 + - col2 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT + 43 * - col1 AS col2 FROM tab2 AS cor0
----
-1333
-2537
-731

query I rowsort
SELECT DISTINCT - 73 * + col1 + + ( col1 ) AS col0 FROM tab0 AS cor0
----
-6192
-6552
-6984

query I rowsort
SELECT col2 * - cor0.col1 * + col2 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL + 2 AS col1 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT - + ( col1 ) * + col0 + + col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - + ( - cor0.col1 ) * + col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + + 11 AS col1 FROM tab1 AS cor0
----
11
11
11

query I rowsort
SELECT + ( col1 ) * col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - 56 AS col1 FROM tab0 AS cor0
----
-56
-56
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6563
SELECT col1 + - col2 DIV 38 AS col0 FROM tab2 AS cor0
----
16
31
59

skipif mysql # not compatible
query I rowsort label-6563
SELECT col1 + - col2 / 38 AS col0 FROM tab2 AS cor0
----
16
31
59

query I rowsort
SELECT DISTINCT + - ( col0 ) * - col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6565
SELECT DISTINCT + + col1 DIV col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6565
SELECT DISTINCT + + col1 / col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT - col1 * + col1 * col2 FROM tab0 cor0
----
-244068
-679042
-9409

query I rowsort
SELECT - tab1.col1 + col2 * ( - col0 ) FROM tab1
----
-188
-3658
-7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 - + cor0.col2 col0 FROM tab2 AS cor0
----
-327
-3507
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-6569
SELECT DISTINCT + col1 * cor0.col2 * + col2 + col0 DIV + col2 + col0 AS col0 FROM tab0 AS cor0
----
167
611974
93678

skipif mysql # not compatible
query I rowsort label-6569
SELECT DISTINCT + col1 * cor0.col2 * + col2 + col0 / + col2 + col0 AS col0 FROM tab0 AS cor0
----
167
611974
93678

onlyif mysql # use DIV operator for integer division
query I rowsort label-6570
SELECT ALL - col0 DIV + 57 - col2 FROM tab0 cor0
----
-1
-33
-83

skipif mysql # not compatible
query I rowsort label-6570
SELECT ALL - col0 / + 57 - col2 FROM tab0 cor0
----
-1
-33
-83

query I rowsort
SELECT ALL + - cor0.col0 * 77 - col2 * + col0 AS col0 FROM tab2 AS cor0
----
-728
-8034
-9085

onlyif mysql # use DIV operator for integer division
query I rowsort label-6572
SELECT DISTINCT + cor0.col2 + + CAST( + col2 AS SIGNED ) DIV col1 col1 FROM tab2 AS cor0
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6572
SELECT DISTINCT + cor0.col2 + + CAST ( + col2 AS INTEGER ) / col1 col1 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT cor0.col0 + + col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT DISTINCT - - 84 AS col2 FROM tab0 AS cor0
----
84

query I rowsort
SELECT ALL + 1 + 61 * - col2 AS col2 FROM tab1 AS cor0
----
-3293
-3476
-5855

query I rowsort
SELECT ALL 80 - ( col1 ) FROM tab1 AS cor0
----
54
67
70

query I rowsort
SELECT + cor0.col1 + - col1 * - col2 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6578
SELECT DISTINCT + col1 DIV - col1 + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-6578
SELECT DISTINCT + col1 / - col1 + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT DISTINCT ( + col0 ) * col1 AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col0 + - col1 * cor0.col0 FROM tab0 cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * col2 col0 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - + ( col1 ) * - col2 + + 12 * - ( col2 ) + col2 FROM tab1 AS cor0
----
-57
192
810

query I rowsort
SELECT - col2 + + 58 * + col1 FROM tab2 cor0
----
1771
3396
948

query I rowsort
SELECT ALL col1 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - col2 - 45 * col2 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT - cor0.col1 + col2 * - col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL + col2 + + cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT col1 + 79 * + col1 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT + col0 * - col0 * + col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT + 12 * col1 - col0 AS col2 FROM tab1 AS cor0
----
309
56
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6591
SELECT ALL col2 DIV - cor0.col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-6591
SELECT ALL col2 / - cor0.col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT - 13 + + tab1.col2 * + col2 FROM tab1
----
2903
3236
9203

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 51 AS REAL ) AS col1 FROM tab0
----
51
51
51

query I rowsort
SELECT DISTINCT 17 FROM tab1, tab1 AS cor0
----
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6595
SELECT ALL + CAST( col2 AS SIGNED ) * - col2 AS col1 FROM tab1
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-6595
SELECT ALL + CAST ( col2 AS INTEGER ) * - col2 AS col1 FROM tab1
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6596
SELECT - 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-6596
SELECT - col0 / - col0 col1 FROM tab0
----
1
1
1

query I rowsort
SELECT + + col1 * - col0 + + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 AS REAL ) * - col2 + col1 AS col2 FROM tab2 AS cor0
----
-1427
-617
-698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6599
SELECT ALL - CAST( NULL AS SIGNED ) - - col0 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6599
SELECT ALL - CAST ( NULL AS INTEGER ) - - col0 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( - col0 ) - - col0 AS col1 FROM tab1
----
128
160
6

query I rowsort
SELECT - 59 + + col1 FROM tab0 AS cor0
----
27
32
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 63 + + cor0.col2 col2 FROM tab0 AS cor0
----
145
64
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6603
SELECT col1 DIV col2 + - 72 FROM tab0 AS cor0
----
-70
-71
25

skipif mysql # not compatible
query I rowsort label-6603
SELECT col1 / col2 + - 72 FROM tab0 AS cor0
----
-70
-71
25

query I rowsort
SELECT + 3 FROM tab1 cor0
----
3
3
3

query I rowsort
SELECT ALL 76 + col1 FROM tab0 AS cor0
----
162
167
173

query I rowsort
SELECT 43 + col2 FROM tab1 cor0
----
100
139
97

query I rowsort
SELECT + col2 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col2 + col2 * + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT + col1 + + col0 * + col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT + - 50 * col0 + col0 FROM tab1 AS cor0
----
-147
-3136
-3920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6611
SELECT ALL 65 DIV col2 FROM tab1 cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6611
SELECT ALL 65 / col2 FROM tab1 cor0
----
0
1
1

query I rowsort
SELECT col0 * ( ( cor0.col0 ) ) + + ( col0 ) AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT col1 * + col1 + 4 * - col1 AS col2 FROM tab1
----
117
572
60

query I rowsort
SELECT - - cor0.col2 + + 49 FROM tab0 AS cor0
----
131
50
82

query I rowsort
SELECT + + 98 - col0 AS col1 FROM tab2 AS cor0
----
19
20
91

query I rowsort
SELECT - - 82 FROM tab2, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 660751b3166f5cb8964b7ef659605795

query I rowsort
SELECT + col1 * + col2 * + cor0.col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT + - cor0.col1 * col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + - ( + col2 ) * - col1 + 60 * - col2 FROM tab1 AS cor0
----
-1836
-2850
-4512

query I rowsort
SELECT DISTINCT - col2 + - cor0.col0 * - col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6621
SELECT - - 67 DIV col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6621
SELECT - - 67 / col0 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT + 77 * - col0 AS col1 FROM tab1 AS cor0
----
-231
-4928
-6160

query I rowsort
SELECT - col2 * - ( col0 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT cor0.col1 + 99 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to eae96f4b5fee6a8316f3a2fa4ca5ce65

query I rowsort
SELECT DISTINCT col0 * 30 AS col0 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT DISTINCT + + ( + ( - col2 ) ) * col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT col1 + cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + 54 * 68 FROM tab1 AS cor0
----
3672
3672
3672

query I rowsort
SELECT ALL - 87 * - 71 FROM tab1 cor0
----
6177
6177
6177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6630
SELECT CAST( NULL AS SIGNED ) * 45 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6630
SELECT CAST ( NULL AS INTEGER ) * 45 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 60 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT DISTINCT + col1 * 87 * - col0 FROM tab0
----
-179568
-295365
-704613

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6633
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab2 cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6633
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab2 cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6634
SELECT DISTINCT CAST( NULL AS DECIMAL ) AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6634
SELECT DISTINCT CAST ( NULL AS REAL ) AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 col0 FROM tab0 AS cor0
----
20
20
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6636
SELECT + CAST( NULL AS SIGNED ) * col0 + col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6636
SELECT + CAST ( NULL AS INTEGER ) * col0 + col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 42 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT ALL + - col1 * col0 * - col1 + + cor0.col2 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT + col0 * - 68 + - cor0.col2 FROM tab0 AS cor0
----
-1665
-2381
-6134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + col2 col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL col0 * - col0 + + col1 FROM tab0 cor0
----
-1128
-490
-7830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col1 * - tab1.col0 col1 FROM tab1
----
1120
704
81

query I rowsort
SELECT col1 - + 63 FROM tab0
----
23
28
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6644
SELECT ALL + 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-6644
SELECT ALL + col0 / + col1 col0 FROM tab1
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6645
SELECT ALL - tab2.col1 DIV col0 AS col1 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-6645
SELECT ALL - tab2.col1 / col0 AS col1 FROM tab2
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 5a5d45989dcc6a06d9ee5a08945518f9

query I rowsort
SELECT + col2 * 86 * col1 FROM tab1 AS cor0
----
107328
120744
49020

query I rowsort
SELECT - 10 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to bb7f754a7a056e665155ed52a63f5bc0

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 cor0.col0 + - col0 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + - ( + cor0.col0 ) + col1 + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1315
-1381
-624

query I rowsort
SELECT + 73 * col1 FROM tab0 AS cor0
----
6278
6643
7081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + - col0 * 8 col0 FROM tab2 AS cor0
----
-25
-565
-615

query I rowsort
SELECT DISTINCT + col2 + - cor0.col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + col0 + col2 + cor0.col0 * - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-177
-40839
-83024

onlyif mysql # use DIV operator for integer division
query I rowsort label-6656
SELECT DISTINCT - 19 DIV + col2 FROM tab0 AS cor0
----
-19
0

skipif mysql # not compatible
query I rowsort label-6656
SELECT DISTINCT - 19 / + col2 FROM tab0 AS cor0
----
-19
0

query I rowsort
SELECT ALL - 20 + cor0.col1 AS col1 FROM tab0 AS cor0
----
66
71
77

query I rowsort
SELECT - + col1 + + ( 71 ) * + col2 AS col2 FROM tab0 AS cor0
----
-26
2257
5731

query I rowsort
SELECT DISTINCT + - col1 * col0 * - 32 + col0 AS col1 FROM tab0 AS cor0
----
108675
259257
66072

query I rowsort
SELECT ALL - + col2 * col0 + - 53 * - col0 FROM tab1 AS cor0
----
-256
-3
-3440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6661
SELECT - - col1 + + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-6661
SELECT - - col1 + + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 43 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT - col1 * + 82 FROM tab1 cor0
----
-1066
-2132
-820

onlyif mysql # use DIV operator for integer division
query I rowsort label-6664
SELECT - - col0 DIV + col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6664
SELECT - - col0 / + col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT col2 + cor0.col2 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT DISTINCT ( col2 * col1 ) AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 92 * - 66 FROM tab2 AS cor0
----
6072

query I rowsort
SELECT ( - 32 ) - cor0.col0 * 64 FROM tab0, tab1 AS cor0
----
9 values hashing to ba05918d355ee68bc4edc6f844604a64

query I rowsort
SELECT DISTINCT - col2 + 54 FROM tab0 AS cor0
----
-28
21
53

query I rowsort
SELECT + 52 * - col1 + + col1 + col2 AS col0 FROM tab2 AS cor0
----
-1554
-2983
-829

query I rowsort
SELECT DISTINCT ( + col2 ) + col2 * 86 FROM tab1 AS cor0
----
4698
4959
8352

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6672
SELECT ALL - + CAST( NULL AS DECIMAL ) - col0 * + col1 * - col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6672
SELECT ALL - + CAST ( NULL AS REAL ) - col0 * + col1 * - col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( + 17 ) AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 39 col1 FROM tab1
----
39
39
39

query I rowsort
SELECT DISTINCT + - col1 * cor0.col1 - - ( - col0 ) * col2 AS col1 FROM tab2 AS cor0
----
-1150
-3291
-5509

onlyif mysql # use DIV operator for integer division
query I rowsort label-6676
SELECT DISTINCT - - col1 DIV + col2 - ( 60 * - col0 ) col1 FROM tab0 cor0
----
1442
2197
5341

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6676
SELECT DISTINCT - - col1 / + col2 - ( 60 * - col0 ) col1 FROM tab0 cor0
----
1442
2197
5341

query I rowsort
SELECT 19 + + col1 * col1 * 35 AS col2 FROM tab2 AS cor0
----
10134
121854
33654

query I rowsort
SELECT ALL + + cor0.col0 + - col1 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + - 17 AS col2 FROM tab1 cor0
----
-17
-17
-17

query I rowsort
SELECT ALL 35 + col2 FROM tab0 AS cor0
----
117
36
68

query I rowsort
SELECT ALL - - 61 + - 88 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 0259a67676b131a4843853be4811b775

query I rowsort
SELECT - + 17 * col1 * ( + col1 ) + col1 * col0 FROM tab1 AS cor0
----
-1060
-11414
-1833

query I rowsort
SELECT col2 + col1 * 0 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6684
SELECT DISTINCT cor0.col1 + + 13 DIV - 40 AS col2 FROM tab2, tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6684
SELECT DISTINCT cor0.col1 + + 13 / - 40 AS col2 FROM tab2, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - tab0.col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 4 col2 FROM tab0
----
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6687
SELECT DISTINCT + col2 DIV + tab0.col0 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-6687
SELECT DISTINCT + col2 / + tab0.col0 FROM tab0
----
0
1

query I rowsort
SELECT DISTINCT col2 * tab1.col0 * + col2 AS col1 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT - + 53 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 2876418587c77a182d88db2907b0a51a

query I rowsort
SELECT ALL - - ( col2 ) + + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6691
SELECT ALL + col2 DIV tab1.col2 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6691
SELECT ALL + col2 / tab1.col2 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT col1 * - 22 + + col2 FROM tab2
----
-1272
-336
-655

query I rowsort
SELECT + col2 - + cor0.col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col0 - ( + col0 ) FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6695
SELECT + col1 + - col1 DIV - col0 AS col1 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-6695
SELECT + col1 + - col1 / - col0 AS col1 FROM tab1
----
10
13
34

query I rowsort
SELECT + - col0 + - ( - col2 ) * - col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT - col0 * 81 * - col2 - col0 AS col0 FROM tab0 AS cor0
----
2800
591049
64128

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + - CAST ( + col2 AS REAL ) AS col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT col2 + 22 + + col1 AS col0 FROM tab2
----
107
77
80

query I rowsort
SELECT DISTINCT + - ( col0 ) + + col0 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL 71 + - col0 AS col2 FROM tab2 AS cor0
----
-7
-8
64

query I rowsort
SELECT DISTINCT - col0 * 91 FROM tab0 cor0
----
-2184
-3185
-8099

query I rowsort
SELECT + col2 * - 22 + col2 AS col0 FROM tab1 cor0
----
-1134
-1197
-2016

onlyif mysql # use DIV operator for integer division
query I rowsort label-6704
SELECT ALL + col0 * + col0 DIV + col0 + + 13 AS col1 FROM tab1 AS cor0
----
16
77
93

skipif mysql # not compatible
query I rowsort label-6704
SELECT ALL + col0 * + col0 / + col0 + + 13 AS col1 FROM tab1 AS cor0
----
16
77
93

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0 CROSS JOIN tab0, tab1, tab2 AS cor1
----
3645 values hashing to b34c9987c389223e07378cde8a36e94f

query I rowsort
SELECT ( - col2 + + col0 ) * + 85 FROM tab2
----
-1700
3485
4420

onlyif mysql # use DIV operator for integer division
query I rowsort label-6707
SELECT - - 17 DIV - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6707
SELECT - - 17 / - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * - col1 + cor0.col1 * - col1 + - cor0.col2 * + col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + - ( col0 ) + col1 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT + 58 * - col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT + col0 + ( col2 * - 7 ) AS col0 FROM tab0 AS cor0
----
-207
-485
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col0 + - col0 col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + col1 * 24 FROM tab2 AS cor0
----
1416
408
744

query I rowsort
SELECT DISTINCT 86 AS col2 FROM tab2
----
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6715
SELECT + - col1 - + CAST( - col2 * - col2 AS SIGNED ) FROM tab0 AS cor0
----
-1175
-6815
-98

skipif mysql # not compatible
query I rowsort label-6715
SELECT + - col1 - + CAST ( - col2 * - col2 AS INTEGER ) FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT col1 - col1 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + cor0.col2 * + 70 + - ( + col1 * col2 ) FROM tab0 AS cor0
----
-1722
-27
-528

query I rowsort
SELECT col1 + col0 * + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - col0 + col0 + 80 FROM tab1 AS cor0
----
80

query I rowsort
SELECT DISTINCT 35 FROM tab2, tab0, tab0 AS cor0
----
35

query I rowsort
SELECT ( - 20 ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query I rowsort
SELECT - col2 - + ( col2 ) FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT - + col0 - + col0 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT - - col1 + col2 + col1 AS col2 FROM tab1 AS cor0
----
106
122
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * + cor0.col2 col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT col2 + - ( col2 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + ( + col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT 62 + + 6 FROM tab2 AS cor0
----
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 75 * + 15 col0 FROM tab1 AS cor0
----
1125
1125
1125

onlyif mysql # use DIV operator for integer division
query I rowsort label-6730
SELECT ALL 11 DIV col0 - col1 FROM tab2 AS cor0
----
-17
-30
-59

skipif mysql # not compatible
query I rowsort label-6730
SELECT ALL 11 / col0 - col1 FROM tab2 AS cor0
----
-17
-30
-59

query I rowsort
SELECT ALL + col1 * - col1 + cor0.col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT ( - 50 ) FROM tab1 AS cor0
----
-50
-50
-50

query I rowsort
SELECT - 54 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

query I rowsort
SELECT 75 AS col2 FROM tab2 AS cor0
----
75
75
75

query I rowsort
SELECT ALL cor1.col1 + 88 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 04c32dfeb6584e905d02ba83a8cad72e

query I rowsort
SELECT ALL - - col0 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - 57 * - col2 AS col2 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT + ( + col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + + col2 * col1 * 36 FROM tab2 cor0
----
23256
30132
55224

query I rowsort
SELECT DISTINCT - col1 + - 11 * - col2 FROM tab2 AS cor0
----
227
266
401

query I rowsort
SELECT - col2 * + 22 FROM tab2 cor0
----
-572
-594
-836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 81 col0 FROM tab2 cor0
----
-2106
-2187
-3078

query I rowsort
SELECT DISTINCT - col1 + + 36 * col1 FROM tab1 cor0
----
350
455
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-6744
SELECT ALL cor0.col1 DIV col2 + col1 FROM tab0 cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-6744
SELECT ALL cor0.col1 / col2 + col1 FROM tab0 cor0
----
194
88
92

query I rowsort
SELECT ALL + + 79 + + 13 FROM tab1 AS cor0
----
92
92
92

query I rowsort
SELECT ALL + col0 * + col1 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT + 45 + + col1 + col1 FROM tab2 AS cor0
----
107
163
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 6 ) col2 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT ALL col1 + - 14 * - col2 AS col1 FROM tab0 cor0
----
111
1239
548

query I rowsort
SELECT ALL + ( + col0 ) * - col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 48 * - 23 AS col2 FROM tab2
----
-1104
-1104
-1104

onlyif mysql # use DIV operator for integer division
query I rowsort label-6752
SELECT DISTINCT - col0 DIV + col0 AS col1 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-6752
SELECT DISTINCT - col0 / + col0 AS col1 FROM tab1
----
-1

query I rowsort
SELECT ALL - - col0 + + col2 * + col2 * col1 AS col2 FROM tab2 AS cor0
----
22606
24627
39962

onlyif mysql # use DIV operator for integer division
query I rowsort label-6754
SELECT 91 + col1 DIV + 42 AS col0 FROM tab1 AS cor0
----
91
91
91

skipif mysql # not compatible
query I rowsort label-6754
SELECT 91 + col1 / + 42 AS col0 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT 17 + 24 AS col1 FROM tab2
----
41
41
41

query I rowsort
SELECT ALL col1 * - tab1.col2 + col0 AS col1 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT - 43 * - col0 + tab2.col2 FROM tab2
----
328
3380
3435

query I rowsort
SELECT 27 - - col2 FROM tab1
----
123
81
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6759
SELECT ALL + CAST( NULL AS SIGNED ) * - 77 + + tab0.col0 + + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6759
SELECT ALL + CAST ( NULL AS INTEGER ) * - 77 + + tab0.col0 + + col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + 85 + col2 FROM tab0 AS cor0
----
183
204
258

onlyif mysql # use DIV operator for integer division
query I rowsort label-6761
SELECT - col1 + col1 DIV col0 AS col2 FROM tab2 cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-6761
SELECT - col1 + col1 / col0 AS col2 FROM tab2 cor0
----
-17
-27
-59

query I rowsort
SELECT ALL + col1 - + ( - col2 + col2 ) FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6763
SELECT DISTINCT col1 + cor0.col2 * col1 / col0 + + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6763
SELECT DISTINCT col1 + cor0.col2 * col1 / col0 + + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 + col1 * col0 * + cor0.col1 FROM tab0 cor0
----
177590
329412
737100

query I rowsort
SELECT col0 + 99 AS col1 FROM tab0
----
123
134
188

query I rowsort
SELECT DISTINCT - 70 AS col0 FROM tab2, tab0 AS cor0
----
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6767
SELECT ALL + CAST( col0 AS SIGNED ) * col2 + + col1 FROM tab0 cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-6767
SELECT ALL + CAST ( col0 AS INTEGER ) * col2 + + col1 FROM tab0 cor0
----
132
7389
878

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6768
SELECT DISTINCT - - CAST( NULL AS SIGNED ) / - col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6768
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) / - col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col0 + + 91 FROM tab1 AS cor0
----
11
27
88

query I rowsort
SELECT DISTINCT + col1 - + 66 FROM tab0 AS cor0
----
20
25
31

query I rowsort
SELECT + 32 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT DISTINCT - ( 56 * col0 ) AS col0 FROM tab0
----
-1344
-1960
-4984

query I rowsort
SELECT DISTINCT + + col2 * - col2 + + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT + 86 + col2 FROM tab0 AS cor0
----
119
168
87

query I rowsort
SELECT DISTINCT cor1.col0 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2 cor2
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6776
SELECT 53 DIV - 98 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6776
SELECT 53 / - 98 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6777
SELECT + ( col1 ) DIV + col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6777
SELECT + ( col1 ) / + col1 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6778
SELECT ALL + col1 + col0 + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6778
SELECT ALL + col1 + col0 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-6780
SELECT DISTINCT - col0 + - col1 DIV col1 FROM tab2
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-6780
SELECT DISTINCT - col0 + - col1 / col1 FROM tab2
----
-79
-8
-80

query I rowsort
SELECT ALL + 76 * col2 * + col1 + col1 + col2 * - col0 FROM tab1 cor0
----
106568
39682
87181

query I rowsort
SELECT DISTINCT 34 * + col0 * ( + 44 ) - col0 FROM tab1 AS cor0
----
119600
4485
95680

query I rowsort
SELECT DISTINCT - + cor0.col0 + + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ( + 90 ) FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT - + cor0.col2 * - col1 + col1 * col0 AS col0 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT - - col0 - - cor0.col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + col0 * + col0 + - 28 * 83 AS col2 FROM tab2 AS cor0
----
-2275
3760
3917

query I rowsort
SELECT ALL + col2 + + col0 * + col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL col2 + ( + 84 ) * + col0 AS col1 FROM tab2 AS cor0
----
615
6578
6674

query I rowsort
SELECT DISTINCT - col1 * - 94 AS col1 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT DISTINCT - col1 + col2 * ( col1 ) FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT + + col0 + + 15 FROM tab2 AS cor0
----
22
93
94

query I rowsort
SELECT ALL col1 * ( + 10 ) + cor0.col0 FROM tab0 cor0
----
1005
884
999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6794
SELECT + col2 * + CAST( NULL AS DECIMAL ) + + 47 * + col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6794
SELECT + col2 * + CAST ( NULL AS REAL ) + + 47 * + col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6795
SELECT ALL + col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6795
SELECT ALL + col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6796
SELECT col1 DIV + col0 + + 52 AS col1 FROM tab2 cor0
----
52
52
56

skipif mysql # not compatible
query I rowsort label-6796
SELECT col1 / + col0 + + 52 AS col1 FROM tab2 cor0
----
52
52
56

query I rowsort
SELECT DISTINCT + + col2 * 21 FROM tab0 AS cor0
----
1722
21
693

onlyif mysql # use DIV operator for integer division
query I rowsort label-6798
SELECT ALL - col2 DIV + cor0.col0 + col0 * col2 - + col0 AS col1 FROM tab2 AS cor0
----
179
1950
2923

skipif mysql # not compatible
query I rowsort label-6798
SELECT ALL - col2 / + cor0.col0 + col0 * col2 - + col0 AS col1 FROM tab2 AS cor0
----
179
1950
2923

query I rowsort
SELECT ALL + col1 * + col0 + + col2 + - col1 * cor0.col2 AS col0 FROM tab0 cor0
----
-741
3299
719

onlyif mysql # use DIV operator for integer division
query I rowsort label-6800
SELECT - ( - col0 ) DIV - col0 + - col1 * + col1 FROM tab1
----
-101
-170
-677

skipif mysql # not compatible
query I rowsort label-6800
SELECT - ( - col0 ) / - col0 + - col1 * + col1 FROM tab1
----
-101
-170
-677

query I rowsort
SELECT col2 + 67 * col1 + + cor0.col0 * - ( 2 ) AS col1 FROM tab2 AS cor0
----
1019
2090
3823

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6802
SELECT DISTINCT - col0 * + CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-6802
SELECT DISTINCT - col0 * + CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - 33 * + col0 + 60 * col0 AS col0 FROM tab1
----
1728
2160
81

query I rowsort
SELECT DISTINCT - col1 + + col2 * + col0 AS col0 FROM tab1
----
136
3638
7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6805
SELECT - + col1 + CAST( col2 AS SIGNED ) + + col2 AS col2 FROM tab2 AS cor0
----
-7
23
59

skipif mysql # not compatible
query I rowsort label-6805
SELECT - + col1 + CAST ( col2 AS INTEGER ) + + col2 AS col2 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT - col1 - ( - col0 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + 50 + tab1.col2 * + tab1.col1 AS col1 FROM tab1
----
1298
1454
620

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6808
SELECT ALL col0 * CAST( NULL AS SIGNED ) * - col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6808
SELECT ALL col0 * CAST ( NULL AS INTEGER ) * - col0 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 96 * + 46 + col1 * - col2 FROM tab2 AS cor0
----
2882
3579
3770

query I rowsort
SELECT + ( + col1 ) * - col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL cor1.col1 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT col1 + col0 + 48 AS col2 FROM tab2
----
144
185
86

query I rowsort
SELECT ALL + col2 * + cor0.col2 AS col0 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6814
SELECT ( col2 ) DIV - col1 + + 48 AS col2 FROM tab0
----
48
48
48

skipif mysql # not compatible
query I rowsort label-6814
SELECT ( col2 ) / - col1 + + 48 AS col2 FROM tab0
----
48
48
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6815
SELECT DISTINCT + CAST( col2 AS SIGNED ) AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6815
SELECT DISTINCT + CAST ( col2 AS INTEGER ) AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL 34 + + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 6cc954a4feb629cbf113eafb4297ab2a

query I rowsort
SELECT + 49 + tab0.col1 AS col1 FROM tab0
----
135
140
146

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col0 + col1 col2 FROM tab1
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-6819
SELECT - col1 - - cor0.col0 DIV 15 AS col0 FROM tab1 AS cor0
----
-26
-6
-8

skipif mysql # not compatible
query I rowsort label-6819
SELECT - col1 - - cor0.col0 / 15 AS col0 FROM tab1 AS cor0
----
-26
-6
-8

query I rowsort
SELECT DISTINCT 49 * - col2 AS col1 FROM tab0 AS cor0
----
-1617
-4018
-49

query I rowsort
SELECT DISTINCT cor0.col0 + col0 * + col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL + ( col2 ) * + ( + col2 ) + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + col1 * col2 - 7 AS col0 FROM tab2 cor0
----
1527
639
830

query I rowsort
SELECT ALL + + col1 * cor0.col1 + col0 * 49 FROM tab1 cor0
----
3236
4089
823

query I rowsort
SELECT + + 93 * + col1 - + col2 FROM tab1 AS cor0
----
1113
2364
873

query I rowsort
SELECT DISTINCT + cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6827
SELECT - col2 + cor0.col1 * - CAST( col1 AS SIGNED ) + col1 AS col1 FROM tab1 AS cor0
----
-147
-252
-704

skipif mysql # not compatible
query I rowsort label-6827
SELECT - col2 + cor0.col1 * - CAST ( col1 AS INTEGER ) + col1 AS col1 FROM tab1 AS cor0
----
-147
-252
-704

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 37 * cor0.col1 - 40 col2 FROM tab2 cor0
----
1107
2143
589

query I rowsort
SELECT ALL 39 * + col2 FROM tab1 AS cor0
----
2106
2223
3744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 34 col1 FROM tab1 cor0
----
34

query I rowsort
SELECT ALL + + 46 * - col2 * col2 FROM tab2 AS cor0
----
-31096
-33534
-66424

query I rowsort
SELECT - - 68 * - 0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - 54 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1674
3186
918

query I rowsort
SELECT - 50 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c7432a968c8352c12996dfa54dd4b9e8

query I rowsort
SELECT + col2 + + 67 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT - ( - cor0.col0 ) * col1 * col1 AS col2 FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT 66 + - 9 AS col0 FROM tab2 AS cor0
----
57

query I rowsort
SELECT ALL + - ( cor0.col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + col0 * 51 FROM tab0 AS cor0
----
-1224
-1785
-4539

query I rowsort
SELECT - 2 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6841
SELECT DISTINCT CAST( + col2 AS SIGNED ) AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6841
SELECT DISTINCT CAST ( + col2 AS INTEGER ) AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL + col0 * + tab0.col2 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - 19 - col1 AS col0 FROM tab0 cor0
----
-105
-110
-116

query I rowsort
SELECT DISTINCT + col1 * + col0 - + col2 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL - 22 + - col1 FROM tab2 AS cor0
----
-39
-53
-81

query I rowsort
SELECT ALL + col0 * col2 * col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + + cor0.col2 + + 95 FROM tab1 AS cor0
----
149
152
191

query I rowsort
SELECT ALL col0 + + ( col0 ) * - col0 AS col1 FROM tab0 AS cor0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - ( 11 ) * - col1 col0 FROM tab2 AS cor0
----
149
314
623

onlyif mysql # use DIV operator for integer division
query I rowsort label-6850
SELECT - col0 DIV + 2 + cor0.col2 + col0 FROM tab1 cor0
----
136
56
89

skipif mysql # not compatible
query I rowsort label-6850
SELECT - col0 / + 2 + cor0.col2 + col0 FROM tab1 cor0
----
136
56
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6851
SELECT ALL - col1 DIV + col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6851
SELECT ALL - col1 / + col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT ( col0 * CAST ( + col0 AS REAL ) ) AS col2 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL col0 * + ( + col1 ) AS col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6854
SELECT + col1 * 82 DIV - cor0.col1 + + col2 AS col0 FROM tab2 AS cor0
----
-44
-55
-56

skipif mysql # not compatible
query I rowsort label-6854
SELECT + col1 * 82 / - cor0.col1 + + col2 AS col0 FROM tab2 AS cor0
----
-44
-55
-56

query I rowsort
SELECT + col0 + col1 * col1 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-6856
SELECT DISTINCT col1 + col1 DIV + col0 AS col1 FROM tab0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-6856
SELECT DISTINCT col1 + col1 / + col0 AS col1 FROM tab0
----
89
92
99

query I rowsort
SELECT + col1 * tab0.col1 + col0 * + col2 * col0 + tab0.col1 * col1 AS col1 FROM tab0
----
20043
33800
666084

query I rowsort
SELECT + col2 + col0 - col2 AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT + col1 + tab1.col2 * col2 * - col0 FROM tab1
----
-207926
-737267
-8722

query I rowsort
SELECT DISTINCT + col2 * col1 + - tab0.col2 * + col0 FROM tab0
----
164
2046
62

query I rowsort
SELECT DISTINCT cor0.col1 * + cor0.col2 FROM tab2, tab0, tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT col0 * + col0 + - col1 AS col2 FROM tab2
----
18
6025
6224

query I rowsort
SELECT cor0.col2 * - cor0.col1 * col1 + - cor0.col1 FROM tab0 AS cor0
----
-244154
-679133
-9506

query I rowsort
SELECT ALL tab1.col1 AS col0 FROM tab1, tab2, tab0 cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT col1 + + col0 AS col2 FROM tab1
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col0 * col0 + tab2.col0 col1 FROM tab2
----
-106018
-1512
-358878

query I rowsort
SELECT - col2 + col2 * + col0 + + tab1.col1 AS col0 FROM tab1
----
134
3601
7597

query I rowsort
SELECT ALL - col0 + + col1 + + col1 AS col2 FROM tab0
----
148
159
93

query I rowsort
SELECT col1 * col1 + + col2 FROM tab0 AS cor0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 + - col1 + - col0 col2 FROM tab1 AS cor0
----
-20
4022
6307

query I rowsort
SELECT DISTINCT + col1 * col2 * col1 AS col0 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT cor0.col1 FROM tab2 AS cor0 WHERE col1 <> NULL OR NOT NULL BETWEEN - col1 / col1 + col1 AND ( NULL )
----

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 ALL + col2 * - col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col0 * - col0 col0 FROM tab2 cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-6876
SELECT cor0.col1 + col0 * col2 DIV - col0 col1 FROM tab1 cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6876
SELECT cor0.col1 + col0 * col2 / - col0 col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + cor0.col1 * cor0.col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL col0 + cor0.col0 / - cor0.col1 + col1 * - col0 FROM tab0 cor0 WHERE NOT col0 IN ( col0 ) OR ( - col2 ) > ( col1 / col0 + + col2 * col0 )
----

query I rowsort
SELECT ALL + col0 * - col0 + col2 AS col1 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT col2 * + cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT - - 97 + cor0.col2 * - col0 AS col0 FROM tab1 AS cor0
----
-3551
-65
-7583

onlyif mysql # use DIV operator for integer division
query I rowsort label-6882
SELECT - col1 DIV - cor0.col0 + col2 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-6882
SELECT - col1 / - cor0.col0 + col2 FROM tab2 AS cor0
----
26
31
38

query I rowsort
SELECT DISTINCT - 69 - tab2.col0 AS col0 FROM tab2
----
-147
-148
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * cor0.col0 * col2 + cor0.col0 * + cor0.col1 col2 FROM tab2 AS cor0
----
124254
52377
6076

query I rowsort
SELECT DISTINCT col1 + col2 * + col2 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT 56 AS col1 FROM tab2 cor0
----
56
56
56

query I rowsort
SELECT ALL - + col1 * col2 + cor0.col2 * - col2 - + col1 FROM tab1 AS cor0
----
-10477
-3829
-4346

query I rowsort
SELECT + + col1 * col2 + col0 AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL - col0 - col2 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + col2 + - cor0.col2 col0 FROM tab1 AS cor0
----
1152
1350
513

onlyif mysql # use DIV operator for integer division
query I rowsort label-6891
SELECT DISTINCT col2 + col1 DIV - col1 AS col2 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-6891
SELECT DISTINCT col2 + col1 / - col1 AS col2 FROM tab2 AS cor0
----
25
26
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6892
SELECT ALL - cor0.col2 DIV - cor0.col1 + - col2 * col1 * col0 AS col2 FROM tab1 AS cor0
----
-36475
-4210
-99833

skipif mysql # not compatible
query I rowsort label-6892
SELECT ALL - cor0.col2 / - cor0.col1 + - col2 * col1 * col0 AS col2 FROM tab1 AS cor0
----
-36475
-4210
-99833

query I rowsort
SELECT tab2.col1 + col0 * - tab2.col1 * col0 AS col1 FROM tab2
----
-106080
-1488
-358897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 * col1 + + col2 * col1 col0 FROM tab1 AS cor0
----
17472
37908
6270

query I rowsort
SELECT + + col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL col0 + cor0.col0 * + col2 FROM tab0 AS cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 23 col1 FROM tab0 AS cor0
----
23

query I rowsort
SELECT DISTINCT + col1 * - col1 * ( col1 ) FROM tab2 cor0
----
-205379
-29791
-4913

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col2 ) * + col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - ( col1 ) + - col0 * + 97 FROM tab1
----
-317
-6218
-7773

query I rowsort
SELECT DISTINCT 25 + - col1 AS col1 FROM tab1
----
-1
12
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6902
SELECT + CAST( NULL AS SIGNED ) * col1 + col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6902
SELECT + CAST ( NULL AS INTEGER ) * col1 + col2 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + + col2 + ( - cor0.col1 ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + ( col1 ) * col0 + - col2 * col1 - col2 FROM tab1 AS cor0
----
-1380
-304
13

query I rowsort
SELECT col1 + + 13 AS col0 FROM tab0
----
104
110
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6906
SELECT + CAST( NULL AS SIGNED ) + - 30 + col2 * + col1 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6906
SELECT + CAST ( NULL AS INTEGER ) + - 30 + col2 * + col1 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 col2 FROM tab2
----
-46
-46
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 77 + - col2 col0 FROM tab0 AS cor0
----
-5
44
76

query I rowsort
SELECT - + 39 + col1 FROM tab2 AS cor0
----
-22
-8
20

query I rowsort
SELECT DISTINCT + 88 * - col1 FROM tab0 cor0
----
-7568
-8008
-8536

query I rowsort
SELECT ALL - + ( + col0 ) * col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - 98 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
-98

query I rowsort
SELECT - + col1 + col0 * col0 + + col2 FROM tab2 AS cor0
----
45
6051
6262

query I rowsort
SELECT + col2 * ( col1 ) - + cor0.col0 AS col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT - col2 * col2 + 6 - col1 AS col2 FROM tab2
----
-1455
-729
-754

query I rowsort
SELECT - 35 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT DISTINCT - 32 * - 90 * - col0 FROM tab1 AS cor0
----
-184320
-230400
-8640

query I rowsort
SELECT + col0 * col2 * col2 AS col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT 66 + - col2 AS col0 FROM tab0
----
-16
33
65

query I rowsort
SELECT ALL ( 17 ) * - col0 FROM tab2 AS cor0
----
-119
-1326
-1343

query I rowsort
SELECT ALL + + cor0.col2 * - cor0.col1 + col2 FROM tab1 cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( col1 ) * col0 col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL cor0.col0 * + 89 AS col1 FROM tab1 AS cor0
----
267
5696
7120

query I rowsort
SELECT + ( 30 ) + + col2 FROM tab2 AS cor0
----
56
57
68

query I rowsort
SELECT ALL - col2 + - cor0.col0 * col2 AS col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL 3 * - tab2.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to c9606dfa70196637d980f7c3ecf9e748

query I rowsort
SELECT ALL - ( cor0.col2 ) + - col0 * col1 AS col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT - - col2 * + col0 + - col0 AS col1 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 col2 FROM tab1 cor0
----
95
95
95

query I rowsort
SELECT + - 81 * + col2 AS col0 FROM tab2 AS cor0
----
-2106
-2187
-3078

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6931
SELECT + - CAST( + col0 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-6931
SELECT + - CAST ( + col0 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + 8 * - 93 + cor0.col0 FROM tab2 AS cor0
----
-665
-666
-737

query I rowsort
SELECT - col1 * + col2 + - col1 FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + 69 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT ALL tab1.col2 + ( col1 + col1 ) FROM tab1
----
106
122
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + cor0.col0 col2 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - ( col0 ) col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL col1 + col0 * + cor0.col2 FROM tab0 cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 31 + cor0.col0 col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
111
34
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col1 * + 7 col0 FROM tab0
----
-602
-637
-679

query I rowsort
SELECT + - cor0.col0 * + col1 + cor0.col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - 0 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6943
SELECT - + cor0.col1 + + CAST( + col1 * col1 AS SIGNED ) FROM tab1 AS cor0
----
156
650
90

skipif mysql # not compatible
query I rowsort label-6943
SELECT - + cor0.col1 + + CAST ( + col1 * col1 AS INTEGER ) FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT DISTINCT col2 * + 18 FROM tab0 AS cor0
----
1476
18
594

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6945
SELECT + + CAST( + 11 AS SIGNED ) * + col2 FROM tab0 AS cor0
----
11
363
902

skipif mysql # not compatible
query I rowsort label-6945
SELECT + + CAST ( + 11 AS INTEGER ) * + col2 FROM tab0 AS cor0
----
11
363
902

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + tab1.col0 * col0 * col2 col2 FROM tab1
----
233415
432
614304

query I rowsort
SELECT + col1 * col1 + - col2 FROM tab0
----
7363
8199
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-6948
SELECT - col1 + col0 DIV 57 FROM tab0
----
-86
-90
-97

skipif mysql # not compatible
query I rowsort label-6948
SELECT - col1 + col0 / 57 FROM tab0
----
-86
-90
-97

query I rowsort
SELECT DISTINCT - tab2.col1 * - col0 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL - col2 + + tab2.col0 * col1 * col0 AS col1 FROM tab2
----
106059
1492
358930

query I rowsort
SELECT ALL tab2.col2 + - ( + col2 ) AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * tab1.col1 + col1 FROM tab1
----
110
182
702

query I rowsort
SELECT - col2 * col1 + - 54 FROM tab1 AS cor0
----
-1302
-1458
-624

query I rowsort
SELECT DISTINCT - col2 + 81 - + 44 AS col2 FROM tab2 AS cor0
----
-1
10
11

query I rowsort
SELECT + + col2 + - 73 * - 38 AS col1 FROM tab0 AS cor0
----
2775
2807
2856

query I rowsort
SELECT col0 + + col2 + - col0 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - ( col0 ) * col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + + cor0.col0 + col2 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + + col0 * - ( - col2 ) FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6960
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + col1 * col2 * + ( + cor0.col0 ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6960
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + col1 * col2 * + ( + cor0.col0 ) FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 90 ) * col2 col2 FROM tab2 AS cor0
----
2340
2430
3420

query I rowsort
SELECT DISTINCT - ( + 19 ) FROM tab0 AS cor0
----
-19

query I rowsort
SELECT 11 * col0 FROM tab0 AS cor0
----
264
385
979

query I rowsort
SELECT 18 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6965
SELECT CAST( NULL AS DECIMAL ) + ( + cor0.col2 ) FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6965
SELECT CAST ( NULL AS REAL ) + ( + cor0.col2 ) FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + tab2.col1 * 41 * col2 FROM tab2
----
26486
34317
62894

query I rowsort
SELECT - col2 * 96 AS col0 FROM tab0
----
-3168
-7872
-96

query I rowsort
SELECT + 91 * cor0.col0 * - col1 FROM tab2 AS cor0
----
-122213
-19747
-418782

query I rowsort
SELECT 81 - + col2 AS col1 FROM tab0 AS cor0
----
-1
48
80

query I rowsort
SELECT - col0 * col0 * + ( 22 * + col1 ) + 67 + + col2 * col1 AS col1 FROM tab1 AS cor0
----
-1829085
-3677
-900483

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 70 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

onlyif mysql # use DIV operator for integer division
query I rowsort label-6972
SELECT DISTINCT 4 DIV - col0 + + tab0.col0 * + ( - tab0.col0 ) + col2 col2 FROM tab0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6972
SELECT DISTINCT 4 / - col0 + + tab0.col0 * + ( - tab0.col0 ) + col2 col2 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT col1 * - col0 * col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - col0 + col2 * col2 + 75 FROM tab1
----
2988
3260
9211

onlyif mysql # use DIV operator for integer division
query I rowsort label-6975
SELECT cor0.col2 DIV tab1.col2 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6975
SELECT cor0.col2 / tab1.col2 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

query I rowsort
SELECT + - 7 * + col0 - + ( + col1 ) FROM tab2 AS cor0
----
-570
-605
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6977
SELECT - - 63 * col1 * + CAST( NULL AS SIGNED ) + 78 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6977
SELECT - - 63 * col1 * + CAST ( NULL AS INTEGER ) + 78 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6978
SELECT + 67 * col2 - col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
102
2211
5495

skipif mysql # not compatible
query I rowsort label-6978
SELECT + 67 * col2 - col0 / - col2 AS col1 FROM tab0 AS cor0
----
102
2211
5495

onlyif mysql # use DIV operator for integer division
query I rowsort label-6979
SELECT col0 + - ( + col2 ) DIV - ( col1 ) + - col0 AS col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6979
SELECT col0 + - ( + col2 ) / - ( col1 ) + - col0 AS col1 FROM tab2
----
0
0
2

query I rowsort
SELECT - col0 + col2 + - col0 AS col2 FROM tab1
----
-64
-71
48

query I rowsort
SELECT - 17 - col0 AS col2 FROM tab0 AS cor0
----
-106
-41
-52

query I rowsort
SELECT ALL - ( col2 * - col1 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT + 89 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT DISTINCT + cor0.col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6985
SELECT DISTINCT col2 * - CAST( + cor0.col2 + col2 AS SIGNED ) FROM tab0 AS cor0
----
-13448
-2
-2178

skipif mysql # not compatible
query I rowsort label-6985
SELECT DISTINCT col2 * - CAST ( + cor0.col2 + col2 AS INTEGER ) FROM tab0 AS cor0
----
-13448
-2
-2178

query I rowsort
SELECT ALL + col2 * col1 + col1 + col2 FROM tab1 AS cor0
----
1357
1484
637

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6987
SELECT col0 * ( ( + cor0.col2 ) ) + + CAST( NULL AS DECIMAL ) / - col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6987
SELECT col0 * ( ( + cor0.col2 ) ) + + CAST ( NULL AS REAL ) / - col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * + col2 + + cor0.col1 + col0 AS col1 FROM tab2 AS cor0
----
2165
227
3098

query I rowsort
SELECT col2 + col1 + - col1 AS col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6990
SELECT ALL + col2 * CAST( 34 AS SIGNED ) AS col1 FROM tab1 cor0
----
1836
1938
3264

skipif mysql # not compatible
query I rowsort label-6990
SELECT ALL + col2 * CAST ( 34 AS INTEGER ) AS col1 FROM tab1 cor0
----
1836
1938
3264

query I rowsort
SELECT ALL - cor0.col0 + + ( 67 ) FROM tab2 AS cor0
----
-11
-12
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-6992
SELECT col0 DIV cor0.col1 + col1 + - col1 AS col2 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-6992
SELECT col0 / cor0.col1 + col1 + - col1 AS col2 FROM tab1 AS cor0
----
0
6
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6993
SELECT ALL - col0 + - CAST( 70 AS SIGNED ) AS col1 FROM tab2 cor0
----
-148
-149
-77

skipif mysql # not compatible
query I rowsort label-6993
SELECT ALL - col0 + - CAST ( 70 AS INTEGER ) AS col1 FROM tab2 cor0
----
-148
-149
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 + col0 col1 FROM tab1
----
133
149
72

query I rowsort
SELECT DISTINCT tab0.col0 - col2 FROM tab0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6996
SELECT ALL col0 * col1 - CAST( 22 AS SIGNED ) FROM tab1
----
1018
56
618

skipif mysql # not compatible
query I rowsort label-6996
SELECT ALL col0 * col1 - CAST ( 22 AS INTEGER ) FROM tab1
----
1018
56
618

query I rowsort
SELECT DISTINCT - col2 + tab2.col0 - col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT col0 + col1 + + col1 AS col1 FROM tab0
----
196
229
271

query I rowsort
SELECT + 42 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # use DIV operator for integer division
query I rowsort label-7000
SELECT DISTINCT - + col2 DIV col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-7000
SELECT DISTINCT - + col2 / col0 AS col2 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT + col1 * - col1 + ( - col1 ) - col2 FROM tab2 AS cor0
----
-1019
-344
-3566

query I rowsort
SELECT + - col1 * ( + col2 ) AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 1 col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col1 * - col2 + - col0 + - col0 FROM tab2 AS cor0
----
-1690
-804
-851

query I rowsort
SELECT DISTINCT + col2 * - ( - col0 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col0 * - 47 AS col2 FROM tab1
----
-141
-3008
-3760

query I rowsort
SELECT + ( + ( - col1 ) ) AS col0 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 52 - col0 FROM tab0
----
-37
17
28

query I rowsort
SELECT DISTINCT + + cor0.col0 * - col2 + + cor0.col0 * 93 AS col0 FROM tab1 AS cor0
----
-240
117
2304

query I rowsort
SELECT DISTINCT + col1 + col2 * + col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-7011
SELECT col0 DIV col1 + - col1 FROM tab1
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-7011
SELECT col0 / col1 + - col1 FROM tab1
----
-26
-4
-7

query I rowsort
SELECT ALL col2 * - col0 * + tab0.col1 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + col2 FROM tab1 WHERE NOT ( + col1 ) NOT IN ( tab1.col0 )
----

query I rowsort
SELECT DISTINCT col2 + + col0 + - col2 AS col1 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7015
SELECT col1 - + col1 * col1 DIV - col1 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-7015
SELECT col1 - + col1 * col1 / - col1 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL col1 + col2 * tab1.col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL tab1.col2 * tab1.col1 + - col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT ALL + tab0.col1 * - col1 + col0 - - col2 FROM tab0
----
-7339
-8110
-9373

query I rowsort
SELECT - col2 + col2 - - col0 * col2 AS col2 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7020
SELECT + col1 DIV - col1 - + tab1.col1 AS col1 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-7020
SELECT + col1 / - col1 - + tab1.col1 AS col1 FROM tab1
----
-11
-14
-27

query I rowsort
SELECT ALL tab2.col1 * col2 + col0 * + col1 AS col1 FROM tab2
----
1054
1989
6136

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 + col1 NOT IN ( - col1 )
----

query I rowsort
SELECT + col2 + col1 * - col1 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL col1 / col0 + + col0 * col0 FROM tab1 WHERE ( - col2 + col2 ) IN ( + col2 )
----

query I rowsort
SELECT + tab2.col2 + + col2 AS col1 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col1 col2 FROM tab1
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col2 * col1 col2 FROM tab2
----
1534
646
837

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE col2 NOT IN ( + col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col2 AS col0 FROM tab1 AS cor0 WHERE NOT NULL <= NULL
----

query I rowsort
SELECT + col2 * + col1 + + col1 * tab2.col1 FROM tab2
----
1798
5015
935

query I rowsort
SELECT col2 + - col1 + col2 FROM tab1
----
104
179
82

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN col2 AND - col0
----

query I rowsort
SELECT DISTINCT - tab1.col2 + + col0 AS col1 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT DISTINCT col1 + - tab1.col2 DIV + col1 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-7034
SELECT DISTINCT col1 + - tab1.col2 / + col1 FROM tab1
----
24
5
6

query I rowsort
SELECT - col0 + + col0 * + col0 * col2 AS col0 FROM tab2
----
1316
158106
237079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 col1 FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7037
SELECT ALL + col1 DIV col0 + + col0 AS col1 FROM tab0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-7037
SELECT ALL + col1 / col0 + + col0 AS col1 FROM tab0
----
27
37
90

query III rowsort
SELECT * FROM tab0 WHERE NOT col2 * - col2 NOT IN ( - col1 * + col1 + col1 )
----

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 * col1 AS col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT 29 AS col0 FROM tab0, tab1 AS cor0
----
29

query I rowsort
SELECT - col0 + 68 FROM tab2 AS cor0
----
-10
-11
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 37 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT ALL + 62 * col2 FROM tab2
----
1612
1674
2356

query I rowsort
SELECT ALL + ( - 43 * col2 ) AS col0 FROM tab1
----
-2322
-2451
-4128

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7045
SELECT + col0 + col0 * col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7045
SELECT + col0 + col0 * col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + tab1.col2 + 56 FROM tab1, tab2 AS cor0
----
110
113
152

query I rowsort
SELECT DISTINCT + - 50 * cor0.col2 FROM tab2, tab1, tab2 cor0
----
-1300
-1350
-1900

query I rowsort
SELECT - 90 + col1 FROM tab0 AS cor0
----
-4
1
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * + cor0.col2 + 72 col1 FROM tab2 AS cor0
----
-1372
-604
-657

query I rowsort
SELECT DISTINCT + col1 + cor0.col1 + + ( 96 ) FROM tab0 AS cor0
----
268
278
290

query I rowsort
SELECT DISTINCT - + col0 * - col2 + col1 + 11 * - col2 AS col1 FROM tab2 AS cor0
----
-77
1801
2601

query I rowsort
SELECT - col2 + + 68 AS col2 FROM tab1 AS cor0
----
-28
11
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-7053
SELECT + col1 DIV - col1 + + col1 AS col1 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-7053
SELECT + col1 / - col1 + + col1 AS col1 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT - col0 + 15 FROM tab2 AS cor0
----
-63
-64
8

query I rowsort
SELECT DISTINCT - col2 * - ( col2 ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + - col2 + - col1 * col2 AS col0 FROM tab0 cor0
----
-2871
-7544
-98

query I rowsort
SELECT - cor0.col1 * + col0 + cor0.col0 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT ALL - col0 * 29 + col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-1855
-2319
-86

skipif mysql # not compatible
query I rowsort label-7058
SELECT ALL - col0 * 29 + col1 / col1 AS col2 FROM tab1 AS cor0
----
-1855
-2319
-86

query I rowsort
SELECT - + cor0.col2 * - 54 FROM tab1 AS cor0
----
2916
3078
5184

onlyif mysql # use DIV operator for integer division
query I rowsort label-7060
SELECT + tab1.col1 * - col2 + + col1 DIV col2 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-7060
SELECT + tab1.col1 * - col2 + + col1 / col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL ( - col0 + + col1 ) FROM tab0
----
2
62
62

query I rowsort
SELECT col0 * ( - cor0.col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col2 + + ( - col2 ) * - col1 + - col2 FROM tab0 AS cor0
----
2772
7298
95

query I rowsort
SELECT - col0 + cor0.col2 + + col1 FROM tab2 AS cor0
----
-24
51
7

query I rowsort
SELECT ALL 8 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT DISTINCT col0 + - col0 * col0 + col1 FROM tab2 AS cor0
----
-11
-5947
-6145

query I rowsort
SELECT col2 + - col0 * col0 * + col1 - + col0 AS col1 FROM tab0 AS cor0
----
-118859
-49527
-720818

query I rowsort
SELECT ALL 51 - 12 AS col1 FROM tab2
----
39
39
39

query I rowsort
SELECT ( col0 ) + col0 - col1 AS col1 FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT DISTINCT tab1.col0 + col2 + - col1 * + col2 FROM tab1
----
-1072
-1347
-449

query I rowsort
SELECT ALL tab2.col1 * col1 * col1 + 51 FROM tab2
----
205430
29842
4964

query I rowsort
SELECT ALL + - 48 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1584
-3936
-48

query I rowsort
SELECT DISTINCT - + col2 * + col1 * col1 + ( - col2 ) AS col2 FROM tab2 AS cor0
----
-11020
-25974
-90532

query I rowsort
SELECT 40 * col0 + 73 FROM tab2 AS cor0
----
3193
3233
353

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7075
SELECT ALL - CAST( 65 AS SIGNED ) + cor0.col2 FROM tab2 AS cor0
----
-27
-38
-39

skipif mysql # not compatible
query I rowsort label-7075
SELECT ALL - CAST ( 65 AS INTEGER ) + cor0.col2 FROM tab2 AS cor0
----
-27
-38
-39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7076
SELECT + col1 / - cor0.col2 + + col0 / CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7076
SELECT + col1 / - cor0.col2 + + col0 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 91 * col1 + - col2 col2 FROM tab0 AS cor0
----
-7859
-8363
-8828

query I rowsort
SELECT - col0 - + col2 AS col0 FROM tab0 cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7079
SELECT + CAST( col2 AS SIGNED ) * col0 - + 81 AS col1 FROM tab2 AS cor0
----
108
1947
2921

skipif mysql # not compatible
query I rowsort label-7079
SELECT + CAST ( col2 AS INTEGER ) * col0 - + 81 AS col1 FROM tab2 AS cor0
----
108
1947
2921

query I rowsort
SELECT + ( - 62 ) + + col2 AS col0 FROM tab1 AS cor0
----
-5
-8
34

query I rowsort
SELECT ALL - col2 * col2 * + cor0.col1 + col0 FROM tab1 AS cor0
----
-119728
-32426
-75813

query I rowsort
SELECT DISTINCT + ( col1 ) - cor0.col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + ( 96 ) * + col0 FROM tab2 AS cor0
----
672
7488
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col1 + cor0.col1 col2 FROM tab2 AS cor0
----
177
51
93

query I rowsort
SELECT ALL + col2 * - cor0.col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-7086
SELECT DISTINCT cor0.col0 DIV col1 + col0 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-7086
SELECT DISTINCT cor0.col0 / col1 + col0 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT DISTINCT 27 AS col2 FROM tab0, tab1 AS cor0
----
27

query I rowsort
SELECT ALL - - col2 * + cor0.col1 * + col2 + 59 - + col1 AS col2 FROM tab2 AS cor0
----
22627
24590
39884

query I rowsort
SELECT ALL + + col2 * - 0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + ( + 50 ) * col2 FROM tab2 AS cor0
----
-1300
-1350
-1900

query I rowsort
SELECT ( + ( col2 ) + col0 ) AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + cor0.col1 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT + + col1 * 38 * col0 AS col2 FROM tab0 cor0
----
129010
307762
78432

query I rowsort
SELECT ALL + col2 * ( col0 ) + 60 + col0 FROM tab0 AS cor0
----
130
7447
876

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 84 + col0 col1 FROM tab1 AS cor0
----
-20
-4
-81

query I rowsort
SELECT ALL 38 + col2 FROM tab1 cor0
----
134
92
95

query I rowsort
SELECT DISTINCT - - 44 * col1 + + col1 AS col0 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT col2 + col2 * - ( + col1 ) FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT cor0.col0 + - cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT - - ( - col1 ) * + ( - col1 ) * col2 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT - - col1 + cor0.col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT + 24 * - col2 FROM tab1 AS cor0
----
-1296
-1368
-2304

onlyif mysql # use DIV operator for integer division
query I rowsort label-7103
SELECT col2 - col1 * col1 DIV + col0 AS col0 FROM tab2 AS cor0
----
-110
-18
35

skipif mysql # not compatible
query I rowsort label-7103
SELECT col2 - col1 * col1 / + col0 AS col0 FROM tab2 AS cor0
----
-110
-18
35

query I rowsort
SELECT DISTINCT + col1 - col0 * col0 AS col1 FROM tab2 AS cor0
----
-18
-6025
-6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-7105
SELECT + ( col1 ) * col2 + + col0 * col0 DIV - ( + 75 ) col2 FROM tab1 AS cor0
----
1163
1404
516

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7105
SELECT + ( col1 ) * col2 + + col0 * col0 / - ( + 75 ) col2 FROM tab1 AS cor0
----
1163
1404
516

query I rowsort
SELECT 31 + 28 FROM tab2
----
59
59
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7107
SELECT DISTINCT 80 DIV col2 - col0 FROM tab1
----
-2
-63
-80

skipif mysql # not compatible
query I rowsort label-7107
SELECT DISTINCT 80 / col2 - col0 FROM tab1
----
-2
-63
-80

query I rowsort
SELECT ALL + 68 - tab1.col0 AS col0 FROM tab1
----
-12
4
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-7109
SELECT + + col2 DIV - 42 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7109
SELECT + + col2 / - 42 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7110
SELECT DISTINCT + col2 DIV - ( col0 ) FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7110
SELECT DISTINCT + col2 / - ( col0 ) FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT col0 * + col0 * - ( col2 ) FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT + col1 + - 30 * col2 AS col0 FROM tab0 AS cor0
----
-2369
-904
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7113
SELECT col1 DIV ( + col1 ) FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7113
SELECT col1 / ( + col1 ) FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * - col0 col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT col2 * 89 + - ( col0 ) * col1 * + col2 AS col2 FROM tab1 AS cor0
----
-31407
-91296
594

query I rowsort
SELECT - col1 + - ( - 73 ) AS col0 FROM tab0 AS cor0
----
-13
-18
-24

query I rowsort
SELECT DISTINCT col1 * + 10 FROM tab2 cor0
----
170
310
590

query I rowsort
SELECT DISTINCT 59 + + col1 AS col0 FROM tab1
----
69
72
85

query I rowsort
SELECT + col1 - + col0 * + 98 AS col2 FROM tab0
----
-2266
-3333
-8631

query I rowsort
SELECT DISTINCT 90 + - col0 + col2 AS col2 FROM tab2
----
110
38
49

query I rowsort
SELECT + - col2 * + 74 AS col0 FROM tab0 cor0
----
-2442
-6068
-74

query I rowsort
SELECT DISTINCT cor0.col2 * col2 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-7123
SELECT DISTINCT - - col1 DIV col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-7123
SELECT DISTINCT - - col1 / col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT + 54 * col1 AS col0 FROM tab2
----
1674
3186
918

query I rowsort
SELECT ALL 81 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT + col0 * ( col1 + - col2 ) FROM tab1
----
-3008
-6640
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7127
SELECT col1 * - col2 + - CAST( col0 AS SIGNED ) AS col2 FROM tab1
----
-1328
-1407
-634

skipif mysql # not compatible
query I rowsort label-7127
SELECT col1 * - col2 + - CAST ( col0 AS INTEGER ) AS col2 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT ALL 3 AS col1 FROM tab0
----
3
3
3

query I rowsort
SELECT DISTINCT cor0.col0 + - col2 + col0 FROM tab2 AS cor0
----
-13
120
130

query I rowsort
SELECT ALL col2 * + col2 + - 34 FROM tab1 AS cor0
----
2882
3215
9182

query I rowsort
SELECT ALL + col0 * - 83 + + 23 FROM tab2 AS cor0
----
-558
-6451
-6534

query I rowsort
SELECT DISTINCT - col0 * + 58 AS col0 FROM tab1 AS cor0
----
-174
-3712
-4640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7133
SELECT DISTINCT - col0 * CAST( col0 AS SIGNED ) FROM tab2 cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-7133
SELECT DISTINCT - col0 * CAST ( col0 AS INTEGER ) FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - + cor0.col2 * - col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col0 * cor0.col2 * 62 FROM tab2 AS cor0
----
-11718
-125736
-186124

onlyif mysql # use DIV operator for integer division
query I rowsort label-7136
SELECT DISTINCT col0 + - CAST( 80 AS SIGNED ) DIV + col0 FROM tab1 AS cor0
----
-23
63
79

skipif mysql # not compatible
query I rowsort label-7136
SELECT DISTINCT col0 + - CAST ( 80 AS INTEGER ) / + col0 FROM tab1 AS cor0
----
-23
63
79

query I rowsort
SELECT DISTINCT + col2 + - 67 * 33 * col1 AS col0 FROM tab1 AS cor0
----
-22053
-28647
-57432

query I rowsort
SELECT ALL - + col1 + - col2 * - ( col0 ) * col2 AS col1 FROM tab2 AS cor0
----
114059
5072
52669

query I rowsort
SELECT ALL col0 * col0 + col0 * col1 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT - col0 * ( col2 ) AS col2 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7141
SELECT col2 + + CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7141
SELECT col2 + + CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * 90 * col1 col1 FROM tab2 AS cor0
----
138060
58140
75330

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + col0 + CAST ( col0 AS REAL ) col2 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + + col0 * col2 col0 FROM tab1 AS cor0
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + cor0.col0 + - col1 col2 FROM tab2 cor0
----
-17
141
97

query I rowsort
SELECT - col1 + - 61 FROM tab1 AS cor0
----
-71
-74
-87

query I rowsort
SELECT DISTINCT + col1 + col2 * col2 - cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
-3867
118
543

query I rowsort
SELECT ALL + col2 + - ( + col1 ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL - col1 * col2 + - col2 FROM tab2 AS cor0
----
-1560
-684
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7150
SELECT + + CAST( col2 AS SIGNED ) * + col2 + 7 DIV 54 AS col0 FROM tab0 cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-7150
SELECT + + CAST ( col2 AS INTEGER ) * + col2 + 7 / 54 AS col0 FROM tab0 cor0
----
1
1089
6724

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab0 cor2
----
3645 values hashing to 4037d65571c1bbf6e0e7d759f858120e

query I rowsort
SELECT 77 * col0 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT DISTINCT + + 30 FROM tab1 AS cor0
----
30

query I rowsort
SELECT ALL col0 * - 33 AS col0 FROM tab1 AS cor0
----
-2112
-2640
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-7155
SELECT DISTINCT 78 DIV col1 + col2 * + 68 FROM tab1 AS cor0
----
3675
3883
6534

skipif mysql # not compatible
query I rowsort label-7155
SELECT DISTINCT 78 / col1 + col2 * + 68 FROM tab1 AS cor0
----
3675
3883
6534

query I rowsort
SELECT ALL 24 FROM tab1 AS cor0
----
24
24
24

query I rowsort
SELECT DISTINCT - col2 * 78 + - cor0.col2 FROM tab1 AS cor0
----
-4266
-4503
-7584

query I rowsort
SELECT DISTINCT + col1 + 82 - - col0 FROM tab2 AS cor0
----
120
178
219

query I rowsort
SELECT ALL + ( + 54 ) FROM tab1 AS cor0
----
54
54
54

query I rowsort
SELECT 3 * - col0 + col2 * - 93 + - col0 FROM tab2 AS cor0
----
-2539
-2730
-3850

query I rowsort
SELECT DISTINCT + - ( col0 ) + + cor0.col0 * + ( - col2 ) AS col1 FROM tab1 cor0
----
-165
-3712
-7760

query I rowsort
SELECT 5 + tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 20ace770fb6189a78e5b0276def42344

query I rowsort
SELECT + col0 * ( col1 ) + tab2.col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT + col1 * col1 + + col1 * col2 FROM tab1 AS cor0
----
1417
2080
670

query I rowsort
SELECT - - 15 + col0 * col2 AS col2 FROM tab2 AS cor0
----
204
2043
3017

query I rowsort
SELECT + col1 * col0 + - col1 * + cor0.col2 * col0 FROM tab0 AS cor0
----
-656019
-66048
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7167
SELECT + col2 * col2 DIV + col0 + 28 FROM tab0 cor0
----
103
28
73

skipif mysql # not compatible
query I rowsort label-7167
SELECT + col2 * col2 / + col0 + 28 FROM tab0 cor0
----
103
28
73

query I rowsort
SELECT + 20 + col0 * - col2 FROM tab0 AS cor0
----
-15
-7278
-772

query I rowsort
SELECT + - 56 AS col2 FROM tab0 cor0
----
-56
-56
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-7170
SELECT cor0.col2 DIV + 18 col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2ee98119c78288c6cb10711ce24bf26c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7170
SELECT cor0.col2 / + 18 col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2ee98119c78288c6cb10711ce24bf26c

query I rowsort
SELECT 36 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT DISTINCT + col1 * ( - ( + col0 ) ) + + col0 + ( col0 ) * col2 * + 41 AS col2 FROM tab0 AS cor0
----
-1925
291208
30432

query I rowsort
SELECT + cor0.col0 + + col0 * col2 + col1 AS col0 FROM tab1 AS cor0
----
191
3722
7773

query I rowsort
SELECT + col0 * - col0 * + cor0.col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + ( - col1 ) * col1 + - col1 * + col0 + + cor0.col2 * 21 AS col0 FROM tab1 AS cor0
----
380
457
807

query I rowsort
SELECT DISTINCT cor1.col2 * + cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3aa3dc9c06ac75ec040ed5bc20953cf9

query I rowsort
SELECT 35 * + cor0.col0 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 18baf8aa12bceafb74e273208d5c2d18

query I rowsort
SELECT - 86 * 60 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-134160
-51600
-67080

query I rowsort
SELECT ALL + ( - 95 ) FROM tab0 AS cor0
----
-95
-95
-95

query I rowsort
SELECT + + col0 * + col0 + col2 + col1 AS col2 FROM tab0 AS cor0
----
1323
695
8094

query I rowsort
SELECT ALL col0 + - col2 * col0 FROM tab2 cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL - - col1 * 18 FROM tab0 AS cor0
----
1548
1638
1746

query I rowsort
SELECT DISTINCT + - cor0.col1 * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7184
SELECT - col2 * - CAST( NULL AS SIGNED ) + cor0.col2 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7184
SELECT - col2 * - CAST ( NULL AS INTEGER ) + cor0.col2 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + col0 * col2 * - col1 FROM tab2 AS cor0
----
-119626
-50996
-5832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7186
SELECT ALL + col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7186
SELECT ALL + col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7187
SELECT - col1 * col0 DIV col1 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-7187
SELECT - col1 * col0 / col1 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - - ( col0 * col1 ) col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT + tab0.col2 * col0 + 62 * - tab0.col0 - 22 FROM tab0
----
-2157
-718
1758

query I rowsort
SELECT col1 + - 52 + col2 * - col2 FROM tab2
----
-1479
-669
-750

query I rowsort
SELECT ALL + tab1.col1 * cor1.col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4307a5c67912e63c47b74283c0988b96

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2, tab1 cor0, tab1 AS cor1
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query I rowsort
SELECT DISTINCT - 25 FROM tab2, tab1 cor0
----
-25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7194
SELECT + col2 * - CAST( NULL AS DECIMAL ) + col2 + col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7194
SELECT + col2 * - CAST ( NULL AS REAL ) + col2 + col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - col2 + col2 + + col2 AS col2 FROM tab2
----
-1482
-570
-783

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + col2 * ( + col1 ) + col2 col1 FROM tab2 AS cor0
----
1482
605
857

query I rowsort
SELECT DISTINCT - 31 AS col2 FROM tab2
----
-31

query I rowsort
SELECT - 85 + tab2.col2 AS col1 FROM tab2, tab0, tab0 cor0
----
27 values hashing to 5270e63eafe339de43a721eb6cd5097b

query I rowsort
SELECT - 83 * + col1 * col2 FROM tab2
----
-127322
-53618
-69471

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 1 * + col1 + - 68 col1 FROM tab2 AS cor0
----
-127
-85
-99

query I rowsort
SELECT DISTINCT col0 + + tab1.col1 + col1 AS col1 FROM tab1
----
106
55
84

query I rowsort
SELECT - col0 + ( - cor0.col1 ) + + col0 AS col2 FROM tab1 cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 10 col1 FROM tab1
----
10

query I rowsort
SELECT cor0.col2 * - 38 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to a6aadcbd9c91c3421ff5b3daa7188cbb

query I rowsort
SELECT + 95 * 30 + col0 FROM tab0
----
2874
2885
2939

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) + - col1 col0 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT ALL tab0.col0 + 90 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 5d16b70fd27aa371e8ca81a76f9053ad

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * tab2.col1 * - col1 + col0 * col1 col1 FROM tab2
----
-21488
-266916
-6510

query I rowsort
SELECT 96 * + cor0.col1 - - cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3af87f3c15ccaee137778d8299993877

query I rowsort
SELECT 53 * cor0.col1 FROM tab2 AS cor0
----
1643
3127
901

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 89 * col1 col2 FROM tab1 AS cor0
----
-1157
-2314
-890

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7212
SELECT DISTINCT - ( + col2 ) + - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7212
SELECT DISTINCT - ( + col2 ) + - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT tab1.col0 - col0 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT - + tab1.col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT DISTINCT cor0.col1 + + tab1.col0 AS col0 FROM tab1, tab0, tab0 AS cor0
----
9 values hashing to 338e91bd6b1ec42ced1d27c185bc6972

query I rowsort
SELECT - + col2 + - col2 * + col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT - - col2 * - col1 + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT col1 * + col1 + - 49 FROM tab0 cor0
----
7347
8232
9360

query I rowsort
SELECT ALL - col1 * col0 + - col2 - + col1 FROM tab1 AS cor0
----
-1149
-158
-707

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 * col0 + col0 col2 FROM tab0
----
240
350
890

query I rowsort
SELECT + + col2 * col0 + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL 40 + col0 FROM tab1 AS cor0
----
104
120
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col0 col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * - col0 + col2 AS col1 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT col2 + 13 AS col0 FROM tab0 AS cor0
----
14
46
95

query I rowsort
SELECT ALL - + col2 * col2 AS col1 FROM tab0 cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-7227
SELECT ALL col1 DIV + 78 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7227
SELECT ALL col1 / + 78 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 + ( col0 ) AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + 6 FROM tab1, tab0, tab2 cor0
----
6

query I rowsort
SELECT - 8 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 852581644118629bf652b1aa4b8f4363

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab1 cor0, tab2 AS cor1
----
972 values hashing to f0b9665afa0b835e4e5097af17c51766

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7232
SELECT DISTINCT - col2 - + CAST( cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-7232
SELECT DISTINCT - col2 - + CAST ( cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7233
SELECT ALL - col1 + + col2 DIV 88 AS col0 FROM tab1 AS cor0
----
-10
-12
-26

skipif mysql # not compatible
query I rowsort label-7233
SELECT ALL - col1 + + col2 / 88 AS col0 FROM tab1 AS cor0
----
-10
-12
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-7234
SELECT DISTINCT + col2 * col0 * + 3 + + cor0.col1 DIV - col0 FROM tab1 cor0
----
10944
23040
478

skipif mysql # not compatible
query I rowsort label-7234
SELECT DISTINCT + col2 * col0 * + 3 + + cor0.col1 / - col0 FROM tab1 cor0
----
10944
23040
478

query I rowsort
SELECT ALL col2 + 41 FROM tab0 AS cor0
----
123
42
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7236
SELECT - cor0.col2 DIV ( 12 + - col0 ) AS col0 FROM tab1 AS cor0
----
-6
1
1

skipif mysql # not compatible
query I rowsort label-7236
SELECT - cor0.col2 / ( 12 + - col0 ) AS col0 FROM tab1 AS cor0
----
-6
1
1

query I rowsort
SELECT DISTINCT - col2 * - 34 * col1 - + col1 AS col0 FROM tab1 AS cor0
----
19370
42419
47710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7238
SELECT + + ( + col0 ) + + cor0.col1 * CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
1120
704
81

skipif mysql # not compatible
query I rowsort label-7238
SELECT + + ( + col0 ) + + cor0.col1 * CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col2 * + col1 col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - cor0.col2 - ( - col0 ) * 36 * cor0.col1 FROM tab0 cor0
----
122219
291482
74271

onlyif mysql # use DIV operator for integer division
query I rowsort label-7241
SELECT ALL + col1 DIV - cor0.col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-7241
SELECT ALL + col1 / - cor0.col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT 46 * col2 + - col2 + ( 87 ) AS col2 FROM tab0 AS cor0
----
132
1572
3777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + ( - col0 ) col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + 10 * + col0 + cor0.col2 + col2 FROM tab0 cor0
----
1054
306
352

onlyif mysql # use DIV operator for integer division
query I rowsort label-7245
SELECT col2 * 2 DIV col1 + - ( col2 ) + - col0 FROM tab1 AS cor0
----
-110
-162
-53

skipif mysql # not compatible
query I rowsort label-7245
SELECT col2 * 2 / col1 + - ( col2 ) + - col0 FROM tab1 AS cor0
----
-110
-162
-53

query I rowsort
SELECT ALL 69 * + 62 + - col2 * + col2 FROM tab0 AS cor0
----
-2446
3189
4277

query I rowsort
SELECT + col2 * - col0 + - col2 AS col0 FROM tab0 cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT - 26 * col0 FROM tab1 AS cor0
----
-1664
-2080
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7249
SELECT ALL CAST( NULL AS SIGNED ) * + cor0.col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7249
SELECT ALL CAST ( NULL AS INTEGER ) * + cor0.col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7250
SELECT + - col1 DIV ( - col2 ) + col0 + cor0.col1 col0 FROM tab0 AS cor0
----
112
181
229

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7250
SELECT + - col1 / ( - col2 ) + col0 + cor0.col1 col0 FROM tab0 AS cor0
----
112
181
229

onlyif mysql # use DIV operator for integer division
query I rowsort label-7251
SELECT DISTINCT + 29 DIV col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7251
SELECT DISTINCT + 29 / col1 AS col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col0 * - col0 col2 FROM tab0 AS cor0
----
13824
42875
704969

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7253
SELECT ALL - 23 - cor0.col2 * CAST( col2 * col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-119831
-32513
-75839

skipif mysql # not compatible
query I rowsort label-7253
SELECT ALL - 23 - cor0.col2 * CAST ( col2 * col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-119831
-32513
-75839

query I rowsort
SELECT DISTINCT - 37 AS col2 FROM tab2 AS cor0
----
-37

query I rowsort
SELECT - - ( - col2 ) + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + ( + col1 ) + col2 AS col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT col1 + - 40 FROM tab2
----
-23
-9
19

query I rowsort
SELECT - 23 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7259
SELECT ALL + col0 * + CAST( NULL AS DECIMAL ) * - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7259
SELECT ALL + col0 * + CAST ( NULL AS REAL ) * - col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7260
SELECT ALL col1 DIV + 69 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7260
SELECT ALL col1 / + 69 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT 65 FROM tab1, tab0 cor0
----
65

query I rowsort
SELECT ALL col0 * 69 AS col1 FROM tab0
----
1656
2415
6141

query I rowsort
SELECT - ( - col2 ) * + col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col1 * 45 AS col1 FROM tab2 cor0
----
1395
2655
765

query I rowsort
SELECT ALL - + ( - cor0.col2 ) + + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + ( + 28 ) FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT + + 43 FROM tab0 AS cor0
----
43
43
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7268
SELECT ALL CAST( col1 AS SIGNED ) + + col0 + + 53 AS col1 FROM tab0 AS cor0
----
163
185
233

skipif mysql # not compatible
query I rowsort label-7268
SELECT ALL CAST ( col1 AS INTEGER ) + + col0 + + 53 AS col1 FROM tab0 AS cor0
----
163
185
233

query I rowsort
SELECT DISTINCT - col0 + - ( + col1 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL + + col2 + ( + cor0.col1 + + 31 ) FROM tab2 AS cor0
----
116
86
89

query I rowsort
SELECT ALL + col2 + - col0 * ( tab1.col0 ) FROM tab1
----
-4039
-6304
45

query I rowsort
SELECT - 21 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT ALL + col0 * col0 + + 96 * col1 AS col2 FROM tab0
----
10537
16657
8832

query I rowsort
SELECT - - cor0.col1 + col0 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - col2 * col2 + - ( + col0 + + col1 ) * col0 FROM tab1 AS cor0
----
-16656
-3003
-7985

query I rowsort
SELECT - - col0 + col1 * + ( col1 ) FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL - - 78 * col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
4215
4510
7568

query I rowsort
SELECT 20 * col2 AS col2 FROM tab2 AS cor0
----
520
540
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7279
SELECT ALL + col2 * + cor0.col1 * + ( col2 ) + + col0 DIV - col0 AS col0 FROM tab1 AS cor0
----
119807
32489
75815

skipif mysql # not compatible
query I rowsort label-7279
SELECT ALL + col2 * + cor0.col1 * + ( col2 ) + + col0 / - col0 AS col0 FROM tab1 AS cor0
----
119807
32489
75815

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col2 col0 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - col0 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - col0 * - ( 92 ) + cor0.col2 FROM tab1 AS cor0
----
330
5945
7456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7283
SELECT DISTINCT + col0 * CAST( col2 AS SIGNED ) + + col2 FROM tab2 AS cor0
----
2054
216
3040

skipif mysql # not compatible
query I rowsort label-7283
SELECT DISTINCT + col0 * CAST ( col2 AS INTEGER ) + + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - cor0.col0 + col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + col0 + - ( - col0 ) AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7286
SELECT col2 * + CAST( col1 AS SIGNED ) AS col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-7286
SELECT col2 * + CAST ( col1 AS INTEGER ) AS col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL + + cor0.col2 + 56 AS col1 FROM tab0 AS cor0
----
138
57
89

query I rowsort
SELECT ALL - - cor0.col0 * 43 AS col0 FROM tab1 AS cor0
----
129
2752
3440

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * ( - 35 ) * cor0.col2 + - col0 col2 FROM tab2 AS cor0
----
-22689
-29302
-53768

onlyif mysql # use DIV operator for integer division
query I rowsort label-7290
SELECT DISTINCT col1 - col2 DIV - ( + col2 ) FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-7290
SELECT DISTINCT col1 - col2 / - ( + col2 ) FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT + cor0.col0 + + cor0.col1 * 6 AS col1 FROM tab2 AS cor0
----
181
193
432

query I rowsort
SELECT ALL - cor1.col2 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7293
SELECT + col2 + 33 DIV - 7 AS col1 FROM tab0 AS cor0
----
-3
29
78

skipif mysql # not compatible
query I rowsort label-7293
SELECT + col2 + 33 / - 7 AS col1 FROM tab0 AS cor0
----
-3
29
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + ( 43 ) * col1 col1 FROM tab0 AS cor0
----
3665
3831
4170

query I rowsort
SELECT + - cor0.col1 + - 72 * 15 FROM tab2 cor0
----
-1097
-1111
-1139

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7296
SELECT + col2 * + CAST( NULL AS DECIMAL ) + 85 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7296
SELECT + col2 * + CAST ( NULL AS REAL ) + 85 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 * + 29 FROM tab0, tab1 AS cor0
----
9 values hashing to 5319314427cff452ca112595a8b96825

onlyif mysql # use DIV operator for integer division
query I rowsort label-7298
SELECT col0 + + col2 DIV cor0.col2 AS col0 FROM tab0 cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7298
SELECT col0 + + col2 / cor0.col2 AS col0 FROM tab0 cor0
----
25
36
90

query I rowsort
SELECT DISTINCT col1 * - col2 * - ( + col2 ) AS col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - - 6 + col0 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT DISTINCT - 99 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-7302
SELECT DISTINCT + - ( col0 ) DIV 91 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7302
SELECT DISTINCT + - ( col0 ) / 91 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col2 * col1 + 47 AS col0 FROM tab1
----
-1201
-1357
-523

query I rowsort
SELECT ALL + 26 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT + tab1.col1 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - col0 * col0 + col0 * col2 FROM tab2 AS cor0
----
-3239
-4056
140

query I rowsort
SELECT - - col1 * ( - col2 * col0 ) AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - cor0.col0 - cor0.col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + 1 * + col0 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT 55 * + col0 + + col2 AS col0 FROM tab0 AS cor0
----
1353
1926
4977

query I rowsort
SELECT - + cor0.col1 * - col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - 69 * - col0 * + 48 AS col0 FROM tab0 AS cor0
----
115920
294768
79488

query I rowsort
SELECT 81 * + col0 AS col2 FROM tab1 AS cor0
----
243
5184
6480

query I rowsort
SELECT DISTINCT + 78 + + col1 AS col2 FROM tab2 AS cor0
----
109
137
95

query I rowsort
SELECT DISTINCT col0 + - col0 * 61 FROM tab2 AS cor0
----
-420
-4680
-4740

query I rowsort
SELECT ALL + ( col0 ) * + ( ( + col2 ) ) FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7317
SELECT + col1 * CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-7317
SELECT + col1 * CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col0 * + 30 + - col1 FROM tab1 AS cor0
----
1910
2387
64

query I rowsort
SELECT ALL - col1 * ( + 44 ) + + col1 * 53 FROM tab1 AS cor0
----
117
234
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col0 * - cor1.col2 + 6 col0 FROM tab1, tab0 cor0, tab0 cor1
----
27 values hashing to cfca5f650fe63dc88b3c8afeb2763a22

query I rowsort
SELECT DISTINCT - col0 + - 66 * - col2 AS col1 FROM tab0 AS cor0
----
2154
31
5323

query I rowsort
SELECT - 98 * col2 + col1 FROM tab0 cor0
----
-1
-3148
-7945

onlyif mysql # use DIV operator for integer division
query I rowsort label-7323
SELECT DISTINCT + col1 DIV - 8 AS col1 FROM tab1 cor0
----
-1
-3

skipif mysql # not compatible
query I rowsort label-7323
SELECT DISTINCT + col1 / - 8 AS col1 FROM tab1 cor0
----
-1
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7324
SELECT - + CAST( NULL AS SIGNED ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7324
SELECT - + CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + - col0 + + col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT ( 75 ) FROM tab2
----
75

query I rowsort
SELECT ( 37 ) FROM tab2
----
37
37
37

query I rowsort
SELECT DISTINCT 83 + 50 FROM tab2
----
133

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 47 + - col1 * ( col2 ) - col0 col2 FROM tab1 cor0
----
-1281
-1360
-587

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 * col2 ) col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - + 62 + - 95 AS col2 FROM tab2 AS cor0
----
-157
-157
-157

query I rowsort
SELECT + 39 + + cor0.col2 FROM tab2 AS cor0
----
65
66
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 83 col1 FROM tab1
----
83
83
83

query I rowsort
SELECT + tab0.col2 - + 81 * col1 AS col2 FROM tab0
----
-6933
-7289
-7856

query I rowsort
SELECT - 32 + - 43 AS col1 FROM tab1
----
-75
-75
-75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 39 * - col2 + + col2 col1 FROM tab2
----
-1026
-1444
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-7337
SELECT DISTINCT col0 + + col2 DIV - col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7337
SELECT DISTINCT col0 + + col2 / - col1 FROM tab0
----
24
35
89

query I rowsort
SELECT col1 * cor0.col2 * 37 + - 51 AS col1 FROM tab0 AS cor0
----
104955
276043
3538

query I rowsort
SELECT DISTINCT + col0 + + col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL + col2 * - col1 * col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT + ( - col1 ) + - col0 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT 80 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT + cor0.col2 * - col2 + col0 AS col1 FROM tab2 AS cor0
----
-1365
-598
-722

onlyif mysql # use DIV operator for integer division
query I rowsort label-7344
SELECT DISTINCT + ( col1 ) * + col1 + + 29 DIV + cor0.col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-7344
SELECT DISTINCT + ( col1 ) * + col1 + + 29 / + cor0.col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT cor0.col0 + - col0 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col2 + + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + col2 + + col1 * - 42 AS col0 FROM tab1 AS cor0
----
-1038
-363
-450

query I rowsort
SELECT DISTINCT cor0.col2 * - 46 FROM tab2, tab2 AS cor0
----
-1196
-1242
-1748

query I rowsort
SELECT ALL - col2 + + ( + col2 ) - col2 * + 1 FROM tab0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7350
SELECT + col2 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7350
SELECT + col2 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + ( + col2 ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + tab0.col0 - + ( tab0.col2 * - col0 ) AS col2 FROM tab0
----
70
7387
816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7353
SELECT ALL - CAST( + col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7353
SELECT ALL - CAST ( + col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT ( 40 ) FROM tab0 cor0
----
40

query I rowsort
SELECT ALL + ( 96 ) * col0 + col1 FROM tab1 AS cor0
----
314
6154
7693

query I rowsort
SELECT ALL + - ( - col2 ) * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col0 * - 35 AS col1 FROM tab1 AS cor0
----
-105
-2240
-2800

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - 46 * - col2 + - col1 + CAST ( col0 AS REAL ) FROM tab0 AS cor0
----
-16
1456
3770

query I rowsort
SELECT DISTINCT + col2 * col2 * cor0.col1 AS col0 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT col2 + + col1 * cor0.col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + col1 + col0 * col1 - + 73 FROM tab2 AS cor0
----
1287
175
4588

onlyif mysql # use DIV operator for integer division
query I rowsort label-7362
SELECT ALL + 46 DIV col1 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7362
SELECT ALL + 46 / col1 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT + ( cor0.col0 ) + - col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 44 * cor0.col2 col1 FROM tab1 cor0
----
2376
2508
4224

query I rowsort
SELECT col0 + - 43 FROM tab0 AS cor0
----
-19
-8
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-7366
SELECT + cor0.col2 DIV - 7 + col2 AS col2 FROM tab2 cor0
----
23
24
33

skipif mysql # not compatible
query I rowsort label-7366
SELECT + cor0.col2 / - 7 + col2 AS col2 FROM tab2 cor0
----
23
24
33

query I rowsort
SELECT DISTINCT col2 + + cor0.col1 * col2 * col1 FROM tab0 cor0
----
244101
679124
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-7368
SELECT ALL - 20 DIV - col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7368
SELECT ALL - 20 / - col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + tab0.col1 - + 43 AS col0 FROM tab0
----
43
48
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7370
SELECT + + CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7370
SELECT + + CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 + + col0 * + col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT 1 AS col0 FROM tab2 AS cor0
----
1

query I rowsort
SELECT DISTINCT 13 * 26 + + col2 FROM tab0 AS cor0
----
339
371
420

query I rowsort
SELECT ALL + - cor0.col1 * col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + 2 AS col2 FROM tab1 cor0
----
2
2
2

query I rowsort
SELECT 18 - + col0 FROM tab0 AS cor0
----
-17
-6
-71

query I rowsort
SELECT DISTINCT + + col1 * col0 + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL col0 + col1 * col0 + col0 FROM tab0 AS cor0
----
2112
3465
8277

query I rowsort
SELECT DISTINCT + col2 + col2 * col0 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT + col1 * + cor0.col2 + + col1 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT col1 + col2 * col0 + + col1 AS col1 FROM tab1 AS cor0
----
214
3668
7706

onlyif mysql # use DIV operator for integer division
query I rowsort label-7382
SELECT - col0 DIV col0 + col0 DIV col0 + + col1 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-7382
SELECT - col0 / col0 + col0 / col0 + + col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT col0 * + col2 + - col0 * + col2 FROM tab0
----
0

query I rowsort
SELECT - tab1.col0 * + tab1.col0 * + col2 + tab1.col0 FROM tab1
----
-233408
-483
-614320

query I rowsort
SELECT ALL col2 + + col1 * col1 FROM tab2
----
327
3507
988

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT - col0 = + col2 * + col2 + - col0 * + col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT - col2 * + tab2.col0 + - col0 * col2 * - col0 FROM tab2
----
1134
156156
234156

query I rowsort
SELECT DISTINCT col0 + col2 * - col2 AS col2 FROM tab0
----
-1065
-6635
34

query III rowsort
SELECT * FROM tab0 WHERE NOT + col2 > - col1
----

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( - col0 )
----

query I rowsort
SELECT col1 * + col0 - + col0 * - col0 AS col1 FROM tab0
----
16020
2640
4620

query I rowsort
SELECT + col2 FROM tab1 WHERE col0 BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col0 * - tab2.col2 + - col0 AS col0 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT col0 * col2 + col0 FROM tab0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT ALL - tab1.col1 DIV col0 + - col1 DIV tab1.col2 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-7395
SELECT ALL - tab1.col1 / col0 + - col1 / tab1.col2 FROM tab1
----
-8
0
0

query I rowsort
SELECT ALL - col2 * col2 * tab0.col1 + col2 AS col2 FROM tab0
----
-611802
-93621
-96

query III rowsort
SELECT * FROM tab2 cor0 WHERE - col0 NOT IN ( col0 * - col2 ) OR NOT col1 < NULL
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - + col2 + - col1 * + col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - cor0.col2 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - col1 * cor0.col2 - + col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT + - cor0.col1 + col0 * + col1 AS col2 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT - + col1 + col2 * col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - tab0.col0 * col1 + tab0.col1 AS col0 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT - col2 * col2 * tab1.col1 + - col2 FROM tab1
----
-119904
-32547
-75870

onlyif mysql # use DIV operator for integer division
query I rowsort label-7405
SELECT ALL cor0.col0 DIV tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 24e4a6ab3e4ec87b60e22cd6a5ba10d0

skipif mysql # not compatible
query I rowsort label-7405
SELECT ALL cor0.col0 / tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 24e4a6ab3e4ec87b60e22cd6a5ba10d0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7406
SELECT - col1 + + col2 DIV col0 FROM tab0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-7406
SELECT - col1 + + col2 / col0 FROM tab0
----
-85
-91
-97

query I rowsort
SELECT ALL - tab0.col1 FROM tab0 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT DISTINCT - col2 * col2 * col0 + - col1 * - col0 AS col0 FROM tab0
----
-24072
-590337
3360

onlyif mysql # use DIV operator for integer division
query I rowsort label-7409
SELECT - + cor0.col1 + col1 DIV + col0 + + col2 AS col0 FROM tab2 AS cor0
----
-33
0
21

skipif mysql # not compatible
query I rowsort label-7409
SELECT - + cor0.col1 + col1 / + col0 + + col2 AS col0 FROM tab2 AS cor0
----
-33
0
21

query I rowsort
SELECT DISTINCT col0 * col0 * - col0 FROM tab1 AS cor0
----
-262144
-27
-512000

query I rowsort
SELECT ALL + + col0 - - col2 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT col0 + col0 * col2 AS col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7413
SELECT DISTINCT col0 DIV cor0.col1 + + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-7413
SELECT DISTINCT col0 / cor0.col1 + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - + col2 + col1 * col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ( - col0 ) * col2 * - tab2.col2 FROM tab2
----
114076
5103
52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 73 col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT DISTINCT + col1 * 65 FROM tab1 AS cor0
----
1690
650
845

onlyif mysql # use DIV operator for integer division
query I rowsort label-7419
SELECT col0 DIV col2 + + 89 + - col1 AS col2 FROM tab0 AS cor0
----
-1
27
3

skipif mysql # not compatible
query I rowsort label-7419
SELECT col0 / col2 + + 89 + - col1 AS col2 FROM tab0 AS cor0
----
-1
27
3

query I rowsort
SELECT ALL - - cor0.col0 + - col2 * 46 AS col2 FROM tab2 cor0
----
-1118
-1235
-1669

query I rowsort
SELECT - + col2 + col1 * + 64 FROM tab1 AS cor0
----
1610
583
736

query I rowsort
SELECT col0 * ( 39 ) + + col1 * + col2 + - col0 FROM tab2 AS cor0
----
1103
3648
4498

onlyif mysql # use DIV operator for integer division
query I rowsort label-7423
SELECT DISTINCT - 23 DIV - col0 + + CAST( 74 + col0 AS SIGNED ) AS col2 FROM tab2
----
152
153
84

skipif mysql # not compatible
query I rowsort label-7423
SELECT DISTINCT - 23 / - col0 + + CAST ( 74 + col0 AS INTEGER ) AS col2 FROM tab2
----
152
153
84

query I rowsort
SELECT - - col1 + - cor0.col1 + - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - col2 + 47 AS col1 FROM tab1 cor0
----
-10
-49
-7

query I rowsort
SELECT + col1 * + 96 + - col0 FROM tab2 AS cor0
----
1553
2969
5586

query I rowsort
SELECT + col0 + + ( ( - col0 ) ) + 64 FROM tab1 AS cor0
----
64
64
64

query I rowsort
SELECT col1 * + 12 + col0 + col1 FROM tab2 cor0
----
300
410
845

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col0 col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT col1 AS col1 FROM tab1 WHERE NOT + col0 <> col1 * - col2
----

query I rowsort
SELECT DISTINCT - col2 * + col2 * tab0.col1 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT col0 + col1 * - col1 * - col1 - col0 * col1 AS col0 FROM tab2
----
200855
29581
3649

query I rowsort
SELECT DISTINCT tab2.col1 * col1 + + col2 FROM tab2
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 * col0 col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL col1 * col1 + col1 * - col1 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT - col2 + + col2 * + col2 FROM tab0
----
0
1056
6642

onlyif mysql # use DIV operator for integer division
query I rowsort label-7437
SELECT - cor0.col2 DIV - col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7437
SELECT - cor0.col2 / - col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT col0 * - 81 + + 97 AS col2 FROM tab2
----
-470
-6221
-6302

query I rowsort
SELECT + 94 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + cor0.col2 col0 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col0 + CAST ( - col2 AS REAL ) FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL + 35 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT DISTINCT col2 * 7 * col0 + - col0 + + col2 AS col0 FROM tab0 AS cor0
----
211
51079
5553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7444
SELECT ALL + CAST( + 78 AS SIGNED ) + - col1 AS col2 FROM tab0 AS cor0
----
-13
-19
-8

skipif mysql # not compatible
query I rowsort label-7444
SELECT ALL + CAST ( + 78 AS INTEGER ) + - col1 AS col2 FROM tab0 AS cor0
----
-13
-19
-8

query I rowsort
SELECT + + col1 + cor0.col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7446
SELECT - 26 DIV + col2 FROM tab0 AS cor0
----
-26
0
0

skipif mysql # not compatible
query I rowsort label-7446
SELECT - 26 / + col2 FROM tab0 AS cor0
----
-26
0
0

query I rowsort
SELECT ALL col2 - col2 * - col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7448
SELECT ( + col0 ) + CAST( col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-7448
SELECT ( + col0 ) + CAST ( col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT col1 - + col1 AS col2 FROM tab1
----
0

query I rowsort
SELECT + col1 * col0 + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 33 + col0 * + col0 col1 FROM tab2 cor0
----
6117
6274
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7452
SELECT ALL - CAST( - cor0.col1 AS SIGNED ) AS col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif mysql # not compatible
query I rowsort label-7452
SELECT ALL - CAST ( - cor0.col1 AS INTEGER ) AS col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + 74 * col1 + col0 FROM tab1 AS cor0
----
1042
1927
804

query I rowsort
SELECT + + col1 * + col1 * + cor0.col1 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
636080
753660
912708

onlyif mysql # use DIV operator for integer division
query I rowsort label-7455
SELECT + col1 - col0 DIV - ( + col0 ) AS col2 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-7455
SELECT + col1 - col0 / - ( + col0 ) AS col2 FROM tab1 cor0
----
11
14
27

query I rowsort
SELECT ALL - ( - tab0.col0 ) FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7457
SELECT ALL - col1 + 12 DIV - cor0.col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7457
SELECT ALL - col1 + 12 / - cor0.col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + col2 + 28 FROM tab2 AS cor0
----
54
55
66

query I rowsort
SELECT DISTINCT + col2 + - 54 * col1 FROM tab0 AS cor0
----
-4611
-4832
-5237

query I rowsort
SELECT DISTINCT + + cor0.col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col2 + + ( + 70 ) * col0 AS col1 FROM tab2 AS cor0
----
517
5486
5568

query I rowsort
SELECT ( - col0 ) * - ( + col2 * + tab1.col1 ) - col0 AS col2 FROM tab1
----
36416
4209
99760

query I rowsort
SELECT ALL + - col2 + 91 FROM tab0 AS cor0
----
58
9
90

query I rowsort
SELECT ALL + col2 * 74 AS col2 FROM tab1 cor0
----
3996
4218
7104

onlyif mysql # use DIV operator for integer division
query I rowsort label-7465
SELECT - - col0 + + 85 DIV cor0.col1 FROM tab1 AS cor0
----
6
72
86

skipif mysql # not compatible
query I rowsort label-7465
SELECT - - col0 + + 85 / cor0.col1 FROM tab1 AS cor0
----
6
72
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7466
SELECT ALL + cor0.col2 + - 67 DIV 31 AS col2 FROM tab0 AS cor0
----
-1
31
80

skipif mysql # not compatible
query I rowsort label-7466
SELECT ALL + cor0.col2 + - 67 / 31 AS col2 FROM tab0 AS cor0
----
-1
31
80

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col0 + cor0.col2 * col1 AS col0 FROM tab1 cor0
----
-3078
-6432
1242

query I rowsort
SELECT - col0 + + col2 AS col1 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7469
SELECT DISTINCT + cor0.col2 DIV - col0 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-7469
SELECT DISTINCT + cor0.col2 / - col0 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT ALL + col2 + - tab2.col2 - col0 FROM tab2
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7471
SELECT - cor0.col1 DIV cor0.col0 + - 4 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 05a698e94545aa6d5f08c124df2a840d

skipif mysql # not compatible
query I rowsort label-7471
SELECT - cor0.col1 / cor0.col0 + - 4 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 05a698e94545aa6d5f08c124df2a840d

onlyif mysql # use DIV operator for integer division
query I rowsort label-7472
SELECT + col2 * - 21 - - 88 DIV - col1 AS col1 FROM tab0 AS cor0
----
-1722
-21
-694

skipif mysql # not compatible
query I rowsort label-7472
SELECT + col2 * - 21 - - 88 / - col1 AS col1 FROM tab0 AS cor0
----
-1722
-21
-694

query I rowsort
SELECT - col1 * col0 + 73 + + col2 AS col2 FROM tab0 AS cor0
----
-1958
-3321
-7944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7474
SELECT - - cor0.col1 DIV + ( - 16 ) + col0 col0 FROM tab1 AS cor0
----
2
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7474
SELECT - - cor0.col1 / + ( - 16 ) + col0 col0 FROM tab1 AS cor0
----
2
64
80

query I rowsort
SELECT tab2.col0 * 3 * - col2 AS col0 FROM tab2
----
-567
-6084
-9006

query I rowsort
SELECT DISTINCT col1 * 55 + 40 * col0 FROM tab2
----
1985
4095
6365

query I rowsort
SELECT - col0 + col2 + + col1 AS col2 FROM tab0
----
63
84
95

query I rowsort
SELECT ALL col1 + 57 * 97 FROM tab1
----
5539
5542
5555

query I rowsort
SELECT DISTINCT + col1 + 10 * col2 * - col2 FROM tab2
----
-14423
-6701
-7259

query I rowsort
SELECT - tab1.col2 * + col1 + col1 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT col0 * col0 - + col1 AS col2 FROM tab0
----
1128
490
7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-7482
SELECT ALL - col1 DIV col1 + + col1 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-7482
SELECT ALL - col1 / col1 + + col1 FROM tab0
----
85
90
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7483
SELECT col0 + ( cor0.col0 + + col1 ) * CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
1289
757
804

skipif mysql # not compatible
query I rowsort label-7483
SELECT col0 + ( cor0.col0 + + col1 ) * CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
1289
757
804

query I rowsort
SELECT + col1 + col0 * col2 + col0 FROM tab1
----
191
3722
7773

query I rowsort
SELECT col1 * + col2 + 26 FROM tab0
----
123
2864
7488

query I rowsort
SELECT ALL tab0.col1 + + col0 AS col1 FROM tab0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7487
SELECT CAST( + col0 AS SIGNED ) AS col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7487
SELECT CAST ( + col0 AS INTEGER ) AS col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) col2 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7489
SELECT - col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7489
SELECT - col1 / - col1 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 38 * cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
1330
277324
30096

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col0 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - ( col1 + col1 * 66 ) AS col2 FROM tab0
----
-5762
-6097
-6499

query I rowsort
SELECT ALL tab2.col1 AS col0 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT + - ( - col2 ) * + ( + col1 + col1 ) FROM tab0 AS cor0
----
14924
194
5676

query I rowsort
SELECT ALL + + 86 * - col1 + col1 * 45 * - col0 FROM tab1 AS cor0
----
-29660
-47918
-5746

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col2 + ( - col0 ) col1 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT ALL + - 2 * col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL cor0.col1 + + col0 * + 84 AS col0 FROM tab0 AS cor0
----
2102
3037
7567

query I rowsort
SELECT ALL - ( col0 ) * - 42 AS col0 FROM tab0 AS cor0
----
1008
1470
3738

onlyif mysql # use DIV operator for integer division
query I rowsort label-7500
SELECT ALL + + 57 DIV cor0.col1 FROM tab2 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-7500
SELECT ALL + + 57 / cor0.col1 FROM tab2 AS cor0
----
0
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 67 col0 FROM tab2 AS cor0
----
67

query I rowsort
SELECT ALL - ( col2 ) * 43 + col1 * col1 * + col1 AS col0 FROM tab1 AS cor0
----
-1451
-1931
15254

query I rowsort
SELECT - + 41 * + col0 AS col0 FROM tab2 cor0
----
-287
-3198
-3239

onlyif mysql # use DIV operator for integer division
query I rowsort label-7504
SELECT ALL col1 + col0 DIV + col0 col2 FROM tab2
----
18
32
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7504
SELECT ALL col1 + col0 / + col0 col2 FROM tab2
----
18
32
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7505
SELECT + CAST( NULL AS SIGNED ) / - ( col0 + ( - col0 ) ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7505
SELECT + CAST ( NULL AS INTEGER ) / - ( col0 + ( - col0 ) ) AS col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7506
SELECT DISTINCT - + CAST( NULL AS SIGNED ) FROM tab2, tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7506
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) FROM tab2, tab0, tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7507
SELECT + CAST( NULL AS SIGNED ) + - 97 * + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7507
SELECT + CAST ( NULL AS INTEGER ) + - 97 * + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 59 * col2 AS col1 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT ALL + - cor0.col2 + - col1 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 3 col0 FROM tab1 AS cor0
----
-3
-3
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - col2 + - ( col0 ) col2 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7512
SELECT 64 * + col1 DIV ( - col1 ) + col1 DIV cor0.col0 AS col1 FROM tab2 cor0
----
-60
-64
-64

skipif mysql # not compatible
query I rowsort label-7512
SELECT 64 * + col1 / ( - col1 ) + col1 / cor0.col0 AS col1 FROM tab2 cor0
----
-60
-64
-64

query I rowsort
SELECT DISTINCT - + col2 + - cor0.col0 * ( 16 ) AS col2 FROM tab2 AS cor0
----
-1274
-1302
-139

onlyif mysql # use DIV operator for integer division
query I rowsort label-7514
SELECT + - col0 DIV - col0 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7514
SELECT + - col0 / - col0 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - + col1 + + col2 * 23 - - col2 * - col2 AS col2 FROM tab2 AS cor0
----
-137
-139
-587

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7516
SELECT CAST( NULL AS SIGNED ) + + ( + col2 ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7516
SELECT CAST ( NULL AS INTEGER ) + + ( + col2 ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 * tab0.col2 + tab0.col0 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to fdb9c9b47b35391db5d68fa4ed1dec42

query I rowsort
SELECT col1 * - col0 + col1 * col2 AS col2 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT + ( col0 ) - col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col2 - - col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - col0 * + ( col2 ) AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7522
SELECT - col2 + + CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7522
SELECT - col2 + + CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7523
SELECT DISTINCT + cor0.col1 * - CAST( - col1 AS SIGNED ) * col1 FROM tab1 AS cor0
----
1000
17576
2197

skipif mysql # not compatible
query I rowsort label-7523
SELECT DISTINCT + cor0.col1 * - CAST ( - col1 AS INTEGER ) * col1 FROM tab1 AS cor0
----
1000
17576
2197

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7524
SELECT col1 * CAST( cor0.col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-7524
SELECT col1 * CAST ( cor0.col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - col0 * col0 + + 20 + col1 FROM tab2 AS cor0
----
-6005
-6204
2

query I rowsort
SELECT DISTINCT + + col0 * + 53 - + col0 AS col2 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT ALL + col0 + cor0.col2 * - col0 + col1 * col0 FROM tab1 cor0
----
-2944
-6560
-81

query I rowsort
SELECT DISTINCT - + col1 + col1 * col0 AS col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT DISTINCT - ( + col0 ) * 35 * + 67 FROM tab2
----
-16415
-182910
-185255

query I rowsort
SELECT + - col0 * - 88 AS col2 FROM tab0 AS cor0
----
2112
3080
7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7531
SELECT col1 * CAST( - cor0.col0 * col2 AS SIGNED ) col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7531
SELECT col1 * CAST ( - cor0.col0 * col2 AS INTEGER ) col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + 73 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT - 38 FROM tab0 cor0
----
-38
-38
-38

query I rowsort
SELECT + 90 * col0 AS col2 FROM tab0 AS cor0
----
2160
3150
8010

query I rowsort
SELECT DISTINCT - + 16 + + col1 * cor0.col1 FROM tab2 AS cor0
----
273
3465
945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7536
SELECT - CAST( - cor0.col1 AS SIGNED ) + col0 * + col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif mysql # not compatible
query I rowsort label-7536
SELECT - CAST ( - cor0.col1 AS INTEGER ) + col0 * + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ( 41 ) * col0 FROM tab0 AS cor0
----
1435
3649
984

query I rowsort
SELECT + cor0.col1 + - 3 * - col1 FROM tab1 AS cor0
----
104
40
52

query I rowsort
SELECT ( - ( - col0 ) * - col2 + - col1 ) FROM tab0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col2 col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
54
57
96

query I rowsort
SELECT ( 85 ) AS col0 FROM tab0
----
85
85
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 46 ) col0 FROM tab1 AS cor0
----
-46
-46
-46

query I rowsort
SELECT + + col2 + 38 AS col1 FROM tab1 AS cor0
----
134
92
95

query I rowsort
SELECT - ( - cor0.col1 ) + col1 * col0 AS col1 FROM tab0 cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-7545
SELECT DISTINCT col2 * - col0 DIV col0 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-7545
SELECT DISTINCT col2 * - col0 / col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT 7 * - 22 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 52d2915db41f2130a5d1796d3716f465

query I rowsort
SELECT 57 AS col0 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7548
SELECT col0 DIV + 34 FROM tab2 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-7548
SELECT col0 / + 34 FROM tab2 AS cor0
----
0
2
2

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT - 72 * 86 AS col0 FROM tab2, tab0 AS cor0
----
-6192

query I rowsort
SELECT DISTINCT - col2 * 38 FROM tab2
----
-1026
-1444
-988

query I rowsort
SELECT - col1 + + col2 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT 90 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT + + col1 * 45 FROM tab0 AS cor0
----
3870
4095
4365

query I rowsort
SELECT - + col0 + - 34 * col1 AS col0 FROM tab2 AS cor0
----
-1061
-2084
-657

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7556
SELECT DISTINCT ( col2 ) + + CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7556
SELECT DISTINCT ( col2 ) + + CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7557
SELECT col1 DIV cor0.col0 - 99 * - 84 FROM tab2 AS cor0
----
8316
8316
8320

skipif mysql # not compatible
query I rowsort label-7557
SELECT col1 / cor0.col0 - 99 * - 84 FROM tab2 AS cor0
----
8316
8316
8320

query I rowsort
SELECT ALL - 60 AS col0 FROM tab1 AS cor0
----
-60
-60
-60

query I rowsort
SELECT + 92 AS col1 FROM tab2 cor0
----
92
92
92

query I rowsort
SELECT cor0.col1 * + col0 + - col0 * - col2 AS col2 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT DISTINCT + - col1 * + col2 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL - - 45 * col1 - col1 * col2 FROM tab1 cor0
----
-120
-234
-663

query I rowsort
SELECT ALL + 46 - + col0 AS col2 FROM tab2 AS cor0
----
-32
-33
39

query I rowsort
SELECT DISTINCT + 28 + + col1 * + cor0.col0 FROM tab0 cor0
----
2092
3423
8127

query I rowsort
SELECT 93 * + col0 * 82 + col2 * + col0 AS col1 FROM tab1 AS cor0
----
23040
491712
617760

query I rowsort
SELECT DISTINCT - col1 * + col0 - - col1 FROM tab2
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-7567
SELECT 63 DIV - col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-7567
SELECT 63 / - col0 FROM tab0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - 66 ) * - col1 * 95 - - col1 col1 FROM tab2
----
106607
194401
369989

query I rowsort
SELECT DISTINCT col2 * col2 + + col0 AS col2 FROM tab2
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col0 col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - ( - cor0.col2 ) * col1 + 81 FROM tab0 AS cor0
----
178
2919
7543

query I rowsort
SELECT DISTINCT - 31 * col0 * col0 FROM tab1 AS cor0
----
-126976
-198400
-279

query I rowsort
SELECT DISTINCT - + 35 * col0 * col0 FROM tab2 AS cor0
----
-1715
-212940
-218435

onlyif mysql # use DIV operator for integer division
query I rowsort label-7574
SELECT ALL - + col1 DIV + col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-7574
SELECT ALL - + col1 / + col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7575
SELECT - 55 + col0 * CAST( + 64 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
137
4041
5065

skipif mysql # not compatible
query I rowsort label-7575
SELECT - 55 + col0 * CAST ( + 64 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
137
4041
5065

query I rowsort
SELECT ALL 9 * + col0 AS col0 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT col0 + - col0 + cor0.col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - 61 * col2 * ( + col2 ) + + col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-177798
-197549
-561136

query I rowsort
SELECT tab0.col0 * 74 + col2 AS col0 FROM tab0
----
1809
2591
6668

query I rowsort
SELECT - cor0.col1 + cor0.col0 FROM tab1 cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7581
SELECT + CAST( NULL AS SIGNED ) * col2 * cor0.col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7581
SELECT + CAST ( NULL AS INTEGER ) * col2 * cor0.col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + 33 * + tab1.col2 - - col2 FROM tab1
----
107274
304224
96282

query I rowsort
SELECT 14 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT - 52 * - tab1.col2 AS col1 FROM tab1
----
2808
2964
4992

onlyif mysql # use DIV operator for integer division
query I rowsort label-7585
SELECT + 42 + col1 - col2 DIV - 47 FROM tab1
----
53
57
69

skipif mysql # not compatible
query I rowsort label-7585
SELECT + 42 + col1 - col2 / - 47 FROM tab1
----
53
57
69

query I rowsort
SELECT 39 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2106
2223
3744

query I rowsort
SELECT + - 2 AS col1 FROM tab1 cor0
----
-2
-2
-2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7588
SELECT ALL + col0 + - col0 DIV col1 AS col0 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-7588
SELECT ALL + col0 + - col0 / col1 AS col0 FROM tab1 AS cor0
----
3
58
74

query I rowsort
SELECT ALL - + 51 + + col1 AS col2 FROM tab1 AS cor0
----
-25
-38
-41

query I rowsort
SELECT ALL 10 AS col0 FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT DISTINCT - col1 * 47 + col1 * col0 * cor0.col1 FROM tab2 AS cor0
----
22032
268745
5270

query I rowsort
SELECT DISTINCT - + 67 + col1 AS col0 FROM tab1 AS cor0
----
-41
-54
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 64 * - cor0.col2 + col1 col2 FROM tab0 cor0
----
161
2198
5339

query I rowsort
SELECT ALL col1 * + col1 + cor0.col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT - col2 * col2 + + col0 AS col1 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT col0 + 20 AS col2 FROM tab0 cor0
----
109
44
55

query I rowsort
SELECT DISTINCT + 21 + - 77 FROM tab2 AS cor0
----
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-7598
SELECT ALL - col2 + ( col0 * - col1 ) + col2 DIV col2 FROM tab0 AS cor0
----
-2096
-3395
-8180

skipif mysql # not compatible
query I rowsort label-7598
SELECT ALL - col2 + ( col0 * - col1 ) + col2 / col2 FROM tab0 AS cor0
----
-2096
-3395
-8180

onlyif mysql # use DIV operator for integer division
query I rowsort label-7599
SELECT - 84 + col2 DIV ( col2 ) + col1 FROM tab0 cor0
----
14
3
8

skipif mysql # not compatible
query I rowsort label-7599
SELECT - 84 + col2 / ( col2 ) + col1 FROM tab0 cor0
----
14
3
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * cor0.col0 col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col0 * - cor0.col2 - + 43 AS col1 FROM tab1 AS cor0
----
119
3605
7637

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 58 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT ALL + + cor0.col2 - ( 35 ) AS col0 FROM tab1 cor0
----
19
22
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col1 - col2 col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + - col0 - 93 FROM tab1 AS cor0
----
-157
-173
-96

query I rowsort
SELECT DISTINCT - col2 + + col1 * - 1 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL - + col0 + 80 FROM tab2 AS cor0
----
1
2
73

query I rowsort
SELECT ALL col1 * + col0 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - 4 + - col2 FROM tab1
----
-100
-58
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-7610
SELECT DISTINCT col0 DIV + ( + 15 ) - + col2 * - col0 AS col2 FROM tab2 AS cor0
----
189
2033
3007

skipif mysql # not compatible
query I rowsort label-7610
SELECT DISTINCT col0 / + ( + 15 ) - + col2 * - col0 AS col2 FROM tab2 AS cor0
----
189
2033
3007

query I rowsort
SELECT + col0 * - ( + col1 ) + + col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + cor0.col2 * - ( col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - + 83 AS col0 FROM tab0 AS cor0
----
-83
-83
-83

query I rowsort
SELECT DISTINCT - + ( + col0 ) + - col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT - col0 * 11 AS col0 FROM tab0 AS cor0
----
-264
-385
-979

query I rowsort
SELECT col1 * - col2 + + col1 AS col1 FROM tab2
----
-1475
-629
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7617
SELECT - tab1.col2 * + CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7617
SELECT - tab1.col2 * + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT * FROM tab0, tab2, tab1 cor0 WHERE NULL <= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7619
SELECT + + col2 DIV + 60 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7619
SELECT + + col2 / + 60 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT col0 * - col1 * col2 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - ( + col0 ) * col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7622
SELECT ALL - 9 DIV + 82 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7622
SELECT ALL - 9 / + 82 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - col2 + col1 * col2 AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + 70 FROM tab1, tab0 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

onlyif mysql # use DIV operator for integer division
query I rowsort label-7625
SELECT ALL col1 DIV + col1 + - col0 * ( - col1 ) AS col1 FROM tab0 AS cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-7625
SELECT ALL col1 / + col1 + - col0 * ( - col1 ) AS col1 FROM tab0 AS cor0
----
2065
3396
8100

query I rowsort
SELECT ALL cor0.col2 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + col2 + ( - cor0.col0 * col2 ) FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - col2 + - col0 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT + 78 * - 11 + col2 AS col2 FROM tab1 AS cor0
----
-762
-801
-804

onlyif mysql # use DIV operator for integer division
query I rowsort label-7630
SELECT ALL + col1 DIV col0 + + cor0.col1 col2 FROM tab1 AS cor0
----
10
13
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7630
SELECT ALL + col1 / col0 + + cor0.col1 col2 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT ALL + col0 * col0 + + cor0.col2 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-7632
SELECT + + col2 DIV col2 col0 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7632
SELECT + + col2 / col2 col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + 57 + + col2 FROM tab2 AS cor0
----
83
84
95

query I rowsort
SELECT ALL - 77 AS col2 FROM tab2
----
-77
-77
-77

query I rowsort
SELECT + 31 * col2 * col0 AS col0 FROM tab1 AS cor0
----
113088
238080
5022

query I rowsort
SELECT + - col0 + + col2 * ( + ( - col1 ) ) FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7637
SELECT + col1 + col2 DIV 92 col2 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7637
SELECT + col1 + col2 / 92 col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + col0 + + col2 * col0 + - ( tab1.col1 ) FROM tab1
----
139
3702
7747

query I rowsort
SELECT - col0 - + col1 AS col2 FROM tab1
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col2 ) * col2 + col2 col1 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT + - col0 * col0 + col0 AS col2 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT - - col0 * col0 + 77 AS col2 FROM tab1 AS cor0
----
4173
6477
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7643
SELECT col1 DIV + 32 AS col1 FROM tab0 AS cor0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-7643
SELECT col1 / + 32 AS col1 FROM tab0 AS cor0
----
2
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7644
SELECT DISTINCT - col1 + + col1 DIV + 1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7644
SELECT DISTINCT - col1 + + col1 / + 1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col1 * + 64 AS col0 FROM tab0 AS cor0
----
-5504
-5824
-6208

query I rowsort
SELECT ALL - col0 * col1 + 98 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-3297
-63
1170

query I rowsort
SELECT DISTINCT col0 + - ( 30 ) FROM tab1 AS cor0
----
-27
34
50

query I rowsort
SELECT 97 * - tab0.col2 AS col2 FROM tab0
----
-3201
-7954
-97

query I rowsort
SELECT - col2 * - col1 * col1 AS col2 FROM tab0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * 9 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 416671f40d8e6ee772eb27529693507e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7651
SELECT + ( cor0.col2 ) - - cor0.col2 * CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7651
SELECT + ( cor0.col2 ) - - cor0.col2 * CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7652
SELECT CAST( NULL AS SIGNED ) * col1 + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7652
SELECT CAST ( NULL AS INTEGER ) * col1 + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + 10 * col2 FROM tab2 AS cor0
----
182
263
301

query I rowsort
SELECT - ( - col1 ) * col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col1 + - col1 + 36 * + col1 AS col0 FROM tab2
----
1054
2006
578

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 45 + - 0 col0 FROM tab0
----
134
69
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7657
SELECT col0 DIV 27 FROM tab2
----
0
2
2

skipif mysql # not compatible
query I rowsort label-7657
SELECT col0 / 27 FROM tab2
----
0
2
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7658
SELECT CAST( cor0.col2 AS SIGNED ) + col1 * col2 * - 14 AS col1 FROM tab2 AS cor0
----
-11691
-21450
-9006

skipif mysql # not compatible
query I rowsort label-7658
SELECT CAST ( cor0.col2 AS INTEGER ) + col1 * col2 * - 14 AS col1 FROM tab2 AS cor0
----
-11691
-21450
-9006

query I rowsort
SELECT - col1 + - 50 AS col0 FROM tab0 AS cor0
----
-136
-141
-147

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7660
SELECT ALL + CAST( 34 AS SIGNED ) + - col2 * ( col1 ) FROM tab2 AS cor0
----
-1500
-612
-803

skipif mysql # not compatible
query I rowsort label-7660
SELECT ALL + CAST ( 34 AS INTEGER ) + - col2 * ( col1 ) FROM tab2 AS cor0
----
-1500
-612
-803

query I rowsort
SELECT - tab2.col0 * + 81 FROM tab2
----
-567
-6318
-6399

query I rowsort
SELECT DISTINCT + + col0 * + col0 + col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT - - col2 + - 93 FROM tab2 AS cor0
----
-55
-66
-67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7664
SELECT - - col0 + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7664
SELECT - - col0 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 + + ( 72 ) * col0 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT cor0.col1 * 29 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 049257e79305753e120dece3d0c380dd

query I rowsort
SELECT ALL 15 * + col1 AS col0 FROM tab1
----
150
195
390

query I rowsort
SELECT ALL + + col0 * 76 * col2 FROM tab0 cor0
----
2660
554648
60192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7669
SELECT - + col2 * - CAST( + col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7669
SELECT - + col2 * - CAST ( + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * + 95 + + col1 AS col2 FROM tab1
----
5156
5425
9133

onlyif mysql # use DIV operator for integer division
query I rowsort label-7671
SELECT + col2 + - ( + ( col0 ) ) DIV col0 - - col2 FROM tab2
----
51
53
75

skipif mysql # not compatible
query I rowsort label-7671
SELECT + col2 + - ( + ( col0 ) ) / col0 - - col2 FROM tab2
----
51
53
75

query I rowsort
SELECT DISTINCT + 36 AS col2 FROM tab2, tab1 AS cor0
----
36

query I rowsort
SELECT 75 FROM tab1, tab2 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT DISTINCT + 88 + - ( col1 ) FROM tab0 AS cor0
----
-3
-9
2

query I rowsort
SELECT ALL + col1 + ( col0 ) FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7676
SELECT ALL 53 * col1 * - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7676
SELECT ALL 53 * col1 * - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT cor1.col0 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ALL 40 + + tab2.col2 AS col1 FROM tab2
----
66
67
78

query I rowsort
SELECT DISTINCT + 18 * col0 FROM tab0
----
1602
432
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7681
SELECT 62 + + col1 * CAST( tab1.col1 AS SIGNED ) FROM tab1
----
162
231
738

skipif mysql # not compatible
query I rowsort label-7681
SELECT 62 + + col1 * CAST ( tab1.col1 AS INTEGER ) FROM tab1
----
162
231
738

query I rowsort
SELECT - ( + col0 ) + col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col2 * col1 col0 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col2 col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - col1 * - col2 + + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT col2 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + 9 + col1 AS col0 FROM tab0 AS cor0
----
100
106
95

query I rowsort
SELECT ALL + col2 + + col0 + col1 AS col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT ALL + 9 * col0 AS col1 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT col0 * + col0 + tab1.col2 AS col0 FROM tab1
----
4153
63
6496

query I rowsort
SELECT DISTINCT + + col0 * + col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - col1 * col2 * + col2 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7693
SELECT ALL - + col0 + col1 * - col1 + col2 DIV + col0 FROM tab2 AS cor0
----
-3559
-368
-965

skipif mysql # not compatible
query I rowsort label-7693
SELECT ALL - + col0 + col1 * - col1 + col2 / + col0 FROM tab2 AS cor0
----
-3559
-368
-965

query I rowsort
SELECT DISTINCT - tab2.col2 * + col2 AS col2 FROM tab2
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col2 col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL 50 * ( - col1 ) FROM tab2 AS cor0
----
-1550
-2950
-850

onlyif mysql # use DIV operator for integer division
query I rowsort label-7697
SELECT + ( col2 ) DIV cor0.col0 + col0 FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-7697
SELECT + ( col2 ) / cor0.col0 + col0 FROM tab2 AS cor0
----
10
78
79

query I rowsort
SELECT DISTINCT - 13 + ( col1 ) FROM tab2 AS cor0
----
18
4
46

query I rowsort
SELECT ALL + 55 + col0 FROM tab2
----
133
134
62

query I rowsort
SELECT ALL col2 + ( - col0 ) AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - col1 + + 7 AS col1 FROM tab2
----
-10
-24
-52

query I rowsort
SELECT ALL - + col1 - col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT 96 - col1 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
1439
313
4698

query I rowsort
SELECT ALL + col0 * col1 * col0 + - col1 FROM tab0 AS cor0
----
118728
49450
720720

query I rowsort
SELECT 19 * - col0 * + col1 + + col0 FROM tab2 AS cor0
----
-25438
-4116
-87360

query I rowsort
SELECT DISTINCT + col0 * 35 + + col0 * - col1 AS col2 FROM tab0 cor0
----
-1224
-2170
-4984

query I rowsort
SELECT ALL - cor1.col2 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + - col0 * - col1 * col0 FROM tab2 AS cor0
----
1470
352872
99856

query I rowsort
SELECT DISTINCT + - col0 * col2 + col0 * + col0 FROM tab2 AS cor0
----
-140
3239
4056

query I rowsort
SELECT + - col0 * col1 + - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL + - 40 FROM tab0 AS cor0
----
-40
-40
-40

query I rowsort
SELECT 33 * col0 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT 66 * col0 * col0 FROM tab0 AS cor0
----
38016
522786
80850

query I rowsort
SELECT DISTINCT - - col0 + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - 75 + + tab2.col2 AS col2 FROM tab2
----
-37
-48
-49

query I rowsort
SELECT 71 + col2 - tab1.col1 * tab1.col2 * + col1 FROM tab1
----
-16057
-36379
-5572

query I rowsort
SELECT - col2 * - 73 FROM tab2
----
1898
1971
2774

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 58 col0 FROM tab2
----
-406
-4524
-4582

query I rowsort
SELECT DISTINCT + 79 * - 86 + - col0 * - col0 AS col2 FROM tab1
----
-2698
-394
-6785

query I rowsort
SELECT 70 * - col2 AS col0 FROM tab2 cor0
----
-1820
-1890
-2660

query I rowsort
SELECT - + 52 AS col0 FROM tab2 AS cor0
----
-52
-52
-52

query I rowsort
SELECT DISTINCT col2 * 30 AS col0 FROM tab2
----
1140
780
810

query I rowsort
SELECT ALL + 96 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT - ( - 46 ) FROM tab1
----
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7725
SELECT ALL CAST( ( col1 ) AS SIGNED ) AS col1 FROM tab2 cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-7725
SELECT ALL CAST ( ( col1 ) AS INTEGER ) AS col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT + ( ( + tab1.col1 ) ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT 33 * - col1 FROM tab1
----
-330
-429
-858

query I rowsort
SELECT - 75 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to c0722b1d77ac0ed13c0f2691a5751c59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7729
SELECT + + cor0.col1 / - CAST( NULL AS SIGNED ) + - 95 - - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7729
SELECT + + cor0.col1 / - CAST ( NULL AS INTEGER ) + - 95 - - col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col0 * + ( - col2 ) + col1 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + col0 * + col2 + col2 * - col1 AS col2 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT DISTINCT 25 AS col2 FROM tab1, tab2, tab2 AS cor0
----
25

query I rowsort
SELECT ALL col2 * tab1.col2 + - 50 + - col2 * col2 * 25 AS col1 FROM tab1
----
-221234
-70034
-78026

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 + - col0 * + CAST ( col0 AS REAL ) + - col0 FROM tab1
----
-38
-4170
-6493

query I rowsort
SELECT ALL 74 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7736
SELECT ALL + 89 * col1 + col0 DIV tab0.col0 FROM tab0
----
7655
8100
8634

skipif mysql # not compatible
query I rowsort label-7736
SELECT ALL + 89 * col1 + col0 / tab0.col0 FROM tab0
----
7655
8100
8634

query I rowsort
SELECT DISTINCT + col2 * - ( col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col1 + col2 * 78 FROM tab1 AS cor0
----
4238
4456
7501

query I rowsort
SELECT ALL col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + col2 * col2 + + col2 + col0 * - col0 FROM tab1 AS cor0
----
-790
2912
2961

query I rowsort
SELECT - - col1 + col2 * + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7742
SELECT + cor0.col1 + - CAST( NULL AS SIGNED ) + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7742
SELECT + cor0.col1 + - CAST ( NULL AS INTEGER ) + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + col0 + + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7744
SELECT - col1 + 65 DIV + col0 + + col2 col1 FROM tab2 AS cor0
----
-33
21
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7744
SELECT - col1 + 65 / + col0 + + col2 col1 FROM tab2 AS cor0
----
-33
21
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7745
SELECT + col0 DIV - col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7745
SELECT + col0 / - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - col0 + col0 + + col2 * col0 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + cor0.col1 + col2 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col2 - + ( col2 + col1 ) FROM tab1
----
-124
-134
-205

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7749
SELECT DISTINCT col2 - + CAST( NULL AS DECIMAL ) AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-7749
SELECT DISTINCT col2 - + CAST ( NULL AS REAL ) AS col0 FROM tab2
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7750
SELECT DISTINCT - tab0.col2 - CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7750
SELECT DISTINCT - tab0.col2 - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT ALL + 71 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT + + col0 + + 97 AS col1 FROM tab1 AS cor0
----
100
161
177

query I rowsort
SELECT ( 46 ) * + col2 + - col2 AS col2 FROM tab0 AS cor0
----
1485
3690
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7754
SELECT + + col2 DIV - col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-7754
SELECT + + col2 / - col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7755
SELECT CAST( col1 AS SIGNED ) * col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7755
SELECT CAST ( col1 AS INTEGER ) * col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + 22 col2 FROM tab0 AS cor0
----
-11
-60
21

query I rowsort
SELECT - 59 + - col0 FROM tab2 cor0
----
-137
-138
-66

query I rowsort
SELECT ALL + 25 * cor0.col0 + col1 * + 56 FROM tab0 AS cor0
----
5416
6307
7321

query I rowsort
SELECT DISTINCT 17 * + col0 + col0 AS col2 FROM tab0 cor0
----
1602
432
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-7760
SELECT DISTINCT + col0 + 74 DIV - col2 AS col0 FROM tab1 AS cor0
----
2
63
80

skipif mysql # not compatible
query I rowsort label-7760
SELECT DISTINCT + col0 + 74 / - col2 AS col0 FROM tab1 AS cor0
----
2
63
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7761
SELECT - CAST( NULL AS SIGNED ) * col0 / - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7761
SELECT - CAST ( NULL AS INTEGER ) * col0 / - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + - col2 AS col1 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL + col1 + - ( - col1 ) FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL - 51 + col1 * col0 FROM tab2 AS cor0
----
1292
166
4551

query I rowsort
SELECT + ( - col2 ) * col1 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 + - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT col1 + - col1 * + col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT tab0.col2 * - tab0.col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT 84 + 59 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
143

query I rowsort
SELECT cor0.col0 * col2 + col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT 90 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 5d25a546acf3ae171e731e50adc0112e

query I rowsort
SELECT + 69 * + col0 AS col0 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 * col1 - 13 AS col0 FROM tab1 AS cor0
----
143
637
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7774
SELECT DISTINCT + 11 + - col1 DIV col2 AS col1 FROM tab0 AS cor0
----
-86
10
9

skipif mysql # not compatible
query I rowsort label-7774
SELECT DISTINCT + 11 + - col1 / col2 AS col1 FROM tab0 AS cor0
----
-86
10
9

query I rowsort
SELECT ALL - col1 + col0 + + ( - 93 ) * col1 FROM tab2 AS cor0
----
-1519
-2907
-5468

query I rowsort
SELECT + cor0.col1 + col0 * - col1 * col0 AS col1 FROM tab1 cor0
----
-208
-40950
-83187

query I rowsort
SELECT - col1 * - 82 * - 71 FROM tab1 AS cor0
----
-151372
-58220
-75686

query I rowsort
SELECT ALL col1 + - 82 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1053
-2106
-810

query I rowsort
SELECT ALL + + col0 * + col1 + 72 AS col0 FROM tab2 cor0
----
1415
289
4674

query I rowsort
SELECT DISTINCT - + col1 + col1 * - 75 AS col1 FROM tab2 AS cor0
----
-1292
-2356
-4484

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + cor0.col2 * + cor0.col0 col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT ALL - - col1 * + 67 AS col2 FROM tab0 cor0
----
5762
6097
6499

query I rowsort
SELECT + col2 * + ( 91 * + col0 ) FROM tab1 AS cor0
----
14742
331968
698880

query I rowsort
SELECT ALL - 9 FROM tab0
----
-9
-9
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7785
SELECT DISTINCT col1 + CAST( NULL AS SIGNED ) + col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7785
SELECT DISTINCT col1 + CAST ( NULL AS INTEGER ) + col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT col1 + - col2 * + cor0.col1 * col2 FROM tab2 AS cor0
----
-22568
-24531
-39825

query I rowsort
SELECT DISTINCT + col1 * 26 FROM tab1 AS cor0
----
260
338
676

query I rowsort
SELECT ALL col0 + + col1 * - 93 FROM tab2 cor0
----
-1502
-2876
-5409

query I rowsort
SELECT 30 + - col0 AS col1 FROM tab0 AS cor0
----
-5
-59
6

query I rowsort
SELECT DISTINCT + + col2 * 65 - + col2 * - col2 FROM tab0 AS cor0
----
12054
3234
66

query I rowsort
SELECT + - col0 + - col0 AS col1 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT col1 * 82 + col0 AS col0 FROM tab1 AS cor0
----
1146
2135
884

query I rowsort
SELECT DISTINCT + 9 * col2 + + cor0.col0 * + col0 FROM tab0 AS cor0
----
1234
8659
873

query I rowsort
SELECT - ( 22 ) + + col2 AS col2 FROM tab0 AS cor0
----
-21
11
60

query I rowsort
SELECT ALL - 7 * + 27 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 8c3726ae2cdc4dc867a801e48e80711d

query I rowsort
SELECT col0 * + col1 * col2 AS col2 FROM tab2
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7797
SELECT + CAST( NULL AS SIGNED ) + col1 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7797
SELECT + CAST ( NULL AS INTEGER ) + col1 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 76 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1292
-2356
-4484

query I rowsort
SELECT DISTINCT + + 95 * - cor0.col2 FROM tab1 cor0
----
-5130
-5415
-9120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7800
SELECT ALL + ( + col1 ) + col1 * 62 * col2 + + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7800
SELECT ALL + ( + col1 ) + col1 * 62 * col2 + + 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-7801
SELECT DISTINCT - 56 DIV col0 + col0 + - col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-2042
-3361
-8010

skipif mysql # not compatible
query I rowsort label-7801
SELECT DISTINCT - 56 / col0 + col0 + - col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-2042
-3361
-8010

query I rowsort
SELECT ALL 80 - - col2 * - col1 FROM tab0 AS cor0
----
-17
-2758
-7382

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7803
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - 65 + + col0 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7803
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - 65 + + col0 col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ( col2 ) + col2 * - col0 AS col1 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - ( - col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col0 * col1 + cor0.col2 AS col0 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT ALL - 89 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to 1e1759ead845b97a0ef58dbd6a959d73

query I rowsort
SELECT + 51 AS col1 FROM tab2 AS cor0
----
51
51
51

query I rowsort
SELECT DISTINCT + cor1.col1 AS col1 FROM tab0, tab1 cor0, tab0 cor1
----
86
91
97

query I rowsort
SELECT DISTINCT + tab0.col2 AS col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
1
33
82

query I rowsort
SELECT ALL 33 + + tab0.col2 FROM tab0
----
115
34
66

query I rowsort
SELECT ALL + - cor0.col2 * col1 * ( - 58 ) + col1 AS col2 FROM tab1 AS cor0
----
33070
72397
81458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 * col2 + col0 * col0 col1 FROM tab1 cor0
----
4723
603
7456

query I rowsort
SELECT + - col2 + - col1 + - col1 FROM tab0 AS cor0
----
-195
-205
-264

query I rowsort
SELECT ALL 91 * - col1 FROM tab2 AS cor0
----
-1547
-2821
-5369

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - - 7 + col2 AS col0 FROM tab1 AS cor0
----
103
61
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-7818
SELECT DISTINCT + col1 * - col2 + 55 DIV col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-7818
SELECT DISTINCT + col1 * - col2 + 55 / col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL cor0.col2 * + col0 + col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - col2 + col2 + col1 * tab1.col1 * 89 FROM tab1
----
15041
60164
8900

query I rowsort
SELECT ALL col2 + col2 * col1 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7822
SELECT + 74 DIV col0 FROM tab1
----
0
1
24

skipif mysql # not compatible
query I rowsort label-7822
SELECT + 74 / col0 FROM tab1
----
0
1
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7823
SELECT + col2 DIV col1 + ( - 38 + col2 ) FROM tab2 AS cor0
----
-11
-12
2

skipif mysql # not compatible
query I rowsort label-7823
SELECT + col2 / col1 + ( - 38 + col2 ) FROM tab2 AS cor0
----
-11
-12
2

query I rowsort
SELECT - + col1 * + col0 + - 62 AS col0 FROM tab1 AS cor0
----
-1102
-140
-702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - tab1.col2 col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT col1 + 47 + + col2 AS col1 FROM tab0
----
145
166
220

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 19 col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT ALL - col2 * col1 * + 44 FROM tab0 AS cor0
----
-124872
-328328
-4268

query I rowsort
SELECT DISTINCT 86 + 66 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
152

query I rowsort
SELECT ALL - col1 + - col2 - + col0 FROM tab2
----
-134
-163
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 col2 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to dfada1ee7a4e3e5c74a063a1282769f9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7832
SELECT ALL + CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7832
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 38 * col1 AS col2 FROM tab2
----
-1178
-2242
-646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + ( col0 * - tab0.col0 ) col2 FROM tab0
----
-118825
-49536
-720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7835
SELECT DISTINCT - 33 * 30 + col2 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7835
SELECT DISTINCT - 33 * 30 + col2 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT + col0 * col1 * + col2 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-7837
SELECT ALL - tab1.col2 DIV col1 + col2 AS col2 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-7837
SELECT ALL - tab1.col2 / col1 + col2 AS col2 FROM tab1
----
52
52
89

query I rowsort
SELECT DISTINCT + + col2 + - cor0.col2 * + col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT + col0 * cor0.col2 * col2 FROM tab0 cor0
----
26136
35
598436

query I rowsort
SELECT 10 + 80 + col2 AS col1 FROM tab2 AS cor0
----
116
117
128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 60 * col1 col1 FROM tab0 AS cor0
----
-5160
-5460
-5820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col1 FROM tab2 cor0
----
25
25
25

query I rowsort
SELECT DISTINCT 21 AS col1 FROM tab0 AS cor0
----
21

query I rowsort
SELECT - - col2 + - 1 + + col1 FROM tab2 AS cor0
----
54
57
84

query I rowsort
SELECT cor0.col1 + + 82 AS col2 FROM tab1 AS cor0
----
108
92
95

query I rowsort
SELECT DISTINCT + col1 * + ( col0 ) FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - col2 col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + col0 * col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - - col2 + - ( col1 * + col2 ) AS col0 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT col1 + ( - col0 ) FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - cor0.col0 + - col2 * cor0.col0 * ( + col1 ) col1 FROM tab0 AS cor0
----
-656019
-66048
0

query I rowsort
SELECT + ( 0 ) * cor0.col1 * - 77 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - col2 + col2 * col0 AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL - col0 + - col0 * col2 AS col2 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT + - col0 * col2 + - 86 * - 34 AS col1 FROM tab1 AS cor0
----
-4756
-724
2762

query I rowsort
SELECT DISTINCT + + cor0.col0 + 21 AS col0 FROM tab1, tab2 AS cor0
----
100
28
99

query I rowsort
SELECT DISTINCT - 77 * ( tab2.col1 + ( - col1 ) ) AS col0 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7858
SELECT - tab0.col0 DIV col0 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7858
SELECT - tab0.col0 / col0 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL 72 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT DISTINCT col0 + tab2.col2 * tab2.col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT - col0 + ( col2 + col0 ) AS col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-7862
SELECT + col1 + col2 DIV col1 col1 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7862
SELECT + col1 + col2 / col1 col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7863
SELECT 30 * tab1.col2 DIV - col2 AS col0 FROM tab1
----
-30
-30
-30

skipif mysql # not compatible
query I rowsort label-7863
SELECT 30 * tab1.col2 / - col2 AS col0 FROM tab1
----
-30
-30
-30

query I rowsort
SELECT - 76 * + tab1.col0 AS col0 FROM tab1
----
-228
-4864
-6080

query I rowsort
SELECT ALL - - cor0.col0 * col2 + - col0 * col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + + ( + col0 ) * - col1 AS col2 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7867
SELECT ALL + col1 * ( col2 ) + - col1 * CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7867
SELECT ALL + col1 * ( col2 ) + - col1 * CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + - ( col0 * col0 ) AS col0 FROM tab2 AS cor0
----
-6110
-6279
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col1 col1 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - col1 + + ( + col1 ) AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 66 * 67 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f7736c38eb755788b89aed4b593d04c3

query I rowsort
SELECT DISTINCT + 71 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
71

query I rowsort
SELECT - col1 + col2 + col2 AS col2 FROM tab0
----
-20
-95
73

query I rowsort
SELECT ALL + col0 * + tab2.col2 - col2 AS col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT DISTINCT - 73 FROM tab0, tab1 AS cor0
----
-73

query I rowsort
SELECT ALL + col1 - col1 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - ( + col2 + col2 ) col1 FROM tab0 AS cor0
----
-14596
-1584
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7878
SELECT - tab0.col1 DIV - 64 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7878
SELECT - tab0.col1 / - 64 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7879
SELECT + col0 + col0 DIV cor0.col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-7879
SELECT + col0 + col0 / cor0.col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT - col2 * + 46 FROM tab2 AS cor0
----
-1196
-1242
-1748

query I rowsort
SELECT + 16 AS col0 FROM tab2
----
16
16
16

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7882
SELECT + CAST( NULL AS SIGNED ) + + col1 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7882
SELECT + CAST ( NULL AS INTEGER ) + + col1 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + - 78 AS col0 FROM tab0
----
-45
-77
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7884
SELECT - CAST( NULL AS SIGNED ) * - col1 + col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7884
SELECT - CAST ( NULL AS INTEGER ) * - col1 + col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 + 13 * cor0.col0 FROM tab1 AS cor0
----
1053
65
842

query I rowsort
SELECT + ( + 58 * - col2 ) FROM tab1
----
-3132
-3306
-5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-7887
SELECT ALL + col2 DIV + 74 AS col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7887
SELECT ALL + col2 / + 74 AS col0 FROM tab0
----
0
0
1

query I rowsort
SELECT DISTINCT + col0 + + ( col1 ) + col1 * - col2 FROM tab1
----
-1155
-1375
-496

query I rowsort
SELECT ( col1 ) * 77 FROM tab1 cor0
----
1001
2002
770

onlyif mysql # use DIV operator for integer division
query I rowsort label-7890
SELECT 1 * col0 DIV - col2 - - col0 FROM tab1
----
3
63
80

skipif mysql # not compatible
query I rowsort label-7890
SELECT 1 * col0 / - col2 - - col0 FROM tab1
----
3
63
80

query I rowsort
SELECT ALL 3 AS col0 FROM tab2 cor0
----
3
3
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7892
SELECT ALL + 17 * col2 * + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7892
SELECT ALL + 17 * col2 * + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 51 * - col1 AS col0 FROM tab0 AS cor0
----
-4386
-4641
-4947

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-7895
SELECT - + 1 DIV + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7895
SELECT - + 1 / + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + + cor0.col0 * + cor0.col0 FROM tab1 cor0
----
-17
4086
6387

onlyif mysql # use DIV operator for integer division
query I rowsort label-7897
SELECT tab1.col2 DIV + 54 + - col1 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-7897
SELECT tab1.col2 / + 54 + - col1 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT col0 * 95 FROM tab0
----
2280
3325
8455

query I rowsort
SELECT + col2 - 81 AS col2 FROM tab2
----
-43
-54
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - 62 col0 FROM tab1
----
-36
-49
-52

query I rowsort
SELECT tab1.col2 * + col2 * - col2 - col1 FROM tab1
----
-157490
-185203
-884749

query I rowsort
SELECT tab2.col1 + 49 * col0 FROM tab2
----
374
3881
3888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 67 col0 FROM tab1 AS cor0
----
121
124
163

query I rowsort
SELECT - col0 * - col0 + + 61 * cor0.col2 FROM tab2 AS cor0
----
1696
7670
8559

query IIIIIIIII rowsort
SELECT * FROM tab1, tab1 cor0 CROSS JOIN tab0 cor1
----
243 values hashing to 3a953203ced079e372111d61dbd9e35f

query I rowsort
SELECT + 80 * + col0 FROM tab0 AS cor0
----
1920
2800
7120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7907
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7907
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 27 * col0 col0 FROM tab1 AS cor0
----
1728
2160
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7909
SELECT ALL CAST( + col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-7909
SELECT ALL CAST ( + col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7910
SELECT + col1 + tab2.col2 DIV - col0 FROM tab2
----
17
28
59

skipif mysql # not compatible
query I rowsort label-7910
SELECT + col1 + tab2.col2 / - col0 FROM tab2
----
17
28
59

query I rowsort
SELECT DISTINCT cor0.col0 + - cor0.col0 * + col1 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT - + col2 + - 1 * + col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL 86 * col2 * col1 AS col2 FROM tab2 cor0
----
131924
55556
71982

onlyif mysql # use DIV operator for integer division
query I rowsort label-7914
SELECT DISTINCT - + ( 40 ) DIV col0 col2 FROM tab0 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7914
SELECT DISTINCT - + ( 40 ) / col0 col2 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT 16 * col2 AS col2 FROM tab1 AS cor0
----
1536
864
912

query I rowsort
SELECT DISTINCT - 50 * ( + cor0.col0 ) FROM tab2 AS cor0
----
-350
-3900
-3950

query I rowsort
SELECT ALL - - col0 * 5 FROM tab0 cor0
----
120
175
445

query I rowsort
SELECT DISTINCT - + 49 * + col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT - col2 * - col1 + col2 AS col1 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7920
SELECT ALL ( - cor0.col1 ) * col2 DIV - 82 AS col2 FROM tab1 AS cor0
----
15
17
6

skipif mysql # not compatible
query I rowsort label-7920
SELECT ALL ( - cor0.col1 ) * col2 / - 82 AS col2 FROM tab1 AS cor0
----
15
17
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 52 - - col2 col2 FROM tab1
----
106
109
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-7922
SELECT - col0 + - col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-7922
SELECT - col0 + - col1 / col1 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - + col0 col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL 96 + cor0.col1 + cor0.col1 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9396ca4b525b71fe1346d2c8a09848f2

query I rowsort
SELECT - cor0.col0 - col2 * + col2 * + col1 FROM tab1 AS cor0
----
-119888
-32554
-75819

query I rowsort
SELECT ALL col1 + - col0 * cor0.col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + 16 + - col1 FROM tab0 AS cor0
----
-70
-75
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-7928
SELECT DISTINCT - col0 + - col2 DIV - ( + col0 * col0 ) FROM tab1 cor0
----
-64
-80
3

skipif mysql # not compatible
query I rowsort label-7928
SELECT DISTINCT - col0 + - col2 / - ( + col0 * col0 ) FROM tab1 cor0
----
-64
-80
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7929
SELECT ALL - - col0 + col2 - CAST( col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
100
3
45

skipif mysql # not compatible
query I rowsort label-7929
SELECT ALL - - col0 + col2 - CAST ( col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT - 85 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 91e44ead5e72fa22f87a57243e232ede

query I rowsort
SELECT - + col0 * + col2 + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL col1 + - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + col1 * - ( + col2 ) + - col2 FROM tab1 cor0
----
-1344
-1458
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-7934
SELECT + col2 + col0 DIV - col1 AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7934
SELECT + col2 + col0 / - col1 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL + cor0.col0 + cor0.col0 + 3 FROM tab0 AS cor0
----
181
51
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + ( col2 ) col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - - col2 + ( 93 ) AS col2 FROM tab2 AS cor0
----
119
120
131

query I rowsort
SELECT + col0 - 55 FROM tab2 AS cor0
----
-48
23
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7939
SELECT DISTINCT - + col0 + 95 DIV - col2 AS col1 FROM tab0 cor0
----
-130
-26
-90

skipif mysql # not compatible
query I rowsort label-7939
SELECT DISTINCT - + col0 + 95 / - col2 AS col1 FROM tab0 cor0
----
-130
-26
-90

query I rowsort
SELECT DISTINCT + col0 + 52 AS col2 FROM tab0 cor0
----
141
76
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-7941
SELECT - - col2 + 7 DIV - 67 FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-7941
SELECT - - col2 + 7 / - 67 FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7942
SELECT ALL - + col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7942
SELECT ALL - + col0 / - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + ( cor0.col0 ) FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 * 60 + - col1 * - col0 * - 75 AS col1 FROM tab1 AS cor0
----
-293760
-462000
-6390

query I rowsort
SELECT DISTINCT - + cor0.col1 + + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + col2 * col0 + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT ALL - col2 * 7 AS col2 FROM tab0 AS cor0
----
-231
-574
-7

query I rowsort
SELECT DISTINCT + col1 * 1 + - col1 * + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL + col0 * + ( ( cor0.col0 ) ) + - col2 AS col0 FROM tab2 AS cor0
----
22
6058
6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7950
SELECT - + col1 + CAST( col2 AS SIGNED ) * + col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

skipif mysql # not compatible
query I rowsort label-7950
SELECT - + col1 + CAST ( col2 AS INTEGER ) * + col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT - col1 * ( ( col0 ) ) - 59 AS col1 FROM tab2 AS cor0
----
-1402
-276
-4661

query I rowsort
SELECT + col2 * + 47 * - col1 + col0 FROM tab0 AS cor0
----
-133362
-350625
-4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 - - col0 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + + cor0.col2 * + cor0.col0 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1260
1368
15219

query I rowsort
SELECT col1 * - 36 AS col1 FROM tab2 cor0
----
-1116
-2124
-612

query I rowsort
SELECT ALL + col2 - - ( col1 + + col1 ) FROM tab0 AS cor0
----
195
205
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7957
SELECT - - ( + col2 ) * cor0.col0 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7957
SELECT - - ( + col2 ) * cor0.col0 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * - ( col0 ) + + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL - - cor0.col2 + - cor0.col2 * col1 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT col1 * col0 + 44 AS col0 FROM tab0 AS cor0
----
2108
3439
8143

query I rowsort
SELECT ALL + - ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - + col2 + - col1 + cor0.col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col1 * + col1 * - col0 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT - 91 AS col0 FROM tab0
----
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col0 col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + 95 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

onlyif mysql # use DIV operator for integer division
query I rowsort label-7967
SELECT DISTINCT - 87 + cor0.col0 DIV CAST( col1 + - col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-43
-87

skipif mysql # not compatible
query I rowsort label-7967
SELECT DISTINCT - 87 + cor0.col0 / CAST ( col1 + - col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-43
-87

query I rowsort
SELECT col2 * - col1 + ( + ( - col0 ) * col0 ) FROM tab1
----
-1413
-4666
-7648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7969
SELECT ALL + CAST( 29 AS SIGNED ) + - col2 * + ( col0 ) FROM tab2
----
-160
-1999
-2973

skipif mysql # not compatible
query I rowsort label-7969
SELECT ALL + CAST ( 29 AS INTEGER ) + - col2 * + ( col0 ) FROM tab2
----
-160
-1999
-2973

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7970
SELECT ALL + col2 * + tab1.col2 + - col1 + CAST( - 32 AS SIGNED ) * + col1 AS col0 FROM tab1
----
2058
2919
8787

skipif mysql # not compatible
query I rowsort label-7970
SELECT ALL + col2 * + tab1.col2 + - col1 + CAST ( - 32 AS INTEGER ) * + col1 AS col0 FROM tab1
----
2058
2919
8787

query I rowsort
SELECT DISTINCT + 29 + + col2 * col2 * - col2 AS col0 FROM tab1 AS cor0
----
-157435
-185164
-884707

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-7973
SELECT - CAST( 41 AS SIGNED ) + + col1 AS col2 FROM tab1 cor0
----
-15
-28
-31

skipif mysql # not compatible
query I rowsort label-7973
SELECT - CAST ( 41 AS INTEGER ) + + col1 AS col2 FROM tab1 cor0
----
-15
-28
-31

query I rowsort
SELECT - 19 + col1 - ( 61 ) AS col1 FROM tab1 cor0
----
-54
-67
-70

query I rowsort
SELECT col0 * + cor0.col1 * col0 + col1 + - col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT + ( col1 ) + - col2 + 78 * col2 FROM tab1 cor0
----
4184
4399
7405

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7977
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 66 col2 FROM tab1, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7977
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 66 col2 FROM tab1, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col1 * col0 + cor0.col1 + - col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + 38 col1 FROM tab0 AS cor0
----
-1330
-3382
-912

onlyif mysql # use DIV operator for integer division
query I rowsort label-7980
SELECT ALL - col2 * cor0.col1 + cor0.col1 DIV col0 FROM tab1 AS cor0
----
-1248
-1396
-570

skipif mysql # not compatible
query I rowsort label-7980
SELECT ALL - col2 * cor0.col1 + cor0.col1 / col0 FROM tab1 AS cor0
----
-1248
-1396
-570

query I rowsort
SELECT DISTINCT - col2 + 13 AS col0 FROM tab0 AS cor0
----
-20
-69
12

query I rowsort
SELECT cor0.col1 * + cor0.col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to aff311fa1b3948e179779cc03c1fade4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7983
SELECT + + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7983
SELECT + + col1 * 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-7984
SELECT ALL + col2 DIV + CAST( cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-7984
SELECT ALL + col2 / + CAST ( cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + ( cor1.col1 ) * 14 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 81cca8049cc111919bf52b8390e5906f

query I rowsort
SELECT - col1 * ( - col1 + col1 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7987
SELECT - col2 DIV ( - col0 ) col1 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7987
SELECT - col2 / ( - col0 ) col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT - tab2.col1 * 32 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 77f9e6b8a5708b36d6f0f4b9bf8ecc0b

query I rowsort
SELECT + col1 + col0 * col1 AS col0 FROM tab1
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT cor1.col1 + - 60 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to d5a625584122e36f4240169d335ca1ca

query I rowsort
SELECT ALL + cor0.col2 * 71 FROM tab1 AS cor0
----
3834
4047
6816

query I rowsort
SELECT DISTINCT + 99 * - col2 * + col0 FROM tab2 AS cor0
----
-18711
-200772
-297198

query I rowsort
SELECT DISTINCT + - 31 * 43 AS col1 FROM tab0 AS cor0
----
-1333

query I rowsort
SELECT ALL - + col2 + col1 + - col1 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7996
SELECT DISTINCT 99 * + cor0.col0 + CAST( col1 AS SIGNED ) * + col1 + ( + col0 ) FROM tab0 AS cor0
----
12909
17181
9796

skipif mysql # not compatible
query I rowsort label-7996
SELECT DISTINCT 99 * + cor0.col0 + CAST ( col1 AS INTEGER ) * + col1 + ( + col0 ) FROM tab0 AS cor0
----
12909
17181
9796

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col0 col1 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col1 * col0 + ( 31 ) + col0 * - 47 AS col2 FROM tab0 AS cor0
----
-12251
-3161
-5009

onlyif mysql # use DIV operator for integer division
query I rowsort label-7999
SELECT DISTINCT + 19 DIV col0 + col2 + - ( col1 ) AS col2 FROM tab1 AS cor0
----
34
47
83

skipif mysql # not compatible
query I rowsort label-7999
SELECT DISTINCT + 19 / col0 + col2 + - ( col1 ) AS col2 FROM tab1 AS cor0
----
34
47
83

query I rowsort
SELECT DISTINCT ( + 76 + + tab0.col2 ) FROM tab0
----
109
158
77

query I rowsort
SELECT DISTINCT col1 + - col2 * - ( - cor0.col0 ) * - 44 FROM tab2 cor0
----
132105
8347
89291

query I rowsort
SELECT cor0.col0 * col2 * + 39 AS col1 FROM tab2 AS cor0
----
117078
7371
79092

query I rowsort
SELECT DISTINCT + col1 * 74 AS col0 FROM tab1 AS cor0
----
1924
740
962

skipif mysql # not compatible
query I rowsort
SELECT - col0 + - CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL + cor0.col2 + + 33 * col2 AS col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT + cor0.col1 + ( col0 + cor0.col0 ) AS col0 FROM tab0 AS cor0
----
134
167
269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8007
SELECT DISTINCT - col0 + CAST( NULL AS DECIMAL ) * col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8007
SELECT DISTINCT - col0 + CAST ( NULL AS REAL ) * col2 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col0 * col0 * col0 AS col0 FROM tab2
----
343
474552
493039

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * ( - col0 ) col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + ( 36 ) col2 FROM tab1 cor0
----
100
116
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + + 76 col2 FROM tab2 AS cor0
----
-2
-3
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( - cor0.col2 ) * col0 + cor0.col0 col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT col1 * col2 * - 97 + - col1 FROM tab1 AS cor0
----
-121069
-136214
-55300

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) * + col2 + col1 * col2 FROM tab0 AS cor0
----
1749
738
96

query I rowsort
SELECT - + 38 + - col0 FROM tab2 AS cor0
----
-116
-117
-45

query I rowsort
SELECT ALL - 88 * - col0 FROM tab1 AS cor0
----
264
5632
7040

query I rowsort
SELECT + 48 * col0 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT tab0.col0 + + col1 * + col2 - col1 FROM tab0
----
2776
35
7460

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL + + col2 * - col1 - 45 FROM tab1 AS cor0
----
-1293
-1449
-615

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8021
SELECT + col0 + + col0 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8021
SELECT + col0 + + col0 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 38 + + col0 FROM tab1
----
-35
26
42

query I rowsort
SELECT DISTINCT col1 + - col1 * + tab2.col2 AS col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + tab2.col2 + - col2 * - col2 AS col1 FROM tab2
----
1482
702
756

query I rowsort
SELECT DISTINCT tab0.col1 + col0 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT + col2 + + ( + col1 ) * col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL 16 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT DISTINCT col2 * col2 + col2 AS col2 FROM tab2
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-8029
SELECT - 51 DIV - col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8029
SELECT - 51 / - col0 FROM tab0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col2 FROM tab0, tab1 cor0
----
3
64
80

query I rowsort
SELECT cor0.col0 - + 7 FROM tab2, tab1 cor0
----
9 values hashing to 42260f035594d239700298b52eeab68f

query I rowsort
SELECT + col0 * col2 + - col0 * + col2 * col0 AS col2 FROM tab1
----
-229824
-324
-606720

onlyif mysql # use DIV operator for integer division
query I rowsort label-8033
SELECT col2 + col2 DIV - ( col2 ) FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-8033
SELECT col2 + col2 / - ( col2 ) FROM tab0
----
0
32
81

query I rowsort
SELECT ALL 50 * col0 + col1 AS col0 FROM tab1
----
176
3210
4013

query I rowsort
SELECT - col1 * col2 - + col1 FROM tab0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-8036
SELECT + col0 DIV col0 + col0 AS col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-8036
SELECT + col0 / col0 + col0 AS col0 FROM tab0
----
25
36
90

query I rowsort
SELECT ALL + 47 + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1296
-170
-4555

query I rowsort
SELECT - 45 * col1 AS col2 FROM tab0 AS cor0
----
-3870
-4095
-4365

query I rowsort
SELECT DISTINCT - 60 * + col2 AS col0 FROM tab0 cor0
----
-1980
-4920
-60

query I rowsort
SELECT + 95 + 85 FROM tab2 AS cor0
----
180
180
180

query I rowsort
SELECT 95 + col0 FROM tab2 AS cor0
----
102
173
174

query I rowsort
SELECT ALL + - 70 * + 24 + col2 AS col1 FROM tab0 AS cor0
----
-1598
-1647
-1679

onlyif mysql # use DIV operator for integer division
query I rowsort label-8043
SELECT DISTINCT - col2 + - col2 - col0 DIV ( + col2 ) FROM tab0 AS cor0
----
-165
-37
-66

skipif mysql # not compatible
query I rowsort label-8043
SELECT DISTINCT - col2 + - col2 - col0 / ( + col2 ) FROM tab0 AS cor0
----
-165
-37
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-8044
SELECT ALL - tab1.col2 * ( - col1 ) DIV + col0 FROM tab1
----
15
468
8

skipif mysql # not compatible
query I rowsort label-8044
SELECT ALL - tab1.col2 * ( - col1 ) / + col0 FROM tab1
----
15
468
8

query I rowsort
SELECT ALL + col2 * + 0 * - col2 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col2 + - ( 14 ) AS col2 FROM tab1
----
40
43
82

query I rowsort
SELECT 99 + + 14 FROM tab0
----
113
113
113

query I rowsort
SELECT DISTINCT + col0 * 5 AS col2 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT + cor0.col1 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8050
SELECT ALL + CAST( 3 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-8050
SELECT ALL + CAST ( 3 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT - 15 * col0 FROM tab0 AS cor0
----
-1335
-360
-525

query I rowsort
SELECT ALL + ( 73 ) * - col2 AS col2 FROM tab0 AS cor0
----
-2409
-5986
-73

query I rowsort
SELECT ALL + - col0 + + col2 - col2 AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + 38 + col0 FROM tab1 AS cor0
----
102
118
41

query I rowsort
SELECT ALL - 39 * col1 - - cor0.col2 FROM tab0 AS cor0
----
-3321
-3467
-3782

query I rowsort
SELECT - + 91 * cor0.col1 FROM tab2 AS cor0
----
-1547
-2821
-5369

query I rowsort
SELECT DISTINCT + 33 AS col1 FROM tab1 AS cor0
----
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8058
SELECT - + CAST( col2 AS SIGNED ) FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8058
SELECT - + CAST ( col2 AS INTEGER ) FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 60 * - col1 AS col2 FROM tab0
----
-5160
-5460
-5820

query I rowsort
SELECT DISTINCT 9 * col0 FROM tab0
----
216
315
801

query I rowsort
SELECT - ( col2 * + col0 ) AS col1 FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 + col1 col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + 80 AS col0 FROM tab2 cor0
----
80
80
80

query I rowsort
SELECT DISTINCT - - col0 + - col1 + col2 FROM tab0 AS cor0
----
-29
-61
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * + col0 * col1 col1 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT - col0 - cor0.col0 * col2 FROM tab0 cor0
----
-70
-7387
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-8067
SELECT ALL - ( - col2 ) DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8067
SELECT ALL - ( - col2 ) / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 32 - - col2 AS col2 FROM tab2 AS cor0
----
58
59
70

query I rowsort
SELECT 72 * col1 - col1 AS col0 FROM tab0 cor0
----
6106
6461
6887

query I rowsort
SELECT DISTINCT + - 15 FROM tab0 AS cor0
----
-15

query I rowsort
SELECT ALL - col2 * + col1 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT 7 + cor0.col2 AS col1 FROM tab2 AS cor0
----
33
34
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-8073
SELECT + - 81 DIV - col1 AS col2 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-8073
SELECT + - 81 / - col1 AS col2 FROM tab2 AS cor0
----
1
2
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-8074
SELECT + col1 + col0 * cor0.col1 DIV - col2 FROM tab0 AS cor0
----
-3298
-7
24

skipif mysql # not compatible
query I rowsort label-8074
SELECT + col1 + col0 * cor0.col1 / - col2 FROM tab0 AS cor0
----
-3298
-7
24

query I rowsort
SELECT DISTINCT + cor0.col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + cor0.col0 + ( - col0 ) * col0 + col1 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-3392
-5280
72

query I rowsort
SELECT col0 + - 81 + + col0 AS col0 FROM tab2 AS cor0
----
-67
75
77

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + - 98 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT ALL col1 * cor0.col2 + - col2 * + col1 AS col1 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8081
SELECT DISTINCT col2 * 88 - 1 DIV col0 FROM tab1 AS cor0
----
4752
5016
8448

skipif mysql # not compatible
query I rowsort label-8081
SELECT DISTINCT col2 * 88 - 1 / col0 FROM tab1 AS cor0
----
4752
5016
8448

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8082
SELECT ALL + + col0 * CAST( + col0 AS SIGNED ) + cor0.col2 AS col0 FROM tab1 cor0
----
4153
63
6496

skipif mysql # not compatible
query I rowsort label-8082
SELECT ALL + + col0 * CAST ( + col0 AS INTEGER ) + cor0.col2 AS col0 FROM tab1 cor0
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-8083
SELECT - col0 DIV - col1 + 80 FROM tab2 AS cor0
----
80
81
84

skipif mysql # not compatible
query I rowsort label-8083
SELECT - col0 / - col1 + 80 FROM tab2 AS cor0
----
80
81
84

query I rowsort
SELECT - cor0.col1 + + cor0.col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + - col2 + - 79 + - col2 FROM tab2 AS cor0
----
-131
-133
-155

onlyif mysql # use DIV operator for integer division
query I rowsort label-8086
SELECT + 33 + + col1 DIV - col1 FROM tab1 AS cor0
----
32
32
32

skipif mysql # not compatible
query I rowsort label-8086
SELECT + 33 + + col1 / - col1 FROM tab1 AS cor0
----
32
32
32

query I rowsort
SELECT DISTINCT col0 * + 89 FROM tab0
----
2136
3115
7921

query I rowsort
SELECT 93 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT tab1.col0 + - col0 * col1 AS col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ALL col1 * + ( - col0 ) - col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - col0 + col0 * + 4 AS col2 FROM tab2 AS cor0
----
21
234
237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * + ( col1 ) + col1 col2 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT 95 * + tab1.col0 AS col1 FROM tab1, tab2 AS cor0
----
285
6080
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col1 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + + col0 * ( col2 + - col2 ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - col2 * - 47 FROM tab1 AS cor0
----
2538
2679
4512

query I rowsort
SELECT 66 + 70 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 241ddcc97f622e1fcc14bd3c6a5bb6f4

query I rowsort
SELECT + + 89 AS col1 FROM tab2 AS cor0
----
89
89
89

query I rowsort
SELECT ALL - 61 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to c91d7b51e91f33d302e697913fb438b6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8100
SELECT 25 DIV col2 - - col2 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8100
SELECT 25 / col2 - - col2 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT cor0.col1 * 67 * 0 FROM tab0, tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * col2 * - col1 + - tab0.col2 col1 FROM tab0
----
-611966
-93687
-98

query I rowsort
SELECT + ( col2 ) + 89 AS col0 FROM tab1 AS cor0
----
143
146
185

query I rowsort
SELECT cor0.col1 + - 80 * - ( cor0.col0 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a1960f3e99717b9a55bc1eea0b28be96

query I rowsort
SELECT - - 49 * - col2 AS col1 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT ALL + - 49 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8107
SELECT + col1 * col2 + + CAST( + 0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-8107
SELECT + col1 * col2 + + CAST ( + 0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + cor1.col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL + col2 * - col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8110
SELECT ALL - CAST( NULL AS SIGNED ) * 84 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8110
SELECT ALL - CAST ( NULL AS INTEGER ) * 84 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 52 * + col2 col2 FROM tab2 AS cor0
----
-35152
-37908
-75088

query I rowsort
SELECT + - col0 * + col1 * - ( + col2 + - ( + 3 ) * + col0 ) FROM tab0 AS cor0
----
-1498315
-353080
-80496

query I rowsort
SELECT + col0 * ( 93 ) FROM tab2 AS cor0
----
651
7254
7347

query I rowsort
SELECT - ( + col1 ) AS col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col2 - - 35 FROM tab2
----
-3
8
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8116
SELECT ALL cor1.col2 DIV - 25 + - cor0.col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0eb80c6daaca531b1ee902b100e445f8

skipif mysql # not compatible
query I rowsort label-8116
SELECT ALL cor1.col2 / - 25 + - cor0.col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0eb80c6daaca531b1ee902b100e445f8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col2 + + 33 col0 FROM tab1 cor0
----
-21
-24
-63

query I rowsort
SELECT - ( - 35 ) - - col1 FROM tab1 AS cor0
----
45
48
61

query I rowsort
SELECT DISTINCT - + col0 * - ( cor0.col2 ) - - 75 * col0 FROM tab1 cor0
----
13680
387
8448

query I rowsort
SELECT DISTINCT + - col0 * 1 * col0 - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1152
-15842
-2450

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8121
SELECT - + CAST( NULL AS SIGNED ) - col1 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8121
SELECT - + CAST ( NULL AS INTEGER ) - col1 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 5 + + col1 * 64 col0 FROM tab1 AS cor0
----
1394
352
355

query I rowsort
SELECT ALL - 38 * - col2 + - col1 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1584
-4346
-59

query I rowsort
SELECT - ( col2 ) + + cor0.col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - col0 * + 38 FROM tab2
----
-266
-2964
-3002

query I rowsort
SELECT ALL col0 * col1 + ( 11 ) FROM tab1 cor0
----
1051
651
89

query I rowsort
SELECT ALL cor0.col2 + - col0 * col0 AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8128
SELECT DISTINCT - col0 * + cor0.col2 + - CAST( cor0.col1 AS SIGNED ) FROM tab0 AS cor0
----
-132
-7389
-878

skipif mysql # not compatible
query I rowsort label-8128
SELECT DISTINCT - col0 * + cor0.col2 + - CAST ( cor0.col1 AS INTEGER ) FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT + + 69 + cor0.col2 FROM tab2 AS cor0
----
107
95
96

query I rowsort
SELECT ALL + - ( + col0 ) * col1 + cor0.col0 * col0 AS col2 FROM tab1 cor0
----
-69
3456
5360

query I rowsort
SELECT - ( + col2 ) - tab1.col2 * - col2 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT ( col2 ) + col2 - ( + col0 ) FROM tab0
----
-33
42
75

query I rowsort
SELECT cor0.col2 - - 38 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 8b524f9c060bc0c207cb1cb5e0bb7d27

query I rowsort
SELECT tab0.col2 * - ( + 34 ) AS col1 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 0944dcb4b02805fdfc02c1d6801446c1

query I rowsort
SELECT DISTINCT - - ( - col2 ) * + col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - col1 + 63 AS col1 FROM tab0 AS cor0
----
-23
-28
-34

query I rowsort
SELECT ALL - + 63 * col1 FROM tab1 AS cor0
----
-1638
-630
-819

query I rowsort
SELECT + 29 FROM tab0, tab1 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT DISTINCT tab0.col1 * col2 * col0 FROM tab0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8140
SELECT + CAST( 75 AS SIGNED ) FROM tab0
----
75
75
75

skipif mysql # not compatible
query I rowsort label-8140
SELECT + CAST ( 75 AS INTEGER ) FROM tab0
----
75
75
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-8141
SELECT DISTINCT + - 4 DIV - col1 + cor0.col2 + - 1 DIV col0 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-8141
SELECT DISTINCT + - 4 / - col1 + cor0.col2 + - 1 / col0 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 42 col0 FROM tab0 AS cor0
----
-42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8143
SELECT + CAST( col0 AS SIGNED ) + col0 * + col1 FROM tab1 AS cor0
----
1120
704
81

skipif mysql # not compatible
query I rowsort label-8143
SELECT + CAST ( col0 AS INTEGER ) + col0 * + col1 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col0 + + col2 + col2 FROM tab1 cor0
----
105
112
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-8146
SELECT - col0 * + cor0.col2 + col0 DIV + col2 FROM tab1 AS cor0
----
-162
-3647
-7680

skipif mysql # not compatible
query I rowsort label-8146
SELECT - col0 * + cor0.col2 + col0 / + col2 FROM tab1 AS cor0
----
-162
-3647
-7680

query I rowsort
SELECT - ( col1 ) * 39 + col0 AS col1 FROM tab0 AS cor0
----
-3330
-3460
-3748

onlyif mysql # use DIV operator for integer division
query I rowsort label-8148
SELECT ALL - col2 DIV - col1 + ( + col2 ) * col0 FROM tab1 cor0
----
164
3653
7687

skipif mysql # not compatible
query I rowsort label-8148
SELECT ALL - col2 / - col1 + ( + col2 ) * col0 FROM tab1 cor0
----
164
3653
7687

query I rowsort
SELECT DISTINCT - col2 + + col1 * - ( - 38 ) AS col0 FROM tab1 AS cor0
----
323
398
934

query I rowsort
SELECT - col0 * col0 + - col2 AS col1 FROM tab2 AS cor0
----
-6110
-6279
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 53 * col1 col0 FROM tab2 cor0
----
-1643
-3127
-901

query I rowsort
SELECT + 78 AS col0 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT - ( ( col0 ) * col1 ) AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - col0 * col0 + 50 AS col0 FROM tab0 cor0
----
-1175
-526
-7871

query I rowsort
SELECT ALL col1 + + 12 FROM tab2 AS cor0
----
29
43
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-8156
SELECT ALL col1 - col0 DIV col0 AS col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-8156
SELECT ALL col1 - col0 / col0 AS col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT DISTINCT + col1 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
1175
6815
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8158
SELECT ALL + col0 DIV - CAST( + col0 AS SIGNED ) + + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-8158
SELECT ALL + col0 / - CAST ( + col0 AS INTEGER ) + + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT - col2 * ( 19 * col0 ) FROM tab0 AS cor0
----
-138662
-15048
-665

query I rowsort
SELECT DISTINCT + - col2 + + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL cor0.col1 * 1 + 74 * - col1 FROM tab2 AS cor0
----
-1241
-2263
-4307

query I rowsort
SELECT + 86 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT DISTINCT + col1 + col1 + + col1 FROM tab0
----
258
273
291

onlyif mysql # use DIV operator for integer division
query I rowsort label-8164
SELECT DISTINCT col0 + col0 DIV + 46 AS col0 FROM tab1
----
3
65
81

skipif mysql # not compatible
query I rowsort label-8164
SELECT DISTINCT col0 + col0 / + 46 AS col0 FROM tab1
----
3
65
81

query I rowsort
SELECT DISTINCT + col0 * 40 - col2 AS col1 FROM tab1 AS cor0
----
2503
3104
66

query I rowsort
SELECT ALL - col1 * - cor0.col1 - + 24 AS col0 FROM tab0 AS cor0
----
7372
8257
9385

query I rowsort
SELECT DISTINCT + cor0.col0 * col2 * - col0 AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT + + tab1.col0 AS col2 FROM tab1, tab2, tab0 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - ( cor2.col1 ) + - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 cor1, tab1 AS cor2
----
81 values hashing to f14517b0530f91463c10f1f09779f807

query I rowsort
SELECT - 45 + + 44 * - col1 FROM tab0 AS cor0
----
-3829
-4049
-4313

query I rowsort
SELECT col1 * col2 - col2 * col0 FROM tab0
----
164
2046
62

query I rowsort
SELECT ALL + col2 * + 72 FROM tab2 AS cor0
----
1872
1944
2736

query I rowsort
SELECT - 25 AS col1 FROM tab1 cor0 CROSS JOIN tab1, tab0 cor1, tab0 AS cor2
----
81 values hashing to 6f83d63ca9889b3b99826987c718bda8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8174
SELECT tab2.col2 + - col2 DIV + col1 AS col1 FROM tab2
----
26
27
36

skipif mysql # not compatible
query I rowsort label-8174
SELECT tab2.col2 + - col2 / + col1 AS col1 FROM tab2
----
26
27
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 22 col2 FROM tab0 AS cor0
----
22
22
22

query I rowsort
SELECT col1 * 21 AS col0 FROM tab1
----
210
273
546

query I rowsort
SELECT DISTINCT 52 * - cor0.col1 FROM tab0, tab2 AS cor0
----
-1612
-3068
-884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 38 col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT ALL - tab1.col1 * tab1.col1 AS col0 FROM tab1
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8180
SELECT DISTINCT + cor0.col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-8180
SELECT DISTINCT + cor0.col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT ALL col2 * 96 FROM tab2
----
2496
2592
3648

query I rowsort
SELECT ALL - 58 * + col0 AS col2 FROM tab2 AS cor0
----
-406
-4524
-4582

query I rowsort
SELECT DISTINCT + 59 * cor0.col0 AS col2 FROM tab2 AS cor0
----
413
4602
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-8184
SELECT ALL 39 DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8184
SELECT ALL 39 / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + ( - 74 ) AS col0 FROM tab2 AS cor0
----
-74
-74
-74

query I rowsort
SELECT ( - 38 ) * + col0 AS col0 FROM tab0 AS cor0
----
-1330
-3382
-912

query I rowsort
SELECT ( col1 ) AS col2 FROM tab0 cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 93 * + 8 + - col2 * col2 col1 FROM tab0 AS cor0
----
-345
-5980
743

query I rowsort
SELECT - 25 + - col2 * col0 FROM tab0
----
-60
-7323
-817

query I rowsort
SELECT ALL tab1.col2 + - col1 AS col2 FROM tab1
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8191
SELECT - col2 * col0 - + CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8191
SELECT - col2 * col0 - + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 67 * - col2 + + ( col1 ) FROM tab1 AS cor0
----
-3592
-3809
-6419

query I rowsort
SELECT ALL + - col0 + col0 + + col0 AS col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 21 + - col2 AS col0 FROM tab1 AS cor0
----
-33
-36
-75

query I rowsort
SELECT + 16 * col2 + - cor0.col2 * col1 AS col2 FROM tab1 AS cor0
----
-540
288
342

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8196
SELECT DISTINCT - col2 + col0 * CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
162
2002
2964

skipif mysql # not compatible
query I rowsort label-8196
SELECT DISTINCT - col2 + col0 * CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
162
2002
2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + cor0.col2 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - 58 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT DISTINCT - - cor0.col0 + cor0.col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8200
SELECT ALL + cor0.col2 * CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8200
SELECT ALL + cor0.col2 * CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + - col1 * col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL col2 + + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + cor2.col1 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ALL + 45 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT - cor0.col0 + cor0.col2 + + cor0.col2 FROM tab2 AS cor0
----
-26
-3
47

query I rowsort
SELECT + col1 * ( 13 ) * cor0.col0 AS col2 FROM tab2 AS cor0
----
17459
2821
59826

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + 70 col2 FROM tab0 AS cor0
----
105
159
94

query I rowsort
SELECT + + col2 * - col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - tab0.col1 * col2 * + tab0.col0 AS col2 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-8210
SELECT - col0 + + cor0.col2 DIV + col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-8210
SELECT - col0 + + cor0.col2 / + col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE - col2 > ( - col0 )
----
64
10
57

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0 WHERE NOT ( NULL ) < NULL
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE + col2 NOT IN ( col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-8214
SELECT col2 DIV col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-8214
SELECT col2 / col0 FROM tab1 cor0
----
0
1
18

query I rowsort
SELECT + tab2.col0 FROM tab2 WHERE - col2 * col1 NOT IN ( col1 * + col0 )
----
7
78
79

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col0 + - col0 IN ( + tab2.col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 34 + - col1 * col1 col2 FROM tab2
----
-255
-3447
-927

query I rowsort
SELECT ALL 15 + tab0.col0 * + col2 AS col0 FROM tab0
----
50
7313
807

query I rowsort
SELECT + col1 * - tab0.col1 * - col1 FROM tab0
----
636056
753571
912673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + cor0.col1 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * + col1 * col2 + + ( col1 ) FROM tab2 cor0
----
-10965
-25916
-90447

query I rowsort
SELECT DISTINCT col0 + tab1.col2 * col2 AS col2 FROM tab1 WHERE ( + col0 ) <= NULL
----

query I rowsort
SELECT + col0 * + col2 * col2 AS col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT + col0 AS col2 FROM tab0 WHERE NULL NOT IN ( - tab0.col1 - - col1 * - col0 )
----

query I rowsort
SELECT - col0 - col1 / col2 FROM tab2 WHERE NOT NULL IN ( + col1 )
----

query I rowsort
SELECT ALL col0 * + col0 * - col0 FROM tab1
----
-262144
-27
-512000

query I rowsort
SELECT col1 * - col1 + col0 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT col0 + col2 - col2 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT - col0 * col2 * col1 AS col2 FROM tab0
----
-3395
-664118
-68112

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col1 >= ( - col0 + col0 )
----

query I rowsort
SELECT ALL col2 + col0 + - col1 FROM tab0
----
-29
-61
80

query I rowsort
SELECT col2 * - col0 + col1 AS col1 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-8233
SELECT DISTINCT - 42 * col0 + col0 DIV 49 AS col1 FROM tab0
----
-1008
-1470
-3737

skipif mysql # not compatible
query I rowsort label-8233
SELECT DISTINCT - 42 * col0 + col0 / 49 AS col1 FROM tab0
----
-1008
-1470
-3737

query I rowsort
SELECT ALL - col1 * col2 * 48 FROM tab0 AS cor0
----
-136224
-358176
-4656

query I rowsort
SELECT + ( col0 ) + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + cor0.col2 + + cor0.col1 * 42 * col1 AS col1 FROM tab2 AS cor0
----
12176
146228
40389

onlyif mysql # use DIV operator for integer division
query I rowsort label-8237
SELECT ALL - + 68 DIV - col1 AS col2 FROM tab2 cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-8237
SELECT ALL - + 68 / - col1 AS col2 FROM tab2 cor0
----
1
2
4

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab1 cor1, tab2, tab1 AS cor2
----
3645 values hashing to 35707ade138fec4b370f5140a4cd2963

query I rowsort
SELECT + 42 + cor0.col0 * col1 FROM tab2 AS cor0
----
1385
259
4644

query I rowsort
SELECT - - col2 * col0 + cor0.col1 * col2 + + col1 FROM tab0 AS cor0
----
14851
229
3716

query I rowsort
SELECT DISTINCT - col1 + - col2 * col2 FROM tab0
----
-1175
-6815
-98

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL < NULL
----

query I rowsort
SELECT ALL + col1 + tab2.col2 AS col2 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-8244
SELECT ALL col0 * - col0 + + tab0.col2 DIV + col2 AS col0 FROM tab0
----
-1224
-575
-7920

skipif mysql # not compatible
query I rowsort label-8244
SELECT ALL col0 * - col0 + + tab0.col2 / + col2 AS col0 FROM tab0
----
-1224
-575
-7920

query I rowsort
SELECT ALL + tab0.col0 + + tab0.col0 * col1 AS col2 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL + col1 AS col0 FROM tab0 AS cor0 WHERE NOT col0 NOT IN ( - col2 )
----

query I rowsort
SELECT - col0 * - col1 * - col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT tab0.col0 AS col0 FROM tab0 WHERE NOT ( NULL ) >= ( col0 )
----

query I rowsort
SELECT DISTINCT + col0 + - col2 * + col1 AS col0 FROM tab1 WHERE ( NULL ) < ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8250
SELECT + col0 DIV - col0 + + col1 * col2 AS col0 FROM tab1
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-8250
SELECT + col0 / - col0 + + col1 * col2 AS col0 FROM tab1
----
1247
1403
569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 * + col0 * col2 col2 FROM tab0
----
-26169
-36
-598518

query I rowsort
SELECT col2 + col2 FROM tab2 WHERE NULL NOT IN ( + col0 * + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8253
SELECT + col0 DIV col2 + - col2 * - col0 AS col1 FROM tab0
----
70
7299
792

skipif mysql # not compatible
query I rowsort label-8253
SELECT + col0 / col2 + - col2 * - col0 AS col1 FROM tab0
----
70
7299
792

query I rowsort
SELECT DISTINCT - tab1.col2 * + col2 AS col1 FROM tab1
----
-2916
-3249
-9216

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT IN ( tab1.col0 / tab1.col1 )
----

query I rowsort
SELECT DISTINCT + tab2.col0 + col0 * + col1 * col0 AS col1 FROM tab2
----
106176
1526
359034

query I rowsort
SELECT DISTINCT tab1.col2 AS col0 FROM tab1 WHERE NOT NULL < col2 * col0 * col1
----

query I rowsort
SELECT ALL - col1 * + col0 * + tab2.col2 AS col2 FROM tab2
----
-119652
-51034
-5859

query III rowsort
SELECT * FROM tab2 WHERE - col1 * col2 + col0 BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT ALL - col0 FROM tab0 WHERE NOT ( col2 + + col2 + + col2 ) BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL col2 * col0 + tab1.col1 FROM tab1
----
188
3658
7693

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( col2 * + col2 ) NOT IN ( col0 )
----

query I rowsort
SELECT ALL + col2 * col0 * 55 FROM tab1
----
200640
422400
8910

query I rowsort
SELECT - cor0.col1 + cor0.col1 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + col1 * + col0 col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ( col2 * 21 ) FROM tab2
----
546
567
798

query I rowsort
SELECT ALL col1 - + 28 AS col1 FROM tab1 AS cor0
----
-15
-18
-2

query I rowsort
SELECT DISTINCT col0 * + ( col2 + col2 ) FROM tab2
----
378
4056
6004

query I rowsort
SELECT - + cor0.col2 + + 71 FROM tab1 AS cor0
----
-25
14
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-8270
SELECT DISTINCT ( ( col1 ) ) + + ( + col1 ) * - col0 DIV - tab1.col0 AS col1 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-8270
SELECT DISTINCT ( ( col1 ) ) + + ( + col1 ) * - col0 / - tab1.col0 AS col1 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8271
SELECT ALL ( + 1 ) * col2 DIV + col0 + col0 AS col1 FROM tab0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-8271
SELECT ALL ( + 1 ) * col2 / + col0 + col0 AS col1 FROM tab0
----
25
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8272
SELECT DISTINCT - col1 DIV + cor0.col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-8272
SELECT DISTINCT - col1 / + cor0.col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT 14 * - 30 AS col1 FROM tab2 AS cor0
----
-420

query I rowsort
SELECT DISTINCT ( 51 ) + col2 FROM tab2
----
77
78
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8275
SELECT DISTINCT CAST( col0 AS SIGNED ) + col0 * - col0 col0 FROM tab0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8275
SELECT DISTINCT CAST ( col0 AS INTEGER ) + col0 * - col0 col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT 47 * + col0 + col2 * - col1 + col0 FROM tab0
----
-1686
-3190
1583

query I rowsort
SELECT - ( tab2.col2 ) + col2 FROM tab2
----
0
0
0

query I rowsort
SELECT 57 + cor0.col0 FROM tab2 cor0
----
135
136
64

query I rowsort
SELECT cor0.col0 * cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to d2e5241c58e367013a1a203910e000c0

query I rowsort
SELECT ALL + col1 + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - 82 + col1 FROM tab2 AS cor0
----
-23
-51
-65

query I rowsort
SELECT - cor0.col1 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col0 col1 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL - col1 * + col2 + ( 86 * col1 ) FROM tab1 AS cor0
----
-130
290
832

query I rowsort
SELECT - col2 * col1 * ( + col1 ) + col0 AS col2 FROM tab0 AS cor0
----
-244044
-678953
-9374

query I rowsort
SELECT - + col2 * - col0 * ( - cor0.col2 + - col1 * - cor0.col0 ) FROM tab1 AS cor0
----
2126784
3888
7249920

query I rowsort
SELECT ALL + col0 + col1 * col1 AS col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT - ( cor0.col0 ) * col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8289
SELECT - cor0.col1 DIV col1 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8289
SELECT - cor0.col1 / col1 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col0 * cor0.col2 + 11 FROM tab1 AS cor0
----
-151
-3637
-7669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8291
SELECT ALL - + col1 + col1 * CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8291
SELECT ALL - + col1 + col1 * CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col2 + tab1.col1 col1 FROM tab1
----
10
13
26

query I rowsort
SELECT - 49 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT + - col2 * + col0 * - col0 AS col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT + - 97 + col1 FROM tab1 AS cor0
----
-71
-84
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-8296
SELECT + col0 DIV + col0 + + col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-8296
SELECT + col0 / + col0 + + col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) * + col2 + col0 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT - 8 + col2 AS col2 FROM tab0 AS cor0
----
-7
25
74

query I rowsort
SELECT - 24 * - col0 * + 96 + - 86 AS col1 FROM tab2 AS cor0
----
16042
179626
181930

query I rowsort
SELECT + col1 + col1 * 61 FROM tab0
----
5332
5642
6014

query I rowsort
SELECT - col2 + + ( 69 ) AS col0 FROM tab0 AS cor0
----
-13
36
68

query I rowsort
SELECT DISTINCT + 63 * + tab0.col1 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
5418
5733
6111

query I rowsort
SELECT DISTINCT - - cor0.col0 + + tab2.col2 AS col1 FROM tab1, tab0, tab1 AS cor0, tab2
----
9 values hashing to 17e6537ffee10dccd14f4a1f12215238

query I rowsort
SELECT - - 69 - - 89 FROM tab0 cor0
----
158
158
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col2 ) * col2 - col2 col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT DISTINCT 82 * - col1 FROM tab1 AS cor0
----
-1066
-2132
-820

query I rowsort
SELECT + ( - col0 ) + + cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * + 20 * col2 + col2 * + col1 FROM tab1 AS cor0
----
11970
26208
29484

query I rowsort
SELECT + - col0 + - 96 FROM tab0 AS cor0
----
-120
-131
-185

query I rowsort
SELECT - 78 * col2 AS col2 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT DISTINCT - col2 * - 90 AS col2 FROM tab1
----
4860
5130
8640

query I rowsort
SELECT ALL col2 * - 50 + col2 AS col2 FROM tab2
----
-1274
-1323
-1862

query I rowsort
SELECT ALL 9 FROM tab1, tab1 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL - cor0.col1 * col2 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8315
SELECT ALL + + ( - col1 ) * + col2 + - ( + 55 + col2 ) DIV - col1 FROM tab2 AS cor0
----
-1533
-641
-835

skipif mysql # not compatible
query I rowsort label-8315
SELECT ALL + + ( - col1 ) * + col2 + - ( + 55 + col2 ) / - col1 FROM tab2 AS cor0
----
-1533
-641
-835

onlyif mysql # use DIV operator for integer division
query I rowsort label-8316
SELECT ALL + + cor0.col1 + + 22 DIV - col1 FROM tab1 cor0
----
12
26
8

skipif mysql # not compatible
query I rowsort label-8316
SELECT ALL + + cor0.col1 + + 22 / - col1 FROM tab1 cor0
----
12
26
8

query I rowsort
SELECT DISTINCT - - 54 - col0 * + col0 * - col1 FROM tab1 AS cor0
----
288
41014
83254

query I rowsort
SELECT - 47 - + col0 FROM tab0 AS cor0
----
-136
-71
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8319
SELECT ALL - - 81 DIV + 35 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-8319
SELECT ALL - - 81 / + 35 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT DISTINCT - 53 * + col1 * + cor0.col1 - col0 AS col0 FROM tab0 AS cor0
----
-392012
-438982
-498712

query I rowsort
SELECT + 97 + col1 AS col2 FROM tab1 AS cor0
----
107
110
123

onlyif mysql # use DIV operator for integer division
query I rowsort label-8322
SELECT DISTINCT + + 44 DIV 33 AS col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-8322
SELECT DISTINCT + + 44 / 33 AS col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT + tab2.col0 * col0 + - 79 + + col0 FROM tab2
----
-23
6083
6241

query I rowsort
SELECT col2 * - 28 AS col0 FROM tab0
----
-2296
-28
-924

query I rowsort
SELECT ALL 36 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT + 74 FROM tab1, tab1 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8327
SELECT col2 + CAST( NULL AS DECIMAL ) * - cor0.col1 + col0 * - 90 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8327
SELECT col2 + CAST ( NULL AS REAL ) * - cor0.col1 + col0 * - 90 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8328
SELECT col1 + ( col2 * + col2 ) + - CAST( NULL AS SIGNED ) / col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8328
SELECT col1 + ( col2 * + col2 ) + - CAST ( NULL AS INTEGER ) / col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 - - col1 AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT + col0 + - 98 + + col1 AS col0 FROM tab0 AS cor0
----
12
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8331
SELECT + - 88 DIV - col2 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-8331
SELECT + - 88 / - col2 AS col1 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT + - ( col0 ) * col1 + + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - - col1 * + 11 AS col1 FROM tab2 AS cor0
----
187
341
649

onlyif mysql # use DIV operator for integer division
query I rowsort label-8334
SELECT - ( - col0 ) DIV + cor0.col0 + + col2 col2 FROM tab1 AS cor0
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8334
SELECT - ( - col0 ) / + cor0.col0 + + col2 col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT col0 * - ( - col2 ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col0 ) * - cor0.col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8337
SELECT - CAST( col1 AS SIGNED ) + col2 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-8337
SELECT - CAST ( col1 AS INTEGER ) + col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ( + col2 ) * col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - col0 * col1 + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT col1 * col1 * - ( col2 * col2 ) FROM tab2 cor0
----
-2353156
-417316
-700569

query I rowsort
SELECT - col0 + + col2 * col1 * 19 FROM tab2 cor0
----
12195
15896
29068

onlyif mysql # use DIV operator for integer division
query I rowsort label-8342
SELECT ALL - cor0.col0 * 70 DIV - col0 + - col0 FROM tab0 AS cor0
----
-19
35
46

skipif mysql # not compatible
query I rowsort label-8342
SELECT ALL - cor0.col0 * 70 / - col0 + - col0 FROM tab0 AS cor0
----
-19
35
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-8343
SELECT + col0 - - 36 DIV + col0 col1 FROM tab0 AS cor0
----
25
36
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8343
SELECT + col0 - - 36 / + col0 col1 FROM tab0 AS cor0
----
25
36
89

query I rowsort
SELECT ALL + col0 + - col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + cor1.col1 * cor1.col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to f8894e3f33962cda5901e1c2ce65d5b0

query I rowsort
SELECT 68 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT ALL + - col1 - - cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * + ( - col1 ) + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + + col0 * ( cor0.col1 ) FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT cor0.col1 * 97 AS col0 FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT col0 + + 24 AS col0 FROM tab1 AS cor0
----
104
27
88

query I rowsort
SELECT - col0 * - col2 + - col2 * - col1 AS col1 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT + cor0.col2 * col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT ALL - - col2 + cor0.col1 + + 2 AS col0 FROM tab2 AS cor0
----
57
60
87

query I rowsort
SELECT ALL - col0 + col1 + 71 FROM tab2 AS cor0
----
52
9
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8356
SELECT ALL + + col1 + cor0.col2 DIV col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-8356
SELECT ALL + + col1 + cor0.col2 / col2 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-8357
SELECT - col1 DIV - col0 + + col1 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-8357
SELECT - col1 / - col0 + + col1 FROM tab2
----
17
35
59

query I rowsort
SELECT DISTINCT ( - 43 ) * + col2 + + 76 * 14 * col2 FROM tab2 AS cor0
----
26546
27567
38798

onlyif mysql # use DIV operator for integer division
query I rowsort label-8359
SELECT col1 DIV + 15 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8359
SELECT col1 / + 15 FROM tab1
----
0
0
1

query I rowsort
SELECT ALL 55 + + 24 FROM tab0, tab0 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT DISTINCT - tab0.col1 - tab0.col1 AS col2 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT ALL - ( col0 ) * col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - col2 + col0 * col2 AS col2 FROM tab1 cor0
----
108
3591
7584

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2, tab2 AS cor1
----
3645 values hashing to b62c1ebc681aca72d13feadb888b3be7

query I rowsort
SELECT ALL - 39 + + col2 * + col2 AS col0 FROM tab1 AS cor0
----
2877
3210
9177

query I rowsort
SELECT DISTINCT - 12 + cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
1522
634
825

query I rowsort
SELECT + 27 * + col2 FROM tab1 cor0
----
1458
1539
2592

query I rowsort
SELECT DISTINCT 60 FROM tab1 AS cor0
----
60

query I rowsort
SELECT + col2 * ( tab2.col1 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL col1 + 79 FROM tab0
----
165
170
176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + - ( + col2 ) col1 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT - - 37 AS col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT + 79 FROM tab0 cor0
----
79
79
79

query I rowsort
SELECT ALL + tab0.col2 + 88 AS col1 FROM tab0
----
121
170
89

query I rowsort
SELECT ALL + ( cor0.col1 ) * + col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + - col0 + col1 + cor0.col0 * col2 FROM tab0 AS cor0
----
7300
854
97

query I rowsort
SELECT - col2 * - 5 + col2 + - cor0.col2 FROM tab0 AS cor0
----
165
410
5

query I rowsort
SELECT DISTINCT 0 - 58 AS col0 FROM tab0 AS cor0
----
-58

query I rowsort
SELECT ALL - col0 + - col0 * col0 - col2 * - cor0.col0 FROM tab2 AS cor0
----
-3318
-4134
133

query I rowsort
SELECT ALL + col0 * ( + col0 ) AS col2 FROM tab1 AS cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 90 col2 FROM tab2, tab1 cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 3b4644ef0734ed220952cae7e0648c4b

query I rowsort
SELECT ALL - ( - ( - col2 ) ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 90 * col1 - - col1 AS col0 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT + 55 + col0 * + col2 AS col2 FROM tab0 cor0
----
7353
847
90

query I rowsort
SELECT DISTINCT - col2 + col0 * col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT + col1 + col0 + 19 FROM tab1
----
112
48
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 + col1 + col1 col2 FROM tab0
----
2236
3589
8281

query I rowsort
SELECT ALL + ( col2 ) * + col0 + - col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT 29 + col2 + col2 FROM tab0
----
193
31
95

query I rowsort
SELECT ALL ( + col0 ) - + 94 AS col0 FROM tab2
----
-15
-16
-87

query I rowsort
SELECT + - col2 * col0 + col0 + + 17 AS col0 FROM tab0 AS cor0
----
-7192
-751
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-8392
SELECT DISTINCT + tab2.col2 DIV - ( + 7 ) FROM tab2, tab2 AS cor0
----
-3
-5

skipif mysql # not compatible
query I rowsort label-8392
SELECT DISTINCT + tab2.col2 / - ( + 7 ) FROM tab2, tab2 AS cor0
----
-3
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8393
SELECT 2 DIV + col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8393
SELECT 2 / + col1 AS col2 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * + ( - col2 ) * - cor0.col1 + + col2 * cor0.col1 col2 FROM tab1 AS cor0
----
101088
37050
5616

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col0 col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + col0 + - col0 * - cor0.col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL + cor0.col1 + - 88 * col2 - - col1 FROM tab0 AS cor0
----
-2732
-7034
106

query I rowsort
SELECT - col2 * - 66 - + col1 FROM tab0 cor0
----
-31
2092
5321

query I rowsort
SELECT + col0 * 62 * - col1 AS col2 FROM tab0 AS cor0
----
-127968
-210490
-502138

query I rowsort
SELECT - col2 + ( cor0.col2 ) + + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 * + col1 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT ( + col0 ) * ( + col2 ) - + col1 AS col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT DISTINCT - col0 + - col0 * col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT - col2 * col2 - col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT + - cor0.col2 + + col1 * col1 + - col2 * col1 FROM tab0 AS cor0
----
4525
737
9311

query I rowsort
SELECT ALL + col1 * - col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + ( + col1 ) * - cor0.col2 col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT cor0.col0 + col2 + 49 AS col2 FROM tab2 cor0
----
153
166
83

query I rowsort
SELECT ALL - cor0.col1 * + col0 + 97 FROM tab0 AS cor0
----
-1967
-3298
-8002

query I rowsort
SELECT + col2 - 4 FROM tab1 AS cor0
----
50
53
92

query I rowsort
SELECT DISTINCT - col1 + 37 FROM tab1 AS cor0
----
11
24
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 84 col1 FROM tab1, tab2 cor0, tab1 cor1
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

query I rowsort
SELECT - col0 * col1 * col0 FROM tab2
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-8414
SELECT col1 - col1 DIV - col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-8414
SELECT col1 - col1 / - col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + + col2 + col2 * col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - cor0.col0 * + col1 + cor0.col2 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8417
SELECT + - CAST( NULL AS DECIMAL ) * cor0.col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8417
SELECT + - CAST ( NULL AS REAL ) * cor0.col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8418
SELECT CAST( NULL AS SIGNED ) / - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8418
SELECT CAST ( NULL AS INTEGER ) / - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( col0 ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + 59 * col2 FROM tab0 cor0
----
1947
4838
59

query I rowsort
SELECT tab2.col2 + col2 * - col0 AS col1 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + col0 * 43 + + tab0.col1 * - tab0.col0 AS col0 FROM tab0
----
-1032
-1890
-4272

query I rowsort
SELECT ( col2 ) + col1 + 93 FROM tab1 AS cor0
----
160
173
202

query I rowsort
SELECT DISTINCT - ( 12 ) FROM tab1, tab2 cor0
----
-12

query I rowsort
SELECT + cor0.col1 + cor0.col1 AS col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - - 30 FROM tab1 AS cor0
----
30

query I rowsort
SELECT - 99 + col2 FROM tab1 AS cor0
----
-3
-42
-45

query I rowsort
SELECT ALL - + 8 + + col2 AS col2 FROM tab2 AS cor0
----
18
19
30

query I rowsort
SELECT DISTINCT cor0.col0 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + - col2 * + col2 + + ( + ( col0 ) ) + + 68 * col1 FROM tab1 AS cor0
----
-1145
-2505
-8252

query I rowsort
SELECT DISTINCT - 93 * col0 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT ALL ( col1 ) + + 36 AS col0 FROM tab1 AS cor0
----
46
49
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8433
SELECT ALL cor0.col2 + col1 + - CAST( 20 AS SIGNED ) FROM tab2 AS cor0
----
35
38
65

skipif mysql # not compatible
query I rowsort label-8433
SELECT ALL cor0.col2 + col1 + - CAST ( 20 AS INTEGER ) FROM tab2 AS cor0
----
35
38
65

query I rowsort
SELECT DISTINCT 34 - col0 * + col0 FROM tab2 AS cor0
----
-15
-6050
-6207

query I rowsort
SELECT + + 39 + - ( cor1.col1 ) * 7 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1a139c2e559895def3c1e23df0bb8ec0

query I rowsort
SELECT ALL + - 63 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5a7845ef6e239561caf9a17a28e274b5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8437
SELECT CAST( col1 AS SIGNED ) * tab0.col1 FROM tab0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-8437
SELECT CAST ( col1 AS INTEGER ) * tab0.col1 FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-8438
SELECT ( - col1 ) DIV col2 AS col1 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-8438
SELECT ( - col1 ) / col2 AS col1 FROM tab0
----
-1
-2
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8439
SELECT + 12 DIV + col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8439
SELECT + 12 / + col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * - col1 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + - cor0.col2 - + cor0.col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL + ( + col0 ) * 4 AS col1 FROM tab0 cor0
----
140
356
96

query I rowsort
SELECT + ( - col2 ) * - 51 + 91 FROM tab0 AS cor0
----
142
1774
4273

query I rowsort
SELECT - 83 FROM tab1, tab2 cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT ALL + col2 - - col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT - - col1 + col0 * - cor0.col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + ( + cor0.col1 ) AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - 35 * + col1 AS col0 FROM tab1 AS cor0
----
-350
-455
-910

query I rowsort
SELECT + ( cor0.col2 ) + + 51 FROM tab1 AS cor0
----
105
108
147

query I rowsort
SELECT - col1 * col2 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT + col2 * col1 * - col0 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + col2 * + cor0.col0 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - 1 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to f3aaea07874d9328a91c424c0907a688

query I rowsort
SELECT DISTINCT - 6 * col1 AS col0 FROM tab2 cor0
----
-102
-186
-354

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8455
SELECT DISTINCT + col1 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-8455
SELECT DISTINCT + col1 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT + col2 * col1 * col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-8457
SELECT - + col1 * col1 DIV col0 AS col2 FROM tab0 cor0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort label-8457
SELECT - + col1 * col1 / col0 AS col2 FROM tab0 cor0
----
-268
-308
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8458
SELECT - col1 + - 60 DIV col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-8458
SELECT - col1 + - 60 / col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8459
SELECT - col2 DIV + cor0.col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-8459
SELECT - col2 / + cor0.col1 FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT - col0 + col0 * tab1.col0 * - ( col2 ) AS col1 FROM tab1
----
-233536
-489
-614480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 * - 84 col2 FROM tab2 AS cor0
----
-3948
-3948
-3948

onlyif mysql # use DIV operator for integer division
query I rowsort label-8462
SELECT ALL - cor0.col2 DIV - col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-8462
SELECT ALL - cor0.col2 / - col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT ALL - - ( 67 ) + - col0 FROM tab2 AS cor0
----
-11
-12
60

query I rowsort
SELECT + ( 7 ) FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT + + 31 * 79 AS col1 FROM tab2 AS cor0
----
2449

query I rowsort
SELECT ALL - cor0.col2 + - col0 * - col1 AS col0 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT - 78 * ( + col1 ) AS col0 FROM tab1 AS cor0
----
-1014
-2028
-780

query I rowsort
SELECT DISTINCT - + ( - col0 ) + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col2 + + cor0.col1 * col2 AS col1 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT ALL + 74 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
152
153
81

query I rowsort
SELECT ALL cor0.col1 * col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - 86 * 9 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 4df53307cad4c8cf074091558637d2ef

query I rowsort
SELECT ALL - col1 * col2 * + col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-8474
SELECT ALL + - 25 + col2 DIV + col0 FROM tab0 AS cor0
----
-24
-25
-25

skipif mysql # not compatible
query I rowsort label-8474
SELECT ALL + - 25 + col2 / + col0 FROM tab0 AS cor0
----
-24
-25
-25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL - 96 AS col2 FROM tab2
----
-96
-96
-96

query I rowsort
SELECT DISTINCT ( col0 ) * col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT + cor0.col1 + - 66 AS col1 FROM tab0 cor0
----
20
25
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8479
SELECT DISTINCT - + col0 + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8479
SELECT DISTINCT - + col0 + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col0 + + ( - 64 ) FROM tab1 AS cor0
----
-128
-144
-67

query I rowsort
SELECT - - col0 + + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col0 + 25 * col1 FROM tab1 AS cor0
----
314
405
653

onlyif mysql # use DIV operator for integer division
query I rowsort label-8483
SELECT DISTINCT col2 + tab0.col2 DIV ( col0 ) FROM tab0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-8483
SELECT DISTINCT col2 + tab0.col2 / ( col0 ) FROM tab0
----
1
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-8484
SELECT DISTINCT + col1 DIV 22 AS col0 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8484
SELECT DISTINCT + col1 / 22 AS col0 FROM tab2 AS cor0
----
0
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-8485
SELECT ALL + tab1.col2 DIV - col0 + + 31 FROM tab1
----
13
30
31

skipif mysql # not compatible
query I rowsort label-8485
SELECT ALL + tab1.col2 / - col0 + + 31 FROM tab1
----
13
30
31

query I rowsort
SELECT + col1 + col0 * - col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT col1 * col2 + tab2.col1 AS col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT 95 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8489
SELECT - col2 * + col2 + + 87 DIV - col0 AS col0 FROM tab2
----
-1445
-677
-741

skipif mysql # not compatible
query I rowsort label-8489
SELECT - col2 * + col2 + + 87 / - col0 AS col0 FROM tab2
----
-1445
-677
-741

query I rowsort
SELECT ALL + col1 + - ( 78 ) * col2 FROM tab2 AS cor0
----
-1969
-2075
-2947

query I rowsort
SELECT - - col0 * - col2 + + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL col1 * ( - col0 + col1 ) FROM tab2 AS cor0
----
-1054
-1121
744

query I rowsort
SELECT ALL + col0 * col1 * 40 FROM tab0 cor0
----
135800
323960
82560

query I rowsort
SELECT ALL - col0 + cor0.col2 * ( - col2 ) FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT + + col2 + + 11 FROM tab2 AS cor0
----
37
38
49

query I rowsort
SELECT col0 - col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + col2 * ( - 96 ) FROM tab1 AS cor0
----
-5184
-5472
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - ( + col2 * col1 ) + col2 col0 FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT - 16 * col0 + + col1 AS col0 FROM tab2 AS cor0
----
-1189
-1247
-81

query I rowsort
SELECT col1 + 94 AS col2 FROM tab0 AS cor0
----
180
185
191

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 14 ) col2 FROM tab2, tab1 AS cor0
----
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-8502
SELECT + - cor0.col0 * + cor0.col2 + col0 DIV + cor0.col2 FROM tab0 AS cor0
----
-7297
-792
0

skipif mysql # not compatible
query I rowsort label-8502
SELECT + - cor0.col0 * + cor0.col2 + col0 / + cor0.col2 FROM tab0 AS cor0
----
-7297
-792
0

query I rowsort
SELECT ALL - col1 + ( + col2 ) * + col2 AS col2 FROM tab0
----
-96
1003
6633

query I rowsort
SELECT ALL - 56 + + 22 FROM tab0, tab0 cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab1, tab1 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 8db0cc6df185b737ff75d2626a6d198b

query I rowsort
SELECT ALL 61 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - col1 col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - - 0 * col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 + - cor0.col1 + ( col0 ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col0 + col2 * - col2 FROM tab1
----
-2919
-3313
-9296

query I rowsort
SELECT ALL col2 AS col1 FROM tab2 WHERE ( col0 ) IN ( + col1 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( - col2 ) IN ( tab0.col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8513
SELECT + tab0.col1 DIV - col1 + tab0.col2 * - col2 * col1 - col0 AS col0 FROM tab0
----
-133
-611974
-93679

skipif mysql # not compatible
query I rowsort label-8513
SELECT + tab0.col1 / - col1 + tab0.col2 * - col2 * col1 - col0 AS col0 FROM tab0
----
-133
-611974
-93679

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 IN ( col2 * - col2 + + col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - col2 + + col1 * tab0.col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT ALL - col1 * - col2 * + col2 FROM tab2
----
22599
24548
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 - + col2 col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL + 51 - col1 FROM tab2
----
-8
20
34

query I rowsort
SELECT 2 * col1 + + col0 FROM tab0
----
196
229
271

onlyif mysql # use DIV operator for integer division
query I rowsort label-8520
SELECT - 29 DIV 93 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-8520
SELECT - 29 / 93 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - cor0.col2 * 64 AS col2 FROM tab1 AS cor0
----
-3456
-3648
-6144

query I rowsort
SELECT ALL + col2 * + 3 AS col2 FROM tab2
----
114
78
81

query I rowsort
SELECT - - col1 + ( + col2 ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + + ( - 79 ) * col1 FROM tab2 AS cor0
----
-1343
-2449
-4661

query I rowsort
SELECT col1 + + 86 AS col2 FROM tab0 AS cor0
----
172
177
183

query I rowsort
SELECT + - col0 * col2 + col2 AS col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL + 46 * col1 FROM tab1
----
1196
460
598

query I rowsort
SELECT ALL 6 * - col0 FROM tab1 AS cor0
----
-18
-384
-480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 * + col0 col2 FROM tab1 AS cor0
----
210
4480
5600

query I rowsort
SELECT - col1 + + col2 * + ( 31 * col2 ) FROM tab1 AS cor0
----
100709
285683
90370

query I rowsort
SELECT ALL 82 * + col1 AS col1 FROM tab1
----
1066
2132
820

query I rowsort
SELECT DISTINCT + + 1 FROM tab1 AS cor0
----
1

query I rowsort
SELECT + - 62 FROM tab1 cor0
----
-62
-62
-62

query I rowsort
SELECT 4 FROM tab0, tab2 cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + 42 * col2 FROM tab0 AS cor0
----
1386
3444
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 * - col2 + col0 col1 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-8537
SELECT + - col1 DIV + col0 AS col0 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-8537
SELECT + - col1 / + col0 AS col0 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT + col2 * col1 * - col2 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT cor0.col0 + col2 * + col2 + - col1 AS col2 FROM tab0 cor0
----
-61
1027
6722

query I rowsort
SELECT - - 88 * col1 + col1 FROM tab2 AS cor0
----
1513
2759
5251

query I rowsort
SELECT ALL + col2 + col1 AS col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - cor0.col1 + + col0 AS col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + ( + 63 ) AS col1 FROM tab1
----
63
63
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8544
SELECT DISTINCT - CAST( - col0 + col2 AS SIGNED ) * - col2 FROM tab2
----
-1352
-1558
540

skipif mysql # not compatible
query I rowsort label-8544
SELECT DISTINCT - CAST ( - col0 + col2 AS INTEGER ) * - col2 FROM tab2
----
-1352
-1558
540

query I rowsort
SELECT ALL - 0 + + col1 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT - + cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - 46 * - col2 FROM tab2 cor0
----
1196
1242
1748

query I rowsort
SELECT - col0 + - col1 * + col1 - col2 AS col0 FROM tab2
----
-3585
-406
-995

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col0 col2 FROM tab1
----
-121
-176
-57

query III rowsort
SELECT ALL * FROM tab1 WHERE col1 + col2 NOT BETWEEN col2 + col2 AND col1 + col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

onlyif mysql # use DIV operator for integer division
query I rowsort label-8551
SELECT - col2 + - col0 DIV + col1 + col1 col1 FROM tab2
----
-25
32
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8551
SELECT - col2 + - col0 / + col1 + col1 col1 FROM tab2
----
-25
32
4

query I rowsort
SELECT ALL col0 * col1 * + col1 AS col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT DISTINCT - col0 + tab1.col0 AS col1 FROM tab1
----
0

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT ALL - col0 + col1 * - col1 * col0 AS col0 FROM tab2
----
-22910
-271596
-6734

onlyif mysql # use DIV operator for integer division
query I rowsort label-8556
SELECT - tab0.col0 DIV - col1 + col1 * tab0.col0 * + col0 FROM tab0 WHERE ( + col0 ) NOT IN ( + col2 )
----
118825
49536
720811

skipif mysql # not compatible
query I rowsort label-8556
SELECT - tab0.col0 / - col1 + col1 * tab0.col0 * + col0 FROM tab0 WHERE ( + col0 ) NOT IN ( + col2 )
----
118825
49536
720811

query I rowsort
SELECT ALL col1 * - col0 FROM tab1 WHERE NOT ( NULL ) IN ( + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8558
SELECT - col1 + col0 * col0 DIV + col0 AS col1 FROM tab2
----
-24
19
62

skipif mysql # not compatible
query I rowsort label-8558
SELECT - col1 + col0 * col0 / + col0 AS col1 FROM tab2
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8559
SELECT DISTINCT - col2 DIV col0 + + col1 FROM tab1
----
10
12
8

skipif mysql # not compatible
query I rowsort label-8559
SELECT DISTINCT - col2 / col0 + + col1 FROM tab1
----
10
12
8

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT - col2 BETWEEN + col1 AND NULL
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 col0 FROM tab2 WHERE NOT col2 NOT IN ( + col2 )
----
26
27
38

query I rowsort
SELECT DISTINCT col2 * + col0 * - col0 + col0 FROM tab0
----
-1190
-18984
-649433

query I rowsort
SELECT + col0 - col0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT col0 - col2 * + col0 AS col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT + col2 * + cor0.col1 + col1 - col0 AS col0 FROM tab0 AS cor0
----
159
2900
7464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col0 col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - cor0.col2 + col1 * col1 + - col1 * col0 FROM tab1 AS cor0
----
-597
-967
544

onlyif mysql # use DIV operator for integer division
query I rowsort label-8568
SELECT cor0.col1 * + col0 + + cor0.col2 + + cor0.col2 * col1 DIV col1 AS col2 FROM tab0 AS cor0
----
2130
3397
8263

skipif mysql # not compatible
query I rowsort label-8568
SELECT cor0.col1 * + col0 + + cor0.col2 + + cor0.col2 * col1 / col1 AS col2 FROM tab0 AS cor0
----
2130
3397
8263

onlyif mysql # use DIV operator for integer division
query I rowsort label-8569
SELECT ALL col1 DIV col1 + col1 col2 FROM tab0 cor0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8569
SELECT ALL col1 / col1 + col1 col2 FROM tab0 cor0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 * cor0.col2 col0 FROM tab0 AS cor0
----
-26136
-35
-598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-8571
SELECT - col1 DIV col0 + + col2 DIV col0 + + col1 AS col0 FROM tab1 AS cor0
----
10
14
36

skipif mysql # not compatible
query I rowsort label-8571
SELECT - col1 / col0 + + col2 / col0 + + col1 AS col0 FROM tab1 AS cor0
----
10
14
36

query I rowsort
SELECT - - col0 - col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - col0 + col1 - - col2 * - col0 AS col1 FROM tab0 AS cor0
----
-7296
-730
27

query I rowsort
SELECT ALL - col1 * col0 * + col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT + col0 + col1 * col0 + - col0 * col1 AS col1 FROM tab0 AS cor0
----
24
35
89

query IIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0 CROSS JOIN tab2 WHERE NULL >= ( NULL )
----

query I rowsort
SELECT + tab0.col0 * + tab0.col1 + tab0.col2 AS col2 FROM tab0 WHERE NOT + col2 - col0 NOT BETWEEN col2 * + col1 AND NULL
----

query I rowsort
SELECT col0 + col0 FROM tab2 AS cor0 WHERE NOT col2 * - col1 > col0
----
14
156
158

query I rowsort
SELECT col2 * + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8580
SELECT - CAST( NULL AS SIGNED ) + - 55 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8580
SELECT - CAST ( NULL AS INTEGER ) + - 55 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 56 AS col2 FROM tab0 cor0
----
56
56
56

query I rowsort
SELECT DISTINCT - + 90 * col2 FROM tab2 AS cor0
----
-2340
-2430
-3420

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + - col0 col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( col2 ) * col0 col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + - ( - col1 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - col2 * col1 * - col1 AS col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT DISTINCT + + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col1 + - col2 * + col0 + + 98 AS col0 FROM tab0
----
-608
-7109
160

query I rowsort
SELECT DISTINCT ( 53 ) * col1 * 67 + col1 - tab1.col1 AS col0 FROM tab1
----
35510
46163
92326

query I rowsort
SELECT + col2 * + cor0.col0 - col0 * + ( col1 ) FROM tab0 AS cor0
----
-1272
-3360
-801

query I rowsort
SELECT - cor0.col2 + col1 + + ( col2 + + col0 * - col2 ) FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT - col0 - col2 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT + 42 + col2 FROM tab0 AS cor0
----
124
43
75

query I rowsort
SELECT + col1 * + cor0.col2 + + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL - col2 + col1 * + col1 - + col2 AS col0 FROM tab2 AS cor0
----
213
3429
907

query I rowsort
SELECT col0 + 27 AS col2 FROM tab1 AS cor0
----
107
30
91

query I rowsort
SELECT DISTINCT - + col1 + ( + col0 ) + col2 FROM tab2 AS cor0
----
100
3
45

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - col0 - CAST ( col2 AS REAL ) AS col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT col0 * ( + 53 ) * col1 + + 67 + col2 FROM tab2 AS cor0
----
11595
243999
71284

query I rowsort
SELECT DISTINCT - - cor0.col1 + + ( + col1 ) + cor0.col2 * col2 AS col0 FROM tab1 AS cor0
----
2968
3269
9242

query I rowsort
SELECT DISTINCT - - col2 * col0 + col0 + col2 FROM tab2 AS cor0
----
2132
223
3119

query I rowsort
SELECT ALL - col1 + + 7 FROM tab0 cor0
----
-79
-84
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8604
SELECT DISTINCT col0 DIV 4 FROM tab0
----
22
6
8

skipif mysql # not compatible
query I rowsort label-8604
SELECT DISTINCT col0 / 4 FROM tab0
----
22
6
8

query I rowsort
SELECT DISTINCT - col1 * - 3 FROM tab2
----
177
51
93

query I rowsort
SELECT ALL + - 0 + ( col2 ) * ( col2 ) * + col1 FROM tab2 AS cor0
----
22599
24548
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col2 ) col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT col0 + - tab1.col2 * - 51 AS col0 FROM tab1
----
2757
2971
4976

query I rowsort
SELECT + col2 + 59 * - col1 FROM tab1
----
-1480
-533
-671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 92 col0 FROM tab1 AS cor0
----
-1196
-2392
-920

query I rowsort
SELECT - + col0 + col1 * + col2 FROM tab1 cor0
----
1168
1401
506

query I rowsort
SELECT col0 + col0 * + col1 * 97 AS col2 FROM tab2 AS cor0
----
130350
21056
446472

query I rowsort
SELECT 36 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT ALL ( - 50 ) FROM tab2
----
-50
-50
-50

query I rowsort
SELECT ALL 95 * - tab1.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 9f36e36a322a1b8f2872b1110f428817

onlyif mysql # use DIV operator for integer division
query I rowsort label-8616
SELECT DISTINCT col2 + + col0 DIV + 47 + 24 AS col2 FROM tab2
----
51
63

skipif mysql # not compatible
query I rowsort label-8616
SELECT DISTINCT col2 + + col0 / + 47 + 24 AS col2 FROM tab2
----
51
63

query I rowsort
SELECT + col1 * - col1 + col2 * ( tab0.col0 ) AS col1 FROM tab0
----
-6604
-9374
-983

query I rowsort
SELECT col1 * col0 + - col0 + - 49 FROM tab0
----
1991
3311
7961

query I rowsort
SELECT ALL 74 * + col1 * col2 FROM tab1
----
103896
42180
92352

query I rowsort
SELECT 86 AS col1 FROM tab0, tab1 cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to e219687f6f4ab6f7ee442792edcebca9

query I rowsort
SELECT DISTINCT - col2 * col1 * - 32 + tab0.col2 * col2 + - col0 FROM tab0
----
245419
3070
91881

query I rowsort
SELECT DISTINCT - col0 * + tab0.col1 + + ( tab0.col2 + col0 * + col1 ) FROM tab0
----
1
33
82

query I rowsort
SELECT ALL col0 * + tab2.col2 * - 2 FROM tab2
----
-378
-4056
-6004

query I rowsort
SELECT + 35 AS col0 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT ALL - col0 + - col0 * col1 * col0 AS col2 FROM tab1 AS cor0
----
-237
-41024
-83280

query I rowsort
SELECT DISTINCT col0 + 10 * 70 FROM tab1 AS cor0
----
703
764
780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8627
SELECT col2 + 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-8627
SELECT col2 + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col2 + + 49 AS col0 FROM tab2 AS cor0
----
11
22
23

query I rowsort
SELECT DISTINCT + + col2 + 2 * col0 FROM tab2 AS cor0
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-8630
SELECT ALL - col2 + 50 DIV col1 AS col2 FROM tab1 AS cor0
----
-52
-53
-93

skipif mysql # not compatible
query I rowsort label-8630
SELECT ALL - col2 + 50 / col1 AS col2 FROM tab1 AS cor0
----
-52
-53
-93

query I rowsort
SELECT DISTINCT - col0 + 61 * col1 - col1 AS col1 FROM tab1 AS cor0
----
1557
536
700

query I rowsort
SELECT - col1 + 69 FROM tab2 AS cor0
----
10
38
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-8633
SELECT col0 DIV + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8633
SELECT col0 / + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 24 AS col2 FROM tab1
----
24
24
24

query I rowsort
SELECT DISTINCT - 63 + col1 AS col1 FROM tab1
----
-37
-50
-53

query I rowsort
SELECT col2 * - col1 + - col2 AS col1 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT 48 + cor0.col2 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 1f4420c69e9883e4e81f6bf61ce8ff21

query I rowsort
SELECT - - 22 + col1 FROM tab2 AS cor0
----
39
53
81

query I rowsort
SELECT DISTINCT - 71 + col1 FROM tab0 AS cor0
----
15
20
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8640
SELECT DISTINCT + col2 * + cor0.col1 + CAST( - col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
1456
567
830

skipif mysql # not compatible
query I rowsort label-8640
SELECT DISTINCT + col2 * + cor0.col1 + CAST ( - col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
1456
567
830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 75 * - col2 col0 FROM tab2 AS cor0
----
1950
2025
2850

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to 01a5931cccc3dad8792a1bc6df09c614

query I rowsort
SELECT - + 52 FROM tab0, tab0 cor0
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

query I rowsort
SELECT col1 * 5 FROM tab1 AS cor0
----
130
50
65

query I rowsort
SELECT DISTINCT - col0 + + col2 * + 63 AS col1 FROM tab0 AS cor0
----
2055
28
5077

query I rowsort
SELECT ALL col1 + - 64 FROM tab0 AS cor0
----
22
27
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8647
SELECT ALL cor0.col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8647
SELECT ALL cor0.col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col2 * - 27 FROM tab0 AS cor0
----
-2214
-27
-891

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8649
SELECT DISTINCT col2 + - CAST( NULL AS SIGNED ) / 34 AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8649
SELECT DISTINCT col2 + - CAST ( NULL AS INTEGER ) / 34 AS col2 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8650
SELECT + col2 DIV + 83 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8650
SELECT + col2 / + 83 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + col0 * - 52 FROM tab2 AS cor0
----
-364
-4056
-4108

onlyif mysql # use DIV operator for integer division
query I rowsort label-8652
SELECT + + col2 + ( + 46 ) DIV + cor0.col0 AS col2 FROM tab1 AS cor0
----
57
69
96

skipif mysql # not compatible
query I rowsort label-8652
SELECT + + col2 + ( + 46 ) / + cor0.col0 AS col2 FROM tab1 AS cor0
----
57
69
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8653
SELECT DISTINCT - col2 + + col0 DIV col2 col1 FROM tab0 AS cor0
----
-33
-81
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8653
SELECT DISTINCT - col2 + + col0 / col2 col1 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT cor0.col1 * ( - 66 ) * col1 FROM tab2 AS cor0
----
-19074
-229746
-63426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 col2 FROM tab2
----
49
6084
6241

query I rowsort
SELECT + 48 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 56 + 62 * - cor0.col1 * + 14 col0 FROM tab2 cor0
----
-14700
-26852
-51156

query I rowsort
SELECT col1 * + cor0.col2 * cor0.col2 + + 4 AS col2 FROM tab2 AS cor0
----
22603
24552
39888

query I rowsort
SELECT col2 * + ( 34 ) AS col1 FROM tab2
----
1292
884
918

query I rowsort
SELECT + - cor0.col0 + 25 AS col2 FROM tab2 AS cor0
----
-53
-54
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8661
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8661
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT - + 32 + - col0 AS col2 FROM tab1 AS cor0
----
-112
-35
-96

query I rowsort
SELECT - col2 + + ( ( + col1 ) + tab0.col1 ) FROM tab0
----
100
139
193

query I rowsort
SELECT ALL - 79 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c9cc9510604e093bd158ca33928acaed

onlyif mysql # use DIV operator for integer division
query I rowsort label-8665
SELECT + col2 DIV ( ( col2 ) * ( + col2 ) + + col0 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8665
SELECT + col2 / ( ( col2 ) * ( + col2 ) + + col0 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + 62 FROM tab0, tab2 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT + 29 + 21 FROM tab1 AS cor0
----
50
50
50

query I rowsort
SELECT cor0.col2 + col2 AS col1 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT - - 10 * + col1 + col0 AS col0 FROM tab0 AS cor0
----
1005
884
999

query I rowsort
SELECT ALL - ( + col2 ) + + ( col1 ) AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + 92 * + col2 + 26 + + 66 AS col1 FROM tab2 AS cor0
----
2484
2576
3588

query I rowsort
SELECT ALL + cor0.col0 + - col1 * - 44 AS col0 FROM tab1 AS cor0
----
1147
504
652

query I rowsort
SELECT DISTINCT - 2 * cor0.col1 * + cor0.col0 FROM tab0, tab2, tab2 AS cor0
----
-2686
-434
-9204

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8674
SELECT ALL - 95 + + col1 / CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8674
SELECT ALL - 95 + + col1 / CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 * col0 - ( + col0 ) AS col2 FROM tab2 AS cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-8676
SELECT + cor0.col2 - - cor0.col2 DIV - ( + 33 ) FROM tab1 AS cor0
----
53
56
94

skipif mysql # not compatible
query I rowsort label-8676
SELECT + cor0.col2 - - cor0.col2 / - ( + 33 ) FROM tab1 AS cor0
----
53
56
94

query I rowsort
SELECT DISTINCT + + 95 * + col1 AS col0 FROM tab2 AS cor0
----
1615
2945
5605

onlyif mysql # use DIV operator for integer division
query I rowsort label-8678
SELECT col0 + + col1 DIV ( - col0 ) + col0 AS col0 FROM tab1 AS cor0
----
-2
128
160

skipif mysql # not compatible
query I rowsort label-8678
SELECT col0 + + col1 / ( - col0 ) + col0 AS col0 FROM tab1 AS cor0
----
-2
128
160

query I rowsort
SELECT ( + col2 ) * tab1.col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT - col1 * - col0 + col0 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL + ( col0 * col0 ) + 83 AS col1 FROM tab0
----
1308
659
8004

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col0 AS col1 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL + col0 * - col1 + + cor0.col1 * + 51 * col0 AS col2 FROM tab2 AS cor0
----
10850
230100
67150

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8684
SELECT ALL + 43 - col2 * - CAST( cor0.col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
140
2881
7505

skipif mysql # not compatible
query I rowsort label-8684
SELECT ALL + 43 - col2 * - CAST ( cor0.col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
140
2881
7505

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 58 * cor0.col2 - ( col1 ) col2 FROM tab0 AS cor0
----
-39
1828
4665

query I rowsort
SELECT DISTINCT + col2 * + cor0.col0 AS col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + cor0.col1 + cor0.col2 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col1 * col2 + + ( - col2 ) FROM tab2
----
1508
608
810

query I rowsort
SELECT DISTINCT - cor0.col0 + col0 + ( ( - col0 ) ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - col1 * col1 * - col0 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT DISTINCT 40 AS col1 FROM tab1, tab2 AS cor0
----
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-8692
SELECT - col1 DIV 3 FROM tab1 cor0
----
-3
-4
-8

skipif mysql # not compatible
query I rowsort label-8692
SELECT - col1 / 3 FROM tab1 cor0
----
-3
-4
-8

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to ca4c79a162f92454e0544707b897521a

query I rowsort
SELECT - + col2 + cor0.col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - 5 * - col0 + + col2 * - ( 87 * + cor0.col0 ) FROM tab1 AS cor0
----
-14079
-317056
-667760

query I rowsort
SELECT DISTINCT + 5 + + 82 AS col1 FROM tab0
----
87

query I rowsort
SELECT ALL - 15 * + col0 AS col1 FROM tab1 AS cor0
----
-1200
-45
-960

query I rowsort
SELECT - - 59 * cor0.col2 * cor0.col2 FROM tab1 cor0
----
172044
191691
543744

query I rowsort
SELECT ALL + col0 * 13 FROM tab1 cor0
----
1040
39
832

query I rowsort
SELECT - - ( col2 ) + + col2 * + ( col0 ) FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT 93 * cor1.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 791d782cef7809f2fe31312217e2c991

query I rowsort
SELECT DISTINCT col2 + 55 FROM tab2 AS cor0
----
81
82
93

query I rowsort
SELECT col1 + col0 * col0 * + col1 AS col0 FROM tab0
----
118922
49622
720902

query I rowsort
SELECT + 13 + col1 * + ( 55 ) FROM tab2
----
1718
3258
948

query I rowsort
SELECT + col1 + + col1 * col2 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + col1 * - tab2.col1 AS col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + ( + 43 ) AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT DISTINCT - - col0 * col0 + 33 * col0 * + col0 FROM tab1 AS cor0
----
139264
217600
306

query I rowsort
SELECT ALL - - col1 + col2 AS col0 FROM tab2 cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 78 col0 FROM tab0 AS cor0
----
2574
6396
78

query I rowsort
SELECT ALL col1 + 90 AS col2 FROM tab0 AS cor0
----
176
181
187

query I rowsort
SELECT ALL + col2 + - ( - col2 ) * cor0.col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL + col0 * - col1 + - 22 FROM tab2 AS cor0
----
-1365
-239
-4624

query I rowsort
SELECT DISTINCT col2 + + ( + col0 ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col0 + - ( + 33 ) AS col0 FROM tab0 AS cor0
----
-9
2
56

query I rowsort
SELECT DISTINCT - + col2 + + 82 * + col0 AS col0 FROM tab1 AS cor0
----
192
5191
6464

query I rowsort
SELECT + 63 + 28 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT + 19 * cor0.col0 + - cor0.col2 + ( col1 ) FROM tab2 AS cor0
----
137
1480
1515

query I rowsort
SELECT DISTINCT + - ( - 54 ) * - col1 FROM tab1 AS cor0
----
-1404
-540
-702

query I rowsort
SELECT DISTINCT - 45 + - col1 * col0 * col2 FROM tab2 cor0
----
-119697
-51079
-5904

query I rowsort
SELECT + 39 AS col1 FROM tab1 AS cor0
----
39
39
39

query I rowsort
SELECT ALL - + col2 * + col0 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - ( + 82 ) * + col1 AS col0 FROM tab0 AS cor0
----
-7052
-7462
-7954

query I rowsort
SELECT DISTINCT 99 * - col0 FROM tab1 AS cor0
----
-297
-6336
-7920

query I rowsort
SELECT - 96 * + col1 + - col0 * + 79 AS col0 FROM tab1 AS cor0
----
-2733
-6016
-7568

query I rowsort
SELECT DISTINCT + 21 + + col0 FROM tab0 AS cor0
----
110
45
56

query I rowsort
SELECT DISTINCT + + cor0.col0 * - col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL 97 + col1 FROM tab1
----
107
110
123

query I rowsort
SELECT - 7 AS col0 FROM tab1 AS cor0
----
-7
-7
-7

query I rowsort
SELECT + col0 + - col1 * 33 * - 13 FROM tab2 AS cor0
----
13306
25389
7372

query I rowsort
SELECT - 61 * + col0 AS col1 FROM tab0
----
-1464
-2135
-5429

query I rowsort
SELECT + cor0.col1 + + col2 * cor0.col1 - + 41 * col0 FROM tab1 cor0
----
-2019
-2044
1307

query I rowsort
SELECT + 87 * - col1 + + col0 + 62 AS col0 FROM tab0 AS cor0
----
-7396
-7766
-8342

query I rowsort
SELECT + 55 * - col0 * 71 FROM tab2 AS cor0
----
-27335
-304590
-308495

query I rowsort
SELECT - col1 * - 55 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT - cor0.col0 * - 74 + col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1247
6448
7290

query I rowsort
SELECT col2 * ( - col1 ) * col1 AS col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8739
SELECT - CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8739
SELECT - CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col2 * + col0 + - 27 FROM tab1
----
-189
-3675
-7707

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8741
SELECT ALL - CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-8741
SELECT ALL - CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT col2 * 74 + - col1 FROM tab0
----
-23
2356
5977

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab1, tab1 AS cor0
----
54
57
96

query I rowsort
SELECT 92 + + ( col1 ) * - 56 + + col2 AS col0 FROM tab1
----
-1310
-411
-540

onlyif mysql # use DIV operator for integer division
query I rowsort label-8745
SELECT - 99 DIV ( - col2 + + 9 ) AS col0 FROM tab1
----
1
2
2

skipif mysql # not compatible
query I rowsort label-8745
SELECT - 99 / ( - col2 + + 9 ) AS col0 FROM tab1
----
1
2
2

query I rowsort
SELECT DISTINCT + 4 * + col2 + + col0 FROM tab1
----
219
292
464

query I rowsort
SELECT - - cor0.col2 * col1 + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - 37 * col0 AS col0 FROM tab1
----
-111
-2368
-2960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-8750
SELECT 76 * - col2 DIV col2 AS col2 FROM tab0
----
-76
-76
-76

skipif mysql # not compatible
query I rowsort label-8750
SELECT 76 * - col2 / col2 AS col2 FROM tab0
----
-76
-76
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8751
SELECT - ( - col2 + + col0 ) DIV - tab0.col2 AS col0 FROM tab0
----
0
0
34

skipif mysql # not compatible
query I rowsort label-8751
SELECT - ( - col2 + + col0 ) / - tab0.col2 AS col0 FROM tab0
----
0
0
34

query I rowsort
SELECT col0 * 47 AS col0 FROM tab1
----
141
3008
3760

query I rowsort
SELECT - 90 FROM tab1, tab0 AS cor0
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

query I rowsort
SELECT DISTINCT tab0.col0 * + ( col1 ) AS col0 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + 5 col2 FROM tab2 AS cor0
----
12
83
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 - + col1 col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8757
SELECT - - CAST( col1 AS SIGNED ) + + col1 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-8757
SELECT - - CAST ( col1 AS INTEGER ) + + col1 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8758
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - 7 AS col2 FROM tab2, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8758
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - 7 AS col2 FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8760
SELECT + CAST( NULL AS DECIMAL ) + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8760
SELECT + CAST ( NULL AS REAL ) + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 47 - col2 AS col1 FROM tab2
----
20
21
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8762
SELECT - 80 + + col1 DIV tab0.col0 FROM tab0
----
-77
-78
-79

skipif mysql # not compatible
query I rowsort label-8762
SELECT - 80 + + col1 / tab0.col0 FROM tab0
----
-77
-78
-79

query I rowsort
SELECT DISTINCT col0 * + tab1.col2 * - col2 + - 92 FROM tab1
----
-208028
-737372
-8840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8764
SELECT DISTINCT - CAST( NULL AS SIGNED ) + ( col1 ) col2 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8764
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + ( col1 ) col2 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8765
SELECT + 29 DIV - col0 + - col1 AS col1 FROM tab0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-8765
SELECT + 29 / - col0 + - col1 AS col1 FROM tab0
----
-87
-91
-97

query I rowsort
SELECT ALL col2 * col0 - col1 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-8767
SELECT DISTINCT - + col1 * - col0 + - col2 + + ( - col2 ) DIV + col1 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-8767
SELECT DISTINCT - + col1 * - col0 + - col2 + + ( - col2 ) / + col1 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT ALL - col1 + - 72 * - col0 AS col2 FROM tab2 cor0
----
473
5557
5671

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 51 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + - 5 col0 FROM tab0 AS cor0
----
-4
28
77

query I rowsort
SELECT DISTINCT - col2 * - col2 + - cor0.col0 FROM tab0 cor0
----
-34
1065
6635

query I rowsort
SELECT + 65 + - tab0.col0 FROM tab0
----
-24
30
41

query I rowsort
SELECT + 62 * col0 FROM tab0 AS cor0
----
1488
2170
5518

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 8 col1 FROM tab1, tab1 cor0, tab1 cor1, tab0, tab0 AS cor2
----
243 values hashing to 166637359c82545ac3371f65af093c5f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8775
SELECT DISTINCT col1 + + CAST( + 31 AS SIGNED ) FROM tab1 AS cor0
----
41
44
57

skipif mysql # not compatible
query I rowsort label-8775
SELECT DISTINCT col1 + + CAST ( + 31 AS INTEGER ) FROM tab1 AS cor0
----
41
44
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8776
SELECT ALL + + col0 + 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-8776
SELECT ALL + + col0 + CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 * + col0 * cor0.col2 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - col1 - + 62 FROM tab2 AS cor0
----
-121
-79
-93

query I rowsort
SELECT col0 * col1 * col1 + col0 FROM tab1 AS cor0
----
13600
2031
6464

query I rowsort
SELECT DISTINCT tab1.col0 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT col1 * + 87 - ( + col1 ) * + 74 FROM tab2 AS cor0
----
221
403
767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * - col0 col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - + col1 * - col1 * - col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT col0 - CAST ( + 87 AS REAL ) col2 FROM tab1 AS cor0
----
-23
-7
-84

query I rowsort
SELECT DISTINCT - col1 + col0 + - col1 AS col2 FROM tab2 cor0
----
-40
-55
45

query I rowsort
SELECT ALL col0 * 35 FROM tab1 AS cor0
----
105
2240
2800

query I rowsort
SELECT ALL - cor0.col2 * 12 AS col2 FROM tab2 AS cor0
----
-312
-324
-456

query I rowsort
SELECT DISTINCT col1 + col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT col1 + col1 * + col1 FROM tab2
----
306
3540
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col1 * tab0.col0 col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL col0 * - col1 + ( + col2 * + col2 ) + col1 FROM tab2
----
-3867
118
543

onlyif mysql # use DIV operator for integer division
query I rowsort label-8792
SELECT - col1 DIV - col1 col1 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8792
SELECT - col1 / - col1 col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + 48 FROM tab0, tab0 cor0, tab2 AS cor1
----
48

query I rowsort
SELECT + cor0.col0 + ( ( + cor0.col0 ) ) FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - + cor0.col2 * + col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + - col1 * 9 + + cor0.col2 AS col2 FROM tab2 cor0
----
-115
-252
-505

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8797
SELECT - col1 * col0 + - cor0.col0 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8797
SELECT - col1 * col0 + - cor0.col0 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 8 + col0 + col2 col1 FROM tab1 AS cor0
----
113
168
49

query I rowsort
SELECT - + 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-8800
SELECT DISTINCT - + CAST( - 38 AS SIGNED ) * cor0.col2 FROM tab2 cor0
----
1026
1444
988

skipif mysql # not compatible
query I rowsort label-8800
SELECT DISTINCT - + CAST ( - 38 AS INTEGER ) * cor0.col2 FROM tab2 cor0
----
1026
1444
988

query I rowsort
SELECT ALL + - cor0.col2 * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - 32 * col2 - col1 FROM tab2 AS cor0
----
-1233
-891
-895

onlyif mysql # use DIV operator for integer division
query I rowsort label-8803
SELECT ALL - ( + col0 ) DIV + col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-8803
SELECT ALL - ( + col0 ) / + col0 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8804
SELECT + CAST( - ( cor0.col0 ) AS SIGNED ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-8804
SELECT + CAST ( - ( cor0.col0 ) AS INTEGER ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + - 40 AS col1 FROM tab0 AS cor0
----
-40
-40
-40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8806
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + + col2 * col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8806
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + + col2 * col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( ( col1 ) ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL col0 + + 12 * 69 + + col0 AS col2 FROM tab1
----
834
956
988

query I rowsort
SELECT ALL + col1 * + col2 + 50 FROM tab0
----
147
2888
7512

query I rowsort
SELECT tab0.col1 * - col2 * ( col0 + + 34 ) AS col2 FROM tab0
----
-164604
-6693
-917826

query I rowsort
SELECT DISTINCT + col2 * col2 - 93 AS col0 FROM tab0
----
-92
6631
996

onlyif mysql # use DIV operator for integer division
query I rowsort label-8812
SELECT ALL tab1.col1 DIV + col0 - col2 FROM tab1
----
-46
-57
-96

skipif mysql # not compatible
query I rowsort label-8812
SELECT ALL tab1.col1 / + col0 - col2 FROM tab1
----
-46
-57
-96

query I rowsort
SELECT ALL tab1.col1 * col1 - col2 * + tab1.col0 * + col2 FROM tab1
----
-207836
-737111
-8072

query I rowsort
SELECT ALL + col0 - col1 AS col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT - - 40 * col1 - + ( col0 ) AS col1 FROM tab0 AS cor0
----
3416
3551
3845

query I rowsort
SELECT - + 94 * cor0.col1 + cor0.col1 * cor0.col0 FROM tab1 AS cor0
----
-182
-2366
-300

query I rowsort
SELECT ALL 22 * col1 * cor0.col2 + + col1 FROM tab0 AS cor0
----
164255
2231
62522

query I rowsort
SELECT DISTINCT col0 * - col0 + - col1 * ( col1 ) AS col2 FROM tab1 AS cor0
----
-4196
-6569
-685

onlyif mysql # use DIV operator for integer division
query I rowsort label-8819
SELECT ALL - 74 + col0 DIV + 86 AS col0 FROM tab0 AS cor0
----
-73
-74
-74

skipif mysql # not compatible
query I rowsort label-8819
SELECT ALL - 74 + col0 / + 86 AS col0 FROM tab0 AS cor0
----
-73
-74
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-8820
SELECT DISTINCT + + col1 DIV - col1 + col0 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-8820
SELECT DISTINCT + + col1 / - col1 + col0 AS col1 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT ALL + col1 * - col1 * 8 + + ( col2 ) AS col1 FROM tab1 cor0
----
-1256
-5354
-743

onlyif mysql # use DIV operator for integer division
query I rowsort label-8822
SELECT DISTINCT - col1 DIV col0 col0 FROM tab2 AS cor0
----
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8822
SELECT DISTINCT - col1 / col0 col0 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT - 90 + - tab0.col1 * col1 AS col1 FROM tab0
----
-7486
-8371
-9499

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8824
SELECT DISTINCT + CAST( col0 AS SIGNED ) * - col1 + col2 * + col0 FROM tab2
----
-2574
-28
1659

skipif mysql # not compatible
query I rowsort label-8824
SELECT DISTINCT + CAST ( col0 AS INTEGER ) * - col1 + col2 * + col0 FROM tab2
----
-2574
-28
1659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 col0 FROM tab0 cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 41 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT + 8 AS col1 FROM tab2, tab0 AS cor0
----
8

query I rowsort
SELECT 87 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT ALL 68 AS col1 FROM tab2
----
68
68
68

query I rowsort
SELECT DISTINCT - + 43 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-8831
SELECT ALL - - col1 DIV cor0.col0 + cor0.col0 AS col2 FROM tab0 cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-8831
SELECT ALL - - col1 / cor0.col0 + cor0.col0 AS col2 FROM tab0 cor0
----
27
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-8832
SELECT DISTINCT - col2 * col1 DIV ( 91 ) FROM tab0 AS cor0
----
-1
-31
-82

skipif mysql # not compatible
query I rowsort label-8832
SELECT DISTINCT - col2 * col1 / ( 91 ) FROM tab0 AS cor0
----
-1
-31
-82

query I rowsort
SELECT - - col2 + col0 * - cor0.col0 FROM tab1 cor0
----
-4039
-6304
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + - col0 * col1 col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT + + ( col0 ) + + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - col1 + cor0.col1 * col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL - - col0 + 63 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-2055
-28
-5077

onlyif mysql # use DIV operator for integer division
query I rowsort label-8838
SELECT DISTINCT col0 - - 94 DIV - col1 FROM tab1 AS cor0
----
0
55
73

skipif mysql # not compatible
query I rowsort label-8838
SELECT DISTINCT col0 - - 94 / - col1 FROM tab1 AS cor0
----
0
55
73

query I rowsort
SELECT - col1 * + ( - tab1.col2 ) AS col0 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8840
SELECT ALL tab0.col2 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8840
SELECT ALL tab0.col2 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + + 21 * - tab1.col2 AS col1 FROM tab1
----
-1160
-1207
-2029

query I rowsort
SELECT - cor0.col1 + 29 AS col1 FROM tab1 AS cor0
----
16
19
3

query I rowsort
SELECT DISTINCT - 61 + 76 FROM tab1, tab0 AS cor0
----
15

query I rowsort
SELECT ALL - col2 + - col0 + - col1 * col0 FROM tab2 AS cor0
----
-1460
-251
-4706

query I rowsort
SELECT DISTINCT + ( - col1 ) + - col1 AS col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL + ( 52 ) * - col1 AS col2 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT ( col1 ) + col0 * - ( + col2 ) FROM tab0 AS cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col0 ) * col0 col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + cor0.col2 * col2 + + col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-8850
SELECT ALL + col1 DIV - col1 + - col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7397
-8282
-9410

skipif mysql # not compatible
query I rowsort label-8850
SELECT ALL + col1 / - col1 + - col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7397
-8282
-9410

query I rowsort
SELECT DISTINCT cor0.col2 * - col0 + col0 * + col0 AS col2 FROM tab0 cor0
----
-216
1190
623

query I rowsort
SELECT - col0 * + col1 * col2 AS col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT col0 + + col1 * + col0 + - 46 FROM tab1
----
1074
35
658

query I rowsort
SELECT DISTINCT + col1 * col0 - col1 FROM tab1
----
1027
52
630

query I rowsort
SELECT - + cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT 1 + + col0 - 7 * - col1 FROM tab2
----
199
225
492

query I rowsort
SELECT col1 + + col2 + + col0 * + col1 * col0 FROM tab1
----
314
41027
83309

query I rowsort
SELECT + col1 * col2 * + col1 + - 32 + col1 AS col0 FROM tab0
----
244122
679101
9474

query I rowsort
SELECT DISTINCT 63 + + col2 FROM tab0
----
145
64
96

query I rowsort
SELECT - col1 * + ( ( + col2 ) ) + 89 * 93 * col2 + + col0 AS col0 FROM tab2
----
213746
222649
313959

query I rowsort
SELECT - col1 * - ( 75 ) AS col0 FROM tab2
----
1275
2325
4425

query I rowsort
SELECT - col1 * tab0.col0 * - tab0.col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + col1 * ( col1 ) + col2 AS col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT - col0 + 91 AS col0 FROM tab0
----
2
56
67

query I rowsort
SELECT DISTINCT + 49 AS col1 FROM tab1, tab1 AS cor0
----
49

query I rowsort
SELECT ALL - col2 + ( - col2 ) FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - col2 * - 70 + - col2 AS col0 FROM tab2 AS cor0
----
1794
1863
2622

query I rowsort
SELECT + 21 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT DISTINCT - 27 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
-27

query I rowsort
SELECT + + cor0.col2 + cor0.col0 * col1 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8871
SELECT - + col0 + + CAST( - 0 AS SIGNED ) + - col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-8871
SELECT - + col0 + + CAST ( - 0 AS INTEGER ) + - col2 AS col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + + col1 * + 29 AS col2 FROM tab2 AS cor0
----
1711
493
899

onlyif mysql # use DIV operator for integer division
query I rowsort label-8873
SELECT - col2 * ( col0 ) + - col2 DIV col2 col1 FROM tab1 AS cor0
----
-163
-3649
-7681

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8873
SELECT - col2 * ( col0 ) + - col2 / col2 col1 FROM tab1 AS cor0
----
-163
-3649
-7681

query I rowsort
SELECT + col2 * + 24 + + col0 * - col1 + + col2 AS col1 FROM tab1 AS cor0
----
1272
1360
785

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 77 + cor0.col2 + col1 col1 FROM tab2 AS cor0
----
-19
-22
8

query I rowsort
SELECT - 8 * + col0 + - col0 * + col2 FROM tab0
----
-315
-8010
-984

query I rowsort
SELECT ALL 68 + col2 AS col2 FROM tab1
----
122
125
164

query I rowsort
SELECT DISTINCT col2 + - 9 AS col2 FROM tab0
----
-8
24
73

query I rowsort
SELECT ( - col2 ) * col2 + col0 AS col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT - 8 * 3 + col1 * col1 FROM tab1 AS cor0
----
145
652
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8881
SELECT - CAST( NULL AS SIGNED ) - - cor0.col2 * cor0.col1 * col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8881
SELECT - CAST ( NULL AS INTEGER ) - - cor0.col2 * cor0.col1 * col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + col2 * col1 AS col0 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-8883
SELECT ALL 91 + col0 DIV ( + col0 ) FROM tab1 cor0
----
92
92
92

skipif mysql # not compatible
query I rowsort label-8883
SELECT ALL 91 + col0 / ( + col0 ) FROM tab1 cor0
----
92
92
92

query I rowsort
SELECT ALL ( + col0 ) + + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + - ( - col2 ) * + ( col1 ) FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 94 col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
94

query I rowsort
SELECT col1 + ( - cor0.col0 ) AS col0 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8888
SELECT - col2 * CAST( - col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-8888
SELECT - col2 * CAST ( - col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8889
SELECT tab2.col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8889
SELECT tab2.col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 95 AS col0 FROM tab1
----
-95
-95
-95

query I rowsort
SELECT ALL + col0 + - cor0.col2 - + 37 AS col1 FROM tab0 AS cor0
----
-3
-30
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-8892
SELECT - 70 + + col1 DIV - 98 AS col2 FROM tab2 AS cor0
----
-70
-70
-70

skipif mysql # not compatible
query I rowsort label-8892
SELECT - 70 + + col1 / - 98 AS col2 FROM tab2 AS cor0
----
-70
-70
-70

query I rowsort
SELECT DISTINCT + - col1 + col2 * col0 AS col0 FROM tab2 AS cor0
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + cor0.col0 col2 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8895
SELECT CAST( + 83 AS SIGNED ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

skipif mysql # not compatible
query I rowsort label-8895
SELECT CAST ( + 83 AS INTEGER ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT DISTINCT cor0.col1 * - col0 + - 60 FROM tab1 AS cor0
----
-1100
-138
-700

query I rowsort
SELECT DISTINCT 85 + + col1 * + col1 AS col0 FROM tab2 AS cor0
----
1046
3566
374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8899
SELECT ALL 20 - + col0 / - 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-8899
SELECT ALL 20 - + col0 / - CAST ( NULL AS INTEGER ) col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * - ( 27 * col1 ) AS col2 FROM tab1
----
-15390
-33696
-37908

query I rowsort
SELECT DISTINCT ( tab0.col2 ) FROM tab0, tab1 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT tab1.col1 * - 69 FROM tab1
----
-1794
-690
-897

query I rowsort
SELECT DISTINCT tab1.col1 FROM tab1, tab1 cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT ( - 6 ) * col1 FROM tab1 AS cor0
----
-156
-60
-78

query I rowsort
SELECT + cor0.col1 + ( + cor0.col0 ) * cor0.col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c4c241ffc8029f59b79a2ffd7677e8b8

query I rowsort
SELECT col1 * - 12 * col2 - tab2.col2 FROM tab2
----
-10071
-18434
-7790

query I rowsort
SELECT - - 93 AS col1 FROM tab1 AS cor0
----
93
93
93

query I rowsort
SELECT DISTINCT - tab1.col2 * - 31 AS col2 FROM tab1
----
1674
1767
2976

query I rowsort
SELECT col0 + + tab1.col2 AS col1 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8910
SELECT DISTINCT ( col0 ) - col0 DIV + col0 FROM tab2 cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-8910
SELECT DISTINCT ( col0 ) - col0 / + col0 FROM tab2 cor0
----
6
77
78

query I rowsort
SELECT + 25 * 59 FROM tab0 AS cor0
----
1475
1475
1475

query I rowsort
SELECT ALL - + 69 * + 44 + + col1 AS col1 FROM tab2 AS cor0
----
-2977
-3005
-3019

query I rowsort
SELECT ALL - 1 * col2 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8914
SELECT DISTINCT - cor0.col2 / - ( col1 ) - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8914
SELECT DISTINCT - cor0.col2 / - ( col1 ) - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + 95 AS REAL ) FROM tab2 AS cor0
----
95
95
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8916
SELECT - CAST( + 13 AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
-221
-403
-767

skipif mysql # not compatible
query I rowsort label-8916
SELECT - CAST ( + 13 AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
-221
-403
-767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 45 + + col1 col1 FROM tab2 AS cor0
----
-14
-28
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - 75 col0 FROM tab1
----
-225
-4800
-6000

query I rowsort
SELECT ( + col0 ) + + col0 AS col0 FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col2 AS REAL ) AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT 70 + col2 * col1 AS col2 FROM tab2
----
1604
716
907

query I rowsort
SELECT ( col0 ) + col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT - 30 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

query I rowsort
SELECT DISTINCT ( col0 ) AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL col1 * 10 FROM tab0 AS cor0
----
860
910
970

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 13 + col2 col0 FROM tab1 AS cor0
----
109
67
70

query I rowsort
SELECT - - col1 * col0 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT ( col1 ) + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL 16 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col2 * + cor0.col1 col0 FROM tab2 cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT 78 AS col0 FROM tab1 AS cor0
----
78

query I rowsort
SELECT ALL col1 + col2 AS col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 57 * + col0 + - 61 FROM tab1 cor0
----
110
3587
4499

query I rowsort
SELECT DISTINCT + col1 * - col0 * col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 60 * col0 col1 FROM tab1 cor0
----
-180
-3840
-4800

query I rowsort
SELECT DISTINCT - 96 AS col2 FROM tab2 AS cor0
----
-96

query I rowsort
SELECT ALL - - 3 + + col0 * ( col0 ) AS col1 FROM tab1 AS cor0
----
12
4099
6403

query I rowsort
SELECT 92 - tab1.col1 * col0 FROM tab1
----
-548
-948
14

query I rowsort
SELECT DISTINCT + col0 - + col0 * + ( - col1 + + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + cor0.col2 * - col1 + - col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT ( col1 ) + - 36 * ( - col1 ) FROM tab0 cor0
----
3182
3367
3589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * col2 col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - cor0.col1 * + col1 - + cor0.col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-8944
SELECT DISTINCT cor0.col0 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-8944
SELECT DISTINCT cor0.col0 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT ALL - + col2 * col2 + + col1 AS col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( cor0.col0 ) col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + - col1 + 50 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1274
490
637

query I rowsort
SELECT DISTINCT + col1 + - col1 * cor0.col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + cor0.col0 + 50 * col1 AS col0 FROM tab0 AS cor0
----
4324
4639
4885

onlyif mysql # use DIV operator for integer division
query I rowsort label-8950
SELECT - - col1 DIV + 41 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-8950
SELECT - - col1 / + 41 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT ALL - col0 + - col2 * col2 * - col1 FROM tab0 cor0
----
611795
62
93630

query I rowsort
SELECT cor0.col0 * + ( + cor0.col1 ) * - col0 + 0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT - col1 + 72 AS col1 FROM tab0 AS cor0
----
-14
-19
-25

onlyif mysql # use DIV operator for integer division
query I rowsort label-8954
SELECT - cor0.col1 DIV CAST( col0 + col1 AS SIGNED ) col0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8954
SELECT - cor0.col1 / CAST ( col0 + col1 AS INTEGER ) col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8955
SELECT + cor0.col0 DIV + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8955
SELECT + cor0.col0 / + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8956
SELECT DISTINCT + cor0.col2 DIV 42 + cor0.col1 col0 FROM tab1 AS cor0
----
11
15
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8956
SELECT DISTINCT + cor0.col2 / 42 + cor0.col1 col0 FROM tab1 AS cor0
----
11
15
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 * + 54 col2 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT DISTINCT + 88 * col0 FROM tab1 AS cor0
----
264
5632
7040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8959
SELECT ALL + CAST( 93 AS SIGNED ) + - col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-2823
-3156
-9123

skipif mysql # not compatible
query I rowsort label-8959
SELECT ALL + CAST ( 93 AS INTEGER ) + - col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-2823
-3156
-9123

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8960
SELECT ALL - CAST( + col2 AS SIGNED ) * col1 + + 73 * - 33 FROM tab0 AS cor0
----
-2506
-5247
-9871

skipif mysql # not compatible
query I rowsort label-8960
SELECT ALL - CAST ( + col2 AS INTEGER ) * col1 + + 73 * - 33 FROM tab0 AS cor0
----
-2506
-5247
-9871

query I rowsort
SELECT DISTINCT - + 41 * col0 AS col1 FROM tab0 AS cor0
----
-1435
-3649
-984

onlyif mysql # use DIV operator for integer division
query I rowsort label-8962
SELECT ALL 61 DIV - ( - cor0.col1 ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-8962
SELECT ALL 61 / - ( - cor0.col1 ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT tab2.col1 + ( tab2.col1 ) AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT tab2.col1 * 16 FROM tab2
----
272
496
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-8965
SELECT tab2.col1 DIV + 87 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8965
SELECT tab2.col1 / + 87 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT - ( 49 ) + + cor0.col0 AS col0 FROM tab1, tab1 AS cor0
----
-46
15
31

query I rowsort
SELECT - cor0.col1 + - col1 + col0 * col0 FROM tab0 AS cor0
----
1031
404
7739

query I rowsort
SELECT + col1 * + 55 FROM tab2
----
1705
3245
935

query I rowsort
SELECT - col2 * + 41 AS col2 FROM tab2
----
-1066
-1107
-1558

query I rowsort
SELECT col2 + ( col1 ) + col2 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT - + col1 * - col2 + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + col1 * + cor0.col2 + - col0 AS col0 FROM tab0 cor0
----
2814
62
7373

query I rowsort
SELECT 45 + - col0 + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-133
-25
-3

query I rowsort
SELECT - ( col1 ) + - col1 + ( + col1 + + col1 ) AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - ( + 64 ) * col2 FROM tab0 AS cor0
----
-2112
-5248
-64

query I rowsort
SELECT + cor0.col0 + + col0 * - col0 + 94 AS col1 FROM tab2 AS cor0
----
-5912
-6068
52

query I rowsort
SELECT + ( - col2 ) + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 47 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT ALL + tab2.col2 + col2 AS col0 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 * cor0.col0 col2 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + - col2 * col1 + - 93 FROM tab2 AS cor0
----
-1627
-739
-930

query I rowsort
SELECT ALL - + 54 * + col1 * - col1 FROM tab1 cor0
----
36504
5400
9126

onlyif mysql # use DIV operator for integer division
query I rowsort label-8983
SELECT ALL col1 DIV col2 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-8983
SELECT ALL col1 / col2 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + 99 AS col0 FROM tab2 AS cor0
----
-99

query I rowsort
SELECT + ( col1 ) + - col0 * col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - col0 * - col0 + - ( + col1 ) AS col2 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT ALL - - cor0.col1 * + col1 AS col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT col2 + col2 * - col1 AS col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT - + 8 * + col0 AS col1 FROM tab2 AS cor0
----
-56
-624
-632

query I rowsort
SELECT 59 * col2 AS col1 FROM tab1 AS cor0
----
3186
3363
5664

query I rowsort
SELECT + tab1.col2 + col1 * - tab1.col1 FROM tab1
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 col1 FROM tab0, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - col1 * col2 * col0 - cor0.col0 FROM tab0 AS cor0
----
-3430
-664207
-68136

query I rowsort
SELECT DISTINCT + col0 * 90 + - col0 * col0 AS col2 FROM tab1 AS cor0
----
1664
261
800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8995
SELECT + cor0.col1 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8995
SELECT + cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + - 55 FROM tab2 AS cor0
----
-81
-82
-93

query I rowsort
SELECT - 92 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to a0e6b76227d870d10c4d9f46545a7c83

query I rowsort
SELECT ALL - col0 + col1 * + 17 AS col1 FROM tab1 AS cor0
----
106
141
439

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 59 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ( + tab2.col0 ) FROM tab2, tab0 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-9001
SELECT + + col0 DIV 46 AS col1 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9001
SELECT + + col0 / 46 AS col1 FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT - 55 FROM tab0, tab1 cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

query I rowsort
SELECT - col0 - 64 FROM tab1
----
-128
-144
-67

query I rowsort
SELECT DISTINCT + ( + 97 ) * - tab1.col1 AS col0 FROM tab1
----
-1261
-2522
-970

query I rowsort
SELECT - + 49 * col0 AS col1 FROM tab0 cor0
----
-1176
-1715
-4361

query I rowsort
SELECT DISTINCT + ( col0 ) * - col0 + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL ( col1 ) * + col1 - ( col1 ) FROM tab0 AS cor0
----
7310
8190
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-9008
SELECT col2 DIV - col1 + + col0 * - col2 FROM tab1
----
-164
-3653
-7687

skipif mysql # not compatible
query I rowsort label-9008
SELECT col2 / - col1 + + col0 * - col2 FROM tab1
----
-164
-3653
-7687

query I rowsort
SELECT ALL - ( 77 ) AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT 81 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT - ( 15 * - col2 ) AS col2 FROM tab1
----
1440
810
855

query I rowsort
SELECT DISTINCT 12 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2, tab1 AS cor1
----
12

query I rowsort
SELECT + - 17 * cor0.col0 FROM tab2 cor0
----
-119
-1326
-1343

query I rowsort
SELECT + 96 + - 68 AS col1 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT + 92 + - col0 AS col1 FROM tab2 AS cor0
----
13
14
85

query I rowsort
SELECT DISTINCT + col1 * 92 + col2 FROM tab1 cor0
----
1292
2446
977

onlyif mysql # use DIV operator for integer division
query I rowsort label-9017
SELECT DISTINCT + 37 DIV col1 AS col2 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-9017
SELECT DISTINCT + 37 / col1 AS col2 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT - - ( col1 ) + - col0 * + col0 FROM tab0 cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL + 39 + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-47
-52
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-9020
SELECT 89 * col2 DIV - col0 FROM tab2 AS cor0
----
-29
-343
-42

skipif mysql # not compatible
query I rowsort label-9020
SELECT 89 * col2 / - col0 FROM tab2 AS cor0
----
-29
-343
-42

query I rowsort
SELECT ALL - ( - col1 ) * col1 * + ( + 27 ) AS col0 FROM tab1 AS cor0
----
18252
2700
4563

query I rowsort
SELECT + - 4 AS col0 FROM tab2 cor0
----
-4
-4
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + 25 col1 FROM tab1 AS cor0
----
-29
-32
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 col2 FROM tab2 AS cor0
----
79
79
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9025
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9025
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - ( ( + col2 ) ) * 32 + - 38 FROM tab2 AS cor0
----
-1254
-870
-902

onlyif mysql # use DIV operator for integer division
query I rowsort label-9027
SELECT ALL - col1 DIV col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9027
SELECT ALL - col1 / col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 23 AS col2 FROM tab2 AS cor0
----
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9029
SELECT + - ( col0 ) + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9029
SELECT + - ( col0 ) + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 30 AS col0 FROM tab2 AS cor0
----
30

query I rowsort
SELECT ALL + 95 FROM tab2
----
95
95
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-9032
SELECT ALL col2 DIV + ( + col0 ) FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-9032
SELECT ALL col2 / + ( + col0 ) FROM tab2
----
0
0
3

query I rowsort
SELECT ALL - col2 + - 92 AS col2 FROM tab1 AS cor0
----
-146
-149
-188

query I rowsort
SELECT ALL col2 * ( + col2 ) - - cor0.col1 AS col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT - - col0 + col0 * ( col0 ) AS col0 FROM tab2 cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-9036
SELECT - + col1 DIV - ( col0 ) + col0 AS col1 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-9036
SELECT - + col1 / - ( col0 ) + col0 AS col1 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT - cor0.col2 * + cor0.col2 + + 54 AS col2 FROM tab0 AS cor0
----
-1035
-6670
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9038
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9038
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - col0 col2 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT DISTINCT col2 + - col1 * - col0 AS col0 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL col1 * + 33 AS col1 FROM tab1
----
330
429
858

query I rowsort
SELECT ALL + 43 * - col2 AS col1 FROM tab2 AS cor0
----
-1118
-1161
-1634

query I rowsort
SELECT DISTINCT + 43 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1118
1161
1634

query I rowsort
SELECT ALL 40 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT col2 * - col0 - tab0.col1 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT + col1 + 11 AS col2 FROM tab1
----
21
24
37

query I rowsort
SELECT DISTINCT + col0 + + col2 + - col0 * col2 * 13 AS col0 FROM tab0
----
-10239
-419
-94703

query I rowsort
SELECT + + 28 * - col0 + col0 FROM tab1 AS cor0
----
-1728
-2160
-81

query I rowsort
SELECT DISTINCT col0 * + 15 + + col1 FROM tab2
----
1202
1229
136

query I rowsort
SELECT DISTINCT - - col1 * - col1 + col1 + - col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT col0 * col2 + col2 AS col2 FROM tab1 AS cor0
----
216
3705
7776

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab1 cor1, tab2 AS cor2
----
972 values hashing to bcf430f79386b43bc4077271fcd15cf0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9053
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9053
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT ALL - col1 * - ( + col2 ) * col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT 35 AS col1 FROM tab1
----
35
35
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9056
SELECT - CAST( 53 * - col0 AS SIGNED ) + tab2.col1 * - col0 AS col1 FROM tab2
----
-468
154
2844

skipif mysql # not compatible
query I rowsort label-9056
SELECT - CAST ( 53 * - col0 AS INTEGER ) + tab2.col1 * - col0 AS col1 FROM tab2
----
-468
154
2844

onlyif mysql # use DIV operator for integer division
query I rowsort label-9057
SELECT ALL + col0 * col1 + col0 + - col1 DIV - ( - col1 ) col1 FROM tab1 AS cor0
----
1119
703
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9057
SELECT ALL + col0 * col1 + col0 + - col1 / - ( - col1 ) col1 FROM tab1 AS cor0
----
1119
703
80

query I rowsort
SELECT ALL - cor0.col2 * ( cor0.col1 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 86c8e75d83d283b29460c020ab5988af

query I rowsort
SELECT ALL 28 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

query I rowsort
SELECT DISTINCT + col1 * + col0 + 71 AS col2 FROM tab2 cor0
----
1414
288
4673

query I rowsort
SELECT cor0.col2 + col1 * - ( + 4 ) AS col0 FROM tab1 AS cor0
----
-50
17
44

query I rowsort
SELECT ALL - - 11 + - cor0.col1 * 24 * + ( - col1 + col2 * cor0.col2 ) AS col2 FROM tab2 cor0
----
-519301
-582205
-873661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - 14 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e36a45752f8c153f7c91c8154f8a920f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9064
SELECT ALL 8 * col0 + + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9064
SELECT ALL 8 * col0 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9065
SELECT DISTINCT - 83 / - col0 + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9065
SELECT DISTINCT - 83 / - col0 + CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT - cor0.col1 + col0 * col1 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT ALL col0 + ( col1 ) AS col2 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-9068
SELECT + col1 DIV - 7 + + 53 FROM tab2 AS cor0
----
45
49
51

skipif mysql # not compatible
query I rowsort label-9068
SELECT + col1 / - 7 + + 53 FROM tab2 AS cor0
----
45
49
51

query I rowsort
SELECT DISTINCT - col2 + + ( col1 ) * col1 AS col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT + col0 * - ( col1 ) FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9071
SELECT ALL + col2 DIV ( 26 ) FROM tab0 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-9071
SELECT ALL + col2 / ( 26 ) FROM tab0 AS cor0
----
0
1
3

query I rowsort
SELECT 32 + + cor1.col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 87305d0d4ea974dff5c91d1dee71f714

query I rowsort
SELECT col1 * 95 + col0 FROM tab0 AS cor0
----
8194
8734
9250

query I rowsort
SELECT ALL col0 + + ( 97 ) AS col0 FROM tab2 cor0
----
104
175
176

query I rowsort
SELECT DISTINCT col2 + - ( - 7 ) FROM tab0 AS cor0
----
40
8
89

query I rowsort
SELECT DISTINCT - + col2 * - 16 + - col2 + col0 AS col1 FROM tab0 AS cor0
----
1319
50
519

query I rowsort
SELECT DISTINCT + col1 + cor0.col0 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9078
SELECT DISTINCT + col0 DIV 29 + + col1 * + col2 * cor0.col2 FROM tab2 AS cor0
----
22599
24550
39886

skipif mysql # not compatible
query I rowsort label-9078
SELECT DISTINCT + col0 / 29 + + col1 * + col2 * cor0.col2 FROM tab2 AS cor0
----
22599
24550
39886

query I rowsort
SELECT ALL cor0.col2 + - col0 FROM tab2 cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 56 * col2 col2 FROM tab1
----
-3024
-3192
-5376

query I rowsort
SELECT + col2 + 92 * col0 FROM tab1
----
330
5945
7456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9082
SELECT ALL + CAST( NULL AS SIGNED ) * + col1 / - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9082
SELECT ALL + CAST ( NULL AS INTEGER ) * + col1 / - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + tab1.col2 * - 8 FROM tab1
----
-432
-456
-768

query I rowsort
SELECT - col1 + - 16 * + cor0.col1 FROM tab1 AS cor0
----
-170
-221
-442

query I rowsort
SELECT DISTINCT + - col2 * - col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 21 * - col1 AS col1 FROM tab0 AS cor0
----
-1806
-1911
-2037

query I rowsort
SELECT 72 + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1606
718
909

query I rowsort
SELECT 20 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT - col2 + col1 * ( col1 ) FROM tab2 AS cor0
----
251
3455
934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 42 + col2 col1 FROM tab1 AS cor0
----
12
15
54

query I rowsort
SELECT + - 40 * col2 FROM tab0 AS cor0
----
-1320
-3280
-40

query I rowsort
SELECT - + col0 + cor0.col1 * ( 71 ) FROM tab0 AS cor0
----
6082
6372
6852

query I rowsort
SELECT + + cor0.col0 * ( cor0.col0 ) + - col1 AS col0 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT ALL + col1 + ( col1 ) * col2 * cor0.col0 AS col0 FROM tab1 cor0
----
36490
4238
99853

query I rowsort
SELECT - col0 * + col2 * col0 AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT + cor0.col1 + 53 AS col0 FROM tab0 AS cor0
----
139
144
150

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9097
SELECT ALL - col2 + - CAST( NULL AS DECIMAL ) * col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9097
SELECT ALL - col2 + - CAST ( NULL AS REAL ) * col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9098
SELECT ALL + col2 * - CAST( + col0 * col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

skipif mysql # not compatible
query I rowsort label-9098
SELECT ALL + col2 * - CAST ( + col0 * col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT col0 + 64 FROM tab2 AS cor0
----
142
143
71

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - col0 * 17 FROM tab2 AS cor0
----
-119
-1326
-1343

query I rowsort
SELECT DISTINCT + - col2 * ( 72 ) FROM tab1 AS cor0
----
-3888
-4104
-6912

query I rowsort
SELECT ALL - + col0 * - col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT col1 * + 34 AS col0 FROM tab2 AS cor0
----
1054
2006
578

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9105
SELECT + CAST( cor0.col2 AS SIGNED ) col0 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9105
SELECT + CAST ( cor0.col2 AS INTEGER ) col0 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9106
SELECT ALL + + CAST( + 59 AS SIGNED ) FROM tab1 AS cor0
----
59
59
59

skipif mysql # not compatible
query I rowsort label-9106
SELECT ALL + + CAST ( + 59 AS INTEGER ) FROM tab1 AS cor0
----
59
59
59

query I rowsort
SELECT 55 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + ( col0 ) + col0 * col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT - 28 AS col2 FROM tab1, tab0 AS cor0
----
-28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9110
SELECT - CAST( 37 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-37
-37
-37

skipif mysql # not compatible
query I rowsort label-9110
SELECT - CAST ( 37 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-37
-37
-37

query I rowsort
SELECT + 72 + + col1 AS col0 FROM tab1 AS cor0
----
82
85
98

query I rowsort
SELECT - col0 * - 12 FROM tab1 AS cor0
----
36
768
960

query I rowsort
SELECT DISTINCT - - 95 FROM tab1 AS cor0
----
95

query I rowsort
SELECT - col0 + - ( cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL 61 AS col1 FROM tab1, tab2, tab0 AS cor0, tab1 AS cor1
----
81 values hashing to 9b52d3939da22c8931e3d5a72ddfb1b1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9116
SELECT + CAST( + col0 AS SIGNED ) * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-9116
SELECT + CAST ( + col0 AS INTEGER ) * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + - ( - 89 ) * + cor0.col0 AS col1 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT ALL - - 8 * col0 AS col0 FROM tab1 AS cor0
----
24
512
640

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab2 cor1
----
243 values hashing to ce53c0e8839c969b0513568da6eb2c4b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9120
SELECT - - col1 * col1 + - 94 DIV - col1 FROM tab0 cor0
----
7397
8282
9409

skipif mysql # not compatible
query I rowsort label-9120
SELECT - - col1 * col1 + - 94 / - col1 FROM tab0 cor0
----
7397
8282
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9121
SELECT col2 + + col0 / - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9121
SELECT col2 + + col0 / - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 93 + 67 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 1 + - 69 col1 FROM tab0, tab0 AS cor0
----
-68

query I rowsort
SELECT 62 FROM tab0, tab2 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT - col1 + + col2 * + col2 * col2 FROM tab0 AS cor0
----
-96
35851
551277

query I rowsort
SELECT ALL 7 + 2 * cor0.col2 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 4acb3a976b46516283f885434e50584a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 60 * - tab0.col1 col0 FROM tab0
----
123840
203700
485940

query I rowsort
SELECT col1 + col2 * 7 AS col1 FROM tab1
----
404
409
685

query I rowsort
SELECT ALL - 63 + col1 FROM tab2
----
-32
-4
-46

query I rowsort
SELECT ALL col0 * col1 + ( - col0 ) * - col1 AS col2 FROM tab1
----
1280
156
2080

query I rowsort
SELECT + col2 * - col0 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + - cor0.col2 * col0 + col1 AS col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT - cor0.col0 * col1 * - cor0.col1 + 88 FROM tab2 AS cor0
----
22919
271606
6815

query I rowsort
SELECT DISTINCT cor0.col0 * - col0 * - col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT + cor0.col1 * cor0.col0 AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + ( 8 ) + col0 FROM tab1 AS cor0
----
11
72
88

query I rowsort
SELECT col0 + 69 AS col0 FROM tab0
----
104
158
93

query I rowsort
SELECT - + 79 * col0 + col2 * - col0 * 99 + - col2 AS col2 FROM tab2 AS cor0
----
-19291
-206960
-303477

query I rowsort
SELECT - - ( + col2 ) + col2 + + col0 AS col2 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT DISTINCT - col0 * + col2 * col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + 35 + 55 FROM tab2 AS cor0
----
90

query I rowsort
SELECT + - col1 + + 50 FROM tab0 cor0
----
-36
-41
-47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9143
SELECT - + CAST( NULL AS SIGNED ) + cor0.col1 - col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9143
SELECT - + CAST ( NULL AS INTEGER ) + cor0.col1 - col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * col0 * + col0 AS col1 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT + col0 + ( - col2 ) + col0 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT - + 30 + cor0.col2 AS col2 FROM tab1 AS cor0
----
24
27
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-9147
SELECT - - col2 + col1 DIV + cor0.col0 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-9147
SELECT - - col2 + col1 / + cor0.col0 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT ALL - - 71 AS col2 FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT ALL 62 * + 42 FROM tab2
----
2604
2604
2604

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * + col2 * col0 + + cor0.col2 col2 FROM tab1 AS cor0
----
-207879
-737184
-8694

query I rowsort
SELECT DISTINCT - + cor0.col1 * + cor0.col0 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 47 col2 FROM tab1 AS cor0
----
47
47
47

query I rowsort
SELECT + 92 AS col0 FROM tab2 AS cor0
----
92
92
92

query I rowsort
SELECT ALL cor0.col0 * + col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9155
SELECT col2 + col2 DIV + col0 FROM tab0 cor0
----
1
34
82

skipif mysql # not compatible
query I rowsort label-9155
SELECT col2 + col2 / + col0 FROM tab0 cor0
----
1
34
82

query I rowsort
SELECT ALL + - 40 AS col2 FROM tab2 AS cor0
----
-40
-40
-40

query I rowsort
SELECT DISTINCT 93 AS col0 FROM tab2 AS cor0
----
93

query I rowsort
SELECT + - col0 + + col0 + ( col2 + col1 * ( - col2 ) ) FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL + tab1.col2 * + col2 AS col0 FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-9160
SELECT + ( + col2 ) DIV col0 + 27 * 31 - tab0.col0 FROM tab0
----
748
802
814

skipif mysql # not compatible
query I rowsort label-9160
SELECT + ( + col2 ) / col0 + 27 * 31 - tab0.col0 FROM tab0
----
748
802
814

query I rowsort
SELECT + 36 * - col1 FROM tab0
----
-3096
-3276
-3492

query I rowsort
SELECT ALL + col2 * col2 + - col2 AS col0 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL - + 68 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-37
-51
-9

query I rowsort
SELECT 38 + cor0.col2 * + cor1.col1 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 61c50c30354aca846bc40155f9f96389

query I rowsort
SELECT col2 + cor0.col0 AS col1 FROM tab2 cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9166
SELECT + 44 + - col0 DIV col0 - - ( ( + col2 ) ) FROM tab2
----
69
70
81

skipif mysql # not compatible
query I rowsort label-9166
SELECT + 44 + - col0 / col0 - - ( ( + col2 ) ) FROM tab2
----
69
70
81

query I rowsort
SELECT DISTINCT tab2.col2 - + col2 FROM tab2
----
0

query I rowsort
SELECT + - col0 - + col1 AS col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - col0 * col1 + col1 * ( - col2 ) AS col0 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT - col2 * - tab2.col1 + col0 * col2 FROM tab2
----
1026
3562
3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-9171
SELECT - col0 DIV ( col0 ) + col0 FROM tab0 cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-9171
SELECT - col0 / ( col0 ) + col0 FROM tab0 cor0
----
23
34
88

query I rowsort
SELECT + 18 * - col1 FROM tab0
----
-1548
-1638
-1746

query I rowsort
SELECT + col0 * col0 + ( 97 ) + + col1 AS col0 FROM tab2
----
177
6240
6355

query I rowsort
SELECT tab0.col1 + - 14 FROM tab0
----
72
77
83

query I rowsort
SELECT col0 + - 25 FROM tab1
----
-22
39
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9176
SELECT ALL + - 3 + col1 DIV - col2 - - 4 FROM tab0 AS cor0
----
-1
-96
0

skipif mysql # not compatible
query I rowsort label-9176
SELECT ALL + - 3 + col1 / - col2 - - 4 FROM tab0 AS cor0
----
-1
-96
0

query I rowsort
SELECT DISTINCT - cor0.col0 + ( + col1 ) + cor0.col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - col0 * cor0.col1 + - col1 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col2 * col1 + col2 * 40 AS col1 FROM tab0 AS cor0
----
-3355
-660838
-66792

query I rowsort
SELECT ALL - + col0 - - col1 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + col2 * ( ( tab2.col1 ) ) FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL + ( - ( col1 ) ) + - col1 AS col1 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT - col0 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + - col2 + + col1 AS col0 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT 93 * col0 * - col2 + col2 FROM tab2 AS cor0
----
-17550
-188578
-279148

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 38 col0 FROM tab1 AS cor0
----
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col1 ) * - col0 + + col2 col0 FROM tab0 AS cor0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * col2 + col2 * - col1 * col0 col0 FROM tab0 AS cor0
----
-3298
-65274
-656656

onlyif mysql # use DIV operator for integer division
query I rowsort label-9189
SELECT + + col1 * 4 DIV col0 AS col1 FROM tab1 AS cor0
----
0
0
34

skipif mysql # not compatible
query I rowsort label-9189
SELECT + + col1 * 4 / col0 AS col1 FROM tab1 AS cor0
----
0
0
34

query I rowsort
SELECT - - col1 * col0 * col0 AS col1 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL + col2 * + ( 20 ) AS col0 FROM tab0
----
1640
20
660

onlyif mysql # use DIV operator for integer division
query I rowsort label-9192
SELECT + col0 DIV - 49 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9192
SELECT + col0 / - 49 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL + tab0.col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT tab2.col1 * + col0 + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL - ( + col0 ) + col2 * + 44 FROM tab1
----
2373
2444
4144

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9196
SELECT ALL + + CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9196
SELECT ALL + + CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL 16 + ( col1 ) * + col1 + + cor0.col2 FROM tab1 AS cor0
----
173
281
746

query I rowsort
SELECT DISTINCT - 69 AS col2 FROM tab0
----
-69

query I rowsort
SELECT DISTINCT - - col1 + - col0 * + ( col1 ) FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT - col0 * col1 + + col0 * + col1 AS col2 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col2 col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - - 55 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
55

query I rowsort
SELECT ALL + col0 + col0 - ( col2 ) AS col0 FROM tab1 AS cor0
----
-48
64
71

query I rowsort
SELECT + 68 + col1 FROM tab1 AS cor0
----
78
81
94

query I rowsort
SELECT DISTINCT - tab2.col1 * col2 * col1 AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT 86 * col2 AS col2 FROM tab1
----
4644
4902
8256

query I rowsort
SELECT + 6 + col2 AS col0 FROM tab0 AS cor0
----
39
7
88

query I rowsort
SELECT ALL col1 + tab1.col0 + + col2 AS col0 FROM tab1
----
131
189
83

query I rowsort
SELECT DISTINCT + tab0.col1 + - col2 * col1 AS col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT + col2 + ( col1 ) * col0 AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - col1 * 81 + - col0 AS col1 FROM tab1 AS cor0
----
-1133
-2109
-874

query I rowsort
SELECT cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL tab1.col1 * - col1 + + tab1.col0 AS col2 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT DISTINCT - cor0.col1 + ( - ( col1 ) ) AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL - col2 + + col0 - - col1 * cor0.col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
183
40967
83184

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + col2 * cor0.col2 col0 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT + col0 + ( - col2 * cor0.col1 ) + col1 FROM tab0 AS cor0
----
-2728
-7282
35

query I rowsort
SELECT ALL + col2 - col0 * + col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL col2 * + 8 + 58 AS col0 FROM tab2 AS cor0
----
266
274
362

query I rowsort
SELECT ALL - col1 * 8 FROM tab2 cor0
----
-136
-248
-472

query I rowsort
SELECT DISTINCT - col2 * - 25 AS col1 FROM tab0 AS cor0
----
2050
25
825

query I rowsort
SELECT + - cor0.col0 * + col1 + + col0 * col2 FROM tab2 AS cor0
----
-2574
-28
1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-9223
SELECT DISTINCT + col0 * col2 + col0 DIV - col2 FROM tab0 AS cor0
----
0
7297
792

skipif mysql # not compatible
query I rowsort label-9223
SELECT DISTINCT + col0 * col2 + col0 / - col2 FROM tab0 AS cor0
----
0
7297
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col0 ) - - col0 col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9225
SELECT + col1 DIV col1 AS col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9225
SELECT + col1 / col1 AS col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL tab2.col1 * ( + col2 ) - col2 FROM tab2
----
1508
608
810

query I rowsort
SELECT + - ( + 31 ) FROM tab2 AS cor0
----
-31
-31
-31

query I rowsort
SELECT - - col2 * 81 AS col2 FROM tab0 AS cor0
----
2673
6642
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9229
SELECT + col1 DIV 63 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9229
SELECT + col1 / 63 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + col0 + col0 * + 94 + col1 * + col2 AS col0 FROM tab0 AS cor0
----
15917
3422
5118

query I rowsort
SELECT ALL + col2 * col2 + + ( + col1 ) * col2 AS col0 FROM tab0 AS cor0
----
14186
3927
98

query I rowsort
SELECT - col2 * col1 + col1 * col0 * col0 FROM tab0 AS cor0
----
118728
46698
713349

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9233
SELECT ALL CAST( NULL AS SIGNED ) / col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9233
SELECT ALL CAST ( NULL AS INTEGER ) / col0 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * col0 + - cor0.col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT - + ( cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + 11 + col0 AS col2 FROM tab2 AS cor0
----
18
89
90

query I rowsort
SELECT - + 61 + 30 AS col1 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT DISTINCT col1 * - col2 * col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL + col1 * - 33 + - col0 FROM tab1 AS cor0
----
-394
-509
-861

query I rowsort
SELECT DISTINCT - + col1 - + col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - col0 * + col1 + + col1 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 49 + + cor0.col2 col2 FROM tab2 cor0
----
370
3848
3909

onlyif mysql # use DIV operator for integer division
query I rowsort label-9243
SELECT - 99 DIV 16 + col1 FROM tab2 AS cor0
----
11
25
53

skipif mysql # not compatible
query I rowsort label-9243
SELECT - 99 / 16 + col1 FROM tab2 AS cor0
----
11
25
53

query I rowsort
SELECT ALL col2 * - ( col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col2 + - col0 * col1 * col2 FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT ALL + col0 - 12 FROM tab2
----
-5
66
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9247
SELECT ALL col1 - CAST( + col0 AS SIGNED ) FROM tab1
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-9247
SELECT ALL col1 - CAST ( + col0 AS INTEGER ) FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL col1 * col2 + col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT 89 FROM tab2, tab2 AS cor0
----
89

query I rowsort
SELECT col2 * ( col1 ) + col1 * col1 FROM tab2
----
1798
5015
935

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 + - col0 col0 FROM tab1 AS cor0
----
-16
0
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + ( col1 ) ) * + col2 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col0 + + 83 AS col2 FROM tab1
----
147
163
86

query I rowsort
SELECT ALL - + tab2.col0 FROM tab2, tab2 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to adaea38eae032c1639715f21831dd376

onlyif mysql # use DIV operator for integer division
query I rowsort label-9255
SELECT + ( - col2 ) DIV - col1 + 14 AS col1 FROM tab0 AS cor0
----
14
14
14

skipif mysql # not compatible
query I rowsort label-9255
SELECT + ( - col2 ) / - col1 + 14 AS col1 FROM tab0 AS cor0
----
14
14
14

query I rowsort
SELECT ALL + cor0.col2 * col2 * - col1 + + col1 AS col0 FROM tab2 AS cor0
----
-22568
-24531
-39825

query I rowsort
SELECT DISTINCT - 39 - - cor0.col1 * + col1 FROM tab2 AS cor0
----
250
3442
922

query I rowsort
SELECT col0 * - col0 + - col0 FROM tab1
----
-12
-4160
-6480

query I rowsort
SELECT - + 2 * - col2 AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT cor0.col0 + + cor0.col0 * + col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT col1 + ( tab1.col1 ) AS col0 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT col1 + + ( 40 + + col0 ) * - col2 AS col0 FROM tab0 AS cor0
----
-10487
-2026
22

skipif mysql # not compatible
query I rowsort
SELECT + col2 * CAST ( col1 AS REAL ) + - col0 AS col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT ALL - col1 * + 46 AS col1 FROM tab1 AS cor0
----
-1196
-460
-598

query I rowsort
SELECT ALL + col0 + 74 * + 61 FROM tab1 AS cor0
----
4517
4578
4594

query I rowsort
SELECT - - col1 * + col2 - col2 AS col0 FROM tab1 cor0
----
1152
1350
513

query I rowsort
SELECT + col1 * col2 + col2 AS col0 FROM tab2
----
1560
684
864

query I rowsort
SELECT ALL - - col1 * col1 + 88 FROM tab0 AS cor0
----
7484
8369
9497

query I rowsort
SELECT ALL col0 - - 22 AS col1 FROM tab0 AS cor0
----
111
46
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * ( - ( - col0 ) ) col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + + col0 * col1 * col1 + col1 FROM tab1 AS cor0
----
13533
2054
6410

query I rowsort
SELECT - - cor0.col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9274
SELECT ALL CAST( NULL AS SIGNED ) * 39 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9274
SELECT ALL CAST ( NULL AS INTEGER ) * 39 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT ALL ( - 87 ) * col2 FROM tab1 AS cor0
----
-4698
-4959
-8352

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 61 * + cor0.col2 + col0 col1 FROM tab1 AS cor0
----
3297
3541
5936

query I rowsort
SELECT + + col0 + - 35 * - col2 FROM tab1 AS cor0
----
1893
2059
3440

query I rowsort
SELECT DISTINCT + + 42 * col1 + col1 + col2 AS col0 FROM tab0 AS cor0
----
3731
3995
4172

query I rowsort
SELECT DISTINCT - col0 - col2 AS col0 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT col2 * 28 + col2 + col0 AS col1 FROM tab2
----
1181
790
832

query I rowsort
SELECT - ( 11 ) - - col1 AS col2 FROM tab0 AS cor0
----
75
80
86

query I rowsort
SELECT ALL + col2 * + col1 + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT 9 * col0 AS col1 FROM tab2 AS cor0
----
63
702
711

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 78 col0 FROM tab0 AS cor0
----
78
78
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9285
SELECT DISTINCT cor0.col0 * - CAST( NULL AS SIGNED ) col2 FROM tab0, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9285
SELECT DISTINCT cor0.col0 * - CAST ( NULL AS INTEGER ) col2 FROM tab0, tab1 AS cor0
----
NULL

query I rowsort
SELECT - - cor0.col1 + col2 * + cor0.col0 * + col1 FROM tab0 AS cor0
----
3492
664209
68198

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9287
SELECT DISTINCT - col1 + col1 / CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9287
SELECT DISTINCT - col1 + col1 / CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - - col1 * - col1 + 60 FROM tab2 AS cor0
----
-229
-3421
-901

query I rowsort
SELECT col0 * - col2 - + ( + col2 ) AS col0 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT tab2.col2 + col2 * - ( col1 ) FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT ALL - 84 * col1 FROM tab1
----
-1092
-2184
-840

query I rowsort
SELECT - + cor0.col0 + - 32 * cor0.col1 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
147186
42897
6937

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * ( + col2 ) * - col1 col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-9294
SELECT DISTINCT 15 DIV col0 FROM tab1
----
0
5

skipif mysql # not compatible
query I rowsort label-9294
SELECT DISTINCT 15 / col0 FROM tab1
----
0
5

query I rowsort
SELECT ALL + 20 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

onlyif mysql # use DIV operator for integer division
query I rowsort label-9296
SELECT + col1 DIV col0 + cor0.col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-9296
SELECT + col1 / col0 + cor0.col0 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT tab1.col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - 56 * cor0.col1 * ( - col2 ) AS col0 FROM tab1 cor0
----
31920
69888
78624

onlyif mysql # use DIV operator for integer division
query I rowsort label-9299
SELECT DISTINCT cor0.col1 DIV + 89 FROM tab1, tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-9299
SELECT DISTINCT cor0.col1 / + 89 FROM tab1, tab1 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col0 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + col0 * col0 * - col0 AS col2 FROM tab1
----
-262144
-27
-512000

query I rowsort
SELECT + col1 * + col2 + col1 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-9303
SELECT - - col1 + + cor0.col2 DIV col2 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-9303
SELECT - - col1 + + cor0.col2 / col2 FROM tab0 AS cor0
----
87
92
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9304
SELECT col0 * CAST( col2 AS SIGNED ) AS col2 FROM tab2 cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-9304
SELECT col0 * CAST ( col2 AS INTEGER ) AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col0 * - ( col0 * cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-9306
SELECT + col0 DIV - 5 AS col2 FROM tab0 AS cor0
----
-17
-4
-7

skipif mysql # not compatible
query I rowsort label-9306
SELECT + col0 / - 5 AS col2 FROM tab0 AS cor0
----
-17
-4
-7

query I rowsort
SELECT - cor0.col2 + col1 * + col2 * + col2 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT 66 * - tab2.col2 FROM tab2
----
-1716
-1782
-2508

query I rowsort
SELECT + col1 * col2 + tab0.col1 FROM tab0 WHERE col1 - tab0.col1 NOT BETWEEN - col0 AND NULL
----

query I rowsort
SELECT ALL col2 + col1 + tab2.col0 * - tab2.col1 * + tab2.col1 AS col1 FROM tab2
----
-22776
-271433
-6669

onlyif mysql # use DIV operator for integer division
query I rowsort label-9311
SELECT + col2 DIV col0 + - col0 + col0 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-9311
SELECT + col2 / col0 + - col0 + col0 FROM tab2
----
0
0
3

query I rowsort
SELECT col0 * + col1 + col2 * - col0 + col2 FROM tab0
----
1305
3361
883

query I rowsort
SELECT DISTINCT col2 + + col1 + + col0 * - col2 FROM tab0
----
-673
-7125
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 + + col2 col1 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT col2 * col0 + + col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT - col1 * col2 + - col1 FROM tab1 WHERE - col2 - col2 NOT IN ( col0 + tab1.col2 )
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT col1 + col2 + col1 FROM tab2
----
144
72
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9318
SELECT ALL tab1.col2 DIV - col2 col0 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9318
SELECT ALL tab1.col2 / - col2 col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT + col0 + col0 - col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT tab2.col2 * + tab2.col1 + + tab2.col0 * - col0 FROM tab2
----
-4550
-5595
788

query I rowsort
SELECT DISTINCT col0 AS col0 FROM tab0 WHERE NOT ( col1 ) <> + col2
----

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) BETWEEN col0 AND + col2 * col0
----

query I rowsort
SELECT ALL - tab0.col2 + tab0.col1 AS col2 FROM tab0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 * col2 col2 FROM tab0
----
1
35937
551368

query I rowsort
SELECT + tab2.col2 * tab2.col0 + col0 FROM tab2
----
196
2106
3081

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col1 + - col1 * col2 * col2 <> ( NULL )
----

query I rowsort
SELECT + col1 * - col0 * + tab2.col0 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT + col1 + col2 * - col1 * col0 FROM tab2
----
-119593
-51017
-5828

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL = - col0
----

query I rowsort
SELECT ALL + col1 * col0 * + col1 AS col1 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT + col0 * + col0 FROM tab2 WHERE NOT ( NULL ) <> NULL
----

query III rowsort
SELECT * FROM tab2 WHERE + col1 / col0 IN ( - col2 )
----

query I rowsort
SELECT + tab1.col1 FROM tab1 WHERE ( NULL ) > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9334
SELECT 52 DIV + col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9334
SELECT 52 / + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - col1 - + col1 * col0 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL + - col0 * - col2 - col2 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + col0 * + cor0.col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT 45 + - cor0.col0 FROM tab1 cor0
----
-19
-35
42

query I rowsort
SELECT DISTINCT + ( 61 ) AS col2 FROM tab1
----
61

query I rowsort
SELECT DISTINCT - 96 * + col1 AS col1 FROM tab0 AS cor0
----
-8256
-8736
-9312

query I rowsort
SELECT ALL - 97 * col0 AS col2 FROM tab0 AS cor0
----
-2328
-3395
-8633

query I rowsort
SELECT - cor0.col2 - col2 * + ( + col1 ) FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - col2 * col0 + 63 AS col0 FROM tab0 AS cor0
----
-7235
-729
28

query I rowsort
SELECT ALL - col1 * + 25 FROM tab0
----
-2150
-2275
-2425

query I rowsort
SELECT 73 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT + col2 * 8 + + 4 AS col2 FROM tab0 AS cor0
----
12
268
660

query I rowsort
SELECT - cor0.col0 + + ( + col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + cor1.col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT - cor0.col2 + 27 AS col2 FROM tab0 AS cor0
----
-55
-6
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9350
SELECT ALL - col1 + col1 * col0 DIV ( + col2 ) AS col0 FROM tab0 AS cor0
----
-24
3298
7

skipif mysql # not compatible
query I rowsort label-9350
SELECT ALL - col1 + col1 * col0 / ( + col2 ) AS col0 FROM tab0 AS cor0
----
-24
3298
7

query I rowsort
SELECT DISTINCT - col1 * + col2 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + - col2 * col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - ( col0 ) * col1 - + col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL 9 + col0 FROM tab1 AS cor0
----
12
73
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9355
SELECT col0 * + col0 + col1 * - col2 + col2 DIV col2 AS col2 FROM tab0 AS cor0
----
-2261
1129
460

skipif mysql # not compatible
query I rowsort label-9355
SELECT col0 * + col0 + col1 * - col2 + col2 / col2 AS col2 FROM tab0 AS cor0
----
-2261
1129
460

query I rowsort
SELECT cor0.col0 * - col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - 35 + - col1 AS col2 FROM tab2 AS cor0
----
-52
-66
-94

query I rowsort
SELECT ALL + + 26 * + cor0.col1 FROM tab2 AS cor0
----
1534
442
806

query I rowsort
SELECT DISTINCT - 91 + - col0 + + col2 FROM tab0 AS cor0
----
-125
-82
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9360
SELECT + + 53 DIV col1 AS col1 FROM tab2 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-9360
SELECT + + 53 / col1 AS col1 FROM tab2 AS cor0
----
0
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 3 * + col0 col2 FROM tab1 AS cor0
----
192
240
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9362
SELECT DISTINCT - - cor0.col2 + + col1 DIV col1 FROM tab1 cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-9362
SELECT DISTINCT - - cor0.col2 + + col1 / col1 FROM tab1 cor0
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * col0 col1 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-9364
SELECT DISTINCT - 42 + - col2 - - col0 DIV col1 AS col0 FROM tab0
----
-124
-43
-75

skipif mysql # not compatible
query I rowsort label-9364
SELECT DISTINCT - 42 + - col2 - - col0 / col1 AS col0 FROM tab0
----
-124
-43
-75

query I rowsort
SELECT - 96 + col2 * col1 - - col1 AS col1 FROM tab2
----
1497
567
772

query I rowsort
SELECT + col1 + col0 * col1 AS col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL + - col1 * + col2 + + col0 * - col2 AS col2 FROM tab0 AS cor0
----
-132
-14760
-3630

query I rowsort
SELECT DISTINCT - - col0 + 14 AS col2 FROM tab1 AS cor0
----
17
78
94

query I rowsort
SELECT DISTINCT - 3 * col2 AS col1 FROM tab2 AS cor0
----
-114
-78
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9370
SELECT ALL cor0.col1 + 66 DIV col2 AS col2 FROM tab1 AS cor0
----
11
13
27

skipif mysql # not compatible
query I rowsort label-9370
SELECT ALL cor0.col1 + 66 / col2 AS col2 FROM tab1 AS cor0
----
11
13
27

query I rowsort
SELECT cor0.col1 * - cor0.col1 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 0456bcedc217ad4d7d255310d4eb4931

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 84 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT DISTINCT 43 AS col0 FROM tab2
----
43

query I rowsort
SELECT DISTINCT ( - 21 * col1 ) AS col2 FROM tab0
----
-1806
-1911
-2037

query I rowsort
SELECT ALL cor0.col2 + col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + ( - ( col1 ) ) FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9377
SELECT col1 * - col1 + + col1 DIV col1 AS col2 FROM tab2
----
-288
-3480
-960

skipif mysql # not compatible
query I rowsort label-9377
SELECT col1 * - col1 + + col1 / col1 AS col2 FROM tab2
----
-288
-3480
-960

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL <> ( col1 * col2 )
----

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT NULL IN ( - col2 )
----

query I rowsort
SELECT - col2 - - tab2.col0 * + col0 AS col1 FROM tab2
----
22
6058
6203

query I rowsort
SELECT DISTINCT - col2 * col1 + + col1 * col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + col1 - - col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL cor0.col2 * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - col2 + col1 * cor0.col1 FROM tab2 cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT + cor0.col0 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT + col0 - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col2 <= NULL
----

query I rowsort
SELECT DISTINCT col1 * col0 + + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT - col1 + col1 / col1 + cor0.col2 AS col0 FROM tab1 cor0 WHERE NULL NOT BETWEEN ( + col0 * + col0 ) AND ( col0 + col0 / col2 )
----

query I rowsort
SELECT col0 FROM tab2 cor0 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NULL = + col1
----

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE + col2 NOT BETWEEN NULL AND ( col1 )
----
79
17
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-9393
SELECT ALL col0 DIV + col0 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9393
SELECT ALL col0 / + col0 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT tab0.col1 * + tab0.col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + tab2.col2 * + col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col1 + col1 * - col2 + - col2 FROM tab1 AS cor0
----
-1331
-1432
-617

query I rowsort
SELECT DISTINCT - col2 * col1 * col2 AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT + tab0.col2 + + col0 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - + col1 * col2 + - col1 AS col1 FROM tab2 cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT + col1 * col1 + col1 * col2 FROM tab0 AS cor0
----
10234
15743
9506

query I rowsort
SELECT - col2 * cor0.col1 * - col1 + col2 FROM tab1 AS cor0
----
16320
36558
5757

onlyif mysql # use DIV operator for integer division
query I rowsort label-9402
SELECT - col0 * + col1 + col2 DIV col2 FROM tab0 AS cor0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-9402
SELECT - col0 * + col1 + col2 / col2 FROM tab0 AS cor0
----
-2063
-3394
-8098

onlyif mysql # use DIV operator for integer division
query I rowsort label-9403
SELECT ALL cor0.col0 DIV + col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9403
SELECT ALL cor0.col0 / + col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col1 * col0 + col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT cor0.col2 + + col2 * col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + col1 * - cor0.col0 + - col0 AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL - cor0.col2 + + col1 * col1 FROM tab0 cor0
----
7363
8199
9408

query I rowsort
SELECT - col0 + + col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT col2 * col0 * + col0 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT col1 + - col0 * - col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col1 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT col1 + - tab0.col0 AS col0 FROM tab0
----
2
62

query I rowsort
SELECT DISTINCT col2 * - col0 + col2 * col2 * - col1 + col2 AS col1 FROM tab1
----
-127392
-36081
-75924

query I rowsort
SELECT col0 - col2 * - col2 * col0 AS col1 FROM tab0
----
26160
598525
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + tab0.col1 * col1 + - col1 col1 FROM tab0
----
7334
8279
9347

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col1 col0 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL 23 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT - col2 + - 53 FROM tab2 AS cor0
----
-79
-80
-91

query I rowsort
SELECT + col0 - ( cor0.col1 ) FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT 81 FROM tab0, tab1 cor0
----
81

query I rowsort
SELECT col1 * - 85 FROM tab0
----
-7310
-7735
-8245

query I rowsort
SELECT 47 + + 10 AS col0 FROM tab2 AS cor0
----
57
57
57

query I rowsort
SELECT ALL - col2 + + col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - 58 + ( - col2 + + col0 ) FROM tab1
----
-109
-51
-74

query I rowsort
SELECT - 81 + cor0.col1 AS col1 FROM tab1 AS cor0
----
-55
-68
-71

query I rowsort
SELECT + 78 * ( - col1 ) * - ( - 18 ) + col1 AS col2 FROM tab1 AS cor0
----
-14030
-18239
-36478

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - 41 col0 FROM tab1 AS cor0
----
13
16
55

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) * cor0.col0 * col1 - - col0 AS col2 FROM tab2 AS cor0
----
-22752
-271440
-6720

query I rowsort
SELECT + - 20 * + 76 + col2 * 56 AS col1 FROM tab1 cor0
----
1504
1672
3856

query I rowsort
SELECT + ( col0 ) * col1 - - col0 AS col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + - col2 + - 91 AS col2 FROM tab1 AS cor0
----
-145
-148
-187

query I rowsort
SELECT DISTINCT 34 AS col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
34

query I rowsort
SELECT + 57 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9434
SELECT + + cor0.col1 + col2 DIV 65 col2 FROM tab0 AS cor0
----
86
92
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9434
SELECT + + cor0.col1 + col2 / 65 col2 FROM tab0 AS cor0
----
86
92
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - col0 ) col1 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col0 col1 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT - col1 * - 3 + col1 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT col0 * - col0 - + col2 * col0 FROM tab1 cor0
----
-14080
-171
-7744

query I rowsort
SELECT - col2 + - ( + ( col2 ) ) AS col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL 29 * col1 FROM tab0
----
2494
2639
2813

onlyif mysql # use DIV operator for integer division
query I rowsort label-9441
SELECT + + col1 + - col1 DIV - 79 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9441
SELECT + + col1 + - col1 / - 79 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col2 + - 34 AS col0 FROM tab0 AS cor0
----
-1
-33
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-9443
SELECT DISTINCT - col2 DIV CAST( + 20 AS SIGNED ) col2 FROM tab0 AS cor0
----
-1
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9443
SELECT DISTINCT - col2 / CAST ( + 20 AS INTEGER ) col2 FROM tab0 AS cor0
----
-1
-4
0

query I rowsort
SELECT + col0 * + col1 + + 34 FROM tab0 AS cor0
----
2098
3429
8133

query I rowsort
SELECT 75 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

onlyif mysql # use DIV operator for integer division
query I rowsort label-9446
SELECT - col1 DIV + 62 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9446
SELECT - col1 / + 62 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 * col1 * + 63 AS col2 FROM tab0
----
130032
213885
510237

query I rowsort
SELECT ALL - cor0.col1 * - col0 * col0 AS col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT + cor0.col1 + + 88 * - col2 FROM tab0 cor0
----
-2818
-7125
9

query I rowsort
SELECT - 79 * + col2 - - col2 AS col2 FROM tab2 AS cor0
----
-2028
-2106
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-9451
SELECT ALL - + col2 DIV + cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9451
SELECT ALL - + col2 / + cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9452
SELECT CAST( col2 AS SIGNED ) + - col1 * - col1 AS col2 FROM tab2 cor0
----
327
3507
988

skipif mysql # not compatible
query I rowsort label-9452
SELECT CAST ( col2 AS INTEGER ) + - col1 * - col1 AS col2 FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT - 45 * ( col2 ) - + col1 * 47 FROM tab0 AS cor0
----
-4604
-5527
-7967

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9454
SELECT DISTINCT CAST( NULL AS SIGNED ) * cor0.col2 AS col2 FROM tab1, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9454
SELECT DISTINCT CAST ( NULL AS INTEGER ) * cor0.col2 AS col2 FROM tab1, tab2 AS cor0
----
NULL

query I rowsort
SELECT + col2 - + col0 * ( - tab1.col1 ) FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL - - 87 AS col1 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT + col2 + col1 * - cor0.col0 * + col0 FROM tab2 AS cor0
----
-106059
-1492
-358930

query I rowsort
SELECT ALL + col1 * - col2 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9459
SELECT - 37 + - col1 + + CAST( - 8 AS SIGNED ) * - col1 AS col0 FROM tab0 AS cor0
----
565
600
642

skipif mysql # not compatible
query I rowsort label-9459
SELECT - 37 + - col1 + + CAST ( - 8 AS INTEGER ) * - col1 AS col0 FROM tab0 AS cor0
----
565
600
642

query I rowsort
SELECT DISTINCT - col0 * col0 + + col0 + 94 FROM tab1 AS cor0
----
-3938
-6226
88

query I rowsort
SELECT ALL 78 * col2 + 59 * + 85 FROM tab2 AS cor0
----
7043
7121
7979

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + cor0.col2 col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + 3 AS col1 FROM tab2
----
3

query I rowsort
SELECT - ( - col1 ) * col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL - 1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT DISTINCT - 41 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-41

query I rowsort
SELECT - 49 * col0 + + col1 + col2 * - cor0.col2 FROM tab0 AS cor0
----
-10994
-1619
-2179

query I rowsort
SELECT ALL - 84 FROM tab1, tab2, tab1 AS cor0, tab1 AS cor1
----
81 values hashing to aaabc1266a1bb4f477091ffbc243c849

query I rowsort
SELECT DISTINCT 67 * - 55 FROM tab0
----
-3685

query I rowsort
SELECT col2 * + col1 + col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT col1 + - col0 * + col2 * + 91 AS col1 FROM tab0
----
-3088
-664027
-71986

query I rowsort
SELECT + 2 * + 83 + - col2 * col2 AS col2 FROM tab2
----
-1278
-510
-563

query I rowsort
SELECT col2 + 48 FROM tab1
----
102
105
144

query I rowsort
SELECT 14 - - col1 AS col0 FROM tab1
----
24
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-9475
SELECT DISTINCT + - col0 * + col1 - col1 DIV col2 FROM tab0 AS cor0
----
-2066
-3492
-8100

skipif mysql # not compatible
query I rowsort label-9475
SELECT DISTINCT + - col0 * + col1 - col1 / col2 FROM tab0 AS cor0
----
-2066
-3492
-8100

query I rowsort
SELECT DISTINCT + 32 AS col0 FROM tab1
----
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( col2 ) + - col2 col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9478
SELECT ALL CAST( NULL AS SIGNED ) * - col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9478
SELECT ALL CAST ( NULL AS INTEGER ) * - col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 75 * + col2 FROM tab2 AS cor0
----
1950
2025
2850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9480
SELECT ALL + ( - col1 ) * + col0 + + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9480
SELECT ALL + ( - col1 ) * + col0 + + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 76 - - col1 FROM tab0 AS cor0
----
162
167
173

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + cor0.col0 * + ( + 85 ) - - col1 col0 FROM tab0 AS cor0
----
2093
3071
7574

query I rowsort
SELECT DISTINCT + 76 * + col1 FROM tab1 AS cor0
----
1976
760
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + cor0.col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT 35 + cor0.col2 AS col1 FROM tab1 AS cor0
----
131
89
92

query I rowsort
SELECT DISTINCT + ( col1 ) * col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT ( 96 * - col1 ) FROM tab1
----
-1248
-2496
-960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9488
SELECT CAST( ( col1 ) AS SIGNED ) FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-9488
SELECT CAST ( ( col1 ) AS INTEGER ) FROM tab1
----
10
13
26

query I rowsort
SELECT 42 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT ALL 76 + col0 AS col2 FROM tab2 AS cor0
----
154
155
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9491
SELECT cor0.col1 DIV ( col1 ) + col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-9491
SELECT cor0.col1 / ( col1 ) + col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort
SELECT + col0 * - col1 + ( col2 * CAST ( col2 AS REAL ) ) AS col2 FROM tab1 AS cor0
----
2609
2838
8176

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL col1 * - ( + 95 + col1 ) FROM tab2
----
-1904
-3906
-9086

query I rowsort
SELECT ALL + col2 * 83 + - col1 FROM tab0 AS cor0
----
-14
2653
6715

query I rowsort
SELECT DISTINCT - cor0.col1 * 70 FROM tab0 AS cor0
----
-6020
-6370
-6790

query I rowsort
SELECT DISTINCT - col2 * - 6 + - 95 * + col2 FROM tab0 cor0
----
-2937
-7298
-89

query I rowsort
SELECT ALL + col0 * col2 * 73 FROM tab2 AS cor0
----
13797
148044
219146

query I rowsort
SELECT DISTINCT + col1 + - ( + col0 + + col2 * col1 ) AS col2 FROM tab0 AS cor0
----
-2776
-35
-7460

query I rowsort
SELECT col0 * col2 + - col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-9501
SELECT + + cor0.col0 DIV - ( col2 ) FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-9501
SELECT + + cor0.col0 / - ( col2 ) FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT ALL + col0 + + cor0.col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT - col2 + 57 * - col0 FROM tab1 AS cor0
----
-225
-3705
-4656

query I rowsort
SELECT DISTINCT - ( - col0 ) + - col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT DISTINCT + - col1 * col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - cor0.col2 + 59 FROM tab1 cor0
----
-37
2
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9507
SELECT ALL ( col0 ) DIV - col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-9507
SELECT ALL ( col0 ) / - col1 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT - + col2 + cor0.col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL 42 * col1 AS col0 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT - 33 * + col0 * + col0 AS col2 FROM tab0 AS cor0
----
-19008
-261393
-40425

query I rowsort
SELECT ALL tab2.col1 * + col2 + 56 * + col0 FROM tab2
----
1229
5070
5902

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9512
SELECT + CAST( NULL AS SIGNED ) + + col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9512
SELECT + CAST ( NULL AS INTEGER ) + + col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * 86 FROM tab0 cor0
----
-2064
-3010
-7654

query I rowsort
SELECT DISTINCT - - ( + col1 ) AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9515
SELECT CAST( - cor0.col1 AS SIGNED ) + + col2 * - col1 FROM tab0 AS cor0
----
-194
-2924
-7553

skipif mysql # not compatible
query I rowsort label-9515
SELECT CAST ( - cor0.col1 AS INTEGER ) + + col2 * - col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL - - col2 * + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9517
SELECT + ( 73 ) * - cor0.col2 / + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9517
SELECT + ( 73 ) * - cor0.col2 / + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + col0 + - col0 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT cor0.col1 * 81 AS col1 FROM tab0, tab0 AS cor0
----
6966
7371
7857

query I rowsort
SELECT DISTINCT - tab0.col0 * 94 AS col2 FROM tab0, tab1 AS cor0
----
-2256
-3290
-8366

query I rowsort
SELECT - 95 + + col2 AS col2 FROM tab2 AS cor0
----
-57
-68
-69

query I rowsort
SELECT + 15 * 17 + col2 AS col0 FROM tab0 cor0
----
256
288
337

query I rowsort
SELECT - ( + col0 ) * col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT tab1.col2 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # use DIV operator for integer division
query I rowsort label-9525
SELECT + col2 * col2 * - col1 + 85 DIV - cor0.col1 FROM tab0 AS cor0
----
-611884
-93654
-97

skipif mysql # not compatible
query I rowsort label-9525
SELECT + col2 * col2 * - col1 + 85 / - cor0.col1 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT + ( tab0.col1 + col0 ) AS col1 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-9527
SELECT DISTINCT - 17 DIV col0 col2 FROM tab1
----
-5
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9527
SELECT DISTINCT - 17 / col0 col2 FROM tab1
----
-5
0

query I rowsort
SELECT 9 * col2 + - tab2.col2 + ( col0 ) * + 17 AS col1 FROM tab2
----
1534
1647
335

query I rowsort
SELECT - 20 * col2 + col1 * col2 FROM tab2
----
-114
1014
297

query I rowsort
SELECT cor0.col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - 74 AS col2 FROM tab2 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT col2 + - ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9533
SELECT DISTINCT + - col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9533
SELECT DISTINCT + - col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9534
SELECT + col0 + - col2 DIV - cor0.col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-9534
SELECT + col0 + - col2 / - cor0.col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT cor1.col1 AS col2 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL + cor0.col2 * + 96 * - col1 FROM tab1 AS cor0
----
-119808
-134784
-54720

query I rowsort
SELECT DISTINCT 88 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
88

query I rowsort
SELECT DISTINCT cor1.col1 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT DISTINCT 90 * col0 FROM tab1
----
270
5760
7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-9540
SELECT ALL - cor0.col2 DIV 97 + - cor0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

skipif mysql # not compatible
query I rowsort label-9540
SELECT ALL - cor0.col2 / 97 + - cor0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT + 28 FROM tab2, tab0 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT cor0.col1 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT 84 AS col0 FROM tab0
----
84

query I rowsort
SELECT 2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT DISTINCT 82 AS col1 FROM tab2, tab0, tab1 AS cor0, tab1 AS cor1
----
82

query I rowsort
SELECT - col0 + + 83 FROM tab1 AS cor0
----
19
3
80

query I rowsort
SELECT + col1 + 5 FROM tab0 AS cor0
----
102
91
96

query I rowsort
SELECT cor0.col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - + 36 AS col0 FROM tab2 cor0
----
-36
-36
-36

query I rowsort
SELECT + + 86 + + 86 * col0 FROM tab0 AS cor0
----
2150
3096
7740

query I rowsort
SELECT DISTINCT - tab2.col2 * col2 * + col2 AS col0 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT ( col1 ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9553
SELECT DISTINCT CAST( NULL AS DECIMAL ) + + col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-9553
SELECT DISTINCT CAST ( NULL AS REAL ) + + col0 FROM tab0
----
NULL

query I rowsort
SELECT + - col1 * + col2 + + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 85 * + cor0.col1 * cor0.col1 col0 FROM tab2 AS cor0
----
24565
295885
81685

query I rowsort
SELECT DISTINCT + 33 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
33

query I rowsort
SELECT DISTINCT 49 * 75 AS col1 FROM tab0 cor0
----
3675

query I rowsort
SELECT col0 * + 49 AS col1 FROM tab2 cor0
----
343
3822
3871

query I rowsort
SELECT + + col0 * - 14 + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1157
-312
-455

query I rowsort
SELECT DISTINCT 83 + - col1 FROM tab0 AS cor0
----
-14
-3
-8

query I rowsort
SELECT ALL - - col0 + - col0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) * 26 * cor0.col1 col1 FROM tab2 AS cor0
----
16796
21762
39884

query I rowsort
SELECT - col0 + - col1 * - 97 AS col1 FROM tab0 cor0
----
8318
8738
9374

query I rowsort
SELECT ALL col1 - + col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - - ( - cor0.col0 ) + - col2 AS col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + cor0.col0 * - col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + + col0 * - col0 * col1 AS col2 FROM tab0 AS cor0
----
-118825
-49536
-720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9568
SELECT CAST( NULL AS SIGNED ) - + col2 / - col0 col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9568
SELECT CAST ( NULL AS INTEGER ) - + col2 / - col0 col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * - 56 AS col0 FROM tab1
----
-3024
-3192
-5376

query I rowsort
SELECT ALL col0 * + col0 * col0 FROM tab1
----
262144
27
512000

query I rowsort
SELECT - + col2 + - col1 * 14 AS col2 FROM tab0 AS cor0
----
-1237
-1356
-1359

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9572
SELECT - + col0 / + CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9572
SELECT - + col0 / + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab0
----
13

query I rowsort
SELECT DISTINCT - col0 + + 39 FROM tab1 AS cor0
----
-25
-41
36

query I rowsort
SELECT ALL + + col2 * - 66 FROM tab0 AS cor0
----
-2178
-5412
-66

query I rowsort
SELECT + col2 * 99 + 31 FROM tab2 AS cor0
----
2605
2704
3793

onlyif mysql # use DIV operator for integer division
query I rowsort label-9578
SELECT ALL - - col1 - cor0.col0 DIV + col0 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-9578
SELECT ALL - - col1 - cor0.col0 / + col0 FROM tab2 AS cor0
----
16
30
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 37 * 25 col1 FROM tab2, tab0 AS cor0
----
925

query I rowsort
SELECT ALL - cor0.col1 + col0 * col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL - tab2.col2 + ( col2 ) FROM tab2
----
0
0
0

query I rowsort
SELECT + - cor0.col0 + + 40 FROM tab0 AS cor0
----
-49
16
5

query I rowsort
SELECT DISTINCT + col0 + col2 * + ( col2 ) AS col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT DISTINCT 99 + + col0 FROM tab0
----
123
134
188

query I rowsort
SELECT DISTINCT + 95 + col2 FROM tab0
----
128
177
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9586
SELECT DISTINCT col2 DIV - col1 + ( col0 ) FROM tab2
----
7
77
78

skipif mysql # not compatible
query I rowsort label-9586
SELECT DISTINCT col2 / - col1 + ( col0 ) FROM tab2
----
7
77
78

query I rowsort
SELECT ALL col2 * col0 + col1 * - col2 FROM tab2 AS cor0
----
-648
2356
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * cor0.col2 + col1 + col2 col2 FROM tab2 AS cor0
----
1499
761
787

query I rowsort
SELECT ALL col2 + tab1.col1 * ( col1 ) FROM tab1
----
157
265
730

query I rowsort
SELECT col0 * + col0 * - 81 AS col2 FROM tab2
----
-3969
-492804
-505521

query I rowsort
SELECT ALL + col2 * + col1 + col2 + - col0 AS col1 FROM tab2 AS cor0
----
1482
605
857

query I rowsort
SELECT col1 * col0 + col0 AS col0 FROM tab1
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9593
SELECT DISTINCT + col1 * + col0 + + CAST( NULL AS SIGNED ) * - col1 * col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9593
SELECT DISTINCT + col1 * + col0 + + CAST ( NULL AS INTEGER ) * - col1 * col1 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + col0 + col1 * ( + 94 ) FROM tab2
----
1677
2921
5624

query I rowsort
SELECT DISTINCT - 50 AS col2 FROM tab1, tab0, tab1 AS cor0
----
-50

query I rowsort
SELECT - col1 + col1 * col1 * tab1.col0 + col0 FROM tab1
----
13587
2005
6454

onlyif mysql # use DIV operator for integer division
query I rowsort label-9597
SELECT DISTINCT - col1 + + 92 * col2 DIV - col2 col2 FROM tab1 AS cor0
----
-102
-105
-118

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9597
SELECT DISTINCT - col1 + + 92 * col2 / - col2 col2 FROM tab1 AS cor0
----
-102
-105
-118

query I rowsort
SELECT DISTINCT col0 + - cor0.col2 * col2 AS col0 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL + col2 - + 14 * + col2 AS col2 FROM tab2 cor0
----
-338
-351
-494

query I rowsort
SELECT ALL - - col0 * - ( + col2 ) * col1 + + col2 + 1 AS col0 FROM tab1 AS cor0
----
-36422
-4157
-99743

query I rowsort
SELECT ALL cor0.col2 + ( col1 ) * col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 * + col2 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + - col1 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT ALL - col0 + - 22 * + 57 AS col0 FROM tab1 AS cor0
----
-1257
-1318
-1334

query I rowsort
SELECT - col0 * + 4 AS col0 FROM tab2 AS cor0
----
-28
-312
-316

query I rowsort
SELECT DISTINCT + - col2 + 97 AS col1 FROM tab1 AS cor0
----
1
40
43

query I rowsort
SELECT DISTINCT - col1 * cor0.col2 + - col0 AS col1 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL + col2 + ( + col2 ) AS col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - - cor0.col0 * - 89 - + 30 AS col1 FROM tab1 AS cor0
----
-297
-5726
-7150

query I rowsort
SELECT + - col0 + - 64 + - col2 FROM tab1 AS cor0
----
-121
-185
-240

query I rowsort
SELECT DISTINCT 10 FROM tab1, tab0 AS cor0
----
10

query I rowsort
SELECT - + cor0.col2 * - col0 + col1 * col2 AS col0 FROM tab0 cor0
----
132
14760
3630

query I rowsort
SELECT ALL col1 - col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * + col1 + - col1 FROM tab0 cor0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT - - col1 * - col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col0 * ( col0 ) - col2 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT + cor0.col2 + col0 * col1 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - 66 * + col1 + col1 + + 12 FROM tab0 AS cor0
----
-5578
-5903
-6293

query I rowsort
SELECT - - col2 - - col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 33 * col0 * col0 AS col2 FROM tab0 AS cor0
----
19008
261393
40425

query I rowsort
SELECT DISTINCT + 16 + col1 + col2 * col0 FROM tab1 AS cor0
----
204
3674
7709

query I rowsort
SELECT DISTINCT + + ( - col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - cor0.col0 - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT 83 - + ( col0 + - col0 * - 37 ) AS col0 FROM tab2
----
-183
-2881
-2919

query I rowsort
SELECT DISTINCT 16 * col0 + - col0 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT - + 51 + - col2 - cor0.col2 * - 91 FROM tab2 AS cor0
----
2289
2379
3369

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * - col1 col0 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9628
SELECT DISTINCT + 40 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9628
SELECT DISTINCT + 40 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT + col2 + col0 + - col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + cor0.col2 + - col1 * - col1 AS col0 FROM tab1 cor0
----
157
265
730

query I rowsort
SELECT ALL + + cor0.col1 + col1 * 90 AS col0 FROM tab0 AS cor0
----
7826
8281
8827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - cor0.col2 + - col1 - col1 col0 FROM tab2 AS cor0
----
1416
612
775

query I rowsort
SELECT col2 + - col2 - col1 AS col0 FROM tab0 cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9634
SELECT + col0 * col0 DIV - col1 + 1 * + col2 FROM tab1 AS cor0
----
-352
-396
54

skipif mysql # not compatible
query I rowsort label-9634
SELECT + col0 * col0 / - col1 + 1 * + col2 FROM tab1 AS cor0
----
-352
-396
54

query I rowsort
SELECT - + col1 + - col2 + + 36 FROM tab1 AS cor0
----
-31
-44
-73

query I rowsort
SELECT ALL + 7 * cor0.col0 + - col2 + cor0.col1 AS col0 FROM tab1 AS cor0
----
-7
401
477

query I rowsort
SELECT - 32 + + col0 + col1 AS col2 FROM tab0 AS cor0
----
100
148
78

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - + 18 FROM tab2, tab2 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col2 * - 11 col1 FROM tab2 cor0
----
304
364
497

query I rowsort
SELECT + - col1 * 98 * - col1 FROM tab2 cor0
----
28322
341138
94178

query I rowsort
SELECT - 40 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 1cb77db1fc64914b19afc3dbc620f9df

query I rowsort
SELECT ALL - ( 81 ) + col0 AS col2 FROM tab2 AS cor0
----
-2
-3
-74

query I rowsort
SELECT ALL + - 38 * - col0 + col0 AS col2 FROM tab2 AS cor0
----
273
3042
3081

query I rowsort
SELECT ALL cor1.col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT col2 * col0 * col1 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + col1 * 19 FROM tab2 AS cor0
----
1121
323
589

query I rowsort
SELECT - 53 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

query I rowsort
SELECT DISTINCT 77 AS col2 FROM tab0 cor0
----
77

query I rowsort
SELECT - col2 - - col0 * - col1 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab0 cor0 CROSS JOIN tab2, tab1 AS cor1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 + 47 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT ALL + cor0.col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL ( tab2.col0 ) + tab2.col1 * + col1 AS col2 FROM tab2
----
3559
368
968

query I rowsort
SELECT DISTINCT col2 + + col0 * + tab0.col0 AS col2 FROM tab0
----
1226
609
8003

query I rowsort
SELECT ALL + col0 + - tab1.col0 * - tab1.col2 FROM tab1
----
165
3712
7760

query I rowsort
SELECT + 21 * col2 * - col0 FROM tab0 AS cor0
----
-153258
-16632
-735

query I rowsort
SELECT DISTINCT + col2 + col2 * col1 * - col0 FROM tab1
----
-36423
-4158
-99744

onlyif mysql # use DIV operator for integer division
query I rowsort label-9659
SELECT DISTINCT - col2 DIV col2 AS col2 FROM tab0 WHERE - col2 <> - col1
----
-1

skipif mysql # not compatible
query I rowsort label-9659
SELECT DISTINCT - col2 / col2 AS col2 FROM tab0 WHERE - col2 <> - col1
----
-1

query I rowsort
SELECT - tab1.col1 * tab1.col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT col0 + col2 * + col1 + col1 AS col0 FROM tab2
----
1671
742
875

query I rowsort
SELECT - col1 + + col1 FROM tab2 WHERE NOT - col2 <> - col0
----

query I rowsort
SELECT DISTINCT + col1 AS col1 FROM tab2 WHERE NULL IN ( - col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col1 col0 FROM tab0
----
-2
-62

query I rowsort
SELECT + col0 FROM tab0 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT col2 * tab0.col2 + + col2 * col1 FROM tab0
----
14186
3927
98

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) NOT IN ( col0 )
----

query I rowsort
SELECT + 58 + col1 AS col2 FROM tab2 AS cor0
----
117
75
89

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT col1 = ( NULL )
----

query I rowsort
SELECT DISTINCT col1 * - cor0.col2 + - ( + 88 ) FROM tab0 AS cor0
----
-185
-2926
-7550

query I rowsort
SELECT col2 - tab0.col1 AS col2 FROM tab0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9672
SELECT DISTINCT - col1 DIV + col2 + col2 AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9672
SELECT DISTINCT - col1 / + col2 + col2 AS col1 FROM tab1
----
54
57
96

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT ( col0 ) IN ( + cor0.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9674
SELECT + col1 DIV col2 + cor0.col2 * cor0.col1 col1 FROM tab0 AS cor0
----
194
2840
7463

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9674
SELECT + col1 / col2 + cor0.col2 * cor0.col1 col1 FROM tab0 AS cor0
----
194
2840
7463

query I rowsort
SELECT ALL - col2 + - col1 * - col1 FROM tab2
----
251
3455
934

query I rowsort
SELECT tab0.col1 * col0 + tab0.col2 * + col2 FROM tab0
----
14823
3153
3396

query I rowsort
SELECT col2 * tab2.col2 + + col2 AS col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT cor0.col1 + cor0.col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT - cor0.col2 * col1 + col1 * - col1 * + col0 FROM tab1 AS cor0
----
-14768
-3432
-6970

query III rowsort
SELECT ALL * FROM tab2 cor0 WHERE NOT ( NULL ) <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 16 ) + col1 * col0 col0 FROM tab2 AS cor0
----
1359
233
4618

query I rowsort
SELECT + - 13 + cor0.col2 AS col0 FROM tab1 cor0
----
41
44
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9683
SELECT DISTINCT ( + col2 ) * - cor0.col2 + CAST( 76 AS SIGNED ) FROM tab0 AS cor0
----
-1013
-6648
75

skipif mysql # not compatible
query I rowsort label-9683
SELECT DISTINCT ( + col2 ) * - cor0.col2 + CAST ( 76 AS INTEGER ) FROM tab0 AS cor0
----
-1013
-6648
75

query I rowsort
SELECT ALL + - 39 + col0 FROM tab2 AS cor0
----
-32
39
40

query I rowsort
SELECT + 20 * cor0.col2 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to b253fd93eadd9a6a37173ff025ac595c

query I rowsort
SELECT ALL col1 + - 48 FROM tab2
----
-17
-31
11

query I rowsort
SELECT col0 - + ( col0 ) FROM tab1
----
0
0
0

query I rowsort
SELECT + tab2.col0 * col0 + col0 AS col0 FROM tab2
----
56
6162
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 11 + ( + col2 ) + col2 col1 FROM tab1
----
119
125
203

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT 61 + 35 + col0 * CAST ( col2 + col1 AS REAL ) AS col0 FROM tab1
----
336
4384
8816

query I rowsort
SELECT ALL + col2 * ( cor0.col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + cor0.col2 + + 57 * col0 FROM tab0 AS cor0
----
1401
1996
5155

query I rowsort
SELECT - 99 * - col0 + + col1 AS col1 FROM tab0 AS cor0
----
2462
3562
8902

query I rowsort
SELECT DISTINCT - 97 * - col1 AS col0 FROM tab2 AS cor0
----
1649
3007
5723

onlyif mysql # use DIV operator for integer division
query I rowsort label-9695
SELECT DISTINCT + col2 DIV + 6 + - col1 FROM tab0 AS cor0
----
-78
-81
-97

skipif mysql # not compatible
query I rowsort label-9695
SELECT DISTINCT + col2 / + 6 + - col1 FROM tab0 AS cor0
----
-78
-81
-97

query I rowsort
SELECT ( 63 ) + - col1 AS col2 FROM tab0 AS cor0
----
-23
-28
-34

query I rowsort
SELECT DISTINCT + col1 * + col1 - col0 AS col2 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT - tab1.col1 * tab1.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 0cea1be551fb4bd88f4da0b7d676ee2f

query I rowsort
SELECT ( tab0.col0 ) * 18 + col1 AS col1 FROM tab0
----
1693
518
727

query I rowsort
SELECT DISTINCT + 18 AS col0 FROM tab0
----
18

query I rowsort
SELECT - 89 + + col1 * + col2 FROM tab0
----
2749
7373
8

query I rowsort
SELECT 81 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT ALL col1 - - 95 * + 4 * col0 FROM tab2 AS cor0
----
2691
29699
30037

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + + col1 + - cor0.col1 * - cor0.col0 col1 FROM tab0 AS cor0
----
2174
3527
8279

query I rowsort
SELECT DISTINCT - col2 * + ( + 39 ) FROM tab2 AS cor0
----
-1014
-1053
-1482

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9706
SELECT ALL + + cor0.col0 + ( + cor0.col2 + cor0.col1 * + CAST( - col1 AS SIGNED ) ) FROM tab1 AS cor0
----
-619
21
7

skipif mysql # not compatible
query I rowsort label-9706
SELECT ALL + + cor0.col0 + ( + cor0.col2 + cor0.col1 * + CAST ( - col1 AS INTEGER ) ) FROM tab1 AS cor0
----
-619
21
7

query I rowsort
SELECT col0 + + 5 * ( col1 ) AS col1 FROM tab2 AS cor0
----
162
164
373

onlyif mysql # use DIV operator for integer division
query I rowsort label-9708
SELECT DISTINCT - col0 * ( 76 + - col1 ) DIV col1 AS col1 FROM tab2 AS cor0
----
-10
-22
-274

skipif mysql # not compatible
query I rowsort label-9708
SELECT DISTINCT - col0 * ( 76 + - col1 ) / col1 AS col1 FROM tab2 AS cor0
----
-10
-22
-274

query I rowsort
SELECT ALL - col2 + 11 AS col1 FROM tab2 AS cor0
----
-15
-16
-27

query I rowsort
SELECT + col0 * - ( - col2 ) - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - col2 * ( cor0.col1 ) + col1 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT - - cor0.col2 FROM tab2, tab0, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT - cor0.col2 - - 8 FROM tab1 AS cor0
----
-46
-49
-88

query I rowsort
SELECT ALL - col1 + col1 * - 19 FROM tab2 AS cor0
----
-1180
-340
-620

query I rowsort
SELECT - + col1 - ( + 88 ) * + col0 AS col1 FROM tab2 AS cor0
----
-647
-6923
-6969

query I rowsort
SELECT DISTINCT col2 + + ( col2 ) * - col1 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT + - col0 * col2 + col1 + + cor0.col1 FROM tab0 cor0
----
-620
-7116
159

query I rowsort
SELECT DISTINCT col2 * - col1 + + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + + 40 AS col1 FROM tab2 AS cor0
----
40
40
40

query I rowsort
SELECT ALL + + col1 * + col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL tab0.col1 * - ( + col1 ) + tab0.col1 AS col2 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT cor0.col2 + 33 + col0 * - col0 * col2 AS col2 FROM tab1 AS cor0
----
-233382
-399
-614271

query I rowsort
SELECT + 63 * ( + col2 ) + col0 FROM tab1 AS cor0
----
3405
3655
6128

onlyif mysql # use DIV operator for integer division
query I rowsort label-9724
SELECT ALL + 72 + col0 DIV tab1.col1 AS col1 FROM tab1
----
72
78
78

skipif mysql # not compatible
query I rowsort label-9724
SELECT ALL + 72 + col0 / tab1.col1 AS col1 FROM tab1
----
72
78
78

query I rowsort
SELECT ( + col2 * col0 ) + col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT DISTINCT col2 + 71 AS col1 FROM tab2
----
109
97
98

query I rowsort
SELECT ALL - col2 * - 26 + - col2 AS col0 FROM tab1
----
1350
1425
2400

query I rowsort
SELECT + 71 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT 76 + - col2 AS col2 FROM tab1 AS cor0
----
-20
19
22

query I rowsort
SELECT ALL 54 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT + 95 + col0 AS col2 FROM tab1
----
159
175
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-9732
SELECT + 96 DIV 57 + col1 * col0 AS col1 FROM tab2
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-9732
SELECT + 96 / 57 + col1 * col0 AS col1 FROM tab2
----
1344
218
4603

query I rowsort
SELECT + 39 * - ( + col1 ) FROM tab1
----
-1014
-390
-507

query I rowsort
SELECT ALL + cor0.col1 + - 71 AS col2 FROM tab0 AS cor0
----
15
20
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9735
SELECT tab2.col1 - col0 DIV 2 AS col2 FROM tab2
----
-22
20
28

skipif mysql # not compatible
query I rowsort label-9735
SELECT tab2.col1 - col0 / 2 AS col2 FROM tab2
----
-22
20
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 + col1 * - col0 * tab1.col2 col2 FROM tab1
----
-36416
-4209
-99760

query I rowsort
SELECT ALL col0 + + 24 FROM tab2 cor0
----
102
103
31

query I rowsort
SELECT ALL cor0.col2 * col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col1 * ( + 90 ) AS col1 FROM tab2 AS cor0
----
-1530
-2790
-5310

query I rowsort
SELECT DISTINCT + + col1 * - cor0.col0 * - col2 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9741
SELECT + - col2 * CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-9741
SELECT + - col2 * CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT 48 + - col1 * col1 AS col1 FROM tab1
----
-121
-52
-628

query I rowsort
SELECT DISTINCT col2 + - 32 * col1 AS col2 FROM tab0
----
-2719
-2830
-3103

query I rowsort
SELECT tab1.col1 + - col0 * + col2 AS col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT + col2 + tab1.col0 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + - col0 + col1 + - cor0.col0 FROM tab0 AS cor0
----
-87
27
38

query I rowsort
SELECT ALL + + col0 * 6 * + 15 FROM tab1 AS cor0
----
270
5760
7200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9748
SELECT ALL + col2 + - CAST( - 14 AS SIGNED ) FROM tab1 cor0
----
110
68
71

skipif mysql # not compatible
query I rowsort label-9748
SELECT ALL + col2 + - CAST ( - 14 AS INTEGER ) FROM tab1 cor0
----
110
68
71

query I rowsort
SELECT DISTINCT + + col2 + + 69 * + cor0.col0 + col2 FROM tab1 AS cor0
----
315
4530
5712

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9750
SELECT - - col2 * CAST( NULL AS SIGNED ) + 65 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9750
SELECT - - col2 * CAST ( NULL AS INTEGER ) + 65 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9751
SELECT DISTINCT - col1 * CAST( col2 AS SIGNED ) + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif mysql # not compatible
query I rowsort label-9751
SELECT DISTINCT - col1 * CAST ( col2 AS INTEGER ) + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9752
SELECT ALL + - col0 + CAST( col2 AS SIGNED ) AS col2 FROM tab1 cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-9752
SELECT ALL + - col0 + CAST ( col2 AS INTEGER ) AS col2 FROM tab1 cor0
----
-7
16
51

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0, tab0 cor0 WHERE NULL < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * - tab1.col1 col1 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col0 * - col2 + col0 * - col0 FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col2 + col1 * col1 * col1 AS col0 FROM tab2 cor0
----
207381
29953
7877

query I rowsort
SELECT ALL cor0.col2 + cor0.col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col2 FROM tab1 AS cor0 WHERE ( col1 ) NOT BETWEEN NULL AND ( - col0 * + col2 ) OR NULL IN ( - col1 * col0 + + col2 * + col0 / cor0.col2 + - col1 )
----
54
57
96

query I rowsort
SELECT cor0.col1 + + col1 * col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT col0 - col2 * col2 FROM tab0 cor0
----
-1065
-6635
34

query I rowsort
SELECT - + col1 - col2 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT col1 * col2 + cor0.col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + 39 * + col2 FROM tab1 cor0
----
2106
2223
3744

onlyif mysql # use DIV operator for integer division
query I rowsort label-9764
SELECT ALL + - col1 + + col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-9764
SELECT ALL + - col1 + + col1 / - col1 AS col0 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT DISTINCT + 98 AS col1 FROM tab1 AS cor0
----
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + col2 * col0 col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - 51 * col2 AS col2 FROM tab0
----
-1683
-4182
-51

query I rowsort
SELECT + col1 * - col2 + + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - + cor0.col1 * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + - 95 * + col2 AS col2 FROM tab2 AS cor0
----
-2470
-2565
-3610

query I rowsort
SELECT DISTINCT + + 4 * - col1 FROM tab1 AS cor0
----
-104
-40
-52

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE col1 <> NULL AND NULL IN ( col2 ) OR NOT NULL <= col2 + col0 + col0
----

query I rowsort
SELECT DISTINCT + col1 * - tab2.col0 * - col2 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT 56 * + col0 + + col0 + col2 FROM tab1 cor0
----
225
3705
4656

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9775
SELECT + col2 * cor0.col0 + CAST( col0 AS SIGNED ) - - col2 FROM tab1 AS cor0
----
219
3769
7856

skipif mysql # not compatible
query I rowsort label-9775
SELECT + col2 * cor0.col0 + CAST ( col0 AS INTEGER ) - - col2 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT cor0.col2 + + cor0.col0 * col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + col0 * col1 + + col2 * + ( col0 * + ( + col1 ) ) AS col0 FROM tab0 AS cor0
----
672217
6790
70176

query I rowsort
SELECT col0 + col2 * - col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + + col1 + col0 * - col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL - 48 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT ALL + col2 + - ( 4 ) AS col1 FROM tab1 AS cor0
----
50
53
92

query I rowsort
SELECT - - col0 * - 73 + - col1 + - ( + col1 ) * + col0 FROM tab0 AS cor0
----
-14687
-3902
-6047

query I rowsort
SELECT ( + col2 ) + col0 + + 57 FROM tab2 AS cor0
----
161
174
91

query I rowsort
SELECT DISTINCT - - col2 * col0 * cor0.col1 AS col0 FROM tab0 cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - 20 FROM tab1, tab1 AS cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT col0 + ( - col1 ) * - 44 FROM tab0
----
3808
4093
4303

query I rowsort
SELECT DISTINCT + 22 * + col1 AS col2 FROM tab0
----
1892
2002
2134

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT + 40 * - col2 * - tab0.col2 FROM tab0
----
268960
40
43560

onlyif mysql # use DIV operator for integer division
query I rowsort label-9792
SELECT cor0.col0 DIV - 89 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-9792
SELECT cor0.col0 / - 89 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT + col2 - + col0 * - col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT DISTINCT + - cor0.col2 + + col2 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + cor0.col1 + col2 + col2 AS col0 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT DISTINCT col2 * - col1 + + 28 FROM tab2 cor0
----
-1506
-618
-809

query I rowsort
SELECT ( col1 ) - + 9 AS col2 FROM tab0 AS cor0
----
77
82
88

query I rowsort
SELECT + - col0 + col0 * + col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL - cor0.col1 * cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9800
SELECT ALL + + col2 * - cor0.col0 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9800
SELECT ALL + + col2 * - cor0.col0 + - CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
-17
-31
-59

query I rowsort
SELECT 73 FROM tab1, tab0 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT + - col1 * + cor0.col1 + - 88 FROM tab0 AS cor0
----
-7484
-8369
-9497

query I rowsort
SELECT ALL + col1 + + col1 * + 62 AS col2 FROM tab2
----
1071
1953
3717

query I rowsort
SELECT ALL + 68 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT DISTINCT col1 - + tab1.col0 * + col2 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL - col0 * - col0 + + col1 AS col2 FROM tab1
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-9808
SELECT - + cor0.col2 + - col1 * - col1 DIV col1 FROM tab2 AS cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-9808
SELECT - + cor0.col2 + - col1 * - col1 / col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL col1 + + col0 * + col0 AS col2 FROM tab1
----
35
4106
6413

query I rowsort
SELECT DISTINCT - + col0 * col1 * col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL + col2 + cor0.col2 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT - - 14 * - col1 AS col2 FROM tab2 AS cor0
----
-238
-434
-826

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col1 col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT + + col2 + 77 FROM tab2 AS cor0
----
103
104
115

query I rowsort
SELECT ALL + ( col1 ) - col0 * 73 AS col2 FROM tab1 AS cor0
----
-193
-4662
-5827

query I rowsort
SELECT DISTINCT + 58 + 52 FROM tab1 AS cor0
----
110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 * 12 + + col2 col1 FROM tab0 AS cor0
----
1065
1165
1174

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9818
SELECT CAST( col1 AS SIGNED ) col2 FROM tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9818
SELECT CAST ( col1 AS INTEGER ) col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT 44 + - col2 AS col1 FROM tab2 AS cor0
----
17
18
6

query I rowsort
SELECT ALL - - col0 - + col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + + ( cor0.col1 ) + + col0 * - col1 FROM tab1 AS cor0
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * 68 col0 FROM tab1 AS cor0
----
3672
3876
6528

onlyif mysql # use DIV operator for integer division
query I rowsort label-9823
SELECT - col0 * col1 + col2 * col1 + ( 74 ) * col0 DIV col0 AS col0 FROM tab1
----
1400
282
4

skipif mysql # not compatible
query I rowsort label-9823
SELECT - col0 * col1 + col2 * col1 + ( 74 ) * col0 / col0 AS col0 FROM tab1
----
1400
282
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + ( - col1 ) * + col0 col1 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT - tab0.col2 + 69 AS col0 FROM tab0
----
-13
36
68

query I rowsort
SELECT + - col2 * 21 FROM tab0 AS cor0
----
-1722
-21
-693

query I rowsort
SELECT col2 * 36 FROM tab1 AS cor0
----
1944
2052
3456

query I rowsort
SELECT + + col1 * ( + col2 ) AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - - ( col0 ) + col1 * + 52 + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-49
-492
14

query I rowsort
SELECT ALL cor0.col1 * + cor0.col0 + - cor0.col1 + - col1 AS col1 FROM tab1 AS cor0
----
1014
26
620

query I rowsort
SELECT ALL 42 * col1 + col2 * 25 FROM tab1 AS cor0
----
1845
2442
2946

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9832
SELECT - CAST( NULL AS DECIMAL ) * + 5 - cor0.col0 * + cor0.col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9832
SELECT - CAST ( NULL AS REAL ) * + 5 - cor0.col0 * + cor0.col1 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 37 + - col1 FROM tab0 AS cor0
----
-49
-54
-60

query I rowsort
SELECT DISTINCT col0 - + 18 FROM tab2 cor0
----
-11
60
61

query I rowsort
SELECT DISTINCT + col1 - col1 * - col2 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-9836
SELECT col0 DIV - cor0.col0 + + col0 * col1 * - col2 AS col1 FROM tab2 AS cor0
----
-119653
-51035
-5860

skipif mysql # not compatible
query I rowsort label-9836
SELECT col0 / - cor0.col0 + + col0 * col1 * - col2 AS col1 FROM tab2 AS cor0
----
-119653
-51035
-5860

skipif mysql # not compatible
query I rowsort
SELECT ALL - - CAST ( + col2 AS REAL ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - - cor0.col2 - 24 AS col2 FROM tab0 AS cor0
----
-23
58
9

query I rowsort
SELECT ALL + tab1.col2 + tab1.col1 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9840
SELECT col0 * - CAST( 74 AS SIGNED ) * - col2 + + 83 + col2 col0 FROM tab1
----
12125
270092
568499

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9840
SELECT col0 * - CAST ( 74 AS INTEGER ) * - col2 + + 83 + col2 col0 FROM tab1
----
12125
270092
568499

query I rowsort
SELECT - cor1.col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - cor0.col1 * - col1 + + 86 AS col2 FROM tab0 AS cor0
----
7482
8367
9495

query I rowsort
SELECT ALL + 93 * col2 FROM tab1 AS cor0
----
5022
5301
8928

query I rowsort
SELECT ALL - + 39 AS col1 FROM tab0 AS cor0
----
-39
-39
-39

query I rowsort
SELECT + col1 * col1 * cor0.col2 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9846
SELECT DISTINCT 50 * col1 * + col0 + CAST( - 53 AS SIGNED ) AS col2 FROM tab1
----
31947
3847
51947

skipif mysql # not compatible
query I rowsort label-9846
SELECT DISTINCT 50 * col1 * + col0 + CAST ( - 53 AS INTEGER ) AS col2 FROM tab1
----
31947
3847
51947

query I rowsort
SELECT ALL - 9 + col2 * col0 AS col2 FROM tab0 AS cor0
----
26
7289
783

query I rowsort
SELECT ALL + col2 * + cor0.col0 AS col0 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col2 + + col0 col0 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT col0 + + col0 * 70 FROM tab1
----
213
4544
5680

query I rowsort
SELECT DISTINCT - 36 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-36

query I rowsort
SELECT DISTINCT col1 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - + 58 AS col1 FROM tab1 AS cor0
----
-58
-58
-58

query I rowsort
SELECT + col2 * + col0 AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + cor0.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query IIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab0 AS cor0 WHERE NULL < ( NULL )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9857
SELECT - col2 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9857
SELECT - col2 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9858
SELECT ALL ( - col2 + col0 ) DIV tab2.col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-9858
SELECT ALL ( - col2 + col0 ) / tab2.col1 FROM tab2
----
0
0
2

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2, tab1 cor3
----
3645 values hashing to fc7c00509fb9d4b8a5290fa6926cc518

query I rowsort
SELECT - cor1.col0 AS col1 FROM tab1, tab1 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

onlyif mysql # use DIV operator for integer division
query I rowsort label-9861
SELECT DISTINCT - col0 DIV 83 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-9861
SELECT DISTINCT - col0 / 83 FROM tab1
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9862
SELECT ALL - - col2 DIV 45 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9862
SELECT ALL - - col2 / 45 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9863
SELECT col0 DIV - 75 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9863
SELECT col0 / - 75 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL cor0.col1 * - col2 + - ( col0 ) AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT + - col1 * - 17 FROM tab0 AS cor0
----
1462
1547
1649

query I rowsort
SELECT ALL + - cor0.col2 * col1 + 98 FROM tab0 AS cor0
----
-2740
-7364
1

query I rowsort
SELECT 24 FROM tab0, tab1 cor0 CROSS JOIN tab1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT - 89 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 924a74d31360fa4301c953b423a4710e

query I rowsort
SELECT - + ( - col0 ) + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - + 19 * + col1 FROM tab2 AS cor0
----
-1121
-323
-589

query I rowsort
SELECT ALL + 93 AS col0 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT DISTINCT - - 87 AS col1 FROM tab1 AS cor0
----
87

query I rowsort
SELECT 20 + col2 FROM tab1 cor0
----
116
74
77

query I rowsort
SELECT ALL + col1 + col0 - 15 FROM tab1 AS cor0
----
14
59
78

query I rowsort
SELECT DISTINCT - + 13 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
1239
345
456

query I rowsort
SELECT ALL 88 + 11 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to 66b0b0906bcd72d5f1ade3ec251d414d

query I rowsort
SELECT - - col0 + + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + 52 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 82 col1 FROM tab2 AS cor0
----
82
82
82

query I rowsort
SELECT col0 + + ( - col2 ) AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT ALL - 80 + col0 AS col0 FROM tab2 cor0
----
-1
-2
-73

query I rowsort
SELECT ALL - 6 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

query I rowsort
SELECT 85 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e4cf94cf0cc632acff30ad1dac617cb7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9884
SELECT + + col1 DIV col0 - col2 * - 13 AS col0 FROM tab2 AS cor0
----
338
355
494

skipif mysql # not compatible
query I rowsort label-9884
SELECT + + col1 / col0 - col2 * - 13 AS col0 FROM tab2 AS cor0
----
338
355
494

query I rowsort
SELECT DISTINCT - 21 AS col0 FROM tab2 cor0
----
-21

query I rowsort
SELECT - 43 + + col2 AS col1 FROM tab0 cor0
----
-10
-42
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-9887
SELECT ALL + + 87 DIV ( + col1 ) AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9887
SELECT ALL + + 87 / ( + col1 ) AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - col1 - col2 * - col2 * + tab2.col0 AS col2 FROM tab2
----
114059
5072
52669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9889
SELECT - col1 + CAST( NULL AS SIGNED ) * + tab1.col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9889
SELECT - col1 + CAST ( NULL AS INTEGER ) * + tab1.col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col0 * 16 AS col1 FROM tab0
----
1424
384
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-9891
SELECT ALL + 69 DIV + 6 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9891
SELECT ALL + 69 / + 6 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9892
SELECT DISTINCT CAST( NULL AS SIGNED ) + col2 / col0 + - ( col2 ) * - col1 / - 76 col0 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9892
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col2 / col0 + - ( col2 ) * - col1 / - 76 col0 FROM tab0
----
NULL

query I rowsort
SELECT - 31 * + ( col2 ) + - 97 + + col1 FROM tab0 AS cor0
----
-1034
-2548
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9894
SELECT + col1 * cor0.col0 * col1 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9894
SELECT + col1 * cor0.col0 * col1 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 17 AS col2 FROM tab0 AS cor0
----
17

query I rowsort
SELECT - 47 + col0 AS col2 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT ALL + col2 + + col2 * - col1 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT + col0 * col1 + + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - col0 * - col2 + + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT - 66 + col2 FROM tab0 AS cor0
----
-33
-65
16

query I rowsort
SELECT DISTINCT + - cor0.col2 * + 24 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-1296
-1368
-2304

query I rowsort
SELECT + col1 + col1 * + col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + 92 * col0 FROM tab1 AS cor0
----
276
5888
7360

onlyif mysql # use DIV operator for integer division
query I rowsort label-9904
SELECT DISTINCT - + col1 DIV col1 + - col2 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-9904
SELECT DISTINCT - + col1 / col1 + - col2 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT ALL - col2 * cor0.col2 * - 50 - - col2 AS col1 FROM tab2 AS cor0
----
33826
36477
72238

query I rowsort
SELECT DISTINCT - col2 + + 95 + col1 AS col0 FROM tab0 AS cor0
----
104
148
191

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2, tab0 AS cor2, tab1
----
13122 values hashing to 46f62700b24db410ea500cee901849b8

query I rowsort
SELECT - col2 * ( - cor0.col1 ) FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT + cor0.col1 * ( - col1 + col2 ) * - col2 FROM tab1 AS cor0
----
-103584
-26790
-39312

query I rowsort
SELECT DISTINCT + - col0 * - col1 * ( col2 ) FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - col2 * ( - col0 ) FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL col0 + + col2 * col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT - col2 * + 93 AS col0 FROM tab1 AS cor0
----
-5022
-5301
-8928

query I rowsort
SELECT col2 * 14 AS col1 FROM tab1 AS cor0
----
1344
756
798

query I rowsort
SELECT DISTINCT + - col1 * + 5 AS col0 FROM tab0 cor0
----
-430
-455
-485

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9916
SELECT + col2 * + CAST( + col1 + - col0 AS SIGNED ) FROM tab2 cor0
----
-2356
-494
648

skipif mysql # not compatible
query I rowsort label-9916
SELECT + col2 * + CAST ( + col1 + - col0 AS INTEGER ) FROM tab2 cor0
----
-2356
-494
648

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 + + CAST ( 55 AS REAL ) * col1 FROM tab1 cor0
----
1484
607
811

query I rowsort
SELECT col2 * - 14 AS col1 FROM tab1 AS cor0
----
-1344
-756
-798

query I rowsort
SELECT ALL - col2 * + 24 FROM tab2 AS cor0
----
-624
-648
-912

query I rowsort
SELECT - - 83 + 84 * cor0.col2 FROM tab2 AS cor0
----
2267
2351
3275

query I rowsort
SELECT DISTINCT - 34 * - col1 AS col2 FROM tab1 AS cor0
----
340
442
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-9922
SELECT ALL col1 + - cor0.col2 * - col0 DIV - ( col0 ) AS col1 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-9922
SELECT ALL col1 + - cor0.col2 * - col0 / - ( col0 ) AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL + col2 * - col0 - + col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL + 37 + col0 FROM tab2 AS cor0
----
115
116
44

query I rowsort
SELECT - + col1 * - 70 + - cor0.col0 FROM tab2 AS cor0
----
1111
2163
4052

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) + col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col1 * col1 + - col2 * + 95 FROM tab2 AS cor0
----
-1604
-3321
1011

query I rowsort
SELECT 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-9929
SELECT - CAST( NULL AS DECIMAL ) + ( col2 ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9929
SELECT - CAST ( NULL AS REAL ) + ( col2 ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + 20 AS col1 FROM tab2 AS cor0
----
-18
-6
-7

query I rowsort
SELECT ALL - tab1.col1 * + col1 FROM tab1
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 93 * col0 col1 FROM tab1 AS cor0
----
279
5952
7440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9933
SELECT DISTINCT - col1 + cor0.col2 * + CAST( - 71 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-1905
-1948
-2715

skipif mysql # not compatible
query I rowsort label-9933
SELECT DISTINCT - col1 + cor0.col2 * + CAST ( - 71 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-1905
-1948
-2715

onlyif mysql # use DIV operator for integer division
query I rowsort label-9934
SELECT - col0 DIV - col2 + + col1 col2 FROM tab1 AS cor0
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9934
SELECT - col0 / - col2 + + col1 col2 FROM tab1 AS cor0
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 60 + - tab1.col2 col2 FROM tab1, tab1 AS cor0
----
-36
3
6

query I rowsort
SELECT + + col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + + col2 + - col1 * 67 - - col0 FROM tab1 AS cor0
----
-1685
-549
-695

query I rowsort
SELECT ALL - 99 * col1 FROM tab1
----
-1287
-2574
-990

query I rowsort
SELECT - tab1.col0 + - 23 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 3fb3cc4c9079d46d0ec835cb47ec495c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9940
SELECT DISTINCT tab0.col2 * col1 * - CAST( - 77 AS SIGNED ) FROM tab0
----
218526
574574
7469

skipif mysql # not compatible
query I rowsort label-9940
SELECT DISTINCT tab0.col2 * col1 * - CAST ( - 77 AS INTEGER ) FROM tab0
----
218526
574574
7469

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 + col0 * - tab1.col1 col2 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT + - 51 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

query I rowsort
SELECT - 14 + col0 FROM tab2
----
-7
64
65

query I rowsort
SELECT + + col1 + + col1 * - col2 * col2 AS col0 FROM tab2 AS cor0
----
-22568
-24531
-39825

onlyif mysql # use DIV operator for integer division
query I rowsort label-9945
SELECT + 96 + - cor0.col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
131
96
97

skipif mysql # not compatible
query I rowsort label-9945
SELECT + 96 + - cor0.col0 / - col2 AS col0 FROM tab0 AS cor0
----
131
96
97

query I rowsort
SELECT 20 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT ALL - cor0.col0 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + 23 * col0 - + col1 * col2 FROM tab2 AS cor0
----
-676
1171
260

query I rowsort
SELECT - ( + 79 ) AS col0 FROM tab0
----
-79
-79
-79

query I rowsort
SELECT + 23 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT ALL - + ( - cor0.col0 ) AS col0 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9952
SELECT ALL + ( - col2 ) DIV 73 AS col1 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9952
SELECT ALL + ( - col2 ) / 73 AS col1 FROM tab0
----
-1
0
0

query I rowsort
SELECT ALL + 23 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT cor0.col2 + - 51 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to a9705de7650612e06898d7a2c7891f53

query I rowsort
SELECT ALL col1 * col1 * col0 AS col0 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT DISTINCT - col1 * col2 * - col2 AS col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT ALL + - 28 * + col0 FROM tab1 cor0
----
-1792
-2240
-84

query I rowsort
SELECT cor0.col2 * - col0 + 21 * + cor0.col1 AS col1 FROM tab2 cor0
----
-2645
-789
462

onlyif mysql # use DIV operator for integer division
query I rowsort label-9959
SELECT DISTINCT col0 + + col2 * 48 DIV col2 FROM tab1
----
112
128
51

skipif mysql # not compatible
query I rowsort label-9959
SELECT DISTINCT col0 + + col2 * 48 / col2 FROM tab1
----
112
128
51

query I rowsort
SELECT ALL + 42 * - tab1.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 3e0f8044842c2fda8718bca4fd6ef49e

query I rowsort
SELECT ALL 64 * 22 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to dc91e85b22e1d6af2e23a2a4b0cea6f1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9962
SELECT col1 DIV - 16 + - col1 AS col1 FROM tab2
----
-18
-32
-62

skipif mysql # not compatible
query I rowsort label-9962
SELECT col1 / - 16 + - col1 AS col1 FROM tab2
----
-18
-32
-62

query I rowsort
SELECT ALL col2 * + 77 FROM tab0 AS cor0
----
2541
6314
77

query I rowsort
SELECT col1 + + col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT - col1 + + col0 * 9 + col2 FROM tab2 AS cor0
----
59
669
732

query I rowsort
SELECT DISTINCT + - col2 + - col2 * + cor0.col2 FROM tab1 cor0
----
-2970
-3306
-9312

query I rowsort
SELECT + cor0.col2 - + col0 * col1 AS col2 FROM tab2 cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-9968
SELECT DISTINCT col1 DIV ( - 8 * col1 ) FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9968
SELECT DISTINCT col1 / ( - 8 * col1 ) FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col0 * ( + cor0.col2 ) + + cor0.col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL col1 * col1 - 25 AS col1 FROM tab2 AS cor0
----
264
3456
936

query I rowsort
SELECT DISTINCT + + col1 * - 62 FROM tab0 cor0
----
-5332
-5642
-6014

query I rowsort
SELECT ALL - + col1 * + 13 AS col0 FROM tab2 AS cor0
----
-221
-403
-767

onlyif mysql # use DIV operator for integer division
query I rowsort label-9973
SELECT DISTINCT 54 DIV - cor0.col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-9973
SELECT DISTINCT 54 / - cor0.col1 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - + 58 * cor0.col0 + col2 AS col1 FROM tab0 AS cor0
----
-1359
-2029
-5080

query I rowsort
SELECT DISTINCT + 37 + 71 FROM tab1 AS cor0
----
108

query I rowsort
SELECT DISTINCT - - col1 * 32 + + col2 * ( col1 ) FROM tab2 AS cor0
----
1190
1829
3422

query I rowsort
SELECT DISTINCT + + col0 + + 14 AS col0 FROM tab2 AS cor0
----
21
92
93

query I rowsort
SELECT ALL - + col0 * + 78 FROM tab0 AS cor0
----
-1872
-2730
-6942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 col2 FROM tab1 AS cor0
----
50
50
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-9980
SELECT ALL - - 23 * - col0 + col0 DIV + cor0.col0 FROM tab0 AS cor0
----
-2046
-551
-804

skipif mysql # not compatible
query I rowsort label-9980
SELECT ALL - - 23 * - col0 + col0 / + cor0.col0 FROM tab0 AS cor0
----
-2046
-551
-804

onlyif mysql # use DIV operator for integer division
query I rowsort label-9981
SELECT DISTINCT + + 27 DIV col1 AS col0 FROM tab1 cor0
----
1
2

skipif mysql # not compatible
query I rowsort label-9981
SELECT DISTINCT + + 27 / col1 AS col0 FROM tab1 cor0
----
1
2

query I rowsort
SELECT + - col2 + + ( col0 ) AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL + - col0 + 82 FROM tab1 AS cor0
----
18
2
79

query I rowsort
SELECT col2 * 16 AS col1 FROM tab2 AS cor0
----
416
432
608

query I rowsort
SELECT + cor0.col1 FROM tab0, tab2 AS cor0 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT + + ( col0 ) * col1 * + 24 + + col1 AS col0 FROM tab2 AS cor0
----
110507
32249
5239

query I rowsort
SELECT - + col0 + 19 FROM tab1 AS cor0
----
-45
-61
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-9988
SELECT - - 53 + - cor0.col1 DIV + col1 FROM tab2 AS cor0
----
52
52
52

skipif mysql # not compatible
query I rowsort label-9988
SELECT - - 53 + - cor0.col1 / + col1 FROM tab2 AS cor0
----
52
52
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-9989
SELECT ALL + col1 + + 65 DIV + col1 AS col0 FROM tab1 cor0
----
16
18
28

skipif mysql # not compatible
query I rowsort label-9989
SELECT ALL + col1 + + 65 / + col1 AS col0 FROM tab1 cor0
----
16
18
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-9990
SELECT + 15 * 54 DIV + col0 AS col2 FROM tab2 AS cor0
----
10
10
115

skipif mysql # not compatible
query I rowsort label-9990
SELECT + 15 * 54 / + col0 AS col2 FROM tab2 AS cor0
----
10
10
115

query I rowsort
SELECT DISTINCT + cor0.col1 + + 78 AS col0 FROM tab2, tab0 cor0
----
164
169
175

query I rowsort
SELECT + - 23 * + 11 + + col1 * ( 1 * - col0 ) FROM tab2 AS cor0
----
-1596
-470
-4855

onlyif mysql # use DIV operator for integer division
query I rowsort label-9993
SELECT + 10 DIV - 43 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9993
SELECT + 10 / - 43 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 * + col1 + + ( - col1 * + col1 + ( col2 ) ) FROM tab1 AS cor0
----
1175
527
782

query I rowsort
SELECT + + col1 * cor0.col2 + 62 AS col2 FROM tab1 AS cor0
----
1310
1466
632

query I rowsort
SELECT ( tab0.col1 ) * tab0.col2 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col0 col1 FROM tab1, tab0 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL tab0.col2 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-9999
SELECT + col2 * col2 DIV - 88 + col0 - col2 FROM tab1 AS cor0
----
-120
-29
-84

skipif mysql # not compatible
query I rowsort label-9999
SELECT + col2 * col2 / - 88 + col0 - col2 FROM tab1 AS cor0
----
-120
-29
-84

